'use strict';var COMPILED=!0,goog=goog||{};goog.global=this;goog.isDef=function(a){return void 0!==a};goog.exportPath_=function(a,b,c){a=a.split(".");c=c||goog.global;a[0]in c||!c.execScript||c.execScript("var "+a[0]);for(var d;a.length&&(d=a.shift());)!a.length&&goog.isDef(b)?c[d]=b:c=c[d]?c[d]:c[d]={}};
goog.define=function(a,b){var c=b;COMPILED||(goog.global.CLOSURE_UNCOMPILED_DEFINES&&Object.prototype.hasOwnProperty.call(goog.global.CLOSURE_UNCOMPILED_DEFINES,a)?c=goog.global.CLOSURE_UNCOMPILED_DEFINES[a]:goog.global.CLOSURE_DEFINES&&Object.prototype.hasOwnProperty.call(goog.global.CLOSURE_DEFINES,a)&&(c=goog.global.CLOSURE_DEFINES[a]));goog.exportPath_(a,c)};goog.DEBUG=!0;goog.LOCALE="en";goog.TRUSTED_SITE=!0;goog.STRICT_MODE_COMPATIBLE=!1;
goog.provide=function(a){if(!COMPILED&&goog.isProvided_(a))throw Error('Namespace "'+a+'" already declared.');goog.constructNamespace_(a)};goog.constructNamespace_=function(a,b){if(!COMPILED){delete goog.implicitNamespaces_[a];for(var c=a;(c=c.substring(0,c.lastIndexOf(".")))&&!goog.getObjectByName(c);)goog.implicitNamespaces_[c]=!0}goog.exportPath_(a,b)};
goog.module=function(a){if(!goog.isString(a)||!a)throw Error("Invalid module identifier");if(!goog.isInModuleLoader_())throw Error("Module "+a+" has been loaded incorrectly.");if(goog.moduleLoaderState_.moduleName)throw Error("goog.module may only be called once per module.");goog.moduleLoaderState_.moduleName=a;if(!COMPILED){if(goog.isProvided_(a))throw Error('Namespace "'+a+'" already declared.');delete goog.implicitNamespaces_[a]}};goog.module.get=function(a){return goog.module.getInternal_(a)};
goog.module.getInternal_=function(a){if(!COMPILED)return goog.isProvided_(a)?a in goog.loadedModules_?goog.loadedModules_[a]:goog.getObjectByName(a):null};goog.moduleLoaderState_=null;goog.isInModuleLoader_=function(){return null!=goog.moduleLoaderState_};goog.module.declareTestMethods=function(){if(!goog.isInModuleLoader_())throw Error("goog.module.declareTestMethods must be called from within a goog.module");goog.moduleLoaderState_.declareTestMethods=!0};
goog.module.declareLegacyNamespace=function(){if(!COMPILED&&!goog.isInModuleLoader_())throw Error("goog.module.declareLegacyNamespace must be called from within a goog.module");if(!COMPILED&&!goog.moduleLoaderState_.moduleName)throw Error("goog.module must be called prior to goog.module.declareLegacyNamespace.");goog.moduleLoaderState_.declareLegacyNamespace=!0};
goog.setTestOnly=function(a){if(COMPILED&&!goog.DEBUG)throw a=a||"",Error("Importing test-only code into non-debug environment"+(a?": "+a:"."));};goog.forwardDeclare=function(a){};COMPILED||(goog.isProvided_=function(a){return a in goog.loadedModules_||!goog.implicitNamespaces_[a]&&goog.isDefAndNotNull(goog.getObjectByName(a))},goog.implicitNamespaces_={"goog.module":!0});
goog.getObjectByName=function(a,b){for(var c=a.split("."),d=b||goog.global,e;e=c.shift();)if(goog.isDefAndNotNull(d[e]))d=d[e];else return null;return d};goog.globalize=function(a,b){var c=b||goog.global,d;for(d in a)c[d]=a[d]};goog.addDependency=function(a,b,c,d){if(goog.DEPENDENCIES_ENABLED){var e;a=a.replace(/\\/g,"/");for(var f=goog.dependencies_,g=0;e=b[g];g++)f.nameToPath[e]=a,f.pathIsModule[a]=!!d;for(d=0;b=c[d];d++)a in f.requires||(f.requires[a]={}),f.requires[a][b]=!0}};
goog.ENABLE_DEBUG_LOADER=!0;goog.logToConsole_=function(a){goog.global.console&&goog.global.console.error(a)};goog.require=function(a){if(!COMPILED){if(goog.isProvided_(a))return goog.isInModuleLoader_()?goog.module.getInternal_(a):null;if(goog.ENABLE_DEBUG_LOADER){var b=goog.getPathFromDeps_(a);if(b)return goog.included_[b]=!0,goog.writeScripts_(),null}a="goog.require could not find: "+a;goog.logToConsole_(a);throw Error(a);}};goog.basePath="";goog.nullFunction=function(){};
goog.identityFunction=function(a,b){return a};goog.abstractMethod=function(){throw Error("unimplemented abstract method");};goog.addSingletonGetter=function(a){a.getInstance=function(){if(a.instance_)return a.instance_;goog.DEBUG&&(goog.instantiatedSingletons_[goog.instantiatedSingletons_.length]=a);return a.instance_=new a}};goog.instantiatedSingletons_=[];goog.LOAD_MODULE_USING_EVAL=!0;goog.SEAL_MODULE_EXPORTS=goog.DEBUG;goog.loadedModules_={};goog.DEPENDENCIES_ENABLED=!COMPILED&&goog.ENABLE_DEBUG_LOADER;
goog.DEPENDENCIES_ENABLED&&(goog.included_={},goog.dependencies_={pathIsModule:{},nameToPath:{},requires:{},visited:{},written:{}},goog.inHtmlDocument_=function(){var a=goog.global.document;return"undefined"!=typeof a&&"write"in a},goog.findBasePath_=function(){if(goog.global.CLOSURE_BASE_PATH)goog.basePath=goog.global.CLOSURE_BASE_PATH;else if(goog.inHtmlDocument_())for(var a=goog.global.document.getElementsByTagName("script"),b=a.length-1;0<=b;--b){var c=a[b].src,d=c.lastIndexOf("?"),d=-1==d?c.length:
d;if("base.js"==c.substr(d-7,7)){goog.basePath=c.substr(0,d-7);break}}},goog.importScript_=function(a,b){(goog.global.CLOSURE_IMPORT_SCRIPT||goog.writeScriptTag_)(a,b)&&(goog.dependencies_.written[a]=!0)},goog.IS_OLD_IE_=goog.global.document&&goog.global.document.all&&!goog.global.atob,goog.importModule_=function(a){goog.importScript_("",'goog.retrieveAndExecModule_("'+a+'");')&&(goog.dependencies_.written[a]=!0)},goog.queuedModules_=[],goog.retrieveAndExecModule_=function(a){for(var b;-1!=(b=a.indexOf("/./"));)a=
a.substr(0,b)+a.substr(b+2);for(;-1!=(b=a.indexOf("/../"));){var c=a.lastIndexOf("/",b-1);a=a.substr(0,c)+a.substr(b+3)}b=goog.global.CLOSURE_IMPORT_SCRIPT||goog.writeScriptTag_;var d=null,c=new goog.global.XMLHttpRequest;c.onload=function(){d=this.responseText};c.open("get",a,!1);c.send();d=c.responseText;if(null!=d)c=goog.wrapModule_(a,d),goog.IS_OLD_IE_?goog.queuedModules_.push(c):b(a,c),goog.dependencies_.written[a]=!0;else throw Error("load of "+a+"failed");},goog.wrapModule_=function(a,b){return goog.LOAD_MODULE_USING_EVAL&&
goog.isDef(goog.global.JSON)?"goog.loadModule("+goog.global.JSON.stringify(b+"\n//# sourceURL="+a+"\n")+");":'goog.loadModule(function(exports) {"use strict";'+b+"\n;return exports});\n//# sourceURL="+a+"\n"},goog.loadQueuedModules_=function(){var a=goog.queuedModules_.length;if(0<a){var b=goog.queuedModules_;goog.queuedModules_=[];for(var c=0;c<a;c++)goog.globalEval(b[c])}},goog.loadModule=function(a){try{goog.moduleLoaderState_={moduleName:void 0,declareTestMethods:!1};var b;if(goog.isFunction(a))b=
a.call(goog.global,{});else if(goog.isString(a))b=goog.loadModuleFromSource_.call(goog.global,a);else throw Error("Invalid module definition");var c=goog.moduleLoaderState_.moduleName;if(!goog.isString(c)||!c)throw Error('Invalid module name "'+c+'"');goog.moduleLoaderState_.declareLegacyNamespace?goog.constructNamespace_(c,b):goog.SEAL_MODULE_EXPORTS&&Object.seal&&Object.seal(b);goog.loadedModules_[c]=b;if(goog.moduleLoaderState_.declareTestMethods)for(var d in b)if(0===d.indexOf("test",0)||"tearDown"==
d||"setUp"==d||"setUpPage"==d||"tearDownPage"==d)goog.global[d]=b[d]}finally{goog.moduleLoaderState_=null}},goog.loadModuleFromSource_=function(a){eval(a);return{}},goog.writeScriptTag_=function(a,b){if(goog.inHtmlDocument_()){var c=goog.global.document;if("complete"==c.readyState){if(/\bdeps.js$/.test(a))return!1;throw Error('Cannot write "'+a+'" after document load');}var d=goog.IS_OLD_IE_;void 0===b?d?(d=" onreadystatechange='goog.onScriptLoad_(this, "+ ++goog.lastNonModuleScriptIndex_+")' ",c.write('<script type="text/javascript" src="'+
a+'"'+d+">\x3c/script>")):c.write('<script type="text/javascript" src="'+a+'">\x3c/script>'):c.write('<script type="text/javascript">'+b+"\x3c/script>");return!0}return!1},goog.lastNonModuleScriptIndex_=0,goog.onScriptLoad_=function(a,b){"complete"==a.readyState&&goog.lastNonModuleScriptIndex_==b&&goog.loadQueuedModules_();return!0},goog.writeScripts_=function(){function a(e){if(!(e in d.written)){if(!(e in d.visited)&&(d.visited[e]=!0,e in d.requires))for(var f in d.requires[e])if(!goog.isProvided_(f))if(f in
d.nameToPath)a(d.nameToPath[f]);else throw Error("Undefined nameToPath for "+f);e in c||(c[e]=!0,b.push(e))}}var b=[],c={},d=goog.dependencies_,e;for(e in goog.included_)d.written[e]||a(e);for(var f=0;f<b.length;f++)e=b[f],goog.dependencies_.written[e]=!0;var g=goog.moduleLoaderState_;goog.moduleLoaderState_=null;for(f=0;f<b.length;f++)if(e=b[f])d.pathIsModule[e]?goog.importModule_(goog.basePath+e):goog.importScript_(goog.basePath+e);else throw goog.moduleLoaderState_=g,Error("Undefined script input");
goog.moduleLoaderState_=g},goog.getPathFromDeps_=function(a){return a in goog.dependencies_.nameToPath?goog.dependencies_.nameToPath[a]:null},goog.findBasePath_(),goog.global.CLOSURE_NO_DEPS||goog.importScript_(goog.basePath+"deps.js"));
goog.typeOf=function(a){var b=typeof a;if("object"==b)if(a){if(a instanceof Array)return"array";if(a instanceof Object)return b;var c=Object.prototype.toString.call(a);if("[object Window]"==c)return"object";if("[object Array]"==c||"number"==typeof a.length&&"undefined"!=typeof a.splice&&"undefined"!=typeof a.propertyIsEnumerable&&!a.propertyIsEnumerable("splice"))return"array";if("[object Function]"==c||"undefined"!=typeof a.call&&"undefined"!=typeof a.propertyIsEnumerable&&!a.propertyIsEnumerable("call"))return"function"}else return"null";
else if("function"==b&&"undefined"==typeof a.call)return"object";return b};goog.isNull=function(a){return null===a};goog.isDefAndNotNull=function(a){return null!=a};goog.isArray=function(a){return"array"==goog.typeOf(a)};goog.isArrayLike=function(a){var b=goog.typeOf(a);return"array"==b||"object"==b&&"number"==typeof a.length};goog.isDateLike=function(a){return goog.isObject(a)&&"function"==typeof a.getFullYear};goog.isString=function(a){return"string"==typeof a};
goog.isBoolean=function(a){return"boolean"==typeof a};goog.isNumber=function(a){return"number"==typeof a};goog.isFunction=function(a){return"function"==goog.typeOf(a)};goog.isObject=function(a){var b=typeof a;return"object"==b&&null!=a||"function"==b};goog.getUid=function(a){return a[goog.UID_PROPERTY_]||(a[goog.UID_PROPERTY_]=++goog.uidCounter_)};goog.hasUid=function(a){return!!a[goog.UID_PROPERTY_]};goog.removeUid=function(a){"removeAttribute"in a&&a.removeAttribute(goog.UID_PROPERTY_);try{delete a[goog.UID_PROPERTY_]}catch(b){}};
goog.UID_PROPERTY_="closure_uid_"+(1E9*Math.random()>>>0);goog.uidCounter_=0;goog.getHashCode=goog.getUid;goog.removeHashCode=goog.removeUid;goog.cloneObject=function(a){var b=goog.typeOf(a);if("object"==b||"array"==b){if(a.clone)return a.clone();var b="array"==b?[]:{},c;for(c in a)b[c]=goog.cloneObject(a[c]);return b}return a};goog.bindNative_=function(a,b,c){return a.call.apply(a.bind,arguments)};
goog.bindJs_=function(a,b,c){if(!a)throw Error();if(2<arguments.length){var d=Array.prototype.slice.call(arguments,2);return function(){var c=Array.prototype.slice.call(arguments);Array.prototype.unshift.apply(c,d);return a.apply(b,c)}}return function(){return a.apply(b,arguments)}};goog.bind=function(a,b,c){Function.prototype.bind&&-1!=Function.prototype.bind.toString().indexOf("native code")?goog.bind=goog.bindNative_:goog.bind=goog.bindJs_;return goog.bind.apply(null,arguments)};
goog.partial=function(a,b){var c=Array.prototype.slice.call(arguments,1);return function(){var b=c.slice();b.push.apply(b,arguments);return a.apply(this,b)}};goog.mixin=function(a,b){for(var c in b)a[c]=b[c]};goog.now=goog.TRUSTED_SITE&&Date.now||function(){return+new Date};
goog.globalEval=function(a){if(goog.global.execScript)goog.global.execScript(a,"JavaScript");else if(goog.global.eval)if(null==goog.evalWorksForGlobals_&&(goog.global.eval("var _et_ = 1;"),"undefined"!=typeof goog.global._et_?(delete goog.global._et_,goog.evalWorksForGlobals_=!0):goog.evalWorksForGlobals_=!1),goog.evalWorksForGlobals_)goog.global.eval(a);else{var b=goog.global.document,c=b.createElement("script");c.type="text/javascript";c.defer=!1;c.appendChild(b.createTextNode(a));b.body.appendChild(c);
b.body.removeChild(c)}else throw Error("goog.globalEval not available");};goog.evalWorksForGlobals_=null;goog.getCssName=function(a,b){var c=function(a){return goog.cssNameMapping_[a]||a},d=function(a){a=a.split("-");for(var b=[],d=0;d<a.length;d++)b.push(c(a[d]));return b.join("-")},d=goog.cssNameMapping_?"BY_WHOLE"==goog.cssNameMappingStyle_?c:d:function(a){return a};return b?a+"-"+d(b):d(a)};goog.setCssNameMapping=function(a,b){goog.cssNameMapping_=a;goog.cssNameMappingStyle_=b};
!COMPILED&&goog.global.CLOSURE_CSS_NAME_MAPPING&&(goog.cssNameMapping_=goog.global.CLOSURE_CSS_NAME_MAPPING);goog.getMsg=function(a,b){b&&(a=a.replace(/\{\$([^}]+)}/g,function(a,d){return d in b?b[d]:a}));return a};goog.getMsgWithFallback=function(a,b){return a};goog.exportSymbol=function(a,b,c){goog.exportPath_(a,b,c)};goog.exportProperty=function(a,b,c){a[b]=c};
goog.inherits=function(a,b){function c(){}c.prototype=b.prototype;a.superClass_=b.prototype;a.prototype=new c;a.prototype.constructor=a;a.base=function(a,c,f){var g=Array.prototype.slice.call(arguments,2);return b.prototype[c].apply(a,g)}};
goog.base=function(a,b,c){var d=arguments.callee.caller;if(goog.STRICT_MODE_COMPATIBLE||goog.DEBUG&&!d)throw Error("arguments.caller not defined.  goog.base() cannot be used with strict mode code. See http://www.ecma-international.org/ecma-262/5.1/#sec-C");if(d.superClass_)return d.superClass_.constructor.apply(a,Array.prototype.slice.call(arguments,1));for(var e=Array.prototype.slice.call(arguments,2),f=!1,g=a.constructor;g;g=g.superClass_&&g.superClass_.constructor)if(g.prototype[b]===d)f=!0;else if(f)return g.prototype[b].apply(a,
e);if(a[b]===d)return a.constructor.prototype[b].apply(a,e);throw Error("goog.base called from a method of one name to a method of a different name");};goog.scope=function(a){a.call(goog.global)};COMPILED||(goog.global.COMPILED=COMPILED);
goog.defineClass=function(a,b){var c=b.constructor,d=b.statics;c&&c!=Object.prototype.constructor||(c=function(){throw Error("cannot instantiate an interface (no constructor defined).");});c=goog.defineClass.createSealingConstructor_(c,a);a&&goog.inherits(c,a);delete b.constructor;delete b.statics;goog.defineClass.applyProperties_(c.prototype,b);null!=d&&(d instanceof Function?d(c):goog.defineClass.applyProperties_(c,d));return c};goog.defineClass.SEAL_CLASS_INSTANCES=goog.DEBUG;
goog.defineClass.createSealingConstructor_=function(a,b){if(goog.defineClass.SEAL_CLASS_INSTANCES&&Object.seal instanceof Function){if(b&&b.prototype&&b.prototype[goog.UNSEALABLE_CONSTRUCTOR_PROPERTY_])return a;var c=function(){var b=a.apply(this,arguments)||this;b[goog.UID_PROPERTY_]=b[goog.UID_PROPERTY_];this.constructor===c&&Object.seal(b);return b};return c}return a};goog.defineClass.OBJECT_PROTOTYPE_FIELDS_="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" ");
goog.defineClass.applyProperties_=function(a,b){for(var c in b)Object.prototype.hasOwnProperty.call(b,c)&&(a[c]=b[c]);for(var d=0;d<goog.defineClass.OBJECT_PROTOTYPE_FIELDS_.length;d++)c=goog.defineClass.OBJECT_PROTOTYPE_FIELDS_[d],Object.prototype.hasOwnProperty.call(b,c)&&(a[c]=b[c])};goog.tagUnsealableClass=function(a){!COMPILED&&goog.defineClass.SEAL_CLASS_INSTANCES&&(a.prototype[goog.UNSEALABLE_CONSTRUCTOR_PROPERTY_]=!0)};goog.UNSEALABLE_CONSTRUCTOR_PROPERTY_="goog_defineClass_legacy_unsealable";var my={logo:{}};my.logo.Directive={};my.logo.Directive=function(a){this.lsAppConfig_=a;this.link=this.link.bind(this)};my.logo.Directive.factory=function(a){return{restrict:"A",link:(new my.logo.Directive(a)).link}};my.logo.Directive.factory.$inject=["lsAppConfig"];
my.logo.Directive.prototype.link=function(a,b,c){var d=this.lsAppConfig_;this.scope=a;this.elem=b;this.attrs=c;d.customLogoURL&&this.elem.append('<img class="pull-right" src="'+d.customLogoURL+'">');d.defaultLogo&&this.elem.append('<img class="pull-left" src="'+d.defaultLogo+'">')};my.locale={};my.locale.Service=function(a,b,c){this.$log_=a;this.$translate_=b;this.tmhDynamicLocale_=c;this.lang=b.use();c.set(this.lang)};my.locale.Service.$inject=["$log","$translate","tmhDynamicLocale"];my.locale.Service.prototype.changeLanguage=function(a){var b=this.$translate_,c=this.tmhDynamicLocale_;this.$log_.debug("change language to "+a);b.use(a);c.set(a)};goog.exportSymbol("my.locale.Service.prototype.changeLanguage",my.locale.Service.prototype.changeLanguage);
my.locale.Service.prototype.getLanguage=function(){return this.$translate_.use()};goog.exportSymbol("my.locale.Service.prototype.getLanguage",my.locale.Service.prototype.getLanguage);my.upload_proposition={};my.upload_proposition.Ctrl=function(a,b,c,d,e){this.$state_=a;this.growl_=b;this.locale_=c;this.UploadProposition_=d;this.form={};this.confirmed=!1;this.recaptchaPublicKey=e.recaptchaPublicKey};goog.exportSymbol("my.upload_proposition.Ctrl",my.upload_proposition.Ctrl);my.upload_proposition.Ctrl.$inject=["$state","growl","locale","UploadProposition","lsAppConfig"];
my.upload_proposition.Ctrl.prototype.submit=function(){var a=this.growl_,b=this;this.UploadProposition_.create(this.form).success(function(){b.confirmed=!0}).error(function(b,d){400===d&&1E3===b.code&&a.addErrorMessage("VALIDATION_ERROR.INVALID_CAPTCHA");503===d&&a.addErrorMessage("VALIDATION_ERROR.SERVER_ERROR")})};goog.exportProperty(my.upload_proposition.Ctrl.prototype,"submit",my.upload_proposition.Ctrl.prototype.submit);my.upload_proposition.Ctrl.prototype.reset=function(){};
goog.exportProperty(my.upload_proposition.Ctrl.prototype,"reset",my.upload_proposition.Ctrl.prototype.reset);my.upload_proposition.Ctrl.prototype.changeLanguage=function(a){this.locale_.changeLanguage(a)};goog.exportProperty(my.upload_proposition.Ctrl.prototype,"changeLanguage",my.upload_proposition.Ctrl.prototype.changeLanguage);my.upload_proposition.Ctrl.prototype.getLanguage=function(){return this.locale_.getLanguage()};goog.exportProperty(my.upload_proposition.Ctrl.prototype,"getLanguage",my.upload_proposition.Ctrl.prototype.getLanguage);my.upload_proposition.Service=function(a,b,c,d){this.vcRecaptchaService_=a;this.$http_=b;this.$log_=c;this.lsAppConfig_=d};my.upload_proposition.Service.$inject=["vcRecaptchaService","$http","$log","lsAppConfig"];
my.upload_proposition.Service.prototype.create=function(a){var b=this.$http_,c=this.$log_,d=this.vcRecaptchaService_,e=this.lsAppConfig_,f=d.data();a.captcha_response=f.response;a.captcha_challenge=f.challenge;return b.post(""+e.backendURL,a).error(function(a,b){c.error(a);c.error(b);400===b&&1E3===a.code&&d.reload()})};my.upload_proposition.module=angular.module("upload_proposition",["ui.router"]);my.upload_proposition.module.configuration=function(a){a.state("upload_proposition",{url:"/upload_proposition",templateUrl:"states/upload_proposition/upload_proposition.html",controller:"UploadPropositionCtrl as upload_proposition"})};my.upload_proposition.module.configuration.$inject=["$stateProvider"];
my.upload_proposition.module.config(my.upload_proposition.module.configuration).controller("UploadPropositionCtrl",my.upload_proposition.Ctrl).service("UploadProposition",my.upload_proposition.Service);angular.module("app",["ngLocale","ngSanitize","ngCookies","ngResource","ui.router","ui.bootstrap","pascalprecht.translate","tmh.dynamicLocale","chieffancypants.loadingBar","angular-growl","vcRecaptcha","validation","validation.rule",my.upload_proposition.module.name]).config(config).directive("logo",my.logo.Directive.factory).service("locale",my.locale.Service);
function config(a,b,c,d,e,f,g,h){a.debugEnabled(h.debug);b.state("404",{url:"/404",templateUrl:"states/404/404.html"});c.otherwise("/upload_proposition");d.useStaticFilesLoader({prefix:"i18n/locale-",suffix:".json"});d.preferredLanguage(h.defaultLocale);d.addInterpolation("$translateMessageFormatInterpolation");d.useMissingTranslationHandlerLog();d.useCookieStorage();e.showSuccessMessage=!1;f.localeLocationPattern("i18n/angular/angular-locale_{{locale}}.js");g.includeSpinner=!1}config.$inject="$logProvider $stateProvider $urlRouterProvider $translateProvider $validationProvider tmhDynamicLocaleProvider cfpLoadingBarProvider lsAppConfig".split(" ");
