|
@ -18,6 +18,7 @@ import com.ruoyi.common.utils.StringUtils; |
|
|
import com.ruoyi.process.general.service.IProcessService; |
|
|
import com.ruoyi.process.general.service.IProcessService; |
|
|
import com.ruoyi.process.todoitem.mapper.BizTodoItemMapper; |
|
|
import com.ruoyi.process.todoitem.mapper.BizTodoItemMapper; |
|
|
import com.ruoyi.system.domain.BaseExpenseAccountChild; |
|
|
import com.ruoyi.system.domain.BaseExpenseAccountChild; |
|
|
|
|
|
import com.ruoyi.system.domain.Vo.BaseEmpRequisiteOrderVO; |
|
|
import com.ruoyi.system.domain.Vo.BaseExpenseAccountVo; |
|
|
import com.ruoyi.system.domain.Vo.BaseExpenseAccountVo; |
|
|
import com.ruoyi.system.domain.Vo.BaseRequisitioningOrderVo; |
|
|
import com.ruoyi.system.domain.Vo.BaseRequisitioningOrderVo; |
|
|
import com.ruoyi.system.mapper.SysDeptMapper; |
|
|
import com.ruoyi.system.mapper.SysDeptMapper; |
|
@ -108,12 +109,18 @@ public class BaseExpenseAccountServiceImpl implements IBaseExpenseAccountService |
|
|
Set<String> roleKeys = roleService.selectRoleKeys(userId); |
|
|
Set<String> roleKeys = roleService.selectRoleKeys(userId); |
|
|
List<BaseExpenseAccountVo> Volist = baseExpenseAccountMapper.selectBaseExpenseAccountList(baseExpenseAccount); |
|
|
List<BaseExpenseAccountVo> Volist = baseExpenseAccountMapper.selectBaseExpenseAccountList(baseExpenseAccount); |
|
|
|
|
|
|
|
|
|
|
|
List<BaseExpenseAccountVo> matchedList = new ArrayList<>(); |
|
|
|
|
|
if(roleKeys.contains("zjlRole") || roleKeys.contains("zozjRole") |
|
|
|
|
|
|| roleKeys.contains("fzjlRole") || roleKeys.contains("admin")|| roleKeys.contains("cwshRole")){ |
|
|
|
|
|
matchedList = Volist; |
|
|
|
|
|
}else{ |
|
|
// 获取当前登录名下可看用户列表
|
|
|
// 获取当前登录名下可看用户列表
|
|
|
Set<String> users = userLimitedList(roleKeys,curUser); |
|
|
Set<String> users = userLimitedList(roleKeys,curUser); |
|
|
|
|
|
|
|
|
List<BaseExpenseAccountVo> matchedList = Volist.stream() |
|
|
matchedList = Volist.stream() |
|
|
.filter(expenseAccount -> users.contains(expenseAccount.getApplyUser())) |
|
|
.filter(expenseAccount -> users.contains(expenseAccount.getApplyUser())) |
|
|
.collect(Collectors.toList()); |
|
|
.collect(Collectors.toList()); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
PageDomain pageDomain = TableSupport.buildPageRequest(); |
|
|
PageDomain pageDomain = TableSupport.buildPageRequest(); |
|
|
Integer pageNum = pageDomain.getPageNum(); |
|
|
Integer pageNum = pageDomain.getPageNum(); |
|
@ -530,14 +537,15 @@ public class BaseExpenseAccountServiceImpl implements IBaseExpenseAccountService |
|
|
|
|
|
|
|
|
if(roleKeys.contains("zjlRole") || roleKeys.contains("zozjRole") |
|
|
if(roleKeys.contains("zjlRole") || roleKeys.contains("zozjRole") |
|
|
|| roleKeys.contains("fzjlRole") || roleKeys.contains("admin") |
|
|
|| roleKeys.contains("fzjlRole") || roleKeys.contains("admin") |
|
|
|| roleKeys.contains("cwshRole")|| roleKeys.contains("hrjlRole")){ |
|
|
|| roleKeys.contains("cwshRole")){ |
|
|
Set<String> users = sysUserlist.stream() |
|
|
Set<String> users = sysUserlist.stream() |
|
|
.map(SysUser::getLoginName) // 提取每个 SysUser 对象的 name 属性
|
|
|
.map(SysUser::getLoginName) // 提取每个 SysUser 对象的 name 属性
|
|
|
.collect(Collectors.toSet()); |
|
|
.collect(Collectors.toSet()); |
|
|
return users; |
|
|
return users; |
|
|
}else if(roleKeys.contains("gcjlRole") || roleKeys.contains("scjlRole") || roleKeys.contains("cgjlRole") |
|
|
}else if(roleKeys.contains("gcjlRole") || roleKeys.contains("scjlRole") || roleKeys.contains("cgjlRole") |
|
|
|| roleKeys.contains("ywjlRole")|| roleKeys.contains("wwjlRole")|| roleKeys.contains("shjlRole") |
|
|
|| roleKeys.contains("ywjlRole")|| roleKeys.contains("wwjlRole")|| roleKeys.contains("shjlRole") |
|
|
|| roleKeys.contains("ckjlRole")|| roleKeys.contains("yfzjRole")|| roleKeys.contains("cwjlRole")) { |
|
|
|| roleKeys.contains("ckjlRole")|| roleKeys.contains("yfzjRole")|| roleKeys.contains("cwjlRole") |
|
|
|
|
|
|| roleKeys.contains("pzjlRole")|| roleKeys.contains("hrjlRole")) { |
|
|
// 部门经理查询部门所属下的所有
|
|
|
// 部门经理查询部门所属下的所有
|
|
|
// 去除列表中部门id为空的数据
|
|
|
// 去除列表中部门id为空的数据
|
|
|
sysUserlist = sysUserlist.stream().filter(item->(item.getDeptId()!=null)).collect(Collectors.toList()); |
|
|
sysUserlist = sysUserlist.stream().filter(item->(item.getDeptId()!=null)).collect(Collectors.toList()); |
|
|