DeviceChargingHistoryDto.java 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404
  1. package com.xy.dto;
  2. import com.alibaba.excel.annotation.ExcelProperty;
  3. import com.alibaba.excel.annotation.format.NumberFormat;
  4. import com.fasterxml.jackson.annotation.JsonFormat;
  5. import com.xy.annotate.DictFormat;
  6. import com.xy.consts.DictConsts;
  7. import com.xy.convert.CustomFenToYuanConverter;
  8. import com.xy.convert.DictConvert;
  9. import com.xy.utils.PageBean;
  10. import io.swagger.annotations.ApiModelProperty;
  11. import lombok.Data;
  12. import lombok.experimental.Accessors;
  13. import java.time.LocalDateTime;
  14. import java.util.List;
  15. /**
  16. * <p>
  17. * 设备计费历史表
  18. * </p>
  19. *
  20. * @author lijin
  21. * @since 2023-04-14
  22. */
  23. public class DeviceChargingHistoryDto {
  24. @Data
  25. @Accessors(chain = true)
  26. public static class MySpendPageVO {
  27. @ApiModelProperty(value = "id")
  28. private Long id;
  29. @ApiModelProperty(value = "商户id")
  30. private Long mercId;
  31. @ApiModelProperty(value = "订单id")
  32. private String orderId;
  33. @ApiModelProperty(value = "设备id")
  34. private Long deviceId;
  35. @ApiModelProperty(value = "续费金额")
  36. private Integer chargingMoney;
  37. @ApiModelProperty(value = "佣金")
  38. private Integer agentMoney;
  39. @ApiModelProperty(value = "续费数量")
  40. private Integer chargingSize;
  41. @ApiModelProperty(value = "续费方式")
  42. private Integer chargingType;
  43. @ApiModelProperty(value = "状态")
  44. private Integer status;
  45. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  46. @ApiModelProperty(value = "创建时间")
  47. private LocalDateTime createTime;
  48. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  49. @ApiModelProperty(value = "更新时间")
  50. private LocalDateTime updateTime;
  51. @ApiModelProperty(value = "备注")
  52. private String note;
  53. @ApiModelProperty(value = "附件")
  54. private String files;
  55. @ApiModelProperty(value = "商户名称")
  56. private String mercName;
  57. @ApiModelProperty(value = "过期时间")
  58. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  59. private LocalDateTime timeout;
  60. @ApiModelProperty(value = "过期状态说明")
  61. private String timeoutStatus;
  62. }
  63. @Data
  64. @Accessors(chain = true)
  65. public static class PageVo {
  66. @ApiModelProperty(value = "id")
  67. private Long id;
  68. @ApiModelProperty(value = "商户id")
  69. private Long mercId;
  70. @ApiModelProperty(value = "订单id")
  71. private String orderId;
  72. @ApiModelProperty(value = "设备id")
  73. private Long deviceId;
  74. @ApiModelProperty(value = "续费金额")
  75. private Integer chargingMoney;
  76. @ApiModelProperty(value = "佣金")
  77. private Integer agentMoney;
  78. @ApiModelProperty(value = "续费数量")
  79. private Integer chargingSize;
  80. @ApiModelProperty(value = "续费方式")
  81. private Integer chargingType;
  82. @ApiModelProperty(value = "状态")
  83. private Integer status;
  84. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  85. @ApiModelProperty(value = "创建时间")
  86. private LocalDateTime createTime;
  87. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  88. @ApiModelProperty(value = "更新时间")
  89. private LocalDateTime updateTime;
  90. @ApiModelProperty(value = "备注")
  91. private String note;
  92. @ApiModelProperty(value = "附件")
  93. private String files;
  94. @ApiModelProperty(value = "商户名称")
  95. private String mercName;
  96. @ApiModelProperty(value = "过期时间")
  97. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  98. private LocalDateTime timeout;
  99. @ApiModelProperty(value = "过期状态说明")
  100. private String timeoutStatus;
  101. }
  102. @Data
  103. @Accessors(chain = true)
  104. public static class PageExcelVo {
  105. @ExcelProperty("商户名称")
  106. @ApiModelProperty(value = "商户名称")
  107. private String mercName;
  108. @ExcelProperty("缴费单号")
  109. @ApiModelProperty(value = "缴费单号")
  110. private String orderId;
  111. @ExcelProperty("设备编号")
  112. @ApiModelProperty(value = "设备编号")
  113. private Long deviceId;
  114. @ExcelProperty(value = "实缴金额", converter = CustomFenToYuanConverter.class)
  115. @NumberFormat("#0.00")
  116. @ApiModelProperty(value = "续费金额")
  117. private Integer chargingMoney;
  118. @ApiModelProperty(value = "佣金")
  119. @ExcelProperty(value = "佣金", converter = CustomFenToYuanConverter.class)
  120. @NumberFormat("#0.00")
  121. private Integer agentMoney;
  122. @ExcelProperty("续费数量(年)")
  123. @ApiModelProperty(value = "续费数量")
  124. private Integer chargingSize;
  125. @ExcelProperty(value = "续费方式", converter = DictConvert.class)
  126. @DictFormat(DictConsts.ORDER_MERC_MANAGE_PAY_TYPE)
  127. @ApiModelProperty(value = "续费方式")
  128. private Integer chargingType;
  129. @ExcelProperty("缴费时间")
  130. @ApiModelProperty(value = "创建时间")
  131. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  132. private LocalDateTime createTime;
  133. @ExcelProperty("过期时间")
  134. @ApiModelProperty(value = "过期时间")
  135. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  136. private LocalDateTime timeout;
  137. @ExcelProperty("状态说明")
  138. @ApiModelProperty(value = "过期状态说明")
  139. private String timeoutStatus;
  140. }
  141. @Data
  142. @Accessors(chain = true)
  143. public static class SpendPageExcelVo {
  144. @ExcelProperty("商户名称")
  145. @ApiModelProperty(value = "商户名称")
  146. private String mercName;
  147. @ExcelProperty("缴费单号")
  148. @ApiModelProperty(value = "缴费单号")
  149. private String orderId;
  150. @ExcelProperty("设备编号")
  151. @ApiModelProperty(value = "设备编号")
  152. private Long deviceId;
  153. @ExcelProperty(value = "实缴金额", converter = CustomFenToYuanConverter.class)
  154. @NumberFormat("#0.00")
  155. @ApiModelProperty(value = "续费金额")
  156. private Integer chargingMoney;
  157. @ExcelProperty("续费数量(年)")
  158. @ApiModelProperty(value = "续费数量")
  159. private Integer chargingSize;
  160. @ExcelProperty(value = "续费方式", converter = DictConvert.class)
  161. @DictFormat(DictConsts.ORDER_MERC_MANAGE_PAY_TYPE)
  162. @ApiModelProperty(value = "续费方式")
  163. private Integer chargingType;
  164. @ExcelProperty("缴费时间")
  165. @ApiModelProperty(value = "创建时间")
  166. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  167. private LocalDateTime createTime;
  168. @ExcelProperty("过期时间")
  169. @ApiModelProperty(value = "过期时间")
  170. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  171. private LocalDateTime timeout;
  172. @ExcelProperty("状态说明")
  173. @ApiModelProperty(value = "过期状态说明")
  174. private String timeoutStatus;
  175. }
  176. @Data
  177. @Accessors(chain = true)
  178. public static class Vo {
  179. @ApiModelProperty(value = "id")
  180. private Long id;
  181. @ApiModelProperty(value = "商户id")
  182. private Long mercId;
  183. @ApiModelProperty(value = "订单id")
  184. private String orderId;
  185. @ApiModelProperty(value = "设备id")
  186. private Long deviceId;
  187. @ApiModelProperty(value = "续费金额")
  188. private Integer chargingMoney;
  189. @ApiModelProperty(value = "续费数量")
  190. private Integer chargingSize;
  191. @ApiModelProperty(value = "续费方式")
  192. private Integer chargingType;
  193. @ApiModelProperty(value = "状态")
  194. private Integer status;
  195. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  196. @ApiModelProperty(value = "创建时间")
  197. private LocalDateTime createTime;
  198. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  199. @ApiModelProperty(value = "更新时间")
  200. private LocalDateTime updateTime;
  201. @ApiModelProperty(value = "备注")
  202. private String note;
  203. @ApiModelProperty(value = "商户名称")
  204. private String mercName;
  205. @ApiModelProperty(value = "附件")
  206. private String files;
  207. @ApiModelProperty(value = "余额抵扣")
  208. private Integer balanceMone;
  209. }
  210. @Data
  211. @Accessors(chain = true)
  212. public static class Page extends Vo {
  213. @ApiModelProperty("分页对象")
  214. private PageBean page;
  215. @ApiModelProperty(value = "创建时间-起")
  216. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  217. private LocalDateTime beginCreateTime;
  218. @ApiModelProperty(value = "创建时间-始")
  219. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  220. private LocalDateTime endCreateTime;
  221. }
  222. @Data
  223. @Accessors(chain = true)
  224. public static class PageByTopMerc {
  225. @ApiModelProperty("分页对象")
  226. private PageBean page;
  227. @ApiModelProperty("是否导出当前页")
  228. private Boolean exportPage = true;
  229. @ApiModelProperty(value = "创建时间-起")
  230. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  231. private LocalDateTime beginCreateTime;
  232. @ApiModelProperty(value = "创建时间-始")
  233. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  234. private LocalDateTime endCreateTime;
  235. @ApiModelProperty(value = "id")
  236. private Long id;
  237. @ApiModelProperty(value = "商户id")
  238. private Long curMercId;
  239. @ApiModelProperty(value = "指定商户id")
  240. private Long chooseMercId;
  241. @ApiModelProperty(value = "订单id")
  242. private String orderId;
  243. @ApiModelProperty(value = "设备id")
  244. private Long deviceId;
  245. @ApiModelProperty(value = "续费金额")
  246. private Integer chargingMoney;
  247. @ApiModelProperty(value = "续费数量")
  248. private Integer chargingSize;
  249. @ApiModelProperty(value = "续费方式")
  250. private Integer chargingType;
  251. @ApiModelProperty(value = "状态")
  252. private Integer status;
  253. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  254. @ApiModelProperty(value = "创建时间")
  255. private LocalDateTime createTime;
  256. @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  257. @ApiModelProperty(value = "更新时间")
  258. private LocalDateTime updateTime;
  259. @ApiModelProperty(value = "备注")
  260. private String note;
  261. @ApiModelProperty(value = "附件")
  262. private String files;
  263. @ApiModelProperty(value = "商户名称")
  264. private String mercName;
  265. // size -1 不分页
  266. public PageBean getPage() {
  267. if (!this.exportPage) {
  268. this.page.setSize(-1L);
  269. }
  270. return page;
  271. }
  272. }
  273. @Data
  274. @Accessors(chain = true)
  275. public static class MoonCount {
  276. @ApiModelProperty(value = "商户id")
  277. private List<Long> mercIds;
  278. @ApiModelProperty(value = "统计时间-起 yyyy-MM")
  279. private String beginDate;
  280. @ApiModelProperty(value = "统计时间-始 yyyy-MM")
  281. private String endDate;
  282. }
  283. @Data
  284. @Accessors(chain = true)
  285. public static class MoonCountVo {
  286. @ApiModelProperty(value = "统计时间 yyyy-MM")
  287. private String date;
  288. @ApiModelProperty(value = "商户id")
  289. private Long mercId;
  290. @ApiModelProperty(value = "商户名称")
  291. private String mercName;
  292. @ApiModelProperty(value = "设备数")
  293. private Integer deviceSize;
  294. @ApiModelProperty(value = "续费金额")
  295. private Integer chargingMoney;
  296. }
  297. @Data
  298. @Accessors(chain = true)
  299. public static class MoonCountPage {
  300. @ApiModelProperty(value = "分页对象")
  301. private PageBean page;
  302. @ApiModelProperty(value = "商户id")
  303. private List<Long> mercIds;
  304. @ApiModelProperty(value = "统计时间-起 yyyy-MM-dd")
  305. private String beginDate;
  306. @ApiModelProperty(value = "统计时间-始 yyyy-MM-dd")
  307. private String endDate;
  308. }
  309. }