Files
cas_tt_cloud_backend/app/common/model/sys_department.go
2022-01-07 16:12:43 +08:00

24 lines
948 B
Go
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package model
// SysDepartment 部门数据模型
type SysDepartment struct {
Model
ModelTenant
ParentID uint64 `gorm:"column:parent_id;type:int;default:0;comment:父级ID" json:"-"`
Name string `gorm:"column:name;type:varchar(20);default:'';comment:部门名称" json:"name"`
Contact string `gorm:"column:contact;type:varchar(20);default:'';comment:联系人" json:"contact"`
ContactMobile string `gorm:"column:contact_mobile;type:varchar(15);default:'';comment:联系方式" json:"contact_mobile"`
Status int `gorm:"column:status;type:tinyint(1);default:1;comment:状态1正常2禁用" json:"status"`
Remark string `gorm:"column:remark;type:varchar(255);default:'';comment:备注信息" json:"remark"`
ModelDeleted
ModelAt
}
func (m *SysDepartment) TableName() string {
return m.NewTableName("sys_department")
}
func NewSysDepartment() *SysDepartment {
return &SysDepartment{}
}