Files
qitongxue-api/internal/model/entity/entity_employees.go
2026-09-29 10:57:01 +08:00

23 lines
940 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 entity
import "github.com/gogf/gf/v2/os/gtime"
// Employees 企业员工库(跨活动复用)。
//
// 去重键为 (EnterpriseId, Phone)(见 migrate 的 UNIQUE uk_ent_phone);
// Name 参与导入时的「同名不同号」冲突检测。
type Employees struct {
Id int64 `json:"id"`
EnterpriseId int64 `json:"enterprise_id"`
Name string `json:"name"`
Phone string `json:"phone"` // 手机号(入库前去空格)
Dept string `json:"dept"`
Remark string `json:"remark"`
Status int `json:"status"` // 1 正常 / 0 停用
CreatedAt *gtime.Time `json:"created_at"`
UpdatedAt *gtime.Time `json:"updated_at"`
// DeletedAt 软删除时间,NULL=未删除;DeletedFrom 保存墓碑化前的 phone 原值(JSON),便于恢复。
DeletedAt *gtime.Time `json:"deleted_at"`
DeletedFrom *string `json:"deleted_from"`
}