1、薪资核算时取账套下的人员范围,且这个人需要再账套所属的扣缴义务人下由档案,且起始发薪和最后发薪日期在这个薪资周期内

2、福利核算的范围需要在扣缴义务人下,且三个起始结束日期在核算周期内
This commit is contained in:
钱涛 2022-08-03 17:02:03 +08:00
parent e6207ad846
commit a340f1aaaf
4 changed files with 12 additions and 6 deletions

View File

@ -660,6 +660,7 @@ public class SIArchivesBiz {
request.setNeedAuth(param.getNeedAuth());
request.setTaxAgentEmployeeIds(param.getTaxAgentEmployeeIds());
request.setTaxAgentIds(param.getTaxAgentIds());
Integer current = param.getCurrent() == null ? 1 : param.getCurrent();
Integer pageSize = param.getPageSize() == null ? 10 : param.getPageSize();
@ -705,10 +706,11 @@ public class SIArchivesBiz {
PageInfo<InsuranceArchivesEmployeePO> pageInfo = new PageInfo<>(InsuranceArchivesEmployeePO.class);
if (needAuth) {
Collection<Long> taxAgentEmployeeIds = param.getTaxAgentEmployeeIds();
Collection<Long> taxAgentIds = param.getTaxAgentIds();
page = socialSchemeMapper.queryEmployeeList(param);
page = page.stream().filter(f ->
// 作为管理员
taxAgentEmployeeIds.contains(f.getEmployeeId())
// taxAgentEmployeeIds.contains(f.getEmployeeId())||
taxAgentIds.contains(f.getPaymentOrganization())
).collect(Collectors.toList());
// 填充总数和当页数据
// 分页参数

View File

@ -97,6 +97,8 @@ public class InsuranceArchivesListParam extends BaseQueryParam {
//分权
private Boolean needAuth;
//个税扣缴义务人
//个税扣缴义务人下人员
private Collection<Long> taxAgentEmployeeIds;
//个税扣缴义务人
private Collection<Long> taxAgentIds;
}

View File

@ -95,7 +95,9 @@ public class SIArchivesServiceImpl extends Service implements SIArchivesService
if (needAuth) {
List<TaxAgentEmployeeDTO> taxAgentEmployeeDTOS = getTaxAgentService(user).listTaxAgentAndEmployee(currentEmployeeId);
Set<Long> employeeIds = SalaryEntityUtil.properties(taxAgentEmployeeDTOS, TaxAgentEmployeeDTO::getEmployeeId);
Set<Long> taxAgentIds = SalaryEntityUtil.properties(taxAgentEmployeeDTOS, TaxAgentEmployeeDTO::getTaxAgentId);
param.setTaxAgentEmployeeIds(employeeIds);
param.setTaxAgentIds(taxAgentIds);
}
Map<String, Object> apidatas = new HashMap<>(16);

View File

@ -407,9 +407,9 @@ public class SalaryAcctEmployeeServiceImpl extends Service implements SalaryAcct
//查询账套对应的扣缴义务人
SalarySobPO salarySobPO = getSalarySobService(user).getById(salaryAcctRecordPO.getSalarySobId());
Long taxAgentId = salarySobPO.getTaxAgentId();
//过滤扣税扣缴义务人不包含的人员
Collection<Long> employeeIdsInTaxAgent = getTaxAgentService(user).listEmployeeIdsInTaxAgent(taxAgentId);
salaryEmployees = salaryEmployees.stream().filter(salaryEmployee -> employeeIdsInTaxAgent.contains(salaryEmployee.getEmployeeId())).collect(Collectors.toList());
// //过滤扣税扣缴义务人不包含的人员
// Collection<Long> employeeIdsInTaxAgent = getTaxAgentService(user).listEmployeeIdsInTaxAgent(taxAgentId);
// salaryEmployees = salaryEmployees.stream().filter(salaryEmployee -> employeeIdsInTaxAgent.contains(salaryEmployee.getEmployeeId())).collect(Collectors.toList());
// 查询薪资档案获取人员的个税扣缴义务人
Set<Long> employeeIds = SalaryEntityUtil.properties(salaryEmployees, DataCollectionEmployee::getEmployeeId);