trade: 调整退款单

pull/2/head
YunaiV 2022-11-15 19:46:30 +08:00
parent 38f67d4130
commit b8d1d31df0
3 changed files with 93 additions and 47 deletions

View File

@ -0,0 +1,37 @@
package cn.iocoder.yudao.module.trade.enums.aftersale;
import lombok.AllArgsConstructor;
import lombok.Getter;
/**
*
*
* <a href="https://www.processon.com/view/link/63731a270e3e742ce7b7c194"></a>
*
* @author
*/
@AllArgsConstructor
@Getter
public enum TradeAfterSaleStatusEnum {
APPLY(10,"申请中"),
SELLER_PASS(20, "已通过"), // 卖家通过售后
BUYER_RETURN(30,"待卖家收货"), // 买家退货,等待卖家收货
WAIT_REFUND(40, "等待平台退款"), // 卖家收货,等待平台退款
COMPLETE(50, "完成"), // 完成退款
BUYER_CANCEL(61, "买家取消售后"),
SELLER_REFUSE(62,"已拒绝"), // 卖家拒绝售后
SELLER_TERMINATION(63,"卖家终止售后"), // 卖家拒绝收货,终止售后
;
/**
*
*/
private final Integer status;
/**
*
*/
private final String name;
}

View File

@ -1,16 +1,16 @@
package cn.iocoder.yudao.module.trade.enums.refund;
package cn.iocoder.yudao.module.trade.enums.aftersale;
import lombok.Getter;
import lombok.RequiredArgsConstructor;
/**
* 退 -
* -
*
* @author Sin
*/
@RequiredArgsConstructor
@Getter
public enum TradeRefundTypeEnum {
public enum TradeAfterSaleTypeEnum {
REFUND(10, "退款"),
RETURN_AND_REFUND(20, "退货退款");

View File

@ -1,10 +1,10 @@
package cn.iocoder.yudao.module.trade.dal.dataobject.refund;
package cn.iocoder.yudao.module.trade.dal.dataobject.aftersale;
import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO;
import cn.iocoder.yudao.module.trade.dal.dataobject.order.TradeOrderDO;
import cn.iocoder.yudao.module.trade.dal.dataobject.order.TradeOrderItemDO;
import cn.iocoder.yudao.module.trade.enums.order.TradeOrderRefundStatusEnum;
import cn.iocoder.yudao.module.trade.enums.refund.TradeRefundTypeEnum;
import cn.iocoder.yudao.module.trade.enums.aftersale.TradeAfterSaleStatusEnum;
import cn.iocoder.yudao.module.trade.enums.aftersale.TradeAfterSaleTypeEnum;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler;
@ -16,32 +16,38 @@ import java.time.LocalDateTime;
import java.util.List;
/**
* 退 {@link TradeOrderDO} 退
* {@link TradeOrderDO} 退退
*
* @author
*/
// TODO 芋艿:需要调整下每个字段的命名;未完全实现;
@TableName(value = "trade_refund")
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
public class TradeRefundDO extends BaseDO {
public class TradeAfterSaleDO extends BaseDO {
/**
* 退
* n
*/
@Deprecated
private Long id;
/**
* 退
*
*
* 1146347329394184195
*/
private String sn;
private String no;
/**
* 退
*
* {@link TradeOrderRefundStatusEnum}
* {@link TradeAfterSaleStatusEnum}
*/
private Integer status;
/**
*
*
* {@link TradeAfterSaleTypeEnum}
*/
private Integer type;
/**
*
*
@ -49,69 +55,75 @@ public class TradeRefundDO extends BaseDO {
*/
private Long userId;
/**
*
*
*/
private String userMobile;
private String applyReason;
/**
*
*
* {@link TradeRefundTypeEnum}
*
*/
private Integer type;
private String applyDescription;
/**
*
*/
private String reasonMemo; // buyer_msg
/**
*
*
*
*
*/
@TableField(typeHandler = JacksonTypeHandler.class)
private List<String> reasonPicUrls; // photo_files
private List<String> applyPicUrls;
// ========== 商家相关 ==========
/**
*
*
*/
private LocalDateTime handleTime; // handel_time
private LocalDateTime auditTime;
/**
*
*
*
* AdminUserDO id
*/
private String rejectReasonMemo; // seller_msg
private Long auditUserId;
/**
*
*/
private String auditReason;
// ========== 交易订单相关 ==========
/**
*
*
* {@link TradeOrderDO#getId()}
* {@link TradeOrderDO#getId()}
*/
private Long tradeOrderId;
private Long orderId;
/**
*
*
* {@link TradeOrderItemDO#getId()}
* 退 0
*/
private Long tradeOrderItemId;
private Long orderItemId;
/**
* SPU
*
* ProductSpuDO
*/
private Long spuId;
/**
* SKU
*
* ProductSkuDO
*/
@Deprecated
private Integer skuId;
/**
* 退
*/
private Integer stock; // goods_num
private Integer count;
// ========== 退款相关 ==========
/**
* 退
*/
private Integer refundPrice; // refund_amount
private Integer refundPrice;
/**
* 退
* 退 TODO
*
* pay-module-biz 退 PayRefundDO id
*/
@ -120,28 +132,25 @@ public class TradeRefundDO extends BaseDO {
// ========== 退货相关 ==========
/**
* 退
* 退 TODO
*
* ExpressDO id
*/
private Long returnExpressId; // express_name
/**
* 退
* 退 TODO
*/
private String returnExpressNo; // express_no
/**
* 退
* 退 TODO
*/
private LocalDateTime returnDate; // ship_time
// ========== 收获相关 ==========
private LocalDateTime deliveryTime; // ship_time
/**
*
* TODO
*/
private String receiveMemo; // receive_message
/**
*
* TODO
*/
private LocalDateTime receiveDate; // receive_time