|
|
@ -221,6 +221,7 @@ public class ScmApplyInboundService extends MybatisBaseService<ScmApplyInboundMa |
|
|
|
inboundVehicle.setApplicationCode(billNo); |
|
|
|
inboundVehicle.setSid(UUID.randomUUID().toString()); |
|
|
|
inboundVehicle.setOrgSidPath(orgPath); |
|
|
|
inboundVehicle.setNewUpdateDate(DateUtil.formatDate(new Date())); |
|
|
|
save(inboundVehicle); |
|
|
|
String num = dto.getNum(); |
|
|
|
if (StringUtils.isNotBlank(num) && StringUtils.isNumeric(num)) { |
|
|
@ -245,6 +246,9 @@ public class ScmApplyInboundService extends MybatisBaseService<ScmApplyInboundMa |
|
|
|
} |
|
|
|
return new ResultBean().success().setMsg("保存成功").setData(inboundVehicle.getSid()); |
|
|
|
} else { // 修改
|
|
|
|
if (StringUtils.isBlank(dto.getGuidedPrice())) { |
|
|
|
return new ResultBean().fail().setMsg("请填写销售指导价"); |
|
|
|
} |
|
|
|
if (StringUtils.isBlank(dto.getDepartureDate())) { |
|
|
|
return new ResultBean().fail().setMsg("请填写厂家发车日期"); |
|
|
|
} |
|
|
@ -291,6 +295,7 @@ public class ScmApplyInboundService extends MybatisBaseService<ScmApplyInboundMa |
|
|
|
ScmApplyInbound scmApplyInbound = fetchBySid(dto.getSid()); |
|
|
|
BeanUtil.copyProperties(dto, scmApplyInbound); |
|
|
|
scmApplyInbound.setOrgSidPath(dto.getOrgPath()); |
|
|
|
scmApplyInbound.setNewUpdateDate(DateUtil.formatDate(new Date())); |
|
|
|
updateById(scmApplyInbound); |
|
|
|
scmFileService.delByMainSid(dto.getSid()); |
|
|
|
if (scmFiles.size() > 0) { |
|
|
|