import { BaseModel } from '../../frame/BaseModel'; import { Column, Entity } from 'typeorm'; @Entity('role', { comment: '角色表' }) export class Role extends BaseModel { @Column({ type: 'varchar', nullable: true, comment: '角色名称' }) name: string; @Column({ type: 'varchar', comment: '角色编码' }) code: string; @Column({ type: 'json', nullable: true, comment: '权限' }) menu: any; @Column({ type: 'varchar', nullable: true, comment: '简介' }) brief: string; @Column({ type: 'varchar', default: '0', comment: '是否使用: 0:使用;1:禁用' }) is_use: string; }