Commit 5fdb92e7 authored by huyuchen's avatar huyuchen

停止合作相关内容修改

parent 04fb9df5
......@@ -339,4 +339,56 @@ public class TEmployeeProjectController {
public Boolean updateEmployeeSalaryStatus(@RequestBody EmpStatusVo vo) {
return tEmployeeProjectService.updateEmployeeSalaryStatus(vo);
}
/**
* 查询项目档案在档人数
* @author hyc
* @param deptNo
* @date 2022-12-12 17:45
* @return R
*/
@Operation(summary = "查询项目档案在档人数", description = "查询项目档案在档人数")
@PostMapping("/selectInUseEmployeeProjectCount")
public R selectInUseEmployeeProjectCount(@RequestBody String deptNo) {
return tEmployeeProjectService.selectInUseEmployeeProjectCount(deptNo);
}
/**
* 查询项目员工合同在用数
* @author hyc
* @param deptNo
* @date 2022-12-12 17:45
* @return R
*/
@Operation(summary = "查询项目员工合同在用数", description = "查询项目员工合同在用数")
@PostMapping("/selectInUseEmployeeContractCount")
public R selectInUseEmployeeContractCount(@RequestBody String deptNo) {
return tEmployeeProjectService.selectInUseEmployeeContractCount(deptNo);
}
/**
* 查询社保在保人数
* @author hyc
* @param deptNo
* @date 2022-12-12 17:45
* @return R
*/
@Operation(summary = "查询社保在保人数", description = "查询社保在保人数")
@PostMapping("/selectInUseSocialCount")
public R selectInUseSocialCount(@RequestBody String deptNo) {
return tEmployeeProjectService.selectInUseSocialCount(deptNo);
}
/**
* 查询公积金在保人数
* @author hyc
* @param deptNo
* @date 2022-12-12 17:45
* @return R
*/
@Operation(summary = "查询公积金在保人数", description = "查询公积金在保人数")
@PostMapping("/selectInUseFundCount")
public R selectInUseFundCount(@RequestBody String deptNo) {
return tEmployeeProjectService.selectInUseFundCount(deptNo);
}
}
......@@ -323,4 +323,17 @@ public class TSettleDomainController {
public R<IPage<IdNameNoVo>> getUnitPage(Page<IdNameNoVo> page, IdNameNoVo idNameNo) {
return R.ok(tSettleDomainService.getUnitPage(page, idNameNo));
}
/**
* 修改项目表--EKP调用接口
* @author hyc
* @param jsonObject
* @return R
*/
@Operation(summary = "更新项目服务状态--EKP调用接口", description = "更新项目服务状态--EKP调用接口")
@SysLog("更新项目服务状态--EKP调用接口")
@PostMapping("/updateProjectStopStatus")
public R updateProjectStopStatus(@RequestBody JSONObject jsonObject) {
return tSettleDomainService.updateProjectStopStatus(jsonObject);
}
}
......@@ -224,4 +224,13 @@ public interface TEmployeeProjectService extends IService<TEmployeeProject> {
* @return: void
**/
void everyDayUpdateEmployeContractStatus();
R selectInUseEmployeeProjectCount(String deptNo);
R selectInUseEmployeeContractCount(String deptNo);
R selectInUseSocialCount(String deptNo);
R selectInUseFundCount(String deptNo);
}
......@@ -17,6 +17,7 @@
package com.yifu.cloud.plus.v1.yifu.archives.service;
import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
......@@ -103,4 +104,6 @@ public interface TSettleDomainService extends IService<TSettleDomain> {
R updateProjectInfo(List<TSettleDomainEkpVo> list);
R updateProjectStopStatus(JSONObject jsonObject);
}
......@@ -96,12 +96,6 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
@Lazy
private DoJointTask doJointTask;
@Autowired
private DaprCheckProperties daprCheckProperties;
@Autowired
private DaprUpmsProperties daprUpmsProperties;
@Override
public R addCheck(TEmployeeProject tEmployeeProject) {
......@@ -118,7 +112,7 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
.eq(TSettleDomain::getStopFlag, CommonConstants.ZERO_STRING)
.eq(TSettleDomain::getDeleteFlag, CommonConstants.ZERO_STRING));
if (Common.isEmpty(tSettleDomain)) {
return R.failed("未找到对应的项目,请核实");
return R.failed("未找到对应的项目或者项目已停止合作,请核实");
}
//项目下已有身份证信息
......@@ -940,27 +934,6 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
if (tEmployeeProject.getProjectStatus() != CommonConstants.dingleDigitIntArray[0]) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.CHECKS_EMP_DELETE_ERROR)));
} else {
/*if (Common.isNotNull(excel.getBankNo())) {
TCheckBankNo check = new TCheckBankNo();
check.setBankNo(excel.getBankNo());
check.setIdNum(excel.getEmpIdcard());
check.setName(tEmployeeProject.getEmpName());
R<CheckBankNoVo> checkListR = HttpDaprUtil.invokeMethodPost(daprCheckProperties.getAppUrl(), daprCheckProperties.getAppId()
, "/tcheckbankno/inner/checkBankNo", check, CheckBankNoVo.class, SecurityConstants.FROM_IN);
if (checkListR != null && checkListR.getData() != null) {
CheckBankNoVo vo = checkListR.getData();
check = (null == vo.getRes()) ? null : vo.getRes().getData();
if (Common.isEmpty(vo)) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), EmployeeConstants.CHECK_NO_RESPONSE));
} else if (!CommonConstants.SUCCESS.equals(vo.getRes().getCode())) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), vo.getRes().getMsg()));
} else if (null != check && !check.getResult().equals(CommonConstants.ZERO_ONE)) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), check.getRemark()));
}
} else {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), EmployeeConstants.CHECK_NO_RESPONSE));
}
}*/
updateExcelProj(excel, updateList, tEmployeeProject);
TEmployeeProject tEmployeeProjectOld = this.getById(tEmployeeProject.getId());
newOldProject = new EmployeeProjectNewOldVO();
......@@ -1442,4 +1415,47 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
public void everyDayUpdateEmployeContractStatus() {
baseMapper.everyDayUpdateEmployeContractStatus();
}
@Override
public R selectInUseEmployeeProjectCount(String deptNo) {
//查询项目档案在档人数
return R.ok(baseMapper.selectCount(Wrappers.<TEmployeeProject>query().lambda()
.eq(TEmployeeProject::getDeptNo,deptNo)
.eq(TEmployeeProject::getProjectStatus,CommonConstants.ZERO_INT)
.eq(TEmployeeProject::getDeleteFlag,CommonConstants.ZERO_STRING)));
}
@Override
public R selectInUseEmployeeContractCount(String deptNo) {
//项目员工合同在用数
return R.ok(baseMapper.selectCount(Wrappers.<TEmployeeProject>query().lambda()
.eq(TEmployeeProject::getDeptNo,deptNo)
.eq(TEmployeeProject::getProjectStatus,CommonConstants.ZERO_INT)
.eq(TEmployeeProject::getDeleteFlag,CommonConstants.ZERO_STRING)
.eq(TEmployeeProject::getContractStatus,CommonConstants.ONE_INT)));
}
@Override
public R selectInUseSocialCount(String deptNo) {
//查询社保在保人数
return R.ok(baseMapper.selectCount(Wrappers.<TEmployeeProject>query().lambda()
.eq(TEmployeeProject::getDeptNo,deptNo)
.eq(TEmployeeProject::getProjectStatus,CommonConstants.ZERO_INT)
.eq(TEmployeeProject::getDeleteFlag,CommonConstants.ZERO_STRING)
.and(obj -> obj.eq(TEmployeeProject::getSocialStatus, CommonConstants.ONE_INT)
.or().eq(TEmployeeProject::getSocialStatus, CommonConstants.TWO_INT)
.or().eq(TEmployeeProject::getSocialStatus, CommonConstants.THREE_INT))));
}
@Override
public R selectInUseFundCount(String deptNo) {
//查询公积金在保人数
return R.ok(baseMapper.selectCount(Wrappers.<TEmployeeProject>query().lambda()
.eq(TEmployeeProject::getDeptNo,deptNo)
.eq(TEmployeeProject::getProjectStatus,CommonConstants.ZERO_INT)
.eq(TEmployeeProject::getDeleteFlag,CommonConstants.ZERO_STRING)
.and(obj -> obj.eq(TEmployeeProject::getFundStatus, CommonConstants.ONE_INT)
.or().eq(TEmployeeProject::getFundStatus, CommonConstants.TWO_INT)
.or().eq(TEmployeeProject::getFundStatus, CommonConstants.THREE_INT))));
}
}
......@@ -17,6 +17,7 @@
package com.yifu.cloud.plus.v1.yifu.archives.service.impl;
import cn.hutool.core.bean.BeanUtil;
import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
......@@ -198,6 +199,34 @@ public class TSettleDomainServiceImpl extends ServiceImpl<TSettleDomainMapper, T
}
}
@Override
public R updateProjectStopStatus(JSONObject jsonObject) {
if (Common.isEmpty(jsonObject.getString("deptNo")) ||
Common.isEmpty(jsonObject.getString("stopFlag"))) {
return R.failed(CommonConstants.PARAM_IS_NOT_ERROR);
}
String deptNo = jsonObject.getString("deptNo");
String stopFlag = jsonObject.getString("stopFlag");
if (!CommonConstants.ONE_STRING.equals(stopFlag) && !CommonConstants.TWO_STRING.equals(stopFlag) &&
!CommonConstants.ZERO_STRING.equals(stopFlag)) {
return R.failed("服务状态传参错误");
}
TSettleDomain settleDomain;
settleDomain = baseMapper.selectOne(Wrappers.<TSettleDomain>query().lambda()
.eq(TSettleDomain::getDepartNo,deptNo)
.eq(TSettleDomain::getDeleteFlag,CommonConstants.ZERO_STRING)
.last(CommonConstants.LAST_ONE_SQL));
if (Common.isEmpty(settleDomain)) {
return R.failed("不存在该项目");
}
if (settleDomain.getStopFlag().equals(stopFlag)) {
return R.failed("不可重复变更项目服务状态");
}
settleDomain.setStopFlag(stopFlag);
baseMapper.updateById(settleDomain);
return R.ok();
}
private String checkInfo(TSettleDomain domain) {
if (Common.isEmpty(domain.getId())){
return ArchivesConstants.SETTLE_DOMAIN_ID_NOT_EMPTY;
......
......@@ -100,7 +100,7 @@ archives.project.change.not.exist=\u4EBA\u5458\u5728\u8BE5\u9879\u76EE\u4E0B\u5B
archives.project.emp.lose.fee.not.empty=\u4E0D\u826F\u8BB0\u5F55\u8D39\u7528\u635F\u5931\u548C\u5176\u4ED6\u635F\u5931\u4E0D\u53EF\u540C\u65F6\u4E3A\u7A7A
qt.project.change.not.exist=\u4EBA\u5458\u5728\u539F\u9879\u76EE\u4E2D\u5B58\u5728\u5728\u9014\u7684\u670D\u52A1\uFF0C\u8BF7\u5148\u7EC8\u6B62\u540E\uFF0C\u518D\u8FDB\u884C\u5212\u8F6C
project.search.not.exist=\u672A\u627E\u5230\u5BF9\u5E94\u7684\u9879\u76EE\uFF0C\u8BF7\u6838\u5B9E
project.search.not.exist=\u672A\u627E\u5230\u5BF9\u5E94\u7684\u9879\u76EE\u6216\u8005\u9879\u76EE\u5DF2\u505C\u6B62\u5408\u4F5C\uFF0C\u8BF7\u6838\u5B9E
change.strat.month.exit=\u5212\u8F6C\u8D77\u59CB\u6708\u4E0D\u80FD\u4E3A\u7A7A
change.less.month.exit=\u5212\u8F6C\u8D77\u59CB\u6708\u8981\u5C0F\u4E8E\u7B49\u4E8E\u5F53\u524D\u6708
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment