123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951 |
- import Vue from 'vue'
- import Router from 'vue-router'
- import i18n from '@/utils/i18n'
- // eslint-disable-next-line no-unused-vars
- // import { uiVersion } from 'domain'
- Vue.use(Router)
- /* Layout */
- import Layout from '@/layout'
- const uiVersion = domain.uiVersion
- const enableBroadcast = domain.enableBroadcast
- const enableMobile = domain.enableMobile
- const enableEntraceguard = domain.enableEntraceguard
- const enableNBiot = domain.enableNBiot
- const enableCustomerDevice = domain.enableCustomerDevice
- const enableSosDevice = domain.enableSosDevice
- const enable485 = domain.enable485
- const enableLinux = domain.enableLinux
- /**
- * constantRoutes
- * a base page that does not have permission requirements
- * all roles can be accessed
- */
- export const constantRoutes = [
- {
- path: '/redirect',
- component: Layout,
- hidden: true,
- children: [
- {
- path: '/redirect/:path(.*)',
- component: () => import('@/views/redirect/index')
- }
- ]
- },
- {
- path: '/login',
- component: () => import('@/views/login/index'),
- hidden: true
- },
- {
- path: '/auth-redirect',
- component: () => import('@/views/login/auth-redirect'),
- hidden: true
- },
- {
- path: '/404',
- component: () => import('@/views/error-page/404'),
- hidden: true
- },
- {
- path: '/401',
- component: () => import('@/views/error-page/401'),
- hidden: true
- },
- {
- path: '/',
- component: Layout,
- redirect: '/dashboard',
- children: [
- {
- path: 'dashboard',
- component: () => import('@/views/dashboard/index'),
- name: 'Dashboard',
- meta: { title: i18n.t('tab.home'), icon: 'dashboard', affix: true }
- }
- ]
- },
- {
- path: '/vital_sign_log',
- component: () => import('@/views/vital-sign/index'),
- hidden: true
- }
- ]
- // 科室级页面
- export const partRoutes = [
- // 空间设备相关
- {
- path: '/frame',
- component: Layout,
- redirect: '/frame/tree',
- name: 'frame-tree',
- meta: { title: i18n.t('tab.frameManage'), icon: 'tree', noCache: true },
- children: [{
- path: 'tree',
- component: () => import('@/views/hospitalFrame/frameTreeView'),
- name: 'part-frame-tree',
- meta: { title: i18n.t('tab.frameManage'), icon: 'tree', noCache: true } // 空间位置
- }, {
- path: 'clerk_frame_manage',
- component: () => import('@/views/ncs-clerk-frame-manage/index'),
- name: 'clerk-frame-manage',
- meta: { title: i18n.t('tab.staffManageFrames'), icon: 'frame_manage', noCache: true }
- }
- ]
- },
- {
- path: '/device',
- name: 'part-device',
- component: Layout,
- redirect: '/device/list',
- meta: { title: i18n.t('deviceManage.deviceManage'), icon: 'devices' },
- children: [
- {
- path: 'list',
- component: () => import('@/views/ncs-device/deviceManagement'),
- name: 'device-list',
- meta: { title: i18n.t('tab.deviceManage'), icon: 'component', noCache: true } // 所有设备
- },
- {
- path: 'mobile',
- component: () => import('@/views/ncs-device/nurse_watch'),
- name: 'device-mobile',
- hidden: !enableMobile,
- meta: { title: i18n.t('tab.mobileDeviceManage'), icon: 'el-icon-watch', noCache: true } // 移动设备
- },
- {
- path: 'user_watch',
- component: () => import('@/views/ncs-device/user_watch'),
- name: 'user-watch',
- hidden: !enableCustomerDevice,
- meta: { title: i18n.t('tab.userLocationManage'), icon: 'el-icon-watch-1', noCache: true } // 用户设备
- },
- {
- path: 'huayi_sleep',
- component: () => import('@/views/ncs-device/huayi_sleep'),
- name: 'huayi-sleep',
- hidden: !enableCustomerDevice,
- meta: { title: i18n.t('zy20241209.huayiSleep'), icon: 'sleep_monitoring', noCache: true } // 用户设备
- },
- {
- path: 'sos',
- component: () => import('@/views/ncs-sos-device-setting/sos_device_setting'),
- name: 'sos-device',
- hidden: !enableSosDevice,
- meta: { title: i18n.t('tab.sosDeviceSettingManage'), icon: 'el-icon-s-help', noCache: true } // 报警设备
- },
- {
- path: 'map',
- component: () => import('@/views/customer/myMapHtml'),
- name: 'device-map',
- meta: { title: i18n.t('customerManage.footprint'), icon: 'area', noCache: true }, // 足迹
- hidden: true
- },
- {
- path: 'nbdevice_condition',
- component: () => import('@/views/ncs-device/nbDeviceCondition'),
- name: 'nbdevice-condition',
- meta: { title: i18n.t('tab.nbiotDeviceStatus'), icon: 'iot', noCache: true },
- hidden: !enableNBiot
- },
- {
- path: 'information_board',
- component: () => import('@/views/calling-board/index'),
- name: 'information-board',
- meta: { title: i18n.t('tab.boardManage'), icon: 'infomation_board', noCache: true },
- hidden: uiVersion === 2
- },
- {
- path: 'custom_infoboard',
- component: () => import('@/views/custom-infoboard/board-title'),
- name: 'board-title',
- meta: { title: i18n.t('tab.customBoardManage'), icon: 'designer', noCache: true },
- hidden: uiVersion === 2
- },
- {
- path: 'index/:id?',
- component: () => import('@/views/custom-infoboard/infoboard-designer'), // 自定义看板 component: () => import('@/views/custom-infoboard/infoboard-designer'),资阳 component: () => import('@/views/custom-infoboard/screen-designer')
- name: 'infoboard-designer-manager',
- meta: { title: i18n.t('tab.customBoardDesigner'), icon: 'el-icon-data-board', noCache: true },
- hidden: true
- },
- {
- path: 'device_menu',
- component: () => import('@/views/ncs-device-menu/index'),
- name: 'device-menu',
- meta: { title: i18n.t('tab.deviceMenuManager'), icon: 'el-icon-menu', noCache: true }
- },
- {
- path: 'device_menu_detail/:id',
- component: () => import('@/views/ncs-device-menu-detail/index'),
- name: 'device-menu-detail',
- meta: { title: i18n.t('tab.deviceMenuDetail'), icon: 'el-icon-tickets', noCache: true },
- hidden: true
- },
- // {
- // path: 'led',
- // component: () => import('@/views/ncs-led/ledDeviceManagement'),
- // name: 'led-manager',
- // meta: { title: i18n.t('tab.ledDeviceManager'), icon: 'led', noCache: true },
- // hidden: uiVersion === 2
- // },
- {
- path: 'led-control',
- component: () => import('@/views/ncs-led/ledControl'),
- name: 'led-control',
- meta: { title: i18n.t('tab.ledDevice'), icon: 'el-icon-message-solid', noCache: true }, // LED点阵屏
- hidden: true
- }
- ]
- },
- // 职员相关
- {
- path: '/clerk',
- component: Layout,
- redirect: '/clerk/list',
- name: 'part-clerk',
- meta: { title: i18n.t('tab.clerkManage'), icon: 'peoples', noCache: true },
- children: [
- {
- path: 'list',
- component: () => import('@/views/ncs-clerk/clerkManagement'),
- name: 'clerk-list',
- meta: { title: i18n.t('tab.clerkManage'), icon: 'el-icon-user-solid', noCache: true }
- },
- {
- path: 'nfc_interaction_list',
- component: () => import('@/views/nfc-interaction/index'),
- name: 'nfc-interaction-list',
- meta: { title: i18n.t('tab.clerkCalendar'), icon: 'el-icon-date', noCache: true }
- }
- ]
- },
- // 门禁
- {
- path: '/entrace_guard',
- component: Layout,
- name: 'entrace-guard',
- redirect: '/entrace_guard/users',
- hidden: !enableEntraceguard,
- children: [
- {
- path: 'users',
- component: () => import('@/views/entrace-guard/users'),
- name: 'entrace-guard-list',
- meta: { title: i18n.t('tab.entraceguardUser'), icon: 'pass_through', noCache: true },
- hidden: !enableEntraceguard
- }]
- },
- // 客户信息
- {
- path: '/customer',
- component: Layout,
- redirect: '/customer/list',
- name: 'customer-manager',
- meta: {
- title: uiVersion === 1 ? i18n.t('tab.patientManage') : i18n.t('tab.customerManage'),
- icon: 'el-icon-s-custom',
- noCache: true
- },
- children: [
- {
- path: 'list',
- component: () => uiVersion === 1 ? import('@/views/customer/patientManagement') : uiVersion === 2 ? import('@/views/customer/customerManagement') : import('@/views/customer/elderlyCareManagement'),
- name: 'customer-list',
- meta: {
- title: uiVersion === 1 ? i18n.t('tab.patientManage') : i18n.t('tab.customerManage'),
- icon: 'el-icon-s-custom',
- noCache: true
- }
- },
- {
- path: 'map',
- component: () => import('@/views/customer/allMap'),
- name: 'map',
- meta: { title: i18n.t('tab.CustomerDistribution'), icon: 'area', noCache: true },
- hidden: true
- },
- {
- path: '/advice/:id?',
- component: () => import('@/views/ncs-advice/index'),
- name: 'advice',
- meta: { title: i18n.t('tab.customerAdvice'), icon: 'area', noCache: true },
- hidden: true
- },
- {
- path: '/customer_affair',
- component: () => import('@/views/ncs-customer-affair/index'),
- name: 'customer-affair',
- meta: { title: i18n.t('zy20240530.customerAffair'), icon: 'el-icon-notebook-2', noCache: true }
- }
- ]
- },
- // 便签
- {
- path: '/remark',
- component: Layout,
- name: 'remark',
- redirect: '/remark/list',
- meta: { title: i18n.t('tab.remarkManage'), icon: 'el-icon-s-order', noCache: true },
- children: [
- {
- path: 'list',
- component: () => import('@/views/ncs-remark/index'),
- name: 'remark-list',
- meta: { title: i18n.t('tab.remarkManage'), icon: 'el-icon-s-order', noCache: true }
- }
- ]
- },
- // 文档管理
- {
- path: '/file-manager',
- component: Layout,
- redirect: '/file-manager/index',
- children: [
- {
- path: 'index',
- component: () => import('@/views/ncs-file-manager/index'),
- name: 'file-manager',
- meta: { title: i18n.t('wu20240322.fileManager'), icon: 'el-icon-folder-opened', noCache: true }
- }
- ]
- },
- // 任务
- {
- path: '/task',
- component: Layout,
- name: 'task',
- redirect: '/task/list',
- meta: { title: i18n.t('tab.taskManage'), icon: 'table', noCache: true },
- children: [
- {
- path: 'list',
- component: () => import('@/views/ncs-task/index'),
- name: 'task-list',
- meta: { title: i18n.t('tab.taskManage'), icon: 'table', noCache: true }
- }
- ]
- },
- // 交互信息
- {
- path: '/interaction',
- component: Layout,
- redirect: '/interaction/history',
- name: 'interaction',
- meta: { title: i18n.t('tab.interaction'), icon: 'list', noCache: true },
- children: [
- {
- path: 'history',
- component: () => import('@/views/ncs-interaction/index'),
- name: 'interaction-history',
- meta: { title: i18n.t('tab.interactionHistory'), icon: 'list', noCache: true }
- }, {
- path: 'chars',
- component: () => import('@/views/ncs-chars/index'),
- name: 'interaction-chars',
- meta: { title: i18n.t('tab.interactionChars'), icon: 'el-icon-pie-chart', noCache: true }
- }
- ]
- },
- // 消息中心
- {
- path: '/message-center',
- component: Layout,
- // redirect: '/interaction/history',
- name: 'message-center',
- meta: { title: i18n.t('mc.messageCenter'), icon: 'el-icon-message', noCache: true },
- children: [
- {
- path: 'message-type',
- component: () => import('@/views/message-center/message-type/index'),
- name: 'message-type',
- meta: { title: i18n.t('mc.messageType'), icon: 'messageType', noCache: true }
- },
- {
- path: 'messages',
- component: () => import('@/views/message-center/messages/index'),
- name: 'messages',
- meta: { title: i18n.t('mc.messages'), icon: 'messageList', noCache: true }
- },
- {
- path: 'messages-edit/:id?',
- component: () => import('@/views/message-center/messages/message-edit'),
- name: 'message-edit',
- meta: { title: i18n.t('mc.messagesModule.addMessage'), icon: 'messageList', noCache: true },
- hidden: true
- },
- {
- path: 'template-param',
- component: () => import('@/views/message-center/template-paramer/index'),
- name: 'template-param',
- meta: { title: i18n.t('mc.templateParamer'), icon: 'templateParamer', noCache: true }
- },
- {
- path: 'message-template',
- component: () => import('@/views/message-center/message-template/index'),
- name: 'message-template',
- meta: { title: i18n.t('mc.messageTemplate'), icon: 'messageTemplate', noCache: true }
- }
- ]
- },
- // 广播
- {
- path: '/broadcast',
- component: Layout,
- name: 'broadcast',
- redirect: '/broadcast/index',
- hidden: !enableBroadcast || uiVersion !== 1,
- children: [
- {
- path: 'index',
- component: () => import('@/views/ncs-broadcast/index'),
- name: 'broadcast-list',
- meta: { title: i18n.t('tab.broadcastManage'), icon: 'el-icon-headset', noCache: true }, // 广播设置
- hidden: !enableBroadcast || uiVersion !== 1
- },
- {
- path: 'edit/:id?',
- component: () => import('@/views/ncs-broadcast/broadcastEdit'),
- name: 'broadcast-edit',
- meta: { title: i18n.t('tab.broadcastEdit'), icon: 'area', noCache: true },
- hidden: true
- }
- ]
- },
- // {
- // path: '/infoboard_designer',
- // component: Layout,
- // name: 'infoboard-designer',
- // children: [
- // {
- // path: 'index/:id?',
- // component: () => import('@/views/custom-infoboard/infoboard-designer'), // 自定义看板 component: () => import('@/views/custom-infoboard/infoboard-designer'),资阳 component: () => import('@/views/custom-infoboard/screen-designer')
- // name: 'infoboard-designer-manager',
- // meta: { title: i18n.t('tab.customBoardDesigner'), icon: 'el-icon-data-board', noCache: true }
- // }
- // ],
- // hidden: true
- // },
- {
- path: '/settings',
- component: Layout,
- redirect: '/settings/index',
- name: 'settings',
- meta: {
- title: i18n.t('tab.settings'),
- icon: 'el-icon-s-tools'
- },
- children: [
- {
- path: 'index',
- component: () => import('@/views/calling-setting/index'),
- name: 'part-settings',
- meta: { title: i18n.t('tab.partSettings'), icon: 'el-icon-s-tools', noCache: true } // 机构设置
- }, {
- path: 'nurse_config',
- component: () => import('@/views/ncs-nurse-config/index'),
- name: 'nurse-config',
- meta: { title: i18n.t('tab.nurseConfig'), icon: 'care1', noCache: true }, // 护理参数
- hidden: uiVersion !== 1
- },
- {
- path: 'channel',
- component: () => import('@/views/hospitalFrame/index'),
- name: 'channel',
- redirect: '/settings/channel/index',
- meta: { title: i18n.t('tab.channelManage'), icon: 'el-icon-mobile-phone', noCache: true },
- children: [
- {
- path: 'index',
- component: () => import('@/views/ncs-channel/index'),
- name: 'channel-im',
- meta: { title: i18n.t('tab.channelManage'), icon: 'el-icon-mobile-phone', noCache: true }
- },
- {
- path: 'history/:id?',
- component: () => import('@/views/ncs-channel/channelImHistory'),
- name: 'channel-im-history',
- meta: { title: i18n.t('tab.channelImHistory'), icon: 'area', noCache: true },
- hidden: true
- }
- ]
- }, {
- path: 'event_list',
- component: () => import('@/views/ncs-event/index'),
- name: 'event-list',
- meta: { title: i18n.t('tab.eventManage'), icon: 'el-icon-notebook-2', noCache: true }
- }, {
- path: 'components',
- component: () => import('@/views/hospitalFrame/index'),
- redirect: '/settings/components/function_mapping',
- name: 'beds-side',
- meta: {
- title: i18n.t('tab.bedsideInteraction'),
- icon: 'component'
- },
- children: [
- {
- path: 'function_mapping',
- component: () => import('@/views/function-mapping/index'),
- name: 'function-mapping',
- meta: { title: i18n.t('tab.functionRoleMapping'), icon: 'function', noCache: true }
- },
- {
- path: 'interaction_chain',
- component: () => import('@/views/interaction-chain/index'),
- name: 'interaction-chain',
- meta: { title: i18n.t('tab.interactionChain'), icon: 'squence', noCache: true } // 交互接收顺序
- },
- {
- path: 'countdonw',
- component: () => import('@/views/ncs-countdown-config/index'),
- name: 'countdown-config',
- meta: { title: i18n.t('tab.countdownConfig'), icon: 'countdown', noCache: true }
- },
- {
- path: 'screentip',
- component: () => import('@/views/ncs-screentip/index'),
- name: 'screen-tip',
- meta: { title: i18n.t('tab.screentip'), icon: 'screen_tip', noCache: true }
- }
- ]
- }, {
- path: '/frame_group',
- component: () => import('@/views/hospitalFrame/index'),
- name: 'frame-group-manager',
- redirect: '/frame_group/index',
- children: [
- {
- path: 'index',
- component: () => import('@/views/hospitalFrame/frameGroup'),
- name: 'frame-group',
- meta: { title: i18n.t('tab.frameGroupManage'), icon: 'area', noCache: true }
- },
- {
- path: 'edit/:id?',
- component: () => import('@/views/hospitalFrame/frameGroupEdit'),
- name: 'frame-group-edit',
- meta: { title: i18n.t('tab.frameGroupEdit'), icon: 'area', noCache: true },
- hidden: true
- },
- {
- path: 'watch_frame/:id?',
- component: () => import('@/views/hospitalFrame/nurse_watch_frame'),
- name: 'nurse-watch-frame',
- meta: { title: i18n.t('tab.watchFrameManage'), icon: 'area', noCache: true },
- hidden: true
- }
- ]
- }
- ]
- },
- { path: '*', redirect: '/404', hidden: true }
- ]
- export const hospitalRoutes = [
- {
- path: '/hospital/frame',
- component: Layout,
- redirect: '/hospital/frame/index',
- name: 'hospital-frame',
- children: [
- {
- path: 'index',
- component: () => import('@/views/hospital/frame/frameTreeView'),
- name: 'hospital-frame-tree',
- meta: { title: i18n.t('tab.frameManage'), icon: 'tree', noCache: true }
- }
- ]
- },
- {
- path: '/hospital/device',
- component: Layout,
- redirect: '/hospital/device/index',
- name: 'hospital-device-manager',
- meta: { title: i18n.t('deviceManage.deviceManage'), icon: 'devices' },
- children: [
- {
- path: 'index',
- component: () => import('@/views/hospital/deviceManagement'),
- name: 'hospital-device-list',
- meta: { title: i18n.t('tab.deviceManage'), icon: 'component', noCache: true }
- },
- {
- path: 'led_control',
- component: () => import('@/views/hospital/ledControl'),
- name: 'hospital-led-control',
- meta: { title: i18n.t('tab.ledDevice'), icon: 'el-icon-message-solid', noCache: true }
- },
- {
- path: 'information_board',
- component: () => import('@/views/calling-board/index'),
- name: 'information-board',
- meta: { title: i18n.t('tab.boardManage'), icon: 'infomation_board', noCache: true },
- hidden: uiVersion === 2
- },
- {
- path: 'custom_infoboard',
- component: () => import('@/views/custom-infoboard/board-title'),
- name: 'board-title',
- meta: { title: i18n.t('tab.customBoardManage'), icon: 'designer', noCache: true },
- hidden: uiVersion === 2
- },
- {
- path: 'index/:id?',
- component: () => import('@/views/custom-infoboard/infoboard-designer'), // 自定义看板 component: () => import('@/views/custom-infoboard/infoboard-designer'),资阳 component: () => import('@/views/custom-infoboard/screen-designer')
- name: 'infoboard-designer-manager',
- meta: { title: i18n.t('tab.customBoardDesigner'), icon: 'el-icon-data-board', noCache: true },
- hidden: true
- }
- ]
- },
- {
- path: '/hospital/clerk',
- component: Layout,
- redirect: '/hospital/clerk/index',
- name: 'hospital-clerk-manager',
- children: [
- {
- path: 'index',
- component: () => import('@/views/hospital/clerkManager'),
- name: 'hospital-clerk-list',
- meta: { title: i18n.t('tab.clerkManage'), icon: 'peoples', noCache: true }
- }
- ]
- },
- {
- path: '/hospital/customer',
- component: Layout,
- redirect: '/hospital/customer/index',
- name: 'hospital-customer-manager',
- children: [
- {
- path: 'index',
- component: () => import('@/views/hospital/customerManagement'),
- name: 'hospital-customer-list',
- meta: { title: i18n.t('tab.customerManage'), icon: 'el-icon-s-custom', noCache: true }
- }
- ]
- },
- // {
- // path: '/hospital/led',
- // component: Layout,
- // redirect: '/hospital/led/index',
- // children: [
- // {
- // path: 'index',
- // component: () => import('@/views/hospital/ledControl'),
- // name: 'hospital_led',
- // meta: { title: i18n.t('tab.ledDevice'), icon: 'el-icon-message-solid', noCache: true }
- // }
- // ]
- // },
- { path: '*', redirect: '/404', hidden: true }
- ]
- export const adminRoutes = [
- {
- path: '/frame',
- component: Layout,
- redirect: '/frame/index',
- children: [
- {
- path: 'index',
- component: () => import('@/views/hospitalFrame/frameTreeView-admin'),
- name: 'admin-frame',
- meta: { title: i18n.t('tab.frameManage'), icon: 'tree', noCache: true }
- }
- ]
- },
- {
- path: '/clerk',
- component: Layout,
- redirect: '/clerk/index',
- children: [
- {
- path: 'index',
- component: () => import('@/views/ncs-clerk/clerk-admin'),
- name: 'admin-clerk',
- meta: { title: i18n.t('tab.allClerk'), icon: 'peoples', noCache: true }
- }
- ]
- },
- {
- path: '/customer',
- component: Layout,
- redirect: '/customer/index',
- children: [
- {
- path: 'index',
- component: () => import('@/views/customer/customer-admin'),
- name: 'admin-customer',
- meta: { title: i18n.t('tab.allCustomer'), icon: 'el-icon-s-custom', noCache: true }
- }
- ]
- },
- {
- path: '/device',
- component: Layout,
- redirect: '/device/index',
- meta: {
- title: i18n.t('deviceManage.deviceManage'),
- icon: 'devices'
- },
- children: [
- {
- path: 'index',
- component: () => import('@/views/ncs-device/device-admin'),
- name: 'admin-device',
- meta: { title: i18n.t('tab.allDevice'), icon: 'component', noCache: true }
- },
- {
- path: 'device_menu',
- component: () => import('@/views/ncs-device-menu/deviceMenuManagement'),
- name: 'admin-device_menu',
- meta: { title: i18n.t('tab.deviceMenuManager'), icon: 'el-icon-menu', noCache: true }
- },
- {
- path: 'linux_version',
- component: () => import('@/views/ncs-linux-version/linuxVersionSetting'),
- name: 'admin-linux-version',
- meta: { title: i18n.t('tab.linuxVersion'), icon: 'nested', noCache: true },
- hidden: !enableLinux
- },
- {
- path: 'led_device',
- component: () => import('@/views/ncs-led/led-admin'),
- name: 'admin-led-device',
- meta: { title: i18n.t('tab.ledDeviceManager'), icon: 'led', noCache: true }
- },
- {
- path: 'device_type',
- component: () => import('@/views/ncs-orginazition/device-type.vue'),
- name: 'admin-device-type',
- meta: { title: i18n.t('deviceManage.deviceType'), icon: 'component', noCache: true }
- }
- ]
- },
- {
- path: '/event',
- component: Layout,
- redirect: '/event/index',
- children: [
- {
- path: 'index',
- component: () => import('@/views/ncs-event/eventManagement'),
- name: 'admin-event',
- meta: { title: i18n.t('tab.eventManage'), icon: 'el-icon-notebook-2', noCache: true }
- }
- ]
- },
- {
- path: '/his',
- component: Layout,
- redirect: '/his/index',
- children: [
- {
- path: 'index',
- component: () => import('@/views/ncs-his/hisManagement'),
- name: 'admin-hist',
- meta: { title: i18n.t('tab.hisManage'), icon: 'el-icon-search', noCache: true }
- },
- {
- path: 'patient/:keyval?',
- component: () => import('@/views/ncs-his/his-patient/hisPatientManage'),
- name: 'admin-his-patient',
- meta: { title: i18n.t('his.hisPatient'), icon: 'el-icon-search', noCache: true },
- hidden: true
- },
- {
- path: 'clerk/:keyval?',
- component: () => import('@/views/ncs-his/his-clerk/hisClerkManager'),
- name: 'admin-his-clerk',
- meta: { title: i18n.t('his.hisClerk'), icon: 'el-icon-search', noCache: true },
- hidden: true
- },
- {
- path: 'nurse_config/:keyval?',
- component: () => import('@/views/ncs-his/his-nurse-config/hisNurseConfigManager'),
- name: 'admin-his-nurse-config',
- meta: { title: i18n.t('his.hisNurseConfig'), icon: 'el-icon-search', noCache: true },
- hidden: true
- }
- ]
- },
- {
- path: '/error_log',
- component: Layout,
- redirect: '/error_log/index',
- children: [
- {
- path: 'index',
- component: () => import('@/views/calling-ncError/index'),
- name: 'admin-error-log',
- meta: { title: i18n.t('tab.errorLog'), icon: 'bug', noCache: true }
- }
- ]
- },
- {
- path: '/system_config',
- component: Layout,
- redirect: '/system_config/index',
- children: [
- {
- path: 'index',
- component: () => import('@/views/ncs-system-config/index'),
- name: 'admin-system-config',
- meta: { title: i18n.t('tab.systemConfig'), icon: 'nested', noCache: true }
- }
- ]
- }, {
- path: '/menu',
- component: Layout,
- redirect: '/menu/index',
- children: [
- {
- path: 'index',
- component: () => import('@/views/ncs-menu/menuManager'),
- name: 'admin-menu',
- meta: { title: i18n.t('tab.menuManage'), icon: 'function', noCache: true }
- }
- ]
- },
- {
- path: '/orginazition',
- component: Layout,
- redirect: '/orginazition/index',
- children: [
- {
- path: 'index',
- component: () => import('@/views/ncs-orginazition/index'),
- name: 'admin-organization',
- meta: { title: i18n.t('tab.organization'), icon: 'tree', noCache: true }
- }, {
- path: 'index/:id?',
- component: () => import('@/views/ncs-orginazition/partInfoSetting'),
- name: 'admin-part-settings',
- meta: { title: i18n.t('tab.shopSetting'), icon: 'nested', noCache: true },
- hidden: true
- }
- ]
- },
- {
- path: '/rolemanager',
- component: Layout,
- redirect: '/rolemanager/index',
- children: [
- {
- path: 'index',
- component: () => import('@/views/ncs-auth/superadmin/defaultRoleManager'),
- name: 'admin-rolemanager',
- meta: { title: i18n.t('tab.roleManage'), icon: 'authen', noCache: true }
- }
- ]
- },
- {
- path: '/485',
- component: Layout,
- redirect: '/485/index',
- children: [
- {
- path: 'index',
- component: () => import('@/views/ncs-485/index'),
- name: 'admin-485-commissioning',
- meta: { title: i18n.t('tab.debugging485'), icon: 'authen', noCache: true }
- }
- ],
- hidden: !enable485
- },
- {
- path: '/interaction_push',
- component: Layout,
- redirect: '/interaction_push/index',
- children: [
- {
- path: 'index',
- component: () => import('@/views/ncs-interaction-push-config/index'),
- name: 'admin-interaction-push',
- meta: { title: i18n.t('tab.interactionPush'), icon: 'el-icon-s-promotion', noCache: true }
- },
- {
- path: 'paramer-config/:id?',
- component: () => import('@/views/ncs-interaction-push-config/param-config'),
- name: 'admin-interaction-push-config',
- meta: { title: i18n.t('tab.interactionPushParamConfig'), icon: 'el-icon-s-promotion', noCache: true },
- hidden: true
- }
- ]
- },
- {
- path: '/convenient_sync',
- component: Layout,
- redirect: '/convenient_sync/index',
- children: [
- {
- path: 'index',
- component: () => import('@/views/convenient-data-sync/index'),
- name: 'convenient-data-sync',
- meta: { title: i18n.t('tab.convenientDataSync'), icon: 'el-icon-refresh', noCache: true }
- }
- ]
- },
- {
- path: '/mysql_backups',
- component: Layout,
- redirect: '/mysql_backups/index',
- children: [
- {
- path: 'index',
- component: () => import('@/views/mysql-backups/index'),
- name: 'mysql-backups-index',
- meta: { title: i18n.t('zy20240205.dataBackup'), icon: 'el-icon-refresh', noCache: true }
- }
- ]
- },
- {
- path: '/device_frame',
- component: Layout,
- redirect: '/device_frame/index',
- children: [
- {
- path: 'index',
- component: () => import('@/views/ncs-orginazition/device-frame'),
- name: 'admin-device-frame',
- meta: { title: i18n.t('tab.deviceFrame'), icon: 'nested', noCache: true },
- hidden: true
- }
- ]
- },
- {
- path: '/license',
- component: Layout,
- redirect: '/license/server',
- children: [
- {
- path: 'server',
- component: () => import('@/views/ncs-orginazition/server-license'),
- name: 'server-license',
- meta: { title: i18n.t('partInfo.serverLicense'), icon: 'el-icon-key', noCache: true }
- }
- ]
- },
- { path: '*', redirect: '/404', hidden: true }
- ]
- const createRouter = () => new Router({
- mode: 'history', // require service support
- scrollBehavior: () => ({ y: 0 }),
- routes: constantRoutes
- })
- const router = createRouter()
- // Detail see: https://github.com/vuejs/vue-router/issues/1234#issuecomment-357941465
- export function resetRouter() {
- const newRouter = createRouter()
- router.matcher = newRouter.matcher // reset router
- }
- export default router
|