Commit 7c37f83f19a3275983ef9c958f35ee104e3ad5da
1 parent
32cc4b1a
Created Method for DA and AA for Save CB
Showing
4 changed files
with
284 additions
and
102 deletions
400-SOURCECODE/AIAHTML5.Web/app/controllers/CIController.js
... | ... | @@ -1109,8 +1109,8 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout |
1109 | 1109 | |
1110 | 1110 | $(document).on("click", "#" + $scope.jsPanelID + " .jsPanel-hdr .jsPanel-hdr-r .jsPanel-btn-min #minSpan", function (event) { |
1111 | 1111 | var currentPanelId = $(event.target).parent().parent().parent().parent().attr('id'); |
1112 | - var len = (currentPanelId).split("_").length; | |
1113 | - windowviewid = $scope.jsPanelCI.on('jspanelstatechange' , event); | |
1112 | + var len = (currentPanelId).split("_").length; | |
1113 | + var windowviewid = (currentPanelId).split("_")[len - 1]; | |
1114 | 1114 | $scope.SetCIwindowStoreData(windowviewid, 'maximised', false); |
1115 | 1115 | $scope.SetCIwindowStoreData(windowviewid, 'minimised', true); |
1116 | 1116 | ... | ... |
400-SOURCECODE/AIAHTML5.Web/app/controllers/CurrBuildController.js
... | ... | @@ -2327,6 +2327,7 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ |
2327 | 2327 | } |
2328 | 2328 | } |
2329 | 2329 | |
2330 | + //Save DISSECTIBLE_ANATOMY activity for CB | |
2330 | 2331 | $scope.saveCIWindowActivity = function (currentId) { |
2331 | 2332 | if ($rootScope.CIWindowData != undefined && $rootScope.CIWindowData.length > 0 ) { |
2332 | 2333 | for (var i = 0; i < $rootScope.CIWindowData.length; i++) { |
... | ... | @@ -2360,6 +2361,7 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ |
2360 | 2361 | |
2361 | 2362 | } |
2362 | 2363 | |
2364 | + //Save CLINICAL_ANIMATIONS activity for CB | |
2363 | 2365 | $scope.saveCAWindowActivity = function (currentId) { |
2364 | 2366 | if ($rootScope.CAWindowData != undefined && $rootScope.CAWindowData.length > 0) { |
2365 | 2367 | for (var i = 0; i < $rootScope.CAWindowData.length; i++) { |
... | ... | @@ -2392,6 +2394,7 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ |
2392 | 2394 | } |
2393 | 2395 | } |
2394 | 2396 | |
2397 | + //Save THREE_D_ANATOMY activity for CB | |
2395 | 2398 | $scope.save3DWindowActivity = function (currentId) { |
2396 | 2399 | if ($rootScope.TheeDWindowData != undefined && $rootScope.TheeDWindowData.length > 0) { |
2397 | 2400 | for (var i = 0; i < $rootScope.TheeDWindowData.length; i++) { |
... | ... | @@ -2408,7 +2411,7 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ |
2408 | 2411 | height: $rootScope.TheeDWindowData[i].height, |
2409 | 2412 | width: $rootScope.TheeDWindowData[i].width |
2410 | 2413 | }, |
2411 | - textVisible: $rootScope.TheeDWindowData[i].isTextVisible, | |
2414 | + //textVisible: $rootScope.TheeDWindowData[i].isTextVisible, | |
2412 | 2415 | imageId: $rootScope.TheeDWindowData[i].imageId, |
2413 | 2416 | minimised: $rootScope.TheeDWindowData[i].minimised, |
2414 | 2417 | windowTitle: $rootScope.TheeDWindowData[i].currentViewTitle, |
... | ... | @@ -2426,6 +2429,39 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ |
2426 | 2429 | } |
2427 | 2430 | } |
2428 | 2431 | |
2432 | + //Save MY_PICTURES activity for CB | |
2433 | + $scope.saveMyPictureWindowActivity = function (currentId) { | |
2434 | + // if ($rootScope.TheeDWindowData != undefined && $rootScope.TheeDWindowData.length > 0) { | |
2435 | + for (var i = 0; i < $rootScope.TheeDWindowData.length; i++) { | |
2436 | + $scope.updatedWindowListForSaveCB.push({ | |
2437 | + | |
2438 | + containsCapturedContent: true,//$rootScope.TheeDWindowData[i] // N | |
2439 | + //annotationData: "",//$rootScope.TheeDWindowData[i] N | |
2440 | + contextMenu: { lockResize: true, hideTitleBar: true }, | |
2441 | + position: { | |
2442 | + top: $rootScope.TheeDWindowData[i].top, | |
2443 | + left: $rootScope.TheeDWindowData[i].left, | |
2444 | + }, | |
2445 | + size: { | |
2446 | + height: $rootScope.TheeDWindowData[i].height, | |
2447 | + width: $rootScope.TheeDWindowData[i].width | |
2448 | + }, | |
2449 | + imageId: $rootScope.TheeDWindowData[i].imageId, | |
2450 | + minimised: $rootScope.TheeDWindowData[i].minimised, | |
2451 | + windowTitle: $rootScope.TheeDWindowData[i].currentViewTitle, | |
2452 | + maximised: $rootScope.TheeDWindowData[i].maximised, | |
2453 | + mType: $rootScope.TheeDWindowData[i].moduleName, | |
2454 | + id: $rootScope.TheeDWindowData[i].imageId, | |
2455 | + windowListId: 0, //$rootScope.TheeDWindowData[i] // N | |
2456 | + scrollPosition: { vertical: 0, horizontal: 0 }, | |
2457 | + imageSource: "" | |
2458 | + }); | |
2459 | + } | |
2460 | + //$rootScope.TheeDWindowData = []; | |
2461 | + //} | |
2462 | + } | |
2463 | + | |
2464 | + //Save ATLAS_ANATOMY activity for CB | |
2429 | 2465 | $scope.saveAAWindowActivity = function () { |
2430 | 2466 | |
2431 | 2467 | if ($rootScope.AAWindowData != undefined && $rootScope.AAWindowData.length > 0) { |
... | ... | @@ -2463,22 +2499,96 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ |
2463 | 2499 | }, |
2464 | 2500 | mType: $rootScope.AAWindowData[i].moduleName, |
2465 | 2501 | containsCapturedContent: true, |
2466 | - contextMenu: { hideLeftBar: false, hideTitleBar: false, hideTopToolBar: false, lockResize: false } | |
2502 | + contextMenu: { hideLeftBar: false, hideTitleBar: false, hideTopToolBar: false, lockResize: false }, | |
2503 | + activePinArray: $rootScope.AAWindowData[i].activePinArray, // Selected PINID on Body | |
2504 | + sliderVal: $rootScope.AAWindowData[i].sliderVal | |
2467 | 2505 | |
2468 | 2506 | |
2469 | 2507 | }); |
2470 | 2508 | } |
2471 | 2509 | $rootScope.AAWindowData = []; |
2472 | 2510 | } |
2511 | + } | |
2512 | + | |
2513 | + //Save DISSECTIBLE_ANATOMY activity for CB | |
2514 | + $scope.saveDAWindowActivity = function () { | |
2515 | + | |
2516 | + if ($rootScope.DaWindowData != undefined && $rootScope.DaWindowData.length > 0) { | |
2517 | + for (var i = 0; i < $rootScope.DaWindowData.length; i++) { | |
2518 | + $scope.updatedWindowListForSaveCB.push({ | |
2519 | + | |
2520 | + bodySystemTermList: $rootScope.DaWindowData[i].BodySystemData, | |
2521 | + isTitleBarVisible: false, //BodySystemData.isTitleBarVisible,//N | |
2522 | + highlightOptionsSelectedId: 0, | |
2523 | + selectedStructureID: 0,//N | |
2524 | + contentDescriptorId: 0, | |
2525 | + callOuts: $rootScope.DaWindowData[i].CurriculumTermData, | |
2526 | + hideAllPins: $rootScope.DaWindowData[i].isHidePinBtnClicked, | |
2527 | + selectedCallouts: $rootScope.DaWindowData[i].CBselectedpinCordinate, | |
2528 | + layerNumber: $rootScope.DaWindowData[i].currentLayerNumber, | |
2529 | + isModestyOn: $rootScope.DaWindowData[i].isModestyOn, | |
2530 | + isTransparent: $rootScope.DaWindowData[i].isTransparencyActivated, | |
2531 | + isTopToolBarVisible: false, //$rootScope.DaWindowData[i].isTopToolBarVisible, | |
2532 | + clickedTermList: $rootScope.DaWindowData[i].fullTermlist, | |
2533 | + minimised: $rootScope.DaWindowData[i].minimised, | |
2534 | + windowTitle: $rootScope.DaWindowData[i].currentViewTitle, | |
2535 | + //scrollPosition: { | |
2536 | + // vertical: $rootScope.DaWindowData[i].verticalScroll, | |
2537 | + // horizontal: $rootScope.DaWindowData[i].horizontalScroll | |
2538 | + //}, | |
2539 | + selectedPins: $rootScope.DaWindowData[i].clickedPins, | |
2540 | + maximised: $rootScope.DaWindowData[i].maximised, | |
2541 | + size: { | |
2542 | + width: $rootScope.DaWindowData[i].width, | |
2543 | + height: $rootScope.DaWindowData[i].height | |
2544 | + }, | |
2545 | + id: $rootScope.DaWindowData[i].imageId, | |
2546 | + //showSelectedPins: $rootScope.DaWindowData[i].isShowSelectedSystemPinsClicked, | |
2547 | + // hideCallOuts: false,//N | |
2548 | + //showAllPins: $rootScope.DaWindowData[i].isShowBodyWithCBPinData,//N | |
2549 | + //scaleIndex: 0,//N | |
2550 | + //bodySystemId: $rootScope.DaWindowData[i].SelectedSystemID, | |
2551 | + //position: { x: 840, y: 263 }, | |
2552 | + imageId: $rootScope.DaWindowData[i].imageId, | |
2553 | + position: { | |
2554 | + top: $rootScope.DaWindowData[i].top, | |
2555 | + left: $rootScope.DaWindowData[i].left, | |
2556 | + }, | |
2557 | + mType: $rootScope.DaWindowData[i].moduleName, | |
2558 | + containsCapturedContent: true, | |
2559 | + //contextMenu: { hideLeftBar: false, hideTitleBar: false, hideTopToolBar: false, lockResize: false }, | |
2560 | + //activePinArray: $rootScope.DaWindowData[i].activePinArray, // Selected PINID on Body | |
2561 | + //sliderVal: $rootScope.DaWindowData[i].sliderVal, | |
2562 | + zoom: $rootScope.DaWindowData[i].zoomInOut, | |
2563 | + skinId: $rootScope.DaWindowData[i].genderId, | |
2564 | + isResizeLock: false , //.isResizeLock,//N | |
2565 | + mode: $rootScope.DaWindowData[i].isNormalMode, | |
2566 | + windowListId: 0,//windowData.windowListId,//25 | |
2567 | + canvasVScrollX: 0,//canvasVScrollX,//N | |
2568 | + canvasHScrollX: 0,//canvasHScrollX,//N | |
2569 | + isCallOutVisible: false, | |
2570 | + annotationData: "", // .annotationData,//24 | |
2571 | + transparencyBounds: 0,//windowData.transparencyBounds, | |
2572 | + isLeftToolBarVisible: false, //windowData.isLeftToolBarVisible,//N | |
2573 | + isModuleLoaded: false, //.isModuleLoaded,//N | |
2574 | + transparencyValue: 0,//N | |
2575 | + layerNumberTransparency: false, //layerNumberTransparency,//N | |
2576 | + searchSelectedText: $rootScope.DaWindowData[i].searchSelectedText, | |
2577 | + prevId: $rootScope.DaWindowData[i].prevId //ActualTermnumber for chnages body image | |
2578 | + | |
2579 | + }); | |
2580 | + } | |
2581 | + $rootScope.DaWindowData = []; | |
2473 | 2582 | } |
2474 | - | |
2583 | + } | |
2584 | + | |
2475 | 2585 | $scope.updateWindowsContentForSaveCB = function (currentId) { |
2476 | 2586 | |
2477 | 2587 | //$scope.saveDAWindowActivity(); |
2478 | 2588 | //$scope.saveAAWindowActivity(currentId); |
2479 | 2589 | //$scope.saveCIWindowActivity(currentId); |
2480 | 2590 | //$scope.saveCAWindowActivity(); |
2481 | - $scope.save3DWindowActivity(); | |
2591 | + //$scope.save3DWindowActivity(); | |
2482 | 2592 | //$scope.savePicWindowActivity($scope.windowDataforCB); |
2483 | 2593 | if ($scope.updatedWindowListForSaveCB.length > 0) { |
2484 | 2594 | findKeyForChange($rootScope.contentNotesForSaveCB, currentId); |
... | ... | @@ -2495,7 +2605,6 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ |
2495 | 2605 | |
2496 | 2606 | |
2497 | 2607 | //$rootScope.updateWindowsContentForSaveCB = function (windowData) { |
2498 | - | |
2499 | 2608 | // //findKeyForChange($scope.windowDataforCB, keyname) |
2500 | 2609 | // //if ($scope.selectedKey.length > 0) { |
2501 | 2610 | // // for (var x = 0 ; x < $scope.selectedKey.length; x++) { |
... | ... | @@ -2516,60 +2625,7 @@ function ($scope, $rootScope, pages, log, Modules, $http, $compile, $location, $ |
2516 | 2625 | // // }) |
2517 | 2626 | // // .at(column[index].keyname = keyname); |
2518 | 2627 | |
2519 | - // $scope.windowDataforCB.push({ | |
2520 | - // //slideId: currentId,//SlideNo, | |
2521 | - // //currentWindowId: windowId, | |
2522 | - // mType: windowData.mType, | |
2523 | - // layerNumber: windowData.layerNumber, | |
2524 | - // currentBodyViewId: windowData.voId, | |
2525 | - // windowTitle: windowData.currentViewTitle, | |
2526 | - // skinId: windowData.genderId, | |
2527 | - // isModestyOn: windowData.isModestyOn, | |
2528 | - // //size: windowData.size, | |
2529 | - // //position: windowData.position, | |
2530 | - // position: { | |
2531 | - // top: $rootScope.jsPanelTop, | |
2532 | - // left: $rootScope.jsPanelLeft, | |
2533 | - // }, | |
2534 | - | |
2535 | - // size: { | |
2536 | - // width: $rootScope.jsPanelWidth, | |
2537 | - // height: $rootScope.jsPanelHeight | |
2538 | - // }, | |
2539 | - // zoom: windowData.zoomInOut, | |
2540 | - | |
2541 | - // maximised:windowData.maximised,//Not Found | |
2542 | - // minimised:windowData.minimised,//Not Found | |
2543 | - // highlightOptionsSelectedId: windowData.highlightOptionsSelectedId,//Not Found | |
2544 | - // selectedStructureId: windowData.selectedStructureId,//Not Found | |
2545 | - // isModuleLoaded: windowData.isModuleLoaded,//N | |
2546 | - // isTopToolBarVisible: windowData.isTopToolBarVisible,//N | |
2547 | - // transparencyValue: windowData.transparencyValue,//N | |
2548 | - // imageId: windowData.imageId,//N | |
2549 | - // containsCapturedContent: windowData.containsCapturedContent,//N | |
2550 | - // layerNumberTransparency: windowData.layerNumberTransparency,//N | |
2551 | - | |
2552 | - // isTitleBarVisible: windowData.isTitleBarVisible,//N | |
2553 | - // clickedTermList: windowData.fullTermlist, | |
2554 | - // isResizeLock: windowData.isResizeLock,//N | |
2555 | - // mode: windowData.isNormalMode, | |
2556 | - // isLeftToolBarVisible: windowData.isLeftToolBarVisible,//N | |
2557 | - // contentDescriptorId: windowData.contentDescriptorId,//6 | |
2558 | - // bodySystemTermList: windowData.BodySystemData, | |
2559 | - // isTransparent: windowData.isTransparencyActivated, | |
2560 | - // windowListId: windowData.windowListId,//25 | |
2561 | - // canvasVScrollX: windowData.canvasVScrollX,//N | |
2562 | - // canvasHScrollX: windowData.canvasHScrollX,//N | |
2563 | - // callOuts: windowData.CurriculumTermData, | |
2564 | - | |
2565 | - // isCallOutVisible: windowData.isCallOutVisible,//22 | |
2566 | - | |
2567 | - // annotationData: windowData.annotationData,//24 | |
2568 | - // transparencyBounds: windowData.transparencyBounds | |
2569 | - | |
2570 | - // }); | |
2571 | - | |
2572 | - //} | |
2628 | + | |
2573 | 2629 | |
2574 | 2630 | |
2575 | 2631 | ... | ... |
400-SOURCECODE/AIAHTML5.Web/app/controllers/DAController.js
... | ... | @@ -807,7 +807,7 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l |
807 | 807 | $rootScope.jsPanelTop = 70; |
808 | 808 | } |
809 | 809 | |
810 | - $.jsPanel({ | |
810 | + $scope.jsPanelDA = $.jsPanel({ | |
811 | 811 | id: $scope.jsPanelID, |
812 | 812 | selector: '.daBodyView', |
813 | 813 | theme: 'success', |
... | ... | @@ -843,6 +843,30 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l |
843 | 843 | //0.3 |
844 | 844 | var daBodyviewElement = angular.element(document.getElementById("daBodyview")); |
845 | 845 | |
846 | + //Perform Activity as per SaveCB JSPanel | |
847 | + var max = $scope.GetwindowStoreData(windowviewid, 'maximised'); | |
848 | + var min = $scope.GetwindowStoreData(windowviewid, 'minimised'); | |
849 | + if ($scope.jsPanelDA.status === "maximized" && max) { | |
850 | + $scope.jsPanelDA.maximize(); | |
851 | + $scope.SetwindowStoreData(windowviewid, 'maximised', true); | |
852 | + $scope.SetwindowStoreData(windowviewid, 'minimised', false); | |
853 | + } | |
854 | + else if ($scope.jsPanelDA.status === "minimized" && min) { | |
855 | + $scope.jsPanelDA.minimize(); | |
856 | + $scope.SetwindowStoreData(windowviewid, 'minimised', true); | |
857 | + $scope.SetwindowStoreData(windowviewid, 'maximised', false); | |
858 | + } | |
859 | + else { | |
860 | + $scope.jsPanelDA.normalize(); | |
861 | + $scope.SetwindowStoreData(windowviewid, 'maximised', false); | |
862 | + $scope.SetwindowStoreData(windowviewid, 'minimised', false); | |
863 | + } | |
864 | + | |
865 | + $scope.SetwindowStoreData(windowviewid, 'top', $scope.jsPanelTop); | |
866 | + $scope.SetwindowStoreData(windowviewid, 'left', $scope.jsPanelLeft); | |
867 | + $scope.SetwindowStoreData(windowviewid, 'width', $scope.jsPanelWidth); | |
868 | + $scope.SetwindowStoreData(windowviewid, 'height', $scope.jsPanelHeight); | |
869 | + | |
846 | 870 | $timeout(function () { |
847 | 871 | $compile(daBodyviewElement.contents())($scope); |
848 | 872 | |
... | ... | @@ -932,7 +956,8 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l |
932 | 956 | |
933 | 957 | $location.path('/'); |
934 | 958 | } |
935 | - | |
959 | + //Calling methode for save Js Panel Activity for SaveCB | |
960 | + $scope.PanelActivity(); | |
936 | 961 | } |
937 | 962 | |
938 | 963 | |
... | ... | @@ -10776,6 +10801,75 @@ AIA.controller("DAController", ["$scope", "$rootScope", "$compile", "$http", "$l |
10776 | 10801 | |
10777 | 10802 | } |
10778 | 10803 | |
10804 | + | |
10805 | + //Created method by Sandeep for Save JSPanel Activity on the CB module | |
10806 | + $scope.PanelActivity = function () { | |
10807 | + | |
10808 | + $("#" + $scope.jsPanelID).resizable({ | |
10809 | + stop: function (event, ui) { | |
10810 | + var len = (event.currentTarget.id).split("_").length; | |
10811 | + var windowviewid = (event.currentTarget.id).split("_")[len - 1]; | |
10812 | + $scope.SetwindowStoreData(windowviewid, 'width', ui.size.width); | |
10813 | + $scope.SetwindowStoreData(windowviewid, 'height', ui.size.height); | |
10814 | + } | |
10815 | + }); | |
10816 | + | |
10817 | + $("#" + $scope.jsPanelID).draggable({ | |
10818 | + stop: function (event, ui) { | |
10819 | + var len = (event.currentTarget.id).split("_").length; | |
10820 | + var windowviewid = (event.currentTarget.id).split("_")[len - 1]; | |
10821 | + //var offSets = $(this).offset(); var postions = (this).position(); (this).offsetTop (this).offsetLeft | |
10822 | + $scope.SetwindowStoreData(windowviewid, 'top', ui.position.top); | |
10823 | + $scope.SetwindowStoreData(windowviewid, 'left', ui.position.left); | |
10824 | + } | |
10825 | + }); | |
10826 | + | |
10827 | + $(document).on("click", "#" + $scope.jsPanelID + " .jsPanel-hdr .jsPanel-hdr-r .jsPanel-btn-close .jsglyph-remove", function (event) { | |
10828 | + var currentPanelId = $(event.target).parent().parent().parent().parent().attr('id'); | |
10829 | + var len = (currentPanelId).split("_").length; | |
10830 | + var windowviewid = (currentPanelId).split("_")[len - 1]; | |
10831 | + for (var i in $rootScope.DaWindowData) { | |
10832 | + if ($rootScope.DaWindowData[i] !== null && typeof ($rootScope.DaWindowData[i]) == "object") { | |
10833 | + if ($rootScope.DaWindowData[i].multiwinid == windowviewid) { | |
10834 | + $rootScope.DaWindowData.splice(i, 1); | |
10835 | + } | |
10836 | + } | |
10837 | + } | |
10838 | + //$(".tools").css("z-index", "15000"); | |
10839 | + }); | |
10840 | + | |
10841 | + $(document).on("click", "#" + $scope.jsPanelID + " .jsPanel-hdr .jsPanel-hdr-r .jsPanel-btn-max .jsglyph-maximize", function (event) { | |
10842 | + var currentPanelId = $(event.target).parent().parent().parent().parent().attr('id'); | |
10843 | + var len = (currentPanelId).split("_").length; | |
10844 | + var windowviewid = (currentPanelId).split("_")[len - 1]; | |
10845 | + $scope.SetwindowStoreData(windowviewid, 'maximised', true); | |
10846 | + $scope.SetwindowStoreData(windowviewid, 'minimised', false); | |
10847 | + }); | |
10848 | + | |
10849 | + $(document).on("click", "#" + $scope.jsPanelID + " .jsPanel-hdr .jsPanel-hdr-r .jsPanel-btn-min #minSpan", function (event) { | |
10850 | + var currentPanelId = $(event.target).parent().parent().parent().parent().attr('id'); | |
10851 | + var len = (currentPanelId).split("_").length; | |
10852 | + var windowviewid = (currentPanelId).split("_")[len - 1]; | |
10853 | + $scope.SetwindowStoreData(windowviewid, 'maximised', false); | |
10854 | + $scope.SetwindowStoreData(windowviewid, 'minimised', true); | |
10855 | + | |
10856 | + }); | |
10857 | + | |
10858 | + $(document).on("click", "#" + $scope.jsPanelID + " .jsPanel-hdr .jsPanel-hdr-r .jsPanel-btn-norm .jsglyph-normalize", function (event) { | |
10859 | + var currentPanelId = $(event.target).parent().parent().parent().parent().attr('id'); | |
10860 | + var len = (currentPanelId).split("_").length; | |
10861 | + var windowviewid = (currentPanelId).split("_")[len - 1]; | |
10862 | + $scope.SetwindowStoreData(windowviewid, 'maximised', false); | |
10863 | + $scope.SetwindowStoreData(windowviewid, 'minimised', false); | |
10864 | + | |
10865 | + }); | |
10866 | + | |
10867 | + } | |
10868 | + | |
10869 | + | |
10870 | + | |
10871 | + | |
10872 | + | |
10779 | 10873 | }]) |
10780 | 10874 | |
10781 | 10875 | function OnGenderChange(event) { | ... | ... |
400-SOURCECODE/AIAHTML5.Web/app/controllers/TileViewListController.js
... | ... | @@ -551,7 +551,7 @@ function ($scope, $window, $rootScope, $compile, $http, $log, $location, $timeou |
551 | 551 | |
552 | 552 | //1. create a jsPanel and load the module item view |
553 | 553 | if (moduleName == ATLAS_ANATOMY) { |
554 | - $.jsPanel({ | |
554 | + $scope.jsPanelAA = $.jsPanel({ | |
555 | 555 | id: $scope.jsPanelID, |
556 | 556 | selector: '.aaBodyView', |
557 | 557 | theme: 'success', |
... | ... | @@ -582,6 +582,30 @@ function ($scope, $window, $rootScope, $compile, $http, $log, $location, $timeou |
582 | 582 | $rootScope.isLoading = true; |
583 | 583 | $('#spinner').css('visibility', 'visible'); |
584 | 584 | |
585 | + //Perform Activity as per SaveCb JSPanel | |
586 | + var max = $scope.GetAAwindowStoreData(windowviewid, 'maximised'); | |
587 | + var min = $scope.GetAAwindowStoreData(windowviewid, 'minimised'); | |
588 | + if ($scope.jsPanelAA.status === "maximized" && max) { | |
589 | + $scope.jsPanelAA.maximize(); | |
590 | + $scope.SetAAwindowStoreData(windowviewid, 'maximised', true); | |
591 | + $scope.SetAAwindowStoreData(windowviewid, 'minimised', false); | |
592 | + } | |
593 | + else if ($scope.jsPanelAA.status === "minimized" && min) { | |
594 | + $scope.jsPanelAA.minimize(); | |
595 | + $scope.SetAAwindowStoreData(windowviewid, 'minimised', true); | |
596 | + $scope.SetAAwindowStoreData(windowviewid, 'maximised', false); | |
597 | + } | |
598 | + else { | |
599 | + $scope.jsPanelAA.normalize(); | |
600 | + $scope.SetAAwindowStoreData(windowviewid, 'maximised', false); | |
601 | + $scope.SetAAwindowStoreData(windowviewid, 'minimised', false); | |
602 | + } | |
603 | + | |
604 | + $scope.SetAAwindowStoreData(windowviewid, 'top', $scope.jsPanelTop); | |
605 | + $scope.SetAAwindowStoreData(windowviewid, 'left', $scope.jsPanelLeft); | |
606 | + $scope.SetAAwindowStoreData(windowviewid, 'width', $scope.jsPanelWidth); | |
607 | + $scope.SetAAwindowStoreData(windowviewid, 'height', $scope.jsPanelHeight); | |
608 | + | |
585 | 609 | $timeout(function () { |
586 | 610 | $compile(aaViewElement.contents())($scope); |
587 | 611 | |
... | ... | @@ -2969,64 +2993,72 @@ function ($scope, $window, $rootScope, $compile, $http, $log, $location, $timeou |
2969 | 2993 | |
2970 | 2994 | }); |
2971 | 2995 | |
2972 | - //Created method by Sandeep for Save JSPanel Activity on the CB module | |
2973 | - $scope.PanelActivity = function () { | |
2996 | + //Created method by Sandeep for Save JSPanel Activity on the CB module | |
2997 | + $scope.PanelActivity = function () { | |
2998 | + | |
2974 | 2999 | $("#" + $scope.jsPanelID).resizable({ |
2975 | - resize: function (event, ui) { | |
3000 | + stop: function (event, ui) { | |
2976 | 3001 | var len = (event.currentTarget.id).split("_").length; |
2977 | 3002 | var windowviewid = (event.currentTarget.id).split("_")[len - 1]; |
2978 | - //$scope.jsPanelWidth = ui.size.width; | |
2979 | - //$scope.jsPanelHeight = ui.size.height; | |
2980 | - $scope.SetCIwindowStoreData(windowviewid, 'width', ui.size.width); | |
2981 | - $scope.SetCIwindowStoreData(windowviewid, 'height', ui.size.height); | |
2982 | - //console.log($rootScope.jsPanelWidth, $rootScope.jsPanelHeight); | |
3003 | + $scope.SetAAwindowStoreData(windowviewid, 'width', ui.size.width); | |
3004 | + $scope.SetAAwindowStoreData(windowviewid, 'height', ui.size.height); | |
2983 | 3005 | } |
2984 | 3006 | }); |
2985 | 3007 | |
2986 | - $("#" + $scope.jsPanelID).mousemove(function (event) { | |
2987 | - var len = (event.currentTarget.id).split("_").length; | |
2988 | - var windowviewid = (event.currentTarget.id).split("_")[len - 1]; | |
2989 | - var offSet = $(this).offset(); | |
2990 | - $scope.SetCIwindowStoreData(windowviewid, 'top', offSet.top); | |
2991 | - $scope.SetCIwindowStoreData(windowviewid, 'left', offSet.left); | |
2992 | - $scope.SetCIwindowStoreData(windowviewid, 'width', event.currentTarget.offsetWidth); | |
2993 | - $scope.SetCIwindowStoreData(windowviewid, 'height', event.currentTarget.offsetHeight); | |
2994 | - | |
2995 | - console.log(offSet.top, offSet.left, event.currentTarget.offsetWidth, event.currentTarget.offsetHeight) | |
3008 | + $("#" + $scope.jsPanelID).draggable({ | |
3009 | + stop: function (event, ui) { | |
3010 | + var len = (event.currentTarget.id).split("_").length; | |
3011 | + var windowviewid = (event.currentTarget.id).split("_")[len - 1]; | |
3012 | + //var offSets = $(this).offset(); var postions = (this).position(); (this).offsetTop (this).offsetLeft | |
3013 | + $scope.SetAAwindowStoreData(windowviewid, 'top', ui.position.top); | |
3014 | + $scope.SetAAwindowStoreData(windowviewid, 'left', ui.position.left); | |
3015 | + } | |
2996 | 3016 | }); |
2997 | 3017 | |
2998 | - $(document).on("click", "#" + $scope.jsPanelID + " .jsPanel-hdr .jsPanel-hdr-r .jsPanel-btn-close .jsglyph-remove", function () { | |
2999 | - var len = ($scope.jsPanelID).split("_").length; | |
3000 | - var windowviewid = ($scope.jsPanelID).split("_")[len - 1]; | |
3001 | - $(".tools").css("z-index", "15000"); | |
3018 | + $(document).on("click", "#" + $scope.jsPanelID + " .jsPanel-hdr .jsPanel-hdr-r .jsPanel-btn-close .jsglyph-remove", function (event) { | |
3019 | + var currentPanelId = $(event.target).parent().parent().parent().parent().attr('id'); | |
3020 | + var len = (currentPanelId).split("_").length; | |
3021 | + var windowviewid = (currentPanelId).split("_")[len - 1]; | |
3022 | + for (var i in $rootScope.AAWindowData) { | |
3023 | + if ($rootScope.AAWindowData[i] !== null && typeof ($rootScope.AAWindowData[i]) == "object") { | |
3024 | + if ($rootScope.AAWindowData[i].multiwinid == windowviewid) { | |
3025 | + $rootScope.AAWindowData.splice(i, 1); | |
3026 | + } | |
3027 | + } | |
3028 | + } | |
3029 | + //$(".tools").css("z-index", "15000"); | |
3002 | 3030 | }); |
3003 | 3031 | |
3004 | - $(document).on("click", "#" + $scope.jsPanelID + " .jsPanel-hdr .jsPanel-hdr-r .jsPanel-btn-max .jsglyph-maximize", function () { | |
3005 | - var len = ($scope.jsPanelID).split("_").length; | |
3006 | - var windowviewid = ($scope.jsPanelID).split("_")[len - 1]; | |
3007 | - $scope.SetCIwindowStoreData(windowviewid, 'maximised', true); | |
3008 | - $scope.SetCIwindowStoreData(windowviewid, 'minimised', false); | |
3009 | - | |
3032 | + $(document).on("click", "#" + $scope.jsPanelID + " .jsPanel-hdr .jsPanel-hdr-r .jsPanel-btn-max .jsglyph-maximize", function (event) { | |
3033 | + var currentPanelId = $(event.target).parent().parent().parent().parent().attr('id'); | |
3034 | + var len = (currentPanelId).split("_").length; | |
3035 | + var windowviewid = (currentPanelId).split("_")[len - 1]; | |
3036 | + $scope.SetAAwindowStoreData(windowviewid, 'maximised', true); | |
3037 | + $scope.SetAAwindowStoreData(windowviewid, 'minimised', false); | |
3010 | 3038 | }); |
3011 | 3039 | |
3012 | - $(document).on("click", "#" + $scope.jsPanelID + " .jsPanel-hdr .jsPanel-hdr-r .jsPanel-btn-min #minSpan", function () { | |
3013 | - var len = ($scope.jsPanelID).split("_").length; | |
3014 | - var windowviewid = ($scope.jsPanelID).split("_")[len - 1]; | |
3015 | - $scope.SetCIwindowStoreData(windowviewid, 'maximised', false); | |
3016 | - $scope.SetCIwindowStoreData(windowviewid, 'minimised', true); | |
3040 | + $(document).on("click", "#" + $scope.jsPanelID + " .jsPanel-hdr .jsPanel-hdr-r .jsPanel-btn-min #minSpan", function (event) { | |
3041 | + var currentPanelId = $(event.target).parent().parent().parent().parent().attr('id'); | |
3042 | + var len = (currentPanelId).split("_").length; | |
3043 | + var windowviewid = (currentPanelId).split("_")[len - 1]; | |
3044 | + $scope.SetAAwindowStoreData(windowviewid, 'maximised', false); | |
3045 | + $scope.SetAAwindowStoreData(windowviewid, 'minimised', true); | |
3017 | 3046 | |
3018 | 3047 | }); |
3019 | 3048 | |
3020 | - $(document).on("click", "#" + $scope.jsPanelID + " .jsPanel-hdr .jsPanel-hdr-r .jsPanel-btn-norm .jsglyph-normalize", function () { | |
3021 | - var len = ($scope.jsPanelID).split("_").length; | |
3022 | - var windowviewid = ($scope.jsPanelID).split("_")[len - 1]; | |
3023 | - $scope.SetCIwindowStoreData(windowviewid, 'maximised', false); | |
3024 | - $scope.SetCIwindowStoreData(windowviewid, 'minimised', false); | |
3049 | + $(document).on("click", "#" + $scope.jsPanelID + " .jsPanel-hdr .jsPanel-hdr-r .jsPanel-btn-norm .jsglyph-normalize", function (event) { | |
3050 | + var currentPanelId = $(event.target).parent().parent().parent().parent().attr('id'); | |
3051 | + var len = (currentPanelId).split("_").length; | |
3052 | + var windowviewid = (currentPanelId).split("_")[len - 1]; | |
3053 | + $scope.SetAAwindowStoreData(windowviewid, 'maximised', false); | |
3054 | + $scope.SetAAwindowStoreData(windowviewid, 'minimised', false); | |
3025 | 3055 | |
3026 | 3056 | }); |
3027 | 3057 | |
3028 | 3058 | } |
3029 | 3059 | |
3060 | + | |
3061 | + | |
3030 | 3062 | }]); |
3031 | 3063 | |
3032 | 3064 | ... | ... |