| | |
| | | |
| | | |
| | | import com.java110.core.base.smo.BaseServiceSMO; |
| | | import com.java110.core.smo.common.IComplaintUserInnerServiceSMO; |
| | | import com.java110.core.smo.common.IWorkflowInnerServiceSMO; |
| | | import com.java110.core.smo.store.IComplaintInnerServiceSMO; |
| | | import com.java110.core.smo.user.IUserInnerServiceSMO; |
| | | import com.java110.intf.common.IComplaintUserInnerServiceSMO; |
| | | import com.java110.intf.common.IWorkflowInnerServiceSMO; |
| | | import com.java110.intf.store.IComplaintInnerServiceSMO; |
| | | import com.java110.intf.user.IUserInnerServiceSMO; |
| | | import com.java110.dto.PageDto; |
| | | import com.java110.dto.auditMessage.AuditMessageDto; |
| | | import com.java110.dto.complaint.ComplaintDto; |
| | |
| | | workflowDto.setCommunityId(communityId); |
| | | List<WorkflowDto> workflowDtos = workflowInnerServiceSMOImpl.queryWorkflows(workflowDto); |
| | | |
| | | Assert.listOnlyOne(workflowDtos, "未找到 投诉建议流程或找到多条"); |
| | | Assert.listOnlyOne(workflowDtos, "未找到 投诉建议流程或找到多条,请在物业账号系统管理下流程管理中配置流程"); |
| | | |
| | | WorkflowDto tmpWorkflowDto = workflowDtos.get(0); |
| | | if (StringUtil.isEmpty(tmpWorkflowDto.getProcessDefinitionKey())) { |
| | |
| | | |
| | | HistoricTaskInstanceQuery historicTaskInstanceQuery = historyService.createHistoricTaskInstanceQuery() |
| | | .processDefinitionKey(getWorkflowDto(user.getCommunityId())) |
| | | .taskAssignee(user.getUserId()); |
| | | .taskAssignee(user.getUserId()) |
| | | .finished(); |
| | | if (!StringUtil.isEmpty(user.getAuditLink()) && "START".equals(user.getAuditLink())) { |
| | | historicTaskInstanceQuery.taskName("complaint"); |
| | | } else if (!StringUtil.isEmpty(user.getAuditLink()) && "AUDIT".equals(user.getAuditLink())) { |
| | |
| | | } |
| | | |
| | | Query query = historicTaskInstanceQuery; |
| | | |
| | | return query.count(); |
| | | } |
| | | |
| | |
| | | |
| | | HistoricTaskInstanceQuery historicTaskInstanceQuery = historyService.createHistoricTaskInstanceQuery() |
| | | .processDefinitionKey(getWorkflowDto(user.getCommunityId())) |
| | | .taskAssignee(user.getUserId()); |
| | | .taskAssignee(user.getUserId()) |
| | | .finished(); |
| | | if (!StringUtil.isEmpty(user.getAuditLink()) && "START".equals(user.getAuditLink())) { |
| | | historicTaskInstanceQuery.taskName("complaint"); |
| | | } else if (!StringUtil.isEmpty(user.getAuditLink()) && "AUDIT".equals(user.getAuditLink())) { |
| | |
| | | String userIds = ""; |
| | | String userNames = ""; |
| | | String userTels = ""; |
| | | String taskIds = ""; |
| | | for (Task task : tasks) { |
| | | String userId = task.getAssignee(); |
| | | taskIds += (task.getId() + "/"); |
| | | List<UserDto> users = userInnerServiceSMOImpl.getUserInfo(new String[]{userId}); |
| | | if (users == null || users.size() == 0) { |
| | | continue; |
| | |
| | | userNames += (users.get(0).getName() + "/"); |
| | | userTels += (users.get(0).getTel() + "/"); |
| | | } |
| | | userIds = userIds.endsWith("/") ? userIds.substring(0, userIds.length() - 2) : userIds; |
| | | userNames = userNames.endsWith("/") ? userNames.substring(0, userNames.length() - 2) : userNames; |
| | | userTels = userTels.endsWith("/") ? userTels.substring(0, userTels.length() - 2) : userTels; |
| | | userIds = userIds.endsWith("/") ? userIds.substring(0, userIds.length() - 1) : userIds; |
| | | userNames = userNames.endsWith("/") ? userNames.substring(0, userNames.length() - 1) : userNames; |
| | | userTels = userTels.endsWith("/") ? userTels.substring(0, userTels.length() - 1) : userTels; |
| | | taskIds = taskIds.endsWith("/") ? taskIds.substring(0, taskIds.length() - 1) : taskIds; |
| | | complaintDto.setCurrentUserId(userIds); |
| | | complaintDto.setCurrentUserName(userNames); |
| | | complaintDto.setCurrentUserTel(userTels); |
| | | complaintDto.setTaskId(taskIds); |
| | | return complaintDto; |
| | | |
| | | } |