opt:基础功能优化
This commit is contained in:
@@ -444,13 +444,13 @@ public class RawAssistIStorServiceImpl implements RawAssistIStorService {
|
||||
queryWrapper.eq("container_name", container_name);
|
||||
}
|
||||
if (StrUtil.isNotEmpty(bill_code)) {
|
||||
queryWrapper.eq("bill_code", bill_code);
|
||||
queryWrapper.eq("sale_order_name", bill_code);
|
||||
}
|
||||
if (StrUtil.isNotEmpty(sap_pcsn)) {
|
||||
queryWrapper.eq("sap_pcsn", sap_pcsn);
|
||||
}
|
||||
if (StrUtil.isNotEmpty(material_search)) {
|
||||
queryWrapper.like("material_search", material_search);
|
||||
queryWrapper.like("product_name", material_search);
|
||||
}
|
||||
if (StrUtil.isNotEmpty(begin_time)) {
|
||||
String beginDate = begin_time.substring(0, 10);
|
||||
|
||||
@@ -230,7 +230,10 @@ public class StorPublicServiceImpl implements StorPublicService {
|
||||
double ivt_qty = jo_in.getDoubleValue("ivt_qty");
|
||||
double canuse_qty = NumberUtil.sub(jo_in.getDoubleValue("canuse_qty"), change_qty);
|
||||
if (canuse_qty < 0) {
|
||||
throw new BadRequestException(LangBehavior.language("system.availableNumNotNegative1"));
|
||||
throw new BadRequestException(LangBehavior.language("system.availableNumNotNegative1")
|
||||
+ "库存数:" + jo_in.getString("canuse_qty")
|
||||
+ "变更数:" + change_qty
|
||||
+ "物料标识:" + material_id_In);
|
||||
}
|
||||
jo_in.put("canuse_qty", canuse_qty);
|
||||
jo_in.put("frozen_qty", jo_in.getDoubleValue("frozen_qty") + change_qty);
|
||||
@@ -313,7 +316,10 @@ public class StorPublicServiceImpl implements StorPublicService {
|
||||
throw new BadRequestException(LangBehavior.language("system.inputDataException"));
|
||||
}
|
||||
if (jo_in.getDoubleValue("canuse_qty") < 0) {
|
||||
throw new BadRequestException(LangBehavior.language("system.availableNumNotNegative2"));
|
||||
throw new BadRequestException(LangBehavior.language("system.availableNumNotNegative2")
|
||||
+ "可用数:" + jo_in.getString("canuse_qty")
|
||||
+ "变更数:" + change_qty
|
||||
+ "物料标识:" + material_id_In);
|
||||
}
|
||||
structivtService.updateById(jo_in.toJavaObject(StIvtStructivt.class));
|
||||
} else {
|
||||
@@ -339,7 +345,10 @@ public class StorPublicServiceImpl implements StorPublicService {
|
||||
throw new BadRequestException(LangBehavior.language("system.stockNumNotNegative"));
|
||||
}
|
||||
if (jo_in.getDoubleValue("canuse_qty") < 0) {
|
||||
throw new BadRequestException(LangBehavior.language("system.availableNumNotNegative2"));
|
||||
throw new BadRequestException(LangBehavior.language("system.availableNumNotNegative2")
|
||||
+ "可用数:" + jo_in.getString("canuse_qty")
|
||||
+ "变更数:" + change_qty
|
||||
+ "物料标识:" + material_id_In);
|
||||
}
|
||||
structivtService.updateById(jo_in.toJavaObject(StIvtStructivt.class));
|
||||
} else {
|
||||
@@ -403,7 +412,10 @@ public class StorPublicServiceImpl implements StorPublicService {
|
||||
throw new BadRequestException(LangBehavior.language("system.stockNumNotNegative"));
|
||||
}
|
||||
if (jo_in.getDoubleValue("canuse_qty") < 0) {
|
||||
throw new BadRequestException(LangBehavior.language("system.availableNumNotNegative2"));
|
||||
throw new BadRequestException(LangBehavior.language("system.availableNumNotNegative2")
|
||||
+ "可用数:" + jo_in.getString("canuse_qty")
|
||||
+ "变更数:" + change_qty
|
||||
+ "物料标识:" + material_id_In);
|
||||
}
|
||||
structivtService.updateById(jo_in.toJavaObject(StIvtStructivt.class));
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user