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

Commit db4798a1 authored by 胡佳晨's avatar 胡佳晨

店铺券使用逻辑提交

parent 071605ca
...@@ -52,6 +52,8 @@ public class GoblinStoreOrderVo implements Serializable, Cloneable { ...@@ -52,6 +52,8 @@ public class GoblinStoreOrderVo implements Serializable, Cloneable {
private BigDecimal priceModify; private BigDecimal priceModify;
@ApiModelProperty(value = "券优惠金额") @ApiModelProperty(value = "券优惠金额")
private BigDecimal priceCoupon; private BigDecimal priceCoupon;
@ApiModelProperty(value = "店铺券优惠金额")
private BigDecimal storePriceCoupon;
@ApiModelProperty(value = " 总优惠价格") @ApiModelProperty(value = " 总优惠价格")
private BigDecimal priceVoucher; private BigDecimal priceVoucher;
@ApiModelProperty(value = "订单状态[0-待付款(用户刚下单)|2-代发货(用户付完款 等待商城发货)3-代收货(商城已经发货 等待用户确认收货)|4-已完成(用户已经确认收货 订单结束)|5-取消订单(用户未付款前取消订单)|6-退款通过(用户已经付款但是商城还未发货,用户发出退款申请,商城同意退款)|7-退货通过(用户已经确认收货后用户发出退货申请,商城同意所有退货申请 ,一个订单可能有多个单品)]") @ApiModelProperty(value = "订单状态[0-待付款(用户刚下单)|2-代发货(用户付完款 等待商城发货)3-代收货(商城已经发货 等待用户确认收货)|4-已完成(用户已经确认收货 订单结束)|5-取消订单(用户未付款前取消订单)|6-退款通过(用户已经付款但是商城还未发货,用户发出退款申请,商城同意退款)|7-退货通过(用户已经确认收货后用户发出退货申请,商城同意所有退货申请 ,一个订单可能有多个单品)]")
...@@ -60,6 +62,8 @@ public class GoblinStoreOrderVo implements Serializable, Cloneable { ...@@ -60,6 +62,8 @@ public class GoblinStoreOrderVo implements Serializable, Cloneable {
private Integer zhengzaiStatus; private Integer zhengzaiStatus;
@ApiModelProperty(value = " 券id") @ApiModelProperty(value = " 券id")
private String ucouponId; private String ucouponId;
@ApiModelProperty(value = " 店铺券id")
private String storeCouponId;
@ApiModelProperty(value = " 支付类型[wepay-微信支付|alipay-阿里支付|douyinpay-抖音支付|unionpay-银联支付]") @ApiModelProperty(value = " 支付类型[wepay-微信支付|alipay-阿里支付|douyinpay-抖音支付|unionpay-银联支付]")
private String payType; private String payType;
@ApiModelProperty(value = " 支付来源") @ApiModelProperty(value = " 支付来源")
......
...@@ -110,6 +110,11 @@ public class GoblinStoreOrder implements Serializable,Cloneable { ...@@ -110,6 +110,11 @@ public class GoblinStoreOrder implements Serializable,Cloneable {
*/ */
private BigDecimal priceCoupon; private BigDecimal priceCoupon;
/**
* 券优惠金额
*/
private BigDecimal storePriceCoupon;
/** /**
* 红包优惠金额 * 红包优惠金额
*/ */
......
...@@ -957,6 +957,8 @@ alter table goblin_store_order add market_type varchar(255) default '' comment ' ...@@ -957,6 +957,8 @@ alter table goblin_store_order add market_type varchar(255) default '' comment '
alter table goblin_store_order add market_id varchar(255) default '' comment '活动id'; alter table goblin_store_order add market_id varchar(255) default '' comment '活动id';
alter table goblin_store_order add store_coupon_id varchar(255) default '' comment '商铺券id'; alter table goblin_store_order add store_coupon_id varchar(255) default '' comment '商铺券id';
alter table goblin_store_order add store_price_coupon decimal (8,2) default 0 comment '商铺券优惠金额';
alter table goblin_back_order add back_price_express decimal (8,2) default 0 comment '退款快递费'; alter table goblin_back_order add back_price_express decimal (8,2) default 0 comment '退款快递费';
......
...@@ -345,7 +345,8 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService { ...@@ -345,7 +345,8 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
storeOrder.setPriceTotal(storeTotalPrice.add(storeOrder.getPriceExpress())); storeOrder.setPriceTotal(storeTotalPrice.add(storeOrder.getPriceExpress()));
storeOrder.setPriceActual(storeOrder.getPriceTotal().add(voucherMarket).subtract(voucherPrice)); storeOrder.setPriceActual(storeOrder.getPriceTotal().add(voucherMarket).subtract(voucherPrice));
storeOrder.setPriceRefund(BigDecimal.ZERO); storeOrder.setPriceRefund(BigDecimal.ZERO);
storeOrder.setPriceCoupon(voucherPrice.add(storeVoucherPrice)); storeOrder.setPriceCoupon(voucherPrice);
storeOrder.setStorePriceCoupon(storeVoucherPrice);
storeOrder.setPriceVoucher(voucherMarket.add(voucherPrice.add(storeVoucherPrice))); storeOrder.setPriceVoucher(voucherMarket.add(voucherPrice.add(storeVoucherPrice)));
storeOrder.setStatus(0); storeOrder.setStatus(0);
storeOrder.setUcouponId(platVoucherCode); storeOrder.setUcouponId(platVoucherCode);
...@@ -482,7 +483,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService { ...@@ -482,7 +483,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
storeOrder.setPayCode(payCode); storeOrder.setPayCode(payCode);
sqlDataOrder.add(new Object[]{ sqlDataOrder.add(new Object[]{
storeOrder.getMasterOrderCode(), storeOrder.getOrderId(), storeOrder.getStoreId(), storeOrder.getStoreName(), storeOrder.getOrderCode(), storeOrder.getUserId(), storeOrder.getUserName(), storeOrder.getUserMobile(), storeOrder.getPriceTotal(), storeOrder.getPayCode(), storeOrder.getMasterOrderCode(), storeOrder.getOrderId(), storeOrder.getStoreId(), storeOrder.getStoreName(), storeOrder.getOrderCode(), storeOrder.getUserId(), storeOrder.getUserName(), storeOrder.getUserMobile(), storeOrder.getPriceTotal(), storeOrder.getPayCode(),
storeOrder.getPriceActual(), storeOrder.getPriceRefund(), storeOrder.getPriceExpress(), storeOrder.getPriceCoupon(), storeOrder.getPriceVoucher(), storeOrder.getStatus(), storeOrder.getUcouponId(), storeOrder.getStoreCouponId(), storeOrder.getPayType(), storeOrder.getDeviceFrom(), storeOrder.getPriceActual(), storeOrder.getPriceRefund(), storeOrder.getPriceExpress(), storeOrder.getPriceCoupon(), storeOrder.getPriceVoucher(),storeOrder.getStorePriceCoupon(), storeOrder.getStatus(), storeOrder.getUcouponId(), storeOrder.getStoreCouponId(), storeOrder.getPayType(), storeOrder.getDeviceFrom(),
storeOrder.getSource(), storeOrder.getVersion(), storeOrder.getIsMember(), storeOrder.getOrderType(), storeOrder.getWriteOffCode(), storeOrder.getPayCountdownMinute(), storeOrder.getIpAddress(), storeOrder.getPayCode(), storeOrder.getMarketId(), storeOrder.getMarketType(), storeOrder.getCreatedAt() storeOrder.getSource(), storeOrder.getVersion(), storeOrder.getIsMember(), storeOrder.getOrderType(), storeOrder.getWriteOffCode(), storeOrder.getPayCountdownMinute(), storeOrder.getIpAddress(), storeOrder.getPayCode(), storeOrder.getMarketId(), storeOrder.getMarketType(), storeOrder.getCreatedAt()
}); });
GoblinOrderAttr orderAttr = item.getOrderAttr(); GoblinOrderAttr orderAttr = item.getOrderAttr();
......
...@@ -70,7 +70,7 @@ goblin.self.market.insertRelation=INSERT INTO goblin_marketing_zhengzai (`zhengz ...@@ -70,7 +70,7 @@ goblin.self.market.insertRelation=INSERT INTO goblin_marketing_zhengzai (`zhengz
goblin.self.market.updateRelation=UPDATE goblin_marketing_zhengzai SET price_marketing=? ,stock_marketing=? , buy_factor=?,buy_roster=?,buy_limit=?,updated_at=? WHERE self_market_id =? and store_id =? goblin.self.market.updateRelation=UPDATE goblin_marketing_zhengzai SET price_marketing=? ,stock_marketing=? , buy_factor=?,buy_roster=?,buy_limit=?,updated_at=? WHERE self_market_id =? and store_id =?
goblin.self.market.delSpuRelation=UPDATE goblin_marketing_zhengzai SET del_flag = ?,updated_at = ? WHERE self_market_id =? and store_id =? and spu_id=? goblin.self.market.delSpuRelation=UPDATE goblin_marketing_zhengzai SET del_flag = ?,updated_at = ? WHERE self_market_id =? and store_id =? and spu_id=?
#---- 订单创建&支付 #---- 订单创建&支付
goblin.order.create.order_insert=INSERT INTO goblin_store_order (`master_order_code`,`order_id`,`store_id`,`store_name`,`order_code`,`user_id`,`user_name`,`user_mobile`,`price_total`,`pay_code`,`price_actual`,`price_refund`,`price_express`,`price_coupon`,`price_voucher`,`status`,`ucoupon_id`,`store_coupon_id`,`pay_type`,`device_from`,`source`,`version`,`is_member`,`order_type`,`write_off_code`,`pay_countdown_minute`,`ip_address`,`pay_code`,`market_id`,`market_type`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) goblin.order.create.order_insert=INSERT INTO goblin_store_order (`master_order_code`,`order_id`,`store_id`,`store_name`,`order_code`,`user_id`,`user_name`,`user_mobile`,`price_total`,`pay_code`,`price_actual`,`price_refund`,`price_express`,`price_coupon`,`store_price_coupon`,`price_voucher`,`status`,`ucoupon_id`,`store_coupon_id`,`pay_type`,`device_from`,`source`,`version`,`is_member`,`order_type`,`write_off_code`,`pay_countdown_minute`,`ip_address`,`pay_code`,`market_id`,`market_type`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)
goblin.order.create.attr_insert=INSERT INTO goblin_order_attr (`order_attr_id`,`order_id`,`express_contacts`,`express_address`,`express_address_detail`,`express_phone`,`express_type`,`created_at`) VALUES (?,?,?,?,?,?,?,?) goblin.order.create.attr_insert=INSERT INTO goblin_order_attr (`order_attr_id`,`order_id`,`express_contacts`,`express_address`,`express_address_detail`,`express_phone`,`express_type`,`created_at`) VALUES (?,?,?,?,?,?,?,?)
goblin.order.create.sku_insert=INSERT INTO goblin_order_sku (`order_sku_id`,`order_id`,`spu_id`,`spu_name`,`spu_pic`,`sku_id`,`num`,`sku_price`,`sku_price_actual`,`sku_name`,`sku_no`,`sku_image`,`sku_specs`,`price_voucher`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) goblin.order.create.sku_insert=INSERT INTO goblin_order_sku (`order_sku_id`,`order_id`,`spu_id`,`spu_name`,`spu_pic`,`sku_id`,`num`,`sku_price`,`sku_price_actual`,`sku_name`,`sku_no`,`sku_image`,`sku_specs`,`price_voucher`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)
goblin_order.pay.order=UPDATE goblin_store_order SET payment_type = ? ,payment_id=?,pay_code = ? ,pay_time = ?,write_off_code = ? ,status = ? ,updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null) goblin_order.pay.order=UPDATE goblin_store_order SET payment_type = ? ,payment_id=?,pay_code = ? ,pay_time = ?,write_off_code = ? ,status = ? ,updated_at = ? WHERE order_id = ? and (updated_at <= ? or created_at = ? or updated_at is null)
......
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