Ero sivun ”Widget:Ol3MainPageMap” versioiden välillä
Järvi-meriwikistä
p (Tekstin korvaus – ”jQuery(window).load( function() { <!--{$id|default:CommonObsMap|escape:'html'}-->_func(); });” muotoon ”function <!--{$id|default:CommonObsMap|escape:'html'}-->_jQueryTest() { if ( typeof window.jQuery == 'undefined' ) { ) |
p (Tekstin korvaus – ”//cdn.polyfill.io/v2/polyfill.min.js?features=requestAnimationFrame,Element.prototype.classList,URL” muotoon ”https://cdnjs.cloudflare.com/polyfill/v3/polyfill.min.js”) |
||
(10 välissä olevaa versiota samalta käyttäjältä ei näytetä) | |||
Rivi 1: | Rivi 1: | ||
<includeonly> | <includeonly> | ||
− | <link rel="stylesheet" href=" | + | <link rel="stylesheet" href="/scripts/ol3/ol.css" type="text/css"> |
− | <script src="// | + | <script src="https://cdnjs.cloudflare.com/polyfill/v3/polyfill.min.js"></script> |
− | <script src=" | + | <script src="/scripts/ol3/ol.js"></script> |
− | <script src=" | + | <script src="/scripts/proj4js/dist/proj4.js"></script> |
− | <script src=" | + | <script src="/scripts/jwol3js/jwol3.js"></script> |
− | <link rel="stylesheet" href=" | + | <link rel="stylesheet" href="/scripts/ol-ext/dist/ol-ext.min.css" type="text/css"> |
− | <script src=" | + | <script src="/scripts/ol-ext/dist/ol-ext.min.js"></script> |
− | <link rel="stylesheet" href=" | + | <link rel="stylesheet" href="/scripts/ol-ext/overlay/popupoverlay.css" /> |
− | <link rel="stylesheet" href=" | + | <link rel="stylesheet" href="/scripts/ol-ext/overlay/popupoverlay.anim.css" /> |
<div class="jwMapContainer" style="height:<!--{$height|default:500|escape:'html'}-->px" > | <div class="jwMapContainer" style="height:<!--{$height|default:500|escape:'html'}-->px" > | ||
Rivi 41: | Rivi 41: | ||
var zoom = parseInt('<!--{$zoom|default:4|escape:'html'}-->'); | var zoom = parseInt('<!--{$zoom|default:4|escape:'html'}-->'); | ||
var base = '<!--{$base|default:osm|escape:'html'}-->'; | var base = '<!--{$base|default:osm|escape:'html'}-->'; | ||
+ | var days = <!--{$days|default:6|escape:'html'}-->; | ||
// do the base map with these settings | // do the base map with these settings | ||
Rivi 50: | Rivi 51: | ||
'zoom': zoom, | 'zoom': zoom, | ||
'layers': [ | 'layers': [ | ||
+ | { | ||
+ | 'type': 'coo311', | ||
+ | 'name': 'Vesi.fi-palvelun havainnot', | ||
+ | 'service_code': 'combined_ice_service_code_201806011206542', | ||
+ | 'obsSearch': "[[obsCode::ice]]", | ||
+ | 'hashtags': '_VesiFiObservation', | ||
+ | 'obsDays': days, | ||
+ | 'pointRadius': 8, | ||
+ | 'obsesColors': { 'type': 'cat', 'attribute': 'ice_combined_situation_singlevaluelist_201806011206544', 'values': [ { 'key': 1, 'color': '#308fb3' }, { 'key': 2, 'color': 'aqua' }, { 'key': 3, 'color': 'white' }, { 'key': 4, 'color': 'white' }, { 'key': 5, 'color': 'aqua' }, { 'key': 6, 'color': '#308fb3' } ] }, | ||
+ | 'obsesLabels': { 'type': 'num', 'attribute': 'ice_combined_thickness_number_201806011206545' }, | ||
+ | //'attribution': 'Havainnot: Järvi-meriwiki', | ||
+ | 'opacitySlider': false, | ||
+ | 'selectable': true, | ||
+ | 'zoomToExtent': false | ||
+ | }, | ||
{ | { | ||
'type': 'sitesNobses', | 'type': 'sitesNobses', | ||
Rivi 55: | Rivi 71: | ||
'siteSearch': '', | 'siteSearch': '', | ||
'obsSearch': "[[obsCode::ice||temp||alg]]", | 'obsSearch': "[[obsCode::ice||temp||alg]]", | ||
− | 'obsDays': | + | 'obsDays': days, |
//'attribution': 'Havainnot: Järvi-meriwiki', | //'attribution': 'Havainnot: Järvi-meriwiki', | ||
'opacitySlider': false, | 'opacitySlider': false, | ||
Rivi 61: | Rivi 77: | ||
'zoomToExtent': false | 'zoomToExtent': false | ||
}, | }, | ||
− | { 'type': 'geoloc', 'name': 'Sijaintisi', 'show': true, 'center': false, 'zoom': 12, 'track': false } | + | //{ 'type': 'geoloc', 'name': 'Sijaintisi', 'show': true, 'center': false, 'zoom': 12, 'track': false } |
], | ], | ||
'memo': memo | 'memo': memo |