Commit | Line | Data |
---|---|---|
13c19b7b | 1 | import { createRouter, createWebHistory } from 'vue-router' |
66a7748d | 2 | import ChargingStationsView from '@/views/ChargingStationsView.vue' |
c317ae3e JB |
3 | import StartTransaction from '@/components/actions/StartTransaction.vue' |
4 | import AddChargingStations from '@/components/actions/AddChargingStations.vue' | |
32de5a57 | 5 | |
13c19b7b | 6 | export const router = createRouter({ |
2cddfd51 | 7 | history: createWebHistory(), |
13c19b7b JB |
8 | routes: [ |
9 | { | |
10 | path: '/', | |
11 | name: 'charging-stations', | |
12 | components: { | |
13 | default: ChargingStationsView | |
14 | } | |
c317ae3e JB |
15 | }, |
16 | { | |
17 | path: '/add-charging-stations', | |
18 | name: 'add-charging-stations', | |
19 | components: { | |
20 | default: ChargingStationsView, | |
21 | action: AddChargingStations | |
22 | } | |
23 | }, | |
24 | { | |
25 | path: '/start-transaction/:hashId/:chargingStationId/:connectorId', | |
26 | name: 'start-transaction', | |
27 | components: { | |
28 | default: ChargingStationsView, | |
29 | action: StartTransaction | |
30 | }, | |
31 | props: { default: false, action: true } | |
13c19b7b JB |
32 | } |
33 | ] | |
66a7748d | 34 | }) |