|
@@ -197,13 +197,13 @@ public class AppDeviceLogServiceImpl extends JpaServiceImp<AppDeviceLog, String>
|
|
|
param.getSn().forEach(p -> {
|
|
|
AppDevice appDevice = appDeviceService.getOne(QueryParamExp.eq("sn", p));
|
|
|
if (null == appDevice) {
|
|
|
- new ApiRuntimeException(p + "设备信息不存在!");
|
|
|
+ throw new ApiRuntimeException(p + "设备信息不存在!");
|
|
|
}
|
|
|
if (1 != appDevice.getStatus() && 2 != appDevice.getStatus()) {
|
|
|
- new ApiRuntimeException(p + "不是入库状态,不能调拨!");
|
|
|
+ throw new ApiRuntimeException(p + "不是入库状态,不能调拨!");
|
|
|
}
|
|
|
if (1 != appDevice.getCheckStatus()) {
|
|
|
- new ApiRuntimeException(p + "自检未通过,不能调拨!");
|
|
|
+ throw new ApiRuntimeException(p + "自检未通过,不能调拨!");
|
|
|
}
|
|
|
});
|
|
|
param.getSn().forEach(p -> {
|
|
@@ -225,7 +225,7 @@ public class AppDeviceLogServiceImpl extends JpaServiceImp<AppDeviceLog, String>
|
|
|
save(appDeviceLog); // 记录划拨日志
|
|
|
}
|
|
|
else{
|
|
|
- new ApiRuntimeException(p + "不是入库状态或自检未通过,不能调拨!");
|
|
|
+ throw new ApiRuntimeException(p + "不是入库状态或自检未通过,不能调拨!");
|
|
|
}
|
|
|
});
|
|
|
}
|
|
@@ -283,10 +283,10 @@ public class AppDeviceLogServiceImpl extends JpaServiceImp<AppDeviceLog, String>
|
|
|
param.getSn().forEach(p -> {
|
|
|
AppDevice appDevice = appDeviceService.getOne(QueryParamExp.eq("sn", p));
|
|
|
if (null == appDevice) {
|
|
|
- new ApiRuntimeException(p + "设备信息不存在!");
|
|
|
+ throw new ApiRuntimeException(p + "设备信息不存在!");
|
|
|
}
|
|
|
if (2 != appDevice.getStatus() && 3 != appDevice.getStatus()) {
|
|
|
- new ApiRuntimeException(p + "不是调拨状态,不能出库!");
|
|
|
+ throw new ApiRuntimeException(p + "不是调拨状态,不能出库!");
|
|
|
}
|
|
|
});
|
|
|
BigInteger finalOperateID = operateID;
|
|
@@ -306,7 +306,7 @@ public class AppDeviceLogServiceImpl extends JpaServiceImp<AppDeviceLog, String>
|
|
|
save(appDeviceLog); // 记录出库日志
|
|
|
}
|
|
|
else{
|
|
|
- new ApiRuntimeException(p + "不是调拨状态,不能出库!");
|
|
|
+ throw new ApiRuntimeException(p + "不是调拨状态,不能出库!");
|
|
|
}
|
|
|
});
|
|
|
}
|