Commit f6baf974af9bcdeaf38d753a5a366c4560ede8cc

Authored by Nikita Kulshreshtha
1 parent 23c5c78b

added correct code

400-SOURCECODE/AIAHTML5.Web/app/controllers/AIController.js
@@ -18,39 +18,39 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -18,39 +18,39 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
18 }; 18 };
19 19
20 $(document).ready(function () { 20 $(document).ready(function () {
21 - $timeout(function () {  
22 - var Count = 200;  
23 - localStorage.setItem("ImageCount", Count);  
24 - var searchByText = $rootScope.getLocalStorageValue("SearchText");  
25 - var searchTextByAlphabet = $rootScope.getLocalStorageValue("SearchByAlphabet");  
26 - $("#ListViewDiv").on('scroll', function () {  
27 - if ($(this).scrollTop() + $(this).innerHeight() >= $(this)[0].scrollHeight - 10) {  
28 - Count += 100;  
29 - var ImageCount = $rootScope.getLocalStorageValue("ImageCount");  
30 - if (typeof (searchByText) !== "undefined" && searchByText !== null && searchByText !== '') {  
31 - $scope.query.SearchText = searchByText;  
32 - }  
33 - else if (typeof (searchTextByAlphabet) !== "undefined" && searchTextByAlphabet !== null && searchTextByAlphabet !== '') {  
34 - $scope.query.SearchTextByAlphabet = searchTextByAlphabet;  
35 - }  
36 - else {  
37 - $scope.query.SearchTextByAlphabet = "";  
38 - }  
39 -  
40 - if ($scope.query.SearchText == "" && $scope.query.SearchTextByAlphabet == "") {  
41 -  
42 - $scope.LoadAIJsonData(Count);  
43 - $scope.loadAllAI(Count);  
44 - }  
45 - else if ($scope.query.SearchTextByAlphabet != "" || $scope.query.SearchText == "") {  
46 - $scope.ApplySearchByAlphabet($scope.query.SearchTextByAlphabet);  
47 - }  
48 - else {  
49 - $scope.ApplySearch($scope.query);  
50 - } 21 + $timeout(function () {
  22 + var Count = 200;
  23 + localStorage.setItem("ImageCount", Count);
  24 + var searchByText = $rootScope.getLocalStorageValue("SearchText");
  25 + var searchTextByAlphabet = $rootScope.getLocalStorageValue("SearchByAlphabet");
  26 + $("#ListViewDiv").on('scroll', function () {
  27 + if ($(this).scrollTop() + $(this).innerHeight() >= $(this)[0].scrollHeight - 10) {
  28 + Count += 100;
  29 + var ImageCount = $rootScope.getLocalStorageValue("ImageCount");
  30 + if (typeof (searchByText) !== "undefined" && searchByText !== null && searchByText !== '') {
  31 + $scope.query.SearchText = searchByText;
51 } 32 }
52 - });  
53 - }, 10); 33 + else if (typeof (searchTextByAlphabet) !== "undefined" && searchTextByAlphabet !== null && searchTextByAlphabet !== '') {
  34 + $scope.query.SearchTextByAlphabet = searchTextByAlphabet;
  35 + }
  36 + else {
  37 + $scope.query.SearchTextByAlphabet = "";
  38 + }
  39 +
  40 + if ($scope.query.SearchText == "" && $scope.query.SearchTextByAlphabet == "") {
  41 +
  42 + $scope.LoadAIJsonData(Count);
  43 + $scope.loadAllAI(Count);
  44 + }
  45 + else if ($scope.query.SearchTextByAlphabet != "" || $scope.query.SearchText == "") {
  46 + $scope.ApplySearchByAlphabet($scope.query.SearchTextByAlphabet);
  47 + }
  48 + else {
  49 + $scope.ApplySearch($scope.query);
  50 + }
  51 + }
  52 + });
  53 + }, 10);
54 }); 54 });
55 55
56 $(document).ready(function () { 56 $(document).ready(function () {
@@ -78,14 +78,14 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -78,14 +78,14 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
78 $scope.loadAllAI(Count); 78 $scope.loadAllAI(Count);
79 } 79 }
80 else if ($scope.query.SearchTextByAlphabet != "" || $scope.query.SearchText == "") { 80 else if ($scope.query.SearchTextByAlphabet != "" || $scope.query.SearchText == "") {
81 - $scope.ApplySearchByAlphabet($scope.query.SearchTextByAlphabet ); 81 + $scope.ApplySearchByAlphabet($scope.query.SearchTextByAlphabet);
82 } 82 }
83 else { 83 else {
84 $scope.ApplySearch($scope.query); 84 $scope.ApplySearch($scope.query);
85 - } 85 + }
86 } 86 }
87 }); 87 });
88 - 88 +
89 }); 89 });
90 90
91 $scope.setActiveTab = function (tabToSet) { 91 $scope.setActiveTab = function (tabToSet) {
@@ -99,7 +99,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -99,7 +99,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
99 var selectedImageId = $rootScope.getLocalStorageValue("currentAIImageId"); 99 var selectedImageId = $rootScope.getLocalStorageValue("currentAIImageId");
100 $scope.ReloadListViewImageDiv(selectedImageId, ImageCount); 100 $scope.ReloadListViewImageDiv(selectedImageId, ImageCount);
101 } 101 }
102 - else { 102 + else {
103 $('#' + $rootScope.getLocalStorageValue("currentAIImageId")).find('.thumbnail').addClass('HightLightThumbnail'); 103 $('#' + $rootScope.getLocalStorageValue("currentAIImageId")).find('.thumbnail').addClass('HightLightThumbnail');
104 $('#' + $rootScope.getLocalStorageValue("currentAIImageId")).removeClass('selected'); 104 $('#' + $rootScope.getLocalStorageValue("currentAIImageId")).removeClass('selected');
105 $scope.loadAllAI(ImageCount); 105 $scope.loadAllAI(ImageCount);
@@ -136,7 +136,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -136,7 +136,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
136 //set the local storage 136 //set the local storage
137 137
138 var curtab = $rootScope.getLocalStorageValue("currentAITabView"); 138 var curtab = $rootScope.getLocalStorageValue("currentAITabView");
139 - if (curtab == 2) { 139 + if (curtab == 2) {
140 $scope.setActiveTab(2); 140 $scope.setActiveTab(2);
141 var curSelectedRowId = $rootScope.getLocalStorageValue("AISelectedRowId"); 141 var curSelectedRowId = $rootScope.getLocalStorageValue("AISelectedRowId");
142 if (typeof (curSelectedRowId) !== "undefined" && curSelectedRowId !== null && curSelectedRowId !== '') { 142 if (typeof (curSelectedRowId) !== "undefined" && curSelectedRowId !== null && curSelectedRowId !== '') {
@@ -213,8 +213,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -213,8 +213,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
213 $('ul li span').removeAttr("style"); 213 $('ul li span').removeAttr("style");
214 $('#aiSpinner').css('visibility', 'visible'); 214 $('#aiSpinner').css('visibility', 'visible');
215 $('#aiSpinner').css('zIndex', '20000'); 215 $('#aiSpinner').css('zIndex', '20000');
216 - if ($location.url() == "/ADAM-images")  
217 - { 216 + if ($location.url() == "/ADAM-images") {
218 $scope.DisableUI(); 217 $scope.DisableUI();
219 } 218 }
220 var promise = DataService.getJson('~/../content/data/json/ai/ai_dat_contentlist.json') 219 var promise = DataService.getJson('~/../content/data/json/ai/ai_dat_contentlist.json')
@@ -225,7 +224,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -225,7 +224,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
225 $scope.selectedAIListViewData = new jinqJs() 224 $scope.selectedAIListViewData = new jinqJs()
226 .from($scope.IllustrationData.root.AIData) 225 .from($scope.IllustrationData.root.AIData)
227 .orderBy([{ field: '_Title', sort: 'asc' }]) 226 .orderBy([{ field: '_Title', sort: 'asc' }])
228 - .select().slice(0,ImageCount); 227 + .select().slice(0, ImageCount);
229 228
230 //console.log($scope.selectedAIListViewData); 229 //console.log($scope.selectedAIListViewData);
231 230
@@ -252,7 +251,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -252,7 +251,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
252 $scope.EnableUI(); 251 $scope.EnableUI();
253 }, 10); 252 }, 10);
254 } 253 }
255 - 254 +
256 255
257 }, 256 },
258 function (error) { 257 function (error) {
@@ -305,7 +304,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -305,7 +304,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
305 $scope.SelectedAITitle = SelectedAIthumbImage[0]._Title; 304 $scope.SelectedAITitle = SelectedAIthumbImage[0]._Title;
306 305
307 } 306 }
308 - 307 +
309 } 308 }
310 }; 309 };
311 310
@@ -346,9 +345,6 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -346,9 +345,6 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
346 $rootScope.isLoading = true; 345 $rootScope.isLoading = true;
347 $('#aiSpinner').css('visibility', 'visible'); 346 $('#aiSpinner').css('visibility', 'visible');
348 $scope.DisableUI(); 347 $scope.DisableUI();
349 - $rootScope.isLoading = true;  
350 - $('#spinner').css('visibility', 'visible');  
351 -  
352 $scope.filterstring = true; 348 $scope.filterstring = true;
353 349
354 //while ($scope.searchAIListViewData.length) { 350 //while ($scope.searchAIListViewData.length) {
@@ -394,7 +390,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -394,7 +390,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
394 if (selectimg === true) { 390 if (selectimg === true) {
395 $scope.imagePath = "~/../content/images/ai/thumbnails/" + value._ThumbnailImage; 391 $scope.imagePath = "~/../content/images/ai/thumbnails/" + value._ThumbnailImage;
396 392
397 - var $el = $('<div id="' + value._id + '" class="col-sm-3 col-md-2" title = "' + value._Title + '" data-ng-click="AdamDetail($event)">' 393 + var $el = $('<div id="' + value._id + '" class="col-sm-3 col-md-2" title = "' + value._Title + '" data-ng-click="OpenAdamImage($event)">'
398 + '<div style="width:auto;height:auto;" class="thumbnail" >' 394 + '<div style="width:auto;height:auto;" class="thumbnail" >'
399 + '<img style="height:150px" id="' + value._Title + '"ng-src="' + $scope.imagePath + '" alt="" title="" >' 395 + '<img style="height:150px" id="' + value._Title + '"ng-src="' + $scope.imagePath + '" alt="" title="" >'
400 + '<div class="caption"><p>' + value._Title + '</p></div></a></div></div>').appendTo('#grid-view'); 396 + '<div class="caption"><p>' + value._Title + '</p></div></a></div></div>').appendTo('#grid-view');
@@ -402,113 +398,6 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -402,113 +398,6 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
402 $compile($el)($scope); 398 $compile($el)($scope);
403 399
404 400
405 - $(".sidebar").mCustomScrollbar({  
406 - autoHideScrollbar: true,  
407 - //theme:"rounded"  
408 - });  
409 -  
410 -  
411 - $scope.searchAIListViewData.push(  
412 - {  
413 - "_id": value._id,  
414 - //"_ImageId": value._ImageId,  
415 - "_Title": value._Title,  
416 - "_contentImage": value._contentImage,  
417 - "_ThumbnailImage": value._ThumbnailImage,  
418 -  
419 -  
420 - });  
421 - }  
422 - });  
423 - $('table > #ListViewDiv > #searchItem').remove();  
424 - //Show Error Message in case of gridview if no data is found  
425 - if ($scope.searchAIListViewData.length == 0) {  
426 - var $el = $('<div class="col-sm-12" style="padding-left:25px;padding-top:10px;"><strong style="color:white">No illustration found for the selected search criteria!</strong></div>').appendTo('#grid-view');  
427 - $compile($el)($scope);  
428 - $('table > #ListViewDiv > #searchItem').remove();  
429 -  
430 - $('#ListViewDiv').append('<tr id="searchItem"><td colspan="6"><strong style="color:black;">No illustration found for the selected search criteria!</strong></td></tr>');  
431 - }  
432 - $rootScope.isLoading = false;  
433 - $('#spinner').css('visibility', 'hidden');  
434 -  
435 - },  
436 - function (error) {  
437 - // handle errors here  
438 - console.log(' $scope.IllustrationData = ' + error.statusText);  
439 - }  
440 - );  
441 - }  
442 -  
443 -  
444 -  
445 - $scope.ApplySearchByAlphabet = function (SearchText) {  
446 -  
447 - $rootScope.isLoading = true;  
448 - $('#spinner').css('visibility', 'visible');  
449 -  
450 - $scope.filterstring = true;  
451 -  
452 - while ($scope.searchAIListViewData.length) {  
453 - $scope.searchAIListViewData.pop();  
454 - }  
455 -  
456 -  
457 -  
458 -  
459 - if (typeof (SearchText) !== "undefined" && (SearchText !== null && SearchText !== "")) {  
460 -  
461 - localStorage.setItem("AIImageId", SearchText);  
462 -  
463 - }  
464 - else {  
465 - localStorage.setItem("AIImageId", '');  
466 -  
467 - }  
468 -  
469 - var promise = DataService.getJson('~/../content/data/json/ai/ai_dat_contentlist.json')  
470 - promise.then(  
471 - function (result) {  
472 - $scope.IllustrationData = result;  
473 -  
474 - $scope.selectedAIListViewData = new jinqJs()  
475 - .from($scope.IllustrationData.root.AIData)  
476 - .orderBy([{ field: '_Title', sort: 'asc' }])  
477 - .select();  
478 -  
479 - $('#grid-view').empty();  
480 -  
481 - angular.forEach($scope.selectedAIListViewData, function (value, key) {  
482 -  
483 - var selectimg = true;  
484 - //var count = 0;  
485 - if (typeof (SearchText) !== "undefined" && (SearchText !== null && SearchText !== "")) {  
486 -  
487 - var firstChar = value._Title[0];  
488 -  
489 - if (firstChar == SearchText) {  
490 - selectimg = true;  
491 - //count = count + 1;  
492 -  
493 - }  
494 - else {  
495 - selectimg = false;  
496 - //count = count - 1;  
497 - }  
498 -  
499 - }  
500 -  
501 - if (selectimg === true) {  
502 - $scope.imagePath = "~/../content/images/ai/thumbnails/" + value._ThumbnailImage;  
503 -  
504 - var $el = $('<div id="' + value._id + '" class="col-sm-3 col-md-2" title = "' + value._Title + '" data-ng-click="AdamDetail($event)">'  
505 - + '<div style="width:auto;height:auto;" class="thumbnail" >'  
506 - + '<img style="height:150px" id="' + value._Title + '"ng-src="' + $scope.imagePath + '" alt="" title="" >'  
507 - + '<div class="caption"><p>' + value._Title + '</p></div></a></div></div>').appendTo('#grid-view');  
508 -  
509 - $compile($el)($scope);  
510 -  
511 -  
512 //$(".sidebar").mCustomScrollbar({ 401 //$(".sidebar").mCustomScrollbar({
513 // autoHideScrollbar: true, 402 // autoHideScrollbar: true,
514 // //theme:"rounded" 403 // //theme:"rounded"
@@ -540,14 +429,14 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -540,14 +429,14 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
540 }, 10); 429 }, 10);
541 430
542 }, 431 },
543 - function (error) {  
544 - // handle errors here  
545 - console.log(' $scope.IllustrationData = ' + error.statusText);  
546 - }  
547 - ); 432 + function (error) {
  433 + // handle errors here
  434 + console.log(' $scope.IllustrationData = ' + error.statusText);
  435 + }
  436 + );
