$timestamps
$timestamps
部门
职责:公司下的树形组织单元。ancestors 祖级路径(0/3/8/)支持 LIKE 子树查询, 并借 SubtreeIds Trait 提供前缀区间子树查询。
$id : int
主键ID
$company_id : int
所属公司ID
$parent_id : int
父部门ID,0=公司直属
$ancestors : string
祖级路径
$name : string
部门名称
$dept_code : string
部门编码
$phone : string
部门电话
$email : string
部门邮箱
$fax : string
传真
$dept_type : int
部门类型:1 职能部门、2 业务部门、3 项目组
$description : string|null
部门职责/简介
$location : string
办公地点
$region_id : int
所在地区ID,0=跟随公司
$leader_id : int
部门负责人用户ID,0=未设置
$sort : int
排序号
$status : int
状态:1 启用,0 停用
$remark : string
备注说明
$create_time : string
创建时间
$update_time : string|null
更新时间
┌────────────────── 分区导航(按此顺序阅读)──────────────────┐ 分区 1 · 常量 本地枚举(启停状态 STATUS_* 已单源 HasStatusConstants) 分区 2 · 表名与属性 $table / $fillable / casts 分区 3 · 关联关系 company / leader / region / posts / memberships / postScopes / userScopes └────────────────────────────────────────────────────────────┘