返聘action
This commit is contained in:
parent
f80bb620dd
commit
5d2218b8f0
|
|
@ -9,6 +9,7 @@ import com.engine.salary.entity.taxagent.param.TaxAgentRangeSaveParam;
|
|||
import com.engine.salary.entity.taxagent.po.TaxAgentPO;
|
||||
import com.engine.salary.enums.salaryarchive.SalaryArchiveStatusEnum;
|
||||
import com.engine.salary.enums.salarysob.TargetTypeEnum;
|
||||
import com.engine.salary.mapper.archive.SalaryArchiveMapper;
|
||||
import com.engine.salary.service.SalaryArchiveService;
|
||||
import com.engine.salary.service.TaxAgentManageRangeService;
|
||||
import com.engine.salary.service.TaxAgentService;
|
||||
|
|
@ -16,6 +17,7 @@ import com.engine.salary.service.impl.SalaryArchiveServiceImpl;
|
|||
import com.engine.salary.service.impl.TaxAgentManageRangeServiceImpl;
|
||||
import com.engine.salary.service.impl.TaxAgentServiceImpl;
|
||||
import com.engine.salary.util.SalaryEntityUtil;
|
||||
import com.engine.salary.util.db.MapperProxyFactory;
|
||||
import com.engine.salary.wrapper.SalaryArchiveWrapper;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
|
|
@ -42,6 +44,10 @@ public class RehireAction implements Action {
|
|||
return ServiceUtil.getService(SalaryArchiveServiceImpl.class, user);
|
||||
}
|
||||
|
||||
private SalaryArchiveMapper getSalaryArchiveMapper() {
|
||||
return MapperProxyFactory.getProxy(SalaryArchiveMapper.class);
|
||||
}
|
||||
|
||||
private TaxAgentService getTaxAgentService(User user) {
|
||||
return ServiceUtil.getService(TaxAgentServiceImpl.class, user);
|
||||
}
|
||||
|
|
@ -110,12 +116,12 @@ public class RehireAction implements Action {
|
|||
|
||||
if (salaryArchivePOS.get(0).getRunStatus().equals(SalaryArchiveStatusEnum.STOP_FROM_SUSPEND.getValue())) {
|
||||
// 停薪来自待停薪 1、取消停薪
|
||||
getSalaryArchiveWrapper(user).cancelStop(Collections.singleton(salaryArchivePOS.get(0).getId()));
|
||||
getSalaryArchiveWrapper(user).cancelStop(Collections.singletonList(salaryArchivePOS.get(0).getId()));
|
||||
}
|
||||
if (salaryArchivePOS.get(0).getRunStatus().equals(SalaryArchiveStatusEnum.STOP_FROM_SUSPEND.getValue()) || salaryArchivePOS.get(0).getRunStatus().equals(SalaryArchiveStatusEnum.SUSPEND.getValue())) {
|
||||
// 1、如果不在人员范围内则把他加入义务人的人员范围,2、删除待办
|
||||
addTaxAgentRangeIfNotExist(taxAgentId, employeeId, user);
|
||||
getSalaryArchiveWrapper(user).deleteSuspendTodo(Collections.singleton(salaryArchivePOS.get(0).getId()));
|
||||
getSalaryArchiveWrapper(user).deleteSuspendTodo(Collections.singletonList(salaryArchivePOS.get(0).getId()));
|
||||
}
|
||||
|
||||
// 调薪
|
||||
|
|
@ -132,6 +138,8 @@ public class RehireAction implements Action {
|
|||
|
||||
List errorNotice = (List) map.get("errorNotice");
|
||||
if (CollectionUtils.isNotEmpty(errorNotice)) {
|
||||
// 回滚档案状态
|
||||
getSalaryArchiveMapper().update(salaryArchivePOS.get(0));
|
||||
log.error("调薪存在异常 requestId:{} map:{}", requestInfo.getRequestid(), map);
|
||||
List<Map<String, String>> excelComments = (List<Map<String, String>>) map.get("errorNotice");
|
||||
StringBuilder message = new StringBuilder("");
|
||||
|
|
|
|||
|
|
@ -792,8 +792,7 @@
|
|||
run_status='FIXED',
|
||||
pay_end_date= null
|
||||
</set>
|
||||
WHERE run_status = 'SUSPEND'
|
||||
and id IN
|
||||
WHERE id IN
|
||||
<foreach collection="ids" open="(" item="id" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
|
|
|
|||
Loading…
Reference in New Issue