feat: 完善平台总后台模块
This commit is contained in:
18
backend/api/internal/models/staff_credential.go
Normal file
18
backend/api/internal/models/staff_credential.go
Normal file
@@ -0,0 +1,18 @@
|
||||
package models
|
||||
|
||||
import (
|
||||
"git.apinb.com/bsm-sdk/core/database"
|
||||
"time"
|
||||
)
|
||||
|
||||
// StaffCredential 对应 staff_credential,保存人员资质。
|
||||
type StaffCredential struct {
|
||||
Entity
|
||||
StaffAccountID uint64 `gorm:"column:staff_account_id;not null;index" json:"staff_account_id"`
|
||||
CredentialType string `gorm:"column:credential_type;type:varchar(64);not null" json:"credential_type"`
|
||||
CredentialNo string `gorm:"column:credential_no;type:varchar(128);not null;default:''" json:"credential_no"`
|
||||
ExpiredAt *time.Time `gorm:"column:expired_at;type:timestamptz" json:"expired_at"`
|
||||
}
|
||||
|
||||
func init() { database.AppendMigrate(&StaffCredential{}) }
|
||||
func (table *StaffCredential) TableName() string { return "staff_credential" }
|
||||
Reference in New Issue
Block a user