Commit 69e170eef35f6c69cf94a22a10527f11298225e2
1 parent
e5997e04
Commit Changes
Showing
1 changed file
with
7 additions
and
20 deletions
400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
... | ... | @@ -1347,7 +1347,6 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l |
1347 | 1347 | } |
1348 | 1348 | } |
1349 | 1349 | else { |
1350 | - // debugger; | |
1351 | 1350 | //below 4 bodyviews have only single body region |
1352 | 1351 | if (($rootScope.voId == '9') || ($rootScope.voId == '11') || ($rootScope.voId == '10') || ($rootScope.voId == '12')) { |
1353 | 1352 | var bodyRegion = SelectedLayerData.BodyRegion._BodyRegionId; |
... | ... | @@ -1357,7 +1356,6 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l |
1357 | 1356 | } |
1358 | 1357 | else // it is for other body view which have multiple body regions and layer no > 0 |
1359 | 1358 | { |
1360 | - // debugger; | |
1361 | 1359 | if (SelectedLayerData.BodyRegion.length > 0) { |
1362 | 1360 | for (var z = 0; z <= SelectedLayerData.BodyRegion.length; z++) { |
1363 | 1361 | var bodyRegion = SelectedLayerData.BodyRegion[z]._BodyRegionId; |
... | ... | @@ -8377,7 +8375,6 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l |
8377 | 8375 | |
8378 | 8376 | |
8379 | 8377 | $scope.ShowSearch = function () { |
8380 | - | |
8381 | 8378 | var primaryLexiconIndex; |
8382 | 8379 | for (var i = 0; i <= $rootScope.vocabTermDataArray.length - 1; i++) { |
8383 | 8380 | if ($rootScope.vocabTermDataArray[i].language == $rootScope.lexiconLanguageArray[0].language) { |
... | ... | @@ -8398,13 +8395,6 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l |
8398 | 8395 | $('#searchListDiv').empty() |
8399 | 8396 | //Delay compile of ul li so that the remove of li is completed. |
8400 | 8397 | $timeout(function () { |
8401 | - //var $e2 = $('<ul id="termlistfilter" class="form-control dropdown-menu" style="height:90px;width:100%;overflow-y:scroll;position:absolute;display:none;z-index:60001;"><li ng-repeat="item in vocabTermDataArray[0].vocabTermTxt| filter:{ _TermText: searchFilter}">' + | |
8402 | - // '<a id="{{item._ActualTermNumber}}" href="" onclick="selectTerm(event)">{{item._TermText}}</a>' + | |
8403 | - // ' </li></ul>').appendTo('#searchListDiv') | |
8404 | - //$compile($e2)($scope); | |
8405 | - | |
8406 | - $rootScope.isSearchInputClicked = true; | |
8407 | - | |
8408 | 8398 | console.log("INSIDE WATCH. LIST IS CREATED"); |
8409 | 8399 | $scope.isSearchDataLoaded = true; |
8410 | 8400 | |
... | ... | @@ -8436,8 +8426,13 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l |
8436 | 8426 | '<a id="{{item._ActualTermNumber}}" href="" onclick="selectTerm(event)">{{item._TermText}}</a>' + |
8437 | 8427 | ' </li></ul>').appendTo('#searchListDiv') |
8438 | 8428 | $compile($e2)($scope); |
8439 | - | |
8440 | 8429 | document.getElementById("termlistfilter").style.display = "block"; |
8430 | + $timeout(function () { | |
8431 | + $rootScope.searchListArray = []; | |
8432 | + $("#backdrop > #searchListDiv > #termlistfilter > li").each(function (key, value) { | |
8433 | + $rootScope.searchListArray.push({ "name": $(this).find("a").html(), "id": $(this).find("a").attr("id") }); | |
8434 | + }); | |
8435 | + }, 100); | |
8441 | 8436 | } |
8442 | 8437 | else { |
8443 | 8438 | $rootScope.loadSearchData(); |
... | ... | @@ -8445,15 +8440,7 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l |
8445 | 8440 | $scope.ShowSearch(); |
8446 | 8441 | } |
8447 | 8442 | } |
8448 | - | |
8449 | - if ($rootScope.isSearchInputClicked == true) { | |
8450 | - $rootScope.isSearchInputClicked = false; | |
8451 | - $rootScope.searchListArray = []; | |
8452 | - $("#backdrop > #searchListDiv > #termlistfilter > li").each(function (key, value) { | |
8453 | - $rootScope.searchListArray.push({ "name": $(this).find("a").html(), "id": $(this).find("a").attr("id") }); | |
8454 | - }); | |
8455 | - | |
8456 | - } | |
8443 | + | |
8457 | 8444 | |
8458 | 8445 | }, 500); |
8459 | 8446 | ... | ... |