Commit ed442995c181fe1df563e8c614ec97eb8f186c37

Authored by Birendra
1 parent 648310f2

fix few change for cener

400-SOURCECODE/AIAHTML5.Web/app/controllers/CurrBuildController.js
@@ -2878,7 +2878,7 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ @@ -2878,7 +2878,7 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $
2878 for (var i = 0; i < $rootScope.DaWindowData.length; i++) { 2878 for (var i = 0; i < $rootScope.DaWindowData.length; i++) {
2879 $scope.updatedWindowListForSaveCB.push({ 2879 $scope.updatedWindowListForSaveCB.push({
2880 2880
2881 - bodySystemTermList: $rootScope.DaWindowData[i].BodySystemData, 2881 + // bodySystemTermList: $rootScope.DaWindowData[i].BodySystemData,
2882 isTitleBarVisible: false, //BodySystemData.isTitleBarVisible,//N 2882 isTitleBarVisible: false, //BodySystemData.isTitleBarVisible,//N
2883 highlightOptionsSelectedId: 0, 2883 highlightOptionsSelectedId: 0,
2884 selectedStructureID: 0,//N 2884 selectedStructureID: 0,//N
400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
@@ -135,8 +135,8 @@ AIA.controller(&quot;DAController&quot;, [&quot;$scope&quot;, &quot;$rootScope&quot;, &quot;$compile&quot;, &quot;$http&quot;, &quot;$l @@ -135,8 +135,8 @@ AIA.controller(&quot;DAController&quot;, [&quot;$scope&quot;, &quot;$rootScope&quot;, &quot;$compile&quot;, &quot;$http&quot;, &quot;$l
135 'minimised': false, 135 'minimised': false,
136 'maximised': false, 136 'maximised': false,
137 'id': 0, 137 'id': 0,
138 - 'moduleName': '',  
139 - 'mode': '', 138 + 'moduleName': 'DISSECTIBLE_ANATOMY',
  139 + 'mode': 'NORMAL',
140 'isCBAnnotationActive':false, 140 'isCBAnnotationActive':false,
141 'annotationData':{shapeStates:[],paintCanvasState:[]}, 141 'annotationData':{shapeStates:[],paintCanvasState:[]},
142 'transparencyBounds': [], 142 'transparencyBounds': [],
@@ -545,94 +545,127 @@ AIA.controller(&quot;DAController&quot;, [&quot;$scope&quot;, &quot;$rootScope&quot;, &quot;$compile&quot;, &quot;$http&quot;, &quot;$l @@ -545,94 +545,127 @@ AIA.controller(&quot;DAController&quot;, [&quot;$scope&quot;, &quot;$rootScope&quot;, &quot;$compile&quot;, &quot;$http&quot;, &quot;$l
545 //load json data for body view 545 //load json data for body view
546 $scope.loadDissectibleAnatomyData = function () { 546 $scope.loadDissectibleAnatomyData = function () {
547 547
548 - // clear data set by curriculum builder  
549 - $rootScope.isCallFromOtherModule = undefined;  
550 -  
551 - $rootScope.MULTI_VIEW_ID += 1  
552 -  
553 - var windowviewid = $rootScope.MULTI_VIEW_ID;  
554 -  
555 - if ($rootScope.refreshcheck == null) {  
556 - $location.path('/');  
557 - }  
558 - $scope.ScopeVariablesDeclare();  
559 -  
560 - // store exist module in module service 548 + if($rootScope.cernerIntegrationActive)
  549 + {
  550 + $rootScope.isCallFromOtherModule = true;
  551 + // store exist module in module service
561 var ExistData = ModuleService.getModuleData("DISSECTIBLE_ANATOMY"); 552 var ExistData = ModuleService.getModuleData("DISSECTIBLE_ANATOMY");
562 553
563 if (ExistData != undefined && ExistData.length > 0) { 554 if (ExistData != undefined && ExistData.length > 0) {
564 // clear all module data before open new module in cb 555 // clear all module data before open new module in cb
565 ModuleService.ClearWinDataByModule(ExistData.mType); 556 ModuleService.ClearWinDataByModule(ExistData.mType);
566 } 557 }
567 - var newWindowData = {  
568 - "mType": 'DISSECTIBLE_ANATOMY',  
569 - }; 558 + var newWindowData = JSON.parse(localStorage.getItem("daDataObject"));
570 ModuleService.setModuleData(newWindowData, 0); 559 ModuleService.setModuleData(newWindowData, 0);
  560 + // close/remove prev panel when in minimised mode
  561 +
  562 + if($rootScope.DaWindowData!=undefined)
  563 + {
  564 + if($rootScope.DaWindowData.length>0)
  565 + {
  566 + for(var x=0 ;x < $rootScope.DaWindowData.length;x++){
  567 + var winid=$rootScope.DaWindowData[x].multiwinid;
  568 + if ($('#daImagePanel_' + winid).html() != undefined) {
  569 + $('#daImagePanel_' + winid).remove();
  570 + }
  571 + }
  572 + $rootScope.DaWindowData=[];
  573 + }
  574 + }
  575 + $rootScope.ClearIframe();
  576 + $location.url('/da-body-view');
  577 + }
  578 + else
  579 + {
571 580
572 - // close/remove prev panel when in minimised mode  
573 -  
574 - if($rootScope.DaWindowData!=undefined)  
575 - {  
576 - if($rootScope.DaWindowData.length>0)  
577 - {  
578 - for(var x=0 ;x < $rootScope.DaWindowData.length;x++){  
579 - var winid=$rootScope.DaWindowData[x].multiwinid;  
580 - if ($('#daImagePanel_' + winid).html() != undefined) {  
581 - $('#daImagePanel_' + winid).remove();  
582 - }  
583 - }  
584 - $rootScope.DaWindowData=[];  
585 - } 581 + // clear data set by curriculum builder
  582 + $rootScope.isCallFromOtherModule = undefined;
  583 +
  584 + $rootScope.MULTI_VIEW_ID += 1
  585 +
  586 + var windowviewid = $rootScope.MULTI_VIEW_ID;
  587 +
  588 + if ($rootScope.refreshcheck == null) {
  589 + $location.path('/');
586 } 590 }
  591 + $scope.ScopeVariablesDeclare();
587 592
588 - $scope.initializeDAWindowData(windowviewid, true, undefined); 593 + // store exist module in module service
  594 + var ExistData = ModuleService.getModuleData("DISSECTIBLE_ANATOMY");
589 595
590 - //get current path  
591 - var currentURL = $location.path();  
592 - var selectedModuleName = '';  
593 - angular.forEach($rootScope.userModules, function (value, key) {  
594 - if (value.slug === currentURL.replace('/', '')) {  
595 - selectedModuleName = value.name;  
596 - $rootScope.currentActiveModuleTitle = selectedModuleName; 596 + if (ExistData != undefined && ExistData.length > 0) {
  597 + // clear all module data before open new module in cb
  598 + ModuleService.ClearWinDataByModule(ExistData.mType);
597 } 599 }
598 - }) 600 + var newWindowData = {
  601 + "mType": 'DISSECTIBLE_ANATOMY',
  602 + };
  603 + ModuleService.setModuleData(newWindowData, 0);
  604 +
  605 + // close/remove prev panel when in minimised mode
  606 +
  607 + if($rootScope.DaWindowData!=undefined)
  608 + {
  609 + if($rootScope.DaWindowData.length>0)
  610 + {
  611 + for(var x=0 ;x < $rootScope.DaWindowData.length;x++){
  612 + var winid=$rootScope.DaWindowData[x].multiwinid;
  613 + if ($('#daImagePanel_' + winid).html() != undefined) {
  614 + $('#daImagePanel_' + winid).remove();
  615 + }
  616 + }
  617 + $rootScope.DaWindowData=[];
  618 + }
  619 + }
  620 +
  621 + $scope.initializeDAWindowData(windowviewid, true, undefined);
599 622
  623 + //get current path
  624 + var currentURL = $location.path();
  625 + var selectedModuleName = '';
  626 + angular.forEach($rootScope.userModules, function (value, key) {
  627 + if (value.slug === currentURL.replace('/', '')) {
  628 + selectedModuleName = value.name;
  629 + $rootScope.currentActiveModuleTitle = selectedModuleName;
  630 + }
  631 + })
600 632
601 - $rootScope.ClearIframe();  
602 633
603 - //load common data  
604 - var commondataJsonPath = '~/../content/data/json/da/da_dat_common.json'; 634 + $rootScope.ClearIframe();
605 635
606 - DataService.getAnotherJson(commondataJsonPath)  
607 - .then(  
608 - function (result) { 636 + //load common data
  637 + var commondataJsonPath = '~/../content/data/json/da/da_dat_common.json';
609 638
610 - $rootScope.CommonData = result;  
611 - $http({ method: 'GET', url: '~/../content/data/json/da/da_dat_contentlist.json' }).success(function (data) { 639 + DataService.getAnotherJson(commondataJsonPath)
  640 + .then(
  641 + function (result) {
612 642
613 - $rootScope.BodyViewData = data;  
614 - $scope.getDAViewList(); 643 + $rootScope.CommonData = result;
  644 + $http({ method: 'GET', url: '~/../content/data/json/da/da_dat_contentlist.json' }).success(function (data) {
615 645
616 - })  
617 - .error(function (data, status, headers, config) {  
618 - console.log(data);  
619 - }); 646 + $rootScope.BodyViewData = data;
  647 + $scope.getDAViewList();
620 648
  649 + })
  650 + .error(function (data, status, headers, config) {
  651 + console.log(data);
  652 + });
621 653
622 - },  
623 - function (error) {  
624 - console.log(error.statusText)  
625 - }  
626 - )  
627 654
628 - // $('#daLoaderLabel').css('visibility', 'hidden')  
629 - $rootScope.isLoading = false; 655 + },
  656 + function (error) {
  657 + console.log(error.statusText)
  658 + }
  659 + )
630 660
  661 + // $('#daLoaderLabel').css('visibility', 'hidden')
  662 + $rootScope.isLoading = false;
631 663
632 664
633 - //push the details of open module in array $rootScope.openModules  
634 - $rootScope.openModules.push({ "ModuleId": 1 });  
635 665
  666 + //push the details of open module in array $rootScope.openModules
  667 + $rootScope.openModules.push({ "ModuleId": 1 });
  668 + }
636 669
637 } 670 }
638 671
@@ -864,19 +897,30 @@ AIA.controller(&quot;DAController&quot;, [&quot;$scope&quot;, &quot;$rootScope&quot;, &quot;$compile&quot;, &quot;$http&quot;, &quot;$l @@ -864,19 +897,30 @@ AIA.controller(&quot;DAController&quot;, [&quot;$scope&quot;, &quot;$rootScope&quot;, &quot;$compile&quot;, &quot;$http&quot;, &quot;$l
864 897
865 898
866 if ($rootScope.isCallFromOtherModule) { 899 if ($rootScope.isCallFromOtherModule) {
867 - // open JS panel for curriculum with define cornonate in CB jason  
868 - $rootScope.jsPanelWidth = $scope.daOpenInOtherModules.size.width;//1000;  
869 - $rootScope.jsPanelHeight = $scope.daOpenInOtherModules.size.height;  
870 - if($scope.daOpenInOtherModules.size.height<450)  
871 - $rootScope.jsPanelHeight = 450;  
872 -  
873 - $rootScope.jsPanelLeft = 320;  
874 -  
875 - $rootScope.jsPanelTop = $rootScope.cBModulejsPanelTop();  
876 - if($location.url()!= "/curriculum-builder-detail") { 900 + if($rootScope.cernerIntegrationActive)
  901 + {
  902 + $rootScope.jsPanelWidth = $(window).outerWidth() - 20;
  903 + $rootScope.jsPanelHeight = $(window).outerHeight() - 110;
877 $rootScope.jsPanelLeft = 1; 904 $rootScope.jsPanelLeft = 1;
  905 + $rootScope.jsPanelTop = 70;
  906 + $rootScope.cernerIntegrationActive=false;
878 } 907 }
  908 + else
  909 + {
  910 + // open JS panel for curriculum with define cornonate in CB jason
  911 + $rootScope.jsPanelWidth = $scope.daOpenInOtherModules.size.width;//1000;
  912 + $rootScope.jsPanelHeight = $scope.daOpenInOtherModules.size.height;
  913 + if($scope.daOpenInOtherModules.size.height<450)
  914 + $rootScope.jsPanelHeight = 450;
879 915
  916 + $rootScope.jsPanelLeft = 320;
  917 +
  918 + $rootScope.jsPanelTop = $rootScope.cBModulejsPanelTop();
  919 + if($location.url()!= "/curriculum-builder-detail") {
  920 + $rootScope.jsPanelLeft = 1;
  921 + }
  922 + }
  923 +
880 } 924 }
881 else { 925 else {
882 $rootScope.jsPanelWidth = $(window).outerWidth() - 20; 926 $rootScope.jsPanelWidth = $(window).outerWidth() - 20;
@@ -1828,8 +1872,26 @@ AIA.controller(&quot;DAController&quot;, [&quot;$scope&quot;, &quot;$rootScope&quot;, &quot;$compile&quot;, &quot;$http&quot;, &quot;$l @@ -1828,8 +1872,26 @@ AIA.controller(&quot;DAController&quot;, [&quot;$scope&quot;, &quot;$rootScope&quot;, &quot;$compile&quot;, &quot;$http&quot;, &quot;$l
1828 $("#btnNormalMode_" + windowviewid).removeClass("btn-primary"); 1872 $("#btnNormalMode_" + windowviewid).removeClass("btn-primary");
1829 } 1873 }
1830 } 1874 }
  1875 + //call time interval function until load Illustration data
  1876 + var timeintval = null;
  1877 + timeintval = $interval(function () {
  1878 + var vocabTermDataArray = $scope.GetwindowStoreData(windowviewid, 'vocabTermDataArray');
  1879 + if (vocabTermDataArray!=null) {
  1880 + $scope.stopVocab();
  1881 + $scope.setLayerNumberAndHighlightByTermListforCB(windowviewid);
  1882 + }
  1883 + else
  1884 + {
  1885 + console.log("waiting for Illustration Data");
  1886 + }
  1887 + }, 100);
1831 1888
1832 - $scope.setLayerNumberAndHighlightByTermListforCB(windowviewid); 1889 + $scope.stopVocab = function () {
  1890 + if (angular.isDefined(timeintval)) {
  1891 + $interval.cancel(timeintval);
  1892 + timeintval = undefined;
  1893 + }
  1894 + };
1833 1895
1834 } 1896 }
1835 1897
400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js
@@ -452,7 +452,7 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data @@ -452,7 +452,7 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data
452 452
453 $scope.loadOpenResourceWindow(newWindowData.mType, '#labBodyview'); 453 $scope.loadOpenResourceWindow(newWindowData.mType, '#labBodyview');
454 } 454 }
455 - 455 +
456 }, 500); 456 }, 500);
457 457
458 458
@@ -922,11 +922,10 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data @@ -922,11 +922,10 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data
922 $location.path('/'); 922 $location.path('/');
923 923
924 $timeout(function () { 924 $timeout(function () {
925 - if($rootScope.siteUrlInfo.mtype!=null)  
926 - { 925 +
927 //currently open CA 926 //currently open CA
928 $scope.RedirectToModule(); 927 $scope.RedirectToModule();
929 - } 928 +
930 }, 100); 929 }, 100);
931 930
932 } 931 }
@@ -1074,6 +1073,10 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data @@ -1074,6 +1073,10 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data
1074 if($rootScope.siteUrlInfo.mtype.toLowerCase()=='ca') 1073 if($rootScope.siteUrlInfo.mtype.toLowerCase()=='ca')
1075 $('#clinical-animations').trigger('click'); 1074 $('#clinical-animations').trigger('click');
1076 } 1075 }
  1076 + if ((localStorage.getItem("daDataObject")) != '') {
  1077 + //$rootScope.cernerIntegrationActive=true;
  1078 + // $('#da-view-list').trigger('click');
  1079 + }
1077 } 1080 }
1078 1081
1079 $scope.ValidateClientSiteUrl = function () { 1082 $scope.ValidateClientSiteUrl = function () {
@@ -7555,6 +7558,70 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data @@ -7555,6 +7558,70 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data
7555 $("#exportlogo").remove(); 7558 $("#exportlogo").remove();
7556 $("#filename").val(""); 7559 $("#filename").val("");
7557 7560
  7561 + if ($rootScope.DaWindowData != undefined && $rootScope.DaWindowData.length > 0) {
  7562 + for (var i = 0; i < $rootScope.DaWindowData.length; i++) {
  7563 + $scope.updatedWindowListForSaveCB={
  7564 +
  7565 + // bodySystemTermList: $rootScope.DaWindowData[i].BodySystemData,
  7566 + isTitleBarVisible: false,
  7567 + highlightOptionsSelectedId: 0,
  7568 + selectedStructureID: 0,//N
  7569 + contentDescriptorId: 0,
  7570 + callOuts: $rootScope.DaWindowData[i].CurriculumTermData,
  7571 +
  7572 + layerNumber: parseInt($rootScope.DaWindowData[i].layerNumber) + 1,
  7573 + isModestyOn: $rootScope.DaWindowData[i].ModestyValue,
  7574 +
  7575 + isTopToolBarVisible: false,
  7576 + clickedTermList: $rootScope.DaWindowData[i].fullTermlist,
  7577 + minimised: $rootScope.DaWindowData[i].minimised,
  7578 + windowTitle: $rootScope.DaWindowData[i].currentViewTitle,
  7579 +
  7580 + maximised: $rootScope.DaWindowData[i].maximised,
  7581 + size: {
  7582 + width: $rootScope.DaWindowData[i].width,
  7583 + height: $rootScope.DaWindowData[i].height
  7584 + },
  7585 + id: $rootScope.DaWindowData[i].voId,
  7586 +
  7587 + imageId: $rootScope.DaWindowData[i].imageId,
  7588 + position: {
  7589 + top: $rootScope.DaWindowData[i].top,
  7590 + left: $rootScope.DaWindowData[i].left,
  7591 + },
  7592 + mType: $rootScope.DaWindowData[i].moduleName,
  7593 + containsCapturedContent: true,
  7594 +
  7595 + zoom: $rootScope.DaWindowData[i].zoomInOut,
  7596 + skinId: $rootScope.DaWindowData[i].curentEthnicity,
  7597 + isResizeLock: false , //N
  7598 + mode: $rootScope.DaWindowData[i].mode,
  7599 + windowListId: 0,//N
  7600 + canvasVScrollX: $rootScope.DaWindowData[i].CanvasDivTopPosition,
  7601 + canvasHScrollX: $rootScope.DaWindowData[i].CanvasDivLeftPosition,
  7602 + isCallOutVisible: false,
  7603 + annotationData:$rootScope.DaWindowData[i].annotationData,
  7604 + isLeftToolBarVisible: false,
  7605 + isModuleLoaded: false,
  7606 + searchSelectedText: $rootScope.DaWindowData[i].searchSelectedText,
  7607 + prevId: $rootScope.DaWindowData[i].prevId,
  7608 +
  7609 + isTransparent: $rootScope.DaWindowData[i].isTransparent,
  7610 + transparencyBounds: $rootScope.DaWindowData[i].transparencyBounds,
  7611 + transparencyValue: $rootScope.DaWindowData[i].transNumber,
  7612 + layerNumberTransparency: $rootScope.DaWindowData[i].layerNumberTransparency,
  7613 + transparencyX: $rootScope.DaWindowData[i].transparencyX,
  7614 + transparencyY: $rootScope.DaWindowData[i].transparencyY,
  7615 + layerNumberBeforeTBDraw: $rootScope.DaWindowData[i].layerNumberBeforeTBDraw,
  7616 + showHideAnnotations: $rootScope.DaWindowData[i].showHideAnnotations
  7617 +
  7618 +
  7619 + }
  7620 + }
  7621 +
  7622 + }
  7623 +
  7624 + localStorage.setItem("daDataObject",JSON.stringify($scope.updatedWindowListForSaveCB) );
7558 if(result!=null && result!="ADMIN" ) 7625 if(result!=null && result!="ADMIN" )
7559 { 7626 {
7560 var userid= $rootScope.userData.Id; 7627 var userid= $rootScope.userData.Id;
400-SOURCECODE/AIAHTML5.Web/app/services/ModuleService.js
@@ -335,7 +335,7 @@ AIA.service(&#39;ModuleService&#39;, function ($http, DataService) { @@ -335,7 +335,7 @@ AIA.service(&#39;ModuleService&#39;, function ($http, DataService) {
335 mode: windowData.mode, 335 mode: windowData.mode,
336 isLeftToolBarVisible: windowData.isLeftToolBarVisible, 336 isLeftToolBarVisible: windowData.isLeftToolBarVisible,
337 contentDescriptorId: windowData.contentDescriptorId, 337 contentDescriptorId: windowData.contentDescriptorId,
338 - bodySystemTermList: windowData.bodySystemTermList, 338 + // bodySystemTermList: windowData.bodySystemTermList,
339 isTransparent: windowData.isTransparent, 339 isTransparent: windowData.isTransparent,
340 windowListId: windowData.windowListId, 340 windowListId: windowData.windowListId,
341 canvasVScrollX: windowData.canvasVScrollX, 341 canvasVScrollX: windowData.canvasVScrollX,