From 1c4e3333251444ecdc32f995fff2952f520c3de2 Mon Sep 17 00:00:00 2001 From: Taka Date: Thu, 18 Oct 2018 08:41:56 +0000 Subject: [PATCH] Account for the timezone when unloading the scenario date. --- vasl_templates/webapp/static/snippets.js | 1 + 1 file changed, 1 insertion(+) diff --git a/vasl_templates/webapp/static/snippets.js b/vasl_templates/webapp/static/snippets.js index 6cdc536..27cbe38 100644 --- a/vasl_templates/webapp/static/snippets.js +++ b/vasl_templates/webapp/static/snippets.js @@ -192,6 +192,7 @@ function unload_snippet_params( unpack_scenario_date, show_warnings_for ) if ( unpack_scenario_date ) { var scenario_date = $( "input[name='SCENARIO_DATE']" ).datepicker( "getDate" ) ; if ( scenario_date ) { + scenario_date.setMinutes( scenario_date.getMinutes() - scenario_date.getTimezoneOffset() ) ; params.SCENARIO_DAY_OF_MONTH = scenario_date.getDate() ; var postfix ; if ( params.SCENARIO_DAY_OF_MONTH in _DAY_OF_MONTH_POSTFIXES )