112 lines
4.7 KiB
Go
112 lines
4.7 KiB
Go
package dbstruct
|
|
|
|
type VideoModerationTask struct {
|
|
Id *string `json:"id" bson:"_id"` // 视频审核任务表id
|
|
AuditedMedia *MediaComponent `json:"audited_media" bson:"audited_media"` // 待审核媒体内容(视频)
|
|
OldMedia *MediaComponent `json:"old_media" bson:"old_media"` // 旧媒体内容
|
|
RouteUrl *string `json:"route_url" bson:"route_url"` // 路由URL
|
|
AssociativeDatabase *string `json:"associative_database" bson:"associative_database"` // 关联数据库
|
|
AssociativeTableName *string `json:"associative_table_name" bson:"associative_table_name"` // 关联表名
|
|
AssociativeTableId *int64 `json:"associative_table_id" bson:"associative_table_id"` // 关联表主键ID
|
|
AssociativeTableColumn *string `json:"associative_table_column" bson:"associative_table_column"` // 关联表字段
|
|
BatchId *string `json:"batch_id" bson:"batch_id"` // 批次号
|
|
IsFragmented *int64 `json:"is_fragmented" bson:"is_fragmented"` // 是否分片
|
|
FragmentsNum *int64 `json:"fragments_num" bson:"fragments_num"` // 分片数量
|
|
VideoModerationId *string `json:"video_moderation_id" bson:"video_moderation_id"` // 视频审核表id(未分片时通过该id关联视频审核表)
|
|
VideoModerationFragmentIds *[]string `json:"video_moderation_fragment_ids" bson:"video_moderation_fragment_ids"` // 视频审核表分片id(分片时通过该id关联视频审核表)
|
|
IsAligned *int64 `json:"is_aligned" bson:"is_aligned"` // 是否已经对齐(详见consts->status->aligned)
|
|
Status *int64 `json:"status" bson:"status"` // 审核状态
|
|
Remarks *string `json:"remarks" bson:"remarks"` // 备注
|
|
Ct *int64 `json:"ct" bson:"ct"` // 创建时间
|
|
Ut *int64 `json:"ut" bson:"ut"` // 更新时间
|
|
DelFlag *int64 `json:"del_flag" bson:"del_flag"` // 删除标记
|
|
|
|
AuditedMediaResults []bool // 每个任务是否审核通过
|
|
Description []string // 每个任务审核结果的描述
|
|
}
|
|
|
|
func (p *VideoModerationTask) IsEmpty() bool {
|
|
if p == nil {
|
|
return true
|
|
}
|
|
return p.Id == nil || p.AuditedMedia.IsEmpty() || p.GetAssociativeDatabase() == "" || p.GetAssociativeTableName() == "" ||
|
|
p.AssociativeTableId == nil || p.GetAssociativeTableColumn() == ""
|
|
}
|
|
|
|
func (p *VideoModerationTask) GetId() string {
|
|
if p == nil || p.Id == nil {
|
|
return ""
|
|
}
|
|
return *p.Id
|
|
}
|
|
|
|
func (p *VideoModerationTask) GetBatchId() string {
|
|
if p == nil || p.BatchId == nil {
|
|
return ""
|
|
}
|
|
return *p.BatchId
|
|
}
|
|
|
|
func (p *VideoModerationTask) GetStatus() int64 {
|
|
if p == nil || p.Status == nil {
|
|
return 0
|
|
}
|
|
return *p.Status
|
|
}
|
|
|
|
func (p *VideoModerationTask) GetVideoModerationId() string {
|
|
if p == nil || p.VideoModerationId == nil {
|
|
return ""
|
|
}
|
|
return *p.VideoModerationId
|
|
}
|
|
|
|
func (p *VideoModerationTask) GetVideoModerationFragmentIds() []string {
|
|
if p == nil || p.VideoModerationId == nil {
|
|
return make([]string, 0)
|
|
}
|
|
return *p.VideoModerationFragmentIds
|
|
}
|
|
|
|
func (p *VideoModerationTask) GetAssociativeDatabase() string {
|
|
if p == nil || p.AssociativeDatabase == nil {
|
|
return ""
|
|
}
|
|
return *p.AssociativeDatabase
|
|
}
|
|
|
|
func (p *VideoModerationTask) GetAssociativeTableName() string {
|
|
if p == nil || p.AssociativeTableName == nil {
|
|
return ""
|
|
}
|
|
return *p.AssociativeTableName
|
|
}
|
|
|
|
func (p *VideoModerationTask) GetAssociativeTableId() int64 {
|
|
if p == nil || p.AssociativeTableId == nil {
|
|
return 0
|
|
}
|
|
return *p.AssociativeTableId
|
|
}
|
|
|
|
func (p *VideoModerationTask) GetAssociativeTableColumn() string {
|
|
if p == nil || p.AssociativeTableColumn == nil {
|
|
return ""
|
|
}
|
|
return *p.AssociativeTableColumn
|
|
}
|
|
|
|
func (p *VideoModerationTask) GetIsFragmented() int64 {
|
|
if p == nil || p.IsFragmented == nil {
|
|
return 0
|
|
}
|
|
return *p.IsFragmented
|
|
}
|
|
|
|
func (p *VideoModerationTask) GetFragmentsNum() int64 {
|
|
if p == nil || p.FragmentsNum == nil {
|
|
return 0
|
|
}
|
|
return *p.FragmentsNum
|
|
}
|