diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/AIController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/AIController.js
index dffa72e..f123574 100644
--- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/AIController.js
+++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/AIController.js
@@ -112,10 +112,15 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
$scope.setImgPosition();
}, 100);
- };
-
+ };
+
$scope.loadAIModuleById = function (moduleId) {
-
+
+ if ($rootScope.checkRefreshButtonClick == 1) {
+ var query = $scope.query;
+ $scope.Reset(query);
+ $rootScope.checkRefreshButtonClick = 0;
+ }
var ImageCount = $rootScope.getLocalStorageValue("ImageCount");
if ($rootScope.refreshcheck == null) {
@@ -180,10 +185,10 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
$scope.query.SearchTextByAlphabet = "";
}
- if ($scope.query.SearchText == "" && $scope.query.SearchTextByAlphabet == "") {
+ //if ($scope.query.SearchText == "" && $scope.query.SearchTextByAlphabet == "") {
- $scope.loadAllAI(ImageCount);
- }
+ // $scope.loadAllAI(ImageCount);
+ //}
}
@@ -309,14 +314,27 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
}
};
+ //Code changes by Sandeep for fixed bug-57854
$scope.Reset = function (query) {
$('ul li span').removeAttr("style");
query.SearchText = "";
$scope.idSelected = '';
+ $scope.hideListViewDiv();
//set localstorage values
localStorage.setItem("SearchText", '');
localStorage.setItem("SearchByAlphabet", '');
localStorage.setItem("AIListViewScroll", '');
+ localStorage.setItem("AIGridViewScroll", '');
+ localStorage.setItem("currentAITabView", '');
+ localStorage.setItem("AIListViewScrollPosition", '');
+ localStorage.setItem("AISelectedRowId", '');
+ localStorage.setItem("currentAIImageId", '');
+ localStorage.setItem("listViewSelectedID", '');
+ localStorage.setItem("AIGridViewHighlightThumbnail", '');
+ localStorage.setItem("currentViewTitle", '');
+ localStorage.setItem("currentImageTitleFromJson", '');
+ //localStorage.setItem("", '');
+ //localStorage.setItem("", '');
var ImageCount = $rootScope.getLocalStorageValue("ImageCount");
if ($('.selected').hasClass("selected")) {
$('.selected').removeClass("selected");
@@ -324,13 +342,13 @@ function ($scope, $window, $rootScope, $compile, $http, log, $location, $timeout
$('#ListViewDiv').scrollTop(0);
- $scope.hideListViewDiv();
+ //$scope.hideListViewDiv();
$scope.filterstring = false;
while ($scope.searchAIListViewData.length) {
$scope.searchAIListViewData.pop();
}
- $scope.loadAllAI(ImageCount);
+ //$scope.loadAllAI(ImageCount);
}
$scope.ApplySearch = function (query) {
diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js
index 0ff499f..4f8b431 100644
--- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js
+++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js
@@ -147,9 +147,12 @@ function ($rootScope, $scope, Modules, $log, $location, $timeout, DataService, A
$("#messageModal").modal('show');
}
-
+
$rootScope.initializeAIA = function () {
+
+ $rootScope.checkRefreshButtonClick = 1;
+
if (params != null && params != undefined && params != "") {
$scope.ValidateClientSiteUrl();
@@ -1380,9 +1383,9 @@ function ($rootScope, $scope, Modules, $log, $location, $timeout, DataService, A
$rootScope.PrintPreview = "PrintPreview";
$rootScope.exportImage = "exportImage";
$rootScope.PrintViewer = "PrintViewer";
- $rootScope.newCurriculum = "newCurriculum";
- $rootScope.openCurriculum = "openCurriculum";
- $rootScope.saveCurriculam = "saveCurriculam";
+ $rootScope.newCurriculum = "";
+ $rootScope.openCurriculum = "";
+ $rootScope.saveCurriculam = "";
}
else if ($location.url() == "/adam-images-detail") {