记得上下班打卡 | git大法好,push需谨慎

Commit 0d71632b authored by jiangxiulong's avatar jiangxiulong

refund refundCate orderTicket refundPrice 0.0不加引号

parent a55e01b1
......@@ -32,6 +32,10 @@ public class KylinTableStatusConst {
public static final Integer ORDER_REFUND_TYPE_APPLY = 0; // 人工申请类型的退款,可以取消退款,退款完成需返还库存
public static final Integer ORDER_REFUND_TYPE_AUTO = 1; // 自动申请类型的退款,无法取消退款,退款完成不返还库存
public static final Integer ORDER_REFUND_CATE1 = 1; // 1票务2快递费3票和快递费
public static final Integer ORDER_REFUND_CATE2 = 2;
public static final Integer ORDER_REFUND_CATE3 = 3;
/**
* 订单状态表状态
*/
......
......@@ -96,6 +96,7 @@ public class KylinOrderRefundsVo implements Serializable {
@ApiModelProperty(value = "票务/快递费/票和快递费")
private String refundType;
private Integer refundCate;
@ApiModelProperty(value = "订单入场人/搭售款式表 id 多个 ,分割")
private String orderTicketEntitiesIds;
......
......@@ -86,7 +86,6 @@ public class KylinOrderRefundsServiceImpl extends ServiceImpl<KylinOrderRefundsM
double priceExpress = orderInfo.getPriceExpress().doubleValue();
// todo 转增是否能退
// 订单状态需已付款
if (thisOrderStatus != KylinTableStatusConst.ORDER_STATUS1) {
return ResponseDto.failure("订单状态信息有误");
......
......@@ -160,9 +160,9 @@ public class KylinRefundsStatusServiceImpl {
kylinOrderRefunds.setReason(reason);
// TODO: 2021/5/27 判断tyoe
if (RefundPriceExpress > 0) {
kylinOrderRefunds.setRefundType("all");
kylinOrderRefunds.setRefundCate(KylinTableStatusConst.ORDER_REFUND_CATE1);
} else {
kylinOrderRefunds.setRefundType("ticket");
kylinOrderRefunds.setRefundCate(KylinTableStatusConst.ORDER_REFUND_CATE2);
}
kylinOrderRefunds.setOrderTicketEntitiesIds(StringUtils.join(ticketEntityIds, ','));
kylinOrderRefunds.setCreatedAt(LocalDateTime.now());
......
......@@ -58,6 +58,7 @@ public class OrderRefundDao implements Serializable {
private String refuse;
private String refundType;
private String refundCate;
private String orderTicketEntitiesIds;
......
......@@ -144,6 +144,7 @@ public class KylinOrderRefunds implements Serializable {
* 票务/快递费/票和快递费
*/
private String refundType;
private Integer refundCate;
/**
* 订单入场人/搭售款式表 id 多个 ,分割
......
......@@ -674,7 +674,7 @@ CREATE TABLE `kylin_order_refunds`
`executor_at` timestamp NULL DEFAULT NULL COMMENT '执行时间',
`refuse` varchar(200) NOT NULL DEFAULT '' COMMENT '回绝原因',
`refund_type` varchar(200) NOT NULL DEFAULT '' COMMENT '退款方式',
`refund_type_old` enum ('ticket','express','all') NOT NULL DEFAULT 'ticket' COMMENT '票务/快递费/票和快递费',
`refund_cate` tinyint NOT NULL DEFAULT '0' COMMENT '1票务2快递费3票和快递费',
`order_ticket_entities_ids` text COMMENT '订单入场人/搭售款式表 id 多个 ,分割',
`created_at` timestamp NULL DEFAULT NULL,
`updated_at` timestamp NULL DEFAULT NULL,
......
......@@ -312,7 +312,7 @@ public class KylinOrderTicketsServiceImpl extends ServiceImpl<KylinOrderTicketsM
orderTickets.setPriceActual(orderTickets.getPriceTotal());
orderTickets.setPriceVoucher(new BigDecimal("0.0"));
orderTickets.setPriceExpress(ticketData.getPriceExpress());
orderTickets.setPriceRefund(new BigDecimal("0.0"));
orderTickets.setPriceRefund(new BigDecimal(0.0));
orderTickets.setRefundNumber(0);
orderTickets.setPayType(payOrderParam.getPayType());
orderTickets.setPaymentType(null);
......
......@@ -97,7 +97,7 @@ public class KylinRefundsStatusServiceImpl {
KylinOrderTicketVo kylinOrderTicketVoOrder = new KylinOrderTicketVo();
kylinOrderTicketVoOrder.setStatus(newStatus);
kylinOrderTicketVoOrder.setRefundNumber(num);
// kylinOrderTicketVoOrder.setPriceRefund(BigDecimal.valueOf(price));
kylinOrderTicketVoOrder.setPriceRefund(BigDecimal.valueOf(price));
BasicDBObject orderEntitiesObject = new BasicDBObject("$set", JSON.parse(JsonUtils.toJson(kylinOrderTicketVoOrder)));
Document docOrder = mongoTemplate.getCollection(KylinOrderTicketVo.class.getSimpleName()).findOneAndUpdate(
Query.query(Criteria.where("orderTicketsId").is(orderTicketsId)).getQueryObject(),
......@@ -132,7 +132,7 @@ public class KylinRefundsStatusServiceImpl {
KylinOrderRefunds kylinOrderRefunds = new KylinOrderRefunds();
kylinOrderRefunds.setStatus(KylinTableStatusConst.ORDER_REFUND_STATUS_REFUNDED);
kylinOrderRefunds.setRefundCode(refundCallbackParam.getRefund_code());
// kylinOrderRefunds.setRefundType(refundCallbackParam.getRefund_type());
kylinOrderRefunds.setRefundType(refundCallbackParam.getRefund_type());
kylinOrderRefunds.setRefundId(refundCallbackParam.getRefund_id());
kylinOrderRefunds.setRefundAt(refundCallbackParam.getRefund_at());
kylinOrderRefunds.setRefundError(refundCallbackParam.getRefund_error());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment