tao.mo

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
......@@ -50,6 +50,11 @@ public class ConsignmentServiceImpl extends BaseService implements IConsignmentS
* @return com.fedex.connect.common.dependencies.date.vo.ResponseVo
*/
public ResponseVo add(AddBo bo, User user){
ConsignmentAddDto consignmentAddDto = new ConsignmentAddDto();
if (StringUtils.isEmpty(bo.getConsignmentCode()) || !bo.getConsignmentCode().matches("\\d{12}")) {
consignmentAddDto.setIsCreatorFlag(DigitConstants.DIGIT_TWO);
return responseUtils.success(ResponseCode.MESSAGE_CODE_30017, consignmentAddDto);
}
//查询运单表是否存在已提交的运单
LocalDate thirtyDaysAgo = LocalDate.now().minusDays(30);
Consignment consignment = consignmentRepository.findByConsignmentCode(bo.getConsignmentCode(),thirtyDaysAgo);
......@@ -57,7 +62,6 @@ public class ConsignmentServiceImpl extends BaseService implements IConsignmentS
* 不存在则直接返回
*/
if (consignment == null){
ConsignmentAddDto consignmentAddDto = new ConsignmentAddDto();
consignmentAddDto.setIsCreatorFlag(DigitConstants.DIGIT_ZERO);
if (!StringUtils.isEmpty(bo.getShipperAccount())){
if (Objects.equals(user.getAccountNo(),bo.getShipperAccount())){
......@@ -83,7 +87,6 @@ public class ConsignmentServiceImpl extends BaseService implements IConsignmentS
* 非501数据
*/
if (StringUtils.isEmpty(bo.getShipperAccount())){
ConsignmentAddDto consignmentAddDto = new ConsignmentAddDto();
consignmentAddDto.setIsCreatorFlag(DigitConstants.DIGIT_ZERO);
return responseUtils.success(consignmentAddDto);
}
......
......@@ -46,4 +46,5 @@ business_exception_30013=文件名为:{0},上传失败,请检查后重试
business_exception_30014=运单信息加载失败,请稍后重试
business_success_30015=上传成功
business_exception_30016=运单提交失败
business_exception_30017=运单提交失败,该运单正在被其他用户操作,请稍后重试
\ No newline at end of file
business_exception_30017=运单号填写错误
business_exception_30018=运单提交失败,该运单正在被其他用户操作,请稍后重试
......
......@@ -46,4 +46,5 @@ business_exception_30013=文件名为:{0},上传失败,请检查后重试
business_exception_30014=运单信息加载失败,请稍后重试
business_success_30015=上传成功
business_exception_30016=运单提交失败
business_exception_30017=运单提交失败,该运单正在被其他用户操作,请稍后重试
\ No newline at end of file
business_exception_30017=运单号填写错误
business_exception_30018=运单提交失败,该运单正在被其他用户操作,请稍后重试
\ No newline at end of file
......