Commit 4fe37ad8 by huluobin

Merge branch 'master' into 4.1

parents f27c18c2 1d6696b7
...@@ -68,15 +68,17 @@ public class CouponsGiftServiceImpl extends ServiceImpl<CouponsGiftMapper, Coupo ...@@ -68,15 +68,17 @@ public class CouponsGiftServiceImpl extends ServiceImpl<CouponsGiftMapper, Coupo
case CouponsGift.BEHAVIOR_FINISH_ORDER: case CouponsGift.BEHAVIOR_FINISH_ORDER:
Integer orderId = Integer.parseInt(attach.toString()); Integer orderId = Integer.parseInt(attach.toString());
CouponsForConsumption couponsForConsumption = couponsForConsumptionMapper.getByOrderId(orderId); CouponsForConsumption couponsForConsumption = couponsForConsumptionMapper.getByOrderId(orderId);
if (couponsForConsumption.getCouponId() != null) { if (couponsForConsumption != null) {
couponService.sendCoupon(couponsForConsumption.getCouponId(), customerId); if (couponsForConsumption.getCouponId() != null) {
} couponService.sendCoupon(couponsForConsumption.getCouponId(), customerId);
if (StringUtils.isNotEmpty(couponsForConsumption.getMessageInfo())) { }
Customer customer = customerMapper.selectById(customerId); if (StringUtils.isNotEmpty(couponsForConsumption.getMessageInfo())) {
SendMessageRequest sendMessageRequest = new SendMessageRequest(); Customer customer = customerMapper.selectById(customerId);
sendMessageRequest.setContent(couponsForConsumption.getMessageInfo()); SendMessageRequest sendMessageRequest = new SendMessageRequest();
sendMessageRequest.setMobiles(Lists.newArrayList(customer.getPhone())); sendMessageRequest.setContent(couponsForConsumption.getMessageInfo());
adminFeign.sendMessage(sendMessageRequest); sendMessageRequest.setMobiles(Lists.newArrayList(customer.getPhone()));
adminFeign.sendMessage(sendMessageRequest);
}
} }
} }
} catch (Exception e) { } catch (Exception e) {
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
and t1.total_price &lt;= t2.order_amount_up and t1.total_price &lt;= t2.order_amount_up
and t1.total_price &gt;= t2.order_amount_down and t1.total_price &gt;= t2.order_amount_down
LEFT JOIN order_serve t3 on t1.id = t3.order_id and (t2.order_serve_type = t3.serve_type_id or LEFT JOIN order_serve t3 on t1.id = t3.order_id and (t2.order_serve_type = t3.serve_type_id or
t2.order_serve_type is null) t2.order_serve_type = 0)
where t1.id = #{orderId} where t1.id = #{orderId}
and t2.id is not null and t2.id is not null
and t1.department_id = t2.store_id and t1.department_id = t2.store_id
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
and t1.total_payment_amount &gt;= t2.order_amount_down and t1.total_payment_amount &gt;= t2.order_amount_down
and t1.department_id = t2.store_id and t1.department_id = t2.store_id
LEFT JOIN order_serve t3 on t1.id = t3.order_id and (t2.order_serve_type = t3.serve_type_id or LEFT JOIN order_serve t3 on t1.id = t3.order_id and (t2.order_serve_type = t3.serve_type_id or
t2.order_serve_type is null) t2.order_serve_type = 0)
where t1.id = #{orderId} where t1.id = #{orderId}
and t2.id is not null and t2.id is not null
and t3.id is not null and t3.id is not 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