OWL ITS + 탐지시스템(인터넷 진흥원)
이민희
2022-02-18 8d1928e733f71e00c6d8685d4f5b15031f4afa38
src/main/webapp/scripts/app/issue/issueModify.controller.js
@@ -579,22 +579,6 @@
                    $rootScope.spinner = true;
                    let inheritYn = false;
                    if ($scope.vm.inheritPartners && $scope.vm.downTotalCount > 0) {
                        SweetAlert.swal({
                                title : $filter("translate")("issue.modifyDownIssue"), // 하위 이슈 변경
                                text : $filter("translate")("issue.wantToInheritPartnersOfParentIssue"), // 상위이슈의 파트너 정보(업체/ISP/호스팅)를 적용시키겠습니까?
                                type : "warning",
                                showCancelButton : true,
                                confirmButtonColor : "#DD6B55",
                                confirmButtonText : $filter("translate")("common.ok"), // 네
                                cancelButtonText : $filter("translate")("common.no"), // 아니오
                                closeOnConfirm : false,
                                closeOnCancel : false
                            },
                            function (isConfirm) {
                                if (isConfirm) {
                                    inheritYn = true;
                                }
                                var content = {
                                    id : parameter.id,
@@ -860,6 +844,23 @@
                                    })()
                                };
                    if ($scope.vm.inheritPartners && $scope.vm.downTotalCount > 0) {
                        SweetAlert.swal({
                            title : $filter("translate")("issue.modifyDownIssue"), // 하위 이슈 변경
                            text : $filter("translate")("issue.wantToInheritPartnersOfParentIssue"), // 상위이슈의 파트너 정보(업체/ISP/호스팅)를 적용시키겠습니까?
                            type : "warning",
                            showCancelButton : true,
                            confirmButtonColor : "#DD6B55",
                            confirmButtonText : $filter("translate")("common.ok"), // 네
                            cancelButtonText : $filter("translate")("common.no"), // 아니오
                            closeOnConfirm : false,
                            closeOnCancel : false
                        },
                        function (isConfirm) {
                            if (isConfirm) {
                                inheritYn = true;
                            }
                                Issue.modify({
                                    method : "POST",
                                    file : (function () {
@@ -897,6 +898,43 @@
                                    $rootScope.spinner = false;
                                });
                            });
                    } else {
                        Issue.modify({
                            method : "POST",
                            file : (function () {
                                var files = [];
                                angular.forEach($scope.vm.form.files, function (file) {
                                    if (angular.isUndefined(file.id)) {
                                        files.push(file);
                                    }
                                });
                                return files;
                            })(),
                            //      data 속성으로 별도의 데이터 전송
                            fields : {
                                content : content
                            },
                            fileFormDataName : "file"
                        }).then(function (result) {
                            if (result.data.message.status === "success") {
                                $scope.fn.cancel();
                                //  이슈 상세 화면 요청
                                $rootScope.$broadcast("getIssueDetail", {
                                    id : parameter.id
                                });
                                $rootScope.$broadcast("getIssueList");
                            }
                            else {
                                SweetAlert.error($filter("translate")("issue.failedIssueModify"), result.data.message.message); // 이슈 수정 실패
                            }
                            $rootScope.spinner = false;
                        });
                    }
                }