{"version":3,"sources":["brokerAngularApp.min.js"],"names":["root","staticData","urls","termsOfUseUrl","currentTheme","Object","$angularApp","angular","module","config","$provide","$logProvider","$themeProvider","decorator","$delegate","originalMethods","debug","error","warn","info","debugEnabled","apply","arguments","args","extend","themeTemplate","setCurrentTheme","controller","$scope","$log","$window","showTermsOfUse","width","height","left","screen","top","open","isSigned","directive","scope","element","attrs","on","event","selectedvalue","preventDefault","alert","onSumtClickValidation","issupportedbrowser","this","value","placeholder","signature"],"mappings":"CAAC,SAAUA,GAIFA,EAQOA,EAAKC,aACbD,EAAKC,YACDC,MACIC,cAAe,0BAEnBC,aAAc,QAZlBJ,EAAO,GAAIK,QACXL,EAAKC,YACDC,MACIC,cAAe,yBAEnBC,aAAc,OAWtBJ,EAAKM,YAAcN,EAAKO,QAAQC,OAAO,aAAc,qBAAsB,eACxEC,QAAQ,WAAY,eAAgB,iBAAkB,SAAUC,EAAUC,EAAcC,GAOrFF,EAASG,UAAU,QAAS,YAAa,SAAUC,GAE/C,GAAIC,IACAC,MAAOF,EAAUE,MACjBC,MAAOH,EAAUG,MACjBC,KAAMJ,EAAUI,KAChBC,KAAML,EAAUK,KAiCpB,OA9BAL,GAAUE,MAAQ,WACVf,WAAWmB,cACXL,EAAgBC,MAAMK,MAAM,KAAMC,YAI1CR,EAAUK,KAAO,WACTlB,WAAWmB,cACXL,EAAgBI,KAAKE,MAAM,KAAMC,YAIzCR,EAAUG,MAAQ,WACd,GAAIhB,WAAWmB,aACXL,EAAgBE,MAAMI,MAAM,KAAMC,eAC/B,CACH,GAAIC,IAAQD,UAAU,GACtBP,GAAgBE,MAAMI,MAAM,KAAME,KAI1CT,EAAUI,KAAO,WACb,GAAIjB,WAAWmB,aACXL,EAAgBG,KAAKG,MAAM,KAAMC,eAC9B,CACH,GAAIC,IAAQD,UAAU,GACtBP,GAAgBG,KAAKG,MAAM,KAAME,KAIlCT,KAMPd,EAAKC,YAAcD,EAAKC,WAAWG,eACnCG,QAAQiB,OAAOZ,E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n /*\r\n * If the root is not defined we're probably testing. Define some fake data.\r\n */\r\n if (!root) {\r\n root = new Object();\r\n root.staticData = {\r\n urls: {\r\n termsOfUseUrl: 'http://www.google.com'\r\n },\r\n currentTheme: null\r\n }\r\n } else if (!root.staticData) {\r\n root.staticData = {\r\n urls: {\r\n termsOfUseUrl: 'http://wwww.google.com'\r\n },\r\n currentTheme: null\r\n };\r\n }\r\n\r\n root.$angularApp = root.angular.module('SSOBroker', ['SumTotalComponents', 'ngMessages'])\r\n .config(['$provide', '$logProvider', '$themeProvider', function ($provide, $logProvider, $themeProvider) {\r\n /**\r\n * Handle extending the $log service...\r\n *\r\n * What is done here is to make sure that any logging statements within our code do not log to the console\r\n * sensitive information. Only the first statement, the message, will be passed through when in production.\r\n */\r\n $provide.decorator('$log', ['$delegate', function ($delegate) {\r\n\r\n var originalMethods = {\r\n debug: $delegate.debug,\r\n error: $delegate.error,\r\n warn: $delegate.warn,\r\n info: $delegate.info\r\n };\r\n\r\n $delegate.debug = function () {\r\n if (staticData.debugEnabled) {\r\n originalMethods.debug.apply(null, arguments);\r\n }\r\n };\r\n\r\n $delegate.info = function () {\r\n if (staticData.debugEnabled) {\r\n originalMethods.info.apply(null, arguments);\r\n }\r\n };\r\n\r\n $delegate.error = function () {\r\n if (staticData.debugEnabled) {\r\n originalMethods.error.apply(null, arguments);\r\n } else {\r\n var args = [arguments[0]];\r\n originalMethods.error.apply(null, args);\r\n }\r\n };\r\n\r\n $delegate.warn = function () {\r\n if (staticData.debugEnabled) {\r\n originalMethods.warn.apply(null, arguments);\r\n } else {\r\n var args = [arguments[0]];\r\n originalMethods.warn.apply(null, args);\r\n }\r\n };\r\n\r\n return $delegate;\r\n }]);\r\n\r\n /*\r\n * Sets up the theming provider.\r\n */\r\n if (root.staticData && root.staticData.currentTheme) {\r\n angular.extend($themeProvider.themeTemplate, root.staticData.currentTheme);\r\n $themeProvider.setCurrentTheme();\r\n }\r\n }])\r\n .controller('GlobalController', ['$scope', '$log', '$window', function ($scope, $log, $window) {\r\n /**\r\n * When invoked shows the terms of use window.\r\n */\r\n $scope.showTermsOfUse = function () {\r\n var width = 800;\r\n var height = 600;\r\n var left = ($window.screen.width / 2) - (width / 2);\r\n var top = ($window.screen.height / 2) - (height / 2);\r\n $log.debug('Terms of Use URL:', root.staticData.urls.termsOfUseUrl);\r\n var targetWin = $window.open(root.staticData.urls.termsOfUseUrl,\r\n \"TermsOfUse\",\r\n \"toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,width=\" + width + \", height=\" + height + \", top=\" + top + \", left=\" + left);\r\n };\r\n }])\r\n .controller('attController', ['$scope', function ($scope) {\r\n $scope.isSigned = false;\r\n }])\r\n .directive('onSumtClickValidation', function () {\r\n return function (scope, element, attrs) {\r\n element.on('click', (function (event) {\r\n if (!scope.isSigned) {\r\n if (attrs.selectedvalue == '1') {\r\n event.preventDefault();\r\n alert(attrs.onSumtClickValidation);\r\n }\r\n }\r\n }));\r\n };\r\n })\r\n .directive('sumtTextbox', function () {\r\n return function (scope, element, attrs) {\r\n element.on('focus', (function (event) {\r\n if (attrs.issupportedbrowser == 0 && this.value == attrs.placeholder) {\r\n this.value = '';\r\n scope.isSigned = false;\r\n }\r\n }));\r\n element.on('blur', (function (event) {\r\n if (attrs.issupportedbrowser == 0 && this.value == '') {\r\n this.value = attrs.placeholder;\r\n scope.isSigned = false;\r\n }\r\n }));\r\n\r\n if (attrs.value) {\r\n scope.signature = attrs.value;\r\n }\r\n\r\n\r\n element.on('change', (function (event) {\r\n if (attrs.issupportedbrowser == 0 && scope.signature == attrs.placeholder) {\r\n scope.isSigned = false;\r\n }\r\n else if (scope.signature && scope.signature != '') {\r\n scope.isSigned = true;\r\n }\r\n else {\r\n scope.isSigned = false;\r\n }\r\n }))\r\n\r\n };\r\n });\r\n}(this));\r\n"],"sourceRoot":"/source/"}