# HG changeset patch # User Thomas Junk # Date 1554792662 -7200 # Node ID ac5ba5a0e9631d92566911c4efef517eaba5d8c9 # Parent 2a29bf8776d0574d4fb440369ad5e1aac545e3e8# Parent 7c301ff449bc96d986b4c1f5fdce8ac83efa897c merge with default diff -r 7c301ff449bc -r ac5ba5a0e963 client/src/components/App.vue --- a/client/src/components/App.vue Mon Apr 08 18:54:13 2019 +0200 +++ b/client/src/components/App.vue Tue Apr 09 08:51:02 2019 +0200 @@ -79,7 +79,7 @@ ...mapState("user", ["isAuthenticated"]), ...mapState("application", ["contextBoxContent", "showSearchbar"]), isMapVisible() { - return /importoverview|stretches|review|bottlenecks|mainview/.test( + return /importconfiguration|importoverview|stretches|review|bottlenecks|mainview/.test( this.routeName ); }, diff -r 7c301ff449bc -r ac5ba5a0e963 client/src/components/Contextbox.vue --- a/client/src/components/Contextbox.vue Mon Apr 08 18:54:13 2019 +0200 +++ b/client/src/components/Contextbox.vue Tue Apr 09 08:51:02 2019 +0200 @@ -6,6 +6,9 @@ + @@ -31,7 +34,9 @@ Bottlenecks: () => import("@/components/Bottlenecks"), Stretches: () => import("@/components/ImportStretches.vue"), ImportOverview: () => - import("@/components/importoverview/ImportOverview.vue") + import("@/components/importoverview/ImportOverview.vue"), + ImportConfiguration: () => + import("@/components/importconfiguration/Import.vue") }, computed: { ...mapState("application", [ diff -r 7c301ff449bc -r ac5ba5a0e963 client/src/components/ImportApprovedGaugeMeasurement.vue --- a/client/src/components/ImportApprovedGaugeMeasurement.vue Mon Apr 08 18:54:13 2019 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,140 +0,0 @@ - - - - - diff -r 7c301ff449bc -r ac5ba5a0e963 client/src/components/ImportWaterwayProfiles.vue --- a/client/src/components/ImportWaterwayProfiles.vue Mon Apr 08 18:54:13 2019 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,182 +0,0 @@ - - - - - diff -r 7c301ff449bc -r ac5ba5a0e963 client/src/components/Sidebar.vue --- a/client/src/components/Sidebar.vue Mon Apr 08 18:54:13 2019 +0200 +++ b/client/src/components/Sidebar.vue Tue Apr 09 08:51:02 2019 +0200 @@ -49,20 +49,14 @@ Soundingresults - - - Approved Gaugemeasurements - - - - Waterway Profiles - Imports + + + Imports (New) + Systemadministration diff -r 7c301ff449bc -r ac5ba5a0e963 client/src/components/importconfiguration/Import.vue --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/client/src/components/importconfiguration/Import.vue Tue Apr 09 08:51:02 2019 +0200 @@ -0,0 +1,256 @@ + + + + + diff -r 7c301ff449bc -r ac5ba5a0e963 client/src/components/importconfiguration/ImportApprovedGaugeMeasurement.vue --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/client/src/components/importconfiguration/ImportApprovedGaugeMeasurement.vue Tue Apr 09 08:51:02 2019 +0200 @@ -0,0 +1,132 @@ + + + + + diff -r 7c301ff449bc -r ac5ba5a0e963 client/src/components/importconfiguration/ImportDetails.vue --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/client/src/components/importconfiguration/ImportDetails.vue Tue Apr 09 08:51:02 2019 +0200 @@ -0,0 +1,108 @@ + + + + + diff -r 7c301ff449bc -r ac5ba5a0e963 client/src/components/importconfiguration/ImportWaterwayProfiles.vue --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/client/src/components/importconfiguration/ImportWaterwayProfiles.vue Tue Apr 09 08:51:02 2019 +0200 @@ -0,0 +1,170 @@ + + + + + diff -r 7c301ff449bc -r ac5ba5a0e963 client/src/router.js --- a/client/src/router.js Mon Apr 08 18:54:13 2019 +0200 +++ b/client/src/router.js Tue Apr 09 08:51:02 2019 +0200 @@ -97,38 +97,6 @@ } }, { - path: "/importwaterwayprofiles", - name: "waterwayprofiles", - component: () => import("./components/ImportWaterwayProfiles"), - meta: { - requiresAuth: true - }, - beforeEnter: (to, from, next) => { - const isWaterwayAdmin = store.getters["user/isWaterwayAdmin"]; - if (!isWaterwayAdmin) { - next("/login"); - } else { - next(); - } - } - }, - { - path: "/importapprovedgaugemeasurement", - name: "approvedgaugemeasurement", - component: () => import("./components/ImportApprovedGaugeMeasurement"), - meta: { - requiresAuth: true - }, - beforeEnter: (to, from, next) => { - const isWaterwayAdmin = store.getters["user/isWaterwayAdmin"]; - if (!isWaterwayAdmin) { - next("/login"); - } else { - next(); - } - } - }, - { path: "/importschedule", name: "importschedule", component: () => import("./components/importschedule/Importschedule.vue"), @@ -175,6 +143,26 @@ } }, { + path: "/imports/configuration", + name: "importconfiguration", + component: Maplayer, + meta: { + requiresAuth: true + }, + beforeEnter: (to, from, next) => { + const isWaterwayAdmin = store.getters["user/isWaterwayAdmin"]; + if (!isWaterwayAdmin) { + next("/login"); + } else { + store.commit("application/searchQuery", ""); + store.commit("application/showContextBox", true); + store.commit("application/contextBoxContent", "importconfiguration"); + store.commit("application/showSearchbar", true); + next(); + } + } + }, + { path: "/imports/overview/:id?", name: "importoverview", component: Maplayer, diff -r 7c301ff449bc -r ac5ba5a0e963 client/src/store/importschedule.js --- a/client/src/store/importschedule.js Mon Apr 08 18:54:13 2019 +0200 +++ b/client/src/store/importschedule.js Tue Apr 09 08:51:02 2019 +0200 @@ -27,7 +27,10 @@ FAIRWAYDIMENSION: "fairwaydimension", WATERWAYGAUGES: "waterwaygauges", DISTANCEMARKSVIRTUAL: "distancemarksvirtual", - DISTANCEMARKSASHORE: "distancemarksashore" + DISTANCEMARKSASHORE: "distancemarksashore", + SOUNDINGRESULTS: "soundingresults", + APPROVEDGAUGEMEASUREMENTS: "approvedgaugemeasurements", + WATERWAYPROFILES: "waterwayprofiles" }; const KINDIMPORTTYPE = { @@ -88,12 +91,18 @@ }; }; +const MODES = { + LIST: "list", + EDIT: "edit" +}; + // initial state const init = () => { return { schedules: [], importScheduleDetailVisible: false, - currentSchedule: initializeCurrentSchedule() + currentSchedule: initializeCurrentSchedule(), + mode: MODES.LIST }; }; @@ -102,6 +111,16 @@ namespaced: true, state: init(), mutations: { + setEditMode: state => { + state.mode = MODES.EDIT; + }, + setListMode: state => { + state.currentSchedule = initializeCurrentSchedule(); + state.mode = MODES.LIST; + }, + setImportType: (state, type) => { + Vue.set(state.currentSchedule, "importType", type); + }, clearCurrentSchedule: state => { state.currentSchedule = initializeCurrentSchedule(); }, @@ -320,5 +339,6 @@ importschedule, initializeCurrentSchedule, IMPORTTYPES, - IMPORTTYPEKIND + IMPORTTYPEKIND, + MODES };