Skip to content
Snippets Groups Projects
Commit b966fda6 authored by Brita Linnestad's avatar Brita Linnestad
Browse files

fix: Store startdate but not enddate

parent 941aa9ea
No related branches found
No related tags found
Loading
This commit is part of merge request !23. Comments created here will be created in the context of that merge request.
......@@ -82,7 +82,6 @@
});
storeLocalSettings(userSettings);
console.info("Store current user settings", userSettings);
}
......@@ -92,15 +91,15 @@
const inputLatitudeElement = document.getElementById("latitude");
const inputLongitudeElement = document.getElementById("longitude");
const userSettingsFields = ["latitude","longitude","timezone","weatherStationId"];
const userSettingsFields = ["latitude","longitude","timezone","weatherStationId","startdate"];
const userSettingsRadios = ["weatherdataType","radioDays"];
let poiIdList = []
let selectedPoint = null;
let selectedFeature = undefined;
let startDate;
let endDate;
//let startDate;
//let endDate;
function selectCoordinates(coordinatesData) {
const selectedLatitude = coordinatesData ? coordinatesData.latitude : undefined;
......@@ -116,7 +115,6 @@
window.loadUserSettings = () => {
let userSettings = getLocalSettings(getNameSpaced("{{ form_id }}",userSettingsFields.concat(userSettingsRadios)), false);
console.info("User settings available when page is loaded", userSettings)
// Settings found, render form and run model
if(Object.keys(userSettings).length > 0)
......@@ -144,8 +142,8 @@
}
window.onload = async(event) => {
startDate = document.getElementById("startdate");
endDate = document.getElementById("endDate");
//startDate = document.getElementById("startdate");
//endDate = document.getElementById("endDate");
await applefruitMoth.renderWeatherstations();
loadUserSettings()
runModel();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment