.umirc.ts 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. import { defineConfig } from '@umijs/max';
  2. export default defineConfig({
  3. antd: {},
  4. access: {},
  5. model: {},
  6. initialState: {},
  7. request: {},
  8. layout: {
  9. title: '商户后台',
  10. },
  11. routes: [
  12. {
  13. path: '/',
  14. redirect: '/home',
  15. },
  16. {
  17. name: '登录',
  18. path: '/login',
  19. component: './Login',
  20. layout: false,
  21. },
  22. {
  23. name: '首页',
  24. path: '/home',
  25. component: './Home',
  26. icon: 'HomeOutlined',
  27. },
  28. {
  29. name: '订单管理',
  30. path: '/order',
  31. icon: 'OrderedListOutlined',
  32. routes: [
  33. {
  34. path: 'all',
  35. name: '全部订单',
  36. component: './Order',
  37. access: 'canUseMainAccount',
  38. },
  39. {
  40. path: 'mine',
  41. name: '我的订单',
  42. component: './Order/Mine',
  43. },
  44. {
  45. path: 'detail/:id',
  46. name: '详情',
  47. component: './Order/Detail',
  48. hideInMenu: true,
  49. },
  50. ],
  51. },
  52. {
  53. name: '产品列表',
  54. path: '/product',
  55. component: './ProductList',
  56. icon: 'AppstoreOutlined',
  57. },
  58. {
  59. name: '子账号管理',
  60. path: '/child_account',
  61. component: './ChildAccount',
  62. icon: 'TeamOutlined',
  63. access: 'canUseMainAccount',
  64. },
  65. {
  66. name: '重置密码',
  67. path: '/reset_pwd',
  68. component: './ResetPassword',
  69. icon: 'ReloadOutlined',
  70. },
  71. ],
  72. npmClient: 'pnpm',
  73. });