selection_task.go 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163
  1. package youngee_talent_model
  2. import (
  3. "github.com/gogf/gf/os/gtime"
  4. "github.com/gogf/gf/util/gmeta"
  5. "youngmini_server/app/model"
  6. )
  7. type SignSecTaskReq struct {
  8. SelectionId string `json:"selection_id"`
  9. ProductId int `json:"product_id"`
  10. AddressId uint64 `json:"address_id"`
  11. LeadTeamId string `json:"lead_team_id"`
  12. TeamId string `json:"team_id"`
  13. SaleNum int `json:"saleNum"`
  14. FansNum int `json:"fans"`
  15. }
  16. type SignSecTaskResp struct {
  17. TaskId string `json:"task_id"`
  18. }
  19. type SecTaskInfoDetail struct {
  20. gmeta.Meta `orm:"table:younggee_sec_task_info"`
  21. Id int `orm:"id,primary" json:"id"` // 递增id
  22. TaskId string `orm:"task_id" json:"task_id"` // 选品任务id
  23. SelectionId string `orm:"selection_id" json:"selection_id"` // 选品id
  24. ProductId int `orm:"product_id" json:"product_id"`
  25. TalentId string `orm:"talent_id" json:"talent_id"` // 达人id
  26. AccountId int `orm:"account_id" json:"account_id"` // 账号id
  27. PlatformId int `orm:"platform_id" json:"platform_id"` // 平台id
  28. TalentPlatformInfoSnap string `orm:"talent_platform_info_snap" json:"talent_platform_info_snap"` // 达人平台信息快照
  29. TalentPersonalInfoSnap string `orm:"talent_personal_info_snap" json:"talent_personal_info_snap"` // 达人个人信息快照
  30. TalentPostAddrSnap string `orm:"talent_post_addr_snap" json:"talent_post_addr_snap"` // 收货地址快照
  31. TaskReward float64 `orm:"task_reward" json:"task_reward"` // 达人赏金
  32. TalentPayment float64 `orm:"talent_payment" json:"talent_payment"` // 达人垫付金额
  33. IsPayPayment int `orm:"is_pay_payment" json:"is_pay_payment"` // 企业是否返样品钱
  34. IsPayReward int `orm:"is_pay_reward" json:"is_pay_reward"` // 企业是否结算悬赏
  35. TaskMode int `orm:"task_mode" json:"task_mode"` // 任务形式,1、2分别表示悬赏任务、纯佣带货',
  36. SampleMode int `orm:"sample_mode" json:"sample_mode"` // 领样形式,1-3分别表示免费领样、垫付买样、不提供样品
  37. TaskStatus int `orm:"task_status" json:"task_status"` // 任务状态 1待选 2已选 3落选
  38. TaskStage int `orm:"task_stage" json:"task_stage"` // 任务阶段,详情见info_sec_task_stage表
  39. CreateDate *gtime.Time `orm:"create_date" json:"create_date"` // 创建时间
  40. SelectDate *gtime.Time `orm:"select_date" json:"select_date"` // 反选时间
  41. DeliveryDate *gtime.Time `orm:"delivery_date" json:"delivery_date"` // 发货时间
  42. CompleteDate *gtime.Time `orm:"complete_date" json:"complete_date"` // 结束时间
  43. WithdrawDate *gtime.Time `orm:"withdraw_date" json:"withdraw_date"` // 提现时间
  44. CompleteStatus int `orm:"complete_status" json:"complete_status"` // 结束方式 1未结束 2正常结束 3反选失败
  45. LogisticsStatus int `orm:"logistics_status" json:"logistics_status"` // 发货状态 1 待发货 2已发货 3 已签收
  46. AssignmentStatus uint `orm:"assignment_status" json:"assignment_status"` // 作业上传状态 1-5分别代表待添加、已添加、待修改、已修改、已通过
  47. UpdateAt *gtime.Time `orm:"update_at" json:"update_at"` // 更新时间
  48. WithdrawStatus int `orm:"withdraw_status" json:"withdraw_status"` // 提现状态,1-4分别代表不可提现、可提现、提现中、已提现
  49. LeadTeamId string `orm:"lead_team_id" json:"lead_team_id"` // 作为团长的young之团id,对应younggee_talent_team中的team_id字段
  50. TeamId string `orm:"team_id" json:"team_id"` // 作为团员的young之团id,对应younggee_talent_team中的team_id字段
  51. TeamIncome int `orm:"team_income" json:"team_income"` // young之团团长现金收益
  52. TeamPoint int `orm:"team_point" json:"team_point"` // young之团团长积分收益
  53. FansNum int `orm:"fans_num" json:"fans_num"` // 粉丝数
  54. SaleNum int `orm:"sale_num" json:"sale_num"` // 30天橱窗销量
  55. FreeStage int `orm:"free_stage" json:"free_stage"` // 免费领样阶段,1-5分别代表已申请、已拒绝、待发货、已发货、已收货',
  56. RewardStage int `orm:"reward_stage" json:"reward_stage"` //悬赏阶段,1-2分别代表待结算、已结算',
  57. SaleActual int `orm:"sale_actual" json:"sale_actual"`
  58. SaleNumAll int `orm:"sale_num_all" json:"sale_num_all"` //达人对此商品的全部销售量(大于1表示已出单)
  59. RewardStrategy []*RewardStrategy `orm:"with:selection_id=selection_id"` // 悬赏策略表
  60. SelectionInfo *model.YounggeeSelectionInfo `orm:"with:selection_id=selection_id"` //选品表
  61. YounggeeProduct *YounggeeProduct `orm:"with:product_id=product_id"` // 商品基本表
  62. YounggeeProductPhoto []*YounggeeProductPhoto `orm:"with:product_id=product_id"` // 商品图片表
  63. PlatformInfo *PlatformInfo `orm:"with:platform_id=platform_id"`
  64. TaskDdl *gtime.Time `json:"task_ddl"`
  65. }
  66. type SecTaskInfoWindowDetail struct {
  67. gmeta.Meta `orm:"table:younggee_sec_task_info"`
  68. Id int `orm:"id,primary" json:"id"` // 递增id
  69. TaskId string `orm:"task_id" json:"task_id"` // 选品任务id
  70. SelectionId string `orm:"selection_id" json:"selection_id"` // 选品id
  71. ProductId int `orm:"product_id" json:"product_id"`
  72. TalentId string `orm:"talent_id" json:"talent_id"` // 达人id
  73. AccountId int `orm:"account_id" json:"account_id"` // 账号id
  74. PlatformId int `orm:"platform_id" json:"platform_id"` // 平台id
  75. TalentPlatformInfoSnap string `orm:"talent_platform_info_snap" json:"talent_platform_info_snap"` // 达人平台信息快照
  76. TalentPersonalInfoSnap string `orm:"talent_personal_info_snap" json:"talent_personal_info_snap"` // 达人个人信息快照
  77. //TalentPostAddrSnap string `orm:"talent_post_addr_snap" json:"talent_post_addr_snap"` // 收货地址快照 加入橱窗不需要收获地址
  78. TaskReward float64 `orm:"task_reward" json:"task_reward"` // 达人赏金
  79. TalentPayment float64 `orm:"talent_payment" json:"talent_payment"` // 达人垫付金额
  80. IsPayPayment int `orm:"is_pay_payment" json:"is_pay_payment"` // 企业是否返样品钱
  81. IsPayReward int `orm:"is_pay_reward" json:"is_pay_reward"` // 企业是否结算悬赏
  82. TaskMode int `orm:"task_mode" json:"task_mode"` // 任务形式,1、2分别表示悬赏任务、纯佣带货',
  83. SampleMode int `orm:"sample_mode" json:"sample_mode"` // 领样形式,1-3分别表示免费领样、垫付买样、不提供样品
  84. TaskStatus int `orm:"task_status" json:"task_status"` // 任务状态 1待选 2已选 3落选
  85. TaskStage int `orm:"task_stage" json:"task_stage"` // 任务阶段,详情见info_sec_task_stage表
  86. CreateDate *gtime.Time `orm:"create_date" json:"create_date"` // 创建时间
  87. SelectDate *gtime.Time `orm:"select_date" json:"select_date"` // 反选时间
  88. DeliveryDate *gtime.Time `orm:"delivery_date" json:"delivery_date"` // 发货时间
  89. CompleteDate *gtime.Time `orm:"complete_date" json:"complete_date"` // 结束时间
  90. WithdrawDate *gtime.Time `orm:"withdraw_date" json:"withdraw_date"` // 提现时间
  91. CompleteStatus int `orm:"complete_status" json:"complete_status"` // 结束方式 1未结束 2正常结束 3反选失败
  92. LogisticsStatus int `orm:"logistics_status" json:"logistics_status"` // 发货状态 1 待发货 2已发货 3 已签收
  93. AssignmentStatus uint `orm:"assignment_status" json:"assignment_status"` // 作业上传状态 1-5分别代表待添加、已添加、待修改、已修改、已通过
  94. UpdateAt *gtime.Time `orm:"update_at" json:"update_at"` // 更新时间
  95. WithdrawStatus int `orm:"withdraw_status" json:"withdraw_status"` // 提现状态,1-4分别代表不可提现、可提现、提现中、已提现
  96. LeadTeamId string `orm:"lead_team_id" json:"lead_team_id"` // 作为团长的young之团id,对应younggee_talent_team中的team_id字段
  97. TeamId string `orm:"team_id" json:"team_id"` // 作为团员的young之团id,对应younggee_talent_team中的team_id字段
  98. TeamIncome int `orm:"team_income" json:"team_income"` // young之团团长现金收益
  99. TeamPoint int `orm:"team_point" json:"team_point"` // young之团团长积分收益
  100. FansNum int `orm:"fans_num" json:"fans_num"` // 粉丝数
  101. SaleNum int `orm:"sale_num" json:"sale_num"` // 30天橱窗销量
  102. FreeStage int `orm:"free_stage" json:"free_stage"` // 免费领样阶段,1-5分别代表已申请、已拒绝、待发货、已发货、已收货',
  103. RewardStage int `orm:"reward_stage" json:"reward_stage"` //悬赏阶段,1-2分别代表待结算、已结算',
  104. SaleActual int `orm:"sale_actual" json:"sale_actual"`
  105. SaleNumAll int `orm:"sale_num_all" json:"sale_num_all"` //达人对此商品的全部销售量(大于1表示已出单)
  106. RewardStrategy []*RewardStrategy `orm:"with:selection_id=selection_id"` // 悬赏策略表
  107. SelectionInfo *model.YounggeeSelectionInfo `orm:"with:selection_id=selection_id"` //选品表
  108. YounggeeProduct *YounggeeProduct `orm:"with:product_id=product_id"` // 商品基本表
  109. YounggeeProductPhoto []*YounggeeProductPhoto `orm:"with:product_id=product_id"` // 商品图片表
  110. PlatformInfo *PlatformInfo `orm:"with:platform_id=platform_id"`
  111. TaskDdl *gtime.Time `json:"task_ddl"`
  112. }
  113. type SecTaskInfoBrief struct {
  114. TaskId string `json:"task_id"` // 选品任务id
  115. SelectionId string `json:"selection_id"` // 选品id
  116. ProductId int `json:"product_id"` // 商品id
  117. TalentId string `json:"talent_id"` // 达人id
  118. AccountId int `json:"account_id"` // 账号id
  119. TalentPlatformInfoSnap string `json:"talent_platform_info_snap"` // 达人平台信息快照
  120. TalentPersonalInfoSnap string `json:"talent_personal_info_snap"` // 达人个人信息快照
  121. TalentPostAddrSnap string `json:"talent_post_addr_snap"` // 收货地址快照
  122. TaskReward float64 `json:"task_reward"` // 达人赏金
  123. TalentPayment float64 `json:"talent_payment"` // 达人垫付金额
  124. IsPayPayment int `json:"is_pay_payment"` // 企业是否返样品钱
  125. IsPayReward int `json:"is_pay_reward"` // 企业是否结算悬赏
  126. TaskMode int `json:"task_mode"` // 任务形式,1、2分别表示纯佣带货、悬赏任务
  127. SampleMode int `json:"sample_mode"` // 领样形式,1-3分别表示免费领样、垫付买样、不提供样品
  128. TaskStatus int `json:"task_status"` // 任务状态 1待选 2已选 3落选
  129. TaskStage int `json:"task_stage"` // 任务阶段,详情见info_sec_task_stage表
  130. CreateDate *gtime.Time `json:"create_date"` // 创建时间
  131. SelectDate *gtime.Time `json:"select_date"` // 反选时间
  132. DeliveryDate *gtime.Time `json:"delivery_date"` // 发货时间
  133. CompleteDate *gtime.Time `json:"complete_date"` // 结束时间
  134. WithdrawDate *gtime.Time `json:"withdraw_date"` // 提现时间
  135. CompleteStatus int `json:"complete_status"` // 结束方式 1未结束 2正常结束 3反选失败
  136. LogisticsStatus int `json:"logistics_status"` // 发货状态 1 待发货 2已发货 3 已签收
  137. AssignmentStatus uint `json:"assignment_status"` // 作业上传状态 1-5分别代表待添加、已添加、待修改、已修改、已通过
  138. UpdateAt *gtime.Time `json:"update_at"` // 更新时间
  139. WithdrawStatus int `json:"withdraw_status"` // 提现状态,1-4分别代表不可提现、可提现、提现中、已提现
  140. LeadTeamId string `json:"lead_team_id"` // 作为团长的young之团id,对应younggee_talent_team中的team_id字段
  141. TeamId string `json:"team_id"` // 作为团员的young之团id,对应younggee_talent_team中的team_id字段
  142. TeamIncome float64 `json:"team_income"` // young之团团长现金收益
  143. TeamPoint int `json:"team_point"` // young之团团长积分收益
  144. PlatformIconUrl string `json:"platform_icon_url"`
  145. PlatformName string `json:"platform_name"`
  146. PlatformNickName string `json:"platform_nick_name"`
  147. SelectionName string `json:"selection_name"`
  148. ProductPhotoSnap string `json:"product_photo_snap"`
  149. //YounggeeProductPhoto *[]model.YounggeeProductPhoto // 商品图片表
  150. TaskDdl *gtime.Time `json:"task_ddl"`
  151. }
  152. type SecTaskDetailResp struct {
  153. SecTaskInfo *SecTaskInfoDetail `json:"sec_task_info"`
  154. SelectionDetail *SelectionDetail `json:"selection_detail"`
  155. WithdrawStatus int `json:"withdraw_status"`
  156. }