|
@@ -1,6 +1,5 @@
|
|
package com.kmall.admin.service.impl;
|
|
package com.kmall.admin.service.impl;
|
|
|
|
|
|
-import cn.hutool.core.io.IoUtil;
|
|
|
|
import com.alibaba.fastjson.JSON;
|
|
import com.alibaba.fastjson.JSON;
|
|
import com.alibaba.fastjson.JSONObject;
|
|
import com.alibaba.fastjson.JSONObject;
|
|
import com.google.common.collect.ImmutableBiMap;
|
|
import com.google.common.collect.ImmutableBiMap;
|
|
@@ -8,6 +7,7 @@ import com.google.common.collect.Lists;
|
|
import com.google.common.collect.Maps;
|
|
import com.google.common.collect.Maps;
|
|
import com.google.gson.Gson;
|
|
import com.google.gson.Gson;
|
|
import com.google.gson.internal.LinkedTreeMap;
|
|
import com.google.gson.internal.LinkedTreeMap;
|
|
|
|
+import com.kmall.admin.biz.CustomsClearanceTimeliness;
|
|
import com.kmall.admin.dao.*;
|
|
import com.kmall.admin.dao.*;
|
|
import com.kmall.admin.dao.alarm.Mall2LowPriceWarningDao;
|
|
import com.kmall.admin.dao.alarm.Mall2LowPriceWarningDao;
|
|
import com.kmall.admin.dao.mk.Mk2GoodsTopicPriceDao;
|
|
import com.kmall.admin.dao.mk.Mk2GoodsTopicPriceDao;
|
|
@@ -82,9 +82,7 @@ import java.nio.charset.Charset;
|
|
import java.text.ParseException;
|
|
import java.text.ParseException;
|
|
import java.text.SimpleDateFormat;
|
|
import java.text.SimpleDateFormat;
|
|
import java.util.*;
|
|
import java.util.*;
|
|
-import java.util.concurrent.CountDownLatch;
|
|
|
|
-import java.util.concurrent.ExecutorService;
|
|
|
|
-import java.util.concurrent.Executors;
|
|
|
|
|
|
+import java.util.concurrent.*;
|
|
|
|
|
|
|
|
|
|
@Service("orderService")
|
|
@Service("orderService")
|
|
@@ -191,6 +189,9 @@ public class OrderServiceImpl implements OrderService {
|
|
@Autowired
|
|
@Autowired
|
|
private KtoEccsService ktoEccsService;
|
|
private KtoEccsService ktoEccsService;
|
|
|
|
|
|
|
|
+ @Autowired
|
|
|
|
+ private CustomsClearanceTimeliness customsClearanceTimeliness;
|
|
|
|
+
|
|
|
|
|
|
@Override
|
|
@Override
|
|
public OrderEntity queryObject(Long id) {
|
|
public OrderEntity queryObject(Long id) {
|
|
@@ -2162,6 +2163,11 @@ public class OrderServiceImpl implements OrderService {
|
|
//插入订单信息和订单商品
|
|
//插入订单信息和订单商品
|
|
orderDao.saveOrderVo(order);
|
|
orderDao.saveOrderVo(order);
|
|
|
|
|
|
|
|
+
|
|
|
|
+ // TODO req_2021-07-19 电商端下单时间 req_20210826_001
|
|
|
|
+ customsClearanceTimeliness.send(Arrays.asList(order.getOrder_sn()), "customerOrder");
|
|
|
|
+
|
|
|
|
+
|
|
// TODO 订单流转表
|
|
// TODO 订单流转表
|
|
OrderProcessRecordEntity processRecordEntity = new OrderProcessRecordEntity();
|
|
OrderProcessRecordEntity processRecordEntity = new OrderProcessRecordEntity();
|
|
processRecordEntity.setOrderSn(order.getOrder_sn());
|
|
processRecordEntity.setOrderSn(order.getOrder_sn());
|
|
@@ -2201,6 +2207,9 @@ public class OrderServiceImpl implements OrderService {
|
|
StoreEntity store = storeService.queryObject(order.getStore_id().intValue());
|
|
StoreEntity store = storeService.queryObject(order.getStore_id().intValue());
|
|
|
|
|
|
// 设置支付单开始时间
|
|
// 设置支付单开始时间
|
|
|
|
+ // TODO req_2021-07-19 顾客付款时间 req_20210826_001
|
|
|
|
+ customsClearanceTimeliness.send(Arrays.asList(order.getOrder_sn()), "customerPay");
|
|
|
|
+
|
|
processRecordEntity.setPaymentStartTime(new Date());
|
|
processRecordEntity.setPaymentStartTime(new Date());
|
|
// 判断是微信的支付码还是支付宝的支付码
|
|
// 判断是微信的支付码还是支付宝的支付码
|
|
if (parCode.startsWith("28")) {
|
|
if (parCode.startsWith("28")) {
|
|
@@ -2220,6 +2229,10 @@ public class OrderServiceImpl implements OrderService {
|
|
throw e;
|
|
throw e;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
+ // TODO req_2021-07-19 客户付款完成时间 req_20210826_001
|
|
|
|
+ customsClearanceTimeliness.send(Arrays.asList(order.getOrder_sn()), "customerPayFinished");
|
|
|
|
+
|
|
|
|
+ processRecordEntity.setPaymentStartTime(new Date());
|
|
|
|
|
|
|
|
|
|
// TODO 到时候要注释掉,测试用而已
|
|
// TODO 到时候要注释掉,测试用而已
|