OrderGoodsVO.java 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105
  1. /*
  2. * Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
  3. *
  4. * Redistribution and use in source and binary forms, with or without
  5. * modification, are permitted provided that the following conditions are met:
  6. *
  7. * Redistributions of source code must retain the above copyright notice,
  8. * this list of conditions and the following disclaimer.
  9. * Redistributions in binary form must reproduce the above copyright
  10. * notice, this list of conditions and the following disclaimer in the
  11. * documentation and/or other materials provided with the distribution.
  12. * Neither the name of the dreamlu.net developer nor the names of its
  13. * contributors may be used to endorse or promote products derived from
  14. * this software without specific prior written permission.
  15. * Author: Chill 庄骞 (smallchill@163.com)
  16. */
  17. package org.springblade.modules.finance.vo;
  18. import io.swagger.annotations.ApiModelProperty;
  19. import org.springblade.common.enums.OrderStateEnum;
  20. import org.springblade.common.enums.PaymentTypeEnum;
  21. import org.springblade.modules.finance.entity.AfterSales;
  22. import org.springblade.modules.finance.entity.AfterSalesGoods;
  23. import org.springblade.modules.finance.entity.OrderGoods;
  24. import lombok.Data;
  25. import lombok.EqualsAndHashCode;
  26. import io.swagger.annotations.ApiModel;
  27. import java.math.BigDecimal;
  28. import java.util.Date;
  29. import java.util.List;
  30. /**
  31. * 商品订单表视图实体类
  32. *
  33. * @author BladeX
  34. * @since 2024-07-17
  35. */
  36. @Data
  37. @EqualsAndHashCode(callSuper = true)
  38. @ApiModel(value = "OrderGoodsVO对象", description = "商品订单表")
  39. public class OrderGoodsVO extends OrderGoods {
  40. private static final long serialVersionUID = 1L;
  41. @ApiModelProperty(value = "订单状态")
  42. private Integer orderState;
  43. @ApiModelProperty(value = "订单状态描述")
  44. private String orderStateDesc;
  45. @ApiModelProperty(value = "订单编号")
  46. private String orderNo;
  47. @ApiModelProperty(value = "客户电话")
  48. private String phone;
  49. @ApiModelProperty(value = "客户昵称")
  50. private String nickname;
  51. @ApiModelProperty(value = "开始时间")
  52. private Date startTime;
  53. @ApiModelProperty(value = "结束时间")
  54. private Date endTime;
  55. @ApiModelProperty(value = "支付方式")
  56. private String payModeDesc;
  57. @ApiModelProperty(value = "支付金额")
  58. private BigDecimal paymentAmount;
  59. @ApiModelProperty(value = "支付方式")
  60. private String paymentMode;
  61. @ApiModelProperty(value = "支付时间")
  62. private Date paymentTime;
  63. @ApiModelProperty(value = "支付状态;1-未支付 2-已支付 3-已退款")
  64. private Integer paymentState;
  65. @ApiModelProperty(value = "总金额")
  66. private BigDecimal totalAmount;
  67. @ApiModelProperty(value = "优惠金额")
  68. private BigDecimal discountAmount;
  69. @ApiModelProperty(value = "是否售后")
  70. private Integer isAfterSales;
  71. @ApiModelProperty(value = "售后实体")
  72. private AfterSales afterSales;
  73. @ApiModelProperty(value = "售后商品")
  74. private List<AfterSalesGoods> afterSalesGoodsList;
  75. public String getPayModeDesc() {
  76. return PaymentTypeEnum.getNameByValue(paymentMode);
  77. }
  78. public String getOrderStateDesc() {
  79. return OrderStateEnum.getNameByValue(orderState);
  80. }
  81. }