From c3ded5e19f1420a17ab1cca8e4661c1760cfb09e Mon Sep 17 00:00:00 2001
From: Tor-Einar Skog <tor-einar.skog@nibio.no>
Date: Wed, 3 Mar 2021 11:01:58 +0100
Subject: [PATCH] Update to use historical counties from <=2017
Added momentjs to page to assist the form validation.
---
.../modules/barkbeetle/barkbeetleSeasonTrapsiteForm.ftl | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/src/main/webapp/templates/modules/barkbeetle/barkbeetleSeasonTrapsiteForm.ftl b/src/main/webapp/templates/modules/barkbeetle/barkbeetleSeasonTrapsiteForm.ftl
index 8046a4a8..1bab39a0 100644
--- a/src/main/webapp/templates/modules/barkbeetle/barkbeetleSeasonTrapsiteForm.ftl
+++ b/src/main/webapp/templates/modules/barkbeetle/barkbeetleSeasonTrapsiteForm.ftl
@@ -28,6 +28,7 @@
<script src="//code.jquery.com/ui/1.10.3/jquery-ui.min.js"></script>
<script type="text/javascript" src="/js/3rdparty/modernizr_custom.js"></script>
<script type="text/javascript" src="/js/3rdparty/proj4.js"></script>
+ <script type="text/javascript" src="/js/3rdparty/moment.min.js"></script>
<script type="text/javascript">
var theForm = document.getElementById("${formId}");
$(document).ready(function() {
@@ -95,8 +96,8 @@
)
.catch( error => console.info(error));
- // Get County and municipality from before 2012
- fetch("/corsproxy/https://proxy1.nibio.no/municipality_cache_ws/kommuneListe/N2000/4326/2019?lon=" + lon + "&lat=" + lat)
+ // Get County and municipality from before 2018
+ fetch("/corsproxy/https://proxy1.nibio.no/municipality_cache_ws/kommuneListe/N2000/4326/2017?lon=" + lon + "&lat=" + lat)
.then(response => response.json())
.then(municInfo =>{
if(municInfo.length == 0)
--
GitLab