|
|
@@ -405,11 +405,9 @@ public class OyeResultServiceImpl implements IOyeResultService {
|
|
|
OyeRealtimeInventory oyeRealtimeInventoryInsert = null;
|
|
|
OyeRealtimeInventory oyeRealtimeInventoryUpdate = null;
|
|
|
//根据区域,客户,物资,单重,米数,仓库,库区查询实时库存在不在
|
|
|
- BigDecimal inventoryId;
|
|
|
- if(newInventoryId.intValue() == 0) {
|
|
|
- inventoryId = oyeRealtimeInventoryMapper.getInventoryId(map);
|
|
|
- }else{
|
|
|
- inventoryId = newInventoryId;
|
|
|
+ BigDecimal inventoryId = oyeRealtimeInventoryMapper.getInventoryId(map);;
|
|
|
+ if(newInventoryId.intValue() > 0 && newInventoryId.compareTo(inventoryId) != 0) {
|
|
|
+ throw new Exception("库存ID存在错误,无法划分!");
|
|
|
}
|
|
|
if (inventoryId != null && inventoryId.compareTo(DataChange.dataToBigDecimal(map.get("inventoryId"))) == 0) {
|
|
|
throw new Exception("库存ID一致无法划分");
|