|
|
@ -305,6 +305,7 @@ public class MaterialServiceImpl implements MaterialService { |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 用于修改库存中的备注 |
|
|
* 用于修改库存中的备注 |
|
|
|
|
|
* |
|
|
* @param map 待修改数据 |
|
|
* @param map 待修改数据 |
|
|
* @return |
|
|
* @return |
|
|
*/ |
|
|
*/ |
|
|
@ -987,7 +988,6 @@ public class MaterialServiceImpl implements MaterialService { |
|
|
map.put("quantity", 0); |
|
|
map.put("quantity", 0); |
|
|
} |
|
|
} |
|
|
Map<String, Object> params = new HashMap<>(); |
|
|
Map<String, Object> params = new HashMap<>(); |
|
|
// params.put("code", map.get("code"));
|
|
|
|
|
|
params.put("mid", map.get("mid")); |
|
|
params.put("mid", map.get("mid")); |
|
|
params.put("depositoryId", map.get("depositoryId")); |
|
|
params.put("depositoryId", map.get("depositoryId")); |
|
|
List<Inventory> inventory = materialMapper.findInventoryForImport(params); |
|
|
List<Inventory> inventory = materialMapper.findInventoryForImport(params); |
|
|
@ -999,10 +999,12 @@ public class MaterialServiceImpl implements MaterialService { |
|
|
Inventory material = inventory.get(0); |
|
|
Inventory material = inventory.get(0); |
|
|
|
|
|
|
|
|
if (map.containsKey("remark")) { |
|
|
if (map.containsKey("remark")) { |
|
|
material.setRemark(map.get("remark").toString()); |
|
|
String materialRemark = material.getRemark(); |
|
|
|
|
|
if (materialRemark == null) { |
|
|
|
|
|
materialRemark = ""; |
|
|
|
|
|
} |
|
|
|
|
|
material.setRemark(materialRemark + map.get("remark").toString()); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
double quantity = Double.parseDouble(map.get("quantity").toString()); |
|
|
double quantity = Double.parseDouble(map.get("quantity").toString()); |
|
|
double quantity_residue = 0; |
|
|
double quantity_residue = 0; |
|
|
int splitInfoScaleQuantity = 0; |
|
|
int splitInfoScaleQuantity = 0; |
|
|
@ -1108,8 +1110,7 @@ public class MaterialServiceImpl implements MaterialService { |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
return materialMapper.updateInventory(material); |
|
|
return materialMapper.updateInventory(material); |
|
|
} |
|
|
} else { |
|
|
else { |
|
|
|
|
|
// 用于标志是新插入的物料
|
|
|
// 用于标志是新插入的物料
|
|
|
map.put("isNew", true); |
|
|
map.put("isNew", true); |
|
|
Double quantity = ObjectFormatUtil.toDouble(map.get("quantity")); |
|
|
Double quantity = ObjectFormatUtil.toDouble(map.get("quantity")); |
|
|
@ -2722,8 +2723,7 @@ public class MaterialServiceImpl implements MaterialService { |
|
|
map.put("id", material.getId()); |
|
|
map.put("id", material.getId()); |
|
|
result.add(map); |
|
|
result.add(map); |
|
|
} |
|
|
} |
|
|
} |
|
|
} else if (inventoryList != null) { |
|
|
else if (inventoryList != null) { |
|
|
|
|
|
for (Inventory inventory : inventoryList) { |
|
|
for (Inventory inventory : inventoryList) { |
|
|
Map<String, Object> map = new HashMap<>(); |
|
|
Map<String, Object> map = new HashMap<>(); |
|
|
String version = inventory.getVersion(); |
|
|
String version = inventory.getVersion(); |
|
|
|