diff --git a/src/pages/Zone/Card/ZoneCard.vue b/src/pages/Zone/Card/ZoneCard.vue
index a470cd5bd..da70a9374 100644
--- a/src/pages/Zone/Card/ZoneCard.vue
+++ b/src/pages/Zone/Card/ZoneCard.vue
@@ -1,13 +1,10 @@
-
+
diff --git a/src/pages/Zone/ZoneList.vue b/src/pages/Zone/ZoneList.vue
index 2a5d290ef..dcd136383 100644
--- a/src/pages/Zone/ZoneList.vue
+++ b/src/pages/Zone/ZoneList.vue
@@ -14,9 +14,8 @@ import VnTable from 'src/components/VnTable/VnTable.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnInput from 'src/components/common/VnInput.vue';
import VnInputTime from 'src/components/common/VnInputTime.vue';
-import RightMenu from 'src/components/common/RightMenu.vue';
import ZoneFilterPanel from './ZoneFilterPanel.vue';
-import ZoneSearchbar from './Card/ZoneSearchbar.vue';
+import VnSection from 'src/components/common/VnSection.vue';
const { t } = useI18n();
const router = useRouter();
@@ -25,6 +24,7 @@ const { viewSummary } = useSummaryDialog();
const { openConfirmationModal } = useVnConfirm();
const tableRef = ref();
const warehouseOptions = ref([]);
+const dataKey = 'ZoneList';
const tableFilter = {
include: [
@@ -132,26 +132,41 @@ const handleClone = (id) => {
-
-
-
+
+
-
+
{
/>
+
+
+
es:
Search zone: Buscar zona
diff --git a/src/pages/Zone/locale/en.yml b/src/pages/Zone/locale/en.yml
index ba4982311..8fb5528d2 100644
--- a/src/pages/Zone/locale/en.yml
+++ b/src/pages/Zone/locale/en.yml
@@ -24,7 +24,7 @@ list:
price: Price
create: Create zone
openSummary: Details
- searchZone: Search zones
+ search: Search zones
searchLocation: Search locations
searchInfo: Search zone by id or name
confirmCloneTitle: All it's properties will be copied
diff --git a/src/router/modules/zone.js b/src/router/modules/zone.js
index f400a708e..696408c76 100644
--- a/src/router/modules/zone.js
+++ b/src/router/modules/zone.js
@@ -1,24 +1,12 @@
import { RouterView } from 'vue-router';
-export default {
- path: '/zone',
+const zoneCard = {
name: 'Zone',
+ path: '/zone',
+ component: () => import('src/pages/Zone/Card/ZoneCard.vue'),
+ redirect: { name: 'ZoneSummary' },
meta: {
- title: 'zones',
- icon: 'vn:zone',
- moduleName: 'Zone',
- keyBinding: 'z',
- },
- component: RouterView,
- redirect: { name: 'ZoneMain' },
- menus: {
- main: [
- 'ZoneList',
- 'ZoneDeliveryDays',
- 'ZoneUpcomingList',
- 'ZoneUpcomingDeliveries',
- ],
- card: [
+ menu: [
'ZoneBasicData',
'ZoneWarehouses',
'ZoneHistory',
@@ -26,21 +14,99 @@ export default {
'ZoneEvents',
],
},
+ children: [
+ {
+ name: 'ZoneSummary',
+ path: 'summary',
+ meta: {
+ title: 'summary',
+ icon: 'launch',
+ },
+ component: () => import('src/pages/Zone/Card/ZoneSummary.vue'),
+ },
+ {
+ name: 'ZoneBasicData',
+ path: 'basic-data',
+ meta: {
+ title: 'basicData',
+ icon: 'vn:settings',
+ },
+ component: () => import('src/pages/Zone/Card/ZoneBasicData.vue'),
+ },
+ {
+ name: 'ZoneLocations',
+ path: 'location',
+ meta: {
+ title: 'locations',
+ icon: 'my_location',
+ },
+ component: () => import('src/pages/Zone/Card/ZoneLocations.vue'),
+ },
+ {
+ name: 'ZoneWarehouses',
+ path: 'warehouses',
+ meta: {
+ title: 'warehouses',
+ icon: 'home',
+ },
+ component: () => import('src/pages/Zone/Card/ZoneWarehouses.vue'),
+ },
+ {
+ name: 'ZoneHistory',
+ path: 'log',
+ meta: {
+ title: 'log',
+ icon: 'history',
+ },
+ component: () => import('src/pages/Zone/Card/ZoneLog.vue'),
+ },
+ {
+ name: 'ZoneEvents',
+ path: 'events',
+ meta: {
+ title: 'calendar',
+ icon: 'vn:calendar',
+ },
+ component: () => import('src/pages/Zone/Card/ZoneEvents.vue'),
+ },
+ ],
+};
+
+export default {
+ name: 'Zone',
+ path: '/zone',
+ meta: {
+ title: 'zones',
+ icon: 'vn:zone',
+ moduleName: 'Zone',
+ keyBinding: 'z',
+ menu: ['ZoneList', 'ZoneDeliveryDays', 'ZoneUpcomingList', 'ZoneUpcomingDeliveries',],
+ },
+ component: RouterView,
+ redirect: { name: 'ZoneMain' },
children: [
{
path: '/zone',
name: 'ZoneMain',
component: () => import('src/components/common/VnModule.vue'),
- redirect: { name: 'ZoneList' },
+ redirect: { name: 'ZoneIndexMain' },
children: [
{
- path: 'list',
- name: 'ZoneList',
- meta: {
- title: 'zonesList',
- icon: 'view_list',
- },
+ path: '',
+ name: 'ZoneIndexMain',
+ redirect: { name: 'ZoneList' },
component: () => import('src/pages/Zone/ZoneList.vue'),
+ children: [
+ {
+ name: 'ZoneList',
+ path: 'list',
+ meta: {
+ title: 'list',
+ icon: 'view_list',
+ },
+ },
+ zoneCard,
+ ],
},
{
path: 'delivery-days',
@@ -62,67 +128,5 @@ export default {
},
],
},
- {
- name: 'ZoneCard',
- path: ':id',
- component: () => import('src/pages/Zone/Card/ZoneCard.vue'),
- redirect: { name: 'ZoneSummary' },
- children: [
- {
- name: 'ZoneSummary',
- path: 'summary',
- meta: {
- title: 'summary',
- icon: 'launch',
- },
- component: () => import('src/pages/Zone/Card/ZoneSummary.vue'),
- },
- {
- name: 'ZoneBasicData',
- path: 'basic-data',
- meta: {
- title: 'basicData',
- icon: 'vn:settings',
- },
- component: () => import('src/pages/Zone/Card/ZoneBasicData.vue'),
- },
- {
- name: 'ZoneLocations',
- path: 'location',
- meta: {
- title: 'locations',
- icon: 'my_location',
- },
- component: () => import('src/pages/Zone/Card/ZoneLocations.vue'),
- },
- {
- name: 'ZoneWarehouses',
- path: 'warehouses',
- meta: {
- title: 'warehouses',
- icon: 'home',
- },
- component: () => import('src/pages/Zone/Card/ZoneWarehouses.vue'),
- },
- {
- name: 'ZoneHistory',
- path: 'log',
- meta: {
- title: 'log',
- icon: 'history',
- },
- component: () => import('src/pages/Zone/Card/ZoneLog.vue'),
- },
- {
- name: 'ZoneEvents',
- path: 'events',
- meta: {
- title: 'calendar',
- icon: 'vn:calendar',
- },
- component: () => import('src/pages/Zone/Card/ZoneEvents.vue'),
- },
- ],
- },
],
};