|
|
@@ -3,7 +3,9 @@ import { useUserStore } from '@/stores/modules/user'
|
|
|
import { useBreadCrumb } from '@/stores/modules/breadCrumb'
|
|
|
import { useHeaderSearch } from '@/stores/modules/headerSearch'
|
|
|
import { useFiltersStore } from '@/stores/modules/filtersList'
|
|
|
+import i18n from '@/locales/index'
|
|
|
|
|
|
+const t = i18n.global.t
|
|
|
const router = createRouter({
|
|
|
history: createWebHistory(`${import.meta.env.VITE_BASE_URL}`),
|
|
|
routes: [
|
|
|
@@ -16,17 +18,26 @@ const router = createRouter({
|
|
|
{
|
|
|
path: '/dashboard',
|
|
|
name: 'Dashboard',
|
|
|
- component: () => import('../views/Dashboard')
|
|
|
+ component: () => import('../views/Dashboard'),
|
|
|
+ meta: {
|
|
|
+ breadName: t('menu.dashboard')
|
|
|
+ }
|
|
|
},
|
|
|
{
|
|
|
path: '/booking',
|
|
|
name: 'Booking',
|
|
|
- component: () => import('../views/Booking')
|
|
|
+ component: () => import('../views/Booking'),
|
|
|
+ meta: {
|
|
|
+ breadName: t('menu.booking')
|
|
|
+ }
|
|
|
},
|
|
|
{
|
|
|
path: '/report',
|
|
|
name: 'Report Management',
|
|
|
- component: () => import('../views/Report')
|
|
|
+ component: () => import('../views/Report'),
|
|
|
+ meta: {
|
|
|
+ breadName: t('menu.reportManagement')
|
|
|
+ }
|
|
|
},
|
|
|
{
|
|
|
path: '/report/detail',
|
|
|
@@ -34,7 +45,7 @@ const router = createRouter({
|
|
|
component: () => import('../views/Report/src/components/ReportDetail'),
|
|
|
meta: {
|
|
|
activeMenu: '/report',
|
|
|
- breadName: 'Detail'
|
|
|
+ breadName: t('menu.reportDetail')
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
@@ -43,7 +54,7 @@ const router = createRouter({
|
|
|
component: () => import('../views/Report/src/components/ReportSchedule'),
|
|
|
meta: {
|
|
|
activeMenu: '/report',
|
|
|
- breadName: 'Schedule Configuration'
|
|
|
+ breadName: t('menu.reportSchedule')
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
@@ -51,20 +62,25 @@ const router = createRouter({
|
|
|
name: 'Booking Detail',
|
|
|
component: () => import('../views/Booking/src/components/BookingDetail'),
|
|
|
meta: {
|
|
|
- activeMenu: '/booking'
|
|
|
+ activeMenu: '/booking',
|
|
|
+ breadName: t('menu.bookingDetail')
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
path: '/tracking',
|
|
|
name: 'Tracking',
|
|
|
- component: () => import('../views/Tracking')
|
|
|
+ component: () => import('../views/Tracking'),
|
|
|
+ meta: {
|
|
|
+ breadName: t('menu.tracking')
|
|
|
+ }
|
|
|
},
|
|
|
{
|
|
|
path: '/tracking/detail',
|
|
|
name: 'Tracking Detail',
|
|
|
component: () => import('../views/Tracking/src/components/TrackingDetail'),
|
|
|
meta: {
|
|
|
- activeMenu: '/tracking'
|
|
|
+ activeMenu: '/tracking',
|
|
|
+ breadName: t('menu.trackingDetail')
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
@@ -72,7 +88,9 @@ const router = createRouter({
|
|
|
name: 'Tracking Download Attachment',
|
|
|
component: () => import('../views/Tracking/src/components/DownloadAttachment'),
|
|
|
meta: {
|
|
|
- activeMenu: '/tracking'
|
|
|
+ activeMenu: '/tracking',
|
|
|
+ breadName: t('menu.trackingDownloadAttachment')
|
|
|
+
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
@@ -80,7 +98,8 @@ const router = createRouter({
|
|
|
name: 'Shipment Detail',
|
|
|
component: () => import('../views/Tracking/src/components/TrackingDetail'),
|
|
|
meta: {
|
|
|
- activeMenu: '/tracking'
|
|
|
+ activeMenu: '/tracking',
|
|
|
+ breadName: t('menu.shipmentDetail')
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
@@ -89,7 +108,8 @@ const router = createRouter({
|
|
|
component: () =>
|
|
|
import('../views/Tracking/src/components/TrackingTable/src/components/VGMView.vue'),
|
|
|
meta: {
|
|
|
- activeMenu: '/tracking'
|
|
|
+ activeMenu: '/tracking',
|
|
|
+ breadName: t('menu.addVGM')
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
@@ -97,7 +117,8 @@ const router = createRouter({
|
|
|
name: 'Public Tracking',
|
|
|
component: () => import('../views/Tracking/src/components/PublicTracking'),
|
|
|
meta: {
|
|
|
- activeMenu: '/tracking'
|
|
|
+ activeMenu: '/tracking',
|
|
|
+ breadName: t('menu.publicTracking')
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
@@ -108,7 +129,9 @@ const router = createRouter({
|
|
|
'../views/Tracking/src/components/PublicTracking/src/components/PublicTrackingDetail.vue'
|
|
|
),
|
|
|
meta: {
|
|
|
- activeMenu: '/tracking'
|
|
|
+ activeMenu: '/tracking',
|
|
|
+ breadName: t('menu.publicTrackingDetail')
|
|
|
+
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
@@ -116,18 +139,22 @@ const router = createRouter({
|
|
|
name: 'Login',
|
|
|
component: () => import('../views/Login'),
|
|
|
meta: {
|
|
|
- activeMenu: '/tracking'
|
|
|
+ activeMenu: '/tracking',
|
|
|
+ breadName: t('menu.login')
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
path: '/reset-password',
|
|
|
name: 'Reset Password',
|
|
|
- component: () => import('../views/Login/src/components/ChangePasswordCard.vue')
|
|
|
+ component: () => import('../views/Login/src/components/ChangePasswordCard.vue'),
|
|
|
+ meta: {
|
|
|
+ breadName: t('menu.resetPassword')
|
|
|
+ }
|
|
|
},
|
|
|
{
|
|
|
path: '/operation-log',
|
|
|
name: 'Operation log',
|
|
|
- component: () => import('../views/OperationLog')
|
|
|
+ component: () => import('../views/OperationLog'),
|
|
|
},
|
|
|
{
|
|
|
path: '/chat-log',
|
|
|
@@ -160,28 +187,35 @@ const router = createRouter({
|
|
|
{
|
|
|
path: '/system-message',
|
|
|
name: 'System Message',
|
|
|
- component: () => import('../views/SystemMessage')
|
|
|
+ component: () => import('../views/SystemMessage'),
|
|
|
+ meta: {
|
|
|
+ breadName: t('menu.systemMessage')
|
|
|
+ }
|
|
|
},
|
|
|
{
|
|
|
path: '/system-message-detail',
|
|
|
name: 'System Message Detail',
|
|
|
+ component: () => import('../views/SystemMessage/src/components/SystemMessageDetail.vue'),
|
|
|
meta: {
|
|
|
- breadName: 'Detail',
|
|
|
+ breadName: t('menu.systemMessageDetail'),
|
|
|
activeMenu: '/system-message'
|
|
|
},
|
|
|
- component: () => import('../views/SystemMessage/src/components/SystemMessageDetail.vue')
|
|
|
},
|
|
|
{
|
|
|
path: '/system-settings',
|
|
|
name: 'System Settings',
|
|
|
- component: () => import('../views/SystemSettings')
|
|
|
+ component: () => import('../views/SystemSettings'),
|
|
|
+ meta: {
|
|
|
+ breadName: t('menu.systemSettings')
|
|
|
+ }
|
|
|
},
|
|
|
{
|
|
|
path: '/system-settings/create-new-rule',
|
|
|
name: 'Create New Rule',
|
|
|
component: () => import('../views/SystemSettings/src/components/CreateNewrule'),
|
|
|
meta: {
|
|
|
- activeMenu: '/system-settings'
|
|
|
+ activeMenu: '/system-settings',
|
|
|
+ breadName: t('menu.createNewRule')
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
@@ -192,19 +226,29 @@ const router = createRouter({
|
|
|
{
|
|
|
path: '/destination-delivery',
|
|
|
name: 'Destination Delivery',
|
|
|
- component: () => import('../views/DestinationDelivery')
|
|
|
+ component: () => import('../views/DestinationDelivery'),
|
|
|
+ meta: {
|
|
|
+ breadName: t('menu.destinationDelivery')
|
|
|
+ }
|
|
|
+
|
|
|
},
|
|
|
{
|
|
|
path: '/destination-delivery/create-new-booking',
|
|
|
name: 'Create New Booking',
|
|
|
- component: () => import('../views/DestinationDelivery/src/components/CreateNewBooking')
|
|
|
+ component: () => import('../views/DestinationDelivery/src/components/CreateNewBooking'),
|
|
|
+ meta: {
|
|
|
+ breadName: t('menu.createNewBooking'),
|
|
|
+ activeMenu: '/destination-delivery'
|
|
|
+ }
|
|
|
+
|
|
|
},
|
|
|
{
|
|
|
path: '/destination-delivery/configurations',
|
|
|
name: 'Configurations',
|
|
|
component: () => import('../views/DestinationDelivery/src/components/ConfiguRations'),
|
|
|
meta: {
|
|
|
- activeMenu: '/destination-delivery'
|
|
|
+ activeMenu: '/destination-delivery',
|
|
|
+ breadName: t('menu.configurations')
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
@@ -215,7 +259,9 @@ const router = createRouter({
|
|
|
'../views/DestinationDelivery/src/components/ConfiguRations/src/components/CreateNewRule.vue'
|
|
|
),
|
|
|
meta: {
|
|
|
- activeMenu: '/destination-delivery'
|
|
|
+ activeMenu: '/destination-delivery',
|
|
|
+ breadName: t('menu.createNewRule')
|
|
|
+
|
|
|
}
|
|
|
},
|
|
|
{
|