Newer
Older
carbon-metering-front / src / router / modules / energyConsumption.ts
lyg on 1 Nov 2 KB 需求修改
// 综合能耗管理
import type { Route } from '@/global'

const Layout = () => import('@/layouts/index.vue')
const routes: Route.recordRaw[] = [
  {
    path: '/energy',
    component: Layout,
    redirect: '/energyData',
    name: 'Energy',
    meta: {
      title: '综合能耗管理',
      icon: 'ep:key',
      auth: '/energy',
    },
    children: [
      {
        path: '/energyData',
        component: Layout,
        redirect: '/energyData/list',
        name: 'EnergyData',
        meta: {
          title: '数据列表',
          icon: 'ep:key',
          auth: '/energy/data',
        },
        children: [
          {
            path: 'list',
            name: 'LDevice',
            component: () => import('@/views/energyConsumption/data/index.vue'),
            meta: {
              title: '设备管理',
              auth: '/energy/data',
              sidebar: false,
              breadcrumb: true,
              activeMenu: '/energyData',
            },
          },
        ],
      },
      {
        path: '/factor',
        component: Layout,
        redirect: '/factor/setup',
        name: 'Factor',
        meta: {
          title: '因子设置',
          icon: 'ep:key',
          auth: '/energy/setup',
        },
        children: [
          {
            path: 'setup',
            name: 'Setup',
            component: () => import('@/views/energyConsumption/setup/index.vue'),
            meta: {
              title: '因子设置',
              auth: '/energy/setup',
              sidebar: false,
              breadcrumb: true,
              activeMenu: '/factor',
            },
          },
        ],
      },
      {
        path: '/count',
        component: Layout,
        redirect: '/count/data',
        name: 'CountData',
        meta: {
          title: '数据统计',
          icon: 'ep:key',
          auth: '/energy/count',
        },
        children: [
          {
            path: 'data',
            name: 'Data',
            component: () => import('@/views/energyConsumption/count/index.vue'),
            meta: {
              title: '数据统计',
              auth: '/energy/count',
              sidebar: false,
              breadcrumb: true,
              activeMenu: '/count',
            },
          },
        ],
      },
    ],
  },
]

export default routes