master
2022-04-07 58389be5d3c1bbf4e47976f7ea09977be8bb84c5
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
import { EntityModel } from '@midwayjs/orm';
import { BaseEntity } from '@cool-midway/core';
import { Column } from 'typeorm';
 
/**
 * 部门
 */
@EntityModel('t_sys_department')
export class BaseSysDepartmentEntity extends BaseEntity {
  @Column({ comment: '部门名称' })
  name: string;
 
  @Column({ comment: '上级部门ID', type: 'bigint', nullable: true })
  parentId: number;
 
  @Column({ comment: '排序', default: 0 })
  orderNum: number;
  // 父菜单名称
  parentName: string;
}