批量优化
This commit is contained in:
1 parent
438145cae7
commit
c925b198d1
50 files changed
+5716
-291
No files matched your search
@@ -0,0 +1,47 @@
|
||||
package models
|
||||
|
||||
import "time"
|
||||
|
||||
// 企业申请类型 / 状态
|
||||
const (
|
||||
TenantApplyTypeJoin = 1 // 加入企业(绑定企业,企业管理员审批)
|
||||
TenantApplyTypeCreate = 2 // 创建企业(平台审批)
|
||||
|
||||
TenantApplyStatusPending = 0 // 待审核
|
||||
TenantApplyStatusPassed = 1 // 已通过
|
||||
TenantApplyStatusReject = 2 // 已驳回
|
||||
)
|
||||
|
||||
// AuthTenantApply 注册企业绑定/创建申请:yz_auth_tenant_apply
|
||||
//
|
||||
// 统一认证注册第二步产生:
|
||||
// - type=join:绑定企业申请,由目标企业的管理员在 backend「加入申请」页审批,
|
||||
// 通过后建立身份-企业绑定(默认「租户用户」角色);
|
||||
// - type=create:创建企业申请(含营业执照),由平台在 platform「企业创建审核」页审批,
|
||||
// 通过后自动创建租户并把申请人绑定为租户管理员。
|
||||
type AuthTenantApply struct {
|
||||
ID uint64 `orm:"column(id);pk;auto" json:"id"`
|
||||
IdentityID uint64 `orm:"column(identity_id)" json:"identity_id"`
|
||||
Type int8 `orm:"column(type);default(1)" json:"type"`
|
||||
Tid uint64 `orm:"column(tid);default(0)" json:"tid"`
|
||||
TenantName string `orm:"column(tenant_name);size(128);default('')" json:"tenant_name"`
|
||||
CreditCode string `orm:"column(credit_code);size(64);default('')" json:"credit_code"`
|
||||
LegalPerson string `orm:"column(legal_person);size(64);default('')" json:"legal_person"`
|
||||
LicenseFile string `orm:"column(license_file);size(500);default('')" json:"license_file"`
|
||||
ContactPerson string `orm:"column(contact_person);size(64);default('')" json:"contact_person"`
|
||||
ContactPhone string `orm:"column(contact_phone);size(20);default('')" json:"contact_phone"`
|
||||
ContactEmail string `orm:"column(contact_email);size(128);default('')" json:"contact_email"`
|
||||
Address string `orm:"column(address);size(255);default('')" json:"address"`
|
||||
Status int8 `orm:"column(status);default(0)" json:"status"`
|
||||
RejectReason string `orm:"column(reject_reason);size(255);default('')" json:"reject_reason"`
|
||||
ReviewerID uint64 `orm:"column(reviewer_id);default(0)" json:"reviewer_id"`
|
||||
ReviewerName string `orm:"column(reviewer_name);size(64);default('')" json:"reviewer_name"`
|
||||
ReviewTime *time.Time `orm:"column(review_time);type(datetime);null" json:"review_time"`
|
||||
CreateTime time.Time `orm:"column(create_time);type(datetime);auto_now_add" json:"create_time"`
|
||||
UpdateTime *time.Time `orm:"column(update_time);type(datetime);null" json:"update_time"`
|
||||
DeleteTime *time.Time `orm:"column(delete_time);type(datetime);null" json:"delete_time"`
|
||||
}
|
||||
|
||||
func (m *AuthTenantApply) TableName() string {
|
||||
return "yz_auth_tenant_apply"
|
||||
}
|
||||
Reference in new issue
Block a user