From 9ea4a2d0385d48a0713a5bbc3c1a8967e10baae1 Mon Sep 17 00:00:00 2001 From: 이민희 <mhlee@maprex.co.kr> Date: 월, 20 12월 2021 11:00:50 +0900 Subject: [PATCH] 이슈 히스토리 하위이슈 문구 중복되는 문제 해결 --- src/main/webapp/views/issue/issueDetail.html | 61 ++++++++++++++++-------------- src/main/webapp/scripts/app/issue/issueDetail.controller.js | 32 ++++++++++------ src/main/webapp/assets/styles/main.css | 11 ++++- 3 files changed, 61 insertions(+), 43 deletions(-) diff --git a/src/main/webapp/assets/styles/main.css b/src/main/webapp/assets/styles/main.css index 78474af..e11c3e7 100644 --- a/src/main/webapp/assets/styles/main.css +++ b/src/main/webapp/assets/styles/main.css @@ -19409,7 +19409,7 @@ -ms-flex-align: center; /*align-items: center;*/ padding: 15px; - border-bottom: 1px solid rgba(0, 0, 0, 0.05); + border-bottom: 1px solid rgba(0, 0, 0, 0.3); position: relative; } @@ -19473,7 +19473,7 @@ .aei-content .aei-delete { position: absolute; top: 0px; - right: -10px; + right: 12px; color: rgba(0, 0, 0, 0.7); font-size: 0.5rem; cursor: pointer; @@ -28591,6 +28591,10 @@ margin-left: 30px !important; } +.ml-3per { + margin-left: 3.3%; +} + .m-0 { margin: 0 auto !important; @@ -29048,9 +29052,10 @@ } .dot { - color: #161617; + color: #15158a; font-size: 0.9rem; font-weight: bold; + margin-bottom: -15px; } .activity-text h6.creat .dot { diff --git a/src/main/webapp/scripts/app/issue/issueDetail.controller.js b/src/main/webapp/scripts/app/issue/issueDetail.controller.js index a635489..5df19b9 100644 --- a/src/main/webapp/scripts/app/issue/issueDetail.controller.js +++ b/src/main/webapp/scripts/app/issue/issueDetail.controller.js @@ -990,7 +990,7 @@ `` function updateActiveHistory() { $scope.vm.activeTab = 'ALL'; - //$scope.fn.makeActiveHistory(); + $scope.fn.makeActiveHistory(); } // �솢�룞 �씠�젰 留뚮뱾湲� @@ -1000,14 +1000,19 @@ $scope.vm.viewer.activeParentHistory = ""; $scope.vm.viewer.activeDownHistory = ""; $scope.vm.viewer.activeDownAllHistory = ""; + var downTitle = ""; // �븯�쐞�씠�뒋 �엳�뒪�넗由� for (var i=0; i<$scope.vm.viewer.issueDownVos.length; i++){ - $scope.vm.viewer.activeDownHistory = $scope.vm.viewer.issueDownVos[i].issueHistoryVos.concat($scope.vm.viewer.issueDownVos[i+1].issueHistoryVos); - i++; + if($scope.vm.viewer.issueDownVos.length > 1){ + $scope.vm.viewer.activeDownHistory = $scope.vm.viewer.issueDownVos[i].issueHistoryVos.concat($scope.vm.viewer.issueDownVos[i+1].issueHistoryVos); + i++; + }else { + $scope.vm.viewer.activeDownHistory = $scope.vm.viewer.issueDownVos[i].issueHistoryVos; + } } for (var i=0; i<$scope.vm.viewer.activeDownHistory.length; i++){ - $scope.vm.viewer.activeDownHistory[i].description - = "<div class='dot'>�븯�쐞�씠�뒋 : "+$scope.vm.viewer.activeDownHistory[i].title+"</div>" + $scope.vm.viewer.activeDownHistory[i].description; + downTitle = "<div class='dot' style='margin-bottom: -8px'>*�븯�쐞�씠�뒋 : "+$scope.vm.viewer.activeDownHistory[i].title+"</div>"; + $scope.vm.viewer.activeDownHistory[i].desc = downTitle + $scope.vm.viewer.activeDownHistory[i].description; } $scope.vm.viewer.activeDownHistory.sort(function (a, b) { //�궡由쇱감�닚 return a.registerDate > b.registerDate ? -1 : a.registerDate < b.registerDate ? 1 : 0; @@ -1015,13 +1020,13 @@ // �븯�쐞�씠�뒋 �뙎湲� �엳�뒪�넗由� for (var i=0; i<$scope.vm.viewer.issueDownVos.length; i++) { - $scope.vm.viewer.downComment = $scope.vm.viewer.issueDownVos[i].issueCommentVos.concat($scope.vm.viewer.issueDownVos[i+1].issueCommentVos); - i++; + if($scope.vm.viewer.issueDownVos.length > 1){ + $scope.vm.viewer.downComment = $scope.vm.viewer.issueDownVos[i].issueCommentVos.concat($scope.vm.viewer.issueDownVos[i+1].issueCommentVos); + i++; + } else { + $scope.vm.viewer.downComment = $scope.vm.viewer.issueDownVos[i].issueCommentVos; + } } - /*for (var i=0; i<$scope.vm.viewer.downComment.length; i++){ - $scope.vm.viewer.downComment[i].description - = $scope.vm.viewer.downComment[i].title +"�쓽 �뙎湲� : "+ $scope.vm.viewer.downComment[i].description; - }*/ $scope.vm.viewer.issueDownVos.sort(function (a, b) { //�궡由쇱감�닚 return a.registerDate > b.registerDate ? -1 : a.registerDate < b.registerDate ? 1 : 0; }); @@ -1031,8 +1036,12 @@ $scope.vm.viewer.activeHistory = $scope.vm.viewer.activeParentHistory.concat($scope.vm.viewer.activeDownAllHistory); }else { + $scope.vm.viewer.activeParentHistory = $scope.vm.viewer.issueCommentVos.concat($scope.vm.viewer.issueHistoryVos); $scope.vm.viewer.activeHistory = $scope.vm.viewer.issueCommentVos.concat($scope.vm.viewer.issueHistoryVos); } + $scope.vm.viewer.activeParentHistory.sort(function (a, b) { //�궡由쇱감�닚 + return a.registerDate > b.registerDate ? -1 : a.registerDate < b.registerDate ? 1 : 0; + }); $scope.vm.viewer.activeHistory.sort(function (a, b) { //�궡由쇱감�닚 return a.registerDate > b.registerDate ? -1 : a.registerDate < b.registerDate ? 1 : 0; }); @@ -1087,7 +1096,6 @@ $timeout(function () { SweetAlert.success($filter("translate")("common.deleteSucceeded"), result.data.message.message); // �궘�젣 �꽦怨� }, 100); - $scope.fn.getCommentList(); } else { diff --git a/src/main/webapp/views/issue/issueDetail.html b/src/main/webapp/views/issue/issueDetail.html index 0aa3b15..f5f0777 100644 --- a/src/main/webapp/views/issue/issueDetail.html +++ b/src/main/webapp/views/issue/issueDetail.html @@ -699,40 +699,45 @@ <!--<h6 ng-if="activeHistory.issueHistoryType == 'TOTAL'" translate="issue.summaryIssueActivity">�씠�뒋 �솢�룞 �궡�뿭 �슂�빟 <i class="os-icon os-icon-arrow-down"></i></h6>--> - <div dom-append dom="activeHistory.description"></div> + <div ng-if="!$root.isDefined(activeHistory.desc)" dom-append dom="activeHistory.description"></div> + <div ng-if="$root.isDefined(activeHistory.desc)" dom-append dom="activeHistory.desc"></div> </div> <!-- �뙎湲��씤 寃쎌슦 --> <div ng-if="!$root.isDefined(activeHistory.issueHistoryType)" ng-show="vm.viewer.title !== activeHistory.title"> <span class="dot"> - �븯�쐞�씠�뒋 : {{::activeHistory.title}} + *�븯�쐞�씠�뒋 : {{::activeHistory.title}} </span> </div> - <div class="aei-image" style="position: absolute; top: 30%" ng-if="!$root.isDefined(activeHistory.issueHistoryType)"> - <div class="user-avatar-w"> - <img alt="image" ng-src="{{::activeHistory.profile}}"> - </div> + <div class="aei-image" style="position: absolute; top: 30%" ng-if="!$root.isDefined(activeHistory.issueHistoryType)"> + <div class="user-avatar-w"> + <img ng-show="vm.viewer.title !== activeHistory.title" + style="margin-top: 15px" alt="image" ng-src="{{::activeHistory.profile}}"> + <img ng-show="vm.viewer.title === activeHistory.title" + alt="image" ng-src="{{::activeHistory.profile}}"> </div> - - + </div> <div class="aei-content" ng-if="!$root.isDefined(activeHistory.issueHistoryType)"> - <h6 class="aei-title mt-1" style="margin-left: 3.3%"> + <h6 class="aei-title mt-1 ml-3per"> {{::activeHistory.registerName}} </h6> - <div class="date-break mt-2" style="margin-left: 3.3%"> + <div class="date-break mt-2 ml-3per"> <span>{{::activeHistory.registerDate}}</span> </div> <div class="aei-delete" - ng-click="fn.removeComment(comment)" - ng-show="$root.user.id == comment.registerId"> + ng-click="fn.removeComment(activeHistory)" + ng-show="vm.viewer.modifyPermissionCheck || $root.user.id === activeHistory.registerId"> <i class="os-icon os-icon-close"></i> </div> <div class="chat-messages"> - <div class="message" style="margin-left: 3.3%"> + <div class="message ml-3per"> <div class="message-content"> <span class="issue-detail-word-break">{{::activeHistory.description}}</span> </div> + <!--<div class="message-content" ng-if="activeHistory.desc === null"> + <span class="issue-detail-word-break">{{::activeHistory.desc}}</span> + </div>--> </div> </div> @@ -761,7 +766,7 @@ </div> <div class="aei-delete" ng-click="fn.removeComment(comment)" - ng-show="$root.user.id == comment.registerId"> + ng-show="vm.viewer.modifyPermissionCheck || $root.user.id == comment.registerId"> <i class="os-icon os-icon-close"></i> </div> <div class="chat-messages"> @@ -781,7 +786,7 @@ 湲곕줉�씠 �뾾�뒿�땲�떎. </div> - <div class="ae-item row" ng-repeat="issueHistory in vm.viewer.activeParentHistory"> + <div class="ae-item" ng-repeat="issueHistory in vm.viewer.activeParentHistory"> <!--<h6 ng-if="issueHistory.issueHistoryType == 'TOTAL'" translate="issue.summaryIssueActivity">�씠�뒋 �솢�룞 �궡�뿭 �슂�빟 <i class="os-icon os-icon-arrow-down"></i> @@ -797,19 +802,19 @@ </div> <div class="aei-content" ng-if="!$root.isDefined(issueHistory.issueHistoryType)"> - <h6 class="aei-title mt-1" style="margin-left: 3.3%"> + <h6 class="aei-title mt-1 ml-3per"> {{::issueHistory.registerName}} </h6> - <div class="date-break mt-2" style="margin-left: 3.3%"> + <div class="date-break mt-2 ml-3per"> <span>{{::issueHistory.registerDate}}</span> </div> <div class="aei-delete" - ng-click="fn.removeComment(comment)" - ng-show="$root.user.id == comment.registerId"> + ng-click="fn.removeComment(issueHistory)" + ng-show="vm.viewer.modifyPermissionCheck || $root.user.id == issueHistory.registerId"> <i class="os-icon os-icon-close"></i> </div> <div class="chat-messages"> - <div class="message" style="margin-left: 3.3%"> + <div class="message ml-3per"> <div class="message-content"> <span class="issue-detail-word-break">{{::issueHistory.description}}</span> </div> @@ -826,29 +831,29 @@ <div class="ae-item row" ng-repeat="issueDownHistory in vm.viewer.activeDownAllHistory"> <!-- 湲곕줉�씤 寃쎌슦 --> <div class="aei-content" ng-if="$root.isDefined(issueDownHistory.issueHistoryType)"> - <div dom-append dom="issueDownHistory.description"></div> + <div dom-append dom="issueDownHistory.desc"></div> </div> <!-- �뙎湲��씤 寃쎌슦 --> - <div class="aei-content" ng-if="!$root.isDefined(issueDownHistory.issueHistoryType)"> + <div class="aei-content pb-3" ng-if="!$root.isDefined(issueDownHistory.issueHistoryType)"> <div class="dot"> - �븯�쐞�씠�뒋 : {{::issueDownHistory.title}} + *�븯�쐞�씠�뒋 : {{::issueDownHistory.title}} </div> </div> <div class="aei-image" style="position: absolute; top: 30%" ng-if="!$root.isDefined(issueDownHistory.issueHistoryType)"> <div class="user-avatar-w "> - <img alt="image" ng-src="{{::issueDownHistory.profile}}"> + <img style="margin-top: 15px" alt="image" ng-src="{{::issueDownHistory.profile}}"> </div> </div> <div class="aei-content" ng-if="!$root.isDefined(issueDownHistory.issueHistoryType)"> - <h6 class="aei-title mt-1" style="margin-left: 3.3%"> + <h6 class="aei-title mt-1 ml-3per"> {{::issueDownHistory.registerName}} </h6> <div class="date-break mt-2" style="margin-left: 3.3%"> <span>{{::issueDownHistory.registerDate}}</span> </div> <div class="aei-delete" - ng-click="fn.removeComment(comment)" - ng-show="$root.user.id == comment.registerId"> + ng-click="fn.removeComment(issueDownHistory)" + ng-show="vm.viewer.modifyPermissionCheck || $root.user.id == issueDownHistory.registerId"> <i class="os-icon os-icon-close"></i> </div> <div class="chat-messages"> @@ -888,7 +893,7 @@ </div> <div class="aei-delete" ng-click="fn.removeComment(comment)" - ng-show="$root.user.id == comment.registerId"> + ng-show="vm.viewer.modifyPermissionCheck || $root.user.id == comment.registerId"> <i class="os-icon os-icon-close"></i> </div> <div class="chat-messages"> -- Gitblit v1.8.0