126 lines
3.5 KiB
TypeScript
126 lines
3.5 KiB
TypeScript
import type { RouteRecordRaw } from 'vue-router'
|
|
import { conditionalOrderEnabledSetting } from '@/utils/config'
|
|
|
|
const HesabKetab: RouteRecordRaw = {
|
|
name: 'hesabKetab',
|
|
path: '/hesab-ketab',
|
|
component: () => import('@core/layouts/BasicLayout.vue'),
|
|
redirect: { name: 'hesabKetabMain' },
|
|
meta: {
|
|
icon: 'vuesax-linear:book',
|
|
title: 'حساب کتاب',
|
|
disabled: false,
|
|
hideMenu: false,
|
|
hideChildren: true,
|
|
order: 6
|
|
},
|
|
children: [
|
|
{
|
|
name: 'hesabKetabMain',
|
|
path: '',
|
|
component: () => import('@/pages/menuPages/hesabKetab/index.vue'),
|
|
redirect: { name: 'accountsMain' },
|
|
meta: {
|
|
icon: 'vuesax-linear:book',
|
|
order: 5,
|
|
title: 'حساب کتاب',
|
|
disabled: false,
|
|
hideMenu: true
|
|
},
|
|
children: [
|
|
{
|
|
name: 'accountsMain',
|
|
path: 'accounts',
|
|
component: () => import('@/pages/menuPages/cards/index.vue'),
|
|
meta: {
|
|
icon: 'vuesax-linear:cards',
|
|
title: 'حساب ها',
|
|
order: 1
|
|
}
|
|
},
|
|
{
|
|
name: 'walletMain',
|
|
path: 'wallet',
|
|
component: () => import('@/pages/menuPages/wallet/index.vue'),
|
|
meta: {
|
|
icon: 'vuesax-linear:wallet',
|
|
title: 'کیف پول',
|
|
order: 2
|
|
}
|
|
},
|
|
{
|
|
name: 'physicalWithdrawMain',
|
|
path: 'physical-withdraw',
|
|
component: () => import('@/pages/menuPages/physicalWithdraw/index.vue'),
|
|
meta: {
|
|
icon: 'vuesax-linear:truck-tick',
|
|
title: 'برداشت فیزیکی',
|
|
order: 3
|
|
}
|
|
},
|
|
{
|
|
name: 'withdrawMain',
|
|
path: 'withdraw',
|
|
component: () => import('@/pages/menuPages/withdraw/index.vue'),
|
|
meta: {
|
|
icon: 'vuesax-linear:money-change',
|
|
title: 'برداشت و واریز',
|
|
order: 4
|
|
}
|
|
},
|
|
{
|
|
name: 'pricingMain',
|
|
path: 'pricing',
|
|
component: () => import('@/pages/menuPages/pricing/index.vue'),
|
|
meta: {
|
|
permissionsKey: 'pricing',
|
|
icon: 'vuesax-linear:dollar-circle',
|
|
title: 'تاریخچه قیمت',
|
|
order: 5
|
|
}
|
|
},
|
|
{
|
|
name: 'priceTriggers',
|
|
path: 'priceTriggers',
|
|
component: () => import('@/pages/menuPages/priceTriggers/index.vue'),
|
|
meta: {
|
|
permissionsKey: 'priceTriggers',
|
|
icon: 'vuesax-linear:notification-bing',
|
|
title: 'هشدار قیمت',
|
|
order: 6
|
|
}
|
|
},
|
|
{
|
|
name: 'conditionalOrders',
|
|
path: 'conditionalOrders',
|
|
component: () => import('@/pages/menuPages/conditionalOrders/index.vue'),
|
|
meta: {
|
|
permissionsKey: 'priceTriggers',
|
|
icon: 'vuesax-linear:timer',
|
|
title: 'سفارش شرطی',
|
|
order: 6.5
|
|
},
|
|
beforeEnter() {
|
|
if (!conditionalOrderEnabledSetting.value) {
|
|
return { name: 'accountsMain' }
|
|
}
|
|
}
|
|
},
|
|
{
|
|
name: 'accountingMain',
|
|
path: 'accounting',
|
|
component: () => import('@/pages/menuPages/accounting/index.vue'),
|
|
meta: {
|
|
permissionsKey: 'accounting',
|
|
icon: 'vuesax-linear:calculator',
|
|
title: 'حسابداری',
|
|
order: 7
|
|
}
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|
|
|
|
export default HesabKetab
|