|
|
@ -191,6 +191,17 @@ public class ScmVehicleReturnService extends MybatisBaseService<ScmVehicleReturn |
|
|
|
ResultBean resultBean = saveOrUpdateVehicleReturn(scmVehicleReturnDto); |
|
|
|
if (resultBean.getSuccess()) { |
|
|
|
String businessSid = resultBean.getData().toString(); |
|
|
|
//判断车辆的状态是否包含采购退库的状态,如果是的话,返回审核失败
|
|
|
|
ResultBean<List<String>> vinNoList1 = scmVehicleReturnDetailsService.selectVinNoList(businessSid); |
|
|
|
if (vinNoList1.getSuccess() && vinNoList1.getData() != null && vinNoList1.getData().size() != 0) { |
|
|
|
//查询车架号数组中是否有采购退库状态的车辆,若有则返回true,没有返回false
|
|
|
|
ResultBean<Boolean> stringResultBean = baseVehicleFeign.selectStateByVinNo(vinNoList1.getData()); |
|
|
|
if (stringResultBean.getSuccess()) { |
|
|
|
if (stringResultBean.getData()) { |
|
|
|
return rb.setMsg("该申请中包含车辆状态已是采购退库状态的车辆"); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
Map<String, Object> variables = new HashMap<>(); |
|
|
|
variables.put("businessSid", businessSid); |
|
|
|
if (Integer.parseInt(scmVehicleReturnDto.getMoney()) > 0) { |
|
|
@ -263,6 +274,12 @@ public class ScmVehicleReturnService extends MybatisBaseService<ScmVehicleReturn |
|
|
|
if (vinNoList1.getSuccess() && vinNoList1.getData() != null && vinNoList1.getData().size() != 0) { |
|
|
|
//查询车架号数组中是否有采购退库状态的车辆,若有则返回true,没有返回false
|
|
|
|
ResultBean<Boolean> stringResultBean = baseVehicleFeign.selectStateByVinNo(vinNoList1.getData()); |
|
|
|
if (stringResultBean.getSuccess()) { |
|
|
|
if (stringResultBean.getData()) { |
|
|
|
return rb.setMsg("该申请中包含车辆状态已是采购退库状态的车辆"); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|