image_record.go 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150
  1. package levelMonitor
  2. import (
  3. "log-server/model/typeManage"
  4. )
  5. type ImageRecord struct {
  6. Id int `json:"id"`
  7. TaskId int `json:"task_id"` //任务id
  8. Account string `json:"account"` //账号
  9. ImageBase64 string `json:"image_base64"` //图片base64文本
  10. Status int `json:"status"` //识别状态, 成功为1, 失败-1, 默认为2未识别
  11. IsCanPay int `json:"is_can_pay"` //是否可付费, 1为可付费
  12. Result string `json:"result"` //识别结果
  13. CreateDate string `json:"create_date"` //创建日期
  14. CreateTime typeManage.LocalTime `json:"create_time"`
  15. UpdateTime typeManage.LocalTime `json:"update_time"`
  16. UseNum int `json:"use_num"` //账号登录成功次数
  17. Identify float64 `json:"identify"` //图片识别的内容
  18. }
  19. type ImageRecordResponse struct {
  20. Id int `json:"id"`
  21. TaskId int `json:"task_id"` //任务id
  22. User string `json:"user"`
  23. TaskName string `json:"task_name"`
  24. Account string `json:"account"` //账号
  25. ImageBase64 string `json:"image_base64"` //图片base64文本
  26. Status int `json:"status"` //识别状态, 成功为1, 失败-1, 默认为2未识别
  27. IsCanPay int `json:"is_can_pay"` //是否可付费, 1为可付费
  28. Result string `json:"result"` //识别结果
  29. CreateDate string `json:"create_date"` //创建日期
  30. CreateTime typeManage.LocalTime `json:"create_time"`
  31. UpdateTime typeManage.LocalTime `json:"update_time"`
  32. UseNum int `json:"use_num"` //账号登录成功次数
  33. Identify float64 `json:"identify"` //图片识别的内容
  34. }
  35. func (ImageRecord) TableName() string {
  36. return "image_record"
  37. }
  38. type ImageRecordStatistics struct {
  39. Id int `json:"id"`
  40. TaskId int `json:"task_id"` //任务id
  41. CreateDate string `json:"create_date"` //创建日期
  42. Two float64 `json:"two"`
  43. Three float64 `json:"three"`
  44. Four float64 `json:"four"`
  45. Five float64 `json:"five"`
  46. Six float64 `json:"six"`
  47. Seven float64 `json:"seven"`
  48. Eight float64 `json:"eight"`
  49. Nine float64 `json:"nine"`
  50. Ten float64 `json:"ten"`
  51. Eleven float64 `json:"eleven"`
  52. Twelve float64 `json:"twelve"`
  53. Thirteen float64 `json:"thirteen"`
  54. Fourteen float64 `json:"fourteen"`
  55. Fifteen float64 `json:"fifteen"`
  56. Sixteen float64 `json:"sixteen"`
  57. Seventeen float64 `json:"seventeen"`
  58. Eighteen float64 `json:"eighteen"`
  59. Nineteen float64 `json:"nineteen"`
  60. Twenty float64 `json:"twenty"`
  61. TwentyOne float64 `json:"twenty_one"`
  62. TwentyTwo float64 `json:"twenty_two"`
  63. TwentyThree float64 `json:"twenty_three"`
  64. TwentyFour float64 `json:"twenty_four"`
  65. TwentyFive float64 `json:"twenty_five"`
  66. TwentySix float64 `json:"twenty_six"`
  67. TwentySeven float64 `json:"twenty_seven"`
  68. TwentyEight float64 `json:"twenty_eight"`
  69. TwentyNine float64 `json:"twenty_nine"`
  70. Thirty float64 `json:"thirty"`
  71. }
  72. type ImageRecordStatisticsResponse struct {
  73. Id int `json:"id"`
  74. TaskId int `json:"task_id"` //任务id
  75. User string `json:"user"` //负责人
  76. TaskName string `json:"task_name"` //任务名称
  77. CreateDate string `json:"create_date"` //创建日期
  78. Two float64 `json:"two"`
  79. Three float64 `json:"three"`
  80. Four float64 `json:"four"`
  81. Five float64 `json:"five"`
  82. Six float64 `json:"six"`
  83. Seven float64 `json:"seven"`
  84. Eight float64 `json:"eight"`
  85. Nine float64 `json:"nine"`
  86. Ten float64 `json:"ten"`
  87. Eleven float64 `json:"eleven"`
  88. Twelve float64 `json:"twelve"`
  89. Thirteen float64 `json:"thirteen"`
  90. Fourteen float64 `json:"fourteen"`
  91. Fifteen float64 `json:"fifteen"`
  92. Sixteen float64 `json:"sixteen"`
  93. Seventeen float64 `json:"seventeen"`
  94. Eighteen float64 `json:"eighteen"`
  95. Nineteen float64 `json:"nineteen"`
  96. Twenty float64 `json:"twenty"`
  97. TwentyOne float64 `json:"twenty_one"`
  98. TwentyTwo float64 `json:"twenty_two"`
  99. TwentyThree float64 `json:"twenty_three"`
  100. TwentyFour float64 `json:"twenty_four"`
  101. TwentyFive float64 `json:"twenty_five"`
  102. TwentySix float64 `json:"twenty_six"`
  103. TwentySeven float64 `json:"twenty_seven"`
  104. TwentyEight float64 `json:"twenty_eight"`
  105. TwentyNine float64 `json:"twenty_nine"`
  106. Thirty float64 `json:"thirty"`
  107. }
  108. func (ImageRecordStatistics) TableName() string {
  109. return "image_record_statistics"
  110. }
  111. var R = map[int]string{
  112. 2: "two",
  113. 3: "three",
  114. 4: "four",
  115. 5: "five",
  116. 6: "six",
  117. 7: "seven",
  118. 8: "eight",
  119. 9: "nine",
  120. 10: "ten",
  121. 11: "eleven",
  122. 12: "twelve",
  123. 13: "thirteen",
  124. 14: "fourteen",
  125. 15: "fifteen",
  126. 16: "sixteen",
  127. 17: "seventeen",
  128. 18: "eighteen",
  129. 19: "nineteen",
  130. 20: "twenty",
  131. 21: "twenty_one",
  132. 22: "twenty_two",
  133. 23: "twenty_three",
  134. 24: "twenty_four",
  135. 25: "twenty_five",
  136. 26: "twenty_six",
  137. 27: "twenty_seven",
  138. 28: "twenty_eight",
  139. 29: "twenty_nine",
  140. 30: "thirty",
  141. }