diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js index ff75a92..c1860fb 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js @@ -7759,7 +7759,14 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo } - $scope.HighlightBodyOnListManagerSelection = function (actualTermNumber) { + $scope.HighlightBodyOnListManagerSelection = function (actualTermNumber, isTermListOptionClicked) { + //$rootScope.SelectedTermList = $("#termList").find("option[id=" + actualTermNumber + "]").val(); + + $rootScope.slectedActualTermNumber = actualTermNumber; + + if (isTermListOptionClicked == true) { + $scope.searchFilter = ''; + } $scope.CloseTransparencyBox(); @@ -8060,8 +8067,9 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo return Math.round(iReturnValue / nExistingZoom); } - $scope.refreshTermListOnSystemSelection = function (bodysystemId) { - + $rootScope.refreshTermListOnSystemSelection = function (bodysystemId) { + $rootScope.selectedBodySystemId = bodysystemId; + $rootScope.selectedBodySystemName = $('#bodySystems option[id="' + bodysystemId + '"]').val(); $('#termList').empty(); // $('#termList').innerHTML = ''; @@ -8460,11 +8468,11 @@ function OnZoom() }); } -function onListManagerTermSelection(id) { +function onListManagerTermSelection(id, isTermListOptionClicked) { var scope = angular.element(document.getElementById("daView")).scope(); scope.$apply(function () { - scope.HighlightBodyOnListManagerSelection(id); + scope.HighlightBodyOnListManagerSelection(id, isTermListOptionClicked); }); } diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js index 1f725f7..fe4c5c4 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js @@ -2542,23 +2542,39 @@ function ($rootScope, Modules, $log, $location, $timeout, DataService, Authentic $('#listManager').css('display', 'block'); $("#listManager").css("visibility", "visible"); - // $('#termList option[selected="selected"]').prop("selected", false); - // $("#termList").find("option[value=" + $rootScope.searchSelectedText + "]").prop("selected", true); - // $("#termList").find("option").css({ "background-color": "#ffffff", "color": "#000000" }); - // $("#termList").find("option[value=" + $rootScope.searchSelectedText + "]").css({ "background-color": "#3399FF", "color": "#ffffff" }); $('#listManager').draggable(); $rootScope.islistManagerEventAlredayDispachted = true; $rootScope.$broadcast('listManagerEvent', true); + + if ($rootScope.selectedBodySystemName == undefined && $rootScope.slectedActualTermNumber == undefined) { + $('#termList option[selected="selected"]').prop("selected", false); + $('#termList option[value="' + $rootScope.searchSelectedText + '"]').prop("selected", true); + $("#termList").find("option").css({ "background-color": "#ffffff", "color": "#000000" }); + $('#termList option[value="' + $rootScope.searchSelectedText + '"]').css({ "background-color": "#3399FF", "color": "#ffffff" }); + } + else { - $('#termList option[selected="selected"]').prop("selected", false); - $('#termList option[value="' + $rootScope.searchSelectedText + '"]').prop("selected", true); - $("#termList").find("option").css({ "background-color": "#ffffff", "color": "#000000" }); - $('#termList option[value="' + $rootScope.searchSelectedText + '"]').css({ "background-color": "#3399FF", "color": "#ffffff" }); + if ($rootScope.selectedBodySystemId == undefined) { + $rootScope.selectedBodySystemId = 0; + $rootScope.refreshTermListOnSystemSelection($rootScope.selectedBodySystemId); + } + else { + $rootScope.refreshTermListOnSystemSelection($rootScope.selectedBodySystemId); + } + + $('#bodySystems option[selected="selected"]').prop("selected", false); + $('#bodySystems option[value="' + $rootScope.selectedBodySystemName + '"]').prop("selected", true); + + // $('#termList option[selected="selected"]').prop("selected", false); + // $('#termList option[value="' + $rootScope.SelectedTermList + '"]').prop("selected", true); + //$("#termList").find("option").css({ "background-color": "#ffffff", "color": "#000000" }); + //$('#termList option[value="' + $rootScope.SelectedTermList + '"]').css({ "background-color": "#3399FF", "color": "#ffffff" }); $("#optionsListManagerTab").addClass("active"); + } } $rootScope.CloseListManager = function () { diff --git a/400-SOURCECODE/AIAHTML5.Web/index.html b/400-SOURCECODE/AIAHTML5.Web/index.html index 891151c..bcd60d0 100644 --- a/400-SOURCECODE/AIAHTML5.Web/index.html +++ b/400-SOURCECODE/AIAHTML5.Web/index.html @@ -793,6 +793,7 @@ left: 140px; display: none; z-index: 780000; + height:auto!important; } #listManager .annotation-modal-header { @@ -866,7 +867,7 @@