Merge branch 'dev'
This commit is contained in:
commit
1634cb4aad
|
@ -19,7 +19,9 @@ import io.renren.modules.resource.service.ResourceService;
|
|||
import io.renren.modules.resourceMountApply.dto.TResourceMountApplyDTO;
|
||||
import io.renren.modules.resourceMountApply.service.TResourceMountApplyService;
|
||||
import io.renren.modules.sys.dao.SysUserDao;
|
||||
import io.renren.modules.sys.dto.SysDeptDTO;
|
||||
import io.renren.modules.sys.dto.SysUserDTO;
|
||||
import io.renren.modules.sys.service.SysDeptService;
|
||||
import io.renren.modules.sys.service.SysUserService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
|
@ -45,6 +47,7 @@ import java.util.ArrayList;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Optional;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* 流程的历史信息
|
||||
|
@ -80,6 +83,8 @@ public class HistoryController {
|
|||
protected RepositoryService repositoryService;
|
||||
@Autowired
|
||||
protected RuntimeService runtimeService;
|
||||
@Autowired
|
||||
private SysDeptService sysDeptService;
|
||||
|
||||
@Autowired
|
||||
private SysUserDao sysUserDao;
|
||||
|
@ -213,6 +218,16 @@ public class HistoryController {
|
|||
list = taskHandleDetailInfo_;
|
||||
}
|
||||
}
|
||||
list = list.stream().map(index_ -> { // 补充审核人部门名称
|
||||
if (StringUtils.isNumeric(index_.getAssignee())) {
|
||||
SysUserDTO userDTO = sysUserService.get(Long.valueOf(index_.getAssignee()));
|
||||
Optional<SysDeptDTO> sysDeptDTOOptional = Optional.ofNullable(sysDeptService.get(userDTO.getDeptId()));
|
||||
if (sysDeptDTOOptional.isPresent()) {
|
||||
index_.setAssigneeDeptName(sysDeptDTOOptional.get().getName());
|
||||
}
|
||||
}
|
||||
return index_;
|
||||
}).collect(Collectors.toList());
|
||||
return new Result().ok(list);
|
||||
}
|
||||
|
||||
|
|
|
@ -53,4 +53,7 @@ public class HistoryDetailDTO {
|
|||
|
||||
@ApiModelProperty(value = "受理人姓名")
|
||||
private String assigneeName;
|
||||
|
||||
@ApiModelProperty(value = "受理人部门名称")
|
||||
private String assigneeDeptName;
|
||||
}
|
||||
|
|
|
@ -27,6 +27,7 @@ import io.renren.modules.resource.service.ResourceService;
|
|||
import io.renren.modules.security.user.SecurityUser;
|
||||
import io.renren.modules.security.user.UserDetail;
|
||||
import io.renren.modules.sys.dto.SysDeptDTO;
|
||||
import io.renren.modules.sys.dto.SysUserDTO;
|
||||
import io.renren.modules.sys.enums.SuperAdminEnum;
|
||||
import io.renren.modules.sys.service.SysDeptService;
|
||||
import io.renren.modules.sys.service.SysUserService;
|
||||
|
@ -213,7 +214,7 @@ public class TAbilityApplicationController {
|
|||
}
|
||||
};
|
||||
// 非超级管理员,只出本人
|
||||
if(user.getSuperAdmin() == SuperAdminEnum.NO.value()){
|
||||
if (user.getSuperAdmin() == SuperAdminEnum.NO.value()) {
|
||||
params.put("user_id", user == null ? null : user.getId());
|
||||
}
|
||||
List<TAbilityApplicationDTO> applicationDTOS = tAbilityApplicationService.list(params);
|
||||
|
@ -247,6 +248,17 @@ public class TAbilityApplicationController {
|
|||
.map(tAbilityApplicationDTO -> resourceService.get(Long.valueOf(tAbilityApplicationDTO.getResourceId()))).collect(Collectors.toList());
|
||||
List<HistoryDetailDTO> taskHandleDetailInfo = activitiService.getTaskHandleDetailInfo(tAbilityApplicationDTOList.get(0).getInstanceId());
|
||||
|
||||
taskHandleDetailInfo = taskHandleDetailInfo.stream().map(index_ -> { // 补充审核人部门名称
|
||||
if (StringUtils.isNumeric(index_.getAssignee())) {
|
||||
SysUserDTO userDTO = sysUserService.get(Long.valueOf(index_.getAssignee()));
|
||||
Optional<SysDeptDTO> sysDeptDTOOptional = Optional.ofNullable(sysDeptService.get(userDTO.getDeptId()));
|
||||
if (sysDeptDTOOptional.isPresent()) {
|
||||
index_.setAssigneeDeptName(sysDeptDTOOptional.get().getName());
|
||||
}
|
||||
}
|
||||
return index_;
|
||||
}).collect(Collectors.toList());
|
||||
|
||||
List<Object> camera;
|
||||
ArrayList cameraList = new ArrayList();
|
||||
QueryWrapper<TAbilityApplicationEntity> queryWrapper = new QueryWrapper<>();
|
||||
|
|
Loading…
Reference in New Issue