Merge branch 'feature/加密方法&分页merge' into feature/V3-backItem-1215
# Conflicts: # src/com/engine/salary/service/impl/SalarySendServiceImpl.java
This commit is contained in:
commit
0130b83f00
|
|
@ -0,0 +1,42 @@
|
|||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE configuration
|
||||
PUBLIC "-//mybatis.org//DTD Config 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-config.dtd">
|
||||
<configuration>
|
||||
<settings>
|
||||
<setting name="mapUnderscoreToCamelCase" value="true"></setting>
|
||||
<setting name="jdbcTypeForNull" value="NULL"/>
|
||||
</settings>
|
||||
<plugins>
|
||||
<plugin interceptor="weaver.conn.mybatis.MyBatisCachePlugin"></plugin>
|
||||
</plugins>
|
||||
<environments default="development">
|
||||
<environment id="development">
|
||||
<transactionManager type="JDBC"/>
|
||||
<dataSource type="weaver.conn.mybatis.MyBatisDataSourceFactory">
|
||||
</dataSource>
|
||||
</environment>
|
||||
</environments>
|
||||
<databaseIdProvider type="weaver.conn.mybatis.DatabaseIdProvider">
|
||||
</databaseIdProvider>
|
||||
<mappers>
|
||||
<!--mapper resource="MyBatis/mapper/WorkflowBaseMapper.xml"/-->
|
||||
<!--package name="*.mapper"></package 不可行,Mybatis不支持通配符,这是spring的ant匹配模式提供的-->
|
||||
<package name="weaver.conn.mybatis.mapper"></package><!-- 示例Mapper -->
|
||||
|
||||
<!-- 项目Mapper -->
|
||||
<package name="com.weaver.mapper"></package>
|
||||
<package name="weaver.general.mapper"></package>
|
||||
<package name="weaver.hrm.mapper"></package>
|
||||
<package name="weaver.workflow.mapper"></package>
|
||||
<package name="weaver.interfaces.mapper"></package>
|
||||
<package name="weaver.portal.mapper"></package>
|
||||
<package name="com.api.formmode.mybatis.mapper"></package>
|
||||
<package name="com.cloudstore.dev.api.mapper"></package>
|
||||
<package name="com.engine.integration.mapper"></package>
|
||||
<package name="com.engine.salary.mapper"></package>
|
||||
<package name="com.engine.organization.mapper"></package>
|
||||
<!-- 需要把现在的配置文件都调整到WEB-INF/config/mapper目录下 -->
|
||||
<!-- 在WEB-INF/config/mapper目录下配置的xml文件也不必加入这里的package -->
|
||||
</mappers>
|
||||
</configuration>
|
||||
Binary file not shown.
Binary file not shown.
|
|
@ -0,0 +1,5 @@
|
|||
log=false
|
||||
defaultCloseNonStandard149=true
|
||||
AESEncryptScrect=990EB004A1C862721C1513AE90038C9E
|
||||
version=2.3.2.2212.01
|
||||
openFormulaForcedEditing=false
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
package com.api.salary.web;
|
||||
|
||||
import javax.ws.rs.Path;
|
||||
|
||||
@Path("/bs/hrmsalary/salaryBill/send/range/")
|
||||
public class SalarySendRangeController extends com.engine.salary.web.SalarySendRangeController{
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,82 @@
|
|||
package com.engine.salary.action;
|
||||
|
||||
import com.engine.common.util.ServiceUtil;
|
||||
import com.engine.salary.entity.salaryarchive.param.SalaryArchiveImportHandleParam;
|
||||
import com.engine.salary.enums.salaryarchive.SalaryArchiveImportTypeEnum;
|
||||
import com.engine.salary.enums.salaryarchive.SalaryArchiveListTypeEnum;
|
||||
import com.engine.salary.service.SalaryArchiveExcelService;
|
||||
import com.engine.salary.service.impl.SalaryArchiveExcelServiceImpl;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import weaver.conn.RecordSet;
|
||||
import weaver.general.Util;
|
||||
import weaver.hrm.User;
|
||||
import weaver.interfaces.workflow.action.Action;
|
||||
import weaver.soa.workflow.request.Property;
|
||||
import weaver.soa.workflow.request.RequestInfo;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
@Slf4j
|
||||
public class BatEditSalaryExcelAction implements Action {
|
||||
|
||||
private SalaryArchiveExcelService getSalaryArchiveExcelService(User user) {
|
||||
return ServiceUtil.getService(SalaryArchiveExcelServiceImpl.class, user);
|
||||
}
|
||||
|
||||
private String batSalaryExcelField;
|
||||
|
||||
public String getBatSalaryExcelField() {
|
||||
return batSalaryExcelField;
|
||||
}
|
||||
|
||||
public void setBatSalaryExcelField(String batSalaryExcelField) {
|
||||
this.batSalaryExcelField = batSalaryExcelField;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String execute(RequestInfo requestInfo) {
|
||||
try {
|
||||
|
||||
Property[] properties = requestInfo.getMainTableInfo().getProperty();
|
||||
Map<String, String> fieldMap = Arrays.stream(properties).collect(Collectors.toMap(Property::getName,
|
||||
property -> Util.null2String(property.getValue())));
|
||||
|
||||
String docId = fieldMap.get(batSalaryExcelField);
|
||||
|
||||
RecordSet rs = new RecordSet();
|
||||
String queryImageId = "select imagefileid from docimagefile where docid = ?";
|
||||
rs.executeQuery(queryImageId, docId);
|
||||
String imagefileid = null;
|
||||
if (rs.next()) {
|
||||
imagefileid = rs.getString("imagefileid");
|
||||
}
|
||||
|
||||
SalaryArchiveImportHandleParam param = SalaryArchiveImportHandleParam.builder().imageId(imagefileid)
|
||||
.listType(SalaryArchiveListTypeEnum.FIXED.getValue())
|
||||
.importType(SalaryArchiveImportTypeEnum.SALARYITEMADJUST.getValue())
|
||||
.onlyCheck(false)
|
||||
.isProcess(true)
|
||||
.build();
|
||||
|
||||
Map<String, Object> map = getSalaryArchiveExcelService(new User()).batchImportEbatch(param);
|
||||
int errorCount = (int) map.get("errorCount");
|
||||
if (errorCount > 0) {
|
||||
log.error("批量调薪存在异常 requestId:{} map:{}",requestInfo.getRequestid(), map);
|
||||
// List<Map<String, String>> excelComments = (List<Map<String, String>>) map.get("errorNotice");
|
||||
// StringBuilder message = new StringBuilder();
|
||||
// for (Map<String, String> comments : excelComments) {
|
||||
// message.append(comments.get("message")).append("/n");
|
||||
// }
|
||||
// requestInfo.getRequestManager().setMessage(message.toString());
|
||||
// return FAILURE_AND_CONTINUE;
|
||||
}
|
||||
} catch (Exception e) {
|
||||
log.error("批量调薪异常", e);
|
||||
requestInfo.getRequestManager().setMessage(e.getMessage());
|
||||
return FAILURE_AND_CONTINUE;
|
||||
}
|
||||
return SUCCESS;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,82 @@
|
|||
package com.engine.salary.action;
|
||||
|
||||
import com.engine.common.util.ServiceUtil;
|
||||
import com.engine.salary.entity.salaryarchive.param.SalaryArchiveImportHandleParam;
|
||||
import com.engine.salary.enums.salaryarchive.SalaryArchiveImportTypeEnum;
|
||||
import com.engine.salary.enums.salaryarchive.SalaryArchiveListTypeEnum;
|
||||
import com.engine.salary.service.SalaryArchiveExcelService;
|
||||
import com.engine.salary.service.impl.SalaryArchiveExcelServiceImpl;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import weaver.conn.RecordSet;
|
||||
import weaver.general.Util;
|
||||
import weaver.hrm.User;
|
||||
import weaver.interfaces.workflow.action.Action;
|
||||
import weaver.soa.workflow.request.Property;
|
||||
import weaver.soa.workflow.request.RequestInfo;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
@Slf4j
|
||||
public class CheckBatEditSalaryExcelAction implements Action {
|
||||
|
||||
private SalaryArchiveExcelService getSalaryArchiveExcelService(User user) {
|
||||
return ServiceUtil.getService(SalaryArchiveExcelServiceImpl.class, user);
|
||||
}
|
||||
|
||||
private String batSalaryExcelField;
|
||||
|
||||
public String getBatSalaryExcelField() {
|
||||
return batSalaryExcelField;
|
||||
}
|
||||
|
||||
public void setBatSalaryExcelField(String batSalaryExcelField) {
|
||||
this.batSalaryExcelField = batSalaryExcelField;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String execute(RequestInfo requestInfo) {
|
||||
try {
|
||||
Property[] properties = requestInfo.getMainTableInfo().getProperty();
|
||||
Map<String, String> fieldMap = Arrays.stream(properties).collect(Collectors.toMap(Property::getName,
|
||||
property -> Util.null2String(property.getValue())));
|
||||
|
||||
String docId = fieldMap.get(batSalaryExcelField);
|
||||
|
||||
RecordSet rs = new RecordSet();
|
||||
String queryImageId = "select imagefileid from docimagefile where docid = ?";
|
||||
rs.executeQuery(queryImageId, docId);
|
||||
String imagefileid = null;
|
||||
if (rs.next()) {
|
||||
imagefileid = rs.getString("imagefileid");
|
||||
}
|
||||
|
||||
SalaryArchiveImportHandleParam param = SalaryArchiveImportHandleParam.builder().imageId(imagefileid)
|
||||
.listType(SalaryArchiveListTypeEnum.FIXED.getValue())
|
||||
.importType(SalaryArchiveImportTypeEnum.SALARYITEMADJUST.getValue())
|
||||
.onlyCheck(true)
|
||||
.isProcess(true)
|
||||
.build();
|
||||
|
||||
Map<String, Object> map = getSalaryArchiveExcelService(new User()).batchImportEbatch(param);
|
||||
int errorCount = (int) map.get("errorCount");
|
||||
if (errorCount > 0) {
|
||||
log.error("批量调薪检查存在异常 requestId:{} map:{}",requestInfo.getRequestid(), map);
|
||||
List<Map<String, String>> excelComments = (List<Map<String, String>>) map.get("errorNotice");
|
||||
StringBuilder message = new StringBuilder("excel中");
|
||||
for (Map<String, String> comments : excelComments) {
|
||||
message.append(comments.get("message")).append("\n");
|
||||
}
|
||||
requestInfo.getRequestManager().setMessage(message.toString());
|
||||
return FAILURE_AND_CONTINUE;
|
||||
}
|
||||
} catch (Exception e) {
|
||||
log.error("批量调薪检查异常", e);
|
||||
requestInfo.getRequestManager().setMessage(e.getMessage());
|
||||
return FAILURE_AND_CONTINUE;
|
||||
}
|
||||
return SUCCESS;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,128 @@
|
|||
package com.engine.salary.action;
|
||||
|
||||
import com.engine.common.util.ServiceUtil;
|
||||
import com.engine.salary.entity.salaryarchive.param.SalaryArchiveImportActionParam;
|
||||
import com.engine.salary.util.SalaryEntityUtil;
|
||||
import com.engine.salary.wrapper.SalaryArchiveWrapper;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import weaver.conn.RecordSet;
|
||||
import weaver.general.Util;
|
||||
import weaver.hrm.User;
|
||||
import weaver.interfaces.workflow.action.Action;
|
||||
import weaver.soa.workflow.request.Property;
|
||||
import weaver.soa.workflow.request.RequestInfo;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
@Slf4j
|
||||
public class CheckEditSalaryAction implements Action {
|
||||
|
||||
|
||||
private SalaryArchiveWrapper getSalaryArchiveWrapper(User user) {
|
||||
return ServiceUtil.getService(SalaryArchiveWrapper.class, user);
|
||||
}
|
||||
|
||||
private String tableName;
|
||||
|
||||
|
||||
public String getTableName() {
|
||||
return tableName;
|
||||
}
|
||||
|
||||
public void setTableName(String tableName) {
|
||||
this.tableName = tableName;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String execute(RequestInfo requestInfo) {
|
||||
try {
|
||||
|
||||
Property[] properties = requestInfo.getMainTableInfo().getProperty();
|
||||
Map<String, String> fieldMap = Arrays.stream(properties).collect(Collectors.toMap(Property::getName,
|
||||
property -> Util.null2String(property.getValue())));
|
||||
|
||||
|
||||
RecordSet rs = new RecordSet();
|
||||
|
||||
String queryImageId = "select salaryname,processfield from " + tableName + " where workflowid = ?";
|
||||
rs.executeQuery(queryImageId, requestInfo.getWorkflowid());
|
||||
|
||||
List<SalaryField> list = new ArrayList<>();
|
||||
while (rs.next()) {
|
||||
String processField = rs.getString("processfield");
|
||||
String salaryName = rs.getString("salaryname");
|
||||
String value = fieldMap.get(processField);
|
||||
list.add(new SalaryField(processField, salaryName, value));
|
||||
}
|
||||
List<Map<String, Object>> importData = new ArrayList<>();
|
||||
importData.add(SalaryEntityUtil.convert2Map(list, SalaryField::getSalaryName, SalaryField::getValue));
|
||||
|
||||
SalaryArchiveImportActionParam build = SalaryArchiveImportActionParam.builder()
|
||||
.importDatas(importData)
|
||||
.build();
|
||||
Map<String, Object> map = getSalaryArchiveWrapper(new User()).checkAdjustmentSalaryArchive(build);
|
||||
|
||||
List errorNotice = (List) map.get("errorNotice");
|
||||
if (CollectionUtils.isNotEmpty(errorNotice)) {
|
||||
log.error("调薪检查存在异常 requestId:{} ,参数:{}, map:{}", requestInfo.getRequestid(), build, map);
|
||||
List<Map<String, String>> excelComments = (List<Map<String, String>>) map.get("errorNotice");
|
||||
StringBuilder message = new StringBuilder("");
|
||||
for (Map<String, String> comments : excelComments) {
|
||||
message.append(comments.get("message")).append("\n");
|
||||
}
|
||||
requestInfo.getRequestManager().setMessage(message.toString());
|
||||
return FAILURE_AND_CONTINUE;
|
||||
}
|
||||
} catch (Exception e) {
|
||||
log.error("调薪检查异常", e);
|
||||
requestInfo.getRequestManager().setMessage(e.getMessage());
|
||||
return FAILURE_AND_CONTINUE;
|
||||
}
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
class SalaryField {
|
||||
|
||||
private String processField;
|
||||
|
||||
private String salaryName;
|
||||
|
||||
private String value;
|
||||
|
||||
public String getProcessField() {
|
||||
return processField;
|
||||
}
|
||||
|
||||
public void setProcessField(String processField) {
|
||||
this.processField = processField;
|
||||
}
|
||||
|
||||
public String getSalaryName() {
|
||||
return salaryName;
|
||||
}
|
||||
|
||||
public void setSalaryName(String salaryName) {
|
||||
this.salaryName = salaryName;
|
||||
}
|
||||
|
||||
public String getValue() {
|
||||
return value;
|
||||
}
|
||||
|
||||
public void setValue(String value) {
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
public SalaryField(String processField, String salaryName, String value) {
|
||||
this.processField = processField;
|
||||
this.salaryName = salaryName;
|
||||
this.value = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,128 @@
|
|||
package com.engine.salary.action;
|
||||
|
||||
import com.engine.common.util.ServiceUtil;
|
||||
import com.engine.salary.entity.salaryarchive.param.SalaryArchiveImportActionParam;
|
||||
import com.engine.salary.util.SalaryEntityUtil;
|
||||
import com.engine.salary.wrapper.SalaryArchiveWrapper;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import weaver.conn.RecordSet;
|
||||
import weaver.general.Util;
|
||||
import weaver.hrm.User;
|
||||
import weaver.interfaces.workflow.action.Action;
|
||||
import weaver.soa.workflow.request.Property;
|
||||
import weaver.soa.workflow.request.RequestInfo;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
@Slf4j
|
||||
public class EditSalaryAction implements Action {
|
||||
|
||||
|
||||
private SalaryArchiveWrapper getSalaryArchiveWrapper(User user) {
|
||||
return ServiceUtil.getService(SalaryArchiveWrapper.class, user);
|
||||
}
|
||||
|
||||
private String tableName;
|
||||
|
||||
|
||||
public String getTableName() {
|
||||
return tableName;
|
||||
}
|
||||
|
||||
public void setTableName(String tableName) {
|
||||
this.tableName = tableName;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String execute(RequestInfo requestInfo) {
|
||||
try {
|
||||
|
||||
Property[] properties = requestInfo.getMainTableInfo().getProperty();
|
||||
Map<String, String> fieldMap = Arrays.stream(properties).collect(Collectors.toMap(Property::getName,
|
||||
property -> Util.null2String(property.getValue())));
|
||||
|
||||
|
||||
RecordSet rs = new RecordSet();
|
||||
|
||||
String queryImageId = "select salaryname,processfield from " + tableName + " where workflowid = ?";
|
||||
rs.executeQuery(queryImageId, requestInfo.getWorkflowid());
|
||||
|
||||
List<SalaryField> list = new ArrayList<>();
|
||||
while (rs.next()) {
|
||||
String processField = rs.getString("processfield");
|
||||
String salaryName = rs.getString("salaryname");
|
||||
String value = fieldMap.get(processField);
|
||||
list.add(new SalaryField(processField, salaryName, value));
|
||||
}
|
||||
List<Map<String, Object>> importData = new ArrayList<>();
|
||||
importData.add(SalaryEntityUtil.convert2Map(list, SalaryField::getSalaryName, SalaryField::getValue));
|
||||
|
||||
SalaryArchiveImportActionParam build = SalaryArchiveImportActionParam.builder()
|
||||
.importDatas(importData)
|
||||
.build();
|
||||
Map<String, Object> map = getSalaryArchiveWrapper(new User()).adjustmentSalaryArchive(build);
|
||||
|
||||
List errorNotice = (List) map.get("errorNotice");
|
||||
if (CollectionUtils.isNotEmpty(errorNotice)) {
|
||||
log.error("调薪存在异常 requestId:{} map:{}",requestInfo.getRequestid(), map);
|
||||
// List<Map<String, String>> excelComments = (List<Map<String, String>>) map.get("errorNotice");
|
||||
// StringBuilder message = new StringBuilder("");
|
||||
// for (Map<String, String> comments : excelComments) {
|
||||
// message.append(comments.get("message")).append("\n");
|
||||
// }
|
||||
// requestInfo.getRequestManager().setMessage(message.toString());
|
||||
// return FAILURE_AND_CONTINUE;
|
||||
}
|
||||
} catch (Exception e) {
|
||||
log.error("调薪异常", e);
|
||||
requestInfo.getRequestManager().setMessage(e.getMessage());
|
||||
return FAILURE_AND_CONTINUE;
|
||||
}
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
class SalaryField {
|
||||
|
||||
private String processField;
|
||||
|
||||
private String salaryName;
|
||||
|
||||
private String value;
|
||||
|
||||
public String getProcessField() {
|
||||
return processField;
|
||||
}
|
||||
|
||||
public void setProcessField(String processField) {
|
||||
this.processField = processField;
|
||||
}
|
||||
|
||||
public String getSalaryName() {
|
||||
return salaryName;
|
||||
}
|
||||
|
||||
public void setSalaryName(String salaryName) {
|
||||
this.salaryName = salaryName;
|
||||
}
|
||||
|
||||
public String getValue() {
|
||||
return value;
|
||||
}
|
||||
|
||||
public void setValue(String value) {
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
public SalaryField(String processField, String salaryName, String value) {
|
||||
this.processField = processField;
|
||||
this.salaryName = salaryName;
|
||||
this.value = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,20 @@
|
|||
package com.engine.salary.annotation;
|
||||
|
||||
import java.lang.annotation.ElementType;
|
||||
import java.lang.annotation.Retention;
|
||||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
/**
|
||||
* 加密字段,用于标注需加解密的字段
|
||||
* <p>Copyright: Copyright (c) 2022</p>
|
||||
* <p>Company: 泛微软件</p>
|
||||
*
|
||||
* @author qiantao
|
||||
* @version 1.0
|
||||
**/
|
||||
@Target(ElementType.FIELD)
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
public @interface Encrypt {
|
||||
|
||||
}
|
||||
|
|
@ -1,8 +1,6 @@
|
|||
package com.engine.salary.biz;
|
||||
|
||||
import com.engine.salary.encrypt.datacollection.AddUpDeductionEncrypt;
|
||||
import com.engine.salary.encrypt.datacollection.AddUpDeductionRecordStrDTOEncrypt;
|
||||
import com.engine.salary.encrypt.datacollection.AddUpDeductionStrDTOEncrypt;
|
||||
import com.engine.salary.encrypt.EncryptUtil;
|
||||
import com.engine.salary.entity.datacollection.AddUpDeduction;
|
||||
import com.engine.salary.entity.datacollection.dto.AddUpDeductionDTO;
|
||||
import com.engine.salary.entity.datacollection.dto.AddUpDeductionRecordDTO;
|
||||
|
|
@ -19,6 +17,8 @@ import java.util.stream.Collectors;
|
|||
|
||||
public class AddUpDeductionBiz extends BaseBean {
|
||||
|
||||
private final EncryptUtil encryptUtil = new EncryptUtil();
|
||||
|
||||
|
||||
/**
|
||||
* 关联查询查询列表
|
||||
|
|
@ -31,7 +31,7 @@ public class AddUpDeductionBiz extends BaseBean {
|
|||
try {
|
||||
AddUpDeductionMapper mapper = sqlSession.getMapper(AddUpDeductionMapper.class);
|
||||
List<AddUpDeductionDTO> list = mapper.list(param);
|
||||
AddUpDeductionStrDTOEncrypt.decryptAddUpDeductionList(list);
|
||||
list = encryptUtil.decryptList(list, AddUpDeductionDTO.class);
|
||||
return list;
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
|
|
@ -49,7 +49,7 @@ public class AddUpDeductionBiz extends BaseBean {
|
|||
try {
|
||||
AddUpDeductionMapper mapper = sqlSession.getMapper(AddUpDeductionMapper.class);
|
||||
List<AddUpDeduction> addUpDeductions = mapper.listSome(param);
|
||||
return AddUpDeductionEncrypt.decryptAddUpDeductionList(addUpDeductions);
|
||||
return encryptUtil.decryptList(addUpDeductions, AddUpDeduction.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
@ -67,7 +67,7 @@ public class AddUpDeductionBiz extends BaseBean {
|
|||
try {
|
||||
AddUpDeductionMapper mapper = sqlSession.getMapper(AddUpDeductionMapper.class);
|
||||
AddUpDeduction byId = mapper.getById(id);
|
||||
return AddUpDeductionEncrypt.decryptAddUpDeduction(byId);
|
||||
return encryptUtil.decrypt(byId, AddUpDeduction.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
@ -84,7 +84,7 @@ public class AddUpDeductionBiz extends BaseBean {
|
|||
try {
|
||||
AddUpDeductionMapper mapper = sqlSession.getMapper(AddUpDeductionMapper.class);
|
||||
List<AddUpDeductionRecordDTO> addUpDeductionRecordStrDTOS = mapper.recordList(param);
|
||||
return AddUpDeductionRecordStrDTOEncrypt.decryptAddUpDeductionRecordDTO(addUpDeductionRecordStrDTOS);
|
||||
return encryptUtil.decryptList(addUpDeductionRecordStrDTOS, AddUpDeductionRecordDTO.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
@ -103,7 +103,7 @@ public class AddUpDeductionBiz extends BaseBean {
|
|||
SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession();
|
||||
try {
|
||||
AddUpDeductionMapper mapper = sqlSession.getMapper(AddUpDeductionMapper.class);
|
||||
AddUpDeductionEncrypt.encryptAddUpDeductionList(param);
|
||||
encryptUtil.encryptList(param, AddUpDeduction.class);
|
||||
List<List<AddUpDeduction>> partition = Lists.partition(param, 100);
|
||||
partition.forEach(mapper::insertData);
|
||||
sqlSession.commit();
|
||||
|
|
@ -125,7 +125,7 @@ public class AddUpDeductionBiz extends BaseBean {
|
|||
SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession();
|
||||
try {
|
||||
AddUpDeductionMapper mapper = sqlSession.getMapper(AddUpDeductionMapper.class);
|
||||
AddUpDeductionEncrypt.encryptAddUpDeductionList(param);
|
||||
encryptUtil.encryptList(param, AddUpDeduction.class);
|
||||
List<List<AddUpDeduction>> partition = Lists.partition(param, 100);
|
||||
partition.forEach(mapper::updateData);
|
||||
sqlSession.commit();
|
||||
|
|
@ -135,11 +135,6 @@ public class AddUpDeductionBiz extends BaseBean {
|
|||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 处理导入数据
|
||||
*
|
||||
|
|
|
|||
|
|
@ -1,8 +1,6 @@
|
|||
package com.engine.salary.biz;
|
||||
|
||||
import com.engine.salary.encrypt.datacollection.AddUpSituationDTOEncrypt;
|
||||
import com.engine.salary.encrypt.datacollection.AddUpSituationEncrypt;
|
||||
import com.engine.salary.encrypt.datacollection.AddUpSituationRecordDTOEncrypt;
|
||||
import com.engine.salary.encrypt.EncryptUtil;
|
||||
import com.engine.salary.entity.datacollection.AddUpSituation;
|
||||
import com.engine.salary.entity.datacollection.dto.AddUpSituationDTO;
|
||||
import com.engine.salary.entity.datacollection.dto.AddUpSituationRecordDTO;
|
||||
|
|
@ -19,6 +17,7 @@ import java.util.stream.Collectors;
|
|||
|
||||
public class AddUpSituationBiz extends BaseBean {
|
||||
|
||||
private EncryptUtil encryptUtil = new EncryptUtil();
|
||||
|
||||
/**
|
||||
* 关联查询查询列表
|
||||
|
|
@ -31,7 +30,7 @@ public class AddUpSituationBiz extends BaseBean {
|
|||
try {
|
||||
AddUpSituationMapper mapper = sqlSession.getMapper(AddUpSituationMapper.class);
|
||||
List<AddUpSituationDTO> list = mapper.list(param);
|
||||
return AddUpSituationDTOEncrypt.decryptAddUpSituationDTOList(list);
|
||||
return encryptUtil.decryptList(list, AddUpSituationDTO.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
@ -48,7 +47,7 @@ public class AddUpSituationBiz extends BaseBean {
|
|||
try {
|
||||
AddUpSituationMapper mapper = sqlSession.getMapper(AddUpSituationMapper.class);
|
||||
List<AddUpSituation> addUpSituations = mapper.listSome(param);
|
||||
return AddUpSituationEncrypt.decryptAddUpSituationList(addUpSituations);
|
||||
return encryptUtil.decryptList(addUpSituations, AddUpSituation.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
@ -66,7 +65,7 @@ public class AddUpSituationBiz extends BaseBean {
|
|||
try {
|
||||
AddUpSituationMapper mapper = sqlSession.getMapper(AddUpSituationMapper.class);
|
||||
AddUpSituation byId = mapper.getById(id);
|
||||
return AddUpSituationEncrypt.decryptAddUpSituation(byId);
|
||||
return encryptUtil.decrypt(byId, AddUpSituation.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
@ -83,7 +82,7 @@ public class AddUpSituationBiz extends BaseBean {
|
|||
try {
|
||||
AddUpSituationMapper mapper = sqlSession.getMapper(AddUpSituationMapper.class);
|
||||
List<AddUpSituationRecordDTO> addUpSituationRecordDTOS = mapper.recordList(param);
|
||||
return AddUpSituationRecordDTOEncrypt.decryptAddUpSituationRecordDTOList(addUpSituationRecordDTOS);
|
||||
return encryptUtil.decryptList(addUpSituationRecordDTOS, AddUpSituationRecordDTO.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
@ -102,7 +101,7 @@ public class AddUpSituationBiz extends BaseBean {
|
|||
SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession();
|
||||
try {
|
||||
AddUpSituationMapper mapper = sqlSession.getMapper(AddUpSituationMapper.class);
|
||||
AddUpSituationEncrypt.encryptAddUpSituationList(param);
|
||||
encryptUtil.encryptList(param, AddUpSituation.class);
|
||||
List<List<AddUpSituation>> partition = Lists.partition(param, 50);
|
||||
partition.forEach(mapper::insertData);
|
||||
sqlSession.commit();
|
||||
|
|
@ -124,7 +123,7 @@ public class AddUpSituationBiz extends BaseBean {
|
|||
SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession();
|
||||
try {
|
||||
AddUpSituationMapper mapper = sqlSession.getMapper(AddUpSituationMapper.class);
|
||||
AddUpSituationEncrypt.encryptAddUpSituationList(param);
|
||||
encryptUtil.encryptList(param, AddUpSituation.class);
|
||||
List<List<AddUpSituation>> partition = Lists.partition(param, 50);
|
||||
partition.forEach(mapper::updateData);
|
||||
sqlSession.commit();
|
||||
|
|
|
|||
|
|
@ -1,7 +1,6 @@
|
|||
package com.engine.salary.biz;
|
||||
|
||||
import com.engine.salary.encrypt.datacollection.OtherDeductionPOEncrypt;
|
||||
import com.engine.salary.encrypt.datacollection.OtherDeductionRecordDTOEncrypt;
|
||||
import com.engine.salary.encrypt.EncryptUtil;
|
||||
import com.engine.salary.entity.datacollection.dto.OtherDeductionRecordDTO;
|
||||
import com.engine.salary.entity.datacollection.param.OtherDeductionQueryParam;
|
||||
import com.engine.salary.entity.datacollection.po.OtherDeductionPO;
|
||||
|
|
@ -17,7 +16,7 @@ import java.util.stream.Collectors;
|
|||
|
||||
public class OtherDeductionBiz extends BaseBean {
|
||||
|
||||
|
||||
private EncryptUtil encryptUtil = new EncryptUtil();
|
||||
|
||||
/**
|
||||
* 条件查询
|
||||
|
|
@ -30,7 +29,7 @@ public class OtherDeductionBiz extends BaseBean {
|
|||
try {
|
||||
OtherDeductionMapper mapper = sqlSession.getMapper(OtherDeductionMapper.class);
|
||||
List<OtherDeductionPO> otherDeductionPOS = mapper.listSome(param);
|
||||
return OtherDeductionPOEncrypt.decryptOtherDeductionPOList(otherDeductionPOS);
|
||||
return encryptUtil.decryptList(otherDeductionPOS, OtherDeductionPO.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
@ -48,7 +47,7 @@ public class OtherDeductionBiz extends BaseBean {
|
|||
try {
|
||||
OtherDeductionMapper mapper = sqlSession.getMapper(OtherDeductionMapper.class);
|
||||
OtherDeductionPO byId = mapper.getById(id);
|
||||
return OtherDeductionPOEncrypt.decryptOtherDeductionPO(byId);
|
||||
return encryptUtil.decrypt(byId, OtherDeductionPO.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
@ -65,7 +64,7 @@ public class OtherDeductionBiz extends BaseBean {
|
|||
try {
|
||||
OtherDeductionMapper mapper = sqlSession.getMapper(OtherDeductionMapper.class);
|
||||
List<OtherDeductionRecordDTO> otherDeductionRecordDTOS = mapper.recordList(param);
|
||||
return OtherDeductionRecordDTOEncrypt.decryptOtherDeductionRecordDTOList(otherDeductionRecordDTOS);
|
||||
return encryptUtil.decryptList(otherDeductionRecordDTOS, OtherDeductionRecordDTO.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
@ -84,7 +83,7 @@ public class OtherDeductionBiz extends BaseBean {
|
|||
SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession();
|
||||
try {
|
||||
OtherDeductionMapper mapper = sqlSession.getMapper(OtherDeductionMapper.class);
|
||||
OtherDeductionPOEncrypt.encryptOtherDeductionPOList(param);
|
||||
encryptUtil.encryptList(param, OtherDeductionPO.class);
|
||||
List<List<OtherDeductionPO>> partition = Lists.partition(param, 100);
|
||||
partition.forEach(mapper::insertData);
|
||||
sqlSession.commit();
|
||||
|
|
@ -106,7 +105,7 @@ public class OtherDeductionBiz extends BaseBean {
|
|||
SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession();
|
||||
try {
|
||||
OtherDeductionMapper mapper = sqlSession.getMapper(OtherDeductionMapper.class);
|
||||
OtherDeductionPOEncrypt.encryptOtherDeductionPOList(param);
|
||||
encryptUtil.encryptList(param, OtherDeductionPO.class);
|
||||
List<List<OtherDeductionPO>> partition = Lists.partition(param, 100);
|
||||
partition.forEach(mapper::updateData);
|
||||
sqlSession.commit();
|
||||
|
|
|
|||
|
|
@ -5,21 +5,16 @@ import com.alibaba.fastjson.TypeReference;
|
|||
import com.api.formmode.mybatis.util.SqlProxyHandle;
|
||||
import com.engine.common.util.ServiceUtil;
|
||||
import com.engine.core.impl.Service;
|
||||
import com.engine.salary.cache.SalaryCacheKey;
|
||||
import com.engine.salary.constant.SalaryDefaultTenantConstant;
|
||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
||||
import com.engine.salary.encrypt.siaccount.InsuranceAccountDetailPOEncrypt;
|
||||
import com.engine.salary.encrypt.siaccount.InsuranceAccountDetailTempPOEncrypt;
|
||||
import com.engine.salary.encrypt.siaccount.SiAccountEncrypt;
|
||||
import com.engine.salary.encrypt.sischeme.InsuranceSchemeDetailPOEncrypt;
|
||||
import com.engine.salary.encrypt.EncryptUtil;
|
||||
import com.engine.salary.entity.datacollection.DataCollectionEmployee;
|
||||
import com.engine.salary.entity.salaryacct.dto.SalaryAcctProgressDTO;
|
||||
import com.engine.salary.entity.siaccount.dto.InsuranceAccountViewListDTO;
|
||||
import com.engine.salary.entity.siaccount.dto.SIAccountUtilDTO;
|
||||
import com.engine.salary.entity.siaccount.param.*;
|
||||
import com.engine.salary.entity.siaccount.po.InsuranceAccountBatchPO;
|
||||
import com.engine.salary.entity.siaccount.po.InsuranceAccountDetailPO;
|
||||
import com.engine.salary.entity.siaccount.po.InsuranceAccountDetailTempPO;
|
||||
import com.engine.salary.entity.siaccount.po.InsuranceAccountInspectPO;
|
||||
import com.engine.salary.entity.siaccount.po.*;
|
||||
import com.engine.salary.entity.siarchives.po.*;
|
||||
import com.engine.salary.entity.sicategory.po.ICategoryPO;
|
||||
import com.engine.salary.entity.sischeme.po.InsuranceSchemeDetailPO;
|
||||
|
|
@ -33,8 +28,10 @@ import com.engine.salary.mapper.siarchives.InsuranceBaseInfoMapper;
|
|||
import com.engine.salary.mapper.sicategory.ICategoryMapper;
|
||||
import com.engine.salary.mapper.sischeme.InsuranceSchemeDetailMapper;
|
||||
import com.engine.salary.mapper.taxagent.TaxAgentMapper;
|
||||
import com.engine.salary.service.SalaryAcctProgressService;
|
||||
import com.engine.salary.service.SalaryEmployeeService;
|
||||
import com.engine.salary.service.TaxAgentService;
|
||||
import com.engine.salary.service.impl.SalaryAcctProgressServiceImpl;
|
||||
import com.engine.salary.service.impl.SalaryEmployeeServiceImpl;
|
||||
import com.engine.salary.service.impl.TaxAgentServiceImpl;
|
||||
import com.engine.salary.sys.entity.vo.OrderRuleVO;
|
||||
|
|
@ -53,6 +50,7 @@ import com.wbi.util.StringUtil;
|
|||
import dm.jdbc.util.IdGenerator;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.apache.commons.lang.math.NumberUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import weaver.hrm.User;
|
||||
|
|
@ -76,6 +74,8 @@ public class SIAccountBiz extends Service {
|
|||
|
||||
private SIArchivesBiz siArchivesBiz = new SIArchivesBiz();
|
||||
|
||||
private EncryptUtil encryptUtil = new EncryptUtil();
|
||||
|
||||
private TaxAgentService getTaxAgentService() {
|
||||
return ServiceUtil.getService(TaxAgentServiceImpl.class, user);
|
||||
}
|
||||
|
|
@ -109,12 +109,20 @@ public class SIAccountBiz extends Service {
|
|||
return ServiceUtil.getService(SalarySysConfServiceImpl.class, user);
|
||||
}
|
||||
|
||||
private InsuranceCompensationMapper getInsuranceCompensationMapper() {
|
||||
return MapperProxyFactory.getProxy(InsuranceCompensationMapper.class);
|
||||
}
|
||||
|
||||
private SalaryAcctProgressService getSalaryAcctProgressService(User user) {
|
||||
return (SalaryAcctProgressService) ServiceUtil.getService(SalaryAcctProgressServiceImpl.class, user);
|
||||
}
|
||||
|
||||
public PageInfo<InsuranceAccountBatchPO> listPage(InsuranceAccountBatchParam queryParam) {
|
||||
SalaryPageUtil.start(queryParam.getCurrent(), queryParam.getPageSize());
|
||||
List<InsuranceAccountBatchPO> list = getInsuranceAccountBatchMapper().list(queryParam);
|
||||
list = SiAccountEncrypt.decryptInsuranceAccountBatchList(list);
|
||||
PageInfo<InsuranceAccountBatchPO> pageInfo = new PageInfo<>(list, InsuranceAccountBatchPO.class);
|
||||
return pageInfo;
|
||||
PageInfo<InsuranceAccountBatchPO> page = SalaryPageUtil.buildPage(queryParam.getCurrent(), queryParam.getPageSize(),
|
||||
list, InsuranceAccountBatchPO.class);
|
||||
encryptUtil.decryptList(page.getList(), InsuranceAccountBatchPO.class);
|
||||
return page;
|
||||
}
|
||||
|
||||
public PageInfo<InsuranceAccountDetailPO> listCommonPage(InsuranceAccountDetailParam queryParam) {
|
||||
|
|
@ -132,21 +140,20 @@ public class SIAccountBiz extends Service {
|
|||
OrderRuleVO orderRule = getSalarySysConfService(user).orderRule();
|
||||
queryParam.setOrderRule(orderRule);
|
||||
|
||||
SalaryPageUtil.start(queryParam.getCurrent(), queryParam.getPageSize());
|
||||
List<InsuranceAccountDetailPO> list = getInsuranceAccountDetailMapper().list(queryParam);
|
||||
|
||||
InsuranceAccountDetailPOEncrypt.decryptInsuranceAccountDetailPOList(list);
|
||||
PageInfo<InsuranceAccountDetailPO> pageInfo = new PageInfo<>(list, InsuranceAccountDetailPO.class);
|
||||
PageInfo<InsuranceAccountDetailPO> pageInfo = SalaryPageUtil.buildPage(queryParam.getCurrent(), queryParam.getPageSize(),
|
||||
list, InsuranceAccountDetailPO.class);
|
||||
encryptUtil.decryptList(pageInfo.getList(), InsuranceAccountDetailPO.class);
|
||||
return pageInfo;
|
||||
}
|
||||
|
||||
public String save(boolean flag, AccountParam param, Long employeeId, String currentUserName) {
|
||||
if (flag) {
|
||||
InsuranceAccountBatchPO insuranceAccountBatchPO = getInsuranceAccountBatchMapper().getByBillMonth(param.getBillMonth(), param.getPaymentOrganization());
|
||||
insuranceAccountBatchPO = SiAccountEncrypt.decryptInsuranceAccountBatch(insuranceAccountBatchPO);
|
||||
insuranceAccountBatchPO = encryptUtil.decrypt(insuranceAccountBatchPO, InsuranceAccountBatchPO.class);
|
||||
SalaryAssert.isNull(insuranceAccountBatchPO, SalaryI18nUtil.getI18nLabel(100461, "所属月份存在核算数据"));
|
||||
|
||||
|
||||
InsuranceAccountBatchPO build = InsuranceAccountBatchPO.builder()
|
||||
.paymentOrganization(param.getPaymentOrganization())
|
||||
.accountant(currentUserName)
|
||||
|
|
@ -160,7 +167,7 @@ public class SIAccountBiz extends Service {
|
|||
.deleteType(DeleteTypeEnum.NOT_DELETED.getValue())
|
||||
.paymentOrganization(param.getPaymentOrganization())
|
||||
.build();
|
||||
SiAccountEncrypt.encryptInsuranceAccountBatch(build);
|
||||
encryptUtil.encrypt(build, InsuranceAccountBatchPO.class);
|
||||
getInsuranceAccountBatchMapper().insert(build);
|
||||
// LoggerContext insuranceSchemeContext = new LoggerContext();
|
||||
// insuranceSchemeContext.setTargetId(String.valueOf(build.getId()));
|
||||
|
|
@ -176,7 +183,7 @@ public class SIAccountBiz extends Service {
|
|||
} catch (Exception e) {
|
||||
// 回滚
|
||||
List<InsuranceAccountBatchPO> list = Lists.newArrayList(getInsuranceAccountBatchMapper().getByBillMonth(param.getBillMonth(), param.getPaymentOrganization()));
|
||||
list = SiAccountEncrypt.decryptInsuranceAccountBatchList(list);
|
||||
list = encryptUtil.decryptList(list, InsuranceAccountBatchPO.class);
|
||||
if (CollectionUtils.isNotEmpty(list)) {
|
||||
list.stream().forEach(f -> {
|
||||
getInsuranceAccountBatchMapper().deleteById(f.getId());
|
||||
|
|
@ -197,7 +204,7 @@ public class SIAccountBiz extends Service {
|
|||
// employeeIds = employeeIds.stream().filter(employeeIdsInTaxAgent::contains).collect(Collectors.toList());
|
||||
if (CollectionUtils.isEmpty(employeeIds)) {
|
||||
List<InsuranceAccountBatchPO> list = Lists.newArrayList(getInsuranceAccountBatchMapper().getByBillMonth(param.getBillMonth(), paymentOrganization));
|
||||
SiAccountEncrypt.decryptInsuranceAccountBatchList(list);
|
||||
encryptUtil.decryptList(list, InsuranceAccountBatchPO.class);
|
||||
if (CollectionUtils.isNotEmpty(list)) {
|
||||
list.stream().forEach(f -> {
|
||||
getInsuranceAccountDetailMapper().deleteById(f.getId());
|
||||
|
|
@ -221,10 +228,20 @@ public class SIAccountBiz extends Service {
|
|||
|
||||
public void accounting(AccountParam param, Long employeeId, String tenantKey, String currentUserName) {
|
||||
//薪资核算进度暂未实现
|
||||
// SalaryAcctProgressDTO salaryAcctProgressDTO = salaryAcctProgressService.getProgress(tenantKey + param.getBillMonth(), employeeId, tenantKey);
|
||||
// if (salaryAcctProgressDTO != null && salaryAcctProgressDTO.getProgress().compareTo(BigDecimal.ONE) < 0) {
|
||||
// return;
|
||||
// }
|
||||
SalaryAcctProgressDTO salaryAcctProgressDTO = getSalaryAcctProgressService(user).getProgress(SalaryCacheKey.ACCT_PROGRESS + param.getBillMonth());
|
||||
if (salaryAcctProgressDTO != null && salaryAcctProgressDTO.getProgress().compareTo(BigDecimal.ONE) < 0) {
|
||||
return;
|
||||
}
|
||||
// 初始化进度
|
||||
SalaryAcctProgressDTO initProgress = new SalaryAcctProgressDTO()
|
||||
.setTitle(SalaryI18nUtil.getI18nLabel(97515, "核算中"))
|
||||
.setTitleLabelId(97515L)
|
||||
.setTotalQuantity(NumberUtils.INTEGER_ONE)
|
||||
.setCalculatedQuantity(NumberUtils.INTEGER_ZERO)
|
||||
.setProgress(BigDecimal.ZERO)
|
||||
.setStatus(true)
|
||||
.setMessage(StringUtils.EMPTY);
|
||||
getSalaryAcctProgressService(user).initProgress(SalaryCacheKey.ACCT_PROGRESS + param.getBillMonth(), initProgress);
|
||||
doAccounting(param, employeeId, tenantKey, currentUserName);
|
||||
}
|
||||
|
||||
|
|
@ -290,11 +307,23 @@ public class SIAccountBiz extends Service {
|
|||
}
|
||||
if (CollectionUtils.isEmpty(ids)) {
|
||||
//salaryAcctProgressService.fail(tenantKey + param.getBillMonth(), SalaryI18nUtil.getI18nLabel( 100468, "无需要核算的人员"));
|
||||
getSalaryAcctProgressService(user).fail(SalaryCacheKey.ACCT_PROGRESS + param.getBillMonth(), SalaryI18nUtil.getI18nLabel( 100468, "无需要核算的人员"));
|
||||
return;
|
||||
}
|
||||
SalaryAcctProgressDTO salaryAcctProgressDTO = new SalaryAcctProgressDTO(SalaryI18nUtil.getI18nLabel(97515, "核算中"), 97515L, ids.size(), 0,
|
||||
BigDecimal.ZERO, true, "", true);
|
||||
// SalaryAcctProgressDTO salaryAcctProgressDTO = new SalaryAcctProgressDTO(SalaryI18nUtil.getI18nLabel(97515, "核算中"), 97515L, ids.size(), 0,
|
||||
// BigDecimal.ZERO, true, "", true);
|
||||
//salaryAcctProgressService.initProgress(tenantKey + param.getBillMonth(), salaryAcctProgressDTO, employeeId, tenantKey);
|
||||
|
||||
// 初始化进度
|
||||
SalaryAcctProgressDTO initProgress = new SalaryAcctProgressDTO()
|
||||
.setTitle(SalaryI18nUtil.getI18nLabel(97515, "核算中"))
|
||||
.setTitleLabelId(97515L)
|
||||
.setTotalQuantity(ids.size())
|
||||
.setCalculatedQuantity(NumberUtils.INTEGER_ZERO)
|
||||
.setProgress(BigDecimal.ZERO)
|
||||
.setStatus(true)
|
||||
.setMessage(StringUtils.EMPTY);
|
||||
getSalaryAcctProgressService(user).initProgress(SalaryCacheKey.ACCT_PROGRESS + param.getBillMonth(), initProgress);
|
||||
/* List<List<Long>> partition = Lists.partition(ids, 100);
|
||||
CountDownLatch countDownLatch = new CountDownLatch(partition.size());
|
||||
BlockingDeque<Boolean> results = new LinkedBlockingDeque<>(partition.size());*/
|
||||
|
|
@ -309,11 +338,16 @@ public class SIAccountBiz extends Service {
|
|||
/* if (allSuccess) {*/
|
||||
handleData(ids, param, employeeId, tenantKey, currentUserName);
|
||||
/*}*/
|
||||
MapperProxyFactory.getProxy(SIAccountDetailTempMapper.class).batchDelAccountTempDetails(ids, param.getBillMonth());
|
||||
List<List<Long>> partition = Lists.partition((List<Long>) ids, 100);
|
||||
partition.forEach(part -> {
|
||||
MapperProxyFactory.getProxy(SIAccountDetailTempMapper.class).batchDelByEmpIdsAndMonthAndPayOrg(part, param.getBillMonth(), param.getPaymentOrganization());
|
||||
});
|
||||
|
||||
getSalaryAcctProgressService(user).finish(SalaryCacheKey.ACCT_PROGRESS + param.getBillMonth(), true);
|
||||
} catch (Exception e) {
|
||||
log.error("account run fail", e);
|
||||
List<InsuranceAccountBatchPO> list = Lists.newArrayList(getInsuranceAccountBatchMapper().getByBillMonth(param.getBillMonth(), param.getPaymentOrganization()));
|
||||
list = SiAccountEncrypt.decryptInsuranceAccountBatchList(list);
|
||||
list = encryptUtil.decryptList(list, InsuranceAccountBatchPO.class);
|
||||
if (CollectionUtils.isNotEmpty(list)) {
|
||||
list.stream().forEach(f -> {
|
||||
getInsuranceAccountBatchMapper().deleteById(f.getId());
|
||||
|
|
@ -323,6 +357,7 @@ public class SIAccountBiz extends Service {
|
|||
//薪资核算进度暂未实现
|
||||
//salaryAcctProgressService.del(tenantKey + param.getBillMonth(), employeeId, tenantKey);
|
||||
//logger.error("welfare account error:{}", e.getMessage(), e);
|
||||
getSalaryAcctProgressService(user).fail(SalaryCacheKey.ACCT_PROGRESS + param.getBillMonth(), e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -364,10 +399,17 @@ public class SIAccountBiz extends Service {
|
|||
count++;
|
||||
if (count % 50 == 0 || count >= ids.size()) {
|
||||
//salaryAcctProgressService.getAndAddCalculatedQty(tenantKey + billMonth, count >= ids.size() ? count % 50 : 50);
|
||||
getSalaryAcctProgressService(user).getAndAddCalculatedQty(SalaryCacheKey.ACCT_PROGRESS + billMonth, count >= ids.size() ? count % 50 : 50);
|
||||
}
|
||||
}
|
||||
//临时表入库前先对(可能存在的)历史数据进行删除
|
||||
List<List<Long>> partition = Lists.partition((List<Long>) ids, 100);
|
||||
partition.forEach(part -> {
|
||||
MapperProxyFactory.getProxy(SIAccountDetailTempMapper.class).batchDelByEmpIdsAndMonthAndPayOrg(part, billMonth, paymentOrganization);
|
||||
});
|
||||
//临时表数据入库
|
||||
if (CollectionUtils.isNotEmpty(list)) {
|
||||
InsuranceAccountDetailTempPOEncrypt.encryptInsuranceAccountDetailTempPOList(list);
|
||||
encryptUtil.encryptList(list, InsuranceAccountDetailTempPO.class);
|
||||
List<List<InsuranceAccountDetailTempPO>> lists = splitList(list, 40);
|
||||
lists.forEach(subList -> {
|
||||
MapperProxyFactory.getProxy(SIAccountDetailTempMapper.class).batchSaveAccountTempDetails(subList);
|
||||
|
|
@ -404,15 +446,23 @@ public class SIAccountBiz extends Service {
|
|||
String billMonth = param.getBillMonth();
|
||||
try {
|
||||
List<InsuranceAccountDetailTempPO> list = MapperProxyFactory.getProxy(SIAccountDetailTempMapper.class).getListByEmployeeIdsAndBillMonth(ids, billMonth, param.getPaymentOrganization());
|
||||
InsuranceAccountDetailTempPOEncrypt.decryptInsuranceAccountDetailTempPOList(list);
|
||||
encryptUtil.decryptList(list, InsuranceAccountDetailTempPO.class);
|
||||
Integer paymentStatus = 0;
|
||||
log.info("核算明细临时表 hrsa_bill_detail_temp待处理数量:{}", list.size());
|
||||
List<List<Long>> partitionIds = Lists.partition((List<Long>) ids, 100);
|
||||
log.info("bill_detail入库前删除数据数量:{}", ids.size());
|
||||
for (List<Long> part : partitionIds) {
|
||||
getInsuranceAccountDetailMapper().batchDelAccountDetails(part, billMonth, param.getPaymentOrganization(), paymentStatus);
|
||||
|
||||
//删除账单月份+个税扣缴义务人+人员id下的调差数据
|
||||
getInsuranceCompensationMapper().deleteByBillMonthPayOrgEmpIds(InsuranceCompensationPO.builder()
|
||||
.billMonth(billMonth)
|
||||
.paymentOrganization(param.getPaymentOrganization())
|
||||
.employeeIds(part)
|
||||
.build());
|
||||
}
|
||||
|
||||
//生成bill_detail入库数据
|
||||
List<InsuranceAccountDetailPO> collect = list.stream().map(item -> {
|
||||
InsuranceAccountDetailPO insuranceAccountDetailPO = new InsuranceAccountDetailPO();
|
||||
BeanUtils.copyProperties(item, insuranceAccountDetailPO);
|
||||
|
|
@ -421,7 +471,7 @@ public class SIAccountBiz extends Service {
|
|||
if (CollectionUtils.isNotEmpty(collect)) {
|
||||
log.info("bill_detail入库数据数量:{}", collect.size());
|
||||
batchSaveAccountInspectDetail(collect, billMonth, tenantKey);
|
||||
InsuranceAccountDetailPOEncrypt.encryptInsuranceAccountDetailPOList(collect);
|
||||
encryptUtil.encryptList(collect, InsuranceAccountDetailPO.class);
|
||||
List<List<InsuranceAccountDetailPO>> lists = splitDetailList(collect, 20);
|
||||
lists.forEach(subList -> {
|
||||
getInsuranceAccountDetailMapper().batchSaveAccountDetails(subList);
|
||||
|
|
@ -475,7 +525,7 @@ public class SIAccountBiz extends Service {
|
|||
Boolean inDataRange = SalaryDateUtil.monthInRange(insuranceAccountDetailPO.getBillMonth(), otherPO.getOtherStartTime(), otherPO.getOtherEndTime());
|
||||
if ((Objects.equals(NonPaymentEnum.YES.getValue(), otherPO.getNonPayment()) || otherPO.getNonPayment() == null) && otherPO.getOtherSchemeId() != null && inDataRange) {
|
||||
List<InsuranceSchemeDetailPO> detailPOS = MapperProxyFactory.getProxy(InsuranceSchemeDetailMapper.class).queryListBySchemeId(otherPO.getOtherSchemeId());
|
||||
InsuranceSchemeDetailPOEncrypt.decryptList(detailPOS);
|
||||
encryptUtil.decryptList(detailPOS, InsuranceSchemeDetailPO.class);
|
||||
//方案中包含的需要缴纳其他的个人福利
|
||||
Map<Long, InsuranceSchemeDetailPO> otherPerson = detailPOS.stream()
|
||||
.filter(item -> Objects.equals(IsPaymentEnum.YES.getValue(), item.getIsPayment()) && item.getPaymentScope() == PaymentScopeEnum.SCOPE_PERSON.getValue())
|
||||
|
|
@ -566,7 +616,7 @@ public class SIAccountBiz extends Service {
|
|||
Boolean inDataRange = SalaryDateUtil.monthInRange(insuranceAccountDetailPO.getBillMonth(), fundPO.getFundStartTime(), fundPO.getFundEndTime());
|
||||
if ((NonPaymentEnum.YES.getValue() == fundPO.getNonPayment() || fundPO.getNonPayment() == null) && fundPO.getFundSchemeId() != null && inDataRange) {
|
||||
List<InsuranceSchemeDetailPO> detailPOS = MapperProxyFactory.getProxy(InsuranceSchemeDetailMapper.class).queryListBySchemeId(fundPO.getFundSchemeId());
|
||||
InsuranceSchemeDetailPOEncrypt.decryptList(detailPOS);
|
||||
encryptUtil.decryptList(detailPOS, InsuranceSchemeDetailPO.class);
|
||||
//方案中包含的需要缴纳社保的个人福利
|
||||
Map<Long, InsuranceSchemeDetailPO> fundperson = detailPOS.stream()
|
||||
.filter(item -> IsPaymentEnum.YES.getValue() == item.getIsPayment() && item.getPaymentScope() == PaymentScopeEnum.SCOPE_PERSON.getValue())
|
||||
|
|
@ -657,7 +707,7 @@ public class SIAccountBiz extends Service {
|
|||
Boolean inDataRange = SalaryDateUtil.monthInRange(insuranceAccountDetailPO.getBillMonth(), socialPO.getSocialStartTime(), socialPO.getSocialEndTime());
|
||||
if ((NonPaymentEnum.YES.getValue().equals(socialPO.getNonPayment()) || socialPO.getNonPayment() == null) && socialPO.getSocialSchemeId() != null && inDataRange) {
|
||||
List<InsuranceSchemeDetailPO> detailPOS = MapperProxyFactory.getProxy(InsuranceSchemeDetailMapper.class).queryListBySchemeId(socialPO.getSocialSchemeId());
|
||||
InsuranceSchemeDetailPOEncrypt.decryptList(detailPOS);
|
||||
encryptUtil.decryptList(detailPOS, InsuranceSchemeDetailPO.class);
|
||||
//方案中包含的需要缴纳社保的个人福利
|
||||
Map<Long, InsuranceSchemeDetailPO> schemeperson = detailPOS.stream()
|
||||
.filter(item -> Objects.equals(IsPaymentEnum.YES.getValue(), item.getIsPayment()) && Objects.equals(item.getPaymentScope(), PaymentScopeEnum.SCOPE_PERSON.getValue()))
|
||||
|
|
@ -817,7 +867,7 @@ public class SIAccountBiz extends Service {
|
|||
BigDecimal socialTemp = new BigDecimal("0");
|
||||
BigDecimal fundTemp = new BigDecimal("0");
|
||||
BigDecimal otherTemp = new BigDecimal("0");
|
||||
InsuranceAccountDetailPOEncrypt.decryptInsuranceAccountDetailPOList(v);
|
||||
encryptUtil.decryptList(v, InsuranceAccountDetailPO.class);
|
||||
boolean socialPersonFlag = false;
|
||||
boolean fundPersonFlag = false;
|
||||
boolean otherPersonFlag = false;
|
||||
|
|
@ -853,7 +903,7 @@ public class SIAccountBiz extends Service {
|
|||
}
|
||||
}
|
||||
InsuranceAccountBatchPO insuranceAccountBatchPO = getInsuranceAccountBatchMapper().getByBillMonth(billMonth, param.getPaymentOrganization());
|
||||
SiAccountEncrypt.decryptInsuranceAccountBatch(insuranceAccountBatchPO);
|
||||
encryptUtil.decrypt(insuranceAccountBatchPO, InsuranceAccountBatchPO.class);
|
||||
|
||||
DataCollectionEmployee simpleEmployee = MapperProxyFactory.getProxy(EmployMapper.class).getEmployeeById(employeeId);
|
||||
insuranceAccountBatchPO.setAccountant(currentUserName);
|
||||
|
|
@ -864,7 +914,7 @@ public class SIAccountBiz extends Service {
|
|||
insuranceAccountBatchPO.setFundPay(fundSum.toPlainString());
|
||||
insuranceAccountBatchPO.setOtherNum(otherAccountPerson);
|
||||
insuranceAccountBatchPO.setOtherPay(otherSum.toPlainString());
|
||||
SiAccountEncrypt.encryptInsuranceAccountBatch(insuranceAccountBatchPO);
|
||||
encryptUtil.encrypt(insuranceAccountBatchPO, InsuranceAccountBatchPO.class);
|
||||
getInsuranceAccountBatchMapper().updateById(insuranceAccountBatchPO);
|
||||
// LoggerContext insuranceSchemeContext = new LoggerContext();
|
||||
// insuranceSchemeContext.setTargetId(String.valueOf(insuranceAccountBatchPO.getId()));
|
||||
|
|
@ -896,13 +946,16 @@ public class SIAccountBiz extends Service {
|
|||
|
||||
public void delete(AccountParam param, Long employeeId) {
|
||||
InsuranceAccountBatchPO insuranceAccountBatchPO = getInsuranceAccountBatchMapper().getByBillMonth(param.getBillMonth(), param.getPaymentOrganization());
|
||||
SiAccountEncrypt.decryptInsuranceAccountBatch(insuranceAccountBatchPO);
|
||||
encryptUtil.decrypt(insuranceAccountBatchPO, InsuranceAccountBatchPO.class);
|
||||
SalaryAssert.notNull(insuranceAccountBatchPO, SalaryI18nUtil.getI18nLabel(84026, "参数错误"));
|
||||
// if(param.getPaymentOrganization()==null){
|
||||
// throw new SalaryRunTimeException("个税扣缴义务人为空");
|
||||
// }
|
||||
getInsuranceAccountBatchMapper().deleteById(insuranceAccountBatchPO.getId());
|
||||
getInsuranceAccountDetailMapper().batchDeleteNotFile(param.getBillMonth(), param.getPaymentOrganization());
|
||||
|
||||
//删除账单月份+个税扣缴义务人下的调差数据
|
||||
getInsuranceCompensationMapper().deleteByBillMonthAndPayOrg(param.getBillMonth(), param.getPaymentOrganization());
|
||||
// LoggerContext insuranceSchemeContext = new LoggerContext();
|
||||
// insuranceSchemeContext.setTargetId(String.valueOf(insuranceAccountBatchPO.getId()));
|
||||
// insuranceSchemeContext.setTargetName(insuranceAccountBatchPO.getBillMonth());
|
||||
|
|
@ -1051,7 +1104,7 @@ public class SIAccountBiz extends Service {
|
|||
insuranceAccountDetailPO.setOtherPaymentBaseString(otherPO.getOtherPaymentBaseString());
|
||||
if ((Objects.equals(NonPaymentEnum.YES.getValue(), otherPO.getNonPayment()) || otherPO.getNonPayment() == null) && otherPO.getOtherSchemeId() != null) {
|
||||
List<InsuranceSchemeDetailPO> detailPOS = MapperProxyFactory.getProxy(InsuranceSchemeDetailMapper.class).queryListBySchemeId(otherPO.getOtherSchemeId());
|
||||
InsuranceSchemeDetailPOEncrypt.decryptList(detailPOS);
|
||||
encryptUtil.decryptList(detailPOS, InsuranceSchemeDetailPO.class);
|
||||
//方案中包含的需要缴纳其他的个人福利
|
||||
Map<Long, InsuranceSchemeDetailPO> otherPerson = detailPOS.stream()
|
||||
.filter(item -> Objects.equals(IsPaymentEnum.YES.getValue(), item.getIsPayment()) && item.getPaymentScope() == PaymentScopeEnum.SCOPE_PERSON.getValue())
|
||||
|
|
@ -1141,7 +1194,7 @@ public class SIAccountBiz extends Service {
|
|||
insuranceAccountDetailPO.setFundPaymentBaseString(fundPO.getFundPaymentBaseString());
|
||||
if ((NonPaymentEnum.YES.getValue() == fundPO.getNonPayment() || fundPO.getNonPayment() == null) && fundPO.getFundSchemeId() != null) {
|
||||
List<InsuranceSchemeDetailPO> detailPOS = MapperProxyFactory.getProxy(InsuranceSchemeDetailMapper.class).queryListBySchemeId(fundPO.getFundSchemeId());
|
||||
InsuranceSchemeDetailPOEncrypt.decryptList(detailPOS);
|
||||
encryptUtil.decryptList(detailPOS, InsuranceSchemeDetailPO.class);
|
||||
//方案中包含的需要缴纳社保的个人福利
|
||||
Map<Long, InsuranceSchemeDetailPO> fundperson = detailPOS.stream()
|
||||
.filter(item -> IsPaymentEnum.YES.getValue() == item.getIsPayment() && item.getPaymentScope() == PaymentScopeEnum.SCOPE_PERSON.getValue())
|
||||
|
|
@ -1229,7 +1282,7 @@ public class SIAccountBiz extends Service {
|
|||
insuranceAccountDetailPO.setSocialPaymentBaseString(socialPO.getSocialPaymentBaseString());
|
||||
if ((NonPaymentEnum.YES.getValue() == socialPO.getNonPayment() || socialPO.getNonPayment() == null) && socialPO.getSocialSchemeId() != null) {
|
||||
List<InsuranceSchemeDetailPO> detailPOS = MapperProxyFactory.getProxy(InsuranceSchemeDetailMapper.class).queryListBySchemeId(socialPO.getSocialSchemeId());
|
||||
InsuranceSchemeDetailPOEncrypt.decryptList(detailPOS);
|
||||
encryptUtil.decryptList(detailPOS, InsuranceSchemeDetailPO.class);
|
||||
//方案中包含的需要缴纳社保的个人福利
|
||||
Map<Long, InsuranceSchemeDetailPO> schemeperson = detailPOS.stream()
|
||||
.filter(item -> IsPaymentEnum.YES.getValue() == item.getIsPayment() && item.getPaymentScope() == PaymentScopeEnum.SCOPE_PERSON.getValue())
|
||||
|
|
@ -1317,7 +1370,7 @@ public class SIAccountBiz extends Service {
|
|||
insuranceAccountDetailPO.setSocialPaymentBaseString(socialPO.getSocialPaymentBaseString());
|
||||
if ((NonPaymentEnum.YES.getValue() == socialPO.getNonPayment() || socialPO.getNonPayment() == null) && socialPO.getSocialSchemeId() != null) {
|
||||
List<InsuranceSchemeDetailPO> detailPOS = MapperProxyFactory.getProxy(InsuranceSchemeDetailMapper.class).queryListBySchemeId(socialPO.getSocialSchemeId());
|
||||
InsuranceSchemeDetailPOEncrypt.decryptList(detailPOS);
|
||||
encryptUtil.decryptList(detailPOS, InsuranceSchemeDetailPO.class);
|
||||
//方案中包含的需要缴纳社保的个人福利
|
||||
Map<Long, InsuranceSchemeDetailPO> schemeperson = detailPOS.stream()
|
||||
.filter(item -> IsPaymentEnum.YES.getValue() == item.getIsPayment() && item.getPaymentScope() == PaymentScopeEnum.SCOPE_PERSON.getValue())
|
||||
|
|
@ -1417,7 +1470,7 @@ public class SIAccountBiz extends Service {
|
|||
}
|
||||
batchSaveAccountInspectDetail(pos, billMonth, tenantKey);
|
||||
getInsuranceAccountDetailMapper().batchDelSupplementAccountDetails(pos);
|
||||
InsuranceAccountDetailPOEncrypt.encryptInsuranceAccountDetailPOList(pos);
|
||||
encryptUtil.encryptList(pos, InsuranceAccountDetailPO.class);
|
||||
List<List<InsuranceAccountDetailPO>> lists = splitDetailList(pos, 20);
|
||||
lists.forEach(subList -> {
|
||||
getInsuranceAccountDetailMapper().batchSaveAccountDetails(subList);
|
||||
|
|
@ -1495,11 +1548,11 @@ public class SIAccountBiz extends Service {
|
|||
// SalaryAssert.isEmpty(insuranceAccountInspectPOS, SalaryI18nUtil.getI18nLabel( 100500, "当前核算月存在核算异常数据"));
|
||||
//开始归档数据
|
||||
InsuranceAccountBatchPO insuranceAccountBatchPO = getInsuranceAccountBatchMapper().getByBillStatus(billMonth, BillStatusEnum.NOT_ARCHIVED.getValue(), paymentOrganization);
|
||||
SiAccountEncrypt.decryptInsuranceAccountBatch(insuranceAccountBatchPO);
|
||||
encryptUtil.decrypt(insuranceAccountBatchPO, InsuranceAccountBatchPO.class);
|
||||
SalaryAssert.notNull(insuranceAccountBatchPO, SalaryI18nUtil.getI18nLabel(100503, "月份账单不存在"));
|
||||
SalaryAssert.isFalse(insuranceAccountBatchPO.getBillStatus() == BillStatusEnum.ARCHIVED.getValue(), SalaryI18nUtil.getI18nLabel(100504, "月份账单已归档"));
|
||||
SalaryAssert.isFalse(Objects.equals(insuranceAccountBatchPO.getBillStatus(), BillStatusEnum.ARCHIVED.getValue()), SalaryI18nUtil.getI18nLabel(100504, "月份账单已归档"));
|
||||
insuranceAccountBatchPO.setBillStatus(BillStatusEnum.ARCHIVED.getValue());
|
||||
SiAccountEncrypt.encryptInsuranceAccountBatch(insuranceAccountBatchPO);
|
||||
encryptUtil.encrypt(insuranceAccountBatchPO, InsuranceAccountBatchPO.class);
|
||||
getInsuranceAccountBatchMapper().updateById(insuranceAccountBatchPO);
|
||||
//日志记录
|
||||
// LoggerContext insuranceSchemeContext = new LoggerContext();
|
||||
|
|
@ -1560,7 +1613,7 @@ public class SIAccountBiz extends Service {
|
|||
|
||||
// SalaryPageUtil.start(queryParam.getCurrent(),queryParam.getPageSize());
|
||||
List<InsuranceAccountDetailPO> insuranceAccountDetailPOS = getInsuranceAccountDetailMapper().selectList(queryParam.getBillMonth(), StringUtil.isBlank(queryParam.getPaymentOrganization()) ? null : Long.valueOf(queryParam.getPaymentOrganization()));
|
||||
InsuranceAccountDetailPOEncrypt.decryptInsuranceAccountDetailPOList(insuranceAccountDetailPOS);
|
||||
encryptUtil.decryptList(insuranceAccountDetailPOS, InsuranceAccountDetailPO.class);
|
||||
|
||||
//获取扣缴义务人信息
|
||||
List<TaxAgentPO> paymentList = MapperProxyFactory.getProxy(TaxAgentMapper.class).listAll();
|
||||
|
|
|
|||
|
|
@ -14,10 +14,7 @@ import com.cloudstore.eccom.pc.table.WeaTableColumn;
|
|||
import com.cloudstore.eccom.result.WeaResultMsg;
|
||||
import com.engine.salary.constant.SalaryDefaultTenantConstant;
|
||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
||||
import com.engine.salary.encrypt.siarchives.InsuranceArchivesFundSchemePOEncrypt;
|
||||
import com.engine.salary.encrypt.siarchives.InsuranceArchivesOtherSchemePOEncrypt;
|
||||
import com.engine.salary.encrypt.siarchives.InsuranceArchivesSocialSchemePOEncrypt;
|
||||
import com.engine.salary.encrypt.sischeme.InsuranceSchemeDetailPOEncrypt;
|
||||
import com.engine.salary.encrypt.EncryptUtil;
|
||||
import com.engine.salary.entity.datacollection.DataCollectionEmployee;
|
||||
import com.engine.salary.entity.siarchives.bo.InsuranceArchivesBO;
|
||||
import com.engine.salary.entity.siarchives.dto.InsuranceArchivesBaseDTO;
|
||||
|
|
@ -81,6 +78,8 @@ public class SIArchivesBiz {
|
|||
Boolean needAuth;
|
||||
Collection<TaxAgentPO> taxAgentPOS;
|
||||
|
||||
private EncryptUtil encryptUtil = new EncryptUtil();
|
||||
|
||||
private TaxAgentMapper getTaxAgentMapper() {
|
||||
return MapperProxyFactory.getProxy(TaxAgentMapper.class);
|
||||
}
|
||||
|
|
@ -378,7 +377,7 @@ public class SIArchivesBiz {
|
|||
try {
|
||||
InsuranceSchemeDetailMapper insuranceSchemeDetailMapper = sqlSession.getMapper(InsuranceSchemeDetailMapper.class);
|
||||
List<InsuranceSchemeDetailPO> insuranceSchemeDetailPOS = insuranceSchemeDetailMapper.queryListByPrimaryIdIsPayment(schemeId, IsPaymentEnum.YES.getValue(), welfareType);
|
||||
InsuranceSchemeDetailPOEncrypt.decryptList(insuranceSchemeDetailPOS);
|
||||
encryptUtil.decryptList(insuranceSchemeDetailPOS, InsuranceSchemeDetailPO.class);
|
||||
return insuranceSchemeDetailPOS;
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
|
|
@ -417,7 +416,7 @@ public class SIArchivesBiz {
|
|||
.employeeId(employeeId)
|
||||
.paymentOrganization(paymentOrganization)
|
||||
.build());
|
||||
InsuranceArchivesOtherSchemePOEncrypt.decryptList(otherList);
|
||||
encryptUtil.decryptList(otherList, InsuranceArchivesOtherSchemePO.class);
|
||||
InsuranceArchivesOtherSchemePO insuranceArchivesOtherSchemePO = otherList.size() != 0 ? otherList.get(0) : null;
|
||||
InsuranceArchivesOtherSchemeDTO data = InsuranceArchivesBO.convertOtherPOtoDTO(insuranceArchivesOtherSchemePO, employeeId);
|
||||
if (insuranceArchivesOtherSchemePO == null) {
|
||||
|
|
@ -448,7 +447,7 @@ public class SIArchivesBiz {
|
|||
.employeeId(employeeId)
|
||||
.paymentOrganization(paymentOrganization)
|
||||
.build());
|
||||
InsuranceArchivesFundSchemePOEncrypt.decryptList(fundList);
|
||||
encryptUtil.decryptList(fundList, InsuranceArchivesFundSchemePO.class);
|
||||
InsuranceArchivesFundSchemePO insuranceArchivesFundSchemePO = fundList.size() != 0 ? fundList.get(0) : null;
|
||||
InsuranceArchivesFundSchemeDTO data = InsuranceArchivesBO.convertFundPOtoDTO(insuranceArchivesFundSchemePO, employeeId);
|
||||
if (insuranceArchivesFundSchemePO == null) {
|
||||
|
|
@ -494,7 +493,7 @@ public class SIArchivesBiz {
|
|||
.employeeId(employeeId)
|
||||
.paymentOrganization(paymentOrganization)
|
||||
.build());
|
||||
InsuranceArchivesSocialSchemePOEncrypt.decryptList(socialList);
|
||||
encryptUtil.decryptList(socialList, InsuranceArchivesSocialSchemePO.class);
|
||||
return socialList.size() != 0 ? socialList.get(0) : null;
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
|
|
@ -670,7 +669,7 @@ public class SIArchivesBiz {
|
|||
if (!checkWelBaseLimit(updateOtherInfo.getOtherSchemeId(),updateOtherInfo.getOtherPaymentBaseString())) {
|
||||
throw new SalaryRunTimeException("其他福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!");
|
||||
}
|
||||
InsuranceArchivesOtherSchemePOEncrypt.encryptItem(updateOtherInfo);
|
||||
encryptUtil.encrypt(updateOtherInfo, InsuranceArchivesOtherSchemePO.class);
|
||||
otherSchemeMapper.updateById(updateOtherInfo);
|
||||
sqlSession.commit();
|
||||
} else {
|
||||
|
|
@ -722,7 +721,7 @@ public class SIArchivesBiz {
|
|||
if (!checkWelBaseLimit(updateFundInfo.getFundSchemeId(),updateFundInfo.getFundPaymentBaseString())) {
|
||||
throw new SalaryRunTimeException("公积金福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!");
|
||||
}
|
||||
InsuranceArchivesFundSchemePOEncrypt.encryptItem(updateFundInfo);
|
||||
encryptUtil.encrypt(updateFundInfo, InsuranceArchivesFundSchemePO.class);
|
||||
fundSchemeMapper.updateById(updateFundInfo);
|
||||
|
||||
sqlSession.commit();
|
||||
|
|
@ -783,7 +782,7 @@ public class SIArchivesBiz {
|
|||
if (!checkWelBaseLimit(updateSocialInfo.getSocialSchemeId(),updateSocialInfo.getSocialPaymentBaseString())) {
|
||||
throw new SalaryRunTimeException("社保福利明细中的基数更新内容不符合相关基数上下限要求,请检查后重试!");
|
||||
}
|
||||
InsuranceArchivesSocialSchemePOEncrypt.encryptItem(updateSocialInfo);
|
||||
encryptUtil.encrypt(updateSocialInfo, InsuranceArchivesSocialSchemePO.class);
|
||||
socialSchemeMapper.updateById(updateSocialInfo);
|
||||
|
||||
sqlSession.commit();
|
||||
|
|
@ -837,7 +836,7 @@ public class SIArchivesBiz {
|
|||
if (isPaymentList.size() > 0) {
|
||||
InsuranceSchemeDetailPO insuranceSchemeDetailPO = isPaymentList.get(0);
|
||||
|
||||
InsuranceSchemeDetailPOEncrypt.decryptItem(insuranceSchemeDetailPO);
|
||||
encryptUtil.decrypt(insuranceSchemeDetailPO, InsuranceSchemeDetailPO.class);
|
||||
String lowerLimit = "0.000".equals(insuranceSchemeDetailPO.getLowerLimit()) ? null : insuranceSchemeDetailPO.getLowerLimit();
|
||||
String upperLimit = "0.000".equals(insuranceSchemeDetailPO.getUpperLimit()) ? null : insuranceSchemeDetailPO.getUpperLimit();
|
||||
if (lowerLimit != null && lowerLimit.length() > 0 && Double.parseDouble(entry.getValue()) < Double.parseDouble(lowerLimit)) {
|
||||
|
|
@ -884,6 +883,11 @@ public class SIArchivesBiz {
|
|||
request.setDepartmentIds(Arrays.stream(param.getDepartmentIdsStr().split(",")).map(BigDecimal::new).collect(Collectors.toList()));
|
||||
}
|
||||
|
||||
if (StringUtils.isNotBlank(param.getSubcompanyIdsStr())) {
|
||||
request.setSubcompanyIds(Arrays.stream(param.getSubcompanyIdsStr().split(",")).map(BigDecimal::new).collect(Collectors.toList()));
|
||||
}
|
||||
|
||||
|
||||
if (StringUtils.isNotBlank(param.getPositionsStr())) {
|
||||
request.setPositions(Arrays.stream(param.getPositionsStr().split(",")).map(BigDecimal::new).collect(Collectors.toList()));
|
||||
}
|
||||
|
|
@ -962,14 +966,13 @@ public class SIArchivesBiz {
|
|||
pageInfo.setTotal(page.size());
|
||||
pageInfo.setList(SalaryPageUtil.subList(pageInfo.getPageNum(), pageInfo.getPageSize(), page));
|
||||
} else {
|
||||
SalaryPageUtil.start(param.getCurrent(), param.getPageSize());
|
||||
// List<InsuranceArchivesEmployeePO> page = socialSchemeMapper.listPageEmployeePOS(param);
|
||||
log.info("从数据库获取档案列表数据开始");
|
||||
sw.start("获取档案列表数据");
|
||||
page = socialSchemeMapper.queryEmployeeList(param);
|
||||
sw.stop();
|
||||
log.info("从数据库获取档案列表数据完成!");
|
||||
pageInfo = new PageInfo<>(page, InsuranceArchivesEmployeePO.class);
|
||||
pageInfo = SalaryPageUtil.buildPage(param.getCurrent(), param.getPageSize(),
|
||||
page, InsuranceArchivesEmployeePO.class);
|
||||
}
|
||||
List<Map<String, Object>> records = null;
|
||||
log.info("buildTableData方法处理福利档案列表数据开始");
|
||||
|
|
@ -1072,13 +1075,13 @@ public class SIArchivesBiz {
|
|||
|
||||
insuranceArchivesEmployeePOS.forEach(item -> {
|
||||
List<InsuranceArchivesSocialSchemePO> socialList = socialSchemeMapper.getSocialByEmployeeId(Collections.singletonList(item.getEmployeeId()));
|
||||
InsuranceArchivesSocialSchemePOEncrypt.decryptList(socialList);
|
||||
encryptUtil.decryptList(socialList, InsuranceArchivesSocialSchemePO.class);
|
||||
// InsuranceArchivesSocialSchemePO socialItem = socialList.size() != 0 ? socialList.get(0) : null;
|
||||
List<InsuranceArchivesFundSchemePO> fundList = fundSchemeMapper.getFundByEmployeeId(Collections.singletonList(item.getEmployeeId()));
|
||||
InsuranceArchivesFundSchemePOEncrypt.decryptList(fundList);
|
||||
encryptUtil.decryptList(fundList, InsuranceArchivesFundSchemePO.class);
|
||||
// InsuranceArchivesFundSchemePO fundItem = fundList.size() != 0 ? fundList.get(0) : null;
|
||||
List<InsuranceArchivesOtherSchemePO> otherList = otherSchemeMapper.getOtherByEmployeeId(Collections.singletonList(item.getEmployeeId()));
|
||||
InsuranceArchivesOtherSchemePOEncrypt.decryptList(otherList);
|
||||
encryptUtil.decryptList(otherList, InsuranceArchivesOtherSchemePO.class);
|
||||
// InsuranceArchivesOtherSchemePO otherItem = otherList.size() != 0 ? otherList.get(0) : null;
|
||||
if (socialList.size() > 0) {
|
||||
for (InsuranceArchivesSocialSchemePO socialSchemePO : socialList) {
|
||||
|
|
@ -1184,13 +1187,13 @@ public class SIArchivesBiz {
|
|||
InsuranceSchemeMapper insuranceSchemeMapper = sqlSession.getMapper(InsuranceSchemeMapper.class);
|
||||
|
||||
// List<Long> employeeIds = insuranceArchivesEmployeePOS.stream().map(InsuranceArchivesEmployeePO::getEmployeeId).collect(Collectors.toList());
|
||||
Map<Long, InsuranceArchivesSocialSchemePO> socialSchemePOMap = InsuranceArchivesSocialSchemePOEncrypt.decryptList(this.getSocialByEmployeeIdAndPayOrg(insuranceArchivesEmployeePOS))
|
||||
Map<Long, InsuranceArchivesSocialSchemePO> socialSchemePOMap = encryptUtil.decryptList(this.getSocialByEmployeeIdAndPayOrg(insuranceArchivesEmployeePOS), InsuranceArchivesSocialSchemePO.class)
|
||||
.stream().collect(Collectors.toMap(InsuranceArchivesSocialSchemePO::getId, Function.identity()));
|
||||
|
||||
Map<Long, InsuranceArchivesFundSchemePO> fundSchemePOMap = InsuranceArchivesFundSchemePOEncrypt.decryptList(this.getFundByEmployeeIdAndPayOrg(insuranceArchivesEmployeePOS))
|
||||
Map<Long, InsuranceArchivesFundSchemePO> fundSchemePOMap = encryptUtil.decryptList(this.getFundByEmployeeIdAndPayOrg(insuranceArchivesEmployeePOS), InsuranceArchivesFundSchemePO.class)
|
||||
.stream().collect(Collectors.toMap(InsuranceArchivesFundSchemePO::getId, Function.identity()));
|
||||
List<InsuranceArchivesOtherSchemePO> otherByEmployeeList = this.getOtherByEmployeeIdAndPayOrg(insuranceArchivesEmployeePOS);
|
||||
InsuranceArchivesOtherSchemePOEncrypt.decryptList(otherByEmployeeList);
|
||||
encryptUtil.decryptList(otherByEmployeeList, InsuranceArchivesOtherSchemePO.class);
|
||||
Map<Long, InsuranceArchivesOtherSchemePO> otherSchemePOMap = otherByEmployeeList
|
||||
.stream().collect(Collectors.toMap(InsuranceArchivesOtherSchemePO::getId, Function.identity()));
|
||||
insuranceArchivesEmployeePOS.forEach(item -> {
|
||||
|
|
@ -1437,16 +1440,16 @@ public class SIArchivesBiz {
|
|||
Map<Long, InsuranceArchivesSocialSchemePO> socialMap = new HashMap<>();
|
||||
Map<Long, InsuranceArchivesFundSchemePO> funMap = new HashMap<>();
|
||||
Map<Long, InsuranceArchivesOtherSchemePO> otherMap = new HashMap<>();
|
||||
List<InsuranceArchivesSocialSchemePO> socialPOS = InsuranceArchivesSocialSchemePOEncrypt.decryptList(this.getSocialByEmployeeIdAndPayOrg(insuranceArchivesEmployeePOS));
|
||||
List<InsuranceArchivesSocialSchemePO> socialPOS = encryptUtil.decryptList(this.getSocialByEmployeeIdAndPayOrg(insuranceArchivesEmployeePOS), InsuranceArchivesSocialSchemePO.class);
|
||||
if (CollectionUtils.isNotEmpty(socialPOS)) {
|
||||
socialMap = socialPOS.stream().collect(Collectors.toMap(InsuranceArchivesSocialSchemePO::getEmployeeId, Function.identity()));
|
||||
}
|
||||
List<InsuranceArchivesFundSchemePO> fundPOS = InsuranceArchivesFundSchemePOEncrypt.decryptList(this.getFundByEmployeeIdAndPayOrg(insuranceArchivesEmployeePOS));
|
||||
List<InsuranceArchivesFundSchemePO> fundPOS = encryptUtil.decryptList(this.getFundByEmployeeIdAndPayOrg(insuranceArchivesEmployeePOS), InsuranceArchivesFundSchemePO.class);
|
||||
if (CollectionUtils.isNotEmpty(fundPOS)) {
|
||||
funMap = fundPOS.stream().collect(Collectors.toMap(InsuranceArchivesFundSchemePO::getEmployeeId, Function.identity()));
|
||||
}
|
||||
List<InsuranceArchivesOtherSchemePO> otherPOS = this.getOtherByEmployeeIdAndPayOrg(insuranceArchivesEmployeePOS);
|
||||
InsuranceArchivesOtherSchemePOEncrypt.decryptList(otherPOS);
|
||||
encryptUtil.decryptList(otherPOS, InsuranceArchivesOtherSchemePO.class);
|
||||
if (CollectionUtils.isNotEmpty(otherPOS)) {
|
||||
otherMap = otherPOS.stream().collect(Collectors.toMap(InsuranceArchivesOtherSchemePO::getEmployeeId, Function.identity()));
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ package com.engine.salary.biz;
|
|||
import com.api.formmode.mybatis.util.SqlProxyHandle;
|
||||
import com.engine.salary.constant.SalaryDefaultTenantConstant;
|
||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
||||
import com.engine.salary.encrypt.sischeme.InsuranceSchemeDetailPOEncrypt;
|
||||
import com.engine.salary.encrypt.EncryptUtil;
|
||||
import com.engine.salary.entity.sicategory.po.ICategoryPO;
|
||||
import com.engine.salary.entity.sischeme.bo.InsuranceSchemeBO;
|
||||
import com.engine.salary.entity.sischeme.dto.InsuranceSchemeDTO;
|
||||
|
|
@ -42,6 +42,8 @@ public class SISchemeBiz {
|
|||
return SqlProxyHandle.getProxy(SIAccountUtilMapper.class);
|
||||
}
|
||||
|
||||
private EncryptUtil encryptUtil = new EncryptUtil();
|
||||
|
||||
/**
|
||||
* 获取社保方案
|
||||
*
|
||||
|
|
@ -150,7 +152,7 @@ public class SISchemeBiz {
|
|||
try {
|
||||
InsuranceSchemeDetailMapper insuranceSchemeDetailMapper = sqlSession.getMapper(InsuranceSchemeDetailMapper.class);
|
||||
InsuranceSchemeDetailPO insuranceSchemeDetailPO = insuranceSchemeDetailMapper.getByPPI(primaryId, paymentScope, insuranceId);
|
||||
InsuranceSchemeDetailPOEncrypt.decryptItem(insuranceSchemeDetailPO);
|
||||
encryptUtil.decrypt(insuranceSchemeDetailPO, InsuranceSchemeDetailPO.class);
|
||||
return insuranceSchemeDetailPO;
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
|
|
@ -231,7 +233,7 @@ public class SISchemeBiz {
|
|||
try {
|
||||
InsuranceSchemeDetailMapper insuranceSchemeDetailMapper = sqlSession.getMapper(InsuranceSchemeDetailMapper.class);
|
||||
List<InsuranceSchemeDetailPO> insuranceSchemeDetailPOS = insuranceSchemeDetailMapper.queryListBySchemeId(primaryId);
|
||||
InsuranceSchemeDetailPOEncrypt.decryptList(insuranceSchemeDetailPOS);
|
||||
encryptUtil.decryptList(insuranceSchemeDetailPOS, InsuranceSchemeDetailPO.class);
|
||||
return decryptSchemeDetailList(insuranceSchemeDetailPOS);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
|
|
@ -271,7 +273,7 @@ public class SISchemeBiz {
|
|||
//保存福利项目明细表
|
||||
InsuranceSchemeDetailMapper insuranceSchemeDetailMapper = sqlSession.getMapper(InsuranceSchemeDetailMapper.class);
|
||||
List<InsuranceSchemeDetailPO> insuranceSchemeDetailPOS = InsuranceSchemeBO.convertToInsuranceSchemeDetailPoList(saveParam.getInsuranceSchemeDetailList(), employeeId, insuranceSchemePO.getId());
|
||||
InsuranceSchemeDetailPOEncrypt.encryptList(insuranceSchemeDetailPOS);
|
||||
encryptUtil.encryptList(insuranceSchemeDetailPOS, InsuranceSchemeDetailPO.class);
|
||||
insuranceSchemeDetailPOS.forEach(insuranceSchemeDetailMapper::insert);
|
||||
|
||||
sqlSession.commit();
|
||||
|
|
@ -325,7 +327,7 @@ public class SISchemeBiz {
|
|||
insuranceSchemeDetailMapper.batchDeleteByPrimaryIds(Collections.singleton(updateParam.getInsuranceScheme().getId()));
|
||||
//更新明细表
|
||||
List<InsuranceSchemeDetailPO> insuranceSchemeDetailPOS = InsuranceSchemeBO.convertToInsuranceSchemeDetailPoList(updateParam.getInsuranceSchemeDetailList(), employeeId, insuranceSchemePO.getId());
|
||||
InsuranceSchemeDetailPOEncrypt.encryptList(insuranceSchemeDetailPOS);
|
||||
encryptUtil.encryptList(insuranceSchemeDetailPOS, InsuranceSchemeDetailPO.class);
|
||||
insuranceSchemeDetailPOS.forEach(insuranceSchemeDetailMapper::insert);
|
||||
|
||||
//记录操作日志
|
||||
|
|
@ -410,7 +412,7 @@ public class SISchemeBiz {
|
|||
.validNum(item.getValidNum())
|
||||
.build()
|
||||
).collect(Collectors.toList());
|
||||
InsuranceSchemeDetailPOEncrypt.encryptList(detailPOS);
|
||||
encryptUtil.encryptList(detailPOS, InsuranceSchemeDetailPO.class);
|
||||
detailPOS.forEach(insuranceSchemeDetailMapper::insert);
|
||||
}
|
||||
|
||||
|
|
@ -432,7 +434,7 @@ public class SISchemeBiz {
|
|||
try {
|
||||
InsuranceSchemeDetailMapper insuranceSchemeDetailMapper = sqlSession.getMapper(InsuranceSchemeDetailMapper.class);
|
||||
List<InsuranceSchemeDetailPO> insuranceSchemeDetailPOList = insuranceSchemeDetailMapper.queryListByInsuranceIdIsPayment(insuranceId, isPayment);
|
||||
InsuranceSchemeDetailPOEncrypt.decryptList(insuranceSchemeDetailPOList);
|
||||
encryptUtil.decryptList(insuranceSchemeDetailPOList, InsuranceSchemeDetailPO.class);
|
||||
return insuranceSchemeDetailPOList;
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
|
|
|
|||
|
|
@ -1,7 +1,6 @@
|
|||
package com.engine.salary.biz;
|
||||
|
||||
import com.engine.salary.encrypt.archive.SalaryArchiveItemPOEncrypt;
|
||||
import com.engine.salary.encrypt.archive.SalaryItemAdjustRecordListDTOEncrypt;
|
||||
import com.engine.salary.encrypt.EncryptUtil;
|
||||
import com.engine.salary.entity.salaryarchive.dto.SalaryItemAdjustRecordListDTO;
|
||||
import com.engine.salary.entity.salaryarchive.param.SalaryArchiveItemQueryParam;
|
||||
import com.engine.salary.entity.salaryarchive.param.SalaryItemAdjustRecordQueryParam;
|
||||
|
|
@ -18,13 +17,14 @@ import java.util.ArrayList;
|
|||
import java.util.List;
|
||||
|
||||
public class SalaryArchiveItemBiz {
|
||||
public EncryptUtil encryptUtil = new EncryptUtil();
|
||||
|
||||
public List<SalaryArchiveItemPO> getCurrentEffectiveItemList(SalaryArchiveItemQueryParam build) {
|
||||
SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession();
|
||||
try {
|
||||
SalaryArchiveItemMapper mapper = sqlSession.getMapper(SalaryArchiveItemMapper.class);
|
||||
List<SalaryArchiveItemPO> salaryArchiveItemPOS = mapper.listByParam(build);
|
||||
return SalaryArchiveItemPOEncrypt.decryptSalaryArchiveItemPOList(salaryArchiveItemPOS);
|
||||
return encryptUtil.decryptList(salaryArchiveItemPOS, SalaryArchiveItemPO.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
@ -35,7 +35,7 @@ public class SalaryArchiveItemBiz {
|
|||
try {
|
||||
SalaryArchiveItemMapper mapper = sqlSession.getMapper(SalaryArchiveItemMapper.class);
|
||||
List<SalaryArchiveItemPO> salaryArchiveItemPOS = mapper.listByParam(build);
|
||||
return SalaryArchiveItemPOEncrypt.decryptSalaryArchiveItemPOList(salaryArchiveItemPOS);
|
||||
return encryptUtil.decryptList(salaryArchiveItemPOS, SalaryArchiveItemPO.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
@ -45,7 +45,7 @@ public class SalaryArchiveItemBiz {
|
|||
SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession();
|
||||
try {
|
||||
SalaryArchiveItemMapper mapper = sqlSession.getMapper(SalaryArchiveItemMapper.class);
|
||||
return SalaryArchiveItemPOEncrypt.decryptSalaryArchiveItemPO(mapper.getById(salaryArchiveItemId));
|
||||
return encryptUtil.decrypt(mapper.getById(salaryArchiveItemId), SalaryArchiveItemPO.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
@ -56,15 +56,15 @@ public class SalaryArchiveItemBiz {
|
|||
try {
|
||||
SalaryArchiveItemMapper mapper = sqlSession.getMapper(SalaryArchiveItemMapper.class);
|
||||
List<SalaryArchiveItemPO> ineffectiveSalaryItems = new ArrayList<>();
|
||||
if(CollectionUtils.isNotEmpty(build.getSalaryArchivesIds())){
|
||||
if (CollectionUtils.isNotEmpty(build.getSalaryArchivesIds())) {
|
||||
List<Long> salaryArchivesIds = (List<Long>) build.getSalaryArchivesIds();
|
||||
List<List<Long>> partition = Lists.partition(salaryArchivesIds,1000);
|
||||
List<List<Long>> partition = Lists.partition(salaryArchivesIds, 1000);
|
||||
partition.forEach(list -> {
|
||||
build.setSalaryArchivesIds(list);
|
||||
ineffectiveSalaryItems.addAll(mapper.getIneffectiveSalaryItems(build));
|
||||
});
|
||||
}
|
||||
return SalaryArchiveItemPOEncrypt.decryptSalaryArchiveItemPOList(ineffectiveSalaryItems);
|
||||
return encryptUtil.decryptList(ineffectiveSalaryItems, SalaryArchiveItemPO.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
@ -75,7 +75,7 @@ public class SalaryArchiveItemBiz {
|
|||
try {
|
||||
SalaryArchiveItemMapper mapper = sqlSession.getMapper(SalaryArchiveItemMapper.class);
|
||||
List<SalaryArchiveItemPO> effectiveSalaryItems = mapper.getEffectiveSalaryItems(build);
|
||||
return SalaryArchiveItemPOEncrypt.decryptSalaryArchiveItemPOList(effectiveSalaryItems);
|
||||
return encryptUtil.decryptList(effectiveSalaryItems, SalaryArchiveItemPO.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
@ -86,7 +86,7 @@ public class SalaryArchiveItemBiz {
|
|||
SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession();
|
||||
try {
|
||||
SalaryArchiveItemMapper mapper = sqlSession.getMapper(SalaryArchiveItemMapper.class);
|
||||
List<List<Long>> partition = Lists.partition(effectiveSalaryItemDels, 999);
|
||||
List<List<Long>> partition = Lists.partition(effectiveSalaryItemDels, 999);
|
||||
partition.forEach(mapper::deleteBatchIds);
|
||||
sqlSession.commit();
|
||||
} finally {
|
||||
|
|
@ -95,13 +95,13 @@ public class SalaryArchiveItemBiz {
|
|||
}
|
||||
|
||||
public void batchInsert(List<SalaryArchiveItemPO> salaryArchiveItemNews) {
|
||||
if(CollectionUtils.isEmpty(salaryArchiveItemNews)){
|
||||
if (CollectionUtils.isEmpty(salaryArchiveItemNews)) {
|
||||
return;
|
||||
}
|
||||
SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession();
|
||||
try {
|
||||
SalaryArchiveItemMapper mapper = sqlSession.getMapper(SalaryArchiveItemMapper.class);
|
||||
SalaryArchiveItemPOEncrypt.encryptSalaryArchiveItemPOList(salaryArchiveItemNews);
|
||||
encryptUtil.encryptList(salaryArchiveItemNews, SalaryArchiveItemPO.class);
|
||||
List<List<SalaryArchiveItemPO>> partition = Lists.partition(salaryArchiveItemNews, 100);
|
||||
partition.forEach(mapper::batchInsert);
|
||||
sqlSession.commit();
|
||||
|
|
@ -114,7 +114,7 @@ public class SalaryArchiveItemBiz {
|
|||
SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession();
|
||||
try {
|
||||
SalaryArchiveItemMapper mapper = sqlSession.getMapper(SalaryArchiveItemMapper.class);
|
||||
SalaryArchiveItemPOEncrypt.encryptSalaryArchiveItemPO(salaryArchiveItem);
|
||||
encryptUtil.encrypt(salaryArchiveItem, SalaryArchiveItemPO.class);
|
||||
mapper.update(salaryArchiveItem);
|
||||
sqlSession.commit();
|
||||
} finally {
|
||||
|
|
@ -127,7 +127,7 @@ public class SalaryArchiveItemBiz {
|
|||
SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession();
|
||||
try {
|
||||
SalaryArchiveItemMapper mapper = sqlSession.getMapper(SalaryArchiveItemMapper.class);
|
||||
SalaryArchiveItemPOEncrypt.encryptSalaryArchiveItemPO(salaryArchiveItem);
|
||||
encryptUtil.encrypt(salaryArchiveItem, SalaryArchiveItemPO.class);
|
||||
mapper.updateIgnoreNull(salaryArchiveItem);
|
||||
sqlSession.commit();
|
||||
} finally {
|
||||
|
|
@ -140,7 +140,7 @@ public class SalaryArchiveItemBiz {
|
|||
SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession();
|
||||
try {
|
||||
SalaryArchiveItemMapper mapper = sqlSession.getMapper(SalaryArchiveItemMapper.class);
|
||||
return SalaryItemAdjustRecordListDTOEncrypt.decryptSalaryItemAdjustRecordListDTOList(mapper.salaryItemAdjustRecordList(queryParam, salaryItemIds));
|
||||
return encryptUtil.decryptList(mapper.salaryItemAdjustRecordList(queryParam, salaryItemIds), SalaryItemAdjustRecordListDTO.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
@ -160,11 +160,12 @@ public class SalaryArchiveItemBiz {
|
|||
public PageInfo<SalaryItemAdjustRecordListDTO> salaryItemAdjustRecordListPage(SalaryItemAdjustRecordQueryParam queryParam, List<Long> salaryItemIds) {
|
||||
SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession();
|
||||
try {
|
||||
SalaryPageUtil.start(queryParam.getCurrent(), queryParam.getPageSize());
|
||||
SalaryArchiveItemMapper mapper = sqlSession.getMapper(SalaryArchiveItemMapper.class);
|
||||
List<SalaryItemAdjustRecordListDTO> salaryItemAdjustRecordListDTOS = mapper.salaryItemAdjustRecordList(queryParam, salaryItemIds);
|
||||
SalaryItemAdjustRecordListDTOEncrypt.decryptSalaryItemAdjustRecordListDTOList(salaryItemAdjustRecordListDTOS);
|
||||
PageInfo<SalaryItemAdjustRecordListDTO> page = new PageInfo<SalaryItemAdjustRecordListDTO>(salaryItemAdjustRecordListDTOS, SalaryItemAdjustRecordListDTO.class);
|
||||
PageInfo<SalaryItemAdjustRecordListDTO> page = SalaryPageUtil.buildPage(queryParam.getCurrent(), queryParam.getPageSize(),
|
||||
salaryItemAdjustRecordListDTOS,
|
||||
SalaryItemAdjustRecordListDTO.class);
|
||||
encryptUtil.decryptList(page.getList(), SalaryItemAdjustRecordListDTO.class);
|
||||
return page;
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import com.engine.salary.entity.salaryitem.po.SalaryItemPO;
|
|||
import com.engine.salary.enums.SalaryOnOffEnum;
|
||||
import com.engine.salary.mapper.salaryitem.SalaryItemMapper;
|
||||
import com.engine.salary.util.page.PageInfo;
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.engine.salary.util.page.SalaryPageUtil;
|
||||
import com.google.common.collect.Lists;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.apache.ibatis.session.SqlSession;
|
||||
|
|
@ -98,10 +98,9 @@ public class SalaryItemBiz {
|
|||
SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession();
|
||||
try {
|
||||
SalaryItemMapper mapper = sqlSession.getMapper(SalaryItemMapper.class);
|
||||
// SalaryPageUtil.start(searchParam.getCurrent(), searchParam.getPageSize());
|
||||
PageHelper.startPage(searchParam.getCurrent(), searchParam.getPageSize());
|
||||
List<SalaryItemPO> salaryItemPOList = mapper.listByParam(searchParam);
|
||||
return new PageInfo<SalaryItemPO>(salaryItemPOList);
|
||||
return SalaryPageUtil.buildPage(searchParam.getCurrent(), searchParam.getPageSize(),
|
||||
salaryItemPOList, SalaryItemPO.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,71 @@
|
|||
package com.engine.salary.biz;
|
||||
|
||||
import com.engine.common.util.ServiceUtil;
|
||||
import com.engine.salary.entity.salaryBill.dto.SalarySendUserInfoDTO;
|
||||
import com.engine.salary.entity.salaryBill.po.SalarySendRangeObj;
|
||||
import com.engine.salary.entity.taxagent.dto.TaxAgentEmployeeTaxAgentDTO;
|
||||
import com.engine.salary.mapper.salarybill.SalarySendRangeObjMapper;
|
||||
import com.engine.salary.service.TaxAgentService;
|
||||
import com.engine.salary.service.impl.TaxAgentServiceImpl;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.apache.ibatis.session.SqlSession;
|
||||
import weaver.conn.mybatis.MyBatisFactory;
|
||||
|
||||
import java.util.*;
|
||||
import java.util.function.Consumer;
|
||||
import java.util.function.Function;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import static com.engine.salary.constant.SalaryDefaultTenantConstant.DEFAULT_TENANT_KEY;
|
||||
|
||||
public class SalarySendRangeObjBiz {
|
||||
private TaxAgentService getTaxAgentService() {
|
||||
return ServiceUtil.getService(TaxAgentServiceImpl.class);
|
||||
}
|
||||
|
||||
public <R> R applyMapper(Function<SalarySendRangeObjMapper, R> mapper) {
|
||||
try (SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession()) {
|
||||
final SalarySendRangeObjMapper salarySendRangeObjMapper = sqlSession.getMapper(SalarySendRangeObjMapper.class);
|
||||
R apply = mapper.apply(salarySendRangeObjMapper);
|
||||
sqlSession.commit();
|
||||
return apply;
|
||||
}
|
||||
}
|
||||
|
||||
public void runMapper(Consumer<SalarySendRangeObjMapper> mapper) {
|
||||
try (SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession()) {
|
||||
final SalarySendRangeObjMapper salarySendRangeObjMapper = sqlSession.getMapper(SalarySendRangeObjMapper.class);
|
||||
mapper.accept(salarySendRangeObjMapper);
|
||||
sqlSession.commit();
|
||||
}
|
||||
}
|
||||
|
||||
public List<SalarySendUserInfoDTO> getSalarySendUserInfoDTOs(List<Long> employees) {
|
||||
List<SalarySendUserInfoDTO> userDTOs = applyMapper(mapper -> mapper.getUserInfoByEmployeeIds(employees));
|
||||
Map<Long, SalarySendUserInfoDTO> userMap = userDTOs.stream()
|
||||
.collect(Collectors.toMap(SalarySendUserInfoDTO::getResourceId, Function.identity()));
|
||||
|
||||
List<Long> employeeIds = userDTOs.stream()
|
||||
.map(SalarySendUserInfoDTO::getResourceId)
|
||||
.collect(Collectors.toList());
|
||||
Collection<TaxAgentEmployeeTaxAgentDTO> employeeAgents
|
||||
= getTaxAgentService().listAllTaxAgentsAsRange(employeeIds);
|
||||
for (TaxAgentEmployeeTaxAgentDTO employeeAgent : employeeAgents) {
|
||||
SalarySendUserInfoDTO info = userMap.get(employeeAgent.getEmployeeId());
|
||||
if (info != null) {
|
||||
if (CollectionUtils.isEmpty(info.getTaxAgentIds())) {
|
||||
info.setTaxAgentIds(new ArrayList<>());
|
||||
}
|
||||
info.getTaxAgentIds().addAll(Optional.ofNullable(employeeAgent.getTaxAgentIds()).orElse(Collections.emptyList()));
|
||||
}
|
||||
}
|
||||
return userDTOs;
|
||||
}
|
||||
|
||||
public void replaceAllByRangeId(Long rangeId, List<SalarySendRangeObj> rangeObjs) {
|
||||
runMapper(mapper -> {
|
||||
mapper.deleteByRangeIds(Collections.singletonList(rangeId), DEFAULT_TENANT_KEY);
|
||||
mapper.batchInsert(rangeObjs);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
@ -4,10 +4,9 @@ import com.engine.salary.entity.salarysob.param.SalarySobCheckRuleQueryParam;
|
|||
import com.engine.salary.entity.salarysob.po.SalarySobCheckRulePO;
|
||||
import com.engine.salary.mapper.salarysob.SalarySobCheckRuleMapper;
|
||||
import com.engine.salary.util.page.PageInfo;
|
||||
|
||||
import com.engine.salary.util.page.SalaryPageUtil;
|
||||
import com.google.common.collect.Lists;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import com.engine.salary.util.page.SalaryPageUtil;
|
||||
import org.apache.ibatis.session.SqlSession;
|
||||
import weaver.conn.mybatis.MyBatisFactory;
|
||||
|
||||
|
|
@ -100,10 +99,9 @@ public class SalarySobCheckRuleBiz {
|
|||
SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession();
|
||||
try {
|
||||
SalarySobCheckRuleMapper mapper = sqlSession.getMapper(SalarySobCheckRuleMapper.class);
|
||||
SalaryPageUtil.start(param.getCurrent(), param.getPageSize());
|
||||
List<SalarySobCheckRulePO> list = mapper.listByParam(param);
|
||||
PageInfo<SalarySobCheckRulePO> pageInfo = new PageInfo<SalarySobCheckRulePO>(list, SalarySobCheckRulePO.class);
|
||||
return pageInfo;
|
||||
return SalaryPageUtil.buildPage(param.getCurrent(), param.getPageSize(),
|
||||
list, SalarySobCheckRulePO.class);
|
||||
} finally {
|
||||
sqlSession.close();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,13 +1,12 @@
|
|||
package com.engine.salary.biz;
|
||||
|
||||
import com.engine.salary.encrypt.datacollection.SpecialAddDeductionEncrypt;
|
||||
import com.engine.salary.encrypt.EncryptUtil;
|
||||
import com.engine.salary.entity.datacollection.dto.SpecialAddDeductionListDTO;
|
||||
import com.engine.salary.entity.datacollection.dto.SpecialAddDeductionRecordDTO;
|
||||
import com.engine.salary.entity.datacollection.param.SpecialAddDeductionQueryParam;
|
||||
import com.engine.salary.entity.datacollection.po.SpecialAddDeductionPO;
|
||||
import com.engine.salary.mapper.datacollection.SpecialAddDeductionMapper;
|
||||
import com.engine.salary.util.db.MapperProxyFactory;
|
||||
import com.engine.salary.util.page.SalaryPageUtil;
|
||||
import com.google.common.collect.Lists;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.apache.ibatis.session.SqlSession;
|
||||
|
|
@ -18,6 +17,8 @@ import java.util.*;
|
|||
import java.util.stream.Collectors;
|
||||
|
||||
public class SpecialAddDeductionBiz extends BaseBean {
|
||||
private EncryptUtil encryptUtil = new EncryptUtil();
|
||||
|
||||
private SpecialAddDeductionMapper mapper() {
|
||||
return MapperProxyFactory.getProxy(SpecialAddDeductionMapper.class);
|
||||
}
|
||||
|
|
@ -32,26 +33,26 @@ public class SpecialAddDeductionBiz extends BaseBean {
|
|||
try (SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession()) {
|
||||
SpecialAddDeductionMapper mapper = sqlSession.getMapper(SpecialAddDeductionMapper.class);
|
||||
SpecialAddDeductionPO byId = mapper.getById(id);
|
||||
return SpecialAddDeductionEncrypt.decrypt(byId);
|
||||
return encryptUtil.decrypt(byId, SpecialAddDeductionPO.class);
|
||||
}
|
||||
}
|
||||
|
||||
public List<SpecialAddDeductionRecordDTO> listDTOByParam(SpecialAddDeductionQueryParam param) {
|
||||
List<SpecialAddDeductionRecordDTO> specialAddDeductionRecordDTOS = mapper().listDtoByParam(param);
|
||||
return SpecialAddDeductionEncrypt.decrypt(specialAddDeductionRecordDTOS);
|
||||
return encryptUtil.decryptList(specialAddDeductionRecordDTOS, SpecialAddDeductionRecordDTO.class);
|
||||
}
|
||||
|
||||
|
||||
public List<SpecialAddDeductionListDTO> listByParam(SpecialAddDeductionQueryParam param) {
|
||||
List<SpecialAddDeductionListDTO> specialAddDeductionListDTOS = mapper().listByParam(param);
|
||||
return SpecialAddDeductionEncrypt.decrypt(specialAddDeductionListDTOS);
|
||||
return encryptUtil.decryptList(specialAddDeductionListDTOS, SpecialAddDeductionListDTO.class);
|
||||
}
|
||||
|
||||
public List<SpecialAddDeductionPO> listByTaxAgentIds(List<Long> taxAgentIds) {
|
||||
try (SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession()) {
|
||||
SpecialAddDeductionMapper mapper = sqlSession.getMapper(SpecialAddDeductionMapper.class);
|
||||
List<SpecialAddDeductionPO> pos = mapper.listByTaxAgentIds(taxAgentIds);
|
||||
return SpecialAddDeductionEncrypt.decrypt(pos);
|
||||
return encryptUtil.decryptList(pos, SpecialAddDeductionPO.class);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -68,7 +69,7 @@ public class SpecialAddDeductionBiz extends BaseBean {
|
|||
}
|
||||
try (SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession()) {
|
||||
SpecialAddDeductionMapper mapper = sqlSession.getMapper(SpecialAddDeductionMapper.class);
|
||||
SpecialAddDeductionEncrypt.encrypt(param);
|
||||
encryptUtil.encryptList(param, SpecialAddDeductionPO.class);
|
||||
List<List<SpecialAddDeductionPO>> partition = Lists.partition(param, 100);
|
||||
partition.forEach(mapper::batchInsert);
|
||||
sqlSession.commit();
|
||||
|
|
@ -88,7 +89,7 @@ public class SpecialAddDeductionBiz extends BaseBean {
|
|||
SqlSession sqlSession = MyBatisFactory.sqlSessionFactory.openSession();
|
||||
try {
|
||||
SpecialAddDeductionMapper mapper = sqlSession.getMapper(SpecialAddDeductionMapper.class);
|
||||
SpecialAddDeductionEncrypt.encrypt(param);
|
||||
encryptUtil.encryptList(param, SpecialAddDeductionPO.class);
|
||||
List<List<SpecialAddDeductionPO>> partition = Lists.partition(param, 100);
|
||||
partition.forEach(mapper::updateBatchSelective);
|
||||
sqlSession.commit();
|
||||
|
|
@ -166,7 +167,7 @@ public class SpecialAddDeductionBiz extends BaseBean {
|
|||
.stream()
|
||||
.filter(Objects::nonNull)
|
||||
.filter(s -> s.getEmployeeId() != null)
|
||||
.map(SpecialAddDeductionEncrypt::decrypt)
|
||||
.map(item -> encryptUtil.decrypt(item, SpecialAddDeductionPO.class))
|
||||
.collect(Collectors.toList());
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,16 @@
|
|||
package com.engine.salary.encrypt;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
public class EncryptSetting {
|
||||
|
||||
public boolean open;
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,131 @@
|
|||
package com.engine.salary.encrypt;
|
||||
|
||||
|
||||
import com.engine.common.util.ServiceUtil;
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import com.engine.salary.exception.SalaryRunTimeException;
|
||||
import com.engine.salary.sys.service.SalarySysConfService;
|
||||
import com.engine.salary.sys.service.impl.SalarySysConfServiceImpl;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import weaver.hrm.User;
|
||||
|
||||
import java.lang.reflect.Field;
|
||||
import java.util.*;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
@Slf4j
|
||||
public class EncryptUtil {
|
||||
|
||||
private SalarySysConfService getSalarySysConfService(User user) {
|
||||
return ServiceUtil.getService(SalarySysConfServiceImpl.class, user);
|
||||
}
|
||||
|
||||
public <T> T encrypt(T data, Class<T> clazz) {
|
||||
boolean encryptIsOpen = getSalarySysConfService(null).encryptIsOpen();
|
||||
if (!encryptIsOpen) {
|
||||
return data;
|
||||
}
|
||||
try {
|
||||
List<Field> fieldList = Arrays.stream(clazz.getDeclaredFields()).filter(field -> field.isAnnotationPresent(Encrypt.class)).collect(Collectors.toList());
|
||||
if (CollectionUtils.isNotEmpty(fieldList)) {
|
||||
for (Field field : fieldList) {
|
||||
Field declaredField = data.getClass().getDeclaredField(field.getName());
|
||||
declaredField.setAccessible(true);
|
||||
String fieldValue = (String) declaredField.get(data);
|
||||
if (StringUtils.isNotBlank(fieldValue)) {
|
||||
String encryptValue = AESEncryptUtil.encrypt(fieldValue);
|
||||
declaredField.set(data, encryptValue);
|
||||
}
|
||||
}
|
||||
}
|
||||
return data;
|
||||
} catch (Exception e) {
|
||||
log.error("加密异常", e);
|
||||
throw new SalaryRunTimeException("加密异常");
|
||||
}
|
||||
}
|
||||
|
||||
public <T> List<T> encryptList(List<T> dataList, Class<T> clazz) {
|
||||
boolean encryptIsOpen = getSalarySysConfService(null).encryptIsOpen();
|
||||
if (!encryptIsOpen) {
|
||||
return dataList;
|
||||
}
|
||||
try {
|
||||
List<Field> fieldList = Arrays.stream(clazz.getDeclaredFields()).filter(field -> field.isAnnotationPresent(Encrypt.class)).collect(Collectors.toList());
|
||||
if (CollectionUtils.isNotEmpty(fieldList)) {
|
||||
List<Map<String, String>> values = new ArrayList<>();
|
||||
for (T data : dataList) {
|
||||
for (Field field : fieldList) {
|
||||
Field declaredField = data.getClass().getDeclaredField(field.getName());
|
||||
declaredField.setAccessible(true);
|
||||
String fieldValue = (String) declaredField.get(data);
|
||||
if (StringUtils.isNotBlank(fieldValue)) {
|
||||
String encryptValue = AESEncryptUtil.encrypt(fieldValue);
|
||||
declaredField.set(data, encryptValue);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
return dataList;
|
||||
} catch (Exception e) {
|
||||
log.error("批量加密异常", e);
|
||||
throw new SalaryRunTimeException("批量加密异常");
|
||||
}
|
||||
}
|
||||
|
||||
public <T> T decrypt(T data, Class<T> clazz) {
|
||||
boolean encryptIsOpen = getSalarySysConfService(null).encryptIsOpen();
|
||||
if (!encryptIsOpen) {
|
||||
return data;
|
||||
}
|
||||
try {
|
||||
List<Field> fieldList = Arrays.stream(clazz.getDeclaredFields()).filter(field -> field.isAnnotationPresent(Encrypt.class)).collect(Collectors.toList());
|
||||
if (CollectionUtils.isNotEmpty(fieldList)) {
|
||||
for (Field field : fieldList) {
|
||||
Field declaredField = data.getClass().getDeclaredField(field.getName());
|
||||
declaredField.setAccessible(true);
|
||||
String fieldValue = (String) declaredField.get(data);
|
||||
if (StringUtils.isNotBlank(fieldValue)) {
|
||||
String encryptValue = AESEncryptUtil.decrypt(fieldValue);
|
||||
declaredField.set(data, encryptValue);
|
||||
}
|
||||
}
|
||||
}
|
||||
return data;
|
||||
} catch (Exception e) {
|
||||
log.error("解密异常", e);
|
||||
throw new SalaryRunTimeException("解密异常");
|
||||
}
|
||||
}
|
||||
|
||||
public <T> List<T> decryptList(List<T> dataList, Class<T> clazz) {
|
||||
boolean encryptIsOpen = getSalarySysConfService(null).encryptIsOpen();
|
||||
if (!encryptIsOpen) {
|
||||
return dataList;
|
||||
}
|
||||
try {
|
||||
List<Field> fieldList = Arrays.stream(clazz.getDeclaredFields()).filter(field -> field.isAnnotationPresent(Encrypt.class)).collect(Collectors.toList());
|
||||
if (CollectionUtils.isNotEmpty(fieldList)) {
|
||||
for (T data : dataList) {
|
||||
for (Field field : fieldList) {
|
||||
Field declaredField = data.getClass().getDeclaredField(field.getName());
|
||||
declaredField.setAccessible(true);
|
||||
String fieldValue = (String) declaredField.get(data);
|
||||
if (StringUtils.isNotBlank(fieldValue)) {
|
||||
String encryptValue = AESEncryptUtil.decrypt(fieldValue);
|
||||
declaredField.set(data, encryptValue);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return dataList;
|
||||
} catch (Exception e) {
|
||||
log.error("批量解密异常", e);
|
||||
throw new SalaryRunTimeException("批量解密异常");
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -10,6 +10,7 @@ import java.util.List;
|
|||
* 字段:
|
||||
* item_value
|
||||
*/
|
||||
@Deprecated
|
||||
public class SalaryArchiveItemPOEncrypt {
|
||||
public static List<SalaryArchiveItemPO> encryptSalaryArchiveItemPOList(List<SalaryArchiveItemPO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ import com.engine.salary.entity.salaryarchive.dto.SalaryItemAdjustRecordListDTO;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
@Deprecated
|
||||
public class SalaryItemAdjustRecordListDTOEncrypt {
|
||||
public static List<SalaryItemAdjustRecordListDTO> decryptSalaryItemAdjustRecordListDTOList(List<SalaryItemAdjustRecordListDTO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -16,7 +16,9 @@ import java.util.List;
|
|||
* add_up_illness_medical
|
||||
* add_up_infant_care
|
||||
*/
|
||||
@Deprecated
|
||||
public class AddUpDeductionEncrypt {
|
||||
@Deprecated
|
||||
public static List<AddUpDeduction> encryptAddUpDeductionList(List<AddUpDeduction> list) {
|
||||
list.forEach(item -> {
|
||||
item.setAddUpChildEducation(AESEncryptUtil.encrypt(item.getAddUpChildEducation()));
|
||||
|
|
@ -30,6 +32,7 @@ public class AddUpDeductionEncrypt {
|
|||
return list;
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
public static List<AddUpDeduction> decryptAddUpDeductionList(List<AddUpDeduction> list) {
|
||||
list.forEach(item -> {
|
||||
item.setAddUpChildEducation(AESEncryptUtil.decrypt(item.getAddUpChildEducation()));
|
||||
|
|
@ -43,6 +46,7 @@ public class AddUpDeductionEncrypt {
|
|||
return list;
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
public static AddUpDeduction encryptAddUpDeduction(AddUpDeduction item) {
|
||||
if(item == null) {
|
||||
return item;
|
||||
|
|
@ -57,6 +61,7 @@ public class AddUpDeductionEncrypt {
|
|||
return item;
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
public static AddUpDeduction decryptAddUpDeduction(AddUpDeduction item) {
|
||||
if(item == null) {
|
||||
return item;
|
||||
|
|
|
|||
|
|
@ -16,6 +16,7 @@ import java.util.stream.Collectors;
|
|||
* add_up_housing_rent
|
||||
* add_up_support_elderly
|
||||
*/
|
||||
@Deprecated
|
||||
public class AddUpDeductionRecordStrDTOEncrypt {
|
||||
public static List<AddUpDeductionRecordDTO> decryptAddUpDeductionRecordDTO(List<AddUpDeductionRecordDTO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -14,6 +14,7 @@ import java.util.List;
|
|||
* add_up_housing_rent
|
||||
* add_up_support_elderly
|
||||
*/
|
||||
@Deprecated
|
||||
public class AddUpDeductionStrDTOEncrypt {
|
||||
public static void decryptAddUpDeductionList(List<AddUpDeductionDTO> list) {
|
||||
if (list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -3,7 +3,6 @@ package com.engine.salary.encrypt.datacollection;
|
|||
import com.engine.salary.encrypt.AESEncryptUtil;
|
||||
import com.engine.salary.entity.datacollection.dto.AddUpSituationDTO;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
|
|
@ -24,9 +23,10 @@ import java.util.List;
|
|||
* add_up_allowed_donation
|
||||
* add_up_advance_tax
|
||||
*/
|
||||
@Deprecated
|
||||
public class AddUpSituationDTOEncrypt {
|
||||
public static List<AddUpSituationDTO> encryptAddUpSituationDTOList(List<AddUpSituationDTO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
if (list == null || list.size() == 0) {
|
||||
return list;
|
||||
}
|
||||
list.forEach(item -> {
|
||||
|
|
@ -53,7 +53,7 @@ public class AddUpSituationDTOEncrypt {
|
|||
}
|
||||
|
||||
public static List<AddUpSituationDTO> decryptAddUpSituationDTOList(List<AddUpSituationDTO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
if (list == null || list.size() == 0) {
|
||||
return list;
|
||||
}
|
||||
list.forEach(item -> {
|
||||
|
|
|
|||
|
|
@ -23,6 +23,7 @@ import java.util.List;
|
|||
* add_up_allowed_donation
|
||||
* add_up_advance_tax
|
||||
*/
|
||||
@Deprecated
|
||||
public class AddUpSituationEncrypt {
|
||||
public static List<AddUpSituation> encryptAddUpSituationList(List<AddUpSituation> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ import com.engine.salary.entity.datacollection.dto.AddUpSituationRecordDTO;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
@Deprecated
|
||||
public class AddUpSituationRecordDTOEncrypt {
|
||||
public static List<AddUpSituationRecordDTO> encryptAddUpSituationRecordDTOList(List<AddUpSituationRecordDTO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -14,6 +14,7 @@ import java.util.List;
|
|||
* other_deduction
|
||||
* deduction_allowed_donation
|
||||
*/
|
||||
@Deprecated
|
||||
public class OtherDeductionListDTOEncrypt {
|
||||
public static List<OtherDeductionListDTO> encryptOtherDeductionListDTOList(List<OtherDeductionListDTO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -4,15 +4,7 @@ import com.engine.salary.encrypt.AESEncryptUtil;
|
|||
import com.engine.salary.entity.datacollection.po.OtherDeductionPO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* hrsa_other_deduction: 加解密
|
||||
* 字段:
|
||||
* business_healthy_insurance
|
||||
* tax_delay_endowment_insurance
|
||||
* other_deduction
|
||||
* deduction_allowed_donation
|
||||
*/
|
||||
@Deprecated
|
||||
public class OtherDeductionPOEncrypt {
|
||||
public static List<OtherDeductionPO> encryptOtherDeductionPOList(List<OtherDeductionPO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -13,6 +13,7 @@ import java.util.List;
|
|||
* other_deduction
|
||||
* deduction_allowed_donation
|
||||
*/
|
||||
@Deprecated
|
||||
public class OtherDeductionRecordDTOEncrypt {
|
||||
public static List<OtherDeductionRecordDTO> encryptOtherDeductionRecordDTOList(List<OtherDeductionRecordDTO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -1,13 +1,9 @@
|
|||
package com.engine.salary.encrypt.datacollection;
|
||||
|
||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
||||
import com.engine.salary.entity.datacollection.dto.SpecialAddDeductionRecordDTO;
|
||||
import com.engine.salary.entity.datacollection.po.SpecialAddDeductionPO;
|
||||
|
||||
import java.lang.reflect.Field;
|
||||
import java.util.Arrays;
|
||||
import java.util.Collection;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
|
|
@ -22,6 +18,7 @@ import java.util.stream.Collectors;
|
|||
* serious_illness_treatment
|
||||
* infant_care
|
||||
*/
|
||||
@Deprecated
|
||||
public class SpecialAddDeductionEncrypt {
|
||||
private static final List<String> FIELDS = Arrays.asList(
|
||||
"childrenEducation", "continuingEducation", "supportingElder", "housingLoanInterest",
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@ import java.util.Collection;
|
|||
/**
|
||||
* 薪资核算报表
|
||||
*/
|
||||
@Deprecated
|
||||
public class SalaryAcctResultReportPOEncrypt {
|
||||
|
||||
public static Collection<SalaryAcctResultReportPO> encryptList(Collection<SalaryAcctResultReportPO> list) {
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@ import com.engine.salary.entity.salaryacct.po.ExcelAcctResultPO;
|
|||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
@Deprecated
|
||||
public class ExcelAcctResultPOEncrypt {
|
||||
|
||||
public static Collection<ExcelAcctResultPO> encryptList(Collection<ExcelAcctResultPO> list) {
|
||||
|
|
|
|||
|
|
@ -5,8 +5,10 @@ import com.engine.salary.entity.salaryacct.po.SalaryAcctResultPO;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
@Deprecated
|
||||
public class SalaryAcctResultPOEncrypt {
|
||||
|
||||
@Deprecated
|
||||
public static List<SalaryAcctResultPO> encryptList(List<SalaryAcctResultPO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
return list;
|
||||
|
|
@ -18,6 +20,7 @@ public class SalaryAcctResultPOEncrypt {
|
|||
return list;
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
public static List<SalaryAcctResultPO> decryptList(List<SalaryAcctResultPO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
return list;
|
||||
|
|
@ -29,6 +32,7 @@ public class SalaryAcctResultPOEncrypt {
|
|||
return list;
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
public static SalaryAcctResultPO encryptItem(SalaryAcctResultPO item) {
|
||||
if(item == null) {
|
||||
return item;
|
||||
|
|
@ -37,6 +41,7 @@ public class SalaryAcctResultPOEncrypt {
|
|||
return item;
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
public static SalaryAcctResultPO decryptItem(SalaryAcctResultPO item) {
|
||||
if(item == null) {
|
||||
return item;
|
||||
|
|
|
|||
|
|
@ -30,6 +30,7 @@ import java.util.List;
|
|||
* other_sum
|
||||
* total
|
||||
*/
|
||||
@Deprecated
|
||||
public class ExcelInsuranceDetailPOEncrypt {
|
||||
public static List<ExcelInsuranceDetailPO> encryptInsuranceAccountDetailPOList(List<ExcelInsuranceDetailPO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -30,6 +30,7 @@ import java.util.List;
|
|||
* other_sum
|
||||
* total
|
||||
*/
|
||||
@Deprecated
|
||||
public class InsuranceAccountDetailPOEncrypt {
|
||||
public static List<InsuranceAccountDetailPO> encryptInsuranceAccountDetailPOList(List<InsuranceAccountDetailPO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -30,6 +30,7 @@ import java.util.List;
|
|||
* other_sum
|
||||
* total
|
||||
*/
|
||||
@Deprecated
|
||||
public class InsuranceAccountDetailTempPOEncrypt {
|
||||
public static List<InsuranceAccountDetailTempPO> encryptInsuranceAccountDetailTempPOList(List<InsuranceAccountDetailTempPO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -12,7 +12,9 @@ import java.util.List;
|
|||
* social_pay
|
||||
* fund_pay
|
||||
*/
|
||||
@Deprecated
|
||||
public class SiAccountEncrypt {
|
||||
@Deprecated
|
||||
public static List<InsuranceAccountBatchPO> encryptInsuranceAccountBatchList(List<InsuranceAccountBatchPO> list) {
|
||||
list.forEach(item -> {
|
||||
item.setOtherPay(AESEncryptUtil.encrypt(item.getOtherPay()));
|
||||
|
|
@ -22,6 +24,7 @@ public class SiAccountEncrypt {
|
|||
return list;
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
public static List<InsuranceAccountBatchPO> decryptInsuranceAccountBatchList(List<InsuranceAccountBatchPO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
return list;
|
||||
|
|
@ -34,6 +37,7 @@ public class SiAccountEncrypt {
|
|||
return list;
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
public static InsuranceAccountBatchPO encryptInsuranceAccountBatch(InsuranceAccountBatchPO item) {
|
||||
if(item == null) {
|
||||
return item;
|
||||
|
|
@ -44,6 +48,7 @@ public class SiAccountEncrypt {
|
|||
return item;
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
public static InsuranceAccountBatchPO decryptInsuranceAccountBatch(InsuranceAccountBatchPO item) {
|
||||
if(item == null) {
|
||||
return item;
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ import com.engine.salary.entity.siarchives.po.InsuranceArchivesFundSchemePO;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
@Deprecated
|
||||
public class InsuranceArchivesFundSchemePOEncrypt {
|
||||
public static List<InsuranceArchivesFundSchemePO> encryptList(List<InsuranceArchivesFundSchemePO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -1,11 +1,11 @@
|
|||
package com.engine.salary.encrypt.siarchives;
|
||||
|
||||
import com.engine.salary.encrypt.AESEncryptUtil;
|
||||
import com.engine.salary.entity.siaccount.po.InsuranceAccountBatchPO;
|
||||
import com.engine.salary.entity.siarchives.po.InsuranceArchivesOtherSchemePO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Deprecated
|
||||
public class InsuranceArchivesOtherSchemePOEncrypt {
|
||||
public static List<InsuranceArchivesOtherSchemePO> encryptList(List<InsuranceArchivesOtherSchemePO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ import com.engine.salary.entity.siarchives.po.InsuranceArchivesSocialSchemePO;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
@Deprecated
|
||||
public class InsuranceArchivesSocialSchemePOEncrypt {
|
||||
public static List<InsuranceArchivesSocialSchemePO> encryptList(List<InsuranceArchivesSocialSchemePO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -30,6 +30,7 @@ import java.util.List;
|
|||
* other_sum
|
||||
* total
|
||||
*/
|
||||
@Deprecated
|
||||
public class AccountExportPOEncrypt {
|
||||
public static List<AccountExportPO> encryptAccountExportPOList(List<AccountExportPO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -30,6 +30,7 @@ import java.util.List;
|
|||
* other_sum
|
||||
* total
|
||||
*/
|
||||
@Deprecated
|
||||
public class ExcelAccountExportPOEncrypt {
|
||||
public static List<ExcelAccountExportPO> encryptExcelAccountExportPOList(List<ExcelAccountExportPO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ import com.engine.salary.entity.sischeme.po.InsuranceSchemeDetailPO;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
@Deprecated
|
||||
public class InsuranceSchemeDetailPOEncrypt {
|
||||
public static List<InsuranceSchemeDetailPO> encryptList(List<InsuranceSchemeDetailPO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -10,6 +10,8 @@ import java.util.List;
|
|||
* 字段:
|
||||
* field_value
|
||||
*/
|
||||
|
||||
@Deprecated
|
||||
public class TaxDeclarationDetailEncrypt {
|
||||
public static List<TaxDeclarationDetailPO> encryptTaxDeclarationDetailList(List<TaxDeclarationDetailPO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -11,6 +11,7 @@ import java.util.List;
|
|||
* 字段:
|
||||
* field_value
|
||||
*/
|
||||
@Deprecated
|
||||
public class TaxDeclarationDetailPOEncrypt {
|
||||
public static List<TaxDeclarationDetailPO> encryptTaxDeclarationDetailPOList(List<TaxDeclarationDetailPO> list) {
|
||||
if(list == null || list.size() == 0) {
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package com.engine.salary.entity.datacollection;
|
||||
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import com.engine.salary.annotation.SalaryFormulaVar;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
|
|
@ -42,42 +43,49 @@ public class AddUpDeduction {
|
|||
* 累计子女教育
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计子女教育", labelId = 86321, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpChildEducation;
|
||||
|
||||
/**
|
||||
* 累计继续教育
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计继续教育", labelId = 86323, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpContinuingEducation;
|
||||
|
||||
/**
|
||||
* 累计住房贷款利息
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计住房贷款利息", labelId = 86324, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpHousingLoanInterest;
|
||||
|
||||
/**
|
||||
* 累计住房租金
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计住房租金", labelId = 86325, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpHousingRent;
|
||||
|
||||
/**
|
||||
* 累计赡养老人
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计赡养老人", labelId = 86326, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpSupportElderly;
|
||||
|
||||
/**
|
||||
* 累计大病医疗
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计大病医疗", labelId = 105142, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpIllnessMedical;
|
||||
|
||||
/**
|
||||
* 累计婴幼儿照护
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计婴幼儿照护", labelId = 117732, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpInfantCare;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package com.engine.salary.entity.datacollection;
|
||||
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import com.engine.salary.annotation.SalaryFormulaVar;
|
||||
import com.engine.salary.annotation.SalaryTable;
|
||||
import com.engine.salary.annotation.SalaryTableOperate;
|
||||
|
|
@ -52,102 +53,119 @@ public class AddUpSituation {
|
|||
* 累计收入额
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计收入额", labelId = 86712, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpIncome;
|
||||
|
||||
/**
|
||||
* 累计减除费用
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计减除费用", labelId = 86711, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpSubtraction;
|
||||
|
||||
/**
|
||||
* 累计社保个人合计
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计社保个人合计", labelId = 86710, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpSocialSecurityTotal;
|
||||
|
||||
/**
|
||||
* 累计公积金个人合计
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计公积金个人合计", labelId = 86709, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpAccumulationFundTotal;
|
||||
|
||||
/**
|
||||
* 累计子女教育
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计子女教育", labelId = 86321, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpChildEducation;
|
||||
|
||||
/**
|
||||
* 累计继续教育
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计继续教育", labelId = 86323, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpContinuingEducation;
|
||||
|
||||
/**
|
||||
* 累计住房贷款利息
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计住房贷款利息", labelId = 86324, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpHousingLoanInterest;
|
||||
|
||||
/**
|
||||
* 累计住房租金
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计住房租金", labelId = 86325, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpHousingRent;
|
||||
|
||||
/**
|
||||
* 累计赡养老人
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计赡养老人", labelId = 86326, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpSupportElderly;
|
||||
|
||||
/**
|
||||
* 累计大病医疗
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计大病医疗", labelId = 105142, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpIllnessMedical;
|
||||
|
||||
/**
|
||||
* 累计婴幼儿照护
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计婴幼儿照护", labelId = 117732, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpInfantCare;
|
||||
|
||||
/**
|
||||
* 累计企业(职业)年金及其他福利
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计企业(职业)年金及其他福利", labelId = 90567, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpEnterpriseAndOther;
|
||||
|
||||
/**
|
||||
* 累计其他免税扣除
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计其他免税扣除", labelId = 93902, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpOtherDeduction;
|
||||
|
||||
/**
|
||||
* 累计免税收入
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计免税收入", labelId = 86704, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpTaxExemptIncome;
|
||||
|
||||
/**
|
||||
* 累计准予扣除的捐赠额
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计准予扣除的捐赠额", labelId = 86703, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpAllowedDonation;
|
||||
|
||||
/**
|
||||
* 累计减免税额
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计减免税额", labelId = 105478, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpTaxSavings;
|
||||
|
||||
/**
|
||||
* 累计已预扣预缴税额
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "累计已预扣预缴税额", labelId = 86702, dataType = "number")
|
||||
@Encrypt
|
||||
private String addUpAdvanceTax;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -1,10 +1,7 @@
|
|||
package com.engine.salary.entity.datacollection.dto;
|
||||
|
||||
import com.cloudstore.eccom.pc.table.WeaTableType;
|
||||
import com.engine.salary.annotation.SalaryTable;
|
||||
import com.engine.salary.annotation.SalaryTableColumn;
|
||||
import com.engine.salary.annotation.SalaryTableOperate;
|
||||
import com.engine.salary.annotation.TableTitle;
|
||||
import com.engine.salary.annotation.*;
|
||||
import com.engine.salary.util.excel.ExcelProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.AllArgsConstructor;
|
||||
|
|
@ -108,6 +105,7 @@ public class AddUpDeductionDTO {
|
|||
@ExcelProperty(index = 7, msg = "第8列,累计子女教育解析错误,请输入数字")
|
||||
@SalaryTableColumn(text = "累计子女教育", width = "10%", column = "addUpChildEducation")
|
||||
@TableTitle(title = "累计子女教育", dataIndex = "addUpChildEducation", key = "addUpChildEducation")
|
||||
@Encrypt
|
||||
private String addUpChildEducation;
|
||||
|
||||
/**
|
||||
|
|
@ -116,6 +114,7 @@ public class AddUpDeductionDTO {
|
|||
@ExcelProperty(index = 8, msg = "第9列,累计继续教育教育解析错误,请输入数字")
|
||||
@SalaryTableColumn(text = "累计继续教育", width = "10%", column = "addUpContinuingEducation")
|
||||
@TableTitle(title = "累计继续教育", dataIndex = "addUpContinuingEducation", key = "addUpContinuingEducation")
|
||||
@Encrypt
|
||||
private String addUpContinuingEducation;
|
||||
|
||||
/**
|
||||
|
|
@ -124,6 +123,7 @@ public class AddUpDeductionDTO {
|
|||
@ExcelProperty(index = 9, msg = "第10列,累计住房贷款利息解析错误,请输入数字")
|
||||
@SalaryTableColumn(text = "累计住房贷款利息", width = "10%", column = "addUpHousingLoanInterest")
|
||||
@TableTitle(title = "累计住房贷款利息", dataIndex = "addUpHousingLoanInterest", key = "addUpHousingLoanInterest")
|
||||
@Encrypt
|
||||
private String addUpHousingLoanInterest;
|
||||
|
||||
/**
|
||||
|
|
@ -132,6 +132,7 @@ public class AddUpDeductionDTO {
|
|||
@ExcelProperty(index = 10, msg = "第11列,累计住房租金解析错误,请输入数字")
|
||||
@SalaryTableColumn(text = "累计住房租金", width = "10%", column = "addUpHousingRent")
|
||||
@TableTitle(title = "累计住房租金", dataIndex = "addUpHousingRent", key = "addUpHousingRent")
|
||||
@Encrypt
|
||||
private String addUpHousingRent;
|
||||
|
||||
/**
|
||||
|
|
@ -140,6 +141,7 @@ public class AddUpDeductionDTO {
|
|||
@ExcelProperty(index = 11, msg = "第12列,累计赡养老人解析错误,请输入数字")
|
||||
@SalaryTableColumn(text = "累计赡养老人", width = "10%", column = "addUpSupportElderly")
|
||||
@TableTitle(title = "累计赡养老人", dataIndex = "addUpSupportElderly", key = "addUpSupportElderly")
|
||||
@Encrypt
|
||||
private String addUpSupportElderly;
|
||||
|
||||
/**
|
||||
|
|
@ -148,11 +150,13 @@ public class AddUpDeductionDTO {
|
|||
@ExcelProperty(index = 12, msg = "第13列,累计大病医疗解析错误,请输入数字")
|
||||
@SalaryTableColumn(text = "累计大病医疗", width = "10%", column = "addUpIllnessMedical")
|
||||
@TableTitle(title = "累计大病医疗", dataIndex = "addUpIllnessMedical", key = "addUpIllnessMedical")
|
||||
@Encrypt
|
||||
private String addUpIllnessMedical;
|
||||
|
||||
@ExcelProperty(index = 13, msg = "第14列,累计婴幼儿照护解析错误,请输入数字")
|
||||
@SalaryTableColumn(text = "累计婴幼儿照护", width = "10%", column = "addUpInfantCare")
|
||||
@TableTitle(title = "累计婴幼儿照护", dataIndex = "addUpInfantCare", key = "addUpInfantCare")
|
||||
@Encrypt
|
||||
private String addUpInfantCare;
|
||||
|
||||
@SalaryTableColumn(text = "操作", width = "20%", column = "operate")
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
package com.engine.salary.entity.datacollection.dto;
|
||||
|
||||
import com.cloudstore.eccom.pc.table.WeaTableType;
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import com.engine.salary.annotation.SalaryTable;
|
||||
import com.engine.salary.annotation.SalaryTableColumn;
|
||||
import com.engine.salary.annotation.TableTitle;
|
||||
|
|
@ -73,6 +74,7 @@ public class AddUpDeductionRecordDTO {
|
|||
@ExcelProperty(index = 5)
|
||||
@SalaryTableColumn(text = "累计子女教育", width = "10%", column = "addUpChildEducation")
|
||||
@TableTitle(title = "累计子女教育", dataIndex = "addUpChildEducation", key = "addUpChildEducation")
|
||||
@Encrypt
|
||||
private String addUpChildEducation;
|
||||
|
||||
/**
|
||||
|
|
@ -81,6 +83,7 @@ public class AddUpDeductionRecordDTO {
|
|||
@ExcelProperty(index = 6)
|
||||
@SalaryTableColumn(text = "累计继续教育", width = "10%", column = "addUpContinuingEducation")
|
||||
@TableTitle(title = "累计继续教育", dataIndex = "addUpContinuingEducation", key = "addUpContinuingEducation")
|
||||
@Encrypt
|
||||
private String addUpContinuingEducation;
|
||||
|
||||
/**
|
||||
|
|
@ -89,6 +92,7 @@ public class AddUpDeductionRecordDTO {
|
|||
@ExcelProperty(index = 7)
|
||||
@SalaryTableColumn(text = "累计住房贷款利息", width = "10%", column = "addUpHousingLoanInterest")
|
||||
@TableTitle(title = "累计住房贷款利息", dataIndex = "addUpHousingLoanInterest", key = "addUpHousingLoanInterest")
|
||||
@Encrypt
|
||||
private String addUpHousingLoanInterest;
|
||||
|
||||
/**
|
||||
|
|
@ -97,6 +101,7 @@ public class AddUpDeductionRecordDTO {
|
|||
@ExcelProperty(index = 8)
|
||||
@SalaryTableColumn(text = "累计住房租金", width = "10%", column = "addUpHousingRent")
|
||||
@TableTitle(title = "累计住房租金", dataIndex = "addUpHousingRent", key = "addUpHousingRent")
|
||||
@Encrypt
|
||||
private String addUpHousingRent;
|
||||
|
||||
/**
|
||||
|
|
@ -105,16 +110,19 @@ public class AddUpDeductionRecordDTO {
|
|||
@ExcelProperty(index = 9)
|
||||
@SalaryTableColumn(text = "累计赡养老人", width = "10%", column = "addUpSupportElderly")
|
||||
@TableTitle(title = "累计赡养老人", dataIndex = "addUpSupportElderly", key = "addUpSupportElderly")
|
||||
@Encrypt
|
||||
private String addUpSupportElderly;
|
||||
|
||||
@ExcelProperty(index = 10)
|
||||
@SalaryTableColumn(text = "累计大病医疗", width = "10%", column = "addUpIllnessMedical")
|
||||
@TableTitle(title = "累计大病医疗", dataIndex = "addUpIllnessMedical", key = "addUpIllnessMedical")
|
||||
@Encrypt
|
||||
private String addUpIllnessMedical;
|
||||
|
||||
@ExcelProperty(index = 11)
|
||||
@SalaryTableColumn(text = "累计婴幼儿照护", width = "10%", column = "addUpInfantCare")
|
||||
@TableTitle(title = "累计婴幼儿照护", dataIndex = "addUpInfantCare", key = "addUpInfantCare")
|
||||
@Encrypt
|
||||
private String addUpInfantCare;
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,10 +1,7 @@
|
|||
package com.engine.salary.entity.datacollection.dto;
|
||||
|
||||
import com.cloudstore.eccom.pc.table.WeaTableType;
|
||||
import com.engine.salary.annotation.SalaryTable;
|
||||
import com.engine.salary.annotation.SalaryTableColumn;
|
||||
import com.engine.salary.annotation.SalaryTableOperate;
|
||||
import com.engine.salary.annotation.TableTitle;
|
||||
import com.engine.salary.annotation.*;
|
||||
import com.engine.salary.util.excel.ExcelProperty;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
|
||||
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
|
||||
|
|
@ -92,102 +89,119 @@ public class AddUpSituationDTO {
|
|||
@SalaryTableColumn(text = "累计收入额", width = "10%", column = "addUpIncome")
|
||||
@TableTitle(title = "累计收入额", dataIndex = "addUpIncome", key = "addUpIncome")
|
||||
@ExcelProperty(index = 7)
|
||||
@Encrypt
|
||||
private String addUpIncome;
|
||||
|
||||
//累计减除费用
|
||||
@SalaryTableColumn(text = "累计减除费用", width = "10%", column = "addUpSubtraction")
|
||||
@TableTitle(title = "累计减除费用", dataIndex = "addUpSubtraction", key = "addUpSubtraction")
|
||||
@ExcelProperty(index = 8)
|
||||
@Encrypt
|
||||
private String addUpSubtraction;
|
||||
|
||||
//累计社保个人合计
|
||||
@SalaryTableColumn(text = "累计社保个人合计", width = "10%", column = "addUpSocialSecurityTotal")
|
||||
@TableTitle(title = "累计社保个人合计", dataIndex = "addUpSocialSecurityTotal", key = "addUpSocialSecurityTotal")
|
||||
@ExcelProperty(index = 9)
|
||||
@Encrypt
|
||||
private String addUpSocialSecurityTotal;
|
||||
|
||||
//累计公积金个人合计
|
||||
@SalaryTableColumn(text = "累计公积金个人合计", width = "10%", column = "addUpAccumulationFundTotal")
|
||||
@TableTitle(title = "累计公积金个人合计", dataIndex = "addUpAccumulationFundTotal", key = "addUpAccumulationFundTotal")
|
||||
@ExcelProperty(index = 10)
|
||||
@Encrypt
|
||||
private String addUpAccumulationFundTotal;
|
||||
|
||||
//累计子女教育
|
||||
@SalaryTableColumn(text = "累计子女教育", width = "10%", column = "addUpChildEducation")
|
||||
@TableTitle(title = "累计子女教育", dataIndex = "addUpChildEducation", key = "addUpChildEducation")
|
||||
@ExcelProperty(index = 11)
|
||||
@Encrypt
|
||||
private String addUpChildEducation;
|
||||
|
||||
//累计继续教育
|
||||
@SalaryTableColumn(text = "累计继续教育", width = "10%", column = "addUpContinuingEducation")
|
||||
@TableTitle(title = "累计继续教育", dataIndex = "addUpContinuingEducation", key = "addUpContinuingEducation")
|
||||
@ExcelProperty(index = 12)
|
||||
@Encrypt
|
||||
private String addUpContinuingEducation;
|
||||
|
||||
//累计住房贷款利息
|
||||
@SalaryTableColumn(text = "累计住房贷款利息", width = "10%", column = "addUpHousingLoanInterest")
|
||||
@TableTitle(title = "累计住房贷款利息", dataIndex = "addUpHousingLoanInterest", key = "addUpHousingLoanInterest")
|
||||
@ExcelProperty(index = 13)
|
||||
@Encrypt
|
||||
private String addUpHousingLoanInterest;
|
||||
|
||||
//累计住房租金
|
||||
@SalaryTableColumn(text = "累计住房租金", width = "10%", column = "addUpHousingRent")
|
||||
@TableTitle(title = "累计住房租金", dataIndex = "addUpHousingRent", key = "addUpHousingRent")
|
||||
@ExcelProperty(index = 14)
|
||||
@Encrypt
|
||||
private String addUpHousingRent;
|
||||
|
||||
//累计赡养老人
|
||||
@SalaryTableColumn(text = "累计赡养老人", width = "10%", column = "addUpSupportElderly")
|
||||
@TableTitle(title = "累计赡养老人", dataIndex = "addUpSupportElderly", key = "addUpSupportElderly")
|
||||
@ExcelProperty(index = 15)
|
||||
@Encrypt
|
||||
private String addUpSupportElderly;
|
||||
|
||||
//累计大病医疗
|
||||
@SalaryTableColumn(text = "累计大病医疗", width = "10%", column = "addUpIllnessMedical")
|
||||
@TableTitle(title = "累计大病医疗", dataIndex = "addUpIllnessMedical", key = "addUpIllnessMedical")
|
||||
@ExcelProperty(index = 16)
|
||||
@Encrypt
|
||||
private String addUpIllnessMedical;
|
||||
|
||||
//累计企业(职业)年金及其他福利
|
||||
@SalaryTableColumn(text = "累计企业(职业)年金及其他福利", width = "10%", column = "addUpEnterpriseAndOther")
|
||||
@TableTitle(title = "累计企业(职业)年金及其他福利", dataIndex = "addUpEnterpriseAndOther", key = "addUpEnterpriseAndOther")
|
||||
@ExcelProperty(index = 17)
|
||||
@Encrypt
|
||||
private String addUpEnterpriseAndOther;
|
||||
|
||||
//累计其他扣除
|
||||
@SalaryTableColumn(text = "累计其他扣除", width = "10%", column = "addUpOtherDeduction")
|
||||
@TableTitle(title = "累计其他扣除", dataIndex = "addUpOtherDeduction", key = "addUpOtherDeduction")
|
||||
@ExcelProperty(index = 18)
|
||||
@Encrypt
|
||||
private String addUpOtherDeduction;
|
||||
|
||||
//累计免税收入
|
||||
@SalaryTableColumn(text = "累计免税收入", width = "10%", column = "addUpTaxExemptIncome")
|
||||
@TableTitle(title = "累计免税收入", dataIndex = "addUpTaxExemptIncome", key = "addUpTaxExemptIncome")
|
||||
@ExcelProperty(index = 19)
|
||||
@Encrypt
|
||||
private String addUpTaxExemptIncome;
|
||||
|
||||
//累计准予扣除的捐赠额
|
||||
@SalaryTableColumn(text = "累计准予扣除的捐赠额", width = "10%", column = "addUpAllowedDonation")
|
||||
@TableTitle(title = "累计准予扣除的捐赠额", dataIndex = "addUpAllowedDonation", key = "addUpAllowedDonation")
|
||||
@ExcelProperty(index = 20)
|
||||
@Encrypt
|
||||
private String addUpAllowedDonation;
|
||||
|
||||
//累计减免税额
|
||||
@SalaryTableColumn(text = "累计减免税额", width = "10%", column = "addUpTaxSavings")
|
||||
@TableTitle(title = "累计减免税额", dataIndex = "addUpTaxSavings", key = "addUpTaxSavings")
|
||||
@ExcelProperty(index = 21)
|
||||
@Encrypt
|
||||
private String addUpTaxSavings;
|
||||
|
||||
//累计已预扣预缴税额
|
||||
@SalaryTableColumn(text = "累计已预扣预缴税额", width = "10%", column = "addUpAdvanceTax")
|
||||
@TableTitle(title = "累计已预扣预缴税额", dataIndex = "addUpAdvanceTax", key = "addUpAdvanceTax")
|
||||
@ExcelProperty(index = 22)
|
||||
@Encrypt
|
||||
private String addUpAdvanceTax;
|
||||
|
||||
//累计婴幼儿照护
|
||||
@ExcelProperty(index = 23)
|
||||
@SalaryTableColumn(text = "累计婴幼儿照护", width = "10%", column = "addUpInfantCare")
|
||||
@TableTitle(title = "累计婴幼儿照护", dataIndex = "addUpInfantCare", key = "addUpInfantCare")
|
||||
@Encrypt
|
||||
private String addUpInfantCare;
|
||||
|
||||
@SalaryTableColumn(text = "操作", width = "20%", column = "operate")
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
package com.engine.salary.entity.datacollection.dto;
|
||||
|
||||
import com.cloudstore.eccom.pc.table.WeaTableType;
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import com.engine.salary.annotation.SalaryTable;
|
||||
import com.engine.salary.annotation.SalaryTableColumn;
|
||||
import com.engine.salary.annotation.TableTitle;
|
||||
|
|
@ -71,85 +72,102 @@ public class AddUpSituationRecordDTO {
|
|||
@SalaryTableColumn(text = "累计收入额", width = "10%", column = "addUpIncome")
|
||||
@TableTitle(title = "累计收入额", dataIndex = "addUpIncome", key = "addUpIncome")
|
||||
@ExcelProperty(index = 6)
|
||||
@Encrypt
|
||||
private String addUpIncome;
|
||||
|
||||
@SalaryTableColumn(text = "累计减除费用", width = "10%", column = "addUpSubtraction")
|
||||
@TableTitle(title = "累计减除费用", dataIndex = "addUpSubtraction", key = "addUpSubtraction")
|
||||
@ExcelProperty(index = 7)
|
||||
@Encrypt
|
||||
private String addUpSubtraction;
|
||||
|
||||
@SalaryTableColumn(text = "累计社保个人合计", width = "10%", column = "addUpSocialSecurityTotal")
|
||||
@TableTitle(title = "累计社保个人合计", dataIndex = "addUpSocialSecurityTotal", key = "addUpSocialSecurityTotal")
|
||||
@ExcelProperty(index = 8)
|
||||
@Encrypt
|
||||
private String addUpSocialSecurityTotal;
|
||||
|
||||
@SalaryTableColumn(text = "累计公积金个人合计", width = "10%", column = "addUpAccumulationFundTotal")
|
||||
@TableTitle(title = "累计公积金个人合计", dataIndex = "addUpAccumulationFundTotal", key = "addUpAccumulationFundTotal")
|
||||
@ExcelProperty(index = 9)
|
||||
@Encrypt
|
||||
private String addUpAccumulationFundTotal;
|
||||
|
||||
@ExcelProperty(index = 10)
|
||||
@SalaryTableColumn(text = "累计子女教育", width = "10%", column = "addUpChildEducation")
|
||||
@TableTitle(title = "累计子女教育", dataIndex = "addUpChildEducation", key = "addUpChildEducation")
|
||||
@Encrypt
|
||||
private String addUpChildEducation;
|
||||
|
||||
@ExcelProperty(index = 11)
|
||||
@SalaryTableColumn(text = "累计继续教育", width = "10%", column = "addUpContinuingEducation")
|
||||
@TableTitle(title = "累计继续教育", dataIndex = "addUpContinuingEducation", key = "addUpContinuingEducation")
|
||||
@Encrypt
|
||||
private String addUpContinuingEducation;
|
||||
|
||||
@ExcelProperty(index = 12)
|
||||
@SalaryTableColumn(text = "累计住房贷款利息", width = "10%", column = "addUpHousingLoanInterest")
|
||||
@TableTitle(title = "累计住房贷款利息", dataIndex = "addUpHousingLoanInterest", key = "addUpHousingLoanInterest")
|
||||
@Encrypt
|
||||
private String addUpHousingLoanInterest;
|
||||
|
||||
@ExcelProperty(index = 13)
|
||||
@SalaryTableColumn(text = "累计住房租金", width = "10%", column = "addUpHousingRent")
|
||||
@TableTitle(title = "累计住房租金", dataIndex = "addUpHousingRent", key = "addUpHousingRent")
|
||||
@Encrypt
|
||||
private String addUpHousingRent;
|
||||
|
||||
@ExcelProperty(index = 14)
|
||||
@SalaryTableColumn(text = "累计赡养老人", width = "10%", column = "addUpSupportElderly")
|
||||
@TableTitle(title = "累计赡养老人", dataIndex = "addUpSupportElderly", key = "addUpSupportElderly")
|
||||
@Encrypt
|
||||
private String addUpSupportElderly;
|
||||
|
||||
@ExcelProperty(index = 15)
|
||||
@SalaryTableColumn(text = "累计大病医疗", width = "10%", column = "addUpIllnessMedical")
|
||||
@TableTitle(title = "累计大病医疗", dataIndex = "addUpIllnessMedical", key = "addUpIllnessMedical")
|
||||
@Encrypt
|
||||
private String addUpIllnessMedical;
|
||||
|
||||
@ExcelProperty(index = 16)
|
||||
@SalaryTableColumn(text = "累计企业(职业)年金及其他福利", width = "10%", column = "addUpEnterpriseAndOther")
|
||||
@TableTitle(title = "累计企业(职业)年金及其他福利", dataIndex = "addUpEnterpriseAndOther", key = "addUpEnterpriseAndOther")
|
||||
@Encrypt
|
||||
private String addUpEnterpriseAndOther;
|
||||
|
||||
@ExcelProperty(index = 17)
|
||||
@SalaryTableColumn(text = "累计其他扣除", width = "10%", column = "addUpOtherDeduction")
|
||||
@TableTitle(title = "累计其他扣除", dataIndex = "addUpOtherDeduction", key = "addUpOtherDeduction")
|
||||
@Encrypt
|
||||
private String addUpOtherDeduction;
|
||||
|
||||
@ExcelProperty(index = 18)
|
||||
@SalaryTableColumn(text = "累计免税收入", width = "10%", column = "addUpTaxExemptIncome")
|
||||
@TableTitle(title = "累计免税收入", dataIndex = "addUpTaxExemptIncome", key = "addUpTaxExemptIncome")
|
||||
@Encrypt
|
||||
private String addUpTaxExemptIncome;
|
||||
|
||||
@ExcelProperty(index = 19)
|
||||
@SalaryTableColumn(text = "累计准予扣除的捐赠额", width = "10%", column = "addUpAllowedDonation")
|
||||
@TableTitle(title = "累计准予扣除的捐赠额", dataIndex = "addUpAllowedDonation", key = "addUpAllowedDonation")
|
||||
@Encrypt
|
||||
private String addUpAllowedDonation;
|
||||
|
||||
@ExcelProperty(index = 20)
|
||||
@SalaryTableColumn(text = "累计减免税额", width = "10%", column = "addUpTaxSavings")
|
||||
@TableTitle(title = "累计减免税额", dataIndex = "addUpTaxSavings", key = "addUpTaxSavings")
|
||||
@Encrypt
|
||||
private String addUpTaxSavings;
|
||||
|
||||
@ExcelProperty(index = 21)
|
||||
@SalaryTableColumn(text = "累计已预扣预缴税额", width = "10%", column = "addUpAdvanceTax")
|
||||
@TableTitle(title = "累计已预扣预缴税额", dataIndex = "addUpAdvanceTax", key = "addUpAdvanceTax")
|
||||
@Encrypt
|
||||
private String addUpAdvanceTax;
|
||||
|
||||
@ExcelProperty(index = 22)
|
||||
@SalaryTableColumn(text = "累计婴幼儿照护", width = "10%", column = "addUpInfantCare")
|
||||
@TableTitle(title = "累计婴幼儿照护", dataIndex = "addUpInfantCare", key = "addUpInfantCare")
|
||||
@Encrypt
|
||||
private String addUpInfantCare;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,10 +1,7 @@
|
|||
package com.engine.salary.entity.datacollection.dto;
|
||||
|
||||
import com.cloudstore.eccom.pc.table.WeaTableType;
|
||||
import com.engine.salary.annotation.SalaryTable;
|
||||
import com.engine.salary.annotation.SalaryTableColumn;
|
||||
import com.engine.salary.annotation.SalaryTableOperate;
|
||||
import com.engine.salary.annotation.TableTitle;
|
||||
import com.engine.salary.annotation.*;
|
||||
import com.engine.salary.util.excel.ExcelProperty;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
|
|
@ -87,24 +84,28 @@ public class OtherDeductionListDTO {
|
|||
@ExcelProperty(index = 7)
|
||||
@SalaryTableColumn(text = "商业健康保险", width = "10%", column = "businessHealthyInsurance")
|
||||
@TableTitle(title = "商业健康保险", dataIndex = "businessHealthyInsurance", key = "businessHealthyInsurance")
|
||||
@Encrypt
|
||||
private String businessHealthyInsurance;
|
||||
|
||||
//税延养老保险
|
||||
@ExcelProperty(index = 8)
|
||||
@SalaryTableColumn(text = "税延养老保险", width = "10%", column = "taxDelayEndowmentInsurance")
|
||||
@TableTitle(title = "税延养老保险", dataIndex = "taxDelayEndowmentInsurance", key = "taxDelayEndowmentInsurance")
|
||||
@Encrypt
|
||||
private String taxDelayEndowmentInsurance;
|
||||
|
||||
//其他
|
||||
@ExcelProperty(index = 9)
|
||||
@SalaryTableColumn(text = "其他", width = "10%", column = "otherDeduction")
|
||||
@TableTitle(title = "其他", dataIndex = "otherDeduction", key = "otherDeduction")
|
||||
@Encrypt
|
||||
private String otherDeduction;
|
||||
|
||||
//准予扣除的捐赠额
|
||||
@ExcelProperty(index = 10)
|
||||
@SalaryTableColumn(text = "准予扣除的捐赠额", width = "10%", column = "deductionAllowedDonation")
|
||||
@TableTitle(title = "准予扣除的捐赠额", dataIndex = "deductionAllowedDonation", key = "deductionAllowedDonation")
|
||||
@Encrypt
|
||||
private String deductionAllowedDonation;
|
||||
|
||||
@SalaryTableColumn(text = "操作", width = "20%", column = "operate")
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
package com.engine.salary.entity.datacollection.dto;
|
||||
|
||||
import com.cloudstore.eccom.pc.table.WeaTableType;
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import com.engine.salary.annotation.SalaryTable;
|
||||
import com.engine.salary.annotation.SalaryTableColumn;
|
||||
import com.engine.salary.annotation.TableTitle;
|
||||
|
|
@ -72,20 +73,24 @@ public class OtherDeductionRecordDTO {
|
|||
//商业健康保险
|
||||
@SalaryTableColumn(text = "商业健康保险", width = "10%", column = "businessHealthyInsurance")
|
||||
@TableTitle(title = "商业健康保险", dataIndex = "businessHealthyInsurance", key = "businessHealthyInsurance")
|
||||
@Encrypt
|
||||
private String businessHealthyInsurance;
|
||||
|
||||
//税延养老保险
|
||||
@SalaryTableColumn(text = "税延养老保险", width = "10%", column = "taxDelayEndowmentInsurance")
|
||||
@TableTitle(title = "税延养老保险", dataIndex = "taxDelayEndowmentInsurance", key = "taxDelayEndowmentInsurance")
|
||||
@Encrypt
|
||||
private String taxDelayEndowmentInsurance;
|
||||
|
||||
//其他
|
||||
@SalaryTableColumn(text = "其他", width = "10%", column = "otherDeduction")
|
||||
@TableTitle(title = "其他", dataIndex = "otherDeduction", key = "otherDeduction")
|
||||
@Encrypt
|
||||
private String otherDeduction;
|
||||
|
||||
//准予扣除的捐赠额
|
||||
@SalaryTableColumn(text = "准予扣除的捐赠额", width = "10%", column = "deductionAllowedDonation")
|
||||
@TableTitle(title = "准予扣除的捐赠额", dataIndex = "deductionAllowedDonation", key = "deductionAllowedDonation")
|
||||
@Encrypt
|
||||
private String deductionAllowedDonation;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,10 +1,7 @@
|
|||
package com.engine.salary.entity.datacollection.dto;
|
||||
|
||||
import com.cloudstore.eccom.pc.table.WeaTableType;
|
||||
import com.engine.salary.annotation.SalaryTable;
|
||||
import com.engine.salary.annotation.SalaryTableColumn;
|
||||
import com.engine.salary.annotation.SalaryTableOperate;
|
||||
import com.engine.salary.annotation.TableTitle;
|
||||
import com.engine.salary.annotation.*;
|
||||
import com.engine.salary.util.excel.ExcelProperty;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
|
|
@ -87,42 +84,49 @@ public class SpecialAddDeductionListDTO {
|
|||
@ExcelProperty(index = 7)
|
||||
@SalaryTableColumn(text = "子女教育", width = "10%", column = "childrenEducation")
|
||||
@TableTitle(title = "子女教育", dataIndex = "childrenEducation", key = "childrenEducation")
|
||||
@Encrypt
|
||||
private String childrenEducation;
|
||||
|
||||
//继续教育
|
||||
@ExcelProperty(index = 8)
|
||||
@SalaryTableColumn(text = "继续教育", width = "10%", column = "continuingEducation")
|
||||
@TableTitle(title = "继续教育", dataIndex = "continuingEducation", key = "continuingEducation")
|
||||
@Encrypt
|
||||
private String continuingEducation;
|
||||
|
||||
//住房贷款利息
|
||||
@ExcelProperty(index = 9)
|
||||
@SalaryTableColumn(text = "住房贷款利息", width = "10%", column = "housingLoanInterest")
|
||||
@TableTitle(title = "住房贷款利息", dataIndex = "housingLoanInterest", key = "housingLoanInterest")
|
||||
@Encrypt
|
||||
private String housingLoanInterest;
|
||||
|
||||
//住房租金
|
||||
@ExcelProperty(index = 10)
|
||||
@SalaryTableColumn(text = "住房租金", width = "10%", column = "housingRent")
|
||||
@TableTitle(title = "住房租金", dataIndex = "housingRent", key = "housingRent")
|
||||
@Encrypt
|
||||
private String housingRent;
|
||||
|
||||
//赡养老人
|
||||
@ExcelProperty(index = 11)
|
||||
@SalaryTableColumn(text = "赡养老人", width = "10%", column = "supportingElder")
|
||||
@TableTitle(title = "赡养老人", dataIndex = "supportingElder", key = "supportingElder")
|
||||
@Encrypt
|
||||
private String supportingElder;
|
||||
|
||||
//大病医疗
|
||||
@ExcelProperty(index = 12)
|
||||
@SalaryTableColumn(text = "大病医疗", width = "10%", column = "seriousIllnessTreatment")
|
||||
@TableTitle(title = "大病医疗", dataIndex = "seriousIllnessTreatment", key = "seriousIllnessTreatment")
|
||||
@Encrypt
|
||||
private String seriousIllnessTreatment;
|
||||
|
||||
//婴幼儿照护
|
||||
@ExcelProperty(index = 13)
|
||||
@SalaryTableColumn(text = "婴幼儿照护", width = "10%", column = "infantCare")
|
||||
@TableTitle(title = "婴幼儿照护", dataIndex = "infantCare", key = "infantCare")
|
||||
@Encrypt
|
||||
private String infantCare;
|
||||
|
||||
@SalaryTableColumn(text = "操作", width = "20%", column = "operate")
|
||||
|
|
|
|||
|
|
@ -1,17 +1,15 @@
|
|||
package com.engine.salary.entity.datacollection.dto;
|
||||
|
||||
import com.cloudstore.eccom.pc.table.WeaTableType;
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import com.engine.salary.annotation.SalaryTable;
|
||||
import com.engine.salary.annotation.SalaryTableColumn;
|
||||
import com.engine.salary.annotation.TableTitle;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 其他免税扣除记录列表
|
||||
* <p>Copyright: Copyright (c) 2022</p>
|
||||
|
|
@ -66,35 +64,42 @@ public class SpecialAddDeductionRecordDTO {
|
|||
//子女教育
|
||||
@SalaryTableColumn(text = "子女教育", width = "10%", column = "childrenEducation")
|
||||
@TableTitle(title = "子女教育", dataIndex = "childrenEducation", key = "childrenEducation")
|
||||
@Encrypt
|
||||
private String childrenEducation;
|
||||
|
||||
//继续教育
|
||||
@SalaryTableColumn(text = "继续教育", width = "10%", column = "continuingEducation")
|
||||
@TableTitle(title = "继续教育", dataIndex = "continuingEducation", key = "continuingEducation")
|
||||
@Encrypt
|
||||
private String continuingEducation;
|
||||
|
||||
//住房贷款利息
|
||||
@SalaryTableColumn(text = "住房贷款利息", width = "10%", column = "housingLoanInterest")
|
||||
@TableTitle(title = "住房贷款利息", dataIndex = "housingLoanInterest", key = "housingLoanInterest")
|
||||
@Encrypt
|
||||
private String housingLoanInterest;
|
||||
|
||||
//住房租金
|
||||
@SalaryTableColumn(text = "住房租金", width = "10%", column = "housingRent")
|
||||
@TableTitle(title = "住房租金", dataIndex = "housingRent", key = "housingRent")
|
||||
@Encrypt
|
||||
private String housingRent;
|
||||
|
||||
//赡养老人
|
||||
@SalaryTableColumn(text = "赡养老人", width = "10%", column = "supportingElder")
|
||||
@TableTitle(title = "赡养老人", dataIndex = "supportingElder", key = "supportingElder")
|
||||
@Encrypt
|
||||
private String supportingElder;
|
||||
|
||||
//大病医疗
|
||||
@SalaryTableColumn(text = "大病医疗", width = "10%", column = "seriousIllnessTreatment")
|
||||
@TableTitle(title = "大病医疗", dataIndex = "seriousIllnessTreatment", key = "seriousIllnessTreatment")
|
||||
@Encrypt
|
||||
private String seriousIllnessTreatment;
|
||||
|
||||
//大病医疗
|
||||
@SalaryTableColumn(text = "婴幼儿照护", width = "10%", column = "infantCare")
|
||||
@TableTitle(title = "婴幼儿照护", dataIndex = "infantCare", key = "infantCare")
|
||||
@Encrypt
|
||||
private String infantCare;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package com.engine.salary.entity.datacollection.po;
|
||||
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import com.engine.salary.annotation.SalaryFormulaVar;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
|
|
@ -43,24 +44,28 @@ public class OtherDeductionPO {
|
|||
* 商业健康保险
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "商业健康保险", labelId = 91238, dataType = "number")
|
||||
@Encrypt
|
||||
private String businessHealthyInsurance;
|
||||
|
||||
/**
|
||||
* 税延养老保险
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "税延养老保险", labelId = 91239, dataType = "number")
|
||||
@Encrypt
|
||||
private String taxDelayEndowmentInsurance;
|
||||
|
||||
/**
|
||||
* 其他
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "其他", labelId = 84500, dataType = "number")
|
||||
@Encrypt
|
||||
private String otherDeduction;
|
||||
|
||||
/**
|
||||
* 准予扣除的捐赠额
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "准予扣除的捐赠额", labelId = 91240, dataType = "number")
|
||||
@Encrypt
|
||||
private String deductionAllowedDonation;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -1,12 +1,14 @@
|
|||
package com.engine.salary.entity.datacollection.po;
|
||||
|
||||
import java.util.Date;
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 数据采集-专项附加扣除表
|
||||
*/
|
||||
|
|
@ -31,36 +33,43 @@ public class SpecialAddDeductionPO {
|
|||
/**
|
||||
* 子女教育
|
||||
*/
|
||||
@Encrypt
|
||||
private String childrenEducation;
|
||||
|
||||
/**
|
||||
* 继续教育
|
||||
*/
|
||||
@Encrypt
|
||||
private String continuingEducation;
|
||||
|
||||
/**
|
||||
* 住房贷款利息
|
||||
*/
|
||||
@Encrypt
|
||||
private String housingLoanInterest;
|
||||
|
||||
/**
|
||||
* 住房租金
|
||||
*/
|
||||
@Encrypt
|
||||
private String housingRent;
|
||||
|
||||
/**
|
||||
* 赡养老人
|
||||
*/
|
||||
@Encrypt
|
||||
private String supportingElder;
|
||||
|
||||
/**
|
||||
* 大病医疗
|
||||
*/
|
||||
@Encrypt
|
||||
private String seriousIllnessTreatment;
|
||||
|
||||
/**
|
||||
* 婴幼儿照护
|
||||
*/
|
||||
@Encrypt
|
||||
private String infantCare;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -20,4 +20,7 @@ public class HrmInfoDTO {
|
|||
|
||||
//姓名
|
||||
private String username;
|
||||
|
||||
|
||||
private Long target;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -18,10 +18,13 @@ import java.util.Collection;
|
|||
@AllArgsConstructor
|
||||
public class HrmQueryParam {
|
||||
|
||||
String userName;
|
||||
private String userName;
|
||||
|
||||
private int pageNum;
|
||||
private int pageSize;
|
||||
|
||||
private Collection<Long> ids;
|
||||
|
||||
private String billMonth;
|
||||
private Long paymentOrganization;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package com.engine.salary.entity.report.po;
|
||||
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -24,6 +25,7 @@ public class SalaryAcctResultReportPO {
|
|||
/**
|
||||
* 薪资核算人员id
|
||||
*/
|
||||
@Encrypt
|
||||
private String salaryAcctEmpId;
|
||||
/**
|
||||
* 薪资核算的id
|
||||
|
|
@ -32,6 +34,7 @@ public class SalaryAcctResultReportPO {
|
|||
/**
|
||||
* 人员id
|
||||
*/
|
||||
@Encrypt
|
||||
private String employeeId;
|
||||
/**
|
||||
* 个税扣缴义务人id
|
||||
|
|
|
|||
|
|
@ -0,0 +1,186 @@
|
|||
package com.engine.salary.entity.salaryBill.bo;
|
||||
|
||||
import com.engine.salary.entity.salaryBill.dto.SalarySendUserInfoDTO;
|
||||
import com.engine.salary.entity.salaryBill.po.SalarySendRangeObj;
|
||||
import com.engine.salary.enums.salarysend.SalarySendRangeTargetTypeEnum;
|
||||
import com.engine.salary.enums.salarysend.SalarySendRangeTypeEnum;
|
||||
import com.google.common.collect.Sets;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
* @Description: 工资单发放范围
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
public class SalarySendRangeBO {
|
||||
private static final SalarySendRangeItem EMPTY_ITEM = new SalarySendRangeItem(null, null, Collections.emptySet());
|
||||
|
||||
private static final Integer INCLUDED = 1;
|
||||
private static final Integer EXCLUDED = -1;
|
||||
private static final Integer NOT_IN = 0;
|
||||
|
||||
/**
|
||||
* 索引map
|
||||
*/
|
||||
private final Map<SalarySendRangeTargetTypeEnum, Map<SalarySendRangeTypeEnum, SalarySendRangeItem>> indexMap
|
||||
= new HashMap<>(6);
|
||||
|
||||
/**
|
||||
* 排除所有人
|
||||
*/
|
||||
private boolean isExcludeAll = false;
|
||||
|
||||
/**
|
||||
* 增加所有人
|
||||
*/
|
||||
private boolean isIncludeAll = false;
|
||||
|
||||
public boolean putNew(SalarySendRangeObj salarySendRangeObj) {
|
||||
//如果已经设置了排除所有人 或者 添加所有人, 直接跳过处理
|
||||
if (isExcludeAll) {
|
||||
return true;
|
||||
}
|
||||
Integer rangeType = salarySendRangeObj.getRangeType();
|
||||
SalarySendRangeTypeEnum rangeTypeE = SalarySendRangeTypeEnum.fromValue(rangeType);
|
||||
|
||||
Integer targetType = salarySendRangeObj.getTargetType();
|
||||
SalarySendRangeTargetTypeEnum targetTypeE = SalarySendRangeTargetTypeEnum.fromValue(targetType);
|
||||
|
||||
if (rangeTypeE == null || targetTypeE == null) {
|
||||
return false;
|
||||
}
|
||||
//所有人 筛选
|
||||
if (targetTypeE == SalarySendRangeTargetTypeEnum.ALL) {
|
||||
isIncludeAll = rangeTypeE == SalarySendRangeTypeEnum.INCLUDE_OBJ;
|
||||
isExcludeAll = rangeTypeE == SalarySendRangeTypeEnum.EXCLUDE_OBJ;
|
||||
}
|
||||
//未存入时插入
|
||||
indexMap.computeIfAbsent(targetTypeE, k -> {
|
||||
Map<SalarySendRangeTypeEnum, SalarySendRangeItem> value = new HashMap<>();
|
||||
SalarySendRangeItem rangeItem =
|
||||
new SalarySendRangeItem(rangeTypeE, targetTypeE, Sets.newHashSet(salarySendRangeObj.getTargetId()));
|
||||
value.put(rangeTypeE, rangeItem);
|
||||
return value;
|
||||
});
|
||||
//已存在时更新
|
||||
indexMap.computeIfPresent(targetTypeE, (k, v) -> {
|
||||
SalarySendRangeItem item = v.get(rangeTypeE);
|
||||
if (null == item) {
|
||||
item = new SalarySendRangeItem(rangeTypeE, targetTypeE, Sets.newHashSet(salarySendRangeObj.getTargetId()));
|
||||
} else {
|
||||
item.getTargetIds().add(salarySendRangeObj.getTargetId());
|
||||
}
|
||||
v.put(rangeTypeE, item);
|
||||
return v;
|
||||
});
|
||||
return true;
|
||||
}
|
||||
|
||||
private Set<Long> getTargetIds(SalarySendRangeTargetTypeEnum targetType, SalarySendRangeTypeEnum rangeType) {
|
||||
Map<SalarySendRangeTypeEnum, SalarySendRangeItem> itemMap = indexMap.get(targetType);
|
||||
if (itemMap != null) {
|
||||
SalarySendRangeItem item = itemMap.getOrDefault(rangeType, EMPTY_ITEM);
|
||||
return item.getTargetIds();
|
||||
}
|
||||
return Collections.emptySet();
|
||||
}
|
||||
|
||||
/**
|
||||
* 判断是否在人员范围内
|
||||
* 如果已经有 所有人 的范围设置,不判断是否有其他范围直接返回
|
||||
*
|
||||
* @param targetType 目标类型
|
||||
* @param targetId 目标id
|
||||
* @return 是否在范围内
|
||||
*/
|
||||
private int doJudgeInRange(SalarySendRangeTargetTypeEnum targetType, Long targetId) {
|
||||
//如果所有人范围已经设置
|
||||
if (isExcludeAll) {
|
||||
return EXCLUDED;
|
||||
}
|
||||
Set<Long> includeTargetIds = getTargetIds(targetType, SalarySendRangeTypeEnum.INCLUDE_OBJ);
|
||||
Set<Long> excludeTargetIds = getTargetIds(targetType, SalarySendRangeTypeEnum.EXCLUDE_OBJ);
|
||||
if (excludeTargetIds.contains(targetId)) {
|
||||
return EXCLUDED;
|
||||
} else if (includeTargetIds.contains(targetId)) {
|
||||
return INCLUDED;
|
||||
} else {
|
||||
//默认值是是否选择所有人
|
||||
return isIncludeAll ? INCLUDED : NOT_IN;
|
||||
}
|
||||
}
|
||||
|
||||
private int doJudgeInRange(SalarySendRangeTargetTypeEnum targetType, Collection<Long> targetIds) {
|
||||
if (CollectionUtils.isEmpty(targetIds)) {
|
||||
return NOT_IN;
|
||||
}
|
||||
//如果所有人范围已经设置
|
||||
if (isExcludeAll) {
|
||||
return EXCLUDED;
|
||||
}
|
||||
if (isIncludeAll) {
|
||||
return INCLUDED;
|
||||
}
|
||||
Set<Long> includeTargetIds = getTargetIds(targetType, SalarySendRangeTypeEnum.INCLUDE_OBJ);
|
||||
Set<Long> excludeTargetIds = getTargetIds(targetType, SalarySendRangeTypeEnum.EXCLUDE_OBJ);
|
||||
if (targetIds.stream().anyMatch(excludeTargetIds::contains)) {
|
||||
return EXCLUDED;
|
||||
} else if (targetIds.stream().anyMatch(includeTargetIds::contains)) {
|
||||
return INCLUDED;
|
||||
} else {
|
||||
return NOT_IN;
|
||||
}
|
||||
}
|
||||
|
||||
public boolean judgeInRange(SalarySendUserInfoDTO dto) {
|
||||
//如果所有人范围已经设置
|
||||
if (isExcludeAll) {
|
||||
return false;
|
||||
}
|
||||
Integer isInRange = NOT_IN;
|
||||
// 默认值为是否选择所有人
|
||||
boolean result = isIncludeAll;
|
||||
for (SalarySendRangeTargetTypeEnum targetType : SalarySendRangeTargetTypeEnum.values()) {
|
||||
switch (targetType) {
|
||||
case DEPT:
|
||||
isInRange = doJudgeInRange(targetType, dto.getDepartmentId());
|
||||
break;
|
||||
case USER:
|
||||
isInRange = doJudgeInRange(targetType, dto.getResourceId());
|
||||
break;
|
||||
case POSITION:
|
||||
isInRange = doJudgeInRange(targetType, dto.getJobTitle());
|
||||
break;
|
||||
// case TAX_AGENT:
|
||||
// isInRange = doJudgeInRange(targetType, dto.getTaxAgentIds());
|
||||
// break;
|
||||
case SUB_COMPANY:
|
||||
isInRange = doJudgeInRange(targetType, dto.getSubCompanyId());
|
||||
break;
|
||||
}
|
||||
if (isInRange.equals(EXCLUDED)) {
|
||||
//如果被排除,返回false
|
||||
return false;
|
||||
} else {
|
||||
// 只要没有被排除,在范围内即为true
|
||||
result |= isInRange.equals(INCLUDED);
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
private static class SalarySendRangeItem {
|
||||
private SalarySendRangeTypeEnum rangeType;
|
||||
|
||||
private SalarySendRangeTargetTypeEnum targetType;
|
||||
|
||||
private Set<Long> targetIds;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,36 @@
|
|||
package com.engine.salary.entity.salaryBill.dto;
|
||||
|
||||
import com.cloudstore.eccom.pc.table.WeaTableType;
|
||||
import com.engine.salary.annotation.SalaryTable;
|
||||
import com.engine.salary.annotation.SalaryTableColumn;
|
||||
import com.engine.salary.annotation.TableTitle;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
|
||||
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@SalaryTable(pageId = "a4fa2487-d36a82d0dc050a5465f1252f9ecaa107",
|
||||
tableType = WeaTableType.CHECKBOX)
|
||||
public class SalarySendRangeListDTO {
|
||||
@JsonSerialize(using = ToStringSerializer.class)
|
||||
@SalaryTableColumn(column = "id", display = false)
|
||||
private Long id;
|
||||
|
||||
private String grantType;
|
||||
|
||||
@SalaryTableColumn(text = "对象", width = "50%", column = "includeObj")
|
||||
@TableTitle(title = "对象", key = "includeObj", dataIndex = "includeObj")
|
||||
private List<SalarySendRangeObjDTO> includeObj;
|
||||
|
||||
@SalaryTableColumn(text = "对象中排除", width = "50%", column = "excludeObj")
|
||||
@TableTitle(title = "对象中排除", key = "excludeObj", dataIndex = "excludeObj")
|
||||
private List<SalarySendRangeObjDTO> excludeObj;
|
||||
}
|
||||
|
|
@ -0,0 +1,44 @@
|
|||
package com.engine.salary.entity.salaryBill.dto;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
|
||||
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* 工资单发放撤回筛选范围对象
|
||||
*/
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
@Builder
|
||||
public class SalarySendRangeObjDTO {
|
||||
|
||||
/**
|
||||
* id
|
||||
*/
|
||||
@JsonSerialize(using = ToStringSerializer.class)
|
||||
private Long targetId;
|
||||
|
||||
/**
|
||||
* 名称
|
||||
*/
|
||||
private String targetName;
|
||||
|
||||
/**
|
||||
* 类型
|
||||
*/
|
||||
private Integer targetType;
|
||||
|
||||
/**
|
||||
* 类型名称
|
||||
*/
|
||||
private String targetTypeName;
|
||||
|
||||
/**
|
||||
* @see com.engine.salary.enums.salarysend.SalarySendRangeTypeEnum
|
||||
*/
|
||||
private Integer rangeType;
|
||||
}
|
||||
|
|
@ -0,0 +1,38 @@
|
|||
package com.engine.salary.entity.salaryBill.dto;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public class SalarySendUserInfoDTO {
|
||||
/**
|
||||
* 岗位
|
||||
*/
|
||||
private Long jobTitle;
|
||||
|
||||
/**
|
||||
* 部门
|
||||
*/
|
||||
private Long departmentId;
|
||||
|
||||
/**
|
||||
* 分部
|
||||
*/
|
||||
private Long subCompanyId;
|
||||
|
||||
|
||||
/**
|
||||
* 人员id
|
||||
*/
|
||||
private Long resourceId;
|
||||
|
||||
/**
|
||||
* 个税扣缴义务人id
|
||||
*/
|
||||
private List<Long> taxAgentIds;
|
||||
}
|
||||
|
|
@ -7,6 +7,7 @@ import lombok.Data;
|
|||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Description: 工资单发放参数
|
||||
|
|
@ -26,6 +27,11 @@ public class SalarySendGrantParam {
|
|||
// @ApiModelProperty("工资单发放Id")
|
||||
private Long salarySendId;
|
||||
|
||||
/**
|
||||
* 工资单发放范围id
|
||||
*/
|
||||
private List<Long> salarySendRangeIds;
|
||||
|
||||
public static String checkParam(SalarySendGrantParam param, Long employeeId, String tenantKey) {
|
||||
if (param.getSalarySendId() == null) {
|
||||
throw new SalaryRunTimeException("工资单发放Id必传");
|
||||
|
|
|
|||
|
|
@ -58,6 +58,12 @@ public class SalarySendInfoQueryParam extends BaseQueryParam {
|
|||
// @ApiModelProperty("发送状态")
|
||||
private SalarySendStatusEnum sendStatus;
|
||||
|
||||
/**
|
||||
* true= [已发送]
|
||||
* false= [未发送,已撤回]
|
||||
*/
|
||||
private Boolean isGranted;
|
||||
|
||||
/**
|
||||
* 发送状态
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -0,0 +1,30 @@
|
|||
package com.engine.salary.entity.salaryBill.param;
|
||||
|
||||
import com.engine.salary.common.BaseQueryParam;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
//@ApiModel("工资单发放范围查询参数")
|
||||
public class SalarySendRangeQueryParam extends BaseQueryParam {
|
||||
/**
|
||||
* 发放类型
|
||||
* @see com.engine.salary.enums.salarysend.SalarySendGrantTypeEnum
|
||||
*/
|
||||
private String grantType;
|
||||
|
||||
/**
|
||||
* 发放单id
|
||||
*/
|
||||
private Long salarySendId;
|
||||
|
||||
/**
|
||||
* 对象名称关键字
|
||||
*/
|
||||
private String targetName;
|
||||
}
|
||||
|
|
@ -0,0 +1,122 @@
|
|||
package com.engine.salary.entity.salaryBill.param;
|
||||
|
||||
import com.alibaba.nacos.client.naming.utils.CollectionUtils;
|
||||
import com.engine.salary.entity.salaryBill.po.SalarySendRangeObj;
|
||||
import com.engine.salary.entity.salaryBill.po.SalarySendRangePO;
|
||||
import com.engine.salary.enums.salarysend.SalarySendGrantTypeEnum;
|
||||
import com.engine.salary.enums.salarysend.SalarySendRangeTypeEnum;
|
||||
import com.engine.salary.exception.SalaryRunTimeException;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
import weaver.hrm.User;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import static com.engine.salary.constant.SalaryDefaultTenantConstant.DEFAULT_TENANT_KEY;
|
||||
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
public class SalarySendRangeSaveParam {
|
||||
/**
|
||||
* 发放id
|
||||
*/
|
||||
private Long salarySendId;
|
||||
|
||||
|
||||
/**
|
||||
* 发放范围id
|
||||
*/
|
||||
private Long salarySendRangeId;
|
||||
|
||||
|
||||
/**
|
||||
* 发放/撤回
|
||||
*
|
||||
* @see SalarySendGrantTypeEnum
|
||||
*/
|
||||
private String grantType;
|
||||
|
||||
|
||||
private List<SalarySendRangeTargetParam> includeObjParams;
|
||||
|
||||
|
||||
private List<SalarySendRangeTargetParam> excludeObjParams;
|
||||
|
||||
public static void checkParam(SalarySendRangeSaveParam saveParam, Long employeeId, String tenantKey) {
|
||||
if (saveParam.getSalarySendId() == null) {
|
||||
throw new SalaryRunTimeException("工资单发放id不能为空");
|
||||
}
|
||||
|
||||
if (saveParam.getGrantType() == null) {
|
||||
throw new SalaryRunTimeException("操作类型不能为空");
|
||||
}
|
||||
|
||||
if (CollectionUtils.isEmpty(saveParam.getIncludeObjParams())) {
|
||||
throw new SalaryRunTimeException("对象不能为空");
|
||||
}
|
||||
}
|
||||
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
public static class SalarySendRangeTargetParam {
|
||||
|
||||
/**
|
||||
* 对象不能为空
|
||||
*/
|
||||
private Long targetId;
|
||||
|
||||
/**
|
||||
* 对象类型不能为空
|
||||
* @see com.engine.salary.enums.salarysend.SalarySendRangeTargetTypeEnum
|
||||
*/
|
||||
private Integer targetType;
|
||||
}
|
||||
|
||||
public SalarySendRangePO toSalarySendRangePO(User user) {
|
||||
return SalarySendRangePO.builder()
|
||||
.id(salarySendRangeId)
|
||||
.grantType(grantType)
|
||||
.salarySendId(salarySendId)
|
||||
.updateTime(new Date())
|
||||
.creator((long) user.getUID())
|
||||
.deleteType(0)
|
||||
.tenantKey(DEFAULT_TENANT_KEY)
|
||||
.createTime(salarySendId == null ? new Date() : null)
|
||||
.build();
|
||||
}
|
||||
|
||||
public List<SalarySendRangeObj> toSalarySendRangeObj(User user) {
|
||||
List<SalarySendRangeObj> includeObjs = includeObjParams.stream()
|
||||
.map(obj -> mapObj(user, obj))
|
||||
.map(obj->obj.setRangeType(SalarySendRangeTypeEnum.INCLUDE_OBJ.getValue()))
|
||||
.collect(Collectors.toList());
|
||||
List<SalarySendRangeObj> excludeObjs = excludeObjParams.stream()
|
||||
.map(obj -> mapObj(user, obj))
|
||||
.map(obj -> obj.setRangeType(SalarySendRangeTypeEnum.EXCLUDE_OBJ.getValue()))
|
||||
.collect(Collectors.toList());
|
||||
List<SalarySendRangeObj> rangeObjs = new ArrayList<>();
|
||||
rangeObjs.addAll(includeObjs);
|
||||
rangeObjs.addAll(excludeObjs);
|
||||
return rangeObjs;
|
||||
}
|
||||
|
||||
private SalarySendRangeObj mapObj(User user, SalarySendRangeTargetParam obj) {
|
||||
return SalarySendRangeObj.builder()
|
||||
.salarySendRangeId(salarySendRangeId)
|
||||
.salarySendId(salarySendId)
|
||||
.targetId(obj.getTargetId())
|
||||
.targetType(obj.getTargetType())
|
||||
.deleteType(0)
|
||||
.tenantKey(DEFAULT_TENANT_KEY)
|
||||
.updateTime(new Date())
|
||||
.createTime(new Date())
|
||||
.creator((long) user.getUID())
|
||||
.build();
|
||||
}
|
||||
}
|
||||
|
|
@ -7,6 +7,7 @@ import lombok.Data;
|
|||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Description: 工资单撤回参数
|
||||
|
|
@ -26,6 +27,8 @@ public class SalarySendWithdrawParam {
|
|||
// @ApiModelProperty("工资单发放Id")
|
||||
private Long salarySendId;
|
||||
|
||||
private List<Long> salarySendRangeIds;
|
||||
|
||||
public static String checkParam(SalarySendWithdrawParam param, Long employeeId, String tenantKey) {
|
||||
if (param.getSalarySendId() == null) {
|
||||
throw new SalaryRunTimeException("工资单发放Id必传");
|
||||
|
|
|
|||
|
|
@ -0,0 +1,71 @@
|
|||
package com.engine.salary.entity.salaryBill.po;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 工资单发放范围项目表
|
||||
*/
|
||||
@Data
|
||||
@Builder
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
@Accessors(chain = true)
|
||||
public class SalarySendRangeObj {
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 发放id
|
||||
*/
|
||||
private Long salarySendId;
|
||||
|
||||
private Long salarySendRangeId;
|
||||
|
||||
/**
|
||||
* 范围类型;对象=1;对象中排除=2
|
||||
*/
|
||||
private Integer rangeType;
|
||||
|
||||
/**
|
||||
* 目标类型,人员=1,部门=2,分部=3,岗位=4,个税扣缴义务人=5,所有人=0
|
||||
*/
|
||||
private Integer targetType;
|
||||
|
||||
/**
|
||||
* 目标id
|
||||
*/
|
||||
private Long targetId;
|
||||
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
private Long creator;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
private Date createTime;
|
||||
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
private Date updateTime;
|
||||
|
||||
/**
|
||||
* 是否已删除。0:未删除、1:已删除
|
||||
*/
|
||||
private Integer deleteType;
|
||||
|
||||
/**
|
||||
* 租户ID
|
||||
*/
|
||||
private String tenantKey;
|
||||
}
|
||||
|
|
@ -0,0 +1,57 @@
|
|||
package com.engine.salary.entity.salaryBill.po;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 工资单发放范围表
|
||||
*/
|
||||
@Data
|
||||
@Builder
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
public class SalarySendRangePO {
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 发放id
|
||||
*/
|
||||
private Long salarySendId;
|
||||
|
||||
/**
|
||||
* 发放=grant;撤回=withdraw
|
||||
*/
|
||||
private String grantType;
|
||||
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
private Long creator;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
private Date createTime;
|
||||
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
private Date updateTime;
|
||||
|
||||
/**
|
||||
* 是否已删除。0:未删除、1:已删除
|
||||
*/
|
||||
private Integer deleteType;
|
||||
|
||||
/**
|
||||
* 租户ID
|
||||
*/
|
||||
private String tenantKey;
|
||||
}
|
||||
|
|
@ -1,5 +1,6 @@
|
|||
package com.engine.salary.entity.salaryacct.po;
|
||||
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -61,6 +62,7 @@ public class ExcelAcctResultPO {
|
|||
/**
|
||||
* 计算后的值
|
||||
*/
|
||||
@Encrypt
|
||||
private String resultValue;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -34,6 +34,7 @@ public class SalaryAcctEmployeePO {
|
|||
/**
|
||||
* 薪资核算的id
|
||||
*/
|
||||
@SalaryFormulaVar(defaultLabel = "核算记录id", labelId = 86321, dataType = "number")
|
||||
private Long salaryAcctRecordId;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package com.engine.salary.entity.salaryacct.po;
|
||||
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -61,6 +62,7 @@ public class SalaryAcctResultPO {
|
|||
/**
|
||||
* 计算后的值
|
||||
*/
|
||||
@Encrypt
|
||||
private String resultValue;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -80,6 +80,8 @@ public class SalaryArchiveBO {
|
|||
columns.add(new WeaTableColumn("100px", SalaryI18nUtil.getI18nLabel(86187, "员工状态"), "employeeStatus"));
|
||||
columns.add(new WeaTableColumn("100px", SalaryI18nUtil.getI18nLabel(86187, "起始发薪日期"), "payStartDate"));
|
||||
columns.add(new WeaTableColumn("100px", SalaryI18nUtil.getI18nLabel(86187, "最后发薪日期"), "payEndDate"));
|
||||
columns.add(new WeaTableColumn("100px", SalaryI18nUtil.getI18nLabel(86187, "入职日期"), "companystartdate").setDisplay(WeaBoolAttr.FALSE));
|
||||
columns.add(new WeaTableColumn("100px", SalaryI18nUtil.getI18nLabel(86187, "离职日期"), "dismissdate").setDisplay(WeaBoolAttr.FALSE));
|
||||
for (SalaryItemPO salaryItem : salaryItems) {
|
||||
columns.add(new WeaTableColumn("100px", salaryItem.getName(), salaryItem.getId() + SalaryItemConstant.DYNAMIC_SUFFIX));
|
||||
}
|
||||
|
|
@ -219,7 +221,7 @@ public class SalaryArchiveBO {
|
|||
if (fromDateItem.after(endTempItem) || endTempItem.before(startItem)) {
|
||||
continue;
|
||||
}
|
||||
if ( endTempItem.equals(startItem) && flag == true) {
|
||||
if ( endTempItem.equals(startItem) && flag) {
|
||||
continue;
|
||||
}
|
||||
SalaryArchiveItemDataDTO salaryArchiveItemData = new SalaryArchiveItemDataDTO();
|
||||
|
|
|
|||
|
|
@ -13,10 +13,15 @@ import com.engine.salary.entity.salaryarchive.po.SalaryArchiveItemPO;
|
|||
import com.engine.salary.entity.salaryarchive.po.SalaryArchivePO;
|
||||
import com.engine.salary.entity.salaryitem.po.SalaryItemPO;
|
||||
import com.engine.salary.entity.taxagent.dto.TaxAgentManageRangeEmployeeDTO;
|
||||
import com.engine.salary.entity.taxagent.param.TaxAgentManageRangeSaveParam;
|
||||
import com.engine.salary.entity.taxagent.param.TaxAgentRangeSaveParam;
|
||||
import com.engine.salary.enums.UserStatusEnum;
|
||||
import com.engine.salary.enums.salaryarchive.*;
|
||||
import com.engine.salary.enums.salarysob.TargetTypeEnum;
|
||||
import com.engine.salary.service.SalaryEmployeeService;
|
||||
import com.engine.salary.service.TaxAgentManageRangeService;
|
||||
import com.engine.salary.service.impl.SalaryEmployeeServiceImpl;
|
||||
import com.engine.salary.service.impl.TaxAgentManageRangeServiceImpl;
|
||||
import com.engine.salary.util.SalaryDateUtil;
|
||||
import com.engine.salary.util.SalaryI18nUtil;
|
||||
import com.engine.salary.util.excel.ExcelComment;
|
||||
|
|
@ -46,6 +51,10 @@ public class SalaryArchiveExcelBO extends Service {
|
|||
return ServiceUtil.getService(SalaryEmployeeServiceImpl.class, user);
|
||||
}
|
||||
|
||||
public TaxAgentManageRangeService getTaxAgentManageRangeService() {
|
||||
return ServiceUtil.getService(TaxAgentManageRangeServiceImpl.class, user);
|
||||
}
|
||||
|
||||
public static String userNameI18n;
|
||||
public static String departmentI18n;
|
||||
public static String jobNumI18n;
|
||||
|
|
@ -180,7 +189,10 @@ public class SalaryArchiveExcelBO extends Service {
|
|||
|
||||
List<String> mustHeaders = Lists.newArrayList();
|
||||
|
||||
mustHeaders.add(userNameI18n);
|
||||
if (!importHandleParam.isProcess()) {
|
||||
//流程中可以使用人员id
|
||||
mustHeaders.add(userNameI18n);
|
||||
}
|
||||
mustHeaders.add(taxAgentI18n);
|
||||
// mustHeaders.add(incomeCategoryI18n);
|
||||
// mustHeaders.add(salarySobI18n);
|
||||
|
|
@ -339,6 +351,9 @@ public class SalaryArchiveExcelBO extends Service {
|
|||
* @return
|
||||
*/
|
||||
public static boolean singleRowCheck(List<String> allTodoSalaryArchives, Map<String, Object> map, List<String> headers, int effectiveTimeIndex, List<Map<String, String>> excelComments, int errorCount, SalaryArchiveImportHandleParam importHandleParam) {
|
||||
//是否是流程
|
||||
boolean process = importHandleParam.isProcess();
|
||||
|
||||
boolean isError = false;
|
||||
String rowindex = "第" + map.get("index") + "行";
|
||||
// 1.姓名
|
||||
|
|
@ -369,7 +384,7 @@ public class SalaryArchiveExcelBO extends Service {
|
|||
}
|
||||
Long employeeId = CollectionUtils.isNotEmpty(employeeSameIds) && employeeSameIds.size() == 1 && employeeSameIds.get(0) > 0 ? employeeSameIds.get(0) : null;
|
||||
|
||||
//员工id 流程定薪使用
|
||||
//员工id 流程使用
|
||||
String empId = Optional.ofNullable(map.get("员工id")).orElse("").toString();
|
||||
if (StringUtils.isNotBlank(empId)) {
|
||||
employeeSameIds.clear();
|
||||
|
|
@ -377,6 +392,14 @@ public class SalaryArchiveExcelBO extends Service {
|
|||
employeeId = Long.valueOf(empId);
|
||||
}
|
||||
|
||||
if (employeeId == null) {
|
||||
Map<String, String> errorMessageMap = Maps.newHashMap();
|
||||
errorMessageMap.put("message", rowindex + "人员存在重复数据,请确定姓名、部门、手机号唯一");
|
||||
excelComments.add(errorMessageMap);
|
||||
isError = true;
|
||||
return isError;
|
||||
}
|
||||
|
||||
|
||||
// 用于初始化导入数据校验
|
||||
map.put("employeeId", employeeId);
|
||||
|
|
@ -408,12 +431,27 @@ public class SalaryArchiveExcelBO extends Service {
|
|||
}
|
||||
Optional<TaxAgentManageRangeEmployeeDTO.TaxAgentEmployee> optionalTaxAgentEmp = optionalTaxAgent.get().getEmployeeList().stream().filter(f -> finalEmployeeSameIds.contains(f.getEmployeeId())).findFirst();
|
||||
if (!optionalTaxAgentEmp.isPresent()) {
|
||||
Map<String, String> errorMessageMap = Maps.newHashMap();
|
||||
errorMessageMap.put("message", rowindex + taxAgentRangeMsg);
|
||||
excelComments.add(errorMessageMap);
|
||||
if (process) {
|
||||
//定薪流程中自动将人员添加进个税扣缴义务人中
|
||||
TaxAgentManageRangeSaveParam.TaxAgentSubAdminRangeTargetParam taxAgentSubAdminRangeTargetParam = new TaxAgentManageRangeSaveParam.TaxAgentSubAdminRangeTargetParam();
|
||||
taxAgentSubAdminRangeTargetParam.setTargetId(employeeId);
|
||||
taxAgentSubAdminRangeTargetParam.setTargetType(TargetTypeEnum.EMPLOYEE);
|
||||
|
||||
TaxAgentRangeSaveParam taxAgentRangeSaveParam = new TaxAgentRangeSaveParam();
|
||||
taxAgentRangeSaveParam.setTaxAgentId(taxAgentId);
|
||||
taxAgentRangeSaveParam.setIncludeType(1);
|
||||
taxAgentRangeSaveParam.setEmployeeStatus(Arrays.asList("0", "1", "2", "3", "4", "5", "6"));
|
||||
taxAgentRangeSaveParam.setTargetParams(Collections.singletonList(taxAgentSubAdminRangeTargetParam));
|
||||
taxAgentRangeSaveParam.setSync(true);
|
||||
importHandleParam.setTaxAgentRanges(Collections.singletonList(taxAgentRangeSaveParam));
|
||||
} else {
|
||||
Map<String, String> errorMessageMap = Maps.newHashMap();
|
||||
errorMessageMap.put("message", rowindex + taxAgentRangeMsg);
|
||||
excelComments.add(errorMessageMap);
|
||||
// SalaryArchiveExcelBO.createExcelComment(excelComments, taxAgentRangeMsg, errorCount + 1, errorCount + 1, 0, 0);
|
||||
isError = true;
|
||||
return isError;
|
||||
isError = true;
|
||||
return isError;
|
||||
}
|
||||
} else {
|
||||
employeeId = optionalTaxAgentEmp.get().getEmployeeId();
|
||||
// 除了定薪中的初始化,其他导入存在相同的取第一条
|
||||
|
|
@ -474,7 +512,7 @@ public class SalaryArchiveExcelBO extends Service {
|
|||
|
||||
// 必填判空
|
||||
boolean isEmpty = StringUtils.isEmpty(cellVal) &&
|
||||
(userNameI18n.equals(key.toString()) || taxAgentI18n.equals(key.toString()) || incomeCategoryI18n.equals(key.toString()) || salarySobI18n.equals(key.toString())
|
||||
((userNameI18n.equals(key.toString()) && !process) || taxAgentI18n.equals(key.toString()) || incomeCategoryI18n.equals(key.toString()) || salarySobI18n.equals(key.toString())
|
||||
// 定薪列表初始化导入必填: 起始发薪日期、生效日期
|
||||
|| ((payStartDateI18n.equals(key.toString()) || effectiveTimeI18n.equals(key.toString())) && importHandleParam.isInit())
|
||||
// 定薪列表调薪必填: 调整原因、生效日期
|
||||
|
|
|
|||
|
|
@ -67,6 +67,16 @@ public class SalaryArchiveListDTO {
|
|||
@TableTitle(title = "电话", dataIndex = "mobile", key = "mobile")
|
||||
private String mobile;
|
||||
|
||||
/**
|
||||
* 入职日期
|
||||
*/
|
||||
private String companystartdate;
|
||||
|
||||
/**
|
||||
* 离职日期
|
||||
*/
|
||||
private String dismissdate;
|
||||
|
||||
/**
|
||||
* 工号
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package com.engine.salary.entity.salaryarchive.dto;
|
||||
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import com.engine.salary.annotation.TableTitle;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.fasterxml.jackson.annotation.JsonIgnore;
|
||||
|
|
@ -50,9 +51,11 @@ public class SalaryItemAdjustRecordListDTO {
|
|||
private String adjustItem;
|
||||
|
||||
@TableTitle(title = "调整前", dataIndex = "adjustBefore", key = "adjustBefore")
|
||||
@Encrypt
|
||||
private String adjustBefore;
|
||||
|
||||
@TableTitle(title = "调整后", dataIndex = "adjustAfter", key = "adjustAfter")
|
||||
@Encrypt
|
||||
private String adjustAfter;
|
||||
|
||||
@TableTitle(title = "调整原因", dataIndex = "adjustReason", key = "adjustReason")
|
||||
|
|
|
|||
|
|
@ -5,7 +5,9 @@ import com.engine.salary.entity.salaryarchive.po.SalaryArchiveItemPO;
|
|||
import com.engine.salary.entity.salaryarchive.po.SalaryArchivePO;
|
||||
import com.engine.salary.entity.salaryitem.po.SalaryItemPO;
|
||||
import com.engine.salary.entity.taxagent.dto.TaxAgentManageRangeEmployeeDTO;
|
||||
import com.engine.salary.entity.taxagent.param.TaxAgentRangeSaveParam;
|
||||
import com.engine.salary.enums.salaryarchive.SalaryArchiveImportTypeEnum;
|
||||
import com.engine.salary.enums.salaryarchive.SalaryArchiveListTypeEnum;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -43,6 +45,11 @@ public class SalaryArchiveImportHandleParam {
|
|||
* @see SalaryArchiveImportTypeEnum
|
||||
*/
|
||||
String importType;
|
||||
|
||||
/**
|
||||
* 列表类型
|
||||
* @see SalaryArchiveListTypeEnum
|
||||
*/
|
||||
String listType;
|
||||
|
||||
/**
|
||||
|
|
@ -50,6 +57,11 @@ public class SalaryArchiveImportHandleParam {
|
|||
*/
|
||||
boolean onlyCheck;
|
||||
|
||||
/**
|
||||
* 是否是流程
|
||||
*/
|
||||
boolean isProcess;
|
||||
|
||||
//*****************************************************************/
|
||||
|
||||
Long currentEmployeeId;
|
||||
|
|
@ -134,6 +146,11 @@ public class SalaryArchiveImportHandleParam {
|
|||
*/
|
||||
List<Long> salaryArchiveItemDelSalaryItemIds;
|
||||
|
||||
/**
|
||||
* 待生成的人员范围
|
||||
*/
|
||||
List<TaxAgentRangeSaveParam> taxAgentRanges;
|
||||
|
||||
/**
|
||||
* 薪资账套
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package com.engine.salary.entity.salaryarchive.po;
|
||||
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -56,6 +57,7 @@ public class SalaryArchiveItemPO {
|
|||
/**
|
||||
* 薪资项目值
|
||||
*/
|
||||
@Encrypt
|
||||
private String itemValue;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -107,6 +107,7 @@ public class SalarySobItemAggregateBO {
|
|||
.salaryItemGroupId(k)
|
||||
.salaryItemId(salaryItemPO.getId())
|
||||
.dateType(salaryItemPO.getDataType())
|
||||
.valueType(salaryItemPO.getValueType())
|
||||
.name(salaryItemPO.getName())
|
||||
.itemHide(salarySobItemPO.getItemHide())
|
||||
.formulaId(salarySobItemPO.getFormulaId())
|
||||
|
|
|
|||
|
|
@ -49,9 +49,9 @@ public class SalarySobRangeSaveParam {
|
|||
private Long targetId;
|
||||
|
||||
// 安全级别最小值
|
||||
private Long minSecLevel;
|
||||
// private Long minSecLevel;
|
||||
|
||||
// 安全级别最大值
|
||||
private Long maxSecLevel;
|
||||
// private Long maxSecLevel;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,97 @@
|
|||
package com.engine.salary.entity.siaccount.dto;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @Author: sy
|
||||
* @Description: 福利台账-调差
|
||||
* @Date: 2022/11/23
|
||||
**/
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
public class InsuranceCompensationDTO {
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 前端自定义id
|
||||
*/
|
||||
private String originId;
|
||||
|
||||
/**
|
||||
* 只读,true为实际调差记录,false为调差配置数据(非实际调差记录)
|
||||
*
|
||||
*/
|
||||
private Boolean status;
|
||||
|
||||
/**
|
||||
* 缴纳组织
|
||||
*/
|
||||
private Long paymentOrganization;
|
||||
|
||||
/**
|
||||
* 员工id
|
||||
*/
|
||||
private Long employeeId;
|
||||
|
||||
/**
|
||||
* 统计调差福利
|
||||
*/
|
||||
private Integer welfareType;
|
||||
|
||||
/**
|
||||
* 统计调差福利类型
|
||||
*/
|
||||
private String categoryType;
|
||||
|
||||
/**
|
||||
* 统计调差福利类型选项
|
||||
*/
|
||||
private List<Map<String,String>> categoryTypeOptions;
|
||||
|
||||
/**
|
||||
* 国家核算金额
|
||||
*/
|
||||
private String countryTotal;
|
||||
|
||||
/**
|
||||
* 公司核算金额
|
||||
*/
|
||||
private String companyTotal;
|
||||
|
||||
/**
|
||||
* 应调差额
|
||||
*/
|
||||
private String adjustmentTotal;
|
||||
|
||||
/**
|
||||
* 调差到
|
||||
*/
|
||||
private Long adjustTo;
|
||||
|
||||
/**
|
||||
* 对象
|
||||
*/
|
||||
private Long target;
|
||||
|
||||
/**
|
||||
* 对象选项
|
||||
*/
|
||||
private Map<String,String> targetOptions;
|
||||
|
||||
/**
|
||||
* 账单月份
|
||||
*/
|
||||
private String billMonth;
|
||||
}
|
||||
|
|
@ -0,0 +1,48 @@
|
|||
package com.engine.salary.entity.siaccount.param;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* @Author: sy
|
||||
* @Description: 福利台账-调差请求参数
|
||||
* @Date: 2022/11/23
|
||||
**/
|
||||
@Data
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Builder
|
||||
public class CompensationParam {
|
||||
|
||||
/**
|
||||
* 缴纳组织
|
||||
*/
|
||||
private Long paymentOrganization;
|
||||
|
||||
/**
|
||||
* 对象,指InsuranceAccountDetailPO.id
|
||||
*/
|
||||
private Long target;
|
||||
|
||||
/**
|
||||
* 指被调差的人员id
|
||||
*/
|
||||
private String employeeId;
|
||||
|
||||
/**
|
||||
* 账单月份
|
||||
*/
|
||||
private String billMonth;
|
||||
|
||||
/**
|
||||
* 统计调差福利
|
||||
*/
|
||||
private Integer welfareType;
|
||||
|
||||
/**
|
||||
* 统计调差福利项,即社保、公积金、其他福利类型下的具体项目
|
||||
*/
|
||||
private String categoryType;
|
||||
}
|
||||
|
|
@ -1,5 +1,6 @@
|
|||
package com.engine.salary.entity.siaccount.po;
|
||||
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -97,6 +98,7 @@ public class ExcelInsuranceDetailPO {
|
|||
/**
|
||||
* 社保缴纳基数
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialPaymentBaseString;
|
||||
|
||||
/**
|
||||
|
|
@ -107,6 +109,7 @@ public class ExcelInsuranceDetailPO {
|
|||
/**
|
||||
* 公积金缴纳基数
|
||||
*/
|
||||
@Encrypt
|
||||
private String fundPaymentBaseString;
|
||||
|
||||
/**
|
||||
|
|
@ -117,51 +120,61 @@ public class ExcelInsuranceDetailPO {
|
|||
/**
|
||||
* 其他福利缴纳基数
|
||||
*/
|
||||
@Encrypt
|
||||
private String otherPaymentBaseString;
|
||||
|
||||
/**
|
||||
* 社保个人缴费明细
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialPerJson;
|
||||
|
||||
/**
|
||||
* 社保个人合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialPerSum;
|
||||
|
||||
/**
|
||||
* 公积金个人缴费明细
|
||||
*/
|
||||
@Encrypt
|
||||
private String fundPerJson;
|
||||
|
||||
/**
|
||||
* 公积金个人合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String fundPerSum;
|
||||
|
||||
/**
|
||||
* 其他福利个人缴费明细
|
||||
*/
|
||||
@Encrypt
|
||||
private String otherPerJson;
|
||||
|
||||
/**
|
||||
* 其他福利个人合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String otherPerSum;
|
||||
|
||||
/**
|
||||
* 个人合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String perSum;
|
||||
|
||||
/**
|
||||
* 社保单位缴费明细
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialComJson;
|
||||
|
||||
/**
|
||||
* 社保单位合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialComSum;
|
||||
|
||||
/**
|
||||
|
|
@ -187,26 +200,31 @@ public class ExcelInsuranceDetailPO {
|
|||
/**
|
||||
* 单位合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String comSum;
|
||||
|
||||
/**
|
||||
* 社保合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialSum;
|
||||
|
||||
/**
|
||||
* 公积金合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String fundSum;
|
||||
|
||||
/**
|
||||
* 其他福利合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String otherSum;
|
||||
|
||||
/**
|
||||
* 合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String total;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package com.engine.salary.entity.siaccount.po;
|
||||
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -54,16 +55,19 @@ public class InsuranceAccountBatchPO {
|
|||
/**
|
||||
* 社保缴费总额(单位+个人)
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialPay;
|
||||
|
||||
/**
|
||||
* 公积金缴费总额(单位+个人)
|
||||
*/
|
||||
@Encrypt
|
||||
private String fundPay;
|
||||
|
||||
/**
|
||||
* 其他福利缴费总额(单位+个人)
|
||||
*/
|
||||
@Encrypt
|
||||
private String otherPay;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
package com.engine.salary.entity.siaccount.po;
|
||||
|
||||
import com.cloudstore.eccom.pc.table.WeaTableType;
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import com.engine.salary.annotation.SalaryTable;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
|
|
@ -102,6 +103,7 @@ public class InsuranceAccountDetailPO {
|
|||
/**
|
||||
* 社保缴纳基数
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialPaymentBaseString;
|
||||
|
||||
/**
|
||||
|
|
@ -112,6 +114,7 @@ public class InsuranceAccountDetailPO {
|
|||
/**
|
||||
* 公积金缴纳基数
|
||||
*/
|
||||
@Encrypt
|
||||
private String fundPaymentBaseString;
|
||||
|
||||
/**
|
||||
|
|
@ -122,51 +125,61 @@ public class InsuranceAccountDetailPO {
|
|||
/**
|
||||
* 其他福利缴纳基数
|
||||
*/
|
||||
@Encrypt
|
||||
private String otherPaymentBaseString;
|
||||
|
||||
/**
|
||||
* 社保个人缴费明细
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialPerJson;
|
||||
|
||||
/**
|
||||
* 社保个人合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialPerSum;
|
||||
|
||||
/**
|
||||
* 公积金个人缴费明细
|
||||
*/
|
||||
@Encrypt
|
||||
private String fundPerJson;
|
||||
|
||||
/**
|
||||
* 公积金个人合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String fundPerSum;
|
||||
|
||||
/**
|
||||
* 其他福利个人缴费明细
|
||||
*/
|
||||
@Encrypt
|
||||
private String otherPerJson;
|
||||
|
||||
/**
|
||||
* 其他福利个人合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String otherPerSum;
|
||||
|
||||
/**
|
||||
* 个人合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String perSum;
|
||||
|
||||
/**
|
||||
* 社保单位缴费明细
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialComJson;
|
||||
|
||||
/**
|
||||
* 社保单位合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialComSum;
|
||||
|
||||
/**
|
||||
|
|
@ -192,26 +205,31 @@ public class InsuranceAccountDetailPO {
|
|||
/**
|
||||
* 单位合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String comSum;
|
||||
|
||||
/**
|
||||
* 社保合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialSum;
|
||||
|
||||
/**
|
||||
* 公积金合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String fundSum;
|
||||
|
||||
/**
|
||||
* 其他福利合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String otherSum;
|
||||
|
||||
/**
|
||||
* 合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String total;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package com.engine.salary.entity.siaccount.po;
|
||||
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -98,6 +99,7 @@ public class InsuranceAccountDetailTempPO {
|
|||
/**
|
||||
* 社保缴纳基数
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialPaymentBaseString;
|
||||
|
||||
/**
|
||||
|
|
@ -108,6 +110,7 @@ public class InsuranceAccountDetailTempPO {
|
|||
/**
|
||||
* 公积金缴纳基数
|
||||
*/
|
||||
@Encrypt
|
||||
private String fundPaymentBaseString;
|
||||
|
||||
/**
|
||||
|
|
@ -118,51 +121,61 @@ public class InsuranceAccountDetailTempPO {
|
|||
/**
|
||||
* 其他福利缴纳基数
|
||||
*/
|
||||
@Encrypt
|
||||
private String otherPaymentBaseString;
|
||||
|
||||
/**
|
||||
* 社保个人缴费明细
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialPerJson;
|
||||
|
||||
/**
|
||||
* 社保个人合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialPerSum;
|
||||
|
||||
/**
|
||||
* 公积金个人缴费明细
|
||||
*/
|
||||
@Encrypt
|
||||
private String fundPerJson;
|
||||
|
||||
/**
|
||||
* 公积金个人合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String fundPerSum;
|
||||
|
||||
/**
|
||||
* 其他福利个人缴费明细
|
||||
*/
|
||||
@Encrypt
|
||||
private String otherPerJson;
|
||||
|
||||
/**
|
||||
* 其他福利个人合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String otherPerSum;
|
||||
|
||||
/**
|
||||
* 个人合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String perSum;
|
||||
|
||||
/**
|
||||
* 社保单位缴费明细
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialComJson;
|
||||
|
||||
/**
|
||||
* 社保单位合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialComSum;
|
||||
|
||||
/**
|
||||
|
|
@ -188,26 +201,31 @@ public class InsuranceAccountDetailTempPO {
|
|||
/**
|
||||
* 单位合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String comSum;
|
||||
|
||||
/**
|
||||
* 社保合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialSum;
|
||||
|
||||
/**
|
||||
* 公积金合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String fundSum;
|
||||
|
||||
/**
|
||||
* 其他福利合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String otherSum;
|
||||
|
||||
/**
|
||||
* 合计
|
||||
*/
|
||||
@Encrypt
|
||||
private String total;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -0,0 +1,80 @@
|
|||
package com.engine.salary.entity.siaccount.po;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @Author: sy
|
||||
* @Description: 社保福利台账-调差配置表
|
||||
* @Date: 2022/11/28
|
||||
**/
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
//hrsa_compensation_config
|
||||
public class InsuranceCompensationConfigPO {
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 缴纳组织
|
||||
*/
|
||||
private Long paymentAgency;
|
||||
|
||||
/**
|
||||
* 个税扣缴义务人
|
||||
*/
|
||||
private Long paymentOrganization;
|
||||
|
||||
/**
|
||||
* 创建人id
|
||||
*/
|
||||
private Long creator;
|
||||
|
||||
/**
|
||||
* 是否删除
|
||||
*/
|
||||
private Integer deleteType;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
private Date createTime;
|
||||
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
private Date updateTime;
|
||||
|
||||
/**
|
||||
* 租户key
|
||||
*/
|
||||
private String tenantKey;
|
||||
|
||||
/**
|
||||
* 统计调差福利
|
||||
*/
|
||||
private Integer welfareType;
|
||||
|
||||
/**
|
||||
* 统计调差福利类型
|
||||
*/
|
||||
private String categoryType;
|
||||
|
||||
/**
|
||||
* 调差到
|
||||
*/
|
||||
private Long adjustTo;
|
||||
|
||||
/**
|
||||
* 员工id
|
||||
*/
|
||||
private Long employeeId;
|
||||
}
|
||||
|
|
@ -0,0 +1,106 @@
|
|||
package com.engine.salary.entity.siaccount.po;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @Author: sy
|
||||
* @Description: 社保福利台账-调差历史记录表
|
||||
* @Date: 2022/11/23
|
||||
**/
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
//hrsa_compensation_log
|
||||
public class InsuranceCompensationPO {
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 缴纳组织
|
||||
*/
|
||||
private Long paymentAgency;
|
||||
|
||||
/**
|
||||
* 个税扣缴义务人
|
||||
*/
|
||||
private Long paymentOrganization;
|
||||
|
||||
/**
|
||||
* 创建人id
|
||||
*/
|
||||
private Long creator;
|
||||
|
||||
/**
|
||||
* 是否删除
|
||||
*/
|
||||
private Integer deleteType;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
private Date createTime;
|
||||
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
private Date updateTime;
|
||||
|
||||
/**
|
||||
* 租户key
|
||||
*/
|
||||
private String tenantKey;
|
||||
|
||||
/**
|
||||
* 员工id
|
||||
*/
|
||||
private Long employeeId;
|
||||
|
||||
/**
|
||||
* 统计调差福利
|
||||
*/
|
||||
private Integer welfareType;
|
||||
|
||||
/**
|
||||
* 统计调差福利类型
|
||||
*/
|
||||
private String categoryType;
|
||||
|
||||
/**
|
||||
* 国家核算金额
|
||||
*/
|
||||
private String countryTotal;
|
||||
|
||||
/**
|
||||
* 公司核算金额
|
||||
*/
|
||||
private String companyTotal;
|
||||
|
||||
/**
|
||||
* 应调差额
|
||||
*/
|
||||
private String adjustmentTotal;
|
||||
|
||||
/**
|
||||
* 调差到
|
||||
*/
|
||||
private Long adjustTo;
|
||||
|
||||
/**
|
||||
* 账单月份
|
||||
*/
|
||||
private String billMonth;
|
||||
|
||||
//---------条件-------
|
||||
private Collection<Long> ids;
|
||||
private Collection<Long> employeeIds;
|
||||
}
|
||||
|
|
@ -34,6 +34,7 @@ public class InsuranceArchivesListParam extends BaseQueryParam {
|
|||
private List<BigDecimal> subcompanyIds;
|
||||
|
||||
private String departmentIdsStr;
|
||||
private String subcompanyIdsStr;
|
||||
|
||||
//状态(多线)")
|
||||
private List<String> statuses;
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package com.engine.salary.entity.siarchives.po;
|
||||
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -83,6 +84,7 @@ public class InsuranceArchivesFundSchemePO {
|
|||
/**
|
||||
* 公积金缴纳基数
|
||||
*/
|
||||
@Encrypt
|
||||
private String fundPaymentBaseString;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package com.engine.salary.entity.siarchives.po;
|
||||
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -73,6 +74,7 @@ public class InsuranceArchivesOtherSchemePO {
|
|||
/**
|
||||
* 其他福利缴纳基数
|
||||
*/
|
||||
@Encrypt
|
||||
private String otherPaymentBaseString;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package com.engine.salary.entity.siarchives.po;
|
||||
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -79,6 +80,7 @@ public class InsuranceArchivesSocialSchemePO {
|
|||
/**
|
||||
* 社保缴纳基数
|
||||
*/
|
||||
@Encrypt
|
||||
private String socialPaymentBaseString;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package com.engine.salary.entity.sischeme.po;
|
||||
|
||||
import com.engine.salary.annotation.Encrypt;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -59,11 +60,13 @@ public class InsuranceSchemeDetailPO {
|
|||
/**
|
||||
* 基数上限
|
||||
*/
|
||||
@Encrypt
|
||||
private String upperLimit;
|
||||
|
||||
/**
|
||||
* 基数下限
|
||||
*/
|
||||
@Encrypt
|
||||
private String lowerLimit;
|
||||
|
||||
/**
|
||||
|
|
@ -74,6 +77,7 @@ public class InsuranceSchemeDetailPO {
|
|||
/**
|
||||
* 固定费用
|
||||
*/
|
||||
@Encrypt
|
||||
private String fixedCost;
|
||||
|
||||
/**
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue