search.go 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172
  1. package search
  2. import (
  3. "go-common/app/admin/main/videoup/model/manager"
  4. account "go-common/app/service/main/account/api"
  5. )
  6. // VideoResultData search video return struct
  7. type VideoResultData struct {
  8. Page struct {
  9. Num int `json:"num"`
  10. Size int `json:"size"`
  11. Total int `json:"total"`
  12. } `json:"page"`
  13. Result []*Video `json:"result"`
  14. }
  15. type ArchiveResultData struct {
  16. Page struct {
  17. Num int `json:"num"`
  18. Size int `json:"size"`
  19. Total int `json:"total"`
  20. } `json:"page"`
  21. Result []*Archive `json:"result"`
  22. Tips string `json:"_tips"`
  23. MoniAids map[int64]int `json:"moni_aids"`
  24. }
  25. // CopyrightResultData search copyright return struct
  26. type CopyrightResultData struct {
  27. Page struct {
  28. Num int `json:"num"`
  29. Size int `json:"size"`
  30. Total int `json:"total"`
  31. } `json:"page"`
  32. Result []*Copyright `json:"result"`
  33. }
  34. // Video search return video item struct
  35. type Video struct {
  36. ID int64 `json:"id"`
  37. Aid int64 `json:"aid"`
  38. Cid int64 `json:"cid"`
  39. Vid int64 `json:"vid"`
  40. ArcTitle string `json:"arc_title"`
  41. ArcState int `json:"arc_state"` //稿件状态。
  42. RelationState int `json:"relation_state"`
  43. State int `json:"state"`
  44. Status int `json:"status"` //视频状态。如果archive_video_relation的state被删除,则此Status为-100;否则此Status为video表的status
  45. ArcTypeID int64 `json:"arc_typeid"`
  46. ArcMid int64 `json:"arc_mid"`
  47. ArcAuthor string `json:"arc_author"`
  48. ArcSendDate string `json:"arc_senddate"`
  49. Duration int64 `json:"duration"`
  50. Filename string `json:"filename"`
  51. MTime string `json:"mtime"`
  52. TagID int64 `json:"tag_id"`
  53. TagName string `json:"tag_name"`
  54. UserType []int64 `json:"user_type"`
  55. UserGroup []*manager.UpGroup `json:"user_group"`
  56. CTime string `json:"ctime"`
  57. VCTime string `json:"v_ctime"`
  58. VMTime string `json:"v_mtime"`
  59. XcodeState int8 `json:"xcode_state"`
  60. }
  61. type Archive struct {
  62. ID int64 `json:"id"`
  63. Mid int64 `json:"mid"`
  64. Official account.OfficialInfo `json:"official_verify"`
  65. TagNames []string `json:"tid_names"`
  66. Access int16 `json:"access"`
  67. Attribute []int `json:"attribute"`
  68. Attrs []int `json:"attrs"`
  69. State int8 `json:"state"`
  70. Author string `json:"author"`
  71. Cover string `json:"cover"`
  72. CTime string `json:"ctime"`
  73. MTime string `json:"mtime"`
  74. PubDate string `json:"pubtime"`
  75. Copyright int8 `json:"copyright"`
  76. FlowID int64 `json:"flow_id"`
  77. MissionID int64 `json:"mission_id"`
  78. OrderID int64 `json:"order_id"`
  79. Round int `json:"round"`
  80. Title string `json:"title"`
  81. Content string `json:"content"`
  82. TypeID int64 `json:"typeid"`
  83. UpFrom int8 `json:"up_from"`
  84. UserType []int64 `json:"user_type"`
  85. UserGroup []*manager.UpGroup2 `json:"user_group"`
  86. }
  87. // Copyright search return copyright item struct
  88. type Copyright struct {
  89. ID int64 `json:"id"`
  90. Name string `json:"name"`
  91. OName string `json:"oname"`
  92. AkaNames string `json:"aka_names"`
  93. Level string `json:"level"`
  94. Avoid string `json:"avoid"`
  95. Plan string `json:"plan"`
  96. Desc string `json:"description"`
  97. URL string `json:"url"`
  98. }
  99. // VideoParams search video params
  100. type VideoParams struct {
  101. Action string `form:"action"`
  102. Status string `form:"status"`
  103. ArcTitle string `form:"arc_title"`
  104. ArcMids string `form:"arc_mids"`
  105. Order string `form:"order"`
  106. Sort int8 `form:"sort_order"`
  107. Keywords string `form:"keywords"`
  108. Aids string `form:"aids"`
  109. Cids string `form:"cids"`
  110. Vids string `form:"vids"`
  111. TypeID string `form:"typeid"`
  112. Filename string `form:"filename"`
  113. TagID string `form:"tag_id"`
  114. Pn int `form:"pn"`
  115. Ps int `form:"ps"`
  116. Xcode string `form:"xcode_state"`
  117. UserType string `form:"user_type"`
  118. OrderType string `form:"order_type"`
  119. DurationFrom string `form:"duration_from"`
  120. DurationTo string `form:"duration_to"`
  121. MonitorList string `form:"monitor_list"`
  122. }
  123. // ArchiveParams search archive params
  124. type ArchiveParams struct {
  125. TypeID string `form:"typeid"`
  126. SpecialType string `form:"special_arctype"`
  127. Round string `form:"round"`
  128. Aids string `form:"aids"`
  129. Mids string `form:"mids"`
  130. Pn int `form:"page"`
  131. Ps int `form:"pagesize"`
  132. OrderType string `form:"order_type"`
  133. Keywords string `form:"keywords"`
  134. KwFields string `form:"kw_fields"`
  135. IsFirst string `form:"is_first"`
  136. IsOrder int8 `form:"execute_order"`
  137. State string `form:"state"`
  138. Access string `form:"access"`
  139. UpFroms string `form:"up_froms"`
  140. PGCList string `form:"pgc_list"`
  141. OrderId string `form:"order_id"`
  142. Attr string `form:"attribute"`
  143. //ChannelReview string `form:"channel_review"`
  144. //HotReview string `form:"hot_review"`
  145. Review string `form:"review"`
  146. ReviewState string `form:"review_state"`
  147. MissionID string `form:"mission_id"`
  148. NoMission string `form:"no_mission"`
  149. UserType string `form:"user_type"`
  150. Copyright string `form:"copyright"`
  151. Order string `form:"order"`
  152. ScoreFirst string `form:"score_first"` //是否按关键字匹配优先
  153. Sort string `form:"sort_order"`
  154. MonitorList string `form:"monitor_list"`
  155. }
  156. // ArcPGCConfig
  157. type ArcPGCConfig struct {
  158. UPFrom []int8
  159. Rounds []int8
  160. States []int8
  161. InState bool
  162. Auth string
  163. }