|
|
@ -22,6 +22,7 @@ import com.daqing.framework.domain.crms.request.DgApplyAmountInfoRequest; |
|
|
|
import com.daqing.framework.domain.crms.response.CrmsCode; |
|
|
|
import com.daqing.framework.domain.crms.response.CrmsCode; |
|
|
|
import com.daqing.framework.domain.guarantee.*; |
|
|
|
import com.daqing.framework.domain.guarantee.*; |
|
|
|
import com.daqing.framework.domain.guarantee.po.DgGuaranteePO; |
|
|
|
import com.daqing.framework.domain.guarantee.po.DgGuaranteePO; |
|
|
|
|
|
|
|
import com.daqing.framework.domain.hrms.ext.EmployeeVO; |
|
|
|
import com.daqing.framework.domain.hrms.response.HrmsCode; |
|
|
|
import com.daqing.framework.domain.hrms.response.HrmsCode; |
|
|
|
import com.daqing.framework.exception.ExceptionCast; |
|
|
|
import com.daqing.framework.exception.ExceptionCast; |
|
|
|
import com.daqing.framework.model.StatusCode; |
|
|
|
import com.daqing.framework.model.StatusCode; |
|
|
@ -192,6 +193,26 @@ public class DgGuaranteeAssignUserServiceImpl extends ServiceImpl<DgGuaranteeAss |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//查询该业务id下对应的A角B角
|
|
|
|
|
|
|
|
DgGuaranteeAssignUser assignUser2 = this.baseMapper.selectOne(new QueryWrapper<DgGuaranteeAssignUser>() |
|
|
|
|
|
|
|
.eq("business_id", guaranteeAssignUser.getBusinessId()).eq("type", 1)); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
DgGuaranteeAssignUser assignUser3 = this.baseMapper.selectOne(new QueryWrapper<DgGuaranteeAssignUser>() |
|
|
|
|
|
|
|
.eq("business_id", guaranteeAssignUser.getBusinessId()).eq("type", 2)); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(assignUser2 !=null || assignUser3 != null){ |
|
|
|
|
|
|
|
Integer empAId = assignUser2.getEmpId(); |
|
|
|
|
|
|
|
Integer empBId = assignUser3.getEmpId(); |
|
|
|
|
|
|
|
Integer arr[] = new Integer[]{ |
|
|
|
|
|
|
|
empAId,empBId |
|
|
|
|
|
|
|
}; |
|
|
|
|
|
|
|
if(arr.length>0){ |
|
|
|
|
|
|
|
ResponseResult<List<EmployeeVO>> listResponseResult = hrmsFeignService.listEmpNameByUserId(arr); |
|
|
|
|
|
|
|
assignUser.setAName(listResponseResult.getData().get(0).getName()); |
|
|
|
|
|
|
|
assignUser.setBName(listResponseResult.getData().get(1).getName()); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
GuaranteeDetailResponse guaranteeDetailResponse = new GuaranteeDetailResponse(); |
|
|
|
GuaranteeDetailResponse guaranteeDetailResponse = new GuaranteeDetailResponse(); |
|
|
|
guaranteeDetailResponse.setDgApplyAmountInfo(dgApplyAmountInfo); |
|
|
|
guaranteeDetailResponse.setDgApplyAmountInfo(dgApplyAmountInfo); |
|
|
|
guaranteeDetailResponse.setDgEnclosureInfo(dgEnclosureInfo); |
|
|
|
guaranteeDetailResponse.setDgEnclosureInfo(dgEnclosureInfo); |
|
|
@ -306,22 +327,59 @@ public class DgGuaranteeAssignUserServiceImpl extends ServiceImpl<DgGuaranteeAss |
|
|
|
//AB角调查,修改审核意见以及状态
|
|
|
|
//AB角调查,修改审核意见以及状态
|
|
|
|
dgGuaranteeAssignUser.setStatus(investigateGuaranteeRequest.getStatus());//状态为审核中
|
|
|
|
dgGuaranteeAssignUser.setStatus(investigateGuaranteeRequest.getStatus());//状态为审核中
|
|
|
|
dgGuaranteeAssignUser.setOperatingStatus(StatusCode.CZ_PROCESSED);//操作状态设置为已处理
|
|
|
|
dgGuaranteeAssignUser.setOperatingStatus(StatusCode.CZ_PROCESSED);//操作状态设置为已处理
|
|
|
|
this.baseMapper.updateById(dgGuaranteeAssignUser); |
|
|
|
// this.baseMapper.updateById(dgGuaranteeAssignUser);
|
|
|
|
|
|
|
|
//插入或更新的字段有 空字符串 或者 null
|
|
|
|
|
|
|
|
this.baseMapper.update( |
|
|
|
|
|
|
|
null, |
|
|
|
|
|
|
|
Wrappers.<DgGuaranteeAssignUser>lambdaUpdate() |
|
|
|
|
|
|
|
.set(DgGuaranteeAssignUser::getApplyContent, investigateGuaranteeRequest.getApplyContent()) //把email设置成null
|
|
|
|
|
|
|
|
.set(DgGuaranteeAssignUser::getOperatingStatus, StatusCode.CZ_PROCESSED) |
|
|
|
|
|
|
|
.set(DgGuaranteeAssignUser::getStatus, investigateGuaranteeRequest.getStatus()) |
|
|
|
|
|
|
|
.eq(DgGuaranteeAssignUser::getId, investigateGuaranteeRequest.getId()) |
|
|
|
|
|
|
|
); |
|
|
|
}else if(investigateGuaranteeRequest.getIsSaveOrCommit() != null && investigateGuaranteeRequest.getIsSaveOrCommit()!=1){//保存
|
|
|
|
}else if(investigateGuaranteeRequest.getIsSaveOrCommit() != null && investigateGuaranteeRequest.getIsSaveOrCommit()!=1){//保存
|
|
|
|
dgGuaranteeAssignUser.setStatus(guaranteeAssignUser.getStatus());//审批状态 当前是什么状态就是什么状态
|
|
|
|
dgGuaranteeAssignUser.setStatus(guaranteeAssignUser.getStatus());//审批状态 当前是什么状态就是什么状态
|
|
|
|
dgGuaranteeAssignUser.setOperatingStatus(StatusCode.CZ_ON_HAND);//操作状态设置为待处理
|
|
|
|
dgGuaranteeAssignUser.setOperatingStatus(StatusCode.CZ_ON_HAND);//操作状态设置为待处理
|
|
|
|
this.baseMapper.updateById(dgGuaranteeAssignUser); |
|
|
|
//this.baseMapper.updateById(dgGuaranteeAssignUser);
|
|
|
|
|
|
|
|
//插入或更新的字段有 空字符串 或者 null
|
|
|
|
|
|
|
|
this.baseMapper.update( |
|
|
|
|
|
|
|
null, |
|
|
|
|
|
|
|
Wrappers.<DgGuaranteeAssignUser>lambdaUpdate() |
|
|
|
|
|
|
|
.set(DgGuaranteeAssignUser::getApplyContent, investigateGuaranteeRequest.getApplyContent()) //把email设置成null
|
|
|
|
|
|
|
|
.set(DgGuaranteeAssignUser::getOperatingStatus, StatusCode.CZ_ON_HAND) |
|
|
|
|
|
|
|
.set(DgGuaranteeAssignUser::getStatus, guaranteeAssignUser.getStatus()) |
|
|
|
|
|
|
|
.eq(DgGuaranteeAssignUser::getId, investigateGuaranteeRequest.getId()) |
|
|
|
|
|
|
|
); |
|
|
|
}else{ |
|
|
|
}else{ |
|
|
|
if(investigateGuaranteeRequest.getStatus().equals(StatusCode.SP_REFUSE)){//如果为拒绝,则修改所有审批状态为拒绝,同时A,B角操作状态均为已处理
|
|
|
|
if(investigateGuaranteeRequest.getStatus().equals(StatusCode.SP_REFUSE)){//如果为拒绝,则修改所有审批状态为拒绝,同时A,B角操作状态均为已处理
|
|
|
|
dgGuaranteeAssignUser.setStatus(StatusCode.SP_REFUSE);//拒绝
|
|
|
|
dgGuaranteeAssignUser.setStatus(StatusCode.SP_REFUSE);//拒绝
|
|
|
|
this.baseMapper.update(dgGuaranteeAssignUser,new QueryWrapper<DgGuaranteeAssignUser>() |
|
|
|
this.baseMapper.update(dgGuaranteeAssignUser,new QueryWrapper<DgGuaranteeAssignUser>() |
|
|
|
.eq("business_id",guaranteeAssignUser.getBusinessId())); |
|
|
|
.eq("business_id",guaranteeAssignUser.getBusinessId())); |
|
|
|
dgGuaranteeAssignUser.setOperatingStatus(StatusCode.CZ_PROCESSED);//已处理
|
|
|
|
dgGuaranteeAssignUser.setOperatingStatus(StatusCode.CZ_PROCESSED);//已处理
|
|
|
|
this.baseMapper.update(dgGuaranteeAssignUser,new QueryWrapper<DgGuaranteeAssignUser>() |
|
|
|
/* this.baseMapper.update(dgGuaranteeAssignUser,new QueryWrapper<DgGuaranteeAssignUser>() |
|
|
|
.eq("business_id",guaranteeAssignUser.getBusinessId()).eq("type",1)); |
|
|
|
.eq("business_id",guaranteeAssignUser.getBusinessId()).eq("type",1)); |
|
|
|
this.baseMapper.update(dgGuaranteeAssignUser,new QueryWrapper<DgGuaranteeAssignUser>() |
|
|
|
this.baseMapper.update(dgGuaranteeAssignUser,new QueryWrapper<DgGuaranteeAssignUser>() |
|
|
|
.eq("business_id",guaranteeAssignUser.getBusinessId()).eq("type",2)); |
|
|
|
.eq("business_id",guaranteeAssignUser.getBusinessId()).eq("type",2));*/ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.baseMapper.update( |
|
|
|
|
|
|
|
null, |
|
|
|
|
|
|
|
Wrappers.<DgGuaranteeAssignUser>lambdaUpdate() |
|
|
|
|
|
|
|
.set(DgGuaranteeAssignUser::getApplyContent, investigateGuaranteeRequest.getApplyContent()) //把email设置成null
|
|
|
|
|
|
|
|
.set(DgGuaranteeAssignUser::getOperatingStatus, StatusCode.CZ_PROCESSED) |
|
|
|
|
|
|
|
.set(DgGuaranteeAssignUser::getStatus, StatusCode.SP_REFUSE) |
|
|
|
|
|
|
|
.eq(DgGuaranteeAssignUser::getBusinessId, guaranteeAssignUser.getBusinessId()) |
|
|
|
|
|
|
|
.eq(DgGuaranteeAssignUser::getType, 1) |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.baseMapper.update( |
|
|
|
|
|
|
|
null, |
|
|
|
|
|
|
|
Wrappers.<DgGuaranteeAssignUser>lambdaUpdate() |
|
|
|
|
|
|
|
.set(DgGuaranteeAssignUser::getApplyContent, investigateGuaranteeRequest.getApplyContent()) //把email设置成null
|
|
|
|
|
|
|
|
.set(DgGuaranteeAssignUser::getOperatingStatus, StatusCode.CZ_PROCESSED) |
|
|
|
|
|
|
|
.set(DgGuaranteeAssignUser::getStatus, StatusCode.SP_REFUSE) |
|
|
|
|
|
|
|
.eq(DgGuaranteeAssignUser::getBusinessId, guaranteeAssignUser.getBusinessId()) |
|
|
|
|
|
|
|
.eq(DgGuaranteeAssignUser::getType, 2) |
|
|
|
|
|
|
|
); |
|
|
|
//拒绝状态下,修改业务状态为已否决
|
|
|
|
//拒绝状态下,修改业务状态为已否决
|
|
|
|
DgBusinessProcessStatus processStatus = new DgBusinessProcessStatus(); |
|
|
|
DgBusinessProcessStatus processStatus = new DgBusinessProcessStatus(); |
|
|
|
processStatus.setBusinessStatus(3);//已否决
|
|
|
|
processStatus.setBusinessStatus(3);//已否决
|
|
|
@ -330,7 +388,16 @@ public class DgGuaranteeAssignUserServiceImpl extends ServiceImpl<DgGuaranteeAss |
|
|
|
}else{ |
|
|
|
}else{ |
|
|
|
dgGuaranteeAssignUser.setStatus(investigateGuaranteeRequest.getStatus());//审批状态 请求过来是什么状态就是什么
|
|
|
|
dgGuaranteeAssignUser.setStatus(investigateGuaranteeRequest.getStatus());//审批状态 请求过来是什么状态就是什么
|
|
|
|
dgGuaranteeAssignUser.setOperatingStatus(StatusCode.CZ_PROCESSED);//操作状态设置为已处理
|
|
|
|
dgGuaranteeAssignUser.setOperatingStatus(StatusCode.CZ_PROCESSED);//操作状态设置为已处理
|
|
|
|
this.baseMapper.updateById(dgGuaranteeAssignUser); |
|
|
|
//this.baseMapper.updateById(dgGuaranteeAssignUser);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.baseMapper.update( |
|
|
|
|
|
|
|
null, |
|
|
|
|
|
|
|
Wrappers.<DgGuaranteeAssignUser>lambdaUpdate() |
|
|
|
|
|
|
|
.set(DgGuaranteeAssignUser::getApplyContent, investigateGuaranteeRequest.getApplyContent()) //把email设置成null
|
|
|
|
|
|
|
|
.set(DgGuaranteeAssignUser::getOperatingStatus, StatusCode.CZ_PROCESSED) |
|
|
|
|
|
|
|
.set(DgGuaranteeAssignUser::getStatus, investigateGuaranteeRequest.getStatus()) |
|
|
|
|
|
|
|
.eq(DgGuaranteeAssignUser::getId, investigateGuaranteeRequest.getId()) |
|
|
|
|
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|