Commit bbaa71f2 by 吕明尚

更改优惠卷金额由后台查找

parent 22a25e54
......@@ -386,7 +386,11 @@ public class SOrderServiceImpl extends ServiceImpl<SOrderMapper, SOrder> impleme
SOrder sOrder = new SOrder();
BeanUtils.copyProperties(request, sOrder);
sOrder.setTotalPrice(request.getTotalFee());
sOrder.setCouponPrice(request.getCouponFee());
if (ObjectUtil.isNotEmpty(request.getCouponId())) {
//查询优惠卷金额
SConsumerCoupon coupon = consumerCouponService.getById(request.getCouponId());
sOrder.setCouponPrice(coupon.getSubPrice());
}
sOrder.setPayPrice(request.getPayFee());
sOrder.setBuyType(request.getBuyType());
//设置订单号
......
......@@ -56,7 +56,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="orderId != null">#{orderId},</if>
<if test="name != null and name != ''">#{name},</if>
<if test="price != null">#{price},</if>
<if test="pay_type != null">#{pay_type},</if>
<if test="pay_type != null">#{payType},</if>
<if test="sign != null">#{sign},</if>
<if test="createTime != null">#{createTime},</if>
</trim>
......@@ -69,7 +69,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="orderId != null">order_id = #{orderId},</if>
<if test="name != null and name != ''">name = #{name},</if>
<if test="price != null">price = #{price},</if>
<if test="pay_type != null">pay_type = #{pay_type},</if>
<if test="pay_type != null">pay_type = #{payType},</if>
<if test="sign != null">sign = #{sign},</if>
<if test="createTime != null">create_time = #{createTime},</if>
</trim>
......
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