1
|
package com.yohoufo.order.service.impl;
|
1
|
package com.yohoufo.order.service.impl;
|
2
|
|
2
|
|
|
|
3
|
+import com.alibaba.fastjson.JSON;
|
3
|
import com.google.common.collect.Lists;
|
4
|
import com.google.common.collect.Lists;
|
4
|
import com.google.common.collect.Maps;
|
5
|
import com.google.common.collect.Maps;
|
5
|
import com.yoho.core.config.ConfigReader;
|
6
|
import com.yoho.core.config.ConfigReader;
|
|
@@ -53,21 +54,25 @@ public class QiniuLiveRecordService { |
|
@@ -53,21 +54,25 @@ public class QiniuLiveRecordService { |
53
|
}
|
54
|
}
|
54
|
|
55
|
|
55
|
public void copyQiniuLiveRecord(StorageDeposit storageDeposit) {
|
56
|
public void copyQiniuLiveRecord(StorageDeposit storageDeposit) {
|
|
|
57
|
+ LOG.info("copyQiniuLiveRecord storageDeposit is {}", storageDeposit);
|
56
|
if (Objects.isNull(storageDeposit)) {
|
58
|
if (Objects.isNull(storageDeposit)) {
|
57
|
return;
|
59
|
return;
|
58
|
}
|
60
|
}
|
59
|
- QiniuLiveRecord qiniuLiveRecords = qiniuLiveRecordMapper.selectByOrderCode(storageDeposit.getOrderCode());
|
61
|
+ QiniuLiveRecord qiniuLiveRecords = qiniuLiveRecordMapper.selectByOrderCode4Copy(storageDeposit.getOrderCode());
|
60
|
if (Objects.isNull(qiniuLiveRecords)) {
|
62
|
if (Objects.isNull(qiniuLiveRecords)) {
|
|
|
63
|
+ LOG.warn("copyQiniuLiveRecord qiniuLiveRecords is null");
|
61
|
return;
|
64
|
return;
|
62
|
}
|
65
|
}
|
63
|
SellerOrder sellerOrder = sellerOrderMapper.selectBySkup(storageDeposit.getNewSkup());
|
66
|
SellerOrder sellerOrder = sellerOrderMapper.selectBySkup(storageDeposit.getNewSkup());
|
64
|
if (Objects.isNull(sellerOrder)) {
|
67
|
if (Objects.isNull(sellerOrder)) {
|
|
|
68
|
+ LOG.warn("copyQiniuLiveRecord sellerOrder is null");
|
65
|
return;
|
69
|
return;
|
66
|
}
|
70
|
}
|
67
|
qiniuLiveRecords.setId(null);
|
71
|
qiniuLiveRecords.setId(null);
|
68
|
qiniuLiveRecords.setOrderCode(storageDeposit.getNewOrderCode());
|
72
|
qiniuLiveRecords.setOrderCode(storageDeposit.getNewOrderCode());
|
69
|
qiniuLiveRecords.setSkup(sellerOrder.getSkup());
|
73
|
qiniuLiveRecords.setSkup(sellerOrder.getSkup());
|
70
|
qiniuLiveRecords.setSellerOrderCode(sellerOrder.getOrderCode());
|
74
|
qiniuLiveRecords.setSellerOrderCode(sellerOrder.getOrderCode());
|
|
|
75
|
+ LOG.info("copyQiniuLiveRecord qiniuLiveRecords for insert is {}", JSON.toJSONString(qiniuLiveRecords));
|
71
|
qiniuLiveRecordMapper.insert(qiniuLiveRecords);
|
76
|
qiniuLiveRecordMapper.insert(qiniuLiveRecords);
|
72
|
}
|
77
|
}
|
73
|
|
78
|
|