丽知:仅退款修改
This commit is contained in:
parent
7d0c15e11a
commit
577977e8c0
|
@ -392,6 +392,7 @@ public class RefundOnlyPluginInitializer extends PluginBaseEntity {
|
||||||
// String ofsId = v.get(0).getId();
|
// String ofsId = v.get(0).getId();
|
||||||
//日志记录使用
|
//日志记录使用
|
||||||
List<RerturnGoodsOrderSearchDetails> logDetails = new ArrayList<>();
|
List<RerturnGoodsOrderSearchDetails> logDetails = new ArrayList<>();
|
||||||
|
List<RerturnGoodsOrderSearchDetails> r1 = new ArrayList<>();
|
||||||
|
|
||||||
try {
|
try {
|
||||||
ArapDjzbVO arapDjzbVO = new ArapDjzbVO();
|
ArapDjzbVO arapDjzbVO = new ArapDjzbVO();
|
||||||
|
@ -451,11 +452,10 @@ public class RefundOnlyPluginInitializer extends PluginBaseEntity {
|
||||||
}
|
}
|
||||||
logDetails.addAll(ofsDetails);
|
logDetails.addAll(ofsDetails);
|
||||||
|
|
||||||
List<ArapDjzbVO.Childrenn> children = new ArrayList<>();
|
|
||||||
|
|
||||||
Iterator<RerturnGoodsOrderSearchDetails> iterator = logDetails.iterator();
|
//没有sku编码的报错
|
||||||
while (iterator.hasNext()) {
|
r1.clear();
|
||||||
RerturnGoodsOrderSearchDetails logDetail = iterator.next();
|
for (RerturnGoodsOrderSearchDetails logDetail : logDetails) {
|
||||||
if(logDetail.getSkuCode()==null||"".equals(logDetail.getSkuCode())) {
|
if(logDetail.getSkuCode()==null||"".equals(logDetail.getSkuCode())) {
|
||||||
IntegrationTaskLivingDetailsEntity integrationTaskLivingDetailsEntity = new IntegrationTaskLivingDetailsEntity();
|
IntegrationTaskLivingDetailsEntity integrationTaskLivingDetailsEntity = new IntegrationTaskLivingDetailsEntity();
|
||||||
integrationTaskLivingDetailsEntity.setNewState(ProfilesActiveConstant.LOG_STATUS_N);
|
integrationTaskLivingDetailsEntity.setNewState(ProfilesActiveConstant.LOG_STATUS_N);
|
||||||
|
@ -467,14 +467,15 @@ public class RefundOnlyPluginInitializer extends PluginBaseEntity {
|
||||||
integrationTaskLivingDetailsEntity.setRootAppBill(logDetail.getReturnOrderCode());
|
integrationTaskLivingDetailsEntity.setRootAppBill(logDetail.getReturnOrderCode());
|
||||||
integrationTaskLivingDetailsEntity.setPluginId(getPluginId());
|
integrationTaskLivingDetailsEntity.setPluginId(getPluginId());
|
||||||
saveOrUpdateBusinessLogUtil.saveOrUpdate(integrationTaskLivingDetailsEntity);
|
saveOrUpdateBusinessLogUtil.saveOrUpdate(integrationTaskLivingDetailsEntity);
|
||||||
// 删除当前的 logDetail 对象
|
}else {
|
||||||
iterator.remove();
|
r1.add(logDetail);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//按sku分组
|
//按sku分组
|
||||||
Map<String, List<RerturnGoodsOrderSearchDetails>> collectSKU = ofsDetails.stream().collect(Collectors.groupingBy(index -> index.getSkuCode()));
|
Map<String, List<RerturnGoodsOrderSearchDetails>> collectSKU = r1.stream().collect(Collectors.groupingBy(index -> index.getSkuCode()));
|
||||||
|
|
||||||
|
List<ArapDjzbVO.Childrenn> children = new ArrayList<>();
|
||||||
Set<Map.Entry<String, List<RerturnGoodsOrderSearchDetails>>> entries = collectSKU.entrySet();
|
Set<Map.Entry<String, List<RerturnGoodsOrderSearchDetails>>> entries = collectSKU.entrySet();
|
||||||
for (Map.Entry<String, List<RerturnGoodsOrderSearchDetails>> entry : entries) {
|
for (Map.Entry<String, List<RerturnGoodsOrderSearchDetails>> entry : entries) {
|
||||||
children.clear();
|
children.clear();
|
||||||
|
@ -615,7 +616,7 @@ public class RefundOnlyPluginInitializer extends PluginBaseEntity {
|
||||||
ErrMessage = "推送U8C,丽知:售后订单(仅退款)--->U8C红字应收单最外层失败,失败原因:" + e.getMessage();
|
ErrMessage = "推送U8C,丽知:售后订单(仅退款)--->U8C红字应收单最外层失败,失败原因:" + e.getMessage();
|
||||||
}
|
}
|
||||||
//失败 批量新增 ofsDetails
|
//失败 批量新增 ofsDetails
|
||||||
for (RerturnGoodsOrderSearchDetails logDetail : logDetails) {
|
for (RerturnGoodsOrderSearchDetails logDetail : r1) {
|
||||||
IntegrationTaskLivingDetailsEntity integrationTaskLivingDetailsEntity = new IntegrationTaskLivingDetailsEntity();
|
IntegrationTaskLivingDetailsEntity integrationTaskLivingDetailsEntity = new IntegrationTaskLivingDetailsEntity();
|
||||||
integrationTaskLivingDetailsEntity.setNewState(ProfilesActiveConstant.LOG_STATUS_N);
|
integrationTaskLivingDetailsEntity.setNewState(ProfilesActiveConstant.LOG_STATUS_N);
|
||||||
integrationTaskLivingDetailsEntity.setRootAppNewData(mapStr);
|
integrationTaskLivingDetailsEntity.setRootAppNewData(mapStr);
|
||||||
|
|
Loading…
Reference in New Issue