Commit b952a6352dffdfd2dbe2917503a16e3a5c62a1b9
1 parent
a9a7faa4
merged DASearchBindingOldDev
Showing
2 changed files
with
12 additions
and
20 deletions
400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
@@ -639,13 +639,15 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo | @@ -639,13 +639,15 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo | ||
639 | 639 | ||
640 | //This is added as the $scope.VocabTermTxt can change while changing view also the li elements need to be removed | 640 | //This is added as the $scope.VocabTermTxt can change while changing view also the li elements need to be removed |
641 | //Remove the list and then Repopulate | 641 | //Remove the list and then Repopulate |
642 | - $('#searchListDiv').empty() | 642 | + if ($('#searchListDiv').html()!="") |
643 | + $('#searchListDiv').empty() | ||
643 | //Delay compile of ul li so that the remove of li is completed. | 644 | //Delay compile of ul li so that the remove of li is completed. |
644 | $timeout(function () { | 645 | $timeout(function () { |
645 | var $e2 = $('<ul id="termlistfilter" class="form-control dropdown-menu" style="height:90px;width:100%;overflow-y:scroll;position:absolute;display:none;z-index:1000;"><li ng-repeat="item in VocabTermTxt| filter:{ _TermText: searchFilter}">' + | 646 | var $e2 = $('<ul id="termlistfilter" class="form-control dropdown-menu" style="height:90px;width:100%;overflow-y:scroll;position:absolute;display:none;z-index:1000;"><li ng-repeat="item in VocabTermTxt| filter:{ _TermText: searchFilter}">' + |
646 | '<a id="{{item._ActualTermNumber}}" href="" onclick="selectTerm(event)">{{item._TermText}}</a>' + | 647 | '<a id="{{item._ActualTermNumber}}" href="" onclick="selectTerm(event)">{{item._TermText}}</a>' + |
647 | ' </li></ul>').appendTo('#searchListDiv') | 648 | ' </li></ul>').appendTo('#searchListDiv') |
648 | $compile($e2)($scope); | 649 | $compile($e2)($scope); |
650 | + | ||
649 | }, 500); | 651 | }, 500); |
650 | 652 | ||
651 | }, true); | 653 | }, true); |
@@ -7543,7 +7545,10 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo | @@ -7543,7 +7545,10 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo | ||
7543 | console.log('listManagerEvent'); | 7545 | console.log('listManagerEvent'); |
7544 | var systemList = $rootScope.CommonData.DACommonData.BodySystems.Item; | 7546 | var systemList = $rootScope.CommonData.DACommonData.BodySystems.Item; |
7545 | 7547 | ||
7546 | - $('#bodySystems').empty(); | 7548 | + var optionsLength = $('#bodySystems option').length;//.children('option').length; |
7549 | + console.log('optionsLength= ' + optionsLength) | ||
7550 | + if (optionsLength>0) | ||
7551 | + $('#bodySystems').empty(); | ||
7547 | 7552 | ||
7548 | 7553 | ||
7549 | var $all = $('<option id="0" selected="">All</option>').appendTo('#bodySystems'); | 7554 | var $all = $('<option id="0" selected="">All</option>').appendTo('#bodySystems'); |
@@ -7577,7 +7582,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo | @@ -7577,7 +7582,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo | ||
7577 | } | 7582 | } |
7578 | 7583 | ||
7579 | } | 7584 | } |
7580 | - | 7585 | + |
7581 | 7586 | ||
7582 | 7587 | ||
7583 | }); | 7588 | }); |
400-SOURCECODE/AIAHTML5.Web/app/views/da/da-view.html
@@ -280,30 +280,17 @@ | @@ -280,30 +280,17 @@ | ||
280 | <div class=""> | 280 | <div class=""> |
281 | <div class="input-group col-sm-8 col-xs-7 col-md-10 pull-left"> | 281 | <div class="input-group col-sm-8 col-xs-7 col-md-10 pull-left"> |
282 | 282 | ||
283 | - <input type="text" class="form-control input-sm pull-left" id="typedtermname" ng-blur="HideSearch()" onclick="OnSearch()" ondblclick="OnSearch()" ng-model="searchFilter" ng-change="resetSearchListView()" " placeholder=" search..."> | 283 | + <input type="text" class="form-control input-sm pull-left" id="typedtermname" ng-blur="HideSearch()" onclick="OnSearch()" ondblclick="OnSearch()" ng-model="searchFilter" ng-change="resetSearchListView()" placeholder=" search..."> |
284 | 284 | ||
285 | <div id="backdrop" ng-show="IsSearchVisible"> | 285 | <div id="backdrop" ng-show="IsSearchVisible"> |
286 | <div id="searchListDiv" class="col-sm-12 col-xs-12 col-md-12 col-lg-12 pull-left"> | 286 | <div id="searchListDiv" class="col-sm-12 col-xs-12 col-md-12 col-lg-12 pull-left"> |
287 | - <!--#Bug 6591--> | ||
288 | - <!--<ul id="termlistfilter" class="form-control dropdown-menu" style="height:90px;width:100%;overflow-y:scroll;position:absolute;display:none;z-index:1000;"> | ||
289 | - <li ng-repeat="item in VocabTermTxt| filter:{ _TermText: searchFilter}"> | ||
290 | - <a id="{{item._ActualTermNumber}}" href="" onclick="selectTerm(event)">{{item._TermText}}</a> | ||
291 | - </li> | ||
292 | - </ul>--> | 287 | + |
293 | </div> | 288 | </div> |
294 | </div> | 289 | </div> |
295 | - <!--</div>--> | ||
296 | 290 | ||
297 | </div> | 291 | </div> |
298 | <div class="btn-group"> | 292 | <div class="btn-group"> |
299 | - <!--<button type="button" style="padding:0px 0px 10px 1px !important;background-color:rgba(255,255,255,0.0); border:none;" class="btn btn-success dropdown-toggle btn-sm" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> | ||
300 | - <img src="~/../content/images/DA/go-to.png" style="height: 30px;width:50px"> | ||
301 | - </button> | ||
302 | - <ul class="dropdown-menu" style="width:100%;"> | ||
303 | - <li><a href="#">{{currentTitleFromJson}}</a></li> | ||
304 | - <li role="separator" class="divider"></li> | ||
305 | - <li><a href="#">All</a></li> | ||
306 | - </ul>--> | 293 | + |
307 | <button type="button" id="btnDATermSearch" style="padding:0px 0px 10px 1px !important;background-color:rgba(255,255,255,0.0); border:none;" class="btn btn-success btn-sm" ng-mousedown="OnSearchBtnClick($event)"> | 294 | <button type="button" id="btnDATermSearch" style="padding:0px 0px 10px 1px !important;background-color:rgba(255,255,255,0.0); border:none;" class="btn btn-success btn-sm" ng-mousedown="OnSearchBtnClick($event)"> |
308 | <img src="~/../content/images/DA/go-to.png" style="height: 30px;width:50px"> | 295 | <img src="~/../content/images/DA/go-to.png" style="height: 30px;width:50px"> |
309 | </button> | 296 | </button> |
@@ -315,7 +302,7 @@ | @@ -315,7 +302,7 @@ | ||
315 | 302 | ||
316 | <div class="dropdown-menu active" id="navigatorDiv" style="min-height:auto; min-width:auto; "> | 303 | <div class="dropdown-menu active" id="navigatorDiv" style="min-height:auto; min-width:auto; "> |
317 | <div id="containment-wrapper" align="center" style="min-width:auto;height:119px; "> | 304 | <div id="containment-wrapper" align="center" style="min-width:auto;height:119px; "> |
318 | - <img id="navimg" alt=""></img> | 305 | + <img id="navimg" alt=""/> |
319 | <div id="draggable" class="draggable ui-widget-content" ng-mouseup="ScrollCanvasDiv()" ng-style="dragdivposition"> | 306 | <div id="draggable" class="draggable ui-widget-content" ng-mouseup="ScrollCanvasDiv()" ng-style="dragdivposition"> |
320 | </div> | 307 | </div> |
321 | </div> | 308 | </div> |