薪酬系统-福利档案、台账,基数调整记录列表查询增加分权,台账查询条件支持个税扣缴义务人多选
This commit is contained in:
parent
163c436b3d
commit
4da07b9e80
|
|
@ -54,4 +54,7 @@ public class SalaryTemplateListDTO {
|
|||
@SalaryTableColumn(text = "备注", width = "20%", column = "description")
|
||||
@TableTitle(title = "备注", dataIndex = "description", key = "description")
|
||||
private String description;
|
||||
|
||||
// 薪资账套id
|
||||
private Long salarySobId;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -366,7 +366,8 @@
|
|||
t.replenish_name as replenishName,
|
||||
s.name as salarysob,
|
||||
t.use_type as useType,
|
||||
t.description
|
||||
t.description,
|
||||
t.salary_sob_id
|
||||
from
|
||||
hrsa_salary_template t left join hrsa_salary_sob s on t.salary_sob_id = s.id
|
||||
where t.delete_type = 0
|
||||
|
|
@ -398,7 +399,8 @@
|
|||
t.replenish_name as replenishName,
|
||||
s.name as salarysob,
|
||||
t.use_type as useType,
|
||||
t.description
|
||||
t.description,
|
||||
t.salary_sob_id
|
||||
from
|
||||
hrsa_salary_template t left join hrsa_salary_sob s on t.salary_sob_id = s.id
|
||||
where t.delete_type = 0
|
||||
|
|
@ -430,7 +432,8 @@
|
|||
t.replenish_name as replenishName,
|
||||
s.name as salarysob,
|
||||
t.use_type as useType,
|
||||
t.description
|
||||
t.description,
|
||||
t.salary_sob_id
|
||||
from
|
||||
hrsa_salary_template t left join hrsa_salary_sob s on t.salary_sob_id = s.id
|
||||
where t.delete_type = 0
|
||||
|
|
|
|||
|
|
@ -232,6 +232,7 @@ public class SIAccountServiceImpl extends Service implements SIAccountService {
|
|||
Long employeeId = (long) user.getUID();
|
||||
Map<String, Object> datas = new HashMap<>();
|
||||
|
||||
List<Long> paymentOrganizationIds = queryParam.getTaxAgents();
|
||||
// 分权逻辑
|
||||
Boolean needAuth = getTaxAgentService(user).isNeedAuth((long) user.getUID());
|
||||
if (needAuth) {
|
||||
|
|
@ -240,7 +241,8 @@ public class SIAccountServiceImpl extends Service implements SIAccountService {
|
|||
if (CollectionUtils.isEmpty(taxAgents)) {
|
||||
//防止普通用户查询
|
||||
queryParam.setTaxAgents(Collections.singletonList(-1L));
|
||||
} else {
|
||||
} else if (paymentOrganizationIds != null && paymentOrganizationIds.size() > 0){
|
||||
taxAgents.retainAll(paymentOrganizationIds);
|
||||
queryParam.setTaxAgents(taxAgents);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1159,6 +1159,20 @@ public class SIArchivesServiceImpl extends Service implements SIArchivesService
|
|||
public PageInfo<InsuranceArchivesBaseHistoryDTO> historyListByEmployeeIdAndOperator(SIArchiveBaseHistoryListParam param) {
|
||||
|
||||
List<InsuranceArchivesBaseHistoryDTO> adjustHistoryDTOS = siArchivesBiz.getBaseHistoryByEmployeeIdAndOperator(param.getOperator(), param.getEmployeeId());
|
||||
|
||||
// 分权逻辑
|
||||
Boolean needAuth = getTaxAgentService(user).isNeedAuth((long) user.getUID());
|
||||
if (needAuth) {
|
||||
Collection<TaxAgentPO> taxAgentPOS = getTaxAgentService(user).listAllTaxAgents((long) user.getUID());
|
||||
List<Long> taxAgents = taxAgentPOS.stream().map(TaxAgentPO::getId).collect(Collectors.toList());
|
||||
if (CollectionUtils.isEmpty(taxAgents)) {
|
||||
//防止普通用户查询
|
||||
adjustHistoryDTOS = new ArrayList<>();
|
||||
} else {
|
||||
adjustHistoryDTOS = adjustHistoryDTOS.stream().filter(f -> taxAgents.contains(f.getPaymentOrganization())).collect(Collectors.toList());
|
||||
}
|
||||
}
|
||||
|
||||
adjustHistoryDTOS.forEach(f -> {
|
||||
if (StringUtils.isNotBlank(f.getPaymentScope())) {
|
||||
if(f.getPaymentScope().equals(PaymentScopeEnum.SCOPE_PERSON.getValue().toString())) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue