fix:异常入库
This commit is contained in:
@@ -216,14 +216,17 @@ public class ProductInstorServiceImpl implements ProductInstorService {
|
|||||||
double box_weight = sub_jo.getDoubleValue("box_weight");
|
double box_weight = sub_jo.getDoubleValue("box_weight");
|
||||||
// 木箱实称重重量
|
// 木箱实称重重量
|
||||||
double real_weight = sub_jo.getDoubleValue("real_weight");
|
double real_weight = sub_jo.getDoubleValue("real_weight");
|
||||||
|
//一楼是否异常
|
||||||
|
String one_exc_param = SpringContextHolder.getBean(SysParamServiceImpl.class).findByCode("one_exc_param").getValue();
|
||||||
|
if (!"1".equals(one_exc_param)) {
|
||||||
if (ObjectUtil.isEmpty(sub_jo.getString("real_weight"))) {
|
if (ObjectUtil.isEmpty(sub_jo.getString("real_weight"))) {
|
||||||
throw new BadRequestException("请先进行木箱称重校验!");
|
throw new BadRequestException("请先进行木箱称重校验!");
|
||||||
}
|
}
|
||||||
|
}
|
||||||
// 判断木箱毛重是否超标
|
// 判断木箱毛重是否超标
|
||||||
if (NumberUtil.sub(box_weight, weight_sys) <= real_weight && NumberUtil.add(box_weight, weight_sys) >= real_weight) {
|
if (NumberUtil.sub(box_weight, weight_sys) <= real_weight && NumberUtil.add(box_weight, weight_sys) >= real_weight) {
|
||||||
} else {
|
} else {
|
||||||
|
if (!"1".equals(one_exc_param)) {
|
||||||
//调用ACS让对应蜂鸣器报警
|
//调用ACS让对应蜂鸣器报警
|
||||||
JSONObject param = new JSONObject();
|
JSONObject param = new JSONObject();
|
||||||
param.put("code", "to_command");
|
param.put("code", "to_command");
|
||||||
@@ -245,7 +248,7 @@ public class ProductInstorServiceImpl implements ProductInstorService {
|
|||||||
throw new BadRequestException("请等待放行!");
|
throw new BadRequestException("请等待放行!");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//判断是该包装计划是否存在长宽高
|
//判断是该包装计划是否存在长宽高
|
||||||
@@ -371,7 +374,9 @@ public class ProductInstorServiceImpl implements ProductInstorService {
|
|||||||
|
|
||||||
form.put("vehicle_code", box_no);
|
form.put("vehicle_code", box_no);
|
||||||
form.put("task_type", "010507");
|
form.put("task_type", "010507");
|
||||||
|
if (!"1".equals(one_exc_param)) {
|
||||||
cutConveyorTask.createTask(form);
|
cutConveyorTask.createTask(form);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
/*
|
/*
|
||||||
* 如果有实际重量则需要判断重量是否超标
|
* 如果有实际重量则需要判断重量是否超标
|
||||||
|
|||||||
Reference in New Issue
Block a user