Ver Fonte

物料申请监听 库存数量减少 报错信息 规格型号改为计量单位

xieyn há 1 ano atrás
pai
commit
b0b690c283

+ 2 - 2
jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/activiti/listener/ListenerMaterialApply.java

@@ -68,11 +68,11 @@ public class ListenerMaterialApply implements TaskListener, ExecutionListener {
                     queryWrapper.eq("unit",unit);
                     Material material = materialMapper.selectOne(queryWrapper);
                     if(material==null){
-                        throw new Exception("物料名称为"+materialName+";规格型号为"+unit+"的物料不存在");
+                        throw new Exception("物料名称为"+materialName+";计量单位为"+unit+"的物料不存在");
                     }
                     BigDecimal  quantity = material.getQuantity();
                     if(quantity.compareTo(amount)==-1){
-                        throw new Exception("物料名称为"+materialName+";规格型号为"+unit+"的物料库存数量小于申请数量!");
+                        throw new Exception("物料名称为"+materialName+";计量单位为"+unit+"的物料库存数量小于申请数量!");
                     }
                     material.setQuantity(material.getQuantity().subtract(amount));
                     materialMapper.updateById(material);