diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
index f98ac81..f7ddc27 100644
--- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
+++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
@@ -5684,7 +5684,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
}
//if user seelcted any term and serached before gender cnage then itshould be highlighted in chnaged gender
- if (($rootScope.isListManagerSelected == true) && ($rootScope.isGenderChnage == true)) {
+ if (($rootScope.isListManagerSelected == true) && (($rootScope.isGenderChnage == true) || $rootScope.isViewChange == true)) {
$scope.setLayerNumberAndHighlightByTermList();
@@ -5716,7 +5716,7 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
//if listanager is visisble then close it
- $rootScope.isListManagerSelected = false;
+ //$rootScope.isListManagerSelected = false;
$rootScope.CloseListManager();
@@ -7426,100 +7426,103 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
$scope.TermList = $scope.getTermNumberList($rootScope.actualTermNumber);
- var internalLayerNumberList = [];
- for (var i = 0; i < $scope.TermList.length; i++) {
- var layerNumber = $scope.TermList[i]._InternalLayerNumber
+ if (($scope.TermList != null || $scope.TermList != undefined) && $scope.TermList.length > 0) {
- internalLayerNumberList[i] = parseInt(layerNumber);
- }
+ var internalLayerNumberList = [];
+ for (var i = 0; i < $scope.TermList.length; i++) {
+ var layerNumber = $scope.TermList[i]._InternalLayerNumber
- internalLayerNumberList.sort(function (a, b) { return a - b })
- var internalLayerNumber = internalLayerNumberList[0]//.replace('00', '');
+ internalLayerNumberList[i] = parseInt(layerNumber);
+ }
- //3. get layer number
- if (internalLayerNumber >= DA[0].SKIN_START_INTERNAL_LAYER && internalLayerNumber <= DA[0].SKIN_END_INTERNAL_LAYER) {
+ internalLayerNumberList.sort(function (a, b) { return a - b })
+ var internalLayerNumber = internalLayerNumberList[0]//.replace('00', '');
- internalLayerNumber = DA[0].SKIN_DEFAULT_INTERNAL_LAYER;
- }
+ //3. get layer number
+ if (internalLayerNumber >= DA[0].SKIN_START_INTERNAL_LAYER && internalLayerNumber <= DA[0].SKIN_END_INTERNAL_LAYER) {
- var layerNumber;
- var matchedLayerNumber = new jinqJs()
- .from($rootScope.BodyLayerData.Layers.DataLayer)
- .where("_lni == " + internalLayerNumber)
- .select('_LayerNumber');
+ internalLayerNumber = DA[0].SKIN_DEFAULT_INTERNAL_LAYER;
+ }
- if (matchedLayerNumber == null || matchedLayerNumber.length == 0) {
- layerNumber = 0;
- }
- else {
- layerNumber = matchedLayerNumber[0]._LayerNumber
- }
+ var layerNumber;
+ var matchedLayerNumber = new jinqJs()
+ .from($rootScope.BodyLayerData.Layers.DataLayer)
+ .where("_lni == " + internalLayerNumber)
+ .select('_LayerNumber');
- if (layerNumber == 0) {
- layerNumber = $rootScope.totalLayers;
- }
- else {
- layerNumber = parseInt(layerNumber) - 1;
- }
+ if (matchedLayerNumber == null || matchedLayerNumber.length == 0) {
+ layerNumber = 0;
+ }
+ else {
+ layerNumber = matchedLayerNumber[0]._LayerNumber
+ }
+
+ if (layerNumber == 0) {
+ layerNumber = $rootScope.totalLayers;
+ }
+ else {
+ layerNumber = parseInt(layerNumber) - 1;
+ }
- $scope.layerNumber = layerNumber;
+ $scope.layerNumber = layerNumber;
- //4.get scroll position
- if ($rootScope.actualTermNumber != DA[0].SKIN_TERM_ID) {
+ //4.get scroll position
+ if ($rootScope.actualTermNumber != DA[0].SKIN_TERM_ID) {
- $scope.termCoordinate = $scope.getTermCoordinate($rootScope.actualTermNumber);
+ $scope.termCoordinate = $scope.getTermCoordinate($rootScope.actualTermNumber);
- }
+ }
- //5.
- $scope.matchdedDataOnLayer = new jinqJs()
- .from($rootScope.TermNumberData.TermData.Term)
- .where('_InternalLayerNumber == ' + internalLayerNumber)
- .select();
+ //5.
+ $scope.matchdedDataOnLayer = new jinqJs()
+ .from($rootScope.TermNumberData.TermData.Term)
+ .where('_InternalLayerNumber == ' + internalLayerNumber)
+ .select();
- if ($scope.matchdedDataOnLayer != null || $scope.matchdedDataOnLayer != undefined) {
+ if ($scope.matchdedDataOnLayer != null || $scope.matchdedDataOnLayer != undefined) {
- //6.
- var matchedDataonActualTerm = new jinqJs()
- .from($scope.matchdedDataOnLayer)
- .where('_ActualTermNumber == ' + $scope.actualTermNumber)
- .select('_TermNumber');
+ //6.
+ var matchedDataonActualTerm = new jinqJs()
+ .from($scope.matchdedDataOnLayer)
+ .where('_ActualTermNumber == ' + $scope.actualTermNumber)
+ .select('_TermNumber');
- if (matchedDataonActualTerm != null || matchedDataonActualTerm != undefined) {
+ if (matchedDataonActualTerm != null || matchedDataonActualTerm != undefined) {
- var termNo = matchedDataonActualTerm[0]._TermNumber.toString();
+ var termNo = matchedDataonActualTerm[0]._TermNumber.toString();
- //7.get termList
- $scope.fullTermlist = [];
- $scope.AllTerms = [];
+ //7.get termList
+ $scope.fullTermlist = [];
+ $scope.AllTerms = [];
- if (termNo != DA[0].figLeafTermId) {
+ if (termNo != DA[0].figLeafTermId) {
- $scope.getChildTermList(termNo);
- // $timeout(function () { $scope.getSiblings(termNo) }, 50);
- $scope.getSiblings(termNo)
- }
+ $scope.getChildTermList(termNo);
+ // $timeout(function () { $scope.getSiblings(termNo) }, 50);
+ $scope.getSiblings(termNo)
+ }
+ }
}
}
+ $('#txtlayerNumber').val((parseInt($scope.layerNumber)));
+ $('#layerChangeSlider').slider("option", "value", parseInt($rootScope.totalLayers) - parseInt($scope.layerNumber));
- $('#txtlayerNumber').val((parseInt($scope.layerNumber)));
- $('#layerChangeSlider').slider("option", "value", parseInt($rootScope.totalLayers) - parseInt($scope.layerNumber));
-
- //8.remove current layer canavses
- $scope.flushCanvas();
+ //8.remove current layer canavses
+ $scope.flushCanvas();
- //9.
- $timeout(function () {
- $rootScope.isHighLight = false;
- $('#sppeachBubble').css('display', 'none');
- $("#dot").css("display", "none");
+ //9.
+ $timeout(function () {
+ $rootScope.isHighLight = false;
+ $('#sppeachBubble').css('display', 'none');
+ $("#dot").css("display", "none");
- //redraw body of respective layer
- $scope.CalculateImageCordinates($rootScope.viewOrientationId)
- }, 500);
+ //redraw body of respective layer
+ $scope.CalculateImageCordinates($rootScope.viewOrientationId)
+ }, 500);
+
}
$scope.getChildTermList = function (termNo) {