2020-10-26 17:40:38 +01:00
|
|
|
<%@page contentType="text/html"%>
|
2020-10-26 12:24:23 +01:00
|
|
|
<%@page pageEncoding="UTF-8"%>
|
|
|
|
|
|
|
|
<%-- Uncomment below lines to add portlet taglibs to jsp
|
|
|
|
<%@ page import="javax.portlet.*"%>
|
|
|
|
<%@ taglib uri="http://java.sun.com/portlet_2_0" prefix="portlet"%>
|
|
|
|
|
|
|
|
<portlet:defineObjects />
|
|
|
|
--%>
|
|
|
|
|
2020-10-26 17:40:38 +01:00
|
|
|
<script
|
|
|
|
src='<%=request.getContextPath()%>/GeoportalDataViewer/js/jquery-1.10.1.min.js'></script>
|
|
|
|
|
|
|
|
<script
|
|
|
|
src='<%=request.getContextPath()%>/GeoportalDataViewer/js/bootstrap.min.js'></script>
|
|
|
|
|
|
|
|
<link
|
2022-08-29 15:14:01 +02:00
|
|
|
href="//cdn.jsdelivr.net/gh/openlayers/openlayers.github.io@main/dist/en/v6.4.3/css/ol.css"
|
2020-10-26 17:40:38 +01:00
|
|
|
rel="stylesheet" type="text/css">
|
|
|
|
|
|
|
|
<script
|
2022-08-29 15:14:01 +02:00
|
|
|
src="//cdn.jsdelivr.net/gh/openlayers/openlayers.github.io@main/dist/en/v6.4.3/build/ol.js"
|
2020-10-26 17:40:38 +01:00
|
|
|
type="text/javascript"></script>
|
|
|
|
|
2021-07-23 19:02:24 +02:00
|
|
|
<link
|
|
|
|
href="//cdnjs.cloudflare.com/ajax/libs/nanogallery2/3.0.5/css/nanogallery2.min.css"
|
|
|
|
rel="stylesheet" type="text/css">
|
|
|
|
|
2022-11-02 18:05:38 +01:00
|
|
|
<script
|
|
|
|
src="//unpkg.com/vis-timeline@7.7.0/standalone/umd/vis-timeline-graph2d.min.js"
|
|
|
|
type="text/javascript"></script>
|
|
|
|
|
|
|
|
<script
|
|
|
|
src="//cdnjs.cloudflare.com/ajax/libs/handlebars.js/4.7.7/handlebars.min.js"
|
|
|
|
type="text/javascript"></script>
|
|
|
|
|
|
|
|
<link
|
|
|
|
href="//unpkg.com/vis-timeline@7.7.0/styles/vis-timeline-graph2d.min.css"
|
|
|
|
rel="stylesheet" type="text/css">
|
|
|
|
|
2020-10-26 12:24:23 +01:00
|
|
|
<link rel="stylesheet"
|
2020-10-26 17:40:38 +01:00
|
|
|
href="<%=request.getContextPath()%>/GeoportalDataViewer.css"
|
2020-10-26 12:24:23 +01:00
|
|
|
type="text/css">
|
|
|
|
|
|
|
|
<script type="text/javascript"
|
|
|
|
src="<%=request.getContextPath()%>/GeoportalDataViewer/GeoportalDataViewer.nocache.js"></script>
|
|
|
|
|
2022-11-02 18:05:38 +01:00
|
|
|
<script id="item-template" type="text/x-handlebars-template">
|
|
|
|
<table>
|
2022-11-08 10:45:39 +01:00
|
|
|
{{#if selected}}
|
2022-11-02 18:05:38 +01:00
|
|
|
<tr><td>
|
2022-11-08 10:45:39 +01:00
|
|
|
<span id="relation-style">{{selected}}</span>
|
2022-11-02 18:05:38 +01:00
|
|
|
</tr></td>
|
|
|
|
{{/if}}
|
|
|
|
{{#if image_url}}
|
|
|
|
<tr><td>
|
|
|
|
<img src="{{image_url}}"></img>
|
|
|
|
</tr></td>
|
|
|
|
{{/if}}
|
|
|
|
<tr>
|
2022-11-03 17:03:15 +01:00
|
|
|
<th colspan="3" class="description">{{truncate_msg content}}</th>
|
2022-11-02 18:05:38 +01:00
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td><code>{{dateformat start}} / {{dateformat end}}</code></td>
|
|
|
|
</tr>
|
|
|
|
</table>
|
2022-11-03 17:03:15 +01:00
|
|
|
</script>
|
2022-11-02 18:05:38 +01:00
|
|
|
|
|
|
|
<script type="text/javascript">
|
|
|
|
Handlebars
|
|
|
|
.registerHelper('dateformat',
|
|
|
|
function(date) {
|
|
|
|
try {
|
|
|
|
if (date) {
|
|
|
|
var d = new Date(date), month = ''
|
|
|
|
+ (d.getMonth() + 1), day = ''
|
|
|
|
+ d.getDate(), year = d.getFullYear();
|
|
|
|
|
|
|
|
if (month.length < 2)
|
|
|
|
month = '0' + month;
|
|
|
|
if (day.length < 2)
|
|
|
|
day = '0' + day;
|
|
|
|
|
|
|
|
return [ year, month, day ].join('-');
|
|
|
|
}
|
|
|
|
return "";
|
|
|
|
} catch (err) {
|
|
|
|
return date + "";
|
|
|
|
}
|
|
|
|
});
|
|
|
|
|
2022-11-08 10:45:39 +01:00
|
|
|
Handlebars.registerHelper("truncate_msg", function(input) {
|
2022-11-02 18:05:38 +01:00
|
|
|
|
2022-11-08 10:45:39 +01:00
|
|
|
max_lenght = 20;
|
2022-11-02 18:05:38 +01:00
|
|
|
|
|
|
|
if (input.length > max_lenght) {
|
|
|
|
return input.substring(0, max_lenght) + '...';
|
|
|
|
}
|
|
|
|
return input;
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
var templateHandlebars = Handlebars.compile(document
|
|
|
|
.getElementById('item-template').innerHTML);
|
|
|
|
|
|
|
|
var optionsTimeline = {
|
|
|
|
// specify a template for the items
|
|
|
|
template : templateHandlebars,
|
|
|
|
type : 'box'
|
|
|
|
};
|
|
|
|
</script>
|
|
|
|
|
2022-11-14 14:12:50 +01:00
|
|
|
<div id="app-notifier" class="app-notifier"></div>
|
2023-07-31 12:15:06 +02:00
|
|
|
<div id="layer-viewer" class="layer-panel"></div>
|
2022-11-02 18:05:38 +01:00
|
|
|
<div id="geoportal-data-viewer"></div>
|
|
|
|
<div class="timeline-container">
|
|
|
|
<div id="timeline-data"></div>
|
|
|
|
</div>
|