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AAK,SAASvuB,GAAM,OAA+B,IAAxB6tB,EAAgB7tB,EAAW,IAAI,CACrE,IAAIuoB,KAAY8F,EACZpG,EAAoBC,EAAEmG,EAAa9F,KACrCN,EAAoBvX,EAAE6X,GAAY8F,EAAY9F,IAGhD,GAAG+F,EAAS,IAAInS,EAASmS,EAAQrG,EAClC,CAEA,IADGmG,GAA4BA,EAA2B7oB,GACrDqJ,EAAIia,EAASxnB,OAAQuN,IACzBgb,EAAUf,EAASja,GAChBqZ,EAAoBC,EAAE2F,EAAiBjE,IAAYiE,EAAgBjE,IACrEiE,EAAgBjE,GAAS,KAE1BiE,EAAgBjE,GAAW,EAE5B,OAAO3B,EAAoBW,EAAEzM,EAC9B,EAEIqS,EAAqBC,KAAK,+BAAiCA,KAAK,gCAAkC,GACtGD,EAAmBvtB,QAAQktB,EAAqBrC,KAAK,KAAM,IAC3D0C,EAAmB3gB,KAAOsgB,EAAqBrC,KAAK,KAAM0C,EAAmB3gB,KAAKie,KAAK0C,G,ICpFvF,IAAIE,EAAsBzG,EAAoBW,OAAEnnB,EAAW,CAAC,MAAM,WAAa,OAAOwmB,EAAoB,MAAQ,IAClHyG,EAAsBzG,EAAoBW,EAAE8F,E","sources":["webpack://travelviewer-ui/./src/env.ts","webpack://travelviewer-ui/./src/flavor/utils.ts","webpack://travelviewer-ui/./src/flavor/index.ts","webpack://travelviewer-ui/./src/flavor/types.ts","webpack://travelviewer-ui/./src/i18n.ts","webpack://travelviewer-ui/./src/App.vue","webpack://travelviewer-ui/./src/App.vue?38a5","webpack://travelviewer-ui/./src/App.vue?892f","webpack://travelviewer-ui/./src/App.vue?0e40","webpack://travelviewer-ui/./src/api/auth_utils.ts","webpack://travelviewer-ui/./src/api/mode.ts","webpack://travelviewer-ui/./src/api/activity.ts","webpack://travelviewer-ui/./src/api/sample.ts","webpack://travelviewer-ui/./src/api/query.ts","webpack://travelviewer-ui/./src/api/index.ts","webpack://travelviewer-ui/./src/store/modules/user/index.ts","webpack://travelviewer-ui/./src/store/modules/survey/index.ts","webpack://travelviewer-ui/./src/store/offline-data/load.ts","webpack://travelviewer-ui/./src/store/modules/sample/index.ts","webpack://travelviewer-ui/./src/store/modules/mode-activity/index.ts","webpack://travelviewer-ui/./src/store/modules/questionnaire/index.ts","webpack://travelviewer-ui/./src/store/modules/home-area/index.ts","webpack://travelviewer-ui/./src/store/modules/filter/index.ts","webpack://travelviewer-ui/./src/store/modules/result-board/index.ts","webpack://travelviewer-ui/./src/store/modules/query/index.ts","webpack://travelviewer-ui/./src/store/modules/query-settings/index.ts","webpack://travelviewer-ui/./src/store/actions.ts","webpack://travelviewer-ui/./src/store/index.ts","webpack://travelviewer-ui/./src/router/index.ts","webpack://travelviewer-ui/./src/main.ts","webpack://travelviewer-ui/./src/store/modules/query/types.ts","webpack://travelviewer-ui/./src/store/modules/result-board/types.ts","webpack://travelviewer-ui/./src/store/modules/survey/types.ts","webpack://travelviewer-ui/./src/utils/I18nLabel.ts","webpack://travelviewer-ui/./src/utils/dateHelpers.ts","webpack://travelviewer-ui/./src/utils/feature.ts","webpack://travelviewer-ui/./src/utils/log.ts","webpack://travelviewer-ui/./src/utils/maAggregate.ts","webpack://travelviewer-ui/./src/utils/palette.ts","webpack://travelviewer-ui/./src/utils/timeout.ts","webpack://travelviewer-ui/./node_modules/moment/locale/ sync ^\\.\\/.*$","webpack://travelviewer-ui/./src/locales/ sync [A-Za-z0-9-_,\\s]+\\.json$/","webpack://travelviewer-ui/webpack/bootstrap","webpack://travelviewer-ui/webpack/runtime/chunk loaded","webpack://travelviewer-ui/webpack/runtime/compat get default export","webpack://travelviewer-ui/webpack/runtime/define property getters","webpack://travelviewer-ui/webpack/runtime/ensure chunk","webpack://travelviewer-ui/webpack/runtime/get javascript chunk filename","webpack://travelviewer-ui/webpack/runtime/get mini-css chunk filename","webpack://travelviewer-ui/webpack/runtime/global","webpack://travelviewer-ui/webpack/runtime/hasOwnProperty shorthand","webpack://travelviewer-ui/webpack/runtime/load script","webpack://travelviewer-ui/webpack/runtime/make namespace object","webpack://travelviewer-ui/webpack/runtime/node module decorator","webpack://travelviewer-ui/webpack/runtime/publicPath","webpack://travelviewer-ui/webpack/runtime/css loading","webpack://travelviewer-ui/webpack/runtime/jsonp chunk loading","webpack://travelviewer-ui/webpack/startup"],"sourcesContent":["// eslint-disable-next-line import/prefer-default-export\nexport const apiUrl = `${process.env.VUE_APP_API}`;\n","import { AppFlavor } from '@/store/modules/survey/types';\nimport { Flavor, FlavorData } from './types';\n\n/**\n * Parses viewer flavor string to Flavor enum. Returns null if no\n * match is found.\n * @param str The string to parse\n * @returns Flavor or null\n */\nexport function parseFlavorStr(str : string): Flavor|null {\n if (str.toLocaleLowerCase() === Flavor.travelViewer.toLocaleLowerCase()) {\n return Flavor.travelViewer;\n } else if (str.toLocaleLowerCase() === Flavor.activeViewer.toLocaleLowerCase()) {\n return Flavor.activeViewer;\n } else {\n return null;\n }\n}\n\n/**\n * Factory function that builds the flavor data for\n * a given Flavor.\n * @param flavor\n */\nexport function getFlavorData(flavor : Flavor): FlavorData|null {\n switch (flavor) {\n case Flavor.travelViewer:\n return {\n id: Flavor.travelViewer,\n name: 'TravelViewer',\n appFlavor: AppFlavor.travelvu,\n supportUrl: 'mailto:travelviewer-support@travelvu.app',\n appSupportUrl: 'https://support.travelvu.app',\n } as FlavorData;\n case Flavor.activeViewer:\n return {\n id: Flavor.activeViewer,\n name: 'ActiveViewer',\n appFlavor: AppFlavor.activeTravel,\n supportUrl: 'mailto:travelviewer-support@travelvu.app',\n appSupportUrl: 'https://support.travelvu.app',\n } as FlavorData;\n default:\n return null;\n }\n}\n","import { Flavor, FlavorData } from './types';\nimport { getFlavorData, parseFlavorStr } from './utils';\n\n// Get flavor from VUE_APP_FLAVOR,\n// parse it and throw exception if invalid.\nconst vueAppFlavor = process.env.VUE_APP_FLAVOR;\nconst flavorOrNull = parseFlavorStr(vueAppFlavor ?? '');\n\nif (flavorOrNull === null) {\n throw Error('Invalid VUE_APP_FLAVOR env parameter. Only \"travelviewer\" or \"activeviewer\" is accepted');\n}\nconst flavorDataOrNull = getFlavorData(flavorOrNull);\nif (flavorDataOrNull === null) {\n throw Error('Invalid flavor');\n}\n\n// Then expose non-null Flavor and FlavorData\n\n/** Flavor of this build of travelviewer-ui */\nexport const flavor:Flavor = flavorOrNull!;\n\n/** Describes the runtime viewer flavor. */\nexport const flavorData:FlavorData = flavorDataOrNull!;\n","import { AppFlavor } from '@/store/modules/survey/types';\n\n/**\n * flavor of travelviewer-ui instance\n */\nexport enum Flavor {\n travelViewer = 'travelviewer',\n activeViewer = 'activeviewer',\n}\n\nexport interface FlavorData {\n id: Flavor;\n name: string;\n appFlavor: AppFlavor;\n supportUrl: string;\n appSupportUrl: string;\n}\n","import Vue from 'vue';\nimport VueI18n, { LocaleMessages } from 'vue-i18n';\nimport { flavor } from './flavor';\nimport { Flavor } from './flavor/types';\n\nVue.use(VueI18n);\n\nfunction loadLocaleMessages(): LocaleMessages {\n if (typeof jest !== 'undefined') {\n // Testing environment\n return {};\n }\n\n const locales = require.context('./locales', true, /[A-Za-z0-9-_,\\s]+\\.json$/i);\n const messages: LocaleMessages = {};\n locales.keys().forEach((key) => {\n const matched = key.match(/([A-Za-z0-9-_]+)\\./i);\n if (matched && matched.length > 1) {\n const locale = matched[1];\n const localeMessages = locales(key);\n\n // There is no point of maintaining duplicate translations that only differ on appName or viewerName.\n // Until we need to inform about the other flavor, we can str-replace brand names.\n //\n // It would be better if this could be done at build-time, but for now the string count is not\n // very high.\n if (flavor === Flavor.activeViewer) {\n Object.keys(localeMessages).forEach((key: string) => {\n if (localeMessages[key] !== null && localeMessages[key] !== undefined) {\n localeMessages[key] = localeMessages[key].replaceAll('TravelViewer', 'ActiveViewer');\n localeMessages[key] = localeMessages[key].replaceAll('TravelVu', 'ActiveTravel');\n }\n });\n }\n\n messages[locale] = localeMessages;\n }\n });\n return messages;\n}\n\nfunction getDefaultLanguage(messages : any) : string {\n // Default language => try to detect user language but fallback to english if unknown\n let defaultLang = navigator.language || (navigator as any).userLanguage;\n if (typeof defaultLang === 'string') {\n defaultLang = defaultLang.substring(0, 2); // eg. sv-SE, en-US. => 'sv', 'en'\n }\n // Norway have two languages Nynorsk and Bokmål with codes nn-NO and nb-NO.\n // Change both to 'no' which is what we use in TravelVu for our single Norwegian\n // language.\n if (['nn', 'nb'].indexOf(defaultLang) !== -1) {\n defaultLang = 'no';\n }\n\n if (messages[defaultLang] === undefined) {\n // Fallback to English if user have a non-supported language on their phone\n defaultLang = 'en';\n }\n\n return defaultLang;\n}\n\nconst messages = loadLocaleMessages();\n\nexport default new VueI18n({\n locale: process.env.VUE_APP_I18N_LOCALE || getDefaultLanguage(messages) || 'en',\n fallbackLocale: process.env.VUE_APP_I18N_FALLBACK_LOCALE || 'en',\n messages,\n});\n","var render = function render(){var _vm=this,_c=_vm._self._c,_setup=_vm._self._setupProxy;return _c('div',{attrs:{\"id\":\"app\"}},[_c('router-view')],1)\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","\nimport Vue from 'vue';\nimport Component from 'vue-class-component';\nimport Chart from 'chart.js';\nimport ChartDataLabels from 'chartjs-plugin-datalabels';\n\n@Component({\n components: {},\n})\nexport default class App extends Vue {\n /* eslint class-methods-use-this: [\"off\"] */\n mounted() {\n // Register ChartDataLabels. Documentation of it says\n // that it is enough to import it and it will auto register,\n // but in practice, it seems we need to register it like this:\n Chart.plugins.register(ChartDataLabels);\n Chart.defaults.global.defaultFontFamily = '\"Work Sans\"';\n }\n}\n","import mod from \"-!../node_modules/thread-loader/dist/cjs.js!../node_modules/babel-loader/lib/index.js!../node_modules/ts-loader/index.js??clonedRuleSet-41.use[2]!../node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./App.vue?vue&type=script&lang=ts&\"; export default mod; export * from \"-!../node_modules/thread-loader/dist/cjs.js!../node_modules/babel-loader/lib/index.js!../node_modules/ts-loader/index.js??clonedRuleSet-41.use[2]!../node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./App.vue?vue&type=script&lang=ts&\"","import { render, staticRenderFns } from \"./App.vue?vue&type=template&id=68c0348d&\"\nimport script from \"./App.vue?vue&type=script&lang=ts&\"\nexport * from \"./App.vue?vue&type=script&lang=ts&\"\nimport style0 from \"./App.vue?vue&type=style&index=0&id=68c0348d&prod&lang=scss&\"\n\n\n/* normalize component */\nimport normalizer from \"!../node_modules/@vue/vue-loader-v15/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","import { AxiosRequestConfig } from 'axios';\n\nexport const foo = 'bar';\nexport function authHeaders(token: string = '') : AxiosRequestConfig {\n return {\n headers: {\n Authorization: `Bearer ${token}`,\n },\n };\n}\n","import axios from 'axios';\nimport { Mode, AggregatedModeConfig } from '@/store/modules/mode-activity/types';\nimport { apiUrl } from '@/env';\nimport { authHeaders } from './auth_utils';\n\nexport default {\n async getModes(surveyId : number|null, token : string) {\n const config = authHeaders(token);\n if (surveyId !== null) {\n config.params = new URLSearchParams({\n surveyId: surveyId.toString(),\n });\n }\n return axios.get>(`${apiUrl}/v1/modes/list`, config);\n },\n// async setAggregatedModes(surveyId : number, aggregatedModes : AggregatedModeConfig) {\n// return axios.post(`${apiUrl}/v1/aggregated-mode`, {\n// surveyId,\n// aggregatedModes,\n// });\n// },\n// async getAggregatedModes(surveyId : number) {\n// const params = new URLSearchParams({\n// surveyId: surveyId.toString(),\n// });\n// return axios.get(`${apiUrl}/v1/aggregated-mode`, { params });\n// },\n};\n","import axios from 'axios';\nimport { Activity, AggregatedActivityConfig } from '@/store/modules/mode-activity/types';\nimport { apiUrl } from '@/env';\nimport { authHeaders } from './auth_utils';\n\nexport default {\n async getActivities(surveyId : number|null, token : string) {\n const config = authHeaders(token);\n if (surveyId !== null) {\n config.params = new URLSearchParams({\n surveyId: surveyId.toString(),\n });\n }\n return axios.get>(`${apiUrl}/v1/activities/list`, config);\n },\n// async setAggregatedActivities(\n// surveyId : number, aggregatedActivities : AggregatedActivityConfig,\n// ) {\n// return axios.post(`${apiUrl}/v1/aggregated-activitiy`, {\n// surveyId,\n// aggregatedActivities,\n// });\n// },\n// async getAggregatedActivities(surveyId : number) {\n// const params = new URLSearchParams({\n// surveyId: surveyId.toString(),\n// });\n// return axios.get(`${apiUrl}/v1/aggregated-activity`, { params });\n// },\n};\n","import axios, { AxiosResponse, AxiosRequestConfig } from 'axios';\nimport { SampleVariable, SampleClass } from '@/store/modules/sample/types';\nimport { apiUrl } from '@/env';\nimport { HomeArea } from '@/store/modules/home-area/types';\nimport { authHeaders } from './auth_utils';\n\n/* eslint arrow-body-style: \"off\" */\n\nexport default {\n async getSampleVariables(\n surveyId : number,\n token : string,\n ) : Promise>> {\n const config : AxiosRequestConfig = authHeaders(token);\n config.params = new URLSearchParams({\n surveyId: surveyId.toString(),\n });\n return axios.get>(`${apiUrl}/v1/sample/sample-variables`, config);\n // return axios.get>('sample-api-mock-data.json', config);\n },\n async setTargetPopulation(surveyId : number, variables : Array, token : string) {\n const data = {\n surveyId,\n variables: variables.map((variable : SampleVariable) => {\n return {\n id: variable.id,\n classes: variable.classes.map((cls : SampleClass) => {\n return {\n id: cls.id,\n targetPopulation: cls.targetPopulation,\n };\n }),\n };\n }),\n };\n\n return axios.put(`${apiUrl}/v1/sample/set-target-population`, data, authHeaders(token));\n },\n async setWeightOn(surveyId : number, variables : Array, token : string) {\n const data = {\n surveyId,\n variables: variables.map((variable : SampleVariable) => {\n return {\n id: variable.id,\n weightOn: variable.weightOn,\n };\n }),\n };\n\n return axios.put(`${apiUrl}/v1/sample/set-weight-on`, data, authHeaders(token));\n },\n async createVariables(surveyId : number, variables : Array, token : string) {\n const data = {\n surveyId,\n variables,\n };\n return axios.put(`${apiUrl}/v1/sample/create-variables`, data, authHeaders(token));\n },\n async updateVariables(surveyId : number, variables : Array, token : string) {\n const data = {\n surveyId,\n variables,\n };\n return axios.put(`${apiUrl}/v1/sample/update-variables`, data, authHeaders(token));\n },\n async deleteVariables(surveyId : number, variableIds : Array, token : string) {\n const data = {\n surveyId,\n variables: variableIds.map((variableId : number) => {\n return {\n id: variableId,\n };\n }),\n };\n return axios.put(`${apiUrl}/v1/sample/delete-variables`, data, authHeaders(token));\n },\n async getHomeAreas(surveyId : number, token : string) {\n const config : AxiosRequestConfig = authHeaders(token);\n config.params = new URLSearchParams({\n surveyId: surveyId.toString(),\n });\n return axios.get>(`${apiUrl}/v1/sample/home-areas`, config);\n },\n};\n","import axios, { AxiosResponse, CancelToken, AxiosRequestConfig } from 'axios';\nimport { Query, QueryResult, ResultQueryPromise } from '@/store/modules/query/types';\nimport { apiUrl } from '@/env';\nimport { authHeaders } from './auth_utils';\n\nexport default {\n async resultQuery(\n query: Query,\n token: string,\n cancelToken: CancelToken|undefined = undefined,\n ) : ResultQueryPromise {\n const config : AxiosRequestConfig = authHeaders(token);\n config.cancelToken = cancelToken;\n return axios.post(`${apiUrl}/v1/result-query`, query, config);\n },\n};\n","import axios, { AxiosPromise, AxiosResponse, AxiosRequestConfig } from 'axios';\nimport { User } from '@/store/modules/user/types';\nimport { Survey } from '@/store/modules/survey/types';\nimport { Questionnaire } from '@/store/modules/questionnaire/types';\nimport { apiUrl } from '@/env';\nimport modeApi from './mode';\nimport activityApi from './activity';\nimport sampleApi from './sample';\nimport queryApi from './query';\nimport { authHeaders } from './auth_utils';\n\nexport const foo = 'bar';\nexport const api = {\n async login(username: string, password: string) {\n const params = new URLSearchParams({\n username,\n password,\n });\n return axios.post(`${apiUrl}/v1/login`, params);\n },\n async getMe(token: string) {\n return axios.get(`${apiUrl}/v1/users/me`, authHeaders(token));\n },\n async getSurveyList(token: string) : Promise>> {\n return axios.get>(`${apiUrl}/v1/surveys/list`, authHeaders(token));\n },\n async getSurveyDetails(surveyId : number, token: string) : Promise> {\n const config : AxiosRequestConfig = authHeaders(token);\n config.params = { surveyId };\n return axios.get(`${apiUrl}/v1/surveys/details`, config);\n },\n async getQuestionnaires(surveyId : number, token: string) : Promise>> {\n const config : AxiosRequestConfig = authHeaders(token);\n config.params = { surveyId };\n return axios.get>(`${apiUrl}/v1/questionnaires/list/`, config);\n },\n ...modeApi,\n ...activityApi,\n ...sampleApi,\n ...queryApi,\n};\n","import { ActionContext } from 'vuex';\nimport { api } from '@/api';\nimport timeout from '@/utils/timeout';\nimport { RootState } from '../../root-state';\nimport { User, UserStateInterface } from './types';\n\ninterface LoginParams {\n username: string;\n password: string;\n}\n\ntype Context = ActionContext;\n\n/**\n * (current) User state management\n */\nexport default {\n namespaced: true,\n state: {\n user: null,\n token: '',\n isLoggedIn: false,\n },\n mutations: {\n /** Private. Set user data in store */\n setUser(state: UserStateInterface, user: User) {\n state.user = user;\n },\n /** Private. Set token in store */\n setToken(state: UserStateInterface, token: string) {\n state.token = token;\n },\n /** Private. Set isLoggedIn in store */\n setLoggedIn(state: UserStateInterface, loggedIn: boolean) {\n state.isLoggedIn = loggedIn;\n },\n },\n getters: {\n /** Check if user is logged in */\n isLoggedIn: (state: UserStateInterface) : boolean => state.isLoggedIn,\n },\n actions: {\n /** Try to login user using provided username and password. */\n async login(\n context: Context,\n { username, password }: LoginParams,\n ) {\n if (process.env.VUE_APP_NO_SERVER === '1') {\n console.log('Skip server login');\n console.log('Simulate waiting on server');\n await timeout(900);\n context.commit('setLoggedIn', true);\n context.commit('setUser', {\n username,\n });\n return;\n }\n\n try {\n const response = await api.login(username, password);\n const token = response.data.access_token;\n if (token) {\n localStorage.setItem('token', token);\n context.commit('setToken', token);\n // Server should respond with username in getProfile, but a bug in the server\n // causes it to respond with null. (see issue #8 of API server)\n context.commit('setUser', {\n username,\n });\n await context.dispatch('getProfile');\n } else {\n // Log.log('No token');\n context.dispatch('logout');\n }\n } catch (error) {\n // Log.log(error);\n context.dispatch('logout');\n throw error;\n }\n },\n /** Logout user */\n async logout(context: Context) {\n // Log.log('logout');\n await context.dispatch('removeLogin');\n context.commit('setUser', null);\n },\n /** private helper action that remove the login data */\n async removeLogin(context: Context) {\n // Log.log('removeLogin', context);\n context.commit('setToken', '');\n context.commit('setLoggedIn', false);\n localStorage.removeItem('token');\n localStorage.removeItem('selectedSurveyId');\n localStorage.removeItem('filter');\n localStorage.removeItem('querySettings');\n },\n /** Fetches user data and update user state. */\n async getProfile(context: Context) {\n /* eslint no-useless-catch: [\"off\"] */\n try {\n const response = await api.getMe(context.state.token);\n // Log.log(response);\n if (response.data) {\n // Server should respond with username, but a bug in the server\n // causes it to respond with null. (see issue #8 of API server)\n if (response.data.username === null && context.state.user !== null) {\n response.data.username = context.state.user.username;\n }\n context.commit('setUser', response.data);\n }\n } catch (error) {\n throw error;\n }\n },\n async checkLoggedIn(context: Context) {\n // Log.log('checkLoggedIn');\n if (!context.state.isLoggedIn) {\n let { token } = context.state;\n if (!token) {\n const localToken = localStorage.getItem('token');\n if (localToken) {\n context.commit('setToken', localToken);\n token = localToken;\n }\n }\n if (token) {\n try {\n const response = await api.getMe(token);\n context.commit('setLoggedIn', true);\n // Server should respond with username, but a bug in the server\n // causes it to respond with null. (see issue #8 of API server)\n if (response.data.username === null && context.state.user !== null) {\n response.data.username = context.state.user.username;\n }\n context.commit('setUser', response.data);\n } catch (error) {\n await context.dispatch('removeLogin');\n }\n } else {\n await context.dispatch('removeLogin');\n }\n }\n },\n },\n};\n","/**\n * Contains a list of surveys that the user has access to and\n * selection of one of the surveys to use for analysis.\n */\n\n// import store from '.';\nimport { ActionContext } from 'vuex';\nimport { api } from '@/api';\nimport { flavor, flavorData } from '@/flavor';\nimport { Flavor } from '@/flavor/types';\nimport { RootState } from '../../root-state';\nimport { AppFlavor, Survey, SurveyStateInterface } from './types';\n\ninterface LoadDetailsParams {\n surveyId: number;\n}\n\nexport default {\n namespaced: true,\n state: {\n surveyList: [],\n selectedSurvey: -1,\n },\n mutations: {\n clear(state:SurveyStateInterface) {\n state.surveyList = [];\n state.selectedSurvey = -1;\n },\n // Pass id: -1 to unset\n selectSurvey(state:SurveyStateInterface, id:number) {\n const index = state.surveyList.findIndex((s) => s.id === id);\n state.selectedSurvey = index;\n },\n // Private. Use load action\n setSurveyList(state:SurveyStateInterface, surveyList : Array) {\n // TODO: perserve selectedSurvey\n state.surveyList = surveyList;\n state.selectedSurvey = -1;\n },\n },\n actions: {\n load(context:ActionContext) {\n return new Promise(async (resolve, reject) => {\n if (process.env.VUE_APP_NO_SERVER === '1') {\n if (flavor === Flavor.travelViewer) {\n context.commit('setSurveyList', [\n {\n id: 1,\n appFlavor: AppFlavor.travelvu,\n label: 'RVU Sundsvall',\n description: 'Undersökning bland dagbefolkningen i Sundsvalls tätort',\n startDate: '2019-05-01',\n endDate: '2019-05-15',\n participateCountAllTime: 578,\n correctedDayInSurveyCount: 1481,\n },\n {\n id: 2,\n appFlavor: AppFlavor.travelvu,\n label: 'RVU Östersund',\n description: 'Undersökning bland invånare i Östersunds kommun',\n startDate: '2019-05-08',\n endDate: '2019-05-22',\n participateCountAllTime: 323,\n correctedDayInSurveyCount: 702,\n },\n {\n id: 13,\n appFlavor: AppFlavor.travelvu,\n label: 'Donate Data',\n description: 'Donate your data to TravelVu',\n startDate: null,\n endDate: null,\n participateCountAllTime: 2050,\n correctedDayInSurveyCount: 1481,\n },\n ]);\n } else {\n context.commit('setSurveyList', [\n {\n id: 3,\n appFlavor: AppFlavor.activeTravel,\n label: 'Bolaget',\n description: 'Kampanj för Bolaget',\n startDate: '2019-05-01',\n endDate: '2019-05-15',\n participateCountAllTime: 73,\n correctedDayInSurveyCount: 148,\n },\n {\n id: 97,\n appFlavor: AppFlavor.activeTravel,\n label: 'Test ActiveTravel',\n description: 'Use this survey to test ActiveTravel',\n startDate: null,\n endDate: null,\n participateCountAllTime: 250,\n correctedDayInSurveyCount: 181,\n },\n ]);\n }\n } else {\n try {\n const response = await api.getSurveyList(context.rootState.user.token);\n let surveys = response.data;\n\n // Only show ActiveTravel surveys in ActiveViewer, but show surveys from\n // both apps in TravelViewer.\n surveys = surveys.filter(\n (s: Survey) => flavor === Flavor.travelViewer || s.appFlavor === flavorData.appFlavor,\n );\n\n surveys.sort((a: Survey, b : Survey) => {\n if (a.id === b.id) return 0;\n // 1. by start date\n if (a.startDate !== null && b.startDate !== null) {\n if (a.startDate < b.startDate) return 1;\n if (a.startDate > b.startDate) return -1;\n }\n if ((a.startDate === null) !== (b.startDate === null)) {\n if (a.startDate === null) return -1;\n if (b.startDate === null) return 1;\n }\n // 2. by name\n if (a.label < b.label) return -1;\n if (a.label > b.label) return 1;\n return 0;\n });\n context.commit('setSurveyList', surveys);\n } catch (error) {\n const e: any = error;\n if (e.response !== undefined && e.response.status === 401) {\n console.log('401 in response => logout');\n context.dispatch('user/logout', {}, { root: true });\n }\n reject();\n }\n }\n resolve();\n });\n },\n /**\n * loads details for one surevyId\n *\n * Store is updated with details and details is also returned.\n */\n loadDetails(\n context:ActionContext,\n payload : LoadDetailsParams,\n ) {\n return new Promise(async (resolve, reject) => {\n try {\n const response = await api.getSurveyDetails(\n payload.surveyId, context.rootState.user.token,\n );\n const survey = context.state.surveyList.find((s : Survey) => s.id === payload.surveyId);\n if (survey !== undefined) {\n survey.correctedDayInSurveyCount = response.data.correctedDayInSurveyCount;\n survey.participateCountAllTime = response.data.participateCountAllTime;\n }\n resolve( response.data);\n } catch (e) {\n reject();\n }\n });\n },\n clear(context:ActionContext) {\n },\n },\n getters: {\n getAll(state:SurveyStateInterface) : Array {\n return state.surveyList;\n },\n getSelected(state:SurveyStateInterface) : Survey|null {\n return state.surveyList[state.selectedSurvey] !== undefined\n ? state.surveyList[state.selectedSurvey] : null;\n },\n },\n};\n","/* eslint global-require: \"off\" */\n\n/**\n * The purpose of this file is to provide\n * methods for requiring offline files\n * that can be called without disabling\n * eslint global-require in a whole\n * store file.\n */\n\nexport function loadOfflineModes() {\n return require('./modes.json');\n}\nexport function loadOfflineActivities() {\n return require('./activities.json');\n}\nexport function loadOfflineSampleVariables() {\n return require('./sample-variables.json');\n}\n","import { ActionContext } from 'vuex';\nimport resolveLabel from '@/utils/I18nLabel';\nimport { api } from '@/api';\nimport { loadOfflineSampleVariables } from '@/store/offline-data/load';\nimport timeout from '@/utils/timeout';\nimport { SampleClass, SampleVariable, SampleStateInterface } from './types';\nimport { RootState } from '../../root-state';\n\nfunction getVariableExpandedStorageKey(variable : SampleVariable) : string {\n return `sample.variable[${variable.id}].isExpanded`;\n}\n\nexport interface SetTargetPopulationParams {\n variableId: number;\n classId: number;\n targetPopulation: number|null;\n}\n\nexport default {\n namespaced: true,\n state: {\n variables: [],\n loadError: false,\n },\n mutations: {\n clear(state:SampleStateInterface) {\n state.variables = [];\n state.loadError = false;\n },\n // Private. Use load, setWeightOn, setTargetPopulation action\n setVariables(state:SampleStateInterface, rows : Array) {\n state.variables = rows;\n },\n // Private. Use load\n setLoadError(state:SampleStateInterface, loadError : boolean) {\n state.loadError = loadError;\n },\n setIsExpanded(state:SampleStateInterface,\n payload: {variableId : number, isExpanded : boolean}) {\n // ---\n const row = state.variables.find((r : SampleVariable) => r.id === payload.variableId);\n if (row !== undefined) {\n row.isExpanded = payload.isExpanded;\n // Persist in localStorage too\n const storeKey = getVariableExpandedStorageKey(row);\n window.localStorage.setItem(storeKey, JSON.stringify(payload.isExpanded !== false));\n }\n },\n },\n actions: {\n setWeightOn(context:ActionContext,\n payload: {variableId : number, weightOn : boolean}) {\n return new Promise(async (resolve, reject) => {\n // ---\n const variables = [...context.state.variables];\n const row = variables.find((r : SampleVariable) => r.id === payload.variableId);\n if (row !== undefined) {\n const oldValue = row.weightOn;\n row.weightOn = payload.weightOn;\n context.commit('setVariables', variables);\n // When there is no server => assign random weights\n if (process.env.VUE_APP_NO_SERVER === '1') {\n await context.dispatch('randomWeigthedSample');\n }\n // Store to server\n const survey = context.rootGetters['survey/getSelected'];\n if (survey !== null) {\n try {\n await api.setWeightOn(survey.id, variables, context.rootState.user.token);\n } catch (e: any) {\n // Restore to old value - hopefully there are not multiple failing toggle requests.\n row.weightOn = oldValue;\n context.commit('setVariables', variables);\n\n if (e.response !== undefined) {\n reject(e.response.status);\n } else {\n reject();\n }\n return;\n }\n }\n }\n resolve();\n });\n },\n /**\n * Set target population of one or more variable classes.\n * @param context\n * @param payload List of variable+class to set target poplation for\n */\n setTargetPopulation(context:ActionContext,\n payload: SetTargetPopulationParams[]) {\n return new Promise(async (resolve, reject) => {\n // ---\n let rejected = false;\n payload.forEach(async (clsParams : SetTargetPopulationParams) => {\n const variables = [...context.state.variables];\n const row = variables.find((r : SampleVariable) => r.id === clsParams.variableId);\n if (row !== undefined) {\n const cls = row.classes.find((c : SampleClass) => c.id === clsParams.classId);\n if (cls !== undefined) {\n const oldValue = cls.targetPopulation;\n cls.targetPopulation = clsParams.targetPopulation;\n context.commit('setVariables', variables);\n // When there is no server => assign random weights\n if (process.env.VUE_APP_NO_SERVER === '1') {\n await context.dispatch('randomWeigthedSample');\n }\n // Store to server\n const survey = context.rootGetters['survey/getSelected'];\n if (survey !== null) {\n try {\n await api.setTargetPopulation(survey.id, variables, context.rootState.user.token);\n } catch (e: any) {\n // Restore to old value - hopefully there are not multiple failing requests\n cls.targetPopulation = oldValue;\n context.commit('setVariables', variables);\n\n if (e.response !== undefined) {\n reject(e.response.status);\n } else {\n reject();\n }\n rejected = true;\n }\n }\n }\n }\n });\n if (!rejected) {\n resolve();\n }\n });\n },\n addVariable(context:ActionContext,\n payload: SampleVariable) {\n return new Promise(async (resolve, reject) => {\n let rejected = false;\n const oldVariables = [...context.state.variables];\n const variables = [...context.state.variables];\n variables.push(payload);\n context.commit('setVariables', variables);\n const survey = context.rootGetters['survey/getSelected'];\n if (survey !== null) {\n try {\n await api.createVariables(survey.id, [\n payload,\n ], context.rootState.user.token);\n await context.dispatch('load'); // obtain id\n } catch (e: any) {\n if (e.response !== undefined && e.response.status === 401) {\n console.log('401 in response => logout');\n context.dispatch('user/logout', {}, { root: true });\n }\n // Restore to old value - hopefully there are not multiple failing requests\n context.commit('setVariables', oldVariables);\n\n if (e.response !== undefined) {\n reject(e.response.status);\n } else {\n reject();\n }\n rejected = true;\n }\n }\n if (!rejected) {\n resolve();\n }\n });\n },\n updateVariable(context:ActionContext,\n payload: SampleVariable) {\n return new Promise(async (resolve, reject) => {\n let rejected = false;\n const oldVariables = [...context.state.variables];\n const variables = [...context.state.variables];\n const rowIndex = variables.findIndex((r : SampleVariable) => r.id === payload.id);\n if (rowIndex === -1) {\n reject();\n return;\n }\n variables[rowIndex] = payload;\n context.commit('setVariables', variables);\n const survey = context.rootGetters['survey/getSelected'];\n if (survey !== null) {\n try {\n await api.updateVariables(survey.id, [\n payload,\n ], context.rootState.user.token);\n await context.dispatch('load'); // obtain ids in case classes was added\n } catch (e: any) {\n if (e.response !== undefined && e.response.status === 401) {\n console.log('401 in response => logout');\n context.dispatch('user/logout', {}, { root: true });\n }\n // Restore to old value - hopefully there are not multiple failing requests\n context.commit('setVariables', oldVariables);\n\n if (e.response !== undefined) {\n reject(e.response.status);\n } else {\n reject();\n }\n rejected = true;\n }\n }\n if (!rejected) {\n resolve();\n }\n });\n },\n deleteVariable(context:ActionContext,\n variableId: number) {\n return new Promise(async (resolve, reject) => {\n let rejected = false;\n const oldVariables = [...context.state.variables];\n const variables = [...context.state.variables];\n const rowIndex = variables.findIndex((r : SampleVariable) => r.id === variableId);\n if (rowIndex === -1) {\n reject();\n return;\n }\n variables.splice(rowIndex, 1);\n context.commit('setVariables', variables);\n const survey = context.rootGetters['survey/getSelected'];\n if (survey !== null) {\n try {\n await api.deleteVariables(survey.id, [\n variableId,\n ], context.rootState.user.token);\n } catch (e: any) {\n if (e.response !== undefined && e.response.status === 401) {\n console.log('401 in response => logout');\n context.dispatch('user/logout', {}, { root: true });\n }\n // Restore to old value - hopefully there are not multiple failing requests\n context.commit('setVariables', oldVariables);\n\n if (e.response !== undefined) {\n reject(e.response.status);\n } else {\n reject();\n }\n rejected = true;\n }\n }\n if (!rejected) {\n resolve();\n }\n });\n },\n /* eslint-disable */\n load(context:ActionContext) {\n return new Promise(async (resolve, reject) => {\n // Don't clear before load because Weighting view will\n // perform load to update the weighted sample column.\n\n // but if we did load with an error but there is no data,\n // reset loadError => show spinner when trying again to load.\n if (context.state.variables.length === 0) {\n context.commit('setLoadError', false);\n }\n\n let variables : Array = [];\n\n if (process.env.VUE_APP_NO_SERVER === '1') {\n console.log('Simulate waiting on server');\n await timeout(1000);\n variables = loadOfflineSampleVariables();\n } else {\n const survey = context.rootGetters['survey/getSelected'];\n if (survey !== null) {\n try {\n const response = await api.getSampleVariables(\n survey.id, context.rootState.user.token,\n );\n const s2 = context.rootGetters['survey/getSelected'];\n if (s2 === null || s2.id !== survey.id) {\n console.log('User changed survey while loading sample data => abort')\n reject();\n return;\n }\n variables = response.data;\n } catch (e: any) {\n if (e.response !== undefined && e.response.status === 401) {\n console.log('401 in response => logout');\n context.dispatch('user/logout', {}, { root: true });\n }\n context.commit('setLoadError', true);\n reject();\n return;\n }\n } else {\n console.error('sampleVariable/load: survey/getSelected is null');\n context.commit('setLoadError', true);\n reject();\n return;\n }\n }\n\n // Resolve label strings\n for (let i = 0; i < variables.length; i += 1) {\n variables[i].label = resolveLabel(variables[i].label, variables[i].labelTranslations);\n for (let c = 0; c < variables[i].classes.length; c += 1) {\n variables[i].classes[c].label = resolveLabel(\n variables[i].classes[c].label, variables[i].classes[c].labelTranslations,\n );\n }\n }\n\n // Get expanded from localStorage\n for (let i = 0; i < variables.length; i += 1) {\n const storeKey = getVariableExpandedStorageKey(variables[i]);\n const storedValue = window.localStorage.getItem(storeKey);\n if (storedValue === null) {\n variables[i].isExpanded = true;\n window.localStorage.setItem(storeKey, JSON.stringify(true));\n } else {\n // bias towards expanded in case of type error\n variables[i].isExpanded = JSON.parse(storedValue) !== false;\n }\n }\n\n context.commit('setVariables', variables);\n if (process.env.VUE_APP_NO_SERVER === '1') {\n await context.dispatch('randomWeigthedSample');\n }\n resolve();\n });\n },\n // When there is no server, this method can be used to assign\n // some random weightedSample values.\n randomWeigthedSample(context:ActionContext) {\n const variables = [...context.state.variables];\n let allOk = true;\n for (let i = 0; i < variables.length; i += 1) {\n allOk = allOk && (!variables[i].weightOn\n || context.getters.isTargetPopulationSum1(variables[i].id));\n }\n for (let i = 0; i < variables.length; i += 1) {\n const variable = variables[i];\n const assignWeight = variable.weightOn && allOk;\n for (let c = 0; c < variable.classes.length; c += 1) {\n const cls = variable.classes[c];\n cls.weightedSample = assignWeight ? Math.random() : null;\n }\n }\n\n context.commit('setVariables', variables);\n },\n },\n getters: {\n /**\n * Checks if targetPopulation sums to 100% for given variable.\n * @param variableId Id of variable to check */\n isTargetPopulationSum1: (state:SampleStateInterface) => (variableId : number) : boolean => {\n const variable = state.variables.find((r : SampleVariable) => r.id === variableId);\n if (variable === undefined) {\n return false; // variable not found\n }\n\n let sum = 0;\n for (let i = 0; i < variable.classes.length; i += 1) {\n const c = variable.classes[i];\n if (c.targetPopulation !== null) {\n sum += c.targetPopulation;\n }\n }\n\n const sum1 = Math.abs(1.0 - sum) < 0.001;\n if (!sum1 && variable.isShare && variable.weightOn) {\n console.log(\n `total poplation sum for variable ${resolveLabel(variable.label, variable.labelTranslations)} is not 1. It is ${sum}`\n );\n }\n return sum1;\n },\n /**\n * Checks if variables have been loaded.\n *\n * It makes an assumption that any loaded state have at\n * least one variable. This is safe as there is one variable\n * that count number of participants and should exist for\n * all surveys.\n */\n isLoaded: (state:SampleStateInterface) => state.variables.length > 0,\n isLoadError: (state:SampleStateInterface) => state.loadError,\n },\n};\n","import { ActionContext } from 'vuex';\nimport { loadOfflineModes, loadOfflineActivities } from '@/store/offline-data/load';\nimport { api } from '@/api';\nimport palette from '@/utils/palette';\nimport i18n from '@/i18n';\nimport {\n getMainAggregateActivities,\n getMainAggregateModes,\n getNoAggregateActivities,\n getNoAggregateModes,\n} from '@/utils/maAggregate';\nimport {\n Mode, Activity, AggregatedMode, AggregatedActivity, ModeActivityStateInterface, AggregatedModeConfig,\n} from './types';\nimport { RootState } from '../../root-state';\n\ntype Context = ActionContext;\n\nfunction flatLabelsToMap(maData : any) : any {\n const labelTranslations : any = {};\n\n Object.keys(maData).forEach((key) => {\n if (key.startsWith('label')) {\n const langKey : string = key.substring(5).toLowerCase();\n labelTranslations[langKey] = maData[key];\n }\n });\n\n return labelTranslations;\n}\n\nconst getters = {\n /**\n * Get mode by id\n * @param id Mode id\n * @return Mode or null if mode was not found\n */\n getMode: (state:ModeActivityStateInterface) => (id : string) : Mode|null => {\n const mode = state.modes.find((m : Mode) => m.id === id);\n if (mode === undefined) return null;\n return mode;\n },\n /**\n * Get activity by id\n * @param id Activity id\n * @return Activity or null if activity was not found\n */\n getActivity: (state:ModeActivityStateInterface) => (id : string) : Activity|null => {\n const activity = state.activities.find((a : Activity) => a.id === id);\n if (activity === undefined) return null;\n return activity;\n },\n\n /**\n * Get a map from mode id to color string using colors\n * from current aggregated modes.\n * @param\n * @returns object mapping from string to string\n */\n getModeColorMap: (state:ModeActivityStateInterface) : any => {\n const r: any = {};\n state.aggregatedModes.forEach((am: AggregatedMode) => {\n am.modeList.forEach((modeId) => {\n r[modeId] = {\n bgColor: am.bgColor,\n textColor: am.textColor,\n borderColor: am.borderColor,\n };\n });\n });\n return r;\n },\n\n /**\n * Get modes in current survey\n */\n /* eslint implicit-arrow-linebreak: [\"off\", {}}] */\n getSurveyModes: (state:ModeActivityStateInterface) => () : Array =>\n state.modes.filter((mode : Mode) => mode.inSurvey),\n\n /**\n * Get activities in current survey\n */\n /* eslint implicit-arrow-linebreak: [\"off\", {}}] */\n getSurveyActivities: (state:ModeActivityStateInterface) => () : Array =>\n state.activities.filter((activity : Activity) => activity.inSurvey),\n\n /**\n * Get aggregated modes exculding Exercice\n * @return array of aggregated modes\n */\n getAggregatedModesExcludingExercice: (state:ModeActivityStateInterface) : AggregatedModeConfig =>\n state.aggregatedModes.filter(\n (m) => m.modeList.length !== 1 || m.modeList[0] !== 'EXRC',\n ),\n\n aggregatedState: (state:ModeActivityStateInterface) => {\n let s = state.aggregatedModes.map((am) => {\n let amStr = `id:${am.id};`;\n amStr += `l:${JSON.stringify(am.labelTranslations)};`;\n amStr += `c:${am.bgColor},${am.textColor},${am.borderColor};`;\n amStr += `c:${am.order};`;\n amStr += `m:${am.modeList.join(',')};`;\n return amStr;\n }).join(',');\n s += state.aggregatedActivities.map((aa) => {\n let aaStr = `id:${aa.id};`;\n aaStr += `l:${JSON.stringify(aa.labelTranslations)};`;\n aaStr += `c:${aa.order};`;\n aaStr += `m:${aa.activityList.join(',')};`;\n return aaStr;\n }).join(',');\n return s;\n },\n};\n\n/**\n * (current) User state management\n */\nexport default {\n namespaced: true,\n state: {\n modes: [],\n activities: [],\n aggregatedModes: [],\n aggregatedActivities: [],\n },\n mutations: {\n clear(state:ModeActivityStateInterface) {\n state.modes = [];\n state.activities = [];\n state.aggregatedModes = [];\n state.aggregatedActivities = [];\n },\n /** Private. Set mode data in store */\n setModes(state: ModeActivityStateInterface, modes: Array) {\n state.modes = modes;\n },\n /** Private. Set activities data in store */\n setActivities(state: ModeActivityStateInterface, activities: Array) {\n state.activities = activities;\n },\n /** Set aggregated mode data in store */\n setAggregatedModes(state: ModeActivityStateInterface, am: Array) {\n state.aggregatedModes = am;\n },\n /** Set aggregated activity data in store */\n setAggregatedActivities(state: ModeActivityStateInterface, aa: Array) {\n state.aggregatedActivities = aa;\n },\n\n /** Creates a aggregate setup that just 1:1 mirrors available modes */\n noAggregateModes(state: ModeActivityStateInterface) {\n state.aggregatedModes = getNoAggregateModes(state.modes);\n },\n /** Creates a aggregate setup that just 1:1 mirrors available activities */\n noAggregateActivities(state: ModeActivityStateInterface) {\n state.aggregatedActivities = getNoAggregateActivities(state.activities);\n },\n /** A aggregate with a few main modes */\n mainAggregateModes(state: ModeActivityStateInterface) {\n state.aggregatedModes = getMainAggregateModes(state.modes);\n },\n /** A aggregate with a few main activities */\n mainAggregateActivities(state: ModeActivityStateInterface) {\n state.aggregatedActivities = getMainAggregateActivities(state.activities);\n },\n },\n actions: {\n /**\n * Load mode and activity data. Depends on current survey\n *\n * Rejects upon server error or no current selected survey.\n */\n load(context:Context) {\n return new Promise(async (resolve, reject) => {\n // Get modes + activities from remote/offline\n let remoteModes = [];\n let remoteActivities = [];\n let remoteSurveyModes : Array = [];\n let remoteSurveyActivities : Array = [];\n if (process.env.VUE_APP_NO_SERVER === '1') {\n remoteModes = loadOfflineModes();\n remoteActivities = loadOfflineActivities();\n remoteSurveyModes = remoteModes;\n remoteSurveyActivities = remoteActivities;\n } else {\n const survey = context.rootGetters['survey/getSelected'];\n if (survey === null) {\n reject(); // no survey\n return;\n }\n try {\n const sm = api.getModes(survey.id, context.rootState.user.token);\n const sa = api.getActivities(survey.id, context.rootState.user.token);\n const m = api.getModes(null, context.rootState.user.token);\n const a = api.getActivities(null, context.rootState.user.token);\n await Promise.all([\n sm,\n sa,\n m,\n a,\n ]).then(([sm, sa, m, a]) => {\n remoteSurveyModes = sm.data;\n remoteSurveyActivities = sa.data;\n remoteModes = m.data;\n remoteActivities = a.data;\n });\n } catch (e) {\n reject();\n return;\n }\n }\n\n // Transform data to local Mode/Activity def\n const modes = remoteModes.map((m : any) : Mode => {\n const mode = {\n id: m.id,\n order: m.order,\n labelTranslations: flatLabelsToMap(m),\n bgColor: m.bgColor,\n textColor: m.textColor,\n borderColor: m.borderColor,\n svgIconBgColor: '',\n svgIconBlack: '',\n inSurvey: remoteSurveyModes.find((value : any) => value.id === m.id) !== undefined,\n };\n return mode;\n }).filter((m : Mode) => ['NSET', 'NMOV'].indexOf(m.id) === -1);\n context.commit('setModes', modes);\n\n const activities = remoteActivities.map((a : any) : Activity => {\n const activity = {\n id: a.id,\n order: a.order,\n labelTranslations: flatLabelsToMap(a),\n svgIconBgColor: '',\n svgIconBlack: '',\n inSurvey: remoteSurveyActivities.find((value : any) => value.id === a.id) !== undefined,\n };\n return activity;\n }).filter((a : Activity) => ['NSET', 'NACT'].indexOf(a.id) === -1);\n context.commit('setActivities', activities);\n\n // Create aggeragate data that does not actually aggregate\n context.commit('noAggregateModes');\n context.commit('noAggregateActivities');\n\n resolve();\n });\n },\n },\n getters: {\n ...getters,\n },\n};\n","import { ActionContext } from 'vuex';\nimport { api } from '@/api';\nimport { RootState } from '../../root-state';\nimport {\n Question, AnswerOption,\n Questionnaire, QuestionnaireStateInterface,\n} from './types';\n\ntype Context = ActionContext;\n\n/**\n * For fetching questionnaires from server\n *\n * @note The data model here is an aggregated one where language-variants\n * are merged into one question/answerOption via keys.\n */\nexport default {\n namespaced: true,\n state: {\n questionnaires: [],\n loaded: false,\n },\n mutations: {\n setQuestionnaires(state : QuestionnaireStateInterface, questionnaires : Array) {\n state.questionnaires = questionnaires;\n state.loaded = true;\n },\n /**\n * Remove all questionnaires.\n */\n clear(state : QuestionnaireStateInterface, params : void) {\n state.questionnaires = [];\n state.loaded = false;\n },\n },\n actions: {\n load(context:ActionContext) {\n return new Promise(async (resolve, reject) => {\n context.commit('clear');\n\n const survey = context.rootGetters['survey/getSelected'];\n if (survey !== null) {\n try {\n const response = await api.getQuestionnaires(survey.id, context.rootState.user.token);\n const s2 = context.rootGetters['survey/getSelected'];\n if (s2 === null || s2.id !== survey.id) {\n reject();\n return;\n }\n\n // Loaded\n context.commit('setQuestionnaires', response.data);\n resolve();\n } catch (e) {\n console.log('Failed to load questionnaires');\n reject();\n }\n } else {\n console.log('Cannot load questionnaires when no survey is selected');\n reject();\n }\n });\n },\n },\n getters: {\n },\n};\n","import { ActionContext } from 'vuex';\nimport { api } from '@/api';\nimport { RootState } from '../../root-state';\nimport { HomeArea, HomeAreaStateInterface } from './types';\n\ntype Context = ActionContext;\n\n/**\n * Home areas\n */\nexport default {\n namespaced: true,\n state: {\n homeAreas: [],\n loaded: false,\n },\n mutations: {\n setHomeAreas(state : HomeAreaStateInterface, homeAreas : Array) {\n state.homeAreas = homeAreas;\n state.loaded = true;\n },\n /**\n * Removes all home areas.\n */\n clear(state : HomeAreaStateInterface, params : void) {\n state.homeAreas = [];\n state.loaded = false;\n },\n },\n actions: {\n load(context:ActionContext) {\n return new Promise(async (resolve, reject) => {\n context.commit('clear');\n\n const survey = context.rootGetters['survey/getSelected'];\n if (survey !== null) {\n try {\n const response = await api.getHomeAreas(survey.id, context.rootState.user.token);\n const s2 = context.rootGetters['survey/getSelected'];\n if (s2 === null || s2.id !== survey.id) {\n reject();\n return;\n }\n\n // Loaded\n context.commit('setHomeAreas', response.data);\n resolve();\n } catch (e) {\n console.log('Failed to load home areas');\n reject();\n }\n } else {\n console.log('Cannot load home areas when no survey is selected');\n reject();\n }\n });\n },\n },\n getters: {\n },\n};\n","import { ActionContext } from 'vuex';\nimport { stringGetDayAfter } from '@/utils/dateHelpers';\nimport Log from '@/utils/log';\nimport { RootState } from '../../root-state';\nimport { FilterStateInterface } from './types';\nimport { AggregatedMode, AggregatedActivity } from '../mode-activity/types';\nimport { SampleVariable, SampleClass } from '../sample/types';\nimport { Survey } from '../survey/types';\n\nexport interface EnableAllParams {\n aggregatedModes: Array;\n aggregatedActivities: Array;\n sampleVariables : Array;\n surveyStartDate: string;\n surveyEndDate: string;\n}\n\nexport interface SetByIdParams {\n id: number;\n enabled: boolean;\n}\n\nexport interface SetSampleClassParams {\n variableId: number;\n classId: number;\n enabled: boolean;\n}\n\ntype Context = ActionContext;\n\nconst enabledClassesStateGetter = (state:FilterStateInterface) => {\n let s = '';\n Object.keys(state.sampleClassIds).forEach((k : string) => {\n const svId = parseInt(k, 10);\n s += `v${svId}:`;\n state.sampleClassIds[svId].forEach((cId : number) => {\n s += `${cId},`;\n });\n });\n return s;\n};\n\nfunction persist(state: FilterStateInterface) {\n localStorage.setItem('filter', JSON.stringify(state));\n}\n\n/* eslint no-underscore-dangle: [\"off\", {}}] */\n/* eslint prefer-template: [\"off\", {}}] */\n\n/**\n * (current) User state management\n */\nexport default {\n namespaced: true,\n state: {\n aggregatedModes: [],\n aggregatedActivities: [],\n sampleClassIds: {},\n startDate: '1990-01-01', // YYYY-MM-DD start date\n endDate: '1990-01-01', // YYYY-MM-DD end date\n startTime: 0, // seconds since 00:00. [0, 24*3600]\n endTime: 0, // seconds since 00:00. [0, 24*3600]\n dayOfWeek: [false, false, false, false, false, false, false],\n minDistanceM: null,\n maxDistanceM: null,\n minDurationS: null,\n maxDurationS: null,\n isCommuteToWork: null,\n _enabledClassesStr: '',\n },\n mutations: {\n /**\n * Unsafe setter (no typechecking or data validation)\n * @param filter Object with same names as state as keys.\n */\n setFilter(state: FilterStateInterface, filter: any) {\n Object.keys(state).forEach((key : string) => {\n if (filter[key] !== undefined\n && (state)[key] !== undefined\n && !key.startsWith('_')\n ) {\n const oldValue = (state)[key];\n (state)[key] = (filter)[key];\n\n if (key === 'aggregatedModes') {\n state.aggregatedModes.sort();\n } else if (key === 'aggregatedActivities') {\n state.aggregatedActivities.sort();\n } else if (key === 'sampleClassIds') {\n Object.keys(state.sampleClassIds).forEach((k : string) => {\n const svId = parseInt(k, 10);\n state.sampleClassIds[svId].sort();\n });\n // For variables that exist only in the old filter state, but\n // not in the new sampleClassIds assignment, retain the old\n // filter state. Purpose: so restore can default to enabled\n Object.keys(oldValue).forEach((k : string) => {\n const oldSvId = parseInt(k, 10);\n if (state.sampleClassIds[oldSvId] === undefined) {\n Log.log(`setFilter restore old sv class state for ${oldSvId}`);\n state.sampleClassIds[oldSvId] = oldValue[oldSvId];\n }\n });\n state._enabledClassesStr = enabledClassesStateGetter(state);\n }\n }\n });\n persist(state);\n },\n /**\n * Enable/disable one aggregated mode specified by id.\n * @param state\n * @param params\n */\n setAggregatedMode(state: FilterStateInterface, params: SetByIdParams) {\n if (params.enabled) {\n if (state.aggregatedModes.find((mId) => mId === params.id) !== undefined) {\n return;\n }\n state.aggregatedModes.push(params.id);\n // Sort is important to not create multiple filter/query states with different mode order\n state.aggregatedModes.sort();\n } else {\n const index = state.aggregatedModes.findIndex((mId) => mId === params.id);\n if (index !== -1) {\n state.aggregatedModes.splice(index, 1);\n }\n }\n persist(state);\n },\n /**\n * Enable/disable one aggregated activity specified by id.\n * @param state\n * @param params\n */\n setAggregatedActivity(state: FilterStateInterface, params: SetByIdParams) {\n if (params.enabled) {\n if (state.aggregatedActivities.find((aId) => aId === params.id) !== undefined) {\n return;\n }\n state.aggregatedActivities.push(params.id);\n state.aggregatedActivities.sort();\n } else {\n const index = state.aggregatedActivities.findIndex((aId) => aId === params.id);\n if (index !== -1) {\n state.aggregatedActivities.splice(index, 1);\n }\n }\n persist(state);\n },\n /**\n * Enable/disable one sample class specified by class and variable id\n * @param state\n * @param params\n */\n setAnswerOptionKeyId(state: FilterStateInterface, params: SetSampleClassParams) {\n if (params.enabled) {\n if (state.sampleClassIds[params.variableId] === undefined) {\n state.sampleClassIds[params.variableId] = {};\n }\n\n if (state.sampleClassIds[params.variableId].find(\n (classId : number) => classId === params.classId,\n ) === undefined) {\n // add class if it is missing\n state.sampleClassIds[params.variableId].push(params.classId);\n state.sampleClassIds[params.variableId].sort();\n }\n } else {\n if (state.sampleClassIds[params.variableId] === undefined) {\n return; // variable is complely missing - should maybe not happen\n }\n const index = state.sampleClassIds[params.variableId].findIndex(\n (classId : number) => classId === params.classId,\n );\n if (index !== -1) {\n state.sampleClassIds[params.variableId].splice(index, 1);\n state.sampleClassIds[params.variableId].sort();\n }\n // Don't remove the variable if all classes have been removed.\n // An omitted variable causes statistics engine to not filter\n // on the variable at all.\n }\n\n // Update _enabledClassesStr as filter state in object doesn't trigger\n // Vue change detection\n state._enabledClassesStr = enabledClassesStateGetter(state);\n\n persist(state);\n },\n /**\n * Enable all filters\n * @param state\n * @param params Lists of all modes, activities etc.\n */\n enableAll(state: FilterStateInterface, params : EnableAllParams) {\n state.aggregatedModes = params.aggregatedModes.map((m) => m.id).sort();\n state.aggregatedActivities = params.aggregatedActivities.map((a) => a.id).sort();\n\n state.sampleClassIds = {};\n params.sampleVariables.forEach((sv : SampleVariable) => {\n if (!sv.isShare || sv.id === null) {\n return;\n }\n\n const svClasses : Array = [];\n sv.classes.forEach((c : SampleClass) => {\n svClasses.push(c.id);\n });\n svClasses.push(null);\n svClasses.sort();\n state.sampleClassIds[sv.id] = svClasses;\n });\n state._enabledClassesStr = enabledClassesStateGetter(state);\n\n state.startDate = params.surveyStartDate;\n state.endDate = params.surveyEndDate;\n state.startTime = 0;\n state.endTime = 24 * 3600 - 1;\n state.dayOfWeek = [true, true, true, true, true, true, true];\n state.minDistanceM = null;\n state.maxDistanceM = null;\n state.minDurationS = null;\n state.maxDurationS = null;\n state.isCommuteToWork = null;\n\n persist(state);\n },\n /**\n * Disable all filters that depends on external data (modes etc.)\n * - all array filters is set to []\n * - sets time filter to [0, 23:59:59]\n * - sets date filter to no date range\n * - sets min/max distance/duration to null\n * @param state\n * @param params\n */\n clear(state: FilterStateInterface) {\n state.aggregatedModes = [];\n state.aggregatedActivities = [];\n state.sampleClassIds = [];\n state.startDate = null;\n state.endDate = null;\n state.startTime = 0;\n state.endTime = 24 * 3600 - 1;\n state.dayOfWeek = [true, true, true, true, true, true, true];\n state.minDistanceM = null;\n state.maxDistanceM = null;\n state.minDurationS = null;\n state.maxDurationS = null;\n state.isCommuteToWork = null;\n },\n },\n actions: {\n restore(context:ActionContext) {\n const filterString = localStorage.getItem('filter');\n const selectedSurvey : Survey|null = context.rootGetters['survey/getSelected'];\n context.commit('enableAll', {\n aggregatedModes: context.rootGetters['modeActivity/getAggregatedModesExcludingExercice'],\n aggregatedActivities: context.rootState.modeActivity.aggregatedActivities,\n sampleVariables: context.rootState.sample.variables,\n surveyStartDate: selectedSurvey?.startDate,\n surveyEndDate: selectedSurvey?.endDate,\n } as EnableAllParams); // default for filters not in store\n if (filterString !== null) {\n const filter = JSON.parse(filterString);\n if (filter !== null) {\n context.commit('setFilter', filter);\n }\n }\n },\n },\n getters: {\n // allow having the reducer on multiple lines for\n // better readability what they do\n /* eslint implicit-arrow-linebreak: [\"off\", {}}] */\n /* eslint function-paren-newline: [\"off\", {}}] */\n\n /**\n * Provides a unique string that represent the current filter\n * state. It can be used to react to changes to the filter\n * state but is not ment to be used for data transfer and\n * being decoded later on.\n */\n filterState: (state:FilterStateInterface) => {\n let s = '';\n\n s += 'am:';\n s += state.aggregatedModes.map((am : number) => am.toString())\n .reduce((reducer, val, index) =>\n `${reducer}${val},`, '',\n );\n s += 'aa:';\n s += state.aggregatedActivities.map((aa : number) => aa.toString())\n .reduce((reducer, val, index) =>\n `${reducer}${val},`, '',\n );\n\n s += 'ao:' + state._enabledClassesStr;\n\n s += `fd:${state.startDate}`;\n s += `ed:${state.endDate}`;\n s += `ft:${state.startTime}`;\n s += `et:${state.endTime}`;\n s += 'dow:';\n s += state.dayOfWeek.map((dow : boolean) => dow.toString())\n .reduce((reducer, val, index) =>\n `${reducer}${val},`, '',\n );\n\n s += `di:${state.minDistanceM}-${state.maxDistanceM}`;\n s += `du:${state.minDurationS}-${state.maxDurationS}`;\n\n return s;\n },\n /** Internal getter to compute _enabledAOsStr */\n _enabledClassesStateStr: enabledClassesStateGetter,\n /**\n * Check if given answer option is enabled in the filter\n * @param variableId SampleVariable id\n * @param classId SampleClass id or null for the psuedo answer 'missing answer'.\n */\n isSampleClassEnabled: (state:FilterStateInterface) => (\n variableId : number, classId : number|null,\n ) => {\n if (state.sampleClassIds[variableId] === undefined) return false;\n return state.sampleClassIds[variableId].indexOf(classId) !== -1;\n },\n },\n};\n","import { ActionContext } from 'vuex';\nimport resolveLabel from '@/utils/I18nLabel';\nimport { date2YMDString } from '@/utils/dateHelpers';\nimport i18n from '@/i18n';\nimport hasFeature from '@/utils/feature';\nimport palette from '@/utils/palette';\nimport { Flavor } from '@/flavor/types';\nimport { flavor, flavorData } from '@/flavor';\nimport Log from '@/utils/log';\nimport { getActiveTransportAggregatedModes, getEmissionAggregatedModes } from '@/utils/maAggregate';\nimport { RootState } from '../../root-state';\nimport {\n ResultBox, ResultBoardStateInterface, ResultBoard, ResultVisual, ResultFormatter, FilterOverride, ResultUnit,\n} from './types';\nimport {\n Numerator, Denominator, StatMethod, TravelType, Attachment, PartialQuery, Query, Axis,\n} from '../query/types';\nimport { SampleVariable, SampleClass } from '../sample/types';\nimport { AggregatedMode } from '../mode-activity/types';\n\ntype Context = ActionContext;\n\nconst noFilterOverride : FilterOverride = {\n aggregatedModes: undefined,\n};\n\nexport interface ResultBoardLoadParams {\n sampleVariables : Array;\n surveyStartDate: string|null;\n surveyEndDate: string|null;\n aggregatedModes: Array;\n}\n\nexport interface SetVisualParams {\n resultBoardId : string;\n boxId : number;\n type: ResultVisual;\n}\n\nexport interface SetZoneFileParams {\n resultBoardId : string;\n boxId : number;\n zoneFile: Attachment|null; // null => remove file\n}\n\nexport interface SetStartEndDateParams {\n startDate : string|null;\n endDate : string|null;\n}\n\n/**\n * Lookup box or return undefined if not found\n */\nfunction findBox(state : ResultBoardStateInterface, resultBoardId: String, boxId: number): ResultBox|undefined {\n const resultBoard = state.resultBoards.find((board) => board.id === resultBoardId);\n if (resultBoard !== undefined) {\n return resultBoard.resultBoxes.find((b) => b.id === boxId);\n }\n return undefined;\n}\n\nfunction attachmentState(file : Attachment|null): string {\n if (file === null) {\n return 'null';\n }\n // Naively use filename and content length as state signature\n return `${file.fileName}:${file.content.length}`;\n}\n\n/**\n * Resolve dates() axis string with given parameters.\n *\n * If either startDate or endDate is null, a days axis for the last 30 days\n * is returned.\n *\n * @param startDate Date string on YYYY-MM-DD format or null\n * @param endDate Date string on YYYY-MM-DD format or null\n * @returns string\n */\nfunction resolveDatesAxis(startDate : string|null, endDate : string|null): string {\n if (startDate == null || endDate == null) {\n const today = new Date();\n const prior = new Date();\n prior.setDate(today.getDate() - 30);\n const end = date2YMDString(today);\n const start = date2YMDString(prior);\n return `dates(${start},${end})`;\n }\n return `dates(${startDate},${endDate})`;\n}\n\n/**\n * Resolve weeks() axis string with given parameters.\n *\n * If either startDate or endDate is null, a weeks axis for the last 30 days\n * is returned.\n *\n * @param startDate Date string on YYYY-MM-DD format or null\n * @param endDate Date string on YYYY-MM-DD format or null\n * @returns string\n */\nfunction resolveWeeksAxis(startDate : string|null, endDate : string|null): string {\n if (startDate == null || endDate == null) {\n const today = new Date();\n const prior = new Date();\n prior.setDate(today.getDate() - 30);\n const end = date2YMDString(today);\n const start = date2YMDString(prior);\n return `weeks(${start},${end})`;\n }\n return `weeks(${startDate},${endDate})`;\n}\n\n/**\n * Build a ResultBox of type ResultVisual.sectionHeading.\n * @param id The id to use\n * @param label The label (translated text)\n * @returns ResultBox\n */\nfunction buildSectionHeadingBox(id: number, label: string) : ResultBox {\n return {\n id,\n type: ResultVisual.sectionHeading,\n label,\n partialQuery: null,\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: null,\n valueDecimals: 0,\n valueUnit: null,\n customPalette: null,\n colspan: 12,\n };\n}\n\n/**\n * (current) User state management\n */\nexport default {\n namespaced: true,\n state: {\n resultBoards: [],\n },\n mutations: {\n /**\n * Store a query as sent\n * @param state\n * @param query\n */\n addBoard(state : ResultBoardStateInterface, resultBoard : ResultBoard) {\n state.resultBoards.push(resultBoard);\n },\n clear(state : ResultBoardStateInterface) {\n state.resultBoards = [];\n },\n /**\n * Set visual type of Result Box\n * @param state\n * @param payload\n */\n setBoxVisual(state : ResultBoardStateInterface, payload : SetVisualParams) {\n const box = findBox(state, payload.resultBoardId, payload.boxId);\n if (box !== undefined) {\n box.type = payload.type;\n }\n },\n /**\n * Set partialQuery.zoneFile of Result Box\n * @param state\n * @param payload\n */\n setBoxZoneFile(state : ResultBoardStateInterface, payload : SetZoneFileParams) {\n const box = findBox(state, payload.resultBoardId, payload.boxId);\n Log.log('setBoxZoneFile');\n if (box !== undefined && box.partialQuery !== null) {\n box.partialQuery.zoneFile = payload.zoneFile;\n }\n },\n /* eslint no-param-reassign: [\"error\", { \"props\": false }] */\n /**\n * Set Start and end date of all result boxes of axis dates() and weeks().\n *\n * If either the start or end date is null, then today's date is used as end date and the\n * day 30 day prior used as start date\n * @param state\n * @param payload\n */\n setStartEndDate(state : ResultBoardStateInterface, payload : SetStartEndDateParams) {\n state.resultBoards.forEach((resultBoard) => {\n resultBoard.resultBoxes.forEach((box) => {\n if (box.partialQuery !== null) {\n if (box.partialQuery.axisX.startsWith('dates(')) {\n box.partialQuery.axisX = resolveDatesAxis(payload.startDate, payload.endDate);\n }\n if (box.partialQuery.axisX.startsWith('weeks(')) {\n box.partialQuery.axisX = resolveWeeksAxis(payload.startDate, payload.endDate);\n }\n }\n });\n });\n },\n },\n actions: {\n load(context : Context, payload: ResultBoardLoadParams) {\n return new Promise(async (resolve, reject) => {\n context.commit('clear');\n let nextId = 0;\n const getNextId = () => {\n const id = nextId;\n nextId += 1;\n return id;\n };\n\n const modalSplitNTrips: ResultBox = {\n id: getNextId(),\n type: ResultVisual.pieChart,\n label: i18n.t('resultbox.modal-split-n-trips').toString(),\n partialQuery: {\n axisX: '\"aggregated mode\"',\n axisY: '',\n numerator: Numerator.nDelresa,\n denominator: Denominator.anyDayDivN,\n scaleFactor: null,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.delresa,\n enableWeighting: true,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: null,\n valueDecimals: 1,\n valueUnit: null,\n customPalette: null,\n colspan: 6,\n };\n\n // Compensate for that people working full time are working 5 out of 7 days.\n const workFullTimeFactor = 7 / 5;\n\n if (flavor === Flavor.travelViewer) {\n // Build result boards for travelViewer\n const overviewBoard : ResultBoard = {\n id: 'overview',\n labelStr: 'resultboard.overview',\n info: null,\n resultBoxes: [\n // modalSplitNTrips, // commented out to avoid slow graph on overview during development\n // N Trips per person and day\n {\n id: getNextId(),\n type: ResultVisual.factText,\n label: i18n.t('resultbox.n-trips-per-person-day').toString(),\n partialQuery: {\n axisX: '',\n axisY: '',\n numerator: Numerator.nDelresa,\n denominator: Denominator.anyDayDivN,\n scaleFactor: null,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.delresa,\n enableWeighting: true,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: 'resultbox.fact-text.n-trips-per-person-day',\n valueFormatter: null,\n valueDecimals: 1,\n valueUnit: null,\n customPalette: null,\n colspan: 4,\n },\n // Distance per person and day\n {\n id: getNextId(),\n type: ResultVisual.factText,\n label: i18n.t('resultbox.distance-per-person-day').toString(),\n partialQuery: {\n axisX: '',\n axisY: '',\n numerator: Numerator.delresaDistanceM,\n denominator: Denominator.anyDayDivN,\n scaleFactor: null,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.delresa,\n enableWeighting: true,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: 'resultbox.fact-text.distance-per-person-day',\n valueFormatter: ResultFormatter.mToKm,\n valueDecimals: 0,\n valueUnit: ResultUnit.km,\n customPalette: null,\n colspan: 4,\n },\n // Distance per person and day\n {\n id: getNextId(),\n type: ResultVisual.factText,\n label: i18n.t('resultbox.duration-per-person-day').toString(),\n partialQuery: {\n axisX: '',\n axisY: '',\n numerator: Numerator.delresaDurationS,\n denominator: Denominator.anyDayDivN,\n scaleFactor: null,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.delresa,\n enableWeighting: true,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: 'resultbox.fact-text.duration-per-person-day',\n valueFormatter: ResultFormatter.sToMinutes,\n valueDecimals: 0,\n valueUnit: ResultUnit.minutes,\n customPalette: null,\n colspan: 4,\n },\n ],\n };\n context.commit('addBoard', overviewBoard);\n const tripsBoard : ResultBoard = {\n id: 'trips',\n labelStr: 'resultboard.trips',\n info: null,\n resultBoxes: [\n modalSplitNTrips,\n // Modal split\n {\n id: getNextId(),\n type: ResultVisual.pieChart,\n label: i18n.t('resultbox.modal-split-trip-distance').toString(),\n partialQuery: {\n axisX: '\"aggregated mode\"',\n axisY: '',\n numerator: Numerator.delresaDistanceM,\n denominator: Denominator.anyDayDivN,\n scaleFactor: null,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.delresa,\n enableWeighting: true,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: ResultFormatter.mToKm,\n valueDecimals: 0,\n valueUnit: ResultUnit.km,\n customPalette: null,\n colspan: 6,\n },\n {\n id: getNextId(),\n type: ResultVisual.pieChart,\n label: i18n.t('resultbox.modal-split-trip-duration').toString(),\n partialQuery: {\n axisX: '\"aggregated mode\"',\n axisY: '',\n numerator: Numerator.delresaDurationS,\n denominator: Denominator.anyDayDivN,\n scaleFactor: null,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.delresa,\n enableWeighting: true,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: ResultFormatter.sToMinutes,\n valueDecimals: 0,\n valueUnit: ResultUnit.minutes,\n customPalette: null,\n colspan: 6,\n },\n {\n id: getNextId(),\n type: ResultVisual.barChart,\n label: i18n.t('resultbox.n-trips-per-week-day').toString(),\n partialQuery: {\n axisX: '\"week days\"',\n axisY: '',\n numerator: Numerator.nDelresa,\n denominator: Denominator.anyDayDivN,\n scaleFactor: null,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.delresa,\n enableWeighting: true,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: null,\n valueDecimals: 1,\n valueUnit: null,\n customPalette: null,\n colspan: 6,\n },\n // Activity split\n {\n id: getNextId(),\n type: ResultVisual.pieChart,\n label: i18n.t('resultbox.activity-split-n-trips').toString(),\n partialQuery: {\n axisX: '\"aggregated activity\"',\n // axisX: '',\n axisY: '',\n numerator: Numerator.nDelresa,\n denominator: Denominator.anyDayDivN,\n scaleFactor: null,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.delresa,\n enableWeighting: true,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: null,\n valueDecimals: 1,\n valueUnit: null,\n customPalette: null,\n colspan: 6,\n },\n {\n id: getNextId(),\n type: ResultVisual.pieChart,\n label: i18n.t('resultbox.activity-split-trip-distance').toString(),\n partialQuery: {\n axisX: '\"aggregated activity\"',\n axisY: '',\n numerator: Numerator.delresaDistanceM,\n denominator: Denominator.anyDayDivN,\n scaleFactor: null,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.delresa,\n enableWeighting: true,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: ResultFormatter.mToKm,\n valueDecimals: 0,\n valueUnit: ResultUnit.km,\n customPalette: null,\n colspan: 6,\n },\n {\n id: getNextId(),\n type: ResultVisual.pieChart,\n label: i18n.t('resultbox.activity-split-trip-duration').toString(),\n partialQuery: {\n axisX: '\"aggregated activity\"',\n axisY: '',\n numerator: Numerator.delresaDurationS,\n denominator: Denominator.anyDayDivN,\n scaleFactor: null,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.delresa,\n enableWeighting: true,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: ResultFormatter.sToMinutes,\n valueDecimals: 0,\n valueUnit: ResultUnit.minutes,\n customPalette: null,\n colspan: 6,\n },\n // average Distance per trip\n {\n id: getNextId(),\n type: ResultVisual.barChart,\n label: i18n.t('resultbox.distance-per-trip').toString(),\n partialQuery: {\n axisX: '\"aggregated mode\"',\n axisY: '',\n numerator: Numerator.delresaDistanceM,\n denominator: Denominator.nDelresaWithDistanceDivN,\n scaleFactor: null,\n statMethod: StatMethod.weightedTrips,\n travelType: TravelType.delresa,\n enableWeighting: true,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: ResultFormatter.mToKm,\n valueDecimals: 0,\n valueUnit: ResultUnit.km,\n customPalette: null,\n colspan: 6,\n },\n // average Duration per trip\n {\n id: getNextId(),\n type: ResultVisual.barChart,\n label: i18n.t('resultbox.duration-per-trip').toString(),\n partialQuery: {\n axisX: '\"aggregated mode\"',\n axisY: '',\n numerator: Numerator.delresaDurationS,\n denominator: Denominator.nDelresaWithDurationDivN,\n scaleFactor: null,\n statMethod: StatMethod.weightedTrips,\n travelType: TravelType.delresa,\n enableWeighting: true,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: ResultFormatter.sToMinutes,\n valueDecimals: 0,\n valueUnit: ResultUnit.minutes,\n customPalette: null,\n colspan: 6,\n },\n // OD matrix\n {\n id: getNextId(),\n type: ResultVisual.odMatrix,\n label: i18n.t('resultbox.od-matrix').toString(),\n partialQuery: {\n axisX: '\"to zone\"',\n axisY: '\"from zone\"',\n numerator: Numerator.nDelresa,\n denominator: Denominator.anyDayDivN,\n scaleFactor: null,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.delresa,\n enableWeighting: true,\n zoneFile: null,\n shareOutput: true,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: ResultFormatter.decToPercent,\n valueDecimals: 0,\n valueUnit: null,\n customPalette: null,\n colspan: 12,\n },\n ],\n };\n if (hasFeature('tripsPerSampleClass')) {\n payload.sampleVariables.forEach((sv : SampleVariable) => {\n if (sv.isShare) { // Ignore total row\n tripsBoard.resultBoxes.push({\n id: getNextId(),\n type: ResultVisual.barChart,\n label: i18n.t('resultbox.n-trips-per-sample-variable', {\n sampleVariable: resolveLabel(sv.label, sv.labelTranslations),\n }).toString(),\n partialQuery: {\n axisX: `sampleVariable(${sv.id})`,\n axisY: '',\n numerator: Numerator.nDelresa,\n denominator: Denominator.anyDayDivN,\n scaleFactor: null,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.delresa,\n enableWeighting: true,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: null,\n valueDecimals: 1,\n valueUnit: null,\n customPalette: null,\n colspan: 6,\n });\n }\n });\n }\n context.commit('addBoard', tripsBoard);\n } else if (flavor === Flavor.activeViewer) {\n // Build result boards for ActiveViewer\n const tripsBoard : ResultBoard = {\n id: 'trips',\n labelStr: 'resultboard.trips',\n info: null,\n resultBoxes: [\n buildSectionHeadingBox(getNextId(), i18n.t('resultboard.section.commuter-trips').toString()),\n {\n id: getNextId(),\n type: ResultVisual.horizontalBarChart,\n label: i18n.tc('resultbox.commuter-travel-days-per-person-day'),\n partialQuery: {\n axisX: '',\n axisY: '\"before/during/after\"',\n numerator: Numerator.nReselementDays,\n denominator: Denominator.anyDayDivN,\n scaleFactor: workFullTimeFactor,\n statMethod: StatMethod.estimatingProportion, // ?\n travelType: TravelType.reselement,\n enableWeighting: false,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: ResultFormatter.decToPercent,\n valueDecimals: 0,\n valueUnit: null,\n customPalette: null,\n colspan: 12,\n },\n {\n id: getNextId(),\n type: ResultVisual.horizontalBarChart,\n label: i18n.tc('resultbox.modal-split-commuter-trips-n-trips'),\n partialQuery: {\n axisX: '\"aggregated mode\"',\n axisY: '\"before/during/after\"',\n numerator: Numerator.nHuvudresa,\n denominator: Denominator.anyDayDivN,\n scaleFactor: 2 * workFullTimeFactor,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.huvudresa,\n enableWeighting: false,\n zoneFile: null,\n shareOutput: Axis.x,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: ResultFormatter.decToPercent,\n valueDecimals: 0,\n valueUnit: null,\n customPalette: null,\n colspan: 12,\n },\n {\n id: getNextId(),\n type: ResultVisual.horizontalBarChart,\n label: i18n.tc('resultbox.modal-split-commuter-trips-distance'),\n partialQuery: {\n axisX: '\"aggregated mode\"',\n axisY: '\"before/during/after\"',\n numerator: Numerator.reselementDistanceM,\n denominator: Denominator.anyDayDivN,\n scaleFactor: 2 * workFullTimeFactor,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.reselement,\n enableWeighting: false,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: ResultFormatter.mToKm,\n valueDecimals: 1,\n valueUnit: ResultUnit.km,\n customPalette: null,\n colspan: 12,\n },\n {\n id: getNextId(),\n type: ResultVisual.horizontalBarChart,\n label: i18n.tc('resultbox.modal-split-commuter-trips-duration'),\n partialQuery: {\n axisX: '\"aggregated mode\"',\n axisY: '\"before/during/after\"',\n numerator: Numerator.reselementDurationS,\n denominator: Denominator.anyDayDivN,\n scaleFactor: 2 * workFullTimeFactor,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.reselement,\n enableWeighting: false,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: ResultFormatter.sToMinutes,\n valueDecimals: 1,\n valueUnit: ResultUnit.minutes,\n customPalette: null,\n colspan: 12,\n },\n ],\n };\n context.commit('addBoard', tripsBoard);\n\n const healthBoard : ResultBoard = {\n id: 'health',\n labelStr: 'resultboard.health',\n info: {\n image: 'dumbbell',\n imageLabel: i18n.tc('resultboard.health'),\n palette: '5',\n label: i18n.tc('resultboard.health.board-info.title'),\n textCol1: i18n.tc('resultboard.health.board-info.col1.text'),\n textCol2: i18n.tc('resultboard.health.board-info.col2.text'),\n },\n resultBoxes: [\n buildSectionHeadingBox(getNextId(), i18n.t('resultboard.section.commuter-trips').toString()),\n {\n id: getNextId(),\n type: ResultVisual.horizontalBarChart,\n label: i18n.t('resultbox.commuter-minutes-per-person-and-week').toString(),\n partialQuery: {\n axisX: '\"aggregated mode\"',\n axisY: '\"before/during/after\"',\n axisXFilter: {\n includeIds: getActiveTransportAggregatedModes(payload.aggregatedModes),\n },\n numerator: Numerator.reselementDurationS,\n denominator: Denominator.anyDayDivN,\n scaleFactor: 2 * 7,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.reselement,\n enableWeighting: false,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: ResultFormatter.sToMinutes,\n valueDecimals: 0,\n valueUnit: ResultUnit.minutes,\n customPalette: [\n {\n bgColor: palette['5'],\n textColor: palette['5d'],\n },\n {\n bgColor: palette['5c'],\n textColor: palette['5b'],\n },\n ],\n colspan: 12,\n },\n\n ],\n };\n context.commit('addBoard', healthBoard);\n\n // CO2 BOARD\n const CO2Board : ResultBoard = {\n id: 'CO2',\n labelStr: 'resultboard.CO2',\n info: {\n image: 'tree',\n imageLabel: i18n.tc('resultboard.CO2'),\n palette: '4',\n label: i18n.tc('resultboard.CO2.board-info.title'),\n textCol1: i18n.tc('resultboard.CO2.board-info.col1.text'),\n textCol2: i18n.tc('resultboard.CO2.board-info.col2.text'),\n },\n resultBoxes: [\n buildSectionHeadingBox(getNextId(), i18n.t('resultboard.section.commuter-trips').toString()),\n {\n id: getNextId(),\n type: ResultVisual.horizontalBarChart,\n label: i18n.tc('resultbox.emissions-co2-per-participant-and-day'),\n partialQuery: {\n axisX: '\"aggregated mode\"',\n axisY: '\"before/during/after\"',\n axisXFilter: {\n includeIds: getEmissionAggregatedModes(payload.aggregatedModes),\n },\n numerator: Numerator.reselementCo2Kg,\n denominator: Denominator.anyDayDivN,\n scaleFactor: 2,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.reselement,\n enableWeighting: false,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: null,\n valueDecimals: 2,\n valueUnit: ResultUnit.kg,\n customPalette: [\n {\n bgColor: palette['4b'],\n textColor: palette['4d'],\n },\n {\n bgColor: palette['4c'],\n textColor: palette['4b'],\n },\n {\n bgColor: palette['4'],\n textColor: palette['4b'],\n },\n ],\n colspan: 12,\n },\n ],\n };\n context.commit('addBoard', CO2Board);\n\n const ParkingBoard : ResultBoard = {\n id: 'Parking',\n labelStr: 'resultboard.parking',\n info: {\n image: 'parking',\n imageLabel: null,\n palette: '1',\n label: i18n.tc('resultboard.parking.board-info.title'),\n textCol1: i18n.tc('resultboard.parking.board-info.col1.text'),\n textCol2: i18n.tc('resultboard.parking.board-info.col2.text'),\n },\n resultBoxes: [\n buildSectionHeadingBox(getNextId(), i18n.t('resultboard.section.commuter-trips').toString()),\n {\n id: getNextId(),\n type: ResultVisual.horizontalBarChart,\n label: i18n.tc('resultbox.car-parking-demand-per-participant'),\n partialQuery: {\n axisX: '',\n axisY: '\"before/during/after\"',\n numerator: Numerator.nHuvudresaCar,\n denominator: Denominator.nHuvudresaDivN,\n scaleFactor: null,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.huvudresa,\n enableWeighting: false,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: ResultFormatter.decToPercent,\n valueDecimals: 1,\n valueUnit: null,\n customPalette: [\n {\n bgColor: palette['1'],\n textColor: palette['1d'],\n },\n ],\n colspan: 6,\n },\n {\n id: getNextId(),\n type: ResultVisual.horizontalBarChart,\n label: i18n.tc('resultbox.bike-parking-demand-per-participant'),\n partialQuery: {\n axisX: '',\n axisY: '\"before/during/after\"',\n numerator: Numerator.nHuvudresaBike,\n denominator: Denominator.nHuvudresaDivN,\n scaleFactor: null,\n statMethod: StatMethod.estimatingProportion,\n travelType: TravelType.huvudresa,\n enableWeighting: false,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: ResultFormatter.decToPercent,\n valueDecimals: 1,\n valueUnit: null,\n customPalette: [\n {\n bgColor: palette['1'],\n textColor: palette['1d'],\n },\n ],\n colspan: 6,\n },\n ],\n };\n context.commit('addBoard', ParkingBoard);\n } else {\n Log.error('Invalid flavor');\n }\n\n // Questionnaire - using sample variables\n // TODO: exclude home area sample variables. (put them in a separate result board)\n const questionnaireBoard : ResultBoard = {\n id: 'questionnaire',\n labelStr: 'resultboard.questionnaire',\n info: null,\n resultBoxes: [\n ],\n };\n payload.sampleVariables.forEach((sv : SampleVariable) => {\n if (sv.isShare) { // Ignore total row\n questionnaireBoard.resultBoxes.push({\n id: getNextId(),\n type: sv.multiMembership ? ResultVisual.barChart : ResultVisual.pieChart,\n label: resolveLabel(sv.label, sv.labelTranslations).toString(),\n partialQuery: {\n axisX: `sampleVariable(${sv.id})`,\n axisY: '',\n numerator: Numerator.nAxisX,\n denominator: Denominator.n,\n scaleFactor: null,\n statMethod: StatMethod.estimatingProportion,\n travelType: flavor === Flavor.travelViewer\n ? TravelType.delresa\n : TravelType.reselement,\n enableWeighting: flavor === Flavor.travelViewer,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: ResultFormatter.decToPercent,\n valueDecimals: 0,\n valueUnit: null,\n customPalette: null,\n colspan: 6,\n });\n }\n });\n context.commit('addBoard', questionnaireBoard);\n\n if (flavor === Flavor.travelViewer) {\n const metaBoard : ResultBoard = {\n id: 'meta',\n labelStr: 'resultboard.meta',\n info: null,\n resultBoxes: [\n // No-travel days per person and day\n {\n id: getNextId(),\n type: ResultVisual.factText,\n label: i18n.t('resultbox.travel-days-per-person-day').toString(),\n partialQuery: {\n axisX: '',\n axisY: '',\n numerator: Numerator.nDelresaDays,\n denominator: Denominator.anyDayDivN,\n scaleFactor: null,\n statMethod: StatMethod.estimatingProportion, // ?\n travelType: TravelType.delresa,\n enableWeighting: true,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: 'resultbox.fact-text.travel-days-per-person-day',\n valueFormatter: ResultFormatter.decToPercent,\n valueDecimals: 0,\n valueUnit: null,\n customPalette: null,\n colspan: 6,\n },\n /*\n // Number of corrected days in total\n {\n id: getNextId(),\n type: ResultVisual.factText,\n label: i18n.t('resultbox.number-of-corrected-days-per-weekday').toString(),\n partialQuery: {\n axisX: '',\n axisY: '',\n numerator: Numerator.nCorrectedDay,\n denominator: Denominator.one,\n scaleFactor: null,\n statMethod: StatMethod.estimatingMean,\n travelType: TravelType.delresa,\n enableWeighting: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: 'resultbox.fact-text.travel-days-per-person-day',\n valueFormatter: null,\n valueDecimals: 0,\n valueUnit: null,\n customPalette: null,\n colspan: 6,\n },\n */\n // Number of corrected days per weekday\n {\n id: getNextId(),\n type: ResultVisual.barChart,\n label: i18n.t('resultbox.number-of-corrected-days-per-weekday').toString(),\n partialQuery: {\n axisX: '\"week days\"',\n axisY: '',\n numerator: Numerator.nCorrectedDay,\n denominator: Denominator.one,\n scaleFactor: null,\n statMethod: StatMethod.estimatingMean,\n travelType: TravelType.delresa,\n enableWeighting: false,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: null,\n valueDecimals: 0,\n valueUnit: null,\n customPalette: null,\n colspan: 6,\n },\n {\n id: getNextId(),\n type: ResultVisual.barChart,\n label: i18n.t('resultbox.number-of-corrected-days-per-date').toString(),\n partialQuery: {\n axisX: resolveDatesAxis(payload.surveyStartDate, payload.surveyEndDate),\n axisY: '',\n numerator: Numerator.nCorrectedDay,\n denominator: Denominator.one,\n scaleFactor: null,\n statMethod: StatMethod.estimatingMean,\n travelType: TravelType.delresa,\n enableWeighting: false,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: null,\n valueDecimals: 0,\n valueUnit: null,\n customPalette: null,\n colspan: 6,\n },\n {\n id: getNextId(),\n type: ResultVisual.barChart,\n label: i18n.t('resultbox.number-of-corrected-days-per-week').toString(),\n partialQuery: {\n axisX: resolveWeeksAxis(payload.surveyStartDate, payload.surveyEndDate),\n axisY: '',\n numerator: Numerator.nCorrectedDay,\n denominator: Denominator.one,\n scaleFactor: null,\n statMethod: StatMethod.estimatingMean,\n travelType: TravelType.delresa,\n enableWeighting: false,\n zoneFile: null,\n shareOutput: false,\n calculateMapFilter: false,\n },\n filterOverride: noFilterOverride,\n factTextStr: null,\n valueFormatter: null,\n valueDecimals: 0,\n valueUnit: null,\n customPalette: null,\n colspan: 6,\n },\n ],\n };\n context.commit('addBoard', metaBoard);\n }\n resolve();\n });\n },\n },\n getters: {\n /**\n * Provides a map from ':' to a string that\n * represent the current box state of a result box. It is\n * meant only for reacting on changes. Not to be parsed.\n */\n boxState: (state:ResultBoardStateInterface) => {\n const map : any = {};\n state.resultBoards.forEach((board) => {\n board.resultBoxes.forEach((box) => {\n const key = `${board.id}:${box.id}`;\n let s = '';\n s += `t:${box.type}`;\n if (box.partialQuery !== null) {\n const i = attachmentState(box.partialQuery.zoneFile);\n s += `x:${box.partialQuery.axisX}`;\n s += `y:${box.partialQuery.axisY}`;\n s += `n:${box.partialQuery.numerator}`;\n s += `d:${box.partialQuery.denominator}`;\n s += `s:${box.partialQuery.scaleFactor}`;\n s += `w:${box.partialQuery.enableWeighting}`;\n s += `s:${box.partialQuery.statMethod}`;\n s += `t:${box.partialQuery.travelType}`;\n s += `z:${box.partialQuery.zoneFile}`;\n s += `i:${i}`;\n s += `s:${box.partialQuery.shareOutput}`;\n }\n map[key] = s;\n });\n });\n return map;\n },\n },\n};\n","import { ActionContext } from 'vuex';\nimport axios, { CancelTokenSource } from 'axios';\nimport { api } from '@/api';\nimport Log from '@/utils/log';\nimport { RootState } from '../../root-state';\nimport {\n Query, QueryResult,\n SentQuery, QueryStateInterface,\n ResultQueryPromise,\n} from './types';\n\ntype Context = ActionContext;\n\ninterface AddSentQueryParams {\n query: Query;\n apiPromise : ResultQueryPromise;\n cancelTokenSource: CancelTokenSource;\n}\n\ninterface SetQueryResultParams {\n sendId: number;\n result : QueryResult;\n}\n\ninterface RemoveSentQueryParams {\n sendId: number;\n}\n\n/**\n * (current) User state management\n */\nexport default {\n namespaced: true,\n state: {\n sentQueries: [],\n lastSendId: -1,\n },\n mutations: {\n /**\n * Store a query as sent\n * @param state\n * @param query\n */\n addSentQuery(state : QueryStateInterface, payload: AddSentQueryParams) {\n state.lastSendId += 1;\n const data : SentQuery = {\n id: state.lastSendId,\n sentTimestamp: (new Date()).getTime() / 1000,\n // Serialize query to make sure we store a copy of filter state etc. for this query\n serializedQuery: JSON.stringify(payload.query),\n result: null,\n apiPromise: payload.apiPromise,\n cancelTokenSource: payload.cancelTokenSource,\n };\n\n state.sentQueries.push(data);\n },\n setQueryResult(state : QueryStateInterface, payload : SetQueryResultParams) {\n const sentQuery = state.sentQueries.find((sq : SentQuery) => sq.id === payload.sendId);\n if (sentQuery !== undefined) {\n sentQuery.result = payload.result;\n sentQuery.cancelTokenSource = null; // not possible to cancel anymore\n }\n },\n /**\n * Removes sent query info for this query\n */\n removeSentQuery(state : QueryStateInterface, payload: RemoveSentQueryParams) {\n const index = state.sentQueries.findIndex((sq : SentQuery) => sq.id === payload.sendId);\n if (index !== -1) {\n state.sentQueries.splice(index, 1);\n }\n },\n /**\n * Removes all queries. Any ongoing query is canceled.\n */\n clear(state : QueryStateInterface, params : void) {\n // Cancel ongoing queries upon clear\n state.sentQueries.forEach((sq : SentQuery) => {\n if (sq.cancelTokenSource !== null) {\n sq.cancelTokenSource.cancel();\n }\n });\n\n state.sentQueries = [];\n state.lastSendId = -1;\n },\n },\n actions: {\n /**\n * Sends query to server and stores the query and later on the response\n * in store.\n * This function will resolve after the query has been sent with an id\n * that can be used with action waitOnQuery(sentId) to wait for server\n * response.\n *\n * @param context\n * @param payload\n */\n sendQuery(context : Context,\n payload: { query: Query }) : Promise {\n return new Promise(async (resolve, reject) => {\n const cancel = axios.CancelToken.source();\n const apiPromise = api.resultQuery(\n payload.query, context.rootState.user.token, cancel.token,\n );\n context.commit('addSentQuery', {\n query: payload.query,\n apiPromise,\n cancelTokenSource: cancel,\n });\n const sendId = context.state.lastSendId;\n resolve(sendId); // Resolve with Id\n\n try {\n const response = await apiPromise;\n context.commit('setQueryResult', {\n sendId,\n result: response.data,\n });\n } catch (e: any) {\n if (e.response !== undefined && e.response.status === 401) {\n console.log('401 in response => logout');\n context.dispatch('user/logout', {}, { root: true });\n }\n context.commit('removeSentQuery', {\n sendId,\n });\n reject();\n }\n });\n },\n /**\n * Waits until the server request triggered by sendQuery has responded and then\n * resolves with the query result.\n * Rejects on server error or invalid sendId\n * @param sendId Id received from sendQuery\n */\n waitOnQuery(context : Context,\n payload: { sendId: number }) : Promise {\n return new Promise(async (resolve, reject) => {\n // --\n Log.log('waitOnQuery', payload.sendId);\n const sentQuery = context.state.sentQueries.find(\n (sq : SentQuery) => sq.id === payload.sendId,\n );\n if (sentQuery !== undefined && sentQuery.apiPromise !== null) {\n try {\n const response = await sentQuery.apiPromise;\n resolve(response.data);\n } catch (e) {\n console.log('network error');\n reject();\n }\n } else {\n console.log('sendId not found', payload.sendId);\n reject();\n }\n });\n },\n },\n getters: {\n /**\n * Get result from query. If query has not yet responded or there\n * is an error, null is returned.\n * @param sendId id of query received from calling sendQuery\n */\n getResult: (state:QueryStateInterface) => (sendId : number) : QueryResult|null => {\n const sentQuery = state.sentQueries.find((sq : SentQuery) => sq.id === sendId);\n\n if (sentQuery !== undefined) {\n return sentQuery.result;\n }\n\n return null;\n },\n /**\n * Look for an identical query that has already been sent and return its sendId.\n *\n * Queries that have responded with an error are not regarded.\n * @param query The query to look for\n * @return SendId of found sent query or null\n */\n findSameQuery: (state:QueryStateInterface) => (query : Query) : number|null => {\n const s = JSON.stringify(query);\n\n // console.log('query', s);\n // state.sentQueries.forEach((sq : SentQuery) => console.log('sq', sq.serializedQuery));\n\n const sentQuery = state.sentQueries.find((sq : SentQuery) => sq.serializedQuery === s);\n\n return sentQuery !== undefined ? sentQuery.id : null;\n },\n },\n};\n","import { ActionContext } from 'vuex';\nimport { RootState } from '../../root-state';\nimport { QuerySettingsStateInterface } from './types';\n\ntype Context = ActionContext;\n\n/* eslint key-spacing: [\"off\"] */\nfunction _initialState() : QuerySettingsStateInterface {\n return {\n includeJoinDateInSurvey: true,\n limits: {\n minDistanceM: {},\n maxDistanceM: {\n // Limits values from RVU manual, but extended to have all modes\n WALK: 25 * 1000,\n CAR_: 1500 * 1000,\n CARD: 1500 * 1000,\n CARP: 1500 * 1000,\n ECAR: 1500 * 1000,\n ECRD: 1500 * 1000,\n ECRP: 1500 * 1000,\n NCAR: 1500 * 1000,\n NCRD: 1500 * 1000,\n NCRP: 1500 * 1000,\n PCAR: 1500 * 1000,\n BCAR: 1500 * 1000,\n SCAR: 1500 * 1000,\n RCAR: 1500 * 1000,\n BUS_: 1500 * 1000,\n SBUS: 1500 * 1000,\n CBUS: 1500 * 1000,\n LORY: 1500 * 1000,\n VAN_: 1500 * 1000,\n FERY: 1000 * 1000,\n TRAM: 250 * 1000,\n METR: 250 * 1000,\n CTRN: 250 * 1000,\n TRN_: 2000 * 1000,\n CABE: 100 * 1000,\n BIKE: 100 * 1000,\n EBKE: 100 * 1000,\n CBKE: 100 * 1000,\n SBIK: 100 * 1000,\n SCOT: 500 * 1000,\n SCOM: 500 * 1000,\n MOPD: 500 * 1000,\n MC__: 1500 * 1000,\n TAXI: 500 * 1000,\n TAXR: 500 * 1000,\n TUKT: 500 * 1000,\n MBSR: 500 * 1000,\n EXRC: 500 * 1000,\n AIR_: 25000 * 1000,\n OTHR: 10000 * 1000,\n UKNW: 10000 * 1000,\n },\n minDurationS: {},\n maxDurationS: {\n WALK: 5 * 3600,\n CAR_: 24 * 3600,\n CARD: 24 * 3600,\n CARP: 24 * 3600,\n ECAR: 24 * 3600,\n ECRD: 24 * 3600,\n ECRP: 24 * 3600,\n NCAR: 24 * 3600,\n NCRD: 24 * 3600,\n NCRP: 24 * 3600,\n PCAR: 24 * 3600,\n BCAR: 24 * 3600,\n SCAR: 24 * 3600,\n RCAR: 24 * 3600,\n BUS_: 24 * 3600,\n SBUS: 24 * 3600,\n CBUS: 24 * 3600,\n LORY: 24 * 3600,\n VAN_: 24 * 3600,\n FERY: 36 * 3600,\n TRAM: 5 * 3600,\n METR: 5 * 3600,\n CTRN: 5 * 3600,\n TRN_: 36 * 3600,\n CABE: 5 * 3600,\n BIKE: 10 * 3600,\n EBKE: 10 * 3600,\n CBKE: 10 * 3600,\n SBIK: 10 * 3600,\n SCOT: 10 * 3600,\n SCOM: 10 * 3600,\n MOPD: 10 * 3600,\n MC__: 24 * 3600,\n TAXI: 10 * 3600,\n TAXR: 10 * 3600,\n TUKT: 10 * 3600,\n MBSR: 10 * 3600,\n EXRC: 15 * 3600,\n AIR_: 36 * 3600,\n OTHR: 36 * 3600,\n UKNW: 36 * 3600,\n },\n },\n minCellN: 5,\n weightLimits: {\n minClassN: 0, // TODO: should default to 5\n minVariableN: 0, // TODO: should default to 100\n warnVariableN: 100, // TODO: should default to 100\n },\n activityMethod: 'end-activity',\n nRequiresTrips: false,\n vtiReselementMerge: false,\n };\n}\n\nfunction persist(state: QuerySettingsStateInterface) {\n localStorage.setItem('querySettings', JSON.stringify(state));\n}\n\n/* eslint no-underscore-dangle: [\"off\", {}}] */\n/* eslint prefer-template: [\"off\", {}}] */\n\n/**\n * (current) User state management\n */\nexport default {\n namespaced: true,\n state: _initialState(),\n mutations: {\n /**\n * Unsafe setter (no typechecking or data validation)\n * @param querySettings Object with same names as state as keys.\n */\n set(state: QuerySettingsStateInterface, querySettings: any) {\n Object.keys(state).forEach((key : string) => {\n if (querySettings[key] !== undefined\n && (state)[key] !== undefined\n ) {\n (state)[key] = (querySettings)[key];\n }\n });\n persist(state);\n },\n /**\n * Reset to deafult state\n * @param state\n * @param params\n */\n clear(state: QuerySettingsStateInterface) {\n const initialState = _initialState();\n Object.keys(state).forEach((key : string) => {\n (state)[key] = (initialState)[key];\n });\n persist(state);\n },\n },\n actions: {\n restore(context:ActionContext) {\n const querySettingsString = localStorage.getItem('querySettings');\n if (querySettingsString !== null) {\n const querySettings = JSON.parse(querySettingsString);\n if (querySettings !== null) {\n context.commit('set', querySettings);\n }\n }\n },\n },\n getters: {\n /**\n * Provides a unique string that represent the current query settings\n * state. It can be used to react to changes to the query settings\n * state but is not ment to be used for data transfer and\n * being decoded later on.\n */\n querySettingsState: (state:QuerySettingsStateInterface) => {\n let s = '';\n\n s += `i:${state.includeJoinDateInSurvey ? '0' : '1'}`;\n s += 'lim:';\n Object.keys(state.limits).forEach((limit : string) => {\n let sm = '';\n const limitObj = (state.limits)[limit];\n Object.keys(limitObj).forEach((mode : string) => {\n if (sm !== '') sm += ',';\n sm += `${mode}:${limitObj[mode]}`;\n });\n s += sm;\n });\n s += `mcn:${state.minCellN}`;\n s += `wl:${state.weightLimits.minClassN},${state.weightLimits.minVariableN},${state.weightLimits.warnVariableN}`;\n s += `am:${state.activityMethod}`;\n s += `nrt:${state.nRequiresTrips ? '0' : '1'}`;\n s += `vrm:${state.vtiReselementMerge ? '0' : '1'}`;\n\n return s;\n },\n },\n};\n","import { flavor } from '@/flavor';\nimport { Flavor } from '@/flavor/types';\nimport Log from '@/utils/log';\nimport { ActionContext } from 'vuex';\nimport { EnableAllParams } from './modules/filter';\nimport { ResultBoardLoadParams } from './modules/result-board';\nimport { Survey } from './modules/survey/types';\nimport { RootState } from './root-state';\n\nexport interface SelectSurveyParams {\n surveyId : number;\n startDate : string;\n endDate : string;\n restore : boolean; // true to restore filter/querySettings\n}\n\n/**\n * Set given surveyId as selected survey and load filters etc.\n * for that survey.\n * @param context\n * @param payload\n * @returns\n */\nexport async function selectSurvey(\n context : ActionContext,\n payload : SelectSurveyParams,\n) {\n return new Promise((resolve, reject) => {\n context.commit('survey/selectSurvey', payload.surveyId);\n try {\n Log.log(`select survey - restore: ${payload.restore}`);\n Log.log('clear');\n if (!payload.restore) {\n context.commit('filter/clear');\n context.commit('querySettings/clear');\n }\n context.commit('sample/clear');\n context.commit('modeActivity/clear');\n context.commit('questionnaire/clear');\n context.commit('resultBoard/clear');\n context.commit('questionnaire/clear');\n Log.log('load');\n const waitOn :Array> = [];\n if (flavor === Flavor.activeViewer) {\n waitOn.push(context.dispatch('questionnaire/load'));\n }\n Promise.all([\n context.dispatch('modeActivity/load'),\n context.dispatch('sample/load'),\n ]).then(async () => {\n if (flavor === Flavor.activeViewer) {\n context.commit('modeActivity/mainAggregateModes');\n context.commit('modeActivity/mainAggregateActivities');\n context.commit('querySettings/set', {\n includeJoinDateInSurvey: false,\n nRequiresTrips: true,\n });\n }\n Log.log('enable filters');\n if (!payload.restore) {\n context.commit('filter/enableAll', {\n aggregatedModes: context.getters['modeActivity/getAggregatedModesExcludingExercice'],\n aggregatedActivities: context.state.modeActivity.aggregatedActivities,\n sampleVariables: context.state.sample.variables,\n surveyStartDate: payload.startDate,\n surveyEndDate: payload.endDate,\n } as EnableAllParams);\n if (flavor === Flavor.activeViewer) {\n context.commit('filter/setFilter', {\n isCommuteToWork: true,\n });\n }\n } else {\n await context.dispatch('filter/restore');\n await context.dispatch('querySettings/restore');\n }\n // load result board last.\n Log.log('load result boards');\n waitOn.push(context.dispatch('resultBoard/load', {\n sampleVariables: context.state.sample.variables,\n surveyStartDate: payload.startDate,\n surveyEndDate: payload.endDate,\n aggregatedModes: context.state.modeActivity.aggregatedModes,\n } as ResultBoardLoadParams));\n await Promise.all(waitOn);\n window.localStorage.setItem('selectedSurveyId', `${payload.surveyId}`);\n resolve();\n });\n } catch (e) {\n // Error => unselect\n context.commit('survey/selectSurvey', -1);\n reject();\n }\n });\n}\n\n/**\n * Restore selected survey from persisted selection in localStorage\n *\n * Perform survey/load and then root selectSurvey if a surveyId is\n * persisted in selectedSurveyId in local storage.\n * @param context\n * @returns\n */\nexport async function restoreSelectedSurvey(\n context : ActionContext,\n) {\n const surveyIdString = window.localStorage.getItem('selectedSurveyId');\n if (surveyIdString === null) {\n Log.log('restoreSelectedSurvey no stored selection => abort');\n return;\n }\n const surveyId = parseInt(surveyIdString, 10);\n\n // If there is a selection already, don't restore.\n if (context.getters['survey/getSelected'] !== null) {\n Log.log('restoreSelectedSurvey has selection => abort');\n return;\n }\n if (context.getters['survey/getAll'].length === 0) {\n await context.dispatch('survey/load');\n }\n\n const surveyList : Array = context.getters['survey/getAll'];\n const survey = surveyList.find((survey) => survey.id === surveyId);\n if (survey === null) {\n Log.log(`selectedSurveyId ${surveyId} in storage is no longer available`);\n return;\n }\n await context.dispatch('selectSurvey', {\n surveyId,\n startDate: survey!.startDate,\n endDate: survey!.endDate,\n restore: true,\n } as SelectSurveyParams);\n}\n","import Vue from 'vue';\nimport Vuex from 'vuex';\nimport UserModule from './modules/user/index';\nimport SurveyModule from './modules/survey/index';\nimport SampleModule from './modules/sample/index';\nimport ModeActivityModule from './modules/mode-activity/index';\nimport Questionnaire from './modules/questionnaire/index';\nimport HomeArea from './modules/home-area/index';\nimport FilterModule from './modules/filter/index';\nimport ResultBoardModule from './modules/result-board/index';\nimport QueryModule from './modules/query/index';\nimport QuerySettingsModule from './modules/query-settings/index';\nimport { RootState } from './root-state';\nimport { QuestionType } from './modules/questionnaire/types';\nimport { selectSurvey, restoreSelectedSurvey } from './actions';\n\nVue.use(Vuex);\n\n/*\n * Principle:\n * No module mutation or action may write to\n * another module.\n *\n * Any orchestrated mutation or action that affect\n * multiple modules are placed at root level.\n */\n\nexport default new Vuex.Store({\n mutations: {\n },\n actions: {\n selectSurvey,\n restoreSelectedSurvey,\n },\n modules: {\n user: UserModule,\n survey: SurveyModule,\n sample: SampleModule,\n modeActivity: ModeActivityModule,\n filter: FilterModule,\n resultBoard: ResultBoardModule,\n query: QueryModule,\n querySettings: QuerySettingsModule,\n questionnaire: Questionnaire,\n homeArea: HomeArea,\n },\n});\n","import Vue from 'vue';\nimport VueRouter, { Route } from 'vue-router';\nimport store from '@/store';\nimport Log from '@/utils/log';\n\nVue.use(VueRouter);\n\nconst routes = [\n {\n path: '/login',\n // route level code-splitting\n // this generates a separate chunk (about.[hash].js) for this route\n // which is lazy-loaded when the route is visited.\n component: () => import(/* webpackChunkName: \"login\" */ '@/views/Login.vue'),\n },\n {\n path: '/',\n name: 'menu',\n component: () => import(/* webpackChunkName: \"home\" */ '@/views/Menu.vue'),\n children: [\n {\n path: 'survey',\n // route level code-splitting\n // this generates a separate chunk (about.[hash].js) for this route\n // which is lazy-loaded when the route is visited.\n component: () => import(/* webpackChunkName: \"survey\" */ '@/views/Survey.vue'),\n },\n {\n path: 'sample',\n // route level code-splitting\n component: () => import(/* webpackChunkName: \"sample\" */ '@/views/Sample.vue'),\n },\n {\n path: 'weighting',\n // route level code-splitting\n component: () => import(/* webpackChunkName: \"weighting\" */ '@/views/Weighting.vue'),\n },\n {\n path: 'analysis',\n // route level code-splitting\n component: () => import(/* webpackChunkName: \"analysis\" */ '@/views/Analysis.vue'),\n },\n {\n path: 'user-profile',\n // route level code-splitting\n component: () => import(/* webpackChunkName: \"user-profile\" */ '@/views/UserProfile.vue'),\n },\n {\n path: 'support',\n // route level code-splitting\n component: () => import(/* webpackChunkName: \"support\" */ '@/views/Support.vue'),\n },\n {\n path: 'edit-sample-variables/:from',\n name: 'edit-sample-variables',\n // route level code-splitting\n component: () => import(/* webpackChunkName: \"edit-sample-variables\" */ '@/views/EditSampleVariables.vue'),\n },\n ],\n },\n {\n path: '/*',\n redirect: '/',\n },\n];\n\n/* Copied from vue-router that have note eported these types at the time of writing this */\ntype Position = { x: number; y: number }\n\n// Actual vue-router scrollBehaviour doesn't work. Probably because our child routes serve\n// a dom node that doesn't scroll and then further down in the three we have our
that\n// does scroll. So instead we use some custom code. The general picture when I read up on\n// the issue is that the Vue scrolling have multiple problems and it is common that people\n// have to roll their own code for this. :-( /Leif, 2020-04-22\nlet scrollPosition: any = {};\n\nconst router = new VueRouter({\n routes,\n});\n\n// Only allow non-home views if user is logged in.\nrouter.beforeEach(async (to: Route, from: Route, next: Function) => {\n await store.dispatch('user/checkLoggedIn');\n if (store.state.user.isLoggedIn) {\n if (store.state.survey.surveyList.length === 0) {\n await store.dispatch('survey/load');\n }\n store.dispatch('restoreSelectedSurvey');\n }\n\n // Save scroll position of
\n if (from !== null) {\n const main = document.querySelector('main');\n if (main !== null) {\n scrollPosition[from.path] = { x: main.scrollLeft, y: main.scrollTop } as Position;\n Log.log('Saved position', from.path, scrollPosition[from.path]);\n }\n }\n\n if (['/', '/login'].includes(to.path) && store.state.user.isLoggedIn) {\n next('/survey');\n } else if (to.path !== '/login' && !store.state.user.isLoggedIn) {\n scrollPosition = {}; // throw away saved scroll positions.\n next('/login');\n } else {\n if (to.path === '/login') {\n scrollPosition = {}; // throw away saved scroll positions.\n }\n next();\n }\n});\n\nrouter.afterEach(async (to: Route, from: Route) => {\n // Restore saved scroll position\n Log.log('Restore Saved position', to.path, scrollPosition[to.path]);\n if ([\n '/survey', '/sample', '/weighting', '/analysis', '/support',\n ].includes(to.path) && scrollPosition[to.path] !== undefined) {\n // We need to let the new route load into DOM before we can access\n // the right
element.\n setTimeout(() => {\n const main = document.querySelector('main');\n if (main !== null) {\n main.scrollLeft = scrollPosition[to.path].x;\n main.scrollTop = scrollPosition[to.path].y;\n }\n }, 1);\n }\n});\n\nexport default router;\n","import Vue from 'vue';\nimport Buefy from 'buefy';\nimport App from './App.vue';\nimport router from './router';\nimport store from './store';\nimport i18n from './i18n';\nimport '@mdi/font/css/materialdesignicons.css';\n\nVue.config.productionTip = false;\nVue.use(Buefy);\n\nnew Vue({\n router,\n store,\n i18n,\n render: (h) => h(App),\n}).$mount('#app');\n","import { AxiosResponse, CancelTokenSource } from 'axios';\nimport { FilterStateInterface } from '../filter/types';\nimport { AggregatedModeConfig, AggregatedActivityConfig } from '../mode-activity/types';\n\nexport enum TravelType {\n reselement = 'reselement',\n delresa = 'delresa',\n huvudresa = 'huvudresa',\n}\n\nexport enum Numerator {\n nCorrectedDay = 'nCorrectedDay',\n nHuvudresa = 'nHuvudresa',\n nHuvudresaCar = 'nHuvudresaCar',\n nHuvudresaBike = 'nHuvudresaBike',\n nDelresa = 'nDelresa',\n nReselement = 'nReselement',\n delresaDistanceM = 'delresaDistanceM',\n delresaDurationS = 'delresaDurationS',\n reselementDistanceM = 'reselementDistanceM',\n reselementDurationS = 'reselementDurationS',\n reselementCo2Kg = 'reselementCo2Kg',\n nDelresaDays = 'nDelresaDays',\n nReselementDays = 'nReselementDays',\n one = 'one', // 1\n nAxisX = 'nAxisX',\n}\n\nexport enum Denominator {\n anyDayDivN = 'anyDayDivN',\n travelDayDivN = 'travelDayDivN',\n n = 'n',\n nDelresaDivN = 'nDelresaDivN',\n nReselementDivN = 'nReselementDivN',\n nHuvudresaDivN = 'nHuvudresaDivN',\n one = 'one',\n nDelresaWithDurationDivN = 'nDelresaWithDurationDivN', // Used with StatMethod.weightedTrips\n nDelresaWithDistanceDivN = 'nDelresaWithDistanceDivN', // Used with StatMethod.weightedTrips\n}\n\nexport enum StatMethod {\n estimatingMean = 'estimatingMean',\n estimatingProportion = 'estimatingProportion',\n weightedTrips = 'weightedTrips', // Used to calculate average distance or duration per trip\n}\n\nexport enum ActivityMethod {\n endActivity = 'end-activity',\n notHomeSleep = 'not-home-sleep',\n}\n\nexport enum Axis {\n x = 'x',\n y = 'y',\n}\n\nexport interface AxisFilter {\n includeIds: Array; // int|string|null - list of ids in returned axis to include\n}\n\nexport interface Limits {\n minDistanceM: any; // object map from string to number\n maxDistanceM: any; // object map from string to number\n minDurationS: any; // object map from string to number\n maxDurationS: any; // object map from string to number\n}\n\nexport interface WeightLimits {\n // mininmum number of respondents in a class to weight on corresponding variable.\n // Recommended default: 5\n minClassN : number;\n // minimum number of respondents in total in a variable to weight on it.\n // Recommended default: 50\n minVariableN : number;\n // if exceeding minVariableN, but less than warnVariableN respondents a warning\n // will be issued.\n // Recommended default: 100\n warnVariableN : number;\n}\n\nexport interface Attachment {\n fileName: string;\n content: string;\n}\n\n/* Contains properties defined in a ResultBox */\nexport interface PartialQuery {\n axisX : string;\n axisY : string;\n axisXFilter? : AxisFilter\n axisYFilter? : AxisFilter\n statMethod: StatMethod;\n travelType: TravelType;\n numerator: Numerator;\n denominator : Denominator;\n scaleFactor : number|null; // Scale the result by this value or null to not scale\n enableWeighting : boolean;\n zoneFile : Attachment|null; // [user input]\n shareOutput : boolean|Axis; // should result be post processed so each cell report its ratio of the table total value? [0, 1]\n // If enabled, mapFilterId is calculated by the query (which is then used to fetch result as map tiles) and no\n // further results are calculated. Should be set to false for all normal calculations.\n calculateMapFilter : boolean;\n}\n\n/* Contains all query porperties joining both each ResultBox settings\n * with global filter state and limits and other misc settings\n */\nexport interface Query extends PartialQuery {\n surveyId: number;\n // If this is set to false, corrected days that occur on the join date of each respondent are ignored.\n includeJoinDateInSurvey: boolean;\n filter : FilterStateInterface;\n // (resonable) Limits does not remove the actual trips, but set distanceM := null or\n // durationS := null when trips do not meet the criteria.\n limits : Limits;\n minCellN : number;\n weightLimits : WeightLimits;\n aggregatedModeConfig : AggregatedModeConfig;\n aggregatedActivityConfig : AggregatedActivityConfig;\n\n activityMethod : ActivityMethod; // \"end-activity\" or \"not-home-sleep\"\n nRequiresTrips : boolean; // require trips (that passes filter) to include individual in n (and x)\n vtiReselementMerge : boolean;\n}\n\nexport interface QueryResultCell {\n value : number; // Value in the cell - double\n n : number; // N individuals - integer\n\n // For future use:\n // median : number; - median value - dobule\n // confidenceInterval : Array; // [lower : double, upper : double]\n}\nexport interface QueryResultAxisItem {\n id: number|string;\n label : string|null\n labelTranslations: any|null; // Object map langKey => translated label :string\n}\n\nexport interface MapFilter {\n id: string;\n centroid: Array; // array of length 2\n envelope: Array; // array of length 4\n // eslint-disable-next-line camelcase\n created_at: string; // datetime string\n // eslint-disable-next-line camelcase\n updated_at: string; // datetime string\n}\n\nexport interface QueryResult {\n axisX : Array;\n axisY : Array;\n\n cells : Array>;\n\n mapFilter: MapFilter|null;\n}\n// Located here and not in API to avoid cyclinc dependency\nexport type ResultQueryPromise = Promise>;\n\nexport interface SentQuery {\n id: number; // sendId set locally to find the query again when result is received\n sentTimestamp : number; // unix timestamp in seconds when query was sent\n serializedQuery: string; // query serialized to string\n result: null|QueryResult; // null => not received response yet\n apiPromise : ResultQueryPromise;\n cancelTokenSource: null|CancelTokenSource; // can be used to cancel the request.\n\n // put any id/ticket received from server here\n}\n\nexport interface QueryStateInterface {\n sentQueries: Array\n lastSendId : number; // id of last added query\n}\n","import { PartialQuery, QueryResult } from '../query/types';\n\nexport enum ResultVisual {\n pieChart = 'pie',\n lineChart = 'line',\n barChart = 'bar',\n horizontalBarChart = 'horizontalBar',\n table = 'table',\n factText = 'fact',\n odMatrix = 'od-matrix',\n // Non-computational types:\n sectionHeading = 'heading',\n}\n\n/** Scales displayed result value */\nexport enum ResultFormatter {\n sToMinutes = 'sToMinutes',\n sToHours = 'sToHours',\n mToKm = 'mToKm',\n decToPercent = 'decToPercent'\n}\n\n/** What unit is the result in */\nexport enum ResultUnit {\n minutes = 'minutes',\n hours = 'hours',\n km = 'km',\n kg = 'kg',\n}\n\nexport interface DataColor {\n bgColor: string;\n textColor: string;\n}\n\n// Optional filter overrides that a result box can specify. This allows\n// a ResultBox to override these filters that otherwise usually is set\n// via Filter store\n//\n// The types should be the same as in FilterStateInterface except for\n// an additional undefined type. When an override is non-undefined\n// it is applied.\n//\n// See FilterStateInterface for documentation of these properties.\nexport interface FilterOverride {\n aggregatedModes: undefined|Array;\n // isCommuteToWork: undefined|boolean|null;\n}\n\nexport interface ResultBox {\n id: number; // unique id of box across result boards\n type: ResultVisual;\n colspan: number; // number of columns that the ResultBox spans. If it is more than remaining columns on current\n // row it will cause a row break.\n label: string; // heading/label of result box\n factTextStr: null|string; // name of string in en.json for text\n // based result with placeholder {value}\n\n // Describes how to format/transform ie. cells[0][0] to the value to include\n // in a fact text or use as y value in a graph.\n valueFormatter : null|ResultFormatter;\n valueDecimals : number;\n valueUnit: null|ResultUnit;\n // null: use getAxisXColor and getAxisYColor default\n // array: an array of colors that is cycled.\n // map: a map from axis id to DataColor\n customPalette: null|Array|any;\n\n // May be null for non-computational ResultVisuals like heading.\n partialQuery : null|PartialQuery;\n filterOverride: FilterOverride;\n\n // todo: size/layout props\n}\n\n/**\n * Represent the result board info.\n */\nexport interface ResultBoardInfo {\n image: string;\n imageLabel: string | null;\n palette: string;\n label: string;\n textCol1: string;\n textCol2: string;\n}\n\n/**\n * Represent the result boxes visible on one result board.\n */\nexport interface ResultBoard {\n id: string;\n labelStr: string; // name of string in en.json\n resultBoxes : Array;\n info: ResultBoardInfo | null; // Add a headerbox to the ResultBoard\n}\n\nexport interface ResultBoardStateInterface {\n resultBoards : Array;\n}\n","/**\n * App flavor for data collection app.\n */\nexport enum AppFlavor {\n travelvu = 'travelvu',\n activeTravel = 'activetravel',\n}\n\n/**\n * Corresponds to Survey model in Yii-server\n */\nexport interface Survey {\n readonly id : number;\n readonly appFlavor : AppFlavor;\n readonly label : string;\n readonly description: string;\n readonly startDate : string|null; // YYYY-MM-DD date\n readonly endDate : string|null; // YYYY-MM-DD date\n readonly hasMapData : boolean; // true => map data is available to this survey.\n participateCountAllTime : number|undefined;\n participateCountAllTimeMinOneCorrDay : number|undefined;\n correctedDayInSurveyCount : number|undefined;\n}\n\n/* Declares the state types */\nexport interface SurveyStateInterface {\n surveyList: Array; // list of data sets available to currently logged in user\n selectedSurvey : number; // index to selected data set in surveyList or -1 for no selection\n}\n","import { Axis } from '@/store/modules/query/types';\nimport i18n from '../i18n';\n\n/**\n * Helper to resolveLabel that reduces the type\n * complexity of i18n.fallbackLocale.\n */\nfunction getFallbackLocale() : string|false {\n const fallbackLocale = i18n.fallbackLocale;\n if (typeof fallbackLocale === 'string') {\n return fallbackLocale;\n } else {\n // We only use string config in our app.\n console.assert(false, 'String i18n fallback config');\n return false;\n }\n}\n\n/**\n * Resolves label text for mixed label from server.\n * The label can either have texts in one or more languages\n * or be a string starting with 'i18n:' following with a local\n * string id for i18n or be a raw text.\n * It is also possible that there exist a map with translations\n * for one or more langKeys.\n * Priority: if both label and labelTranslations is non-null, then\n * label has higher priority.\n * @param label string 'i18n:' or plain text label or null\n * @param labelTranslations map { langKey => translated label } or null.\n */\nexport default function resolveLabel(label : string|null, labelTranslations: any|null) : string {\n // Use plain text label if it is non-null\n if (label !== null) {\n if (label === '') return '';\n\n if (label.startsWith('i18n:')) {\n return i18n.tc(label.substr('i18n:'.length));\n }\n\n return label;\n }\n\n // Else use translations map (if it is non-null)\n if (labelTranslations === null) {\n return '';\n }\n if (labelTranslations[i18n.locale] !== undefined) {\n return labelTranslations[i18n.locale];\n }\n const fallbackLocale = getFallbackLocale();\n if (fallbackLocale !== false && labelTranslations[fallbackLocale] !== undefined) {\n return labelTranslations[fallbackLocale];\n }\n\n // For now beyond selected locale and fallbackLocale there is\n // no hard coded prio order of languages in TravelViewer the\n // same way as in yii-server and the app.\n for (let i = 0; i < i18n.availableLocales.length; i += 1) {\n const langKey = i18n.availableLocales[i];\n if (labelTranslations[langKey] !== undefined) {\n return labelTranslations[langKey];\n }\n }\n\n return '';\n}\n\n/** copy labelTranslations to new JS object */\nexport function copyLabelTranslations(labelTranslations : any|null) : any|null {\n const r : any = {};\n for (let i = 0; i < i18n.availableLocales.length; i += 1) {\n const langKey = i18n.availableLocales[i];\n r[langKey] = labelTranslations[langKey];\n }\n return r;\n}\n\n/**\n * Translate axis (query.axisX or query.axisY)\n *\n * Not all axises have translations and in that case the\n * raw axis is returned.\n *\n * Uses current language\n * @param axis\n * @returns translated string\n */\nexport function axisTranslation(axis : string) {\n if (axis === '\"from zone\"') {\n return i18n.t('axis.from-zone');\n } else if (axis === '\"to zone\"') {\n return i18n.t('axis.to-zone');\n }\n return axis;\n}\n\n/**\n * Get translated label for Query.shareOutput\n * @param shareOutput Query.shareOutput value\n * @returns translated string\n */\nexport function shareOutputLabel(shareOutput : boolean|Axis): string {\n if (shareOutput === Axis.x) {\n return 'x';\n } else if (shareOutput === Axis.y) {\n return 'y';\n } else {\n return shareOutput === true ? i18n.tc('state.on') : i18n.tc('state.off');\n }\n}\n","/**\n * Output date string in format 'YYYY-MM-DD' from a Date object\n * @param dateObj JavaScript Date object\n */\nexport function date2YMDString(dateObj : Date) : string {\n const z = (val : number) => {\n let s = val.toString();\n if (s.length === 1) s = `0${s}`;\n return s;\n };\n if (dateObj == null) return '';\n return `${dateObj.getFullYear()}-${z(dateObj.getMonth() + 1)}-${z(dateObj.getDate())}`; // Months are zero-based in JS\n}\n\n/**\n * Convert date string in format 'YYYY-MM-DD' to a Date object\n * @param dateStr string on format 'YYYY-MM-DD'.\n * @return Date object\n */\nexport function ymdString2date(dateStr : string) : Date|null {\n return new Date(dateStr);\n}\n\n/**\n * Formats given YYYY-MM-DD date string to local date string if\n * date is non-null. If date is null, then nullString is returned\n * instead.\n * @param dateStr date on YYYY-MM-DD format or null\n * @param nullString localized text to display if dateStr is null\n * @param locale this.$i18n.locale\n */\nexport function formatYmdString(dateStr : string|null, nullString : string, locale : string) {\n const dateFormatter = new Intl.DateTimeFormat(locale);\n if (dateStr !== null) {\n const date = ymdString2date(dateStr);\n if (date !== null) {\n return dateFormatter.format(date);\n }\n }\n return nullString;\n}\n\n/**\n * Convert time in seconds since 00:00 to a date object\n * @param time seconds since 00:00\n */\nexport function seconds2date(time : number) : Date {\n const date = new Date();\n date.setHours(0);\n date.setMinutes(0);\n date.setSeconds(time);\n return date;\n}\n\n/**\n * Convert a date from eg. time2date back to seconds since 00:00\n * @param dateObj Date object with hours, minutes and seconds set.\n */\nexport function date2seconds(dateObj : Date) : number {\n return dateObj.getHours() * 3600 + dateObj.getMinutes() * 60 + dateObj.getSeconds();\n}\n\n/**\n * Output time string in format 'HH:MM' from a Date object\n * @param dateObj JavaScript Date object\n * @return string\n */\nexport function date2HMString(dateObj : Date) : string {\n let h = dateObj.getHours().toString();\n let m = dateObj.getMinutes().toString();\n if (h.length < 2) h = `0${h}`;\n if (m.length < 2) m = `0${m}`;\n return `${h}:${m}`;\n}\n\n/**\n * Returns a new date object of the day after dateObj\n * @param dateObj JavaScript Date object\n * @return JavaScript Date object\n */\nexport function dateGetDayAfter(dateObj : Date) : Date {\n const dateCopy = new Date(dateObj);\n dateCopy.setDate(dateCopy.getDate() + 1);\n return dateCopy;\n}\n\n/**\n * Returns a new date object of the day before dateObj\n * @param dateObj JavaScript Date object\n * @return JavaScript Date object\n */\nexport function dateGetDayBefore(dateObj : Date) : Date {\n const dateCopy = new Date(dateObj);\n dateCopy.setDate(dateCopy.getDate() - 1);\n return dateCopy;\n}\n\n/**\n * Returns a new date object of the first day in the\n * current ISO-8601 week (mon-sun) of given date object.\n * @param dateObj JavaScript Date object\n * @return JavaScript Date object of a Monday\n */\nexport function dateGetFirstDayOfWeek(dateObj : Date) : Date {\n const dateCopy = new Date(dateObj);\n let i = 0;\n while (dateCopy.getDay() !== 1) {\n dateCopy.setDate(dateCopy.getDate() - 1);\n\n i += 1;\n if (i > 1000) break;\n }\n return dateCopy;\n}\n\n/**\n * Returns a new date object of the last day in the\n * current ISO-8601 week (mon-sun) of given date object.\n * @param dateObj JavaScript Date object\n * @return JavaScript Date object of a Sunday\n */\nexport function dateGetLastDayOfWeek(dateObj : Date) : Date {\n const dateCopy = new Date(dateObj);\n let i = 0;\n while (dateCopy.getDay() !== 0) {\n dateCopy.setDate(dateCopy.getDate() + 1);\n\n i += 1;\n if (i > 1000) break;\n }\n return dateCopy;\n}\n\n/**\n * Returns date 'YYYY-MM-DD' of the day before for given 'YYYY-MM-DD' date string\n * @param dateStr string on format 'YYYY-MM-DD'.\n * @return string|null\n */\nexport function stringGetDayAfter(dateStr : string) : string|null {\n const d = ymdString2date(dateStr);\n if (d !== null) {\n return date2YMDString(dateGetDayAfter(d));\n }\n\n return null;\n}\n\n/**\n * Returns a new date object of the day before date_obj\n * @param dateStr string on format 'YYYY-MM-DD'.\n * @return string|null\n */\nexport function stringGetDayBefore(dateStr : string) : string|null {\n const d = ymdString2date(dateStr);\n if (d !== null) {\n return date2YMDString(dateGetDayBefore(d));\n }\n\n return null;\n}\n\n/**\n * Returns 'HH:MM (YYYY-MM-DD)' string\n * @param timestamp Unix timestamp in seconds\n */\nexport function timestamp2timeDateStr(timestamp : number) : string {\n const dateObj = new Date(timestamp * 1000);\n return `${date2HMString(dateObj)} (${date2YMDString(dateObj)})`;\n}\n\n/**\n * Returns the current time as unix timestamp in seconds.\n */\nexport function currentTimestamp() : number {\n return Math.floor(((new Date()).getTime()) / 1000);\n}\n\n/**\n * Return the delta time in seconds to add to UTC time in order to get\n * what the clock was in local time according to the timezone of the browser.\n */\nexport function currentTzDeltaMin() : number {\n // value (in seconds) to add to UTC time to get local time\n return -(new Date()).getTimezoneOffset();\n}\n","/**\n * Checks if user has access to given feature\n * @param feature Feature id\n * @returns true if user has access\n */\nexport default function hasFeature(feature: string): boolean {\n const params = new URLSearchParams(window.location.search.toLowerCase());\n return params.get(`unlock${feature.toLowerCase()}`) !== null;\n}\n","/**\n * Drop in replacement to console class\n * that only enable log if VUE_APP_ENABLE_LOG\n * is set to 1 in .env\n */\nexport default class Log {\n /* eslint no-console: [\"off\", {}}] */\n\n /** Check if log is enabled */\n public static isLogEnabled() : boolean {\n return process.env.VUE_APP_ENABLE_LOG === '1';\n }\n\n public static log(...args: any[]) : void {\n if (Log.isLogEnabled()) {\n console.log(...args);\n }\n }\n\n public static warn(...args: any[]) : void {\n if (Log.isLogEnabled()) {\n console.warn(...args);\n }\n }\n\n public static error(...args: any[]) : void {\n if (Log.isLogEnabled()) {\n console.error(...args);\n }\n }\n\n public static time(...args: any[]) : void {\n if (Log.isLogEnabled()) {\n console.time(...args);\n }\n }\n\n public static timeEnd(...args: any[]) : void {\n if (Log.isLogEnabled()) {\n console.timeEnd(...args);\n }\n }\n}\n","import i18n from '@/i18n';\nimport {\n Activity, AggregatedActivity, AggregatedMode, Mode,\n} from '@/store/modules/mode-activity/types';\nimport { copyLabelTranslations } from './I18nLabel';\nimport palette from './palette';\n\n/**\n * Get mode by id\n * @param id Mode id\n * @return Mode or null if mode was not found\n */\nfunction getMode(id : string, modes:Array) : Mode|null {\n const mode = modes.find((m : Mode) => m.id === id);\n if (mode === undefined) return null;\n return mode;\n}\n\n/**\n * Get activity by id\n * @param id Activity id\n * @return Activity or null if activity was not found\n */\nfunction getActivity(id : string, activities:Array) : Activity|null {\n const activity = activities.find((a : Activity) => a.id === id);\n if (activity === undefined) return null;\n return activity;\n}\n\n/**\n * Get labelTranslations object by looking up\n * given string in app locale strings.\n * @param strId\n * @return object that maps from locale to translation\n */\nfunction getTranslations(strId : string) : any {\n const r : any = {};\n i18n.availableLocales.forEach((locale: string) => {\n r[locale] = i18n.t(strId, locale);\n });\n return r;\n}\n\n/** Creates a aggregate setup that just 1:1 mirrors available modes */\nexport function getNoAggregateModes(modes : Array) : Array {\n const aggregatedModes = modes\n .filter((m : Mode) => m.inSurvey)\n .map((m : Mode) : AggregatedMode => {\n const mode = {\n id: 0,\n order: m.order,\n labelTranslations: copyLabelTranslations(m.labelTranslations),\n bgColor: m.bgColor,\n textColor: m.textColor,\n borderColor: m.borderColor,\n svgIconBgColor: m.svgIconBgColor,\n svgIconBlack: m.svgIconBlack,\n modeList: [m.id],\n };\n if (m.id === 'OTHR') {\n mode.modeList.push(\n ...modes.filter((m2 : Mode) => !m2.inSurvey).map((m2 : Mode) => m2.id),\n );\n }\n return mode;\n });\n\n // assign some ids\n for (let i = 0; i < aggregatedModes.length; i += 1) {\n aggregatedModes[i].id = i;\n }\n\n // sort by order\n aggregatedModes.sort((a, b) => a.order - b.order);\n\n return aggregatedModes;\n}\n\n/** Creates a aggregate setup that just 1:1 mirrors available activities */\nexport function getNoAggregateActivities(activities : Array) : Array {\n const aggregatedActivities = activities\n .filter((a : Activity) => a.inSurvey)\n .map((a : Activity) : AggregatedActivity => {\n const activity = {\n id: 0,\n order: a.order,\n labelTranslations: copyLabelTranslations(a.labelTranslations),\n svgIconBgColor: a.svgIconBgColor,\n svgIconBlack: a.svgIconBlack,\n activityList: [a.id],\n };\n if (a.id === 'OTHR') {\n activity.activityList.push(\n ...activities.filter((a2 : Activity) => !a2.inSurvey)\n .map((a2 : Activity) => a2.id),\n );\n }\n return activity;\n });\n\n // assign some ids\n for (let i = 0; i < aggregatedActivities.length; i += 1) {\n aggregatedActivities[i].id = i;\n }\n\n // sort by order\n aggregatedActivities.sort((a, b) => a.order - b.order);\n\n return aggregatedActivities;\n}\n\n/** A aggregate with a few main modes */\nexport function getMainAggregateModes(modes: Array) : Array {\n const car = getMode('CAR_', modes);\n const walk = getMode('WALK', modes);\n const bike = getMode('BIKE', modes);\n const exercice = getMode('EXRC', modes);\n const air = getMode('AIR_', modes);\n const other = getMode('OTHR', modes);\n\n /* eslint quote-props: \"off\" */\n const aggregatedModes = [\n {\n id: 0,\n order: 0,\n labelTranslations: walk !== null\n ? copyLabelTranslations(walk.labelTranslations)\n : { 'en': 'Walk' },\n bgColor: palette[3], // walk green\n textColor: palette['3a'],\n borderColor: palette['3c'],\n svgIconBgColor: '',\n svgIconBlack: '',\n modeList: ['WALK'],\n },\n {\n id: 1,\n order: 1,\n labelTranslations: exercice !== null\n ? copyLabelTranslations(exercice.labelTranslations)\n : { 'en': 'Exercise and recreation' },\n bgColor: exercice !== null ? exercice.bgColor : palette[4],\n textColor: exercice !== null ? exercice.textColor : palette['4a'],\n borderColor: exercice !== null ? exercice.borderColor : palette['4c'],\n svgIconBgColor: '',\n svgIconBlack: '',\n modeList: ['EXRC'],\n },\n {\n id: 2,\n order: 2,\n labelTranslations: bike !== null\n ? copyLabelTranslations(bike.labelTranslations)\n : { 'en': 'Bicycle' },\n bgColor: palette[5], // yellow-orange\n textColor: palette['5a'],\n borderColor: palette['5c'],\n svgIconBgColor: '',\n svgIconBlack: '',\n modeList: ['BIKE', 'EBKE', 'CBKE', 'SBIK'],\n },\n {\n id: 3,\n order: 3,\n labelTranslations: getTranslations('aggregated-mode.public-transport'),\n bgColor: palette[1], // blue (same as metro/tram)\n textColor: palette['1a'],\n borderColor: palette['1c'],\n svgIconBgColor: '',\n svgIconBlack: '',\n modeList: ['BUS_', 'METR', 'TRAM', 'TRN_', 'CTRN', 'CABE', 'CBUS'],\n },\n {\n id: 4,\n order: 4,\n labelTranslations: car !== null\n ? copyLabelTranslations(car.labelTranslations)\n : { 'en': 'Car' },\n bgColor: palette[4], // magenta\n textColor: palette['4a'],\n borderColor: palette['4c'],\n svgIconBgColor: '',\n svgIconBlack: '',\n modeList: [\n 'CAR_', 'ECAR', 'NCAR', 'PCAR', 'BCAR', 'SCAR', 'CARD', 'CARP', 'ECRD', 'ECRP', 'NCRD', 'NCRP', 'RCAR',\n ],\n },\n {\n id: 5,\n order: 5,\n labelTranslations: air !== null\n ? copyLabelTranslations(air.labelTranslations)\n : { 'en': 'Airplane' },\n bgColor: palette['2b'],\n textColor: palette['2c'],\n borderColor: palette['2a'],\n svgIconBgColor: '',\n svgIconBlack: '',\n modeList: ['AIR_'],\n },\n // This need to be last in order to have all remaining modes added to modeList\n {\n id: 6,\n order: 6,\n labelTranslations: other !== null\n ? copyLabelTranslations(other.labelTranslations)\n : { 'en': 'Other' },\n bgColor: palette[2], // purple\n textColor: palette['2a'],\n borderColor: palette['2c'],\n svgIconBgColor: '',\n svgIconBlack: '',\n modeList: [],\n },\n ];\n // Add all unused modes to Other aggregated mode\n let usedModes : Array = [];\n aggregatedModes.forEach((am : AggregatedMode) => {\n usedModes = usedModes.concat(am.modeList);\n });\n modes.forEach((m : Mode) => {\n if (usedModes.indexOf(m.id) === -1) {\n aggregatedModes[aggregatedModes.length - 1].modeList.push(m.id);\n }\n });\n\n return aggregatedModes;\n}\n\n/** A aggregate with a few main activities */\nexport function getMainAggregateActivities(activities: Array) : Array {\n const work = getActivity('WORK', activities);\n const shop = getActivity('SHOP', activities);\n const edu = getActivity('EDU_', activities);\n const home = getActivity('HOME', activities);\n const other = getActivity('OTHR', activities);\n\n /* eslint quote-props: \"off\" */\n const aggregatedActivities = [\n {\n id: 0,\n order: 0,\n labelTranslations: work !== null\n ? copyLabelTranslations(work.labelTranslations)\n : { 'en': 'Work' },\n svgIconBgColor: '',\n svgIconBlack: '',\n activityList: ['WORK', 'BSTR'],\n },\n {\n id: 1,\n order: 1,\n labelTranslations: edu !== null\n ? copyLabelTranslations(edu.labelTranslations)\n : { 'en': 'Education' },\n svgIconBgColor: '',\n svgIconBlack: '',\n activityList: ['EDU_'],\n },\n {\n id: 2,\n order: 2,\n labelTranslations: shop !== null\n ? copyLabelTranslations(shop.labelTranslations)\n : { 'en': 'Shopping' },\n svgIconBgColor: '',\n svgIconBlack: '',\n activityList: ['SHOP', 'SHOG', 'SHOO'],\n },\n {\n id: 3,\n order: 3,\n labelTranslations: getTranslations('aggregated-activity.service'),\n svgIconBgColor: '',\n svgIconBlack: '',\n activityList: ['OSRV', 'HEAL', 'CHIL', 'PICC', 'PICO', 'PICG', 'PICD', 'RECY'],\n },\n {\n id: 4,\n order: 4,\n labelTranslations: getTranslations('aggregated-activity.leisure'),\n svgIconBgColor: '',\n svgIconBlack: '',\n activityList: ['ENTE', 'HOBY', 'REST', 'RUN_', 'VIST'],\n },\n {\n id: 5,\n order: 5,\n labelTranslations: home !== null\n ? copyLabelTranslations(home.labelTranslations)\n : { 'en': 'Home' },\n svgIconBgColor: '',\n svgIconBlack: '',\n activityList: ['HOME', 'SLEP'],\n },\n // This need to be last in order to have all remaining activities added to modeList\n {\n id: 6,\n order: 6,\n labelTranslations: other !== null\n ? copyLabelTranslations(other.labelTranslations)\n : { 'en': 'Other' },\n svgIconBgColor: '',\n svgIconBlack: '',\n activityList: [],\n },\n ];\n // Add all unused modes to Other aggregated activity\n let usedActivities : Array = [];\n aggregatedActivities.forEach((aa : AggregatedActivity) => {\n usedActivities = usedActivities.concat(aa.activityList);\n });\n activities.forEach((a : Activity) => {\n if (usedActivities.indexOf(a.id) === -1) {\n aggregatedActivities[aggregatedActivities.length - 1].activityList.push(a.id);\n }\n });\n\n return aggregatedActivities;\n}\n\n/**\n * Return list of aggregated mode ids that represent the given list of modes.\n *\n * @param aggregatedModes aggregated modes config\n * @param searchList array of mode ids to search for\n * @param requireFullMatch If true, the found aggregated modes must only\n * contain modes in searchList. If there are an aggregated mode which mixed\n * content, this method will fail and return an empty list.\n */\nexport function getAggregatesForModes(\n aggregatedModes: Array,\n searchList: Array,\n requireFullMatch: boolean,\n) : Array {\n const result: Array = [];\n let fullMatch = true;\n aggregatedModes.forEach((am) => {\n const nActive = am.modeList.reduce(\n (n, curr) => n + (searchList.includes(curr) ? 1 : 0),\n 0,\n );\n if (requireFullMatch\n ? nActive === am.modeList.length\n : nActive > 0) {\n result.push(am.id);\n } else if (nActive !== 0) {\n fullMatch = false;\n }\n });\n if (requireFullMatch && !fullMatch) {\n return [];\n }\n return result;\n}\n\n/**\n * Return list of aggregated mode ids that represent active modes of transport.\n *\n * If it is the case that there are aggregarted modes that contain a mix of active\n * and non-active modes of transport, then this method will fail and return an empty list.\n */\nexport function getActiveTransportAggregatedModes(aggregatedModes: Array) : Array {\n const activeModes = ['WALK', 'EXRC', 'BIKE', 'EBKE', 'CBKE', 'SBIK'];\n return getAggregatesForModes(aggregatedModes, activeModes, true);\n}\n\n/**\n * Return list of aggregated mode ids that consist of modes that emit emissions\n */\nexport function getEmissionAggregatedModes(aggregatedModes: Array) : Array {\n const emisisonModes = ['CAR_', 'BUS_', 'AIR_'];\n return getAggregatesForModes(aggregatedModes, emisisonModes, false);\n}\n","/* eslint quote-props: [\"off\", {}}] */\n/* eslint key-spacing: [\"off\", {}}] */\n/* eslint object-property-newline: [\"off\", {}}] */\n/* eslint max-len: [\"off\", {}}] */\n\n/**\n * The graph needs colors in JS. this palette should have same colors as the\n * palette in _variables.scss\n */\nexport default {\n '1': '#3961FF', '1a': '#071756', '1b': '#203EB3', '1c': '#93A9FD', '1d': '#D3DCFF',\n '2': '#BB7DDD', '2a': '#49076E', '2b': '#7A2DA4', '2c': '#E3AFFF', '2d': '#F0D5FF',\n '3': '#63C8A0', '3a': '#004027', '3b': '#229567', '3c': '#8AEEC6', '3d': '#C2FFE7',\n '4': '#F56B92', '4a': '#850328', '4b': '#C72E59', '4c': '#FFA4BE', '4d': '#FFD7E2',\n '5': '#F6914E', '5a': '#A74402', '5b': '#D96C23', '5c': '#FFB27F', '5d': '#FFD7BC',\n 'grey': '#C3C8D6', 'grey-a': '#18191E', 'grey-b': '#545B6F', 'grey-c': '#A0A4B0', 'grey-d': '#E9EAEE',\n\n 'black': '#18191E',\n 'white': '#ffffff',\n};\n","/** await compatible wrapper around setTimeout */\nexport default async function timeout(ms : number) {\n return new Promise((resolve) => {\n setTimeout(resolve, ms);\n });\n}\n","var map = {\n\t\"./af\": 52496,\n\t\"./af.js\": 52496,\n\t\"./ar\": 70186,\n\t\"./ar-dz\": 46881,\n\t\"./ar-dz.js\": 46881,\n\t\"./ar-kw\": 16265,\n\t\"./ar-kw.js\": 16265,\n\t\"./ar-ly\": 40451,\n\t\"./ar-ly.js\": 40451,\n\t\"./ar-ma\": 68625,\n\t\"./ar-ma.js\": 68625,\n\t\"./ar-sa\": 88819,\n\t\"./ar-sa.js\": 88819,\n\t\"./ar-tn\": 87092,\n\t\"./ar-tn.js\": 87092,\n\t\"./ar.js\": 70186,\n\t\"./az\": 44421,\n\t\"./az.js\": 44421,\n\t\"./be\": 17067,\n\t\"./be.js\": 17067,\n\t\"./bg\": 43871,\n\t\"./bg.js\": 43871,\n\t\"./bm\": 54242,\n\t\"./bm.js\": 54242,\n\t\"./bn\": 8189,\n\t\"./bn-bd\": 82507,\n\t\"./bn-bd.js\": 82507,\n\t\"./bn.js\": 8189,\n\t\"./bo\": 5799,\n\t\"./bo.js\": 5799,\n\t\"./br\": 97803,\n\t\"./br.js\": 97803,\n\t\"./bs\": 78434,\n\t\"./bs.js\": 78434,\n\t\"./ca\": 14581,\n\t\"./ca.js\": 14581,\n\t\"./cs\": 38004,\n\t\"./cs.js\": 38004,\n\t\"./cv\": 14464,\n\t\"./cv.js\": 14464,\n\t\"./cy\": 60163,\n\t\"./cy.js\": 60163,\n\t\"./da\": 80803,\n\t\"./da.js\": 80803,\n\t\"./de\": 60233,\n\t\"./de-at\": 57607,\n\t\"./de-at.js\": 57607,\n\t\"./de-ch\": 86777,\n\t\"./de-ch.js\": 86777,\n\t\"./de.js\": 60233,\n\t\"./dv\": 66969,\n\t\"./dv.js\": 66969,\n\t\"./el\": 59618,\n\t\"./el.js\": 59618,\n\t\"./en-au\": 9245,\n\t\"./en-au.js\": 9245,\n\t\"./en-ca\": 45036,\n\t\"./en-ca.js\": 45036,\n\t\"./en-gb\": 31438,\n\t\"./en-gb.js\": 31438,\n\t\"./en-ie\": 26053,\n\t\"./en-ie.js\": 26053,\n\t\"./en-il\": 10134,\n\t\"./en-il.js\": 10134,\n\t\"./en-in\": 847,\n\t\"./en-in.js\": 847,\n\t\"./en-nz\": 1363,\n\t\"./en-nz.js\": 1363,\n\t\"./en-sg\": 59022,\n\t\"./en-sg.js\": 59022,\n\t\"./eo\": 58990,\n\t\"./eo.js\": 58990,\n\t\"./es\": 79817,\n\t\"./es-do\": 78155,\n\t\"./es-do.js\": 78155,\n\t\"./es-mx\": 80952,\n\t\"./es-mx.js\": 80952,\n\t\"./es-us\": 39358,\n\t\"./es-us.js\": 39358,\n\t\"./es.js\": 79817,\n\t\"./et\": 25396,\n\t\"./et.js\": 25396,\n\t\"./eu\": 24338,\n\t\"./eu.js\": 24338,\n\t\"./fa\": 77030,\n\t\"./fa.js\": 77030,\n\t\"./fi\": 72292,\n\t\"./fi.js\": 72292,\n\t\"./fil\": 13578,\n\t\"./fil.js\": 13578,\n\t\"./fo\": 8900,\n\t\"./fo.js\": 8900,\n\t\"./fr\": 26067,\n\t\"./fr-ca\": 8362,\n\t\"./fr-ca.js\": 8362,\n\t\"./fr-ch\": 99404,\n\t\"./fr-ch.js\": 99404,\n\t\"./fr.js\": 26067,\n\t\"./fy\": 46742,\n\t\"./fy.js\": 46742,\n\t\"./ga\": 8152,\n\t\"./ga.js\": 8152,\n\t\"./gd\": 6920,\n\t\"./gd.js\": 6920,\n\t\"./gl\": 37234,\n\t\"./gl.js\": 37234,\n\t\"./gom-deva\": 23578,\n\t\"./gom-deva.js\": 23578,\n\t\"./gom-latn\": 97054,\n\t\"./gom-latn.js\": 97054,\n\t\"./gu\": 28166,\n\t\"./gu.js\": 28166,\n\t\"./he\": 88927,\n\t\"./he.js\": 88927,\n\t\"./hi\": 12153,\n\t\"./hi.js\": 12153,\n\t\"./hr\": 39329,\n\t\"./hr.js\": 39329,\n\t\"./hu\": 32782,\n\t\"./hu.js\": 32782,\n\t\"./hy-am\": 85023,\n\t\"./hy-am.js\": 85023,\n\t\"./id\": 96655,\n\t\"./id.js\": 96655,\n\t\"./is\": 20000,\n\t\"./is.js\": 20000,\n\t\"./it\": 75107,\n\t\"./it-ch\": 13045,\n\t\"./it-ch.js\": 13045,\n\t\"./it.js\": 75107,\n\t\"./ja\": 99175,\n\t\"./ja.js\": 99175,\n\t\"./jv\": 74853,\n\t\"./jv.js\": 74853,\n\t\"./ka\": 68684,\n\t\"./ka.js\": 68684,\n\t\"./kk\": 60312,\n\t\"./kk.js\": 60312,\n\t\"./km\": 91271,\n\t\"./km.js\": 91271,\n\t\"./kn\": 67256,\n\t\"./kn.js\": 67256,\n\t\"./ko\": 14833,\n\t\"./ko.js\": 14833,\n\t\"./ku\": 45258,\n\t\"./ku.js\": 45258,\n\t\"./ky\": 73430,\n\t\"./ky.js\": 73430,\n\t\"./lb\": 97665,\n\t\"./lb.js\": 97665,\n\t\"./lo\": 2238,\n\t\"./lo.js\": 2238,\n\t\"./lt\": 50920,\n\t\"./lt.js\": 50920,\n\t\"./lv\": 28769,\n\t\"./lv.js\": 28769,\n\t\"./me\": 10818,\n\t\"./me.js\": 10818,\n\t\"./mi\": 15722,\n\t\"./mi.js\": 15722,\n\t\"./mk\": 17117,\n\t\"./mk.js\": 17117,\n\t\"./ml\": 69904,\n\t\"./ml.js\": 69904,\n\t\"./mn\": 8590,\n\t\"./mn.js\": 8590,\n\t\"./mr\": 29544,\n\t\"./mr.js\": 29544,\n\t\"./ms\": 40176,\n\t\"./ms-my\": 28850,\n\t\"./ms-my.js\": 28850,\n\t\"./ms.js\": 40176,\n\t\"./mt\": 70291,\n\t\"./mt.js\": 70291,\n\t\"./my\": 64830,\n\t\"./my.js\": 64830,\n\t\"./nb\": 4893,\n\t\"./nb.js\": 4893,\n\t\"./ne\": 8782,\n\t\"./ne.js\": 8782,\n\t\"./nl\": 38337,\n\t\"./nl-be\": 62297,\n\t\"./nl-be.js\": 62297,\n\t\"./nl.js\": 38337,\n\t\"./nn\": 58272,\n\t\"./nn.js\": 58272,\n\t\"./oc-lnc\": 50277,\n\t\"./oc-lnc.js\": 50277,\n\t\"./pa-in\": 6198,\n\t\"./pa-in.js\": 6198,\n\t\"./pl\": 35231,\n\t\"./pl.js\": 35231,\n\t\"./pt\": 93141,\n\t\"./pt-br\": 19626,\n\t\"./pt-br.js\": 19626,\n\t\"./pt.js\": 93141,\n\t\"./ro\": 42797,\n\t\"./ro.js\": 42797,\n\t\"./ru\": 30048,\n\t\"./ru.js\": 30048,\n\t\"./sd\": 60023,\n\t\"./sd.js\": 60023,\n\t\"./se\": 7339,\n\t\"./se.js\": 7339,\n\t\"./si\": 72851,\n\t\"./si.js\": 72851,\n\t\"./sk\": 89764,\n\t\"./sk.js\": 89764,\n\t\"./sl\": 40646,\n\t\"./sl.js\": 40646,\n\t\"./sq\": 81751,\n\t\"./sq.js\": 81751,\n\t\"./sr\": 79016,\n\t\"./sr-cyrl\": 31368,\n\t\"./sr-cyrl.js\": 31368,\n\t\"./sr.js\": 79016,\n\t\"./ss\": 21943,\n\t\"./ss.js\": 21943,\n\t\"./sv\": 91751,\n\t\"./sv.js\": 91751,\n\t\"./sw\": 46014,\n\t\"./sw.js\": 46014,\n\t\"./ta\": 21571,\n\t\"./ta.js\": 21571,\n\t\"./te\": 24819,\n\t\"./te.js\": 24819,\n\t\"./tet\": 78646,\n\t\"./tet.js\": 78646,\n\t\"./tg\": 38641,\n\t\"./tg.js\": 38641,\n\t\"./th\": 25714,\n\t\"./th.js\": 25714,\n\t\"./tk\": 57082,\n\t\"./tk.js\": 57082,\n\t\"./tl-ph\": 39830,\n\t\"./tl-ph.js\": 39830,\n\t\"./tlh\": 38757,\n\t\"./tlh.js\": 38757,\n\t\"./tr\": 3571,\n\t\"./tr.js\": 3571,\n\t\"./tzl\": 6785,\n\t\"./tzl.js\": 6785,\n\t\"./tzm\": 44924,\n\t\"./tzm-latn\": 59126,\n\t\"./tzm-latn.js\": 59126,\n\t\"./tzm.js\": 44924,\n\t\"./ug-cn\": 52134,\n\t\"./ug-cn.js\": 52134,\n\t\"./uk\": 63350,\n\t\"./uk.js\": 63350,\n\t\"./ur\": 83397,\n\t\"./ur.js\": 83397,\n\t\"./uz\": 88556,\n\t\"./uz-latn\": 93562,\n\t\"./uz-latn.js\": 93562,\n\t\"./uz.js\": 88556,\n\t\"./vi\": 27751,\n\t\"./vi.js\": 27751,\n\t\"./x-pseudo\": 61505,\n\t\"./x-pseudo.js\": 61505,\n\t\"./yo\": 95943,\n\t\"./yo.js\": 95943,\n\t\"./zh-cn\": 74186,\n\t\"./zh-cn.js\": 74186,\n\t\"./zh-hk\": 2243,\n\t\"./zh-hk.js\": 2243,\n\t\"./zh-mo\": 5437,\n\t\"./zh-mo.js\": 5437,\n\t\"./zh-tw\": 33843,\n\t\"./zh-tw.js\": 33843\n};\n\n\nfunction webpackContext(req) {\n\tvar id = webpackContextResolve(req);\n\treturn __webpack_require__(id);\n}\nfunction webpackContextResolve(req) {\n\tif(!__webpack_require__.o(map, req)) {\n\t\tvar e = new Error(\"Cannot find module '\" + req + \"'\");\n\t\te.code = 'MODULE_NOT_FOUND';\n\t\tthrow e;\n\t}\n\treturn map[req];\n}\nwebpackContext.keys = function webpackContextKeys() {\n\treturn Object.keys(map);\n};\nwebpackContext.resolve = webpackContextResolve;\nmodule.exports = webpackContext;\nwebpackContext.id = 46700;","var map = {\n\t\"./da.json\": 85638,\n\t\"./de.json\": 39929,\n\t\"./en.json\": 20790,\n\t\"./fr.json\": 844,\n\t\"./it.json\": 20504,\n\t\"./no.json\": 80438,\n\t\"./sv.json\": 93244\n};\n\n\nfunction webpackContext(req) {\n\tvar id = webpackContextResolve(req);\n\treturn __webpack_require__(id);\n}\nfunction webpackContextResolve(req) {\n\tif(!__webpack_require__.o(map, req)) {\n\t\tvar e = new Error(\"Cannot find module '\" + req + \"'\");\n\t\te.code = 'MODULE_NOT_FOUND';\n\t\tthrow e;\n\t}\n\treturn map[req];\n}\nwebpackContext.keys = function webpackContextKeys() {\n\treturn Object.keys(map);\n};\nwebpackContext.resolve = webpackContextResolve;\nmodule.exports = webpackContext;\nwebpackContext.id = 23251;","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\tloaded: false,\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Flag the module as loaded\n\tmodule.loaded = true;\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = function(result, chunkIds, fn, priority) {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar chunkIds = deferred[i][0];\n\t\tvar fn = deferred[i][1];\n\t\tvar priority = deferred[i][2];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every(function(key) { return __webpack_require__.O[key](chunkIds[j]); })) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = function(chunkId) {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce(function(promises, key) {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks\n__webpack_require__.u = function(chunkId) {\n\t// return url for filenames based on template\n\treturn \"js/\" + ({\"148\":\"sample\",\"177\":\"home\",\"237\":\"analysis\",\"273\":\"user-profile\",\"504\":\"edit-sample-variables\",\"535\":\"login\",\"551\":\"support\",\"587\":\"weighting\",\"999\":\"survey\"}[chunkId] || chunkId) + \"-legacy.\" + {\"24\":\"08c6d330\",\"148\":\"41fe94c1\",\"177\":\"eabf5e3d\",\"237\":\"6831372e\",\"273\":\"99c07e33\",\"504\":\"4fba87fa\",\"535\":\"b159817d\",\"551\":\"19881891\",\"587\":\"8a26b424\",\"831\":\"0b74e158\",\"999\":\"0257e118\"}[chunkId] + \".js\";\n};","// This function allow to reference async chunks\n__webpack_require__.miniCssF = function(chunkId) {\n\t// return url for filenames based on template\n\treturn \"css/\" + {\"148\":\"sample\",\"177\":\"home\",\"237\":\"analysis\",\"273\":\"user-profile\",\"504\":\"edit-sample-variables\",\"535\":\"login\",\"551\":\"support\",\"587\":\"weighting\",\"999\":\"survey\"}[chunkId] + \".\" + {\"148\":\"8b6c5f63\",\"177\":\"4d5a3e27\",\"237\":\"f7378101\",\"273\":\"e078261e\",\"504\":\"15e7030b\",\"535\":\"7dd455bf\",\"551\":\"6d5650b3\",\"587\":\"8b6c5f63\",\"999\":\"69775b4f\"}[chunkId] + \".css\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","var inProgress = {};\nvar dataWebpackPrefix = \"travelviewer-ui:\";\n// loadScript function to load a script via script tag\n__webpack_require__.l = function(url, done, key, chunkId) {\n\tif(inProgress[url]) { inProgress[url].push(done); return; }\n\tvar script, needAttach;\n\tif(key !== undefined) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tfor(var i = 0; i < scripts.length; i++) {\n\t\t\tvar s = scripts[i];\n\t\t\tif(s.getAttribute(\"src\") == url || s.getAttribute(\"data-webpack\") == dataWebpackPrefix + key) { script = s; break; }\n\t\t}\n\t}\n\tif(!script) {\n\t\tneedAttach = true;\n\t\tscript = document.createElement('script');\n\n\t\tscript.charset = 'utf-8';\n\t\tscript.timeout = 120;\n\t\tif (__webpack_require__.nc) {\n\t\t\tscript.setAttribute(\"nonce\", __webpack_require__.nc);\n\t\t}\n\t\tscript.setAttribute(\"data-webpack\", dataWebpackPrefix + key);\n\t\tscript.src = url;\n\t}\n\tinProgress[url] = [done];\n\tvar onScriptComplete = function(prev, event) {\n\t\t// avoid mem leaks in IE.\n\t\tscript.onerror = script.onload = null;\n\t\tclearTimeout(timeout);\n\t\tvar doneFns = inProgress[url];\n\t\tdelete inProgress[url];\n\t\tscript.parentNode && script.parentNode.removeChild(script);\n\t\tdoneFns && doneFns.forEach(function(fn) { return fn(event); });\n\t\tif(prev) return prev(event);\n\t}\n\tvar timeout = setTimeout(onScriptComplete.bind(null, undefined, { type: 'timeout', target: script }), 120000);\n\tscript.onerror = onScriptComplete.bind(null, script.onerror);\n\tscript.onload = onScriptComplete.bind(null, script.onload);\n\tneedAttach && document.head.appendChild(script);\n};","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","__webpack_require__.nmd = function(module) {\n\tmodule.paths = [];\n\tif (!module.children) module.children = [];\n\treturn module;\n};","__webpack_require__.p = \"\";","if (typeof document === \"undefined\") return;\nvar createStylesheet = function(chunkId, fullhref, oldTag, resolve, reject) {\n\tvar linkTag = document.createElement(\"link\");\n\n\tlinkTag.rel = \"stylesheet\";\n\tlinkTag.type = \"text/css\";\n\tvar onLinkComplete = function(event) {\n\t\t// avoid mem leaks.\n\t\tlinkTag.onerror = linkTag.onload = null;\n\t\tif (event.type === 'load') {\n\t\t\tresolve();\n\t\t} else {\n\t\t\tvar errorType = event && (event.type === 'load' ? 'missing' : event.type);\n\t\t\tvar realHref = event && event.target && event.target.href || fullhref;\n\t\t\tvar err = new Error(\"Loading CSS chunk \" + chunkId + \" failed.\\n(\" + realHref + \")\");\n\t\t\terr.code = \"CSS_CHUNK_LOAD_FAILED\";\n\t\t\terr.type = errorType;\n\t\t\terr.request = realHref;\n\t\t\tif (linkTag.parentNode) linkTag.parentNode.removeChild(linkTag)\n\t\t\treject(err);\n\t\t}\n\t}\n\tlinkTag.onerror = linkTag.onload = onLinkComplete;\n\tlinkTag.href = fullhref;\n\n\tif (oldTag) {\n\t\toldTag.parentNode.insertBefore(linkTag, oldTag.nextSibling);\n\t} else {\n\t\tdocument.head.appendChild(linkTag);\n\t}\n\treturn linkTag;\n};\nvar findStylesheet = function(href, fullhref) {\n\tvar existingLinkTags = document.getElementsByTagName(\"link\");\n\tfor(var i = 0; i < existingLinkTags.length; i++) {\n\t\tvar tag = existingLinkTags[i];\n\t\tvar dataHref = tag.getAttribute(\"data-href\") || tag.getAttribute(\"href\");\n\t\tif(tag.rel === \"stylesheet\" && (dataHref === href || dataHref === fullhref)) return tag;\n\t}\n\tvar existingStyleTags = document.getElementsByTagName(\"style\");\n\tfor(var i = 0; i < existingStyleTags.length; i++) {\n\t\tvar tag = existingStyleTags[i];\n\t\tvar dataHref = tag.getAttribute(\"data-href\");\n\t\tif(dataHref === href || dataHref === fullhref) return tag;\n\t}\n};\nvar loadStylesheet = function(chunkId) {\n\treturn new Promise(function(resolve, reject) {\n\t\tvar href = __webpack_require__.miniCssF(chunkId);\n\t\tvar fullhref = __webpack_require__.p + href;\n\t\tif(findStylesheet(href, fullhref)) return resolve();\n\t\tcreateStylesheet(chunkId, fullhref, null, resolve, reject);\n\t});\n}\n// object to store loaded CSS chunks\nvar installedCssChunks = {\n\t143: 0\n};\n\n__webpack_require__.f.miniCss = function(chunkId, promises) {\n\tvar cssChunks = {\"148\":1,\"177\":1,\"237\":1,\"273\":1,\"504\":1,\"535\":1,\"551\":1,\"587\":1,\"999\":1};\n\tif(installedCssChunks[chunkId]) promises.push(installedCssChunks[chunkId]);\n\telse if(installedCssChunks[chunkId] !== 0 && cssChunks[chunkId]) {\n\t\tpromises.push(installedCssChunks[chunkId] = loadStylesheet(chunkId).then(function() {\n\t\t\tinstalledCssChunks[chunkId] = 0;\n\t\t}, function(e) {\n\t\t\tdelete installedCssChunks[chunkId];\n\t\t\tthrow e;\n\t\t}));\n\t}\n};\n\n// no hmr","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t143: 0\n};\n\n__webpack_require__.f.j = function(chunkId, promises) {\n\t\t// JSONP chunk loading for javascript\n\t\tvar installedChunkData = __webpack_require__.o(installedChunks, chunkId) ? installedChunks[chunkId] : undefined;\n\t\tif(installedChunkData !== 0) { // 0 means \"already installed\".\n\n\t\t\t// a Promise means \"currently loading\".\n\t\t\tif(installedChunkData) {\n\t\t\t\tpromises.push(installedChunkData[2]);\n\t\t\t} else {\n\t\t\t\tif(true) { // all chunks have JS\n\t\t\t\t\t// setup Promise in chunk cache\n\t\t\t\t\tvar promise = new Promise(function(resolve, reject) { installedChunkData = installedChunks[chunkId] = [resolve, reject]; });\n\t\t\t\t\tpromises.push(installedChunkData[2] = promise);\n\n\t\t\t\t\t// start chunk loading\n\t\t\t\t\tvar url = __webpack_require__.p + __webpack_require__.u(chunkId);\n\t\t\t\t\t// create error before stack unwound to get useful stacktrace later\n\t\t\t\t\tvar error = new Error();\n\t\t\t\t\tvar loadingEnded = function(event) {\n\t\t\t\t\t\tif(__webpack_require__.o(installedChunks, chunkId)) {\n\t\t\t\t\t\t\tinstalledChunkData = installedChunks[chunkId];\n\t\t\t\t\t\t\tif(installedChunkData !== 0) installedChunks[chunkId] = undefined;\n\t\t\t\t\t\t\tif(installedChunkData) {\n\t\t\t\t\t\t\t\tvar errorType = event && (event.type === 'load' ? 'missing' : event.type);\n\t\t\t\t\t\t\t\tvar realSrc = event && event.target && event.target.src;\n\t\t\t\t\t\t\t\terror.message = 'Loading chunk ' + chunkId + ' failed.\\n(' + errorType + ': ' + realSrc + ')';\n\t\t\t\t\t\t\t\terror.name = 'ChunkLoadError';\n\t\t\t\t\t\t\t\terror.type = errorType;\n\t\t\t\t\t\t\t\terror.request = realSrc;\n\t\t\t\t\t\t\t\tinstalledChunkData[1](error);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t};\n\t\t\t\t\t__webpack_require__.l(url, loadingEnded, \"chunk-\" + chunkId, chunkId);\n\t\t\t\t} else installedChunks[chunkId] = 0;\n\t\t\t}\n\t\t}\n};\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = function(chunkId) { return installedChunks[chunkId] === 0; };\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = function(parentChunkLoadingFunction, data) {\n\tvar chunkIds = data[0];\n\tvar moreModules = data[1];\n\tvar runtime = data[2];\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some(function(id) { return installedChunks[id] !== 0; })) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = self[\"webpackChunktravelviewer_ui\"] = self[\"webpackChunktravelviewer_ui\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [998], function() { return __webpack_require__(79786); })\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n"],"names":["apiUrl","concat","process","parseFlavorStr","str","toLocaleLowerCase","Flavor","getFlavorData","flavor","id","name","appFlavor","AppFlavor","supportUrl","appSupportUrl","vueAppFlavor","flavorOrNull","Error","flavorDataOrNull","flavorData","loadLocaleMessages","jest","locales","require","messages","keys","forEach","key","matched","match","length","locale","localeMessages","Object","undefined","replaceAll","getDefaultLanguage","defaultLang","navigator","language","userLanguage","substring","indexOf","Vue","VueI18n","fallbackLocale","render","_vm","this","_c","_self","_setupProxy","attrs","staticRenderFns","App","_Vue","_inherits","_super","_createSuper","_classCallCheck","apply","arguments","_createClass","value","Chart","ChartDataLabels","__decorate","Component","components","component","authHeaders","token","headers","Authorization","getModes","surveyId","_asyncToGenerator","_regeneratorRuntime","mark","_callee","config","wrap","_context","prev","next","params","URLSearchParams","toString","abrupt","axios","stop","getActivities","getSampleVariables","setTargetPopulation","variables","_callee2","data","_context2","map","variable","classes","cls","targetPopulation","setWeightOn","_callee3","_context3","weightOn","createVariables","_callee4","_context4","updateVariables","_callee5","_context5","deleteVariables","variableIds","_callee6","_context6","variableId","getHomeAreas","_callee7","_context7","resultQuery","query","_arguments","cancelToken","api","_objectSpread","login","username","password","getMe","getSurveyList","getSurveyDetails","getQuestionnaires","modeApi","activityApi","sampleApi","queryApi","namespaced","state","user","isLoggedIn","mutations","setUser","setToken","setLoggedIn","loggedIn","getters","actions","context","_ref","response","commit","sent","access_token","localStorage","setItem","dispatch","t0","logout","removeLogin","removeItem","getProfile","checkLoggedIn","localToken","getItem","surveyList","selectedSurvey","clear","selectSurvey","index","findIndex","s","setSurveyList","load","Promise","resolve","reject","surveys","e","rootState","filter","sort","a","b","startDate","label","status","console","log","root","_x","_x2","loadDetails","payload","_ref2","survey","find","correctedDayInSurveyCount","participateCountAllTime","_x3","_x4","getAll","getSelected","loadOfflineSampleVariables","getVariableExpandedStorageKey","loadError","setVariables","rows","setLoadError","setIsExpanded","row","r","isExpanded","storeKey","window","JSON","stringify","oldValue","_toConsumableArray","rootGetters","rejected","_ref3","clsParams","c","classId","_x5","addVariable","_ref4","oldVariables","push","_x6","_x7","updateVariable","_ref5","rowIndex","_x8","_x9","deleteVariable","_ref6","splice","_x10","_x11","_ref7","s2","i","_i","storedValue","error","resolveLabel","labelTranslations","parse","_x12","_x13","randomWeigthedSample","allOk","isTargetPopulationSum1","assignWeight","weightedSample","Math","random","sum","sum1","abs","isShare","isLoaded","isLoadError","flatLabelsToMap","maData","startsWith","langKey","toLowerCase","getMode","mode","modes","m","getActivity","activity","activities","getModeColorMap","aggregatedModes","am","modeList","modeId","bgColor","textColor","borderColor","getSurveyModes","inSurvey","getSurveyActivities","getAggregatedModesExcludingExercice","aggregatedState","amStr","order","join","aggregatedActivities","aa","aaStr","activityList","setModes","setActivities","setAggregatedModes","setAggregatedActivities","noAggregateModes","getNoAggregateModes","noAggregateActivities","getNoAggregateActivities","mainAggregateModes","getMainAggregateModes","mainAggregateActivities","getMainAggregateActivities","remoteModes","remoteActivities","remoteSurveyModes","remoteSurveyActivities","sm","sa","all","then","_slicedToArray","svgIconBgColor","svgIconBlack","questionnaires","loaded","setQuestionnaires","homeAreas","setHomeAreas","enabledClassesStateGetter","sampleClassIds","k","svId","parseInt","cId","persist","endDate","startTime","endTime","dayOfWeek","minDistanceM","maxDistanceM","minDurationS","maxDurationS","isCommuteToWork","_enabledClassesStr","setFilter","oldSvId","Log","setAggregatedMode","enabled","mId","setAggregatedActivity","aId","setAnswerOptionKeyId","enableAll","sampleVariables","sv","svClasses","surveyStartDate","surveyEndDate","restore","filterString","modeActivity","sample","filterState","reduce","reducer","val","dow","_enabledClassesStateStr","isSampleClassEnabled","noFilterOverride","findBox","resultBoardId","boxId","resultBoard","resultBoards","board","resultBoxes","attachmentState","file","fileName","content","resolveDatesAxis","today","Date","prior","setDate","getDate","end","date2YMDString","start","resolveWeeksAxis","buildSectionHeadingBox","type","ResultVisual","partialQuery","filterOverride","factTextStr","valueFormatter","valueDecimals","valueUnit","customPalette","colspan","addBoard","setBoxVisual","box","setBoxZoneFile","zoneFile","setStartEndDate","axisX","nextId","getNextId","modalSplitNTrips","workFullTimeFactor","overviewBoard","tripsBoard","_tripsBoard","healthBoard","CO2Board","ParkingBoard","questionnaireBoard","metaBoard","i18n","axisY","numerator","Numerator","denominator","Denominator","scaleFactor","statMethod","StatMethod","travelType","TravelType","enableWeighting","shareOutput","calculateMapFilter","labelStr","info","ResultFormatter","ResultUnit","hasFeature","sampleVariable","Axis","image","imageLabel","palette","textCol1","textCol2","axisXFilter","includeIds","getActiveTransportAggregatedModes","getEmissionAggregatedModes","multiMembership","boxState","sentQueries","lastSendId","addSentQuery","sentTimestamp","getTime","serializedQuery","result","apiPromise","cancelTokenSource","setQueryResult","sentQuery","sq","sendId","removeSentQuery","cancel","sendQuery","waitOnQuery","getResult","findSameQuery","_initialState","includeJoinDateInSurvey","limits","WALK","CAR_","CARD","CARP","ECAR","ECRD","ECRP","NCAR","NCRD","NCRP","PCAR","BCAR","SCAR","RCAR","BUS_","SBUS","CBUS","LORY","VAN_","FERY","TRAM","METR","CTRN","TRN_","CABE","BIKE","EBKE","CBKE","SBIK","SCOT","SCOM","MOPD","MC__","TAXI","TAXR","TUKT","MBSR","EXRC","AIR_","OTHR","UKNW","minCellN","weightLimits","minClassN","minVariableN","warnVariableN","activityMethod","nRequiresTrips","vtiReselementMerge","set","querySettings","initialState","querySettingsString","querySettingsState","limit","limitObj","_selectSurvey","waitOn","restoreSelectedSurvey","_restoreSelectedSurvey","surveyIdString","Vuex","modules","UserModule","SurveyModule","SampleModule","ModeActivityModule","FilterModule","ResultBoardModule","QueryModule","QuerySettingsModule","questionnaire","Questionnaire","homeArea","HomeArea","VueRouter","routes","path","children","redirect","scrollPosition","router","beforeEach","to","from","main","store","document","querySelector","x","scrollLeft","y","scrollTop","includes","afterEach","setTimeout","Buefy","h","$mount","ActivityMethod","getFallbackLocale","assert","substr","copyLabelTranslations","axisTranslation","axis","shareOutputLabel","dateObj","z","getFullYear","getMonth","ymdString2date","dateStr","formatYmdString","nullString","dateFormatter","Intl","DateTimeFormat","date","format","seconds2date","time","setHours","setMinutes","setSeconds","date2seconds","getHours","getMinutes","getSeconds","feature","location","search","get","_console","isLogEnabled","_console2","warn","_console3","_console4","_console5","timeEnd","getTranslations","strId","_mode$modeList","m2","_activity$activityLis","a2","car","walk","bike","exercice","air","other","usedModes","work","shop","edu","home","usedActivities","getAggregatesForModes","searchList","requireFullMatch","fullMatch","nActive","n","curr","activeModes","emisisonModes","timeout","_timeout","ms","webpackContext","req","webpackContextResolve","__webpack_require__","o","code","module","exports","__webpack_module_cache__","moduleId","cachedModule","__webpack_modules__","call","deferred","O","chunkIds","fn","priority","notFulfilled","Infinity","fulfilled","j","every","getter","__esModule","d","definition","defineProperty","enumerable","f","chunkId","promises","u","miniCssF","g","globalThis","Function","obj","prop","prototype","hasOwnProperty","inProgress","dataWebpackPrefix","l","url","done","script","needAttach","scripts","getElementsByTagName","getAttribute","createElement","charset","nc","setAttribute","src","onScriptComplete","event","onerror","onload","clearTimeout","doneFns","parentNode","removeChild","bind","target","head","appendChild","Symbol","toStringTag","nmd","paths","p","createStylesheet","fullhref","oldTag","linkTag","rel","onLinkComplete","errorType","realHref","href","err","request","insertBefore","nextSibling","findStylesheet","existingLinkTags","tag","dataHref","existingStyleTags","loadStylesheet","installedCssChunks","miniCss","cssChunks","installedChunks","installedChunkData","promise","loadingEnded","realSrc","message","webpackJsonpCallback","parentChunkLoadingFunction","moreModules","runtime","some","chunkLoadingGlobal","self","__webpack_exports__"],"sourceRoot":""}