From c0fdfd97029df03f209de9d360be519a8054708b Mon Sep 17 00:00:00 2001 From: Mukul Date: Fri, 18 May 2018 17:11:31 +0530 Subject: [PATCH] this is copy right config services with new develop --- 400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js | 6 +++--- 400-SOURCECODE/AIAHTML5.Web/app/services/ConfigurationService.js | 20 ++++++++++++++++++++ 400-SOURCECODE/AIAHTML5.Web/index.html | 1 + 3 files changed, 24 insertions(+), 3 deletions(-) create mode 100644 400-SOURCECODE/AIAHTML5.Web/app/services/ConfigurationService.js diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js index 9752f2d..2a08713 100644 --- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js +++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js @@ -1,7 +1,7 @@ 'use strict'; -AIA.controller("HomeController", ["$rootScope", "$scope", "Modules", "$log", "$location", "$timeout", "DataService", "AuthenticationService", "LoginConstants", "UserModules", "LoginMessageConstants", "AdminService", "$http", "AdminConstants", "UserTypeConstants", "AIAConstants", -function ($rootScope, $scope, Modules, $log, $location, $timeout, DataService, AuthenticationService, LoginConstants, UserModules, LoginMessageConstants, AdminService, $http, AdminConstants, UserTypeConstants,AIAConstants) { +AIA.controller("HomeController", ["$rootScope", "$scope", "Modules", "$log", "$location", "$timeout", "DataService", "AuthenticationService","ConfigurationService", "LoginConstants", "UserModules", "LoginMessageConstants", "AdminService", "$http", "AdminConstants", "UserTypeConstants", "AIAConstants", +function ($rootScope, $scope, Modules, $log, $location, $timeout, DataService, AuthenticationService,ConfigurationService, LoginConstants, UserModules, LoginMessageConstants, AdminService, $http, AdminConstants, UserTypeConstants,AIAConstants) { //$scope.pageToOpen = { // name: 'MainMenu' @@ -176,7 +176,7 @@ function ($rootScope, $scope, Modules, $log, $location, $timeout, DataService, A } $rootScope.getConfigurationValues = function () { - AuthenticationService.getCofigValue() + ConfigurationService.getCofigValue() .then( function (configresult) { $rootScope.current_year = configresult; diff --git a/400-SOURCECODE/AIAHTML5.Web/app/services/ConfigurationService.js b/400-SOURCECODE/AIAHTML5.Web/app/services/ConfigurationService.js new file mode 100644 index 0000000..300e09f --- /dev/null +++ b/400-SOURCECODE/AIAHTML5.Web/app/services/ConfigurationService.js @@ -0,0 +1,20 @@ +AIA.factory('ConfigurationService', function ($http, $q, $rootScope) { + return { + getCofigValue: function () { + var deferred = $q.defer(); + $http({ + method: 'GET', + url: 'API/api/Configuration/GetConfigurationvalues' + }).success(function (data, status, headers, config) { + console.log('success' + data); + deferred.resolve(data); + }).error(function (data, status, headers, config) { + console.log('error') + deferred.reject(data); + + }); + return deferred.promise; + } + + } +}); \ No newline at end of file diff --git a/400-SOURCECODE/AIAHTML5.Web/index.html b/400-SOURCECODE/AIAHTML5.Web/index.html index f3df5d8..75aa4c3 100644 --- a/400-SOURCECODE/AIAHTML5.Web/index.html +++ b/400-SOURCECODE/AIAHTML5.Web/index.html @@ -1422,6 +1422,7 @@ + -- libgit2 0.21.4