diff --git a/mallinkService/src/main/resources/mapper/WxCouponMapper.xml b/mallinkService/src/main/resources/mapper/WxCouponMapper.xml
index b684b964c..362b8e4fb 100644
--- a/mallinkService/src/main/resources/mapper/WxCouponMapper.xml
+++ b/mallinkService/src/main/resources/mapper/WxCouponMapper.xml
@@ -48,11 +48,11 @@
- `id`,`tenant_id`,`type`,`cover_img`,`title`,`sub_title`,`sale_price`,`use_price`,`use_limit_quantity`,`send_type`,
- `valid_type`,`valid_start_date`,`valid_end_date`,`valid_days`,`detail`,`price`,`unit`,`remain_inventory`,`inventory`,
- `remark`,`status`,`create_date`,`update_date`,`business`,`support_transfer`,`subsidy_num`,`subsidy_type`,
- `press_limit_num`, `press_limit_hours`, `auto_refund`
-
+ `id`,`tenant_id`,`type`,`cover_img`,`title`,`sub_title`,`sale_price`,`use_price`,`use_limit_quantity`,`send_type`,
+ `valid_type`,`valid_start_date`,`valid_end_date`,`valid_days`,`detail`,`price`,`unit`,`remain_inventory`,`inventory`,
+ `remark`,`status`,`create_date`,`update_date`,`business`,`support_transfer`,`subsidy_num`,`subsidy_type`,
+ `press_limit_num`, `press_limit_hours`, `auto_refund`
+
where 1 = 1
@@ -402,31 +402,31 @@
- update wx_coupon SET remain_inventory = remain_inventory - #{number} where id = #{id} and remain_inventory>= #{number}
-
+ update wx_coupon SET remain_inventory = remain_inventory - #{number} where id = #{id} and remain_inventory>= #{number}
+
- update wx_coupon SET status = 1, update_date = now()
- where status = 0 and valid_type = 1 and valid_end_date < now()
-
+ update wx_coupon SET status = 1, update_date = now()
+ where status = 0 and valid_type = 1 and valid_end_date < now()
+
- update wx_coupon c
- SET c.status = 1, c.update_date = now()
- where c.status = 0 and
- (select count(*) from wx_coupon_merchant cm, wx_merchant m
- where m.id = cm.merchant_id
- and c.id = cm.product_id
- and cm.status = 0
- and m.status = 1) = 0
-
+ update wx_coupon c
+ SET c.status = 1, c.update_date = now()
+ where c.status = 0 and
+ (select count(*) from wx_coupon_merchant cm, wx_merchant m
+ where m.id = cm.merchant_id
+ and c.id = cm.product_id
+ and cm.status = 0
+ and m.status = 1) = 0
+