@@ -9,7 +9,6 @@ import { createLogThunk } from '../application/logging/LoggingThunk';
99import { applicationGetConnectionUser , applicationIsStandalone } from '../application/ApplicationSelectors' ;
1010import { applicationGetLoggingSettings } from '../application/logging/LoggingSelectors' ;
1111import { NEODASH_VERSION , VERSION_TO_MIGRATE } from './DashboardReducer' ;
12- import { Date as Neo4jDate } from 'neo4j-driver-core/lib/temporal-types.js' ;
1312
1413export const removePageThunk = ( number ) => ( dispatch : any , getState : any ) => {
1514 try {
@@ -113,16 +112,6 @@ export const loadDashboardThunk = (uuid, text) => (dispatch: any, getState: any)
113112 throw `Invalid dashboard version: ${ dashboard . version } . Try restarting the application, or retrieve your cached dashboard using a debug report.` ;
114113 }
115114
116- // Cast dashboard parameters from serialized format to correct types
117- Object . keys ( dashboard . settings . parameters ) . forEach ( ( key ) => {
118- const value = dashboard . settings . parameters [ key ] ;
119-
120- // Serialized Date to Neo4jDate
121- if ( value && value . year && value . month && value . day ) {
122- dashboard . settings . parameters [ key ] = new Neo4jDate ( value . year , value . month , value . day ) ;
123- }
124- } ) ;
125-
126115 // Reverse engineer the minimal set of fields from the selection loaded.
127116 dashboard . pages . forEach ( ( p ) => {
128117 p . reports . forEach ( ( r ) => {
@@ -140,8 +129,8 @@ export const loadDashboardThunk = (uuid, text) => (dispatch: any, getState: any)
140129 const { application } = getState ( ) ;
141130
142131 dispatch ( updateGlobalParametersThunk ( application . parametersToLoadAfterConnecting ) ) ;
132+ dispatch ( updateGlobalParametersThunk ( dashboard . settings . parameters ) ) ;
143133 dispatch ( setParametersToLoadAfterConnecting ( null ) ) ;
144-
145134 // Pre-2.3.4 dashboards might now always have a UUID. Set it if not present.
146135 if ( ! dashboard . uuid ) {
147136 dispatch ( setDashboardUuid ( uuid ) ) ;
0 commit comments