From 663dbe4ddca1fa409e6acbc1f77d924c161b0c39 Mon Sep 17 00:00:00 2001
From: jiangping <jp@doumee.com>
Date: 星期一, 09 六月 2025 17:04:50 +0800
Subject: [PATCH] 提交一把订单
---
server/service/src/main/java/com/doumee/service/business/impl/SolutionsBaseServiceImpl.java | 45 +++++++++++++++++++++++++++++++++++++++------
1 files changed, 39 insertions(+), 6 deletions(-)
diff --git a/server/service/src/main/java/com/doumee/service/business/impl/SolutionsBaseServiceImpl.java b/server/service/src/main/java/com/doumee/service/business/impl/SolutionsBaseServiceImpl.java
index 8d21eff..fe919a1 100644
--- a/server/service/src/main/java/com/doumee/service/business/impl/SolutionsBaseServiceImpl.java
+++ b/server/service/src/main/java/com/doumee/service/business/impl/SolutionsBaseServiceImpl.java
@@ -145,6 +145,7 @@
//鍘嗗彶鐗堟湰鐨勫伐绉嶄俊鎭�
SolutionWorktype newType = new SolutionWorktype();
BeanUtils.copyProperties(w, newType);
+ newType.setId(null);
newType.setSolutionId(newModel.getId());
solutionWorktypeJoinMapper.insert(newType);
}
@@ -163,12 +164,12 @@
|| Objects.isNull(solutionsBase.getAddValidDays())
|| Objects.isNull(solutionsBase.getDelValidDays())
|| Objects.isNull(solutionsBase.getInsuranceId())
- || Objects.isNull(solutionsBase.getRiskDelayStatus())
- || Objects.isNull(solutionsBase.getRiskDelayTime())
- || Objects.isNull(solutionsBase.getRiskDelayUnit())
- || Objects.isNull(solutionsBase.getRiskNewUserStatus())
- || Objects.isNull(solutionsBase.getRiskNewUserTime())
- || Objects.isNull(solutionsBase.getRiskNewUserUnit())
+// || Objects.isNull(solutionsBase.getRiskDelayStatus())
+// || Objects.isNull(solutionsBase.getRiskDelayTime())
+// || Objects.isNull(solutionsBase.getRiskDelayUnit())
+// || Objects.isNull(solutionsBase.getRiskNewUserStatus())
+// || Objects.isNull(solutionsBase.getRiskNewUserTime())
+// || Objects.isNull(solutionsBase.getRiskNewUserUnit())
||solutionsBase.getInsuranceId()==null
|| Constants.formatIntegerNum(solutionsBase.getMaxAge()) < 0
@@ -181,6 +182,35 @@
if(Constants.equalsInteger(solutionsBase.getValidType(),Constants.ZERO) && Objects.isNull(solutionsBase.getValidTypeNum())){
throw new BusinessException(ResponseStatus.BAD_REQUEST);
}
+ }
+
+
+ @Override
+ public void saveSolutionsRisk(SolutionsBase solutionsBase){
+ if( Objects.isNull(solutionsBase)
+ || Objects.isNull(solutionsBase.getId())
+ ||Objects.isNull(solutionsBase.getRiskDelayStatus())
+ || Objects.isNull(solutionsBase.getRiskDelayTime())
+ || Objects.isNull(solutionsBase.getRiskDelayUnit())
+ || Objects.isNull(solutionsBase.getRiskNewUserStatus())
+ || Objects.isNull(solutionsBase.getRiskNewUserTime())
+ || Objects.isNull(solutionsBase.getRiskNewUserUnit())){
+ throw new BusinessException(ResponseStatus.BAD_REQUEST);
+ }
+ SolutionsBase model = solutionsBaseMapper.selectById(solutionsBase.getId());
+ if(Objects.isNull(model)){
+ throw new BusinessException(ResponseStatus.DATA_EMPTY);
+ }
+ solutionsBaseMapper.update(new UpdateWrapper<SolutionsBase>().lambda()
+ .set(SolutionsBase::getEditDate,new Date())
+ .set(SolutionsBase::getRiskDelayStatus,solutionsBase.getRiskDelayStatus())
+ .set(SolutionsBase::getRiskDelayTime,solutionsBase.getRiskDelayTime())
+ .set(SolutionsBase::getRiskDelayUnit,solutionsBase.getRiskDelayUnit())
+ .set(SolutionsBase::getRiskNewUserStatus,solutionsBase.getRiskNewUserStatus())
+ .set(SolutionsBase::getRiskNewUserTime,solutionsBase.getRiskNewUserTime())
+ .set(SolutionsBase::getRiskNewUserUnit,solutionsBase.getRiskNewUserUnit())
+ .eq(SolutionsBase::getId,solutionsBase.getId())
+ );
}
@Override
@@ -218,6 +248,9 @@
solutionsBaseMapper.deleteBatchIds(ids);
}
+
+
+
@Override
@Transactional(rollbackFor = {BusinessException.class,Exception.class})
public void updateById(SolutionsBase solutionsBase) {
--
Gitblit v1.9.3