548 } 437 }
549 $scope.DisableUI = function () { 438 $scope.DisableUI = function () {
550 - 439 +
551 $('#imgParent').css('z-index', '1'); 440 $('#imgParent').css('z-index', '1');
552 document.getElementById("imgParent").style.pointerEvents = "none"; 441 document.getElementById("imgParent").style.pointerEvents = "none";
553 document.getElementById("imgParent").style.opacity = "0.5"; 442 document.getElementById("imgParent").style.opacity = "0.5";
@@ -564,7 +453,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -564,7 +453,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
564 $rootScope.isLoading = true; 453 $rootScope.isLoading = true;
565 $('#aiSpinner').css('visibility', 'visible'); 454 $('#aiSpinner').css('visibility', 'visible');
566 $scope.DisableUI(); 455 $scope.DisableUI();
567 - $('ul li span').removeAttr("style"); 456 + $('ul li span').removeAttr("style");
568 $('#' + $rootScope.SearchTextByAlphabet).css({ "color": "white", "background-color": "#1B92D0" }); 457 $('#' + $rootScope.SearchTextByAlphabet).css({ "color": "white", "background-color": "#1B92D0" });
569 $scope.filterstring = true; 458 $scope.filterstring = true;
570 if (typeof (SearchTextByAlphabet) !== "undefined" && (SearchTextByAlphabet !== null && SearchTextByAlphabet !== "")) { 459 if (typeof (SearchTextByAlphabet) !== "undefined" && (SearchTextByAlphabet !== null && SearchTextByAlphabet !== "")) {
@@ -581,7 +470,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -581,7 +470,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
581 470
582 $scope.selectedAIListViewData = new jinqJs() 471 $scope.selectedAIListViewData = new jinqJs()
583 .from($scope.IllustrationData.root.AIData) 472 .from($scope.IllustrationData.root.AIData)
584 - .orderBy([{ field: '_Title', sort: 'asc' }]).select(); 473 + .orderBy([{ field: '_Title', sort: 'asc' }]).select();
585 474
586 $('#grid-view').empty(); 475 $('#grid-view').empty();
587 476
@@ -601,7 +490,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -601,7 +490,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
601 if (selectimg === true) { 490 if (selectimg === true) {
602 $scope.imagePath = "~/../content/images/ai/thumbnails/" + value._ThumbnailImage; 491 $scope.imagePath = "~/../content/images/ai/thumbnails/" + value._ThumbnailImage;
603 492
604 - var $el = $('<div id="' + value._id + '" ng-disabled="' + $scope.IsDisable + '" class="col-sm-3 col-md-2" title = "' + value._Title + '" data-ng-click="OpenAdamImage($event)">' 493 + var $el = $('<div id="' + value._id + '" ng-disabled="' + $scope.IsDisable + '" class="col-sm-3 col-md-2" title = "' + value._Title + '" data-ng-click="OpenAdamImage($event)">'
605 + '<div style="width:auto;height:auto;" class="thumbnail" >' 494 + '<div style="width:auto;height:auto;" class="thumbnail" >'
606 + '<img style="height:150px" id="' + value._Title + '"ng-src="' + $scope.imagePath + '" alt="" title="" >' 495 + '<img style="height:150px" id="' + value._Title + '"ng-src="' + $scope.imagePath + '" alt="" title="" >'
607 + '<div class="caption"><p>' + value._Title + '</p></div></a></div></div>').appendTo('#grid-view'); 496 + '<div class="caption"><p>' + value._Title + '</p></div></a></div></div>').appendTo('#grid-view');
@@ -629,17 +518,17 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -629,17 +518,17 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
629 } 518 }
630 $rootScope.isLoading = false; 519 $rootScope.isLoading = false;
631 520
632 - setTimeout(function () {  
633 - $scope.EnableUI();  
634 - }, 10); 521 + setTimeout(function () {
  522 + $scope.EnableUI();
  523 + }, 10);
635 }, 524 },
636 function (error) { 525 function (error) {
637 console.log(' $scope.IllustrationData = ' + error.statusText); 526 console.log(' $scope.IllustrationData = ' + error.statusText);
638 } 527 }
639 - 528 +
640 ); 529 );
641 -  
642 - 530 +
  531 +
