| | |
| | | issueApiForm.addUseIssueCustomFieldId(customFieldApiOverlap.getCustomField().getId()); |
| | | } |
| | | |
| | | // 중복된 이슈검색 |
| | | // 종료상태가 아닌 중복된 상위 이슈검색 |
| | | List<Issue> issues = this.findIssue(issueApiForm, customFieldApiOverlaps, user.getId()); |
| | | int size = issues.size(); |
| | | if (size > 0) { |
| | |
| | | issueCustomFieldValueCondition.setUseValue(concatUseValue); |
| | | issueCustomFieldValueCondition.setUseValues(userValues); |
| | | issueCustomFieldValueCondition.setIssueTypeId(issueApiform.getIssueTypeId()); |
| | | issueCustomFieldValueCondition.setIssueStatusType("CLOSE"); |
| | | List<Map<String, Object>> results = this.issueMapper.findByCustomFieldValue(issueCustomFieldValueCondition); |
| | | if (results != null && results.size() > 0) { |
| | | for (Map<String, Object> result : results) { |
| | |
| | | // if (!this.userWorkspaceService.checkWorkspaceManager(user) |
| | | // && !MngPermission.checkMngPermission(userLevel.getPermission(), MngPermission.USER_PERMISSION_MNG_ISSUE)) { //최고관리자 & 프로젝트,이슈 관리자 일 경우 모든 이슈 보기 |
| | | // this.SetMyDepartmentId(issueCondition); |
| | | //this.SetAllDepartmentId(issueCondition); |
| | | //this.SetAllDepartmentId(issueCondition); |
| | | // } /*else{ |
| | | // results = this.issueMapper.findByDepartment(issueCondition); |
| | | // totalCount = this.issueMapper.countByDepartment(issueCondition); |
| | |
| | | // 이슈 상세 정보를 조회한다. |
| | | @Override |
| | | @Transactional(readOnly = true) |
| | | public void detailIssue(Map<String, Object> resJsonData, IssueCondition issueCondition, Pageable relPageable, Pageable downPageable) { |
| | | public void detailIssue(Map<String, Object> resJsonData, IssueCondition issueCondition) { |
| | | IssueVo issueVo = new IssueVo(); |
| | | Pageable relPageable = issueCondition.getRelPageable(); |
| | | Pageable downPageable = issueCondition.getDownPageable(); |
| | | |
| | | if (issueCondition.getId() != null) { |
| | | Issue issue = this.getIssue(issueCondition.getId()); |
| | | issueVo = ConvertUtil.copyProperties(issue, IssueVo.class); |
| | | User user = this.webAppUtil.getLoginUserObject(); |
| | | |
| | | issueVo.setRelPage(relPageable.getPageNumber() * relPageable.getPageSize()); |
| | | issueVo.setRelPageSize(relPageable.getPageSize()); |
| | | |
| | | issueVo.setRelPageNumber(relPageable.getPageNumber()); |
| | | issueVo.setRelPageSize(relPageable.getPageSize()); |
| | | issueVo.setRelPage(relPageable.getPageNumber() * relPageable.getPageSize()); |
| | | |
| | | issueVo.setDownPageNumber(downPageable.getPageNumber()); |
| | | issueVo.setDownPage(downPageable.getPageNumber() * downPageable.getPageSize()); |
| | | issueVo.setDownPageSize(downPageable.getPageSize()); |
| | | |
| | |
| | | break; |
| | | } |
| | | } |
| | | Long relTotalCount = issueVo.getRelTotalCount(); |
| | | int relTotalPage = issueVo.getRelTotalPage(); |
| | | |
| | | Long downTotalCount = issueVo.getDownTotalCount(); |
| | | int downTotalPage = issueVo.getDownTotalPage(); |
| | | // 사용자 시스템 기능 사용 정보 수집 |
| | | log.info(ElasticSearchUtil.makeUserActiveHistoryMessage(this.webAppUtil.getLoginUser(), ElasticSearchConstants.ISSUE_DETAIL)); |
| | | |
| | | resJsonData.put(Constants.RES_KEY_CONTENTS, issueVo); |
| | | resJsonData.put(Constants.REQ_KEY_RELATION_ISSUE_PAGE_VO, new ResPage(relPageable.getPageNumber(), relPageable.getPageSize(), |
| | | relTotalPage, relTotalCount)); |
| | | resJsonData.put(Constants.REQ_KEY_DOWN_ISSUE_PAGE_VO, new ResPage(downPageable.getPageNumber(), downPageable.getPageSize(), |
| | | downTotalPage, downTotalCount)); |
| | | } |
| | | |
| | | // 테이블 설정 셋팅 |
| | |
| | | this.issueHistoryService.addIssueHistory(issue, IssueHistoryType.SEND, sb.toString()); |
| | | } |
| | | |
| | | @Override |
| | | public void sendCommonEmail(EmailCommonForm emailCommonForm) { |
| | | if (emailCommonForm.getSendEmails().size() < 1) { |
| | | throw new OwlRuntimeException( |
| | | this.messageAccessor.getMessage(MsgConstants.ISSUE_NOT_SEND_USER)); |
| | | } else if (emailCommonForm.getIssueId() == null) { |
| | | throw new OwlRuntimeException( |
| | | this.messageAccessor.getMessage(MsgConstants.ISSUE_NOT_EXIST)); |
| | | } |
| | | |
| | | Issue issue = this.getIssue(emailCommonForm.getIssueId()); |
| | | |
| | | // 발신자 표시 |
| | | User user = this.webAppUtil.getLoginUserObject(); |
| | | UserVo toUser = this.webAppUtil.getLoginUser(); |
| | | |
| | | // 사용자 시스템 기능 사용 정보 수집 |
| | | log.info(ElasticSearchUtil.makeUserActiveHistoryMessage(this.webAppUtil.getLoginUser(), ElasticSearchConstants.ISSUE_ANOTHER_USER_SEND_EMAIL)); |
| | | StringBuilder sb = new StringBuilder(); |
| | | |
| | | Locale locale = CommonUtil.getUserLanguage(user.getLanguage()); |
| | | String[] sendMails = ConvertUtil.ToArray(emailCommonForm.getSendEmails()); |
| | | for(int i=0; i < sendMails.length; i++) { |
| | | sendMails[i] = CommonUtil.decryptAES128(sendMails[i]); |
| | | } |
| | | this.systemEmailService.sendEmail(emailCommonForm.getTitle(), emailCommonForm.getDescription(), sendMails, null); |
| | | |
| | | this.issueHistoryService.detectSendIssueMail(IssueHistoryType.SEND, emailCommonForm.getSendEmails(), sb); |
| | | this.issueHistoryService.addIssueHistory(issue, IssueHistoryType.SEND, sb.toString()); |
| | | } |
| | | |
| | | // 예약 발생 이슈를 실행한다 |
| | | @Override |
| | | @Transactional |