72 lines
2.2 KiB
Go
72 lines
2.2 KiB
Go
// Package model -----------------------------
|
|
// @file : artworkEx.go
|
|
// @author : JJXu
|
|
// @contact : wavingbear@163.com
|
|
// @time : 2023/2/28 8:58
|
|
// -------------------------------------------
|
|
package model
|
|
|
|
import "fmt"
|
|
|
|
// 画展补充信息审批表
|
|
//type ArtExhibitionAudit struct {
|
|
// Model
|
|
// //ArtworkUid string `json:"artworkUid" gorm:"column:artwork_uid;comment:画作uid"`
|
|
// //ArtistUid string `json:"artistUid" gorm:"column:artist_uid;comment:画家uid"`
|
|
// //UserId int64 `json:"userId" gorm:"column:user_id;comment:画家宝用户id"`
|
|
// LockTime string `json:"lockTime" gorm:"column:lock_time;comment:锁定时间"`
|
|
// AuditType auditType `json:"auditType" gorm:"column:audit_type;comment:审批类型"`
|
|
// AuditModel
|
|
//}
|
|
//
|
|
//func (a ArtExhibitionAudit) TableName() string {
|
|
// return "art_exhibition_audit"
|
|
//}
|
|
|
|
//// 画作信息补充审批
|
|
//type AuditArtworkExt struct {
|
|
// AuditInfo ArtExhibitionAudit `json:"AuditInfo" gorm:"polymorphic:Owner;polymorphicValue:AuditType_ArtworkExt"`
|
|
//}
|
|
//
|
|
//// 画家视频资料补充审批
|
|
//type AuditArtistVideo struct {
|
|
// ArtworkId
|
|
// AuditInfo ArtExhibitionAudit `json:"AuditInfo" gorm:"polymorphic:Owner;polymorphicValue:AuditType_ArtistVideo"`
|
|
//}
|
|
//
|
|
//// 画家信息补充审批
|
|
//type AuditArtistExt struct {
|
|
// AuditInfo ArtExhibitionAudit `json:"AuditInfo" gorm:"polymorphic:Owner;polymorphicValue:AuditType_ArtistExt"`
|
|
//}
|
|
//
|
|
//// 画家指数补充审批
|
|
//type AuditArtistIndex struct {
|
|
// AuditInfo ArtExhibitionAudit `json:"AuditInfo" gorm:"polymorphic:Owner;polymorphicValue:AuditType_ArtistIndex"`
|
|
//}
|
|
|
|
// ======================================
|
|
// auditType 审批类型
|
|
type auditType int
|
|
|
|
const (
|
|
AuditType_ArtworkExt auditType = iota + 1
|
|
AuditType_ArtistVideo
|
|
AuditType_ArtistIndex
|
|
AuditType_ArtistExt
|
|
)
|
|
|
|
var auditTypeMapper = map[auditType]string{
|
|
AuditType_ArtworkExt: "画作信息补充审批",
|
|
AuditType_ArtistVideo: "画家视频资料补充审批",
|
|
AuditType_ArtistIndex: "画家指数补充审批",
|
|
AuditType_ArtistExt: "画家信息补充审批",
|
|
}
|
|
|
|
func (a auditType) String() string {
|
|
if str, ok := auditTypeMapper[a]; ok {
|
|
return str
|
|
} else {
|
|
return fmt.Sprintf("未知的审批类型:%d", int(a))
|
|
}
|
|
}
|