Merge remote-tracking branch 'origin/master'
# Conflicts: # server/biz-customer/src/main/resources/message_en_US.properties # server/biz-customer/src/main/resources/message_zh_CN.properties
Showing
3 changed files
with
9 additions
and
4 deletions
| ... | @@ -50,6 +50,11 @@ public class ConsignmentServiceImpl extends BaseService implements IConsignmentS | ... | @@ -50,6 +50,11 @@ public class ConsignmentServiceImpl extends BaseService implements IConsignmentS |
| 50 | * @return com.fedex.connect.common.dependencies.date.vo.ResponseVo | 50 | * @return com.fedex.connect.common.dependencies.date.vo.ResponseVo |
| 51 | */ | 51 | */ |
| 52 | public ResponseVo add(AddBo bo, User user){ | 52 | public ResponseVo add(AddBo bo, User user){ |
| 53 | + ConsignmentAddDto consignmentAddDto = new ConsignmentAddDto(); | ||
| 54 | + if (StringUtils.isEmpty(bo.getConsignmentCode()) || !bo.getConsignmentCode().matches("\\d{12}")) { | ||
| 55 | + consignmentAddDto.setIsCreatorFlag(DigitConstants.DIGIT_TWO); | ||
| 56 | + return responseUtils.success(ResponseCode.MESSAGE_CODE_30017, consignmentAddDto); | ||
| 57 | + } | ||
| 53 | //查询运单表是否存在已提交的运单 | 58 | //查询运单表是否存在已提交的运单 |
| 54 | LocalDate thirtyDaysAgo = LocalDate.now().minusDays(30); | 59 | LocalDate thirtyDaysAgo = LocalDate.now().minusDays(30); |
| 55 | Consignment consignment = consignmentRepository.findByConsignmentCode(bo.getConsignmentCode(),thirtyDaysAgo); | 60 | Consignment consignment = consignmentRepository.findByConsignmentCode(bo.getConsignmentCode(),thirtyDaysAgo); |
| ... | @@ -57,7 +62,6 @@ public class ConsignmentServiceImpl extends BaseService implements IConsignmentS | ... | @@ -57,7 +62,6 @@ public class ConsignmentServiceImpl extends BaseService implements IConsignmentS |
| 57 | * 不存在则直接返回 | 62 | * 不存在则直接返回 |
| 58 | */ | 63 | */ |
| 59 | if (consignment == null){ | 64 | if (consignment == null){ |
| 60 | - ConsignmentAddDto consignmentAddDto = new ConsignmentAddDto(); | ||
| 61 | consignmentAddDto.setIsCreatorFlag(DigitConstants.DIGIT_ZERO); | 65 | consignmentAddDto.setIsCreatorFlag(DigitConstants.DIGIT_ZERO); |
| 62 | if (!StringUtils.isEmpty(bo.getShipperAccount())){ | 66 | if (!StringUtils.isEmpty(bo.getShipperAccount())){ |
| 63 | if (Objects.equals(user.getAccountNo(),bo.getShipperAccount())){ | 67 | if (Objects.equals(user.getAccountNo(),bo.getShipperAccount())){ |
| ... | @@ -83,7 +87,6 @@ public class ConsignmentServiceImpl extends BaseService implements IConsignmentS | ... | @@ -83,7 +87,6 @@ public class ConsignmentServiceImpl extends BaseService implements IConsignmentS |
| 83 | * 非501数据 | 87 | * 非501数据 |
| 84 | */ | 88 | */ |
| 85 | if (StringUtils.isEmpty(bo.getShipperAccount())){ | 89 | if (StringUtils.isEmpty(bo.getShipperAccount())){ |
| 86 | - ConsignmentAddDto consignmentAddDto = new ConsignmentAddDto(); | ||
| 87 | consignmentAddDto.setIsCreatorFlag(DigitConstants.DIGIT_ZERO); | 90 | consignmentAddDto.setIsCreatorFlag(DigitConstants.DIGIT_ZERO); |
| 88 | return responseUtils.success(consignmentAddDto); | 91 | return responseUtils.success(consignmentAddDto); |
| 89 | } | 92 | } | ... | ... |
| ... | @@ -46,4 +46,5 @@ business_exception_30013=文件名为:{0},上传失败,请检查后重试 | ... | @@ -46,4 +46,5 @@ business_exception_30013=文件名为:{0},上传失败,请检查后重试 |
| 46 | business_exception_30014=运单信息加载失败,请稍后重试 | 46 | business_exception_30014=运单信息加载失败,请稍后重试 |
| 47 | business_success_30015=上传成功 | 47 | business_success_30015=上传成功 |
| 48 | business_exception_30016=运单提交失败 | 48 | business_exception_30016=运单提交失败 |
| 49 | -business_exception_30017=运单提交失败,该运单正在被其他用户操作,请稍后重试 | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file |
| 49 | +business_exception_30017=运单号填写错误 | ||
| 50 | +business_exception_30018=运单提交失败,该运单正在被其他用户操作,请稍后重试 | ... | ... |
| ... | @@ -46,4 +46,5 @@ business_exception_30013=文件名为:{0},上传失败,请检查后重试 | ... | @@ -46,4 +46,5 @@ business_exception_30013=文件名为:{0},上传失败,请检查后重试 |
| 46 | business_exception_30014=运单信息加载失败,请稍后重试 | 46 | business_exception_30014=运单信息加载失败,请稍后重试 |
| 47 | business_success_30015=上传成功 | 47 | business_success_30015=上传成功 |
| 48 | business_exception_30016=运单提交失败 | 48 | business_exception_30016=运单提交失败 |
| 49 | -business_exception_30017=运单提交失败,该运单正在被其他用户操作,请稍后重试 | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file |
| 49 | +business_exception_30017=运单号填写错误 | ||
| 50 | +business_exception_30018=运单提交失败,该运单正在被其他用户操作,请稍后重试 | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file | ... | ... |
-
Please register or login to post a comment