type.ts 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. /**
  2. * 后端保存菜单的详细信息
  3. * 其中 0 - false,1 - true
  4. */
  5. export interface MenuDetail {
  6. // 主键ID
  7. id: number | null;
  8. // 父级菜单主键ID
  9. parentId: number | null;
  10. // 菜单编码
  11. menuCode: string;
  12. // 菜单名
  13. menuName: string;
  14. // 前端路由 name
  15. routeName: string;
  16. // 前端路由 path
  17. routeUrl: string;
  18. // 路由参数
  19. query: string;
  20. // 路由对应的组件
  21. component: string;
  22. // 默认跳转路由
  23. redirect: string;
  24. // 显示顺序
  25. orderNum: number | null;
  26. // 菜单icon
  27. icon: string;
  28. // 菜单是否隐藏
  29. isHidden: 0 | 1;
  30. // 菜单是否禁用
  31. isDisabled: 0 | 1;
  32. // 菜单是否缓存
  33. isCache: 0 | 1;
  34. // 是否固定多标签
  35. isAffix: 0 | 1;
  36. // 简化路由
  37. isAlwaysShow: 0 | 1;
  38. // 是否根路由
  39. isRoot: 0 | 1;
  40. // 是否是外链接
  41. isFrame: 0 | 1;
  42. // 外连接
  43. frameSrc?: string;
  44. // 1 - 当前窗口; 2 - 新窗口
  45. openType?: 1 | 2;
  46. // 选中路由名称
  47. activeMenu?: string;
  48. // 创建时间
  49. createdAt?: string;
  50. // 创建人
  51. createdBy?: string;
  52. // 更新时间
  53. updatedAt?: string;
  54. // 更新人
  55. updatedBy?: string;
  56. // 路由是否删除(逻辑删除)
  57. isDeleted?: number;
  58. // 子菜单
  59. children?: MenuDetail[];
  60. }
  61. /**
  62. * 用于 element-plus 树形控件 展示
  63. */
  64. export interface MenuSimple {
  65. label: string;
  66. key: number | string;
  67. children?: MenuSimple[] | null;
  68. }