2023-03-03 01:12:26 +00:00
|
|
|
|
// Package model -----------------------------
|
|
|
|
|
// @file : artshow_artistIndex.go
|
|
|
|
|
// @author : JJXu
|
|
|
|
|
// @contact : wavingbear@163.com
|
|
|
|
|
// @time : 2023/3/2 23:11
|
|
|
|
|
// -------------------------------------------
|
|
|
|
|
package model
|
|
|
|
|
|
|
|
|
|
// 画家指数
|
|
|
|
|
type ArtshowArtistIndex struct {
|
|
|
|
|
Model
|
|
|
|
|
ArtistUid string `gorm:"column:artist_uid;comment:画家uid" json:"artistUid"`
|
|
|
|
|
Title string `gorm:"column:title;comment:" json:"title"` //艺术家-展览(exhibition) 、 艺术家-资历(seniority) 、艺术家-专业(specialized) 、艺术家-影响力(Influence)、艺术家-收藏(collect)
|
|
|
|
|
Class string `gorm:"column:class;comment:指数类别" json:"class"` //exhibition 、seniority 、specialized 、Influence 、collect
|
2023-03-10 09:27:10 +00:00
|
|
|
|
TitleScore float32 `gorm:"column:title_score;comment:总分" json:"titleScore"`
|
2023-03-03 01:12:26 +00:00
|
|
|
|
Score string `gorm:"column:score;comment:前端定义的分数列表" json:"score"` //
|
|
|
|
|
Types string `gorm:"column:types;comment:" json:"types"`
|
|
|
|
|
Status int64 `json:"status" gorm:"column:status;default:2;comment:2=锁定 3=解锁"` //跟随用户的锁定和解锁状态,用于控制数据的展示
|
|
|
|
|
LockTime string `json:"lockTime" gorm:"column:lock_time;comment:锁定时间"`
|
|
|
|
|
AuditStatus AuditStatus `json:"auditStatus" gorm:"column:audit_status;default:5;comment:审核状态:2= 待审核,3= 审核失败,4= 审核通过,5= 待补充"`
|
|
|
|
|
AuditMark1 string `json:"auditMark1" gorm:"column:audit_mark1;comment:审核备注1"`
|
|
|
|
|
AuditMark2 string `json:"auditMark2" gorm:"column:audit_mark2;comment:审核备注2"`
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
func (a ArtshowArtistIndex) TableName() string {
|
|
|
|
|
return "artshow_artist_index"
|
|
|
|
|
}
|
2023-03-03 07:28:55 +00:00
|
|
|
|
func (a *ArtshowArtistIndex) Editable() bool {
|
|
|
|
|
if a.Status == 1 {
|
|
|
|
|
return true
|
|
|
|
|
}
|
|
|
|
|
if a.Status == 2 && (a.AuditStatus == AuditType_Failed || a.AuditStatus == AuditType_Pending || a.AuditStatus == AuditType_Supplemented) {
|
|
|
|
|
return true
|
|
|
|
|
}
|
|
|
|
|
return false
|
|
|
|
|
}
|