fix:库存同步优化
This commit is contained in:
@@ -80,7 +80,7 @@ public class MdPbStoragevehicleextServiceImpl extends ServiceImpl<MdPbStorageveh
|
|||||||
|
|
||||||
Map<String, JSONObject> localMap = new HashMap<>();
|
Map<String, JSONObject> localMap = new HashMap<>();
|
||||||
for (JSONObject local : localStocks) {
|
for (JSONObject local : localStocks) {
|
||||||
String key = local.getString("material_code") + "_" + local.getString("pcsn");
|
String key = local.getString("material_code");
|
||||||
localMap.put(key, local);
|
localMap.put(key, local);
|
||||||
}
|
}
|
||||||
if ("-----".equals(warehouseno)){//装配线边库同步中鼎库存
|
if ("-----".equals(warehouseno)){//装配线边库同步中鼎库存
|
||||||
@@ -139,7 +139,7 @@ public class MdPbStoragevehicleextServiceImpl extends ServiceImpl<MdPbStorageveh
|
|||||||
Set<String> easKeys = new HashSet<>();
|
Set<String> easKeys = new HashSet<>();
|
||||||
|
|
||||||
for (QueryEasStockResponse eas : easStocks) {
|
for (QueryEasStockResponse eas : easStocks) {
|
||||||
String key = eas.getMaterialno() + "_" + eas.getLotnumber();
|
String key = eas.getMaterialno();
|
||||||
easKeys.add(key);
|
easKeys.add(key);
|
||||||
|
|
||||||
if (localMap.containsKey(key)) {
|
if (localMap.containsKey(key)) {
|
||||||
@@ -179,7 +179,7 @@ public class MdPbStoragevehicleextServiceImpl extends ServiceImpl<MdPbStorageveh
|
|||||||
}
|
}
|
||||||
|
|
||||||
for (JSONObject local : localStocks) {
|
for (JSONObject local : localStocks) {
|
||||||
String key = local.getString("material_code") + "_" + local.getString("pcsn");
|
String key = local.getString("material_code");
|
||||||
if (!easKeys.contains(key)) {
|
if (!easKeys.contains(key)) {
|
||||||
iMdPbGroupplateService.removeById(local.getString("group_id"));
|
iMdPbGroupplateService.removeById(local.getString("group_id"));
|
||||||
deleteCount++;
|
deleteCount++;
|
||||||
|
|||||||
Reference in New Issue
Block a user