import type { RouteRecordRaw } from 'vue-router';

const routes: RouteRecordRaw[] = [
  {
    path: '/energy',
    name: 'EnergyCenter',
    meta: {
      title: '能源管理',
      icon: 'lucide:zap',
      keepAlive: true,
      hideInMenu: true,
    },
    children: [
      {
        path: 'hydrogen-record',
        name: 'EnergyHydrogenRecord',
        component: () => import('#/views/energy/hydrogen-record/index.vue'),
      },
      {
        path: 'hydrogen-detail',
        name: 'EnergyHydrogenDetail',
        component: () => import('#/views/energy/hydrogen-detail/index.vue'),
      },
      {
        path: 'bill',
        name: 'EnergyBill',
        component: () => import('#/views/energy/bill/index.vue'),
      },
      {
        path: String.raw`bill/detail/:id(\d+)`,
        name: 'EnergyBillDetail',
        meta: { title: '账单详情', activePath: '/energy/bill' },
        component: () => import('#/views/energy/bill/detail.vue'),
      },
      {
        path: 'account',
        name: 'EnergyAccount',
        component: () => import('#/views/energy/account/index.vue'),
      },
      {
        path: 'station-price',
        name: 'EnergyStationPrice',
        component: () => import('#/views/energy/station-price/index.vue'),
      },
      {
        path: 'station-config',
        name: 'EnergyStationConfig',
        component: () => import('#/views/energy/station-config/index.vue'),
      },
    ],
  },
];

export default routes;
