fix:修复[编辑按钮报错]Bug
编辑报告-部门为空的时候,编辑按钮报错
This commit is contained in:
@@ -689,11 +689,13 @@ public class IReportServiceImpl extends ServiceImpl<ReportDao, ReportEntity>
|
||||
ReportDetailVo reportDetailVo = reportDao.reportDetail(reportId);
|
||||
//设置部门名称
|
||||
String department = reportDetailVo.getDepartment();
|
||||
String[] idArray = department.split(",");
|
||||
List<OrgEO> orgEOList = orgEOService.query().in("ID", idArray).list();
|
||||
if (CollectionUtils.isNotEmpty(orgEOList)) {
|
||||
String departmentName = orgEOList.stream().map(OrgEO::getOrgName).collect(Collectors.joining(","));
|
||||
reportDetailVo.setDepartmentName(departmentName);
|
||||
if (StrUtil.isNotBlank(department)) {
|
||||
String[] idArray = department.split(",");
|
||||
List<OrgEO> orgEOList = orgEOService.query().in("ID", idArray).list();
|
||||
if (CollectionUtils.isNotEmpty(orgEOList)) {
|
||||
String departmentName = orgEOList.stream().map(OrgEO::getOrgName).collect(Collectors.joining(","));
|
||||
reportDetailVo.setDepartmentName(departmentName);
|
||||
}
|
||||
}
|
||||
|
||||
//设置标签列表
|
||||
|
||||
Reference in New Issue
Block a user