| | |
| | | @Override |
| | | public IPage<AfterSalesServiceNewDto> listPage(Page page, AfterSalesServiceNewDto afterSalesService) { |
| | | Long tenantId = SecurityUtils.getLoginUser().getTenantId(); |
| | | SysDept sysDept = sysDeptMapper.selectDeptById(tenantId); |
| | | String deptName = null; |
| | | if (tenantId != null) { |
| | | SysDept sysDept = sysDeptMapper.selectDeptById(tenantId); |
| | | if (sysDept != null) { |
| | | deptName = sysDept.getDeptName(); |
| | | } |
| | | } |
| | | IPage<AfterSalesServiceNewDto> afterSalesServiceIPage = afterSalesServiceMapper.listPage(page, afterSalesService); |
| | | String finalDeptName = deptName; |
| | | afterSalesServiceIPage.getRecords().forEach(item -> { |
| | | item.setDeptName(sysDept.getDeptName()); |
| | | item.setDeptName(finalDeptName); |
| | | }); |
| | | return afterSalesServiceIPage; |
| | | } |