bug修改
This commit is contained in:
parent
597e2206e9
commit
4e4c190f31
|
|
@ -810,7 +810,7 @@ public class SIArchivesBiz {
|
|||
map.put("siSchemeId", item.getSiSchemeId());
|
||||
map.put("fundSchemeId", item.getFundSchemeId());
|
||||
map.put("otherSchemeId",item.getOtherSchemeId());
|
||||
map.put("status", item.getUserStatusEnum() == null ? "" : item.getUserStatusEnum().getDescription());
|
||||
map.put("status", item.getUserStatus() != null ? UserStatusEnum.values()[item.getUserStatus()].getDescription() : "");
|
||||
if (socialItem != null) {
|
||||
map.put("socialName", insuranceSchemeMapper.querySchemeName(socialItem.getSocialSchemeId()));
|
||||
Map<String, Object> socialJson = JSON.parseObject(socialItem.getSocialPaymentBaseString(), new TypeReference<Map<String, Object>>() {
|
||||
|
|
|
|||
|
|
@ -34,6 +34,8 @@ public class InsuranceArchivesEmployeePO {
|
|||
|
||||
private BigDecimal position;
|
||||
|
||||
private Integer userStatus;
|
||||
|
||||
private UserStatusEnum userStatusEnum;
|
||||
|
||||
private String hiredate;
|
||||
|
|
|
|||
|
|
@ -83,6 +83,4 @@ public enum UserStatusEnum {
|
|||
return Arrays.stream(UserStatusEnum.values()).filter(v -> v != INVALID).collect(Collectors.toList());
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -12,8 +12,17 @@
|
|||
</select>
|
||||
|
||||
<select id="getEmployeeByIds" resultType="com.engine.salary.entity.datacollection.DataCollectionEmployee">
|
||||
select e.ID as employeeId,
|
||||
e.LASTNAME as username
|
||||
select e.id as employeeId,
|
||||
e.lastname as username,
|
||||
e.status as status,
|
||||
e.workcode as workcode,
|
||||
d.departmentname as departmentName,
|
||||
d.id as departmentId,
|
||||
c.jobtitlename as jobtitleName,
|
||||
c.id as jobtitleId,
|
||||
e.companystartdate as companystartdate,
|
||||
e.mobile as mobile,
|
||||
b.dismissdate as dismissdate
|
||||
from hrmresource e
|
||||
where e.status not in (7)
|
||||
<if test="collection != null and collection.size()>0">
|
||||
|
|
|
|||
|
|
@ -51,6 +51,7 @@
|
|||
<sql id="baseColumns">
|
||||
t.id
|
||||
, t.employee_id
|
||||
, e.status as employee_status
|
||||
, t.bill_month
|
||||
, t.bill_status
|
||||
, t.payment_status
|
||||
|
|
|
|||
|
|
@ -11,6 +11,7 @@ import com.engine.salary.entity.siarchives.po.InsuranceArchivesFundSchemePO;
|
|||
import com.engine.salary.entity.siarchives.po.InsuranceArchivesOtherSchemePO;
|
||||
import com.engine.salary.entity.siarchives.po.InsuranceArchivesSocialSchemePO;
|
||||
import com.engine.salary.entity.taxrate.TaxAgent;
|
||||
import com.engine.salary.enums.UserStatusEnum;
|
||||
import com.engine.salary.enums.siaccount.BillStatusEnum;
|
||||
import com.engine.salary.enums.siaccount.ResourceFromEnum;
|
||||
import com.engine.salary.mapper.TaxAgentMapper;
|
||||
|
|
@ -44,7 +45,7 @@ public class RecordsBuildServiceImpl extends Service implements RecordsBuildServ
|
|||
return result;
|
||||
}
|
||||
List<Long> employeeIds = list.stream().map(item -> item.getEmployeeId()).collect(Collectors.toList());
|
||||
List<DataCollectionEmployee> employeeByIds = MapperProxyFactory.getProxy(EmployMapper.class).getEmployeeByIds(employeeIds);
|
||||
List<DataCollectionEmployee> employeeByIds = MapperProxyFactory.getProxy(EmployMapper.class).getEmployeeByIdsAll(employeeIds);
|
||||
if (CollectionUtils.isEmpty(employeeByIds)) {
|
||||
return result;
|
||||
}
|
||||
|
|
@ -64,7 +65,7 @@ public class RecordsBuildServiceImpl extends Service implements RecordsBuildServ
|
|||
record.put("department", simpleEmployee.getDepartmentName());
|
||||
record.put("supplementaryMonth", item.getSupplementaryMonth());
|
||||
record.put("mobile", simpleEmployee.getMobile());
|
||||
record.put("employeeStatus", simpleEmployee.getStatus());
|
||||
record.put("employeeStatus", simpleEmployee.getStatus() != null ? UserStatusEnum.values()[Integer.parseInt(simpleEmployee.getStatus())].getDescription() : "");
|
||||
ResourceFromEnum from = SalaryEnumUtil.enumMatchByValue(item.getResourceFrom(), ResourceFromEnum.values(), ResourceFromEnum.class);
|
||||
record.put("sourceFrom", SalaryI18nUtil.getI18nLabel(from.getLabelId(), from.getDefaultLabel()));
|
||||
record.put("socialPayOrg", paymentMap.get(item.getSocialPayOrg()) == null ? "" : paymentMap.get(item.getSocialPayOrg()).getName());
|
||||
|
|
|
|||
|
|
@ -200,15 +200,29 @@ public class SISchemeServiceImpl extends Service implements SISchemeService {
|
|||
if (CollectionUtils.isEmpty(employeeIds)) {
|
||||
return records;
|
||||
}
|
||||
List<InsuranceArchivesSocialSchemePO> socialList = new ArrayList<>();
|
||||
List<InsuranceArchivesFundSchemePO> fundList = new ArrayList<>();
|
||||
List<InsuranceArchivesOtherSchemePO> otherList = new ArrayList<>();
|
||||
|
||||
for(int i = 0; i < employeeIds.size(); i+=1000) {
|
||||
int end = i + 1000;
|
||||
if(i + 1000 >= employeeIds.size()) {
|
||||
end = employeeIds.size();
|
||||
}
|
||||
List<Long> ids = employeeIds.subList(i, end);
|
||||
socialList.addAll(getSocialSchemeMapper().getSocialByEmployeeId(ids));
|
||||
fundList.addAll(getFundSchemeMapper().getFundByEmployeeId(ids));
|
||||
otherList.addAll(getOtherSchemeMapper().getOtherByEmployeeId(ids));
|
||||
}
|
||||
|
||||
Map<Long, InsuranceArchivesSocialSchemePO> socialSchemePOMap =
|
||||
getSocialSchemeMapper().getSocialByEmployeeId(employeeIds)
|
||||
socialList
|
||||
.stream().collect(Collectors.toMap(InsuranceArchivesSocialSchemePO::getEmployeeId, Function.identity()));
|
||||
Map<Long, InsuranceArchivesFundSchemePO> fundSchemePOMap =
|
||||
getFundSchemeMapper().getFundByEmployeeId(employeeIds)
|
||||
fundList
|
||||
.stream().collect(Collectors.toMap(InsuranceArchivesFundSchemePO::getEmployeeId, Function.identity()));
|
||||
Map<Long, InsuranceArchivesOtherSchemePO> otherSchemePOMap =
|
||||
getOtherSchemeMapper().getOtherByEmployeeId(employeeIds)
|
||||
otherList
|
||||
.stream().collect(Collectors.toMap(InsuranceArchivesOtherSchemePO::getEmployeeId, Function.identity()));
|
||||
insuranceArchivesEmployeePOS.forEach(item -> {
|
||||
InsuranceArchivesSocialSchemePO socialItem = socialSchemePOMap.get(item.getEmployeeId());
|
||||
|
|
|
|||
Loading…
Reference in New Issue