| | |
| | | $scope.fn.getUserList = getUserList; // 사용자 목록 정보를 조회한다. |
| | | $scope.fn.getProjectList = getProjectList; // 프로젝트 목록 정보를 조회한다. |
| | | $scope.fn.getIssueList = getIssueList; // 일감 목록 정보를 조회한다. |
| | | $scope.fn.getRelIssueList = getRelIssueList; // 연관 이슈 목록 정보를 조회한다. |
| | | $scope.fn.getDownIssueList = getDownIssueList; // 하위 이슈 목록 정보를 조회한다. |
| | | $scope.fn.getWorkflowList = getWorkflowList; // 워크플로우 목록 정보를 조회한다. |
| | | $scope.fn.getUserDepartmentList = getUserDepartmentList; // 부서 목록 정보를 조회한다. |
| | |
| | | return deferred.promise; |
| | | } |
| | | |
| | | function getRelIssueList(query, issueTypeId, excludeList, page, callBack) { |
| | | var conditions = { |
| | | name : query, |
| | | excludeIds : (function () { |
| | | var excludeIds = []; |
| | | |
| | | function getDownIssueList(query, issueTypeId, excludeList, page, callBack) { |
| | | angular.forEach(excludeList, function (exclude) { |
| | | excludeIds.push(exclude.id); |
| | | }); |
| | | return excludeIds; |
| | | })() |
| | | }; |
| | | |
| | | var deferred = $q.defer(); |
| | | |
| | | Issue.find($resourceProvider.getContent( |
| | | conditions)).then(function (result) { |
| | | if (result.data.message.status === "success") { |
| | | if ($rootScope.isDefined(callBack)) { |
| | | callBack(result); |
| | | } |
| | | deferred.resolve(result.data.data); |
| | | } |
| | | else { |
| | | SweetAlert.swal($filter("translate")("common.failedToIssueListLookUp"), result.data.message.message, "error"); // "워크플로우 목록 조회 실패" |
| | | } |
| | | }); |
| | | return deferred.promise; |
| | | } |
| | | |
| | | function getDownIssueList(query, issueTypeId, parentIssueId, excludeList, page, callBack) { |
| | | var conditions = { |
| | | name : query, |
| | | issueTypeIds : (function () { |
| | |
| | | excludeIds.push(exclude.id); |
| | | }); |
| | | |
| | | if(parentIssueId != null) { |
| | | excludeIds.push(parentIssueId); |
| | | } |
| | | return excludeIds; |
| | | })() |
| | | }; |
| | | |
| | | var deferred = $q.defer(); |
| | | |
| | | Issue.find($resourceProvider.getContent( // 페이징 업데이트가 필요한 컴포넌트 일경우, page 업데이트가 있을 경우 기본 10개씩 가져오고 아닐경우 25개씩 가져온다. |
| | | conditions, $resourceProvider.getPageContent($rootScope.isDefined(page) ? page : 0, $rootScope.isDefined(page) ? 10 : 25))).then(function (result) { |
| | | conditions)).then(function (result) { |
| | | if (result.data.message.status === "success") { |
| | | |
| | | if ($rootScope.isDefined(callBack)) { |
| | | callBack(result); |
| | | } |
| | | |
| | | deferred.resolve(result.data.data); |
| | | } |
| | | else { |
| | | SweetAlert.swal($filter("translate")("common.failedToIssueListLookUp"), result.data.message.message, "error"); // "워크플로우 목록 조회 실패" |
| | | } |
| | | }); |
| | | |
| | | return deferred.promise; |
| | | } |
| | | |