|
@@ -37,7 +37,6 @@ import org.springframework.data.mongodb.core.query.Query;
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
|
import java.util.ArrayList;
|
|
|
-import java.util.Date;
|
|
|
import java.util.HashMap;
|
|
|
import java.util.List;
|
|
|
import java.util.Map;
|
|
@@ -775,8 +774,6 @@ public class SupplyChainServiceImpl implements ISupplyChainService {
|
|
|
return yuxiu;
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
-
|
|
|
return 0;
|
|
|
}
|
|
|
|
|
@@ -812,15 +809,13 @@ public class SupplyChainServiceImpl implements ISupplyChainService {
|
|
|
if (!Check.isNull(itemCheck)) {
|
|
|
ownership = itemCheck.getOwnership();
|
|
|
}
|
|
|
-// supplyChainMapper.replaceOne(ownership, supplyChain);
|
|
|
- supplyChainMapper.replaceOne("rocket", supplyChain);// todo 测试完 删除改行 放开上面 并修改数据表
|
|
|
+ supplyChainMapper.replaceOne(ownership, supplyChain);
|
|
|
} //更新
|
|
|
else if (2 == messageType) {
|
|
|
Integer cpsOrderStatus = info.getInteger("cpsOrderStatus");
|
|
|
Long oid = info.getLong("oid");
|
|
|
if (cpsOrderStatus == 60 || cpsOrderStatus == 40) {
|
|
|
-// Integer i = updateOrderRegimentalSettleAmount(oid, cpsOrderStatus);
|
|
|
- Integer i = updateOrderRegimentalSettleAmountCeshi(oid, cpsOrderStatus);// todo 测试完 删除改行 放开上面
|
|
|
+ Integer i = updateOrderRegimentalSettleAmount(oid, cpsOrderStatus);
|
|
|
if (i <= 0) {
|
|
|
log.error("订单ID:{},状态:{} 修改失败", oid, cpsOrderStatus);
|
|
|
}
|
|
@@ -834,11 +829,6 @@ public class SupplyChainServiceImpl implements ISupplyChainService {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- /*测完删除*/
|
|
|
- private Integer updateOrderRegimentalSettleAmountCeshi(Long oid, Integer cpsOrderStatus) {
|
|
|
- return supplyChainMapper.updateRocketOrderRegimentalSettleAmountCS(oid, cpsOrderStatus);
|
|
|
- }
|
|
|
-
|
|
|
@Override
|
|
|
public void addList(String beginDate, String endDate, String pcursor) throws InterruptedException {
|
|
|
String url = KuaiShouConstants.KFX_URL;
|
|
@@ -956,13 +946,13 @@ public class SupplyChainServiceImpl implements ISupplyChainService {
|
|
|
KuaishouSupplyChain supplyChain = new KuaishouSupplyChain(info, "1");
|
|
|
|
|
|
String ownership = null;
|
|
|
-// Criteria criteria = new Criteria();
|
|
|
-// criteria = Criteria.where("_id").is(supplyChain.getItemId());
|
|
|
-// Query query = new Query(criteria);
|
|
|
-// ItemCheck itemCheck = mongoTemplate.findOne(query, ItemCheck.class);
|
|
|
-// if (!Check.isNull(itemCheck)) {
|
|
|
-// ownership = itemCheck.getOwnership();
|
|
|
-// }
|
|
|
+ Criteria criteria = new Criteria();
|
|
|
+ criteria = Criteria.where("_id").is(supplyChain.getItemId());
|
|
|
+ Query query = new Query(criteria);
|
|
|
+ ItemCheck itemCheck = mongoTemplate.findOne(query, ItemCheck.class);
|
|
|
+ if (!Check.isNull(itemCheck)) {
|
|
|
+ ownership = itemCheck.getOwnership();
|
|
|
+ }
|
|
|
|
|
|
if (Check.isNull(ownership)) {
|
|
|
commonlist.add(supplyChain);
|
|
@@ -994,7 +984,7 @@ public class SupplyChainServiceImpl implements ISupplyChainService {
|
|
|
supplyChainMapper.replaceBatchOrder(null, commonlist);
|
|
|
}
|
|
|
if (!Check.isNull(ruixuanList)) {
|
|
|
- supplyChainMapper.replaceBatchOrder("ruixuan", ruixuanList); //TODO 测试完 修改该方法数据表
|
|
|
+ supplyChainMapper.replaceBatchOrder("ruixuan", ruixuanList);
|
|
|
}
|
|
|
if (!Check.isNull(mgsList)) {
|
|
|
supplyChainMapper.replaceBatchOrder("miaogousi", mgsList);
|