643 } 532 }
644 533
645 534
@@ -704,9 +593,9 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -704,9 +593,9 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
704 .select('_contentImage'); 593 .select('_contentImage');
705 594
706 $scope.clickedAIImage = "~/../content/images/ai/images/" + clickedAIImage[0]._contentImage; 595 $scope.clickedAIImage = "~/../content/images/ai/images/" + clickedAIImage[0]._contentImage;
707 - 596 +
708 if (clickedAIImage.length > 0) { 597 if (clickedAIImage.length > 0) {
709 - 598 +
710 $.jsPanel({ 599 $.jsPanel({
711 id: 'aiImagePanel', 600 id: 'aiImagePanel',
712 selector: '.aiView', 601 selector: '.aiView',
@@ -724,7 +613,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -724,7 +613,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
724 title: $rootScope.getLocalStorageValue("currentViewTitle"), 613 title: $rootScope.getLocalStorageValue("currentViewTitle"),
725 position: { 614 position: {
726 top: 70, 615 top: 70,
727 - left: 20, 616 + left: 20,
728 }, 617 },
729 618
730 size: { width: $(window).outerWidth() - 20, height: $(window).outerHeight() - 110 }, 619 size: { width: $(window).outerWidth() - 20, height: $(window).outerHeight() - 110 },
@@ -732,7 +621,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -732,7 +621,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
732 }); 621 });
733 622
734 $('#canvasDiv img').load(function () { 623 $('#canvasDiv img').load(function () {
735 - 624 +
736 $rootScope.isLoading = false; 625 $rootScope.isLoading = false;
737 $('#aiSpinner').css('visibility', 'hidden'); 626 $('#aiSpinner').css('visibility', 'hidden');
738 var canvas = document.getElementById("canvas"); 627 var canvas = document.getElementById("canvas");
@@ -746,14 +635,14 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -746,14 +635,14 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
746 "module": $rootScope.currentActiveModuleTitle, "bodyView": tittle, "state": 'max', "BodyViewId": $rootScope.currentAIImageId, 635 "module": $rootScope.currentActiveModuleTitle, "bodyView": tittle, "state": 'max', "BodyViewId": $rootScope.currentAIImageId,
747 "slug": $rootScope.currentSlug 636 "slug": $rootScope.currentSlug
748 }); 637 });
749 -  
750 - $("#aiImagePanel .img-thumbnail").css("min-height", $("#aiImagePanel .jsPanel-content").height()); 638 +
  639 + $("#aiImagePanel .img-thumbnail").css("min-height", $("#aiImagePanel .jsPanel-content").height());
751 $('.jsPanel-content .jsPanel-theme-success').css('overflow-y', 'auto !important') 640 $('.jsPanel-content .jsPanel-theme-success').css('overflow-y', 'auto !important')
752 var jspContentHeight = $('.jsPanel-content').height(); 641 var jspContentHeight = $('.jsPanel-content').height();
753 -  
754 -  
755 642
756 - 643 +
  644 +
  645 +
757 } 646 }
758 }, 647 },
759 function (error) { 648 function (error) {
@@ -764,7 +653,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -764,7 +653,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
764 // console.log($rootScope.OpenAdamImages); 653 // console.log($rootScope.OpenAdamImages);
765 $('#AIView').css("height", $(window).outerHeight()); 654 $('#AIView').css("height", $(window).outerHeight());
766 655
767 - $('#AIView').css("width", $(window).outerWidth()); 656 + $('#AIView').css("width", $(window).outerWidth());
768 } 657 }
769 658
770 $scope.$on('annotationToolEvent', function (event, data) { 659 $scope.$on('annotationToolEvent', function (event, data) {
@@ -776,12 +665,12 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -776,12 +665,12 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
776 665
777 $("#canvas").css("display", "block"); 666 $("#canvas").css("display", "block");
778 $("#canvasPaint").css("display", "block"); 667 $("#canvasPaint").css("display", "block");
779 - 668 +
780 $rootScope.onDrawingCanvasClick(); 669 $rootScope.onDrawingCanvasClick();
781 $rootScope.FreeStylePaint(); 670 $rootScope.FreeStylePaint();
782 }); 671 });
783 672
784 - $scope.ReloadListViewImageDiv = function (id,imgCount) { 673 + $scope.ReloadListViewImageDiv = function (id, imgCount) {
785 //console.log(id); 674 //console.log(id);
786 $scope.idSelected = id; 675 $scope.idSelected = id;
787 $scope.hiderow = true; 676 $scope.hiderow = true;
@@ -810,7 +699,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout @@ -810,7 +699,7 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
810 var curAIListViewScroll = $rootScope.getLocalStorageValue("AIListViewScroll"); 699 var curAIListViewScroll = $rootScope.getLocalStorageValue("AIListViewScroll");
811 if (typeof (curAIListViewScroll) !== "undefined" && curAIListViewScroll !== null && curAIListViewScroll !== '') { 700 if (typeof (curAIListViewScroll) !== "undefined" && curAIListViewScroll !== null && curAIListViewScroll !== '') {
812 if (typeof InstallTrigger !== 'undefined') { 701 if (typeof InstallTrigger !== 'undefined') {
813 - $('#ListViewDiv').animate({ scrollTop: $rootScope.getLocalStorageValue("AIListViewScroll") }); 702 + $('#ListViewDiv').animate({ scrollTop: $rootScope.getLocalStorageValue("AIListViewScroll") });
814 } 703 }
815 else { 704 else {
816 $('#ListViewDiv').scrollTop($rootScope.getLocalStorageValue("AIListViewScroll")); 705 $('#ListViewDiv').scrollTop($rootScope.getLocalStorageValue("AIListViewScroll"));