232 lines
15 KiB
Go
232 lines
15 KiB
Go
package dto
|
||
|
||
import "time"
|
||
|
||
// TaskQueryRequest 查询待指派任务记录请求参数
|
||
type TaskQueryRequest struct {
|
||
Keyword string `json:"keyword"` // 艺人姓名、编号、手机号搜索关键词
|
||
LastTaskAssignee string `json:"lastTaskAssignee"` // 最近一次指派人筛选(模糊匹配)
|
||
Page int `json:"page"` // 页码
|
||
PageSize int `json:"pageSize"` // 每页数量
|
||
SortBy string `json:"sortBy"` // 排序字段(支持白名单字段)
|
||
SortType string `json:"sortType"` // 排序类型 asc/desc
|
||
SubNums []string `json:"subNums"` // 选中导出的艺人编号集合(可选)
|
||
}
|
||
|
||
// TaskAssignRequest 指派任务请求参数
|
||
type TaskAssignRequest struct {
|
||
SubNum string `json:"subNum"` // 艺人编号
|
||
TelNum string `json:"telNum"` // 艺人手机号
|
||
ArtistName string `json:"artistName"` // 艺人姓名
|
||
TaskAssignee string `json:"taskAssignee"` // 任务指派人
|
||
TaskAssigneeNum string `json:"taskAssigneeNum"` // 任务指派人账号
|
||
Operator string `json:"operator"` // 操作人
|
||
OperatorNum string `json:"operatorNum"` // 操作人账号
|
||
AssignVideoCount int `json:"assignVideoCount"` // 指派视频数
|
||
AssignPostCount int `json:"assignPostCount"` // 指派图文数
|
||
AssignDataCount int `json:"assignDataCount"` // 指派数据数
|
||
AssignVideoScriptCount int `json:"assignVideoScriptCount"` // 指派视频脚本数
|
||
TaskBatch string `json:"taskBatch"` // 任务批次
|
||
}
|
||
|
||
// BatchAssignItem 批量指派项(仅写入指派记录,不更新任务管理表)
|
||
type BatchAssignItem struct {
|
||
SubNum string `json:"subNum"` // 艺人编号
|
||
TelNum string `json:"telNum"` // 艺人手机号
|
||
ArtistName string `json:"artistName"` // 艺人姓名
|
||
TaskAssignee string `json:"taskAssignee"` // 任务指派人
|
||
TaskAssigneeNum string `json:"taskAssigneeNum"` // 任务指派人账号
|
||
Operator string `json:"operator"` // 操作人
|
||
OperatorNum string `json:"operatorNum"` // 操作人账号
|
||
AssignVideoCount int `json:"assignVideoCount"` // 指派视频数
|
||
AssignPostCount int `json:"assignPostCount"` // 指派图文数
|
||
AssignDataCount int `json:"assignDataCount"` // 指派数据数
|
||
AssignVideoScriptCount int `json:"assignVideoScriptCount"` // 指派视频脚本数
|
||
TaskBatch string `json:"taskBatch"` // 任务批次
|
||
}
|
||
|
||
// EmployeeTaskQueryRequest 员工任务查询请求参数
|
||
type EmployeeTaskQueryRequest struct {
|
||
TaskAssigneeNum string `json:"taskAssigneeNum"` // 被指派人账号
|
||
Keyword string `json:"keyword"` // 艺人姓名、编号、手机号搜索关键词
|
||
Operator string `json:"operator"` // 操作人
|
||
SortBy string `json:"sortBy"` // 排序字段
|
||
StartTime string `json:"startTime"` // 指派开始时间
|
||
EndTime string `json:"endTime"` // 指派结束时间
|
||
StartCompleteTime string `json:"startCompleteTime"` // 开始完成时间
|
||
EndCompleteTime string `json:"endCompleteTime"` // 结束完成时间
|
||
Status int `json:"status"` // 反馈完成状态
|
||
TaskBatch string `json:"taskBatch"` // 任务批次
|
||
|
||
Page int `json:"page"` // 页码
|
||
PageSize int `json:"pageSize"` // 每页数量
|
||
}
|
||
|
||
// CompleteTaskRequest 完成任务请求参数
|
||
type CompleteTaskRequest struct {
|
||
AssignRecordsUUID string `json:"assignRecordsUUID,omitempty"` // 指派记录UUID(可选)
|
||
EmployeeName string `json:"employeeName"` // 员工姓名(必要)
|
||
EmployeeNum string `json:"employeeNum"` // 员工工号(必要)
|
||
TaskType string `json:"taskType"` // 任务类型: video/post/data/script
|
||
UUID string `json:"uuid"` // 任务UUID
|
||
CompleteCount int `json:"completeCount"` // 完成数量
|
||
}
|
||
|
||
// TaskAssignRecordsQueryRequest 多条件查询操作记录表请求参数
|
||
type TaskAssignRecordsQueryRequest struct {
|
||
Keyword string `json:"keyword"` // 艺人姓名、编号、手机号搜索关键词
|
||
TaskAssignee string `json:"taskAssignee"` // 指派人姓名
|
||
Operator string `json:"operator"` // 操作人姓名
|
||
OperatorNum string `json:"operatorNum"` // 操作人手机号
|
||
StartTime string `json:"startTime"` // 操作开始时间
|
||
EndTime string `json:"endTime"` // 操作结束时间
|
||
Status int `json:"status"` // 反馈完成状态 0:全部 1:未完成 2:完成
|
||
ActualStatus int `json:"actualStatus"` // 实际完成状态 0:全部 1:未完成 2:完成
|
||
TaskBatch string `json:"taskBatch"` // 任务批次
|
||
Page int `json:"page"` // 页码
|
||
PageSize int `json:"pageSize"` // 每页数量
|
||
SortBy string `json:"sortBy"` // 排序字段(白名单)
|
||
SortType string `json:"sortType"` // 排序方式
|
||
}
|
||
|
||
// 任务记录表返回结构体
|
||
type TaskAssignRecordsResponse struct {
|
||
AssignRecordsUUID string `gorm:"column:assign_records_uuid;comment:指派记录UUID" json:"assignRecordsUUID"`
|
||
SubNum string `gorm:"column:sub_num;comment:艺人编号" json:"subNum"`
|
||
TelNum string `gorm:"column:tel_num;comment:艺人手机号" json:"telNum"`
|
||
ArtistName string `gorm:"column:artist_name;comment:艺人名称" json:"artistName"`
|
||
Status int `gorm:"column:status;comment:反馈完成状态 1:未完成 2:完成" json:"status"`
|
||
ActualStatus int `gorm:"column:actual_status;comment:实际完成状态 1:未完成 2:完成" json:"actualStatus"`
|
||
CompleteTime *time.Time `gorm:"column:complete_time;comment:反馈完成时间" json:"completeTime"`
|
||
OperatorType int `gorm:"column:operator_type;comment:操作类型 1:修改待发数量 2:指派" json:"operatorType"`
|
||
Operator string `gorm:"column:operator;comment:操作人" json:"operator"`
|
||
OperatorNum string `gorm:"column:operator_num;comment:操作人账号" json:"operatorNum"`
|
||
OperatorTime time.Time `gorm:"column:operator_time;comment:操作时间" json:"operatorTime"`
|
||
TaskAssignee string `gorm:"column:task_assignee;comment:任务指派人" json:"taskAssignee"`
|
||
TaskAssigneeNum string `gorm:"column:task_assignee_num;comment:任务指派人账号" json:"taskAssigneeNum"`
|
||
TaskBatch string `gorm:"column:task_batch;comment:任务批次" json:"taskBatch"`
|
||
PendingVideoCount int `gorm:"column:pending_video_count;comment:待发视频数量" json:"pendingVideoCount"`
|
||
PendingPostCount int `gorm:"column:pending_post_count;comment:待发图文数量" json:"pendingPostCount"`
|
||
PendingDataCount int `gorm:"column:pending_data_count;comment:待发数据数量" json:"pendingDataCount"`
|
||
PendingVideoScriptCount int `gorm:"column:pending_video_script_count;comment:待发视频脚本数量" json:"pendingVideoScriptCount"`
|
||
// 已完成统计
|
||
CompleteVideoScriptCount int `gorm:"column:complete_video_script_count;comment:已完成视频脚本数" json:"completeVideoScriptCount"`
|
||
CompleteVideoCount int `gorm:"column:complete_video_count;comment:已完成视频数" json:"completeVideoCount"`
|
||
CompletePostCount int `gorm:"column:complete_post_count;comment:已完成图文数" json:"completePostCount"`
|
||
CompleteDataCount int `gorm:"column:complete_data_count;comment:已完成数据数" json:"completeDataCount"`
|
||
UpdatedAt time.Time `gorm:"column:updated_at;comment:更新时间" json:"updatedAt"`
|
||
}
|
||
|
||
// 多条件查询后分页前的艺人数量汇总
|
||
type TaskAssignRecordsSummary struct {
|
||
TotalPendingVideoScriptCount int `json:"totalPendingVideoScriptCount"`
|
||
TotalPendingVideoCount int `json:"totalPendingVideoCount"`
|
||
TotalPendingPostCount int `json:"totalPendingPostCount"`
|
||
TotalPendingDataCount int `json:"totalPendingDataCount"`
|
||
TotalCompleteVideoScriptCount int `json:"totalCompleteVideoScriptCount"`
|
||
TotalCompleteVideoCount int `json:"totalCompleteVideoCount"`
|
||
TotalCompletePostCount int `json:"totalCompletePostCount"`
|
||
TotalCompleteDataCount int `json:"totalCompleteDataCount"`
|
||
}
|
||
|
||
// ValidArtistInfo 有效艺人信息结构体
|
||
type ValidArtistInfo struct {
|
||
UserID int `json:"userId"` // 用户ID
|
||
CustomerNum string `json:"customerNum"` // 艺人编号
|
||
UserName string `json:"userName"` // 艺人姓名
|
||
UserPhoneNumber string `json:"userPhoneNumber"` // 艺人手机号
|
||
BundleName string `json:"bundleName"` // 套餐名称
|
||
ExpirationTime string `json:"expirationTime"` // 过期时间
|
||
Status int `json:"status"` // 套餐状态
|
||
OrderUUID string `json:"orderUUID"` // 订单UUID
|
||
AccountNumber int `json:"accountNumber"` // 账号数量
|
||
AccountConsumptionNumber int `json:"accountConsumptionNumber"` // 账号消耗数量
|
||
VideoNumber int `json:"videoNumber"` // 视频数量
|
||
VideoConsumptionNumber int `json:"videoConsumptionNumber"` // 视频消耗数量
|
||
ImageNumber int `json:"imageNumber"` // 图片数量
|
||
ImageConsumptionNumber int `json:"imageConsumptionNumber"` // 图片消耗数量
|
||
DataAnalysisNumber int `json:"dataAnalysisNumber"` // 数据分析数量
|
||
DataAnalysisConsumptionNumber int `json:"dataAnalysisConsumptionNumber"` // 数据分析消耗数量
|
||
ExpansionPacksNumber int `json:"expansionPacksNumber"` // 扩展套餐数量
|
||
}
|
||
|
||
// ArtistUploadStatsItem 艺人上传与额度统计(视频/图文/数据分析)
|
||
type ArtistUploadStatsItem struct {
|
||
// 身份信息
|
||
SubNum string `json:"subNum" gorm:"column:customer_num"`
|
||
UserName string `json:"userName" gorm:"column:user_name"`
|
||
UserPhoneNumber string `json:"userPhoneNumber" gorm:"column:user_phone_number"`
|
||
StartAt string `json:"startAt" gorm:"column:start_at"`
|
||
ExpiredAt string `json:"expiredAt" gorm:"column:expired_at"`
|
||
|
||
// 视频
|
||
UploadedVideoCount int `json:"uploadedVideoCount" gorm:"column:uploaded_video_count"`
|
||
BundleVideoTotal int `json:"bundleVideoTotal" gorm:"column:bundle_video_total"`
|
||
IncreaseVideoTotal int `json:"increaseVideoTotal" gorm:"column:increase_video_total"`
|
||
ReleasedVideoTotal int `json:"releasedVideoTotal" gorm:"column:released_video_total"`
|
||
PendingVideoCount int `json:"pendingVideoCount" gorm:"column:pending_video_count"`
|
||
|
||
// 图文
|
||
UploadedPostCount int `json:"uploadedPostCount" gorm:"column:uploaded_post_count"`
|
||
BundlePostTotal int `json:"bundlePostTotal" gorm:"column:bundle_post_total"`
|
||
IncreasePostTotal int `json:"increasePostTotal" gorm:"column:increase_post_total"`
|
||
ReleasedPostTotal int `json:"releasedPostTotal" gorm:"column:released_post_total"`
|
||
PendingPostCount int `json:"pendingPostCount" gorm:"column:pending_post_count"`
|
||
|
||
// 数据分析
|
||
UploadedDataAnalysisCount int `json:"uploadedDataAnalysisCount" gorm:"column:uploaded_data_count"`
|
||
BundleDataAnalysisTotal int `json:"bundleDataAnalysisTotal" gorm:"column:bundle_data_total"`
|
||
IncreaseDataAnalysisTotal int `json:"increaseDataAnalysisTotal" gorm:"column:increase_data_total"`
|
||
ReleasedDataAnalysisTotal int `json:"releasedDataAnalysisTotal" gorm:"column:released_data_total"`
|
||
PendingDataAnalysisCount int `json:"pendingDataAnalysisCount" gorm:"column:pending_data_count"`
|
||
|
||
// 任务管理
|
||
LastTaskAssignee string `json:"lastTaskAssignee" gorm:"column:last_task_assignee"`
|
||
TaskAssigneeNum string `json:"taskAssigneeNum" gorm:"column:task_assignee_num"`
|
||
ProgressTaskCount int `json:"progressTaskCount" gorm:"column:progress_task_count"`
|
||
CompleteTaskCount int `json:"completeTaskCount" gorm:"column:complete_task_count"`
|
||
|
||
// 脚本
|
||
UploadedVideoScriptCount int `json:"uploadedVideoScriptCount" gorm:"column:uploaded_video_script_count"`
|
||
PendingVideoScriptCount int `json:"pendingVideoScriptCount" gorm:"column:pending_video_script_count"`
|
||
|
||
// 可指派数(可上传数 - 已指派且未完成的数量)
|
||
AllowVideoScriptCount int `json:"allowVideoScriptCount" gorm:"column:allow_video_script_count"`
|
||
AllowVideoCount int `json:"allowVideoCount" gorm:"column:allow_video_count"`
|
||
AllowPostCount int `json:"allowPostCount" gorm:"column:allow_post_count"`
|
||
AllowDataCount int `json:"allowDataCount" gorm:"column:allow_data_count"`
|
||
}
|
||
|
||
// ArtistPendingAssignItem 艺人可指派数量(可上传数 - 已指派且未完成的数量)
|
||
type ArtistPendingAssignItem struct {
|
||
SubNum string `json:"subNum" gorm:"column:customer_num"`
|
||
TelNum string `json:"telNum" gorm:"column:tel_num"`
|
||
UserName string `json:"userName" gorm:"column:user_name"`
|
||
AllowVideoScriptCount int `json:"allowVideoScriptCount" gorm:"column:allow_video_script_count"`
|
||
AllowVideoCount int `json:"allowVideoCount" gorm:"column:allow_video_count"`
|
||
AllowPostCount int `json:"allowPostCount" gorm:"column:allow_post_count"`
|
||
AllowDataCount int `json:"allowDataCount" gorm:"column:allow_data_count"`
|
||
}
|
||
|
||
// CreateTaskWorkLogRequest 创建任务日志请求参数
|
||
type CreateTaskWorkLogRequest struct {
|
||
AssignRecordsUUID string `json:"assignRecordsUUID"` // 任务指派记录UUID(必填)
|
||
WorkUUID string `json:"workUUID"` // 任务作品UUID(必填)
|
||
Title string `json:"title"` // 任务作品标题
|
||
|
||
ArtistUUID string `json:"artistUUID"` // 任务艺人UUID
|
||
SubNum string `json:"subNum"` // 任务用户编号(必填)
|
||
TelNum string `json:"telNum"` // 任务用户手机号(必填)
|
||
ArtistName string `json:"artistName"` // 任务艺人名称
|
||
|
||
// 操作信息
|
||
OperationType int `json:"operationType"` // 任务操作类型 1:加任务 2:消耗任务 3:完成任务 4:任务过期(必填)
|
||
TaskType int `json:"taskType"` // 任务类型 1:视频 2:图片 3:数据分析(必填)
|
||
TaskCount int `json:"taskCount"` // 任务数量(必填)
|
||
Remark string `json:"remark"` // 任务备注
|
||
|
||
// 操作人信息
|
||
OperatorName string `json:"operatorName"` // 任务操作人姓名
|
||
OperatorNum string `json:"operatorNum"` // 任务操作人账号
|
||
}
|