package model import "time" // UserOrganization 用户-机构-角色关联 type UserOrganization struct { Id int64 `gorm:"column:id;primaryKey;autoIncrement" json:"id"` UserId int64 `gorm:"column:user_id;index" json:"userId"` OrgId int64 `gorm:"column:org_id;index" json:"orgId"` RoleId int64 `gorm:"column:role_id" json:"roleId"` CreatedAt time.Time `gorm:"column:created_at;autoCreateTime" json:"createdAt"` } func (UserOrganization) TableName() string { return "user_organization" }