diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
index f53e6c9..02e9323 100644
--- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
+++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
@@ -4511,38 +4511,46 @@ function ($scope, $rootScope, $compile, $http, $log, $location, $timeout, DA, Mo
//set modesty image visiblility true/false as per layer
// if(bodyRegionId.match('modestyImg3'))
+ var BRID='';
+ if (bodyRegionId.match('modestyImg') && document.getElementById('modestyTransCanavs_' + bodyRegionId)!=null) {
+ BRID = bodyRegionId[bodyRegionId.length - 1];
+ }
+ else if ((bodyRegionId == '2' || bodyRegionId == '3') && document.getElementById('modestyTransCanavs_modestyImg' + bodyRegionId) != null) {
+ BRID = bodyRegionId;
+ }
+ if (BRID != '') {
+ var layerInfo = new jinqJs()
+ .from($scope.layerInfoForModesty)
+ .where('bodyRegionId == ' + BRID)
+ .select();
+ if (layerInfo != undefined && layerInfo.length > 0) {
+ var lowerlayerNumberForModesty = layerInfo[0].lowerlayerNumberForModesty;
+ var HigherlayerNumberForModesty = layerInfo[0].HigherlayerNumberForModesty;
- var layerInfo = new jinqJs()
- .from($scope.layerInfoForModesty)
- .where('bodyRegionId == ' + bodyRegionId)
- .select();
- if (layerInfo != undefined && layerInfo.length > 0) {
- var lowerlayerNumberForModesty = layerInfo[0].lowerlayerNumberForModesty;
- var HigherlayerNumberForModesty = layerInfo[0].HigherlayerNumberForModesty;
-
- var modestyTransCanvases = $("canvas[id*='modestyTransCanavs']");
+ var modestyTransCanvases = $("canvas[id*='modestyTransCanavs']");
- if (modestyTransCanvases != null || modestyTransCanvases != undefined && modestyTransCanvases.length > 0) {
- for (var j = 0; j < modestyTransCanvases.length; j++) {
+ if (modestyTransCanvases != null || modestyTransCanvases != undefined && modestyTransCanvases.length > 0) {
+ for (var j = 0; j < modestyTransCanvases.length; j++) {
- if (modestyTransCanvases[j].id.match(bodyRegionId)) {
+ if (modestyTransCanvases[j].id.match(bodyRegionId)) {
- var modestyCanavs = document.getElementById(modestyTransCanvases[j].id);
+ var modestyCanavs = document.getElementById(modestyTransCanvases[j].id);
- if ((parseInt(lowerlayerNumberForModesty) <= parseInt($scope.layerNumber)) && (HigherlayerNumberForModesty) > parseInt($scope.layerNumber)) {
+ if ((parseInt(lowerlayerNumberForModesty) <= parseInt($scope.layerNumber)) && (HigherlayerNumberForModesty) > parseInt($scope.layerNumber)) {
- modestyCanavs.style.visibility = 'visible';
- }
- else {
+ modestyCanavs.style.visibility = 'visible';
+ }
+ else {
- modestyCanavs.style.visibility = 'hidden';
+ modestyCanavs.style.visibility = 'hidden';
+ }
}
- }
+ }
}
- }
+ }
}
}