inhsghk.hgvsibf.gigigi.cc
Open in
urlscan Pro
183.56.250.136
Public Scan
Submitted URL: http://inhsghk.hgvsibf.gigigi.cc/web/resource/js/app/common.min.js?v=202201250002
Effective URL: https://inhsghk.hgvsibf.gigigi.cc/web/resource/js/app/common.min.js?v=202201250002
Submission: On May 04 via api from US — Scanned from DE
Effective URL: https://inhsghk.hgvsibf.gigigi.cc/web/resource/js/app/common.min.js?v=202201250002
Submission: On May 04 via api from US — Scanned from DE
Form analysis
0 forms found in the DOMText Content
var mod;function resizeView(){var e=document.documentElement.clientHeight,t=0<$(".footer").length?$(".footer").css("height"):0,a=0<$(".left-menu-content").length?$(".left-menu-content").css("height"):0;$(".main-panel-body,.panel-cut").css("min-height",e-100),$(".caret-wxapp .panel-app").css("min-height",e-95),parseInt(a)>e-50?$(".skin-black .right-content>.content").css("min-height",parseInt(a)-parseInt(t)-30+"px"):$(".skin-black .right-content>.content").css("min-height",e-parseInt(t)-93+"px")}!function(h){"use strict";function w(s,o){return o=o||Error,function(){var e,t,a=arguments,n=a[0],i="["+(s?s+":":"")+n+"] ";for(i+=a[1].replace(/\{\d+\}/g,function(e){var t=2+ +e.slice(1,-1);return t<a.length?Re(a[t]):e}),i+="\nhttp://errors.angularjs.org/1.5.6/"+(s?s+"/":"")+n,t=2,e="?";t<a.length;t++,e="&")i+=e+"p"+(t-2)+"="+encodeURIComponent(Re(a[t]));return new o(i)}}var s=/^\/(.+)\/([a-z]*)$/,d="validity",L=Object.prototype.hasOwnProperty,O=function(e){return R(e)?e.toLowerCase():e},u=function(e){return R(e)?e.toUpperCase():e};"i"!=="I".toLowerCase()&&(O=function(e){return R(e)?e.replace(/[A-Z]/g,function(e){return String.fromCharCode(32|e.charCodeAt(0))}):e},u=function(e){return R(e)?e.replace(/[a-z]/g,function(e){return String.fromCharCode(-33&e.charCodeAt(0))}):e});var U,me,i,f,o=[].slice,a=[].splice,e=[].push,$=Object.prototype.toString,r=Object.getPrototypeOf,l=w("ng"),S=h.angular||(h.angular={}),t=0;function j(e){if(null!=e&&!M(e)){if(be(e)||R(e)||me&&e instanceof me)return 1;var t="length"in Object(e)&&e.length;return _(t)&&(0<=t&&(t-1 in e||e instanceof Array)||"function"==typeof e.item)}}function ge(e,t,a){if(e)if(we(e))for(i in e)"prototype"==i||"length"==i||"name"==i||e.hasOwnProperty&&!e.hasOwnProperty(i)||t.call(a,e[i],i,e);else if(be(e)||j(e))for(var n="object"!=typeof e,i=0,s=e.length;i<s;i++)(n||i in e)&&t.call(a,e[i],i,e);else if(e.forEach&&e.forEach!==ge)e.forEach(t,a,e);else if(x(e))for(i in e)t.call(a,e[i],i,e);else if("function"==typeof e.hasOwnProperty)for(i in e)e.hasOwnProperty(i)&&t.call(a,e[i],i,e);else for(i in e)L.call(e,i)&&t.call(a,e[i],i,e);return e}function c(e,t,a){for(var n=Object.keys(e).sort(),i=0;i<n.length;i++)t.call(a,e[n[i]],n[i]);return n}function v(a){return function(e,t){a(t,e)}}function p(){return++t}function m(e,t){t?e.$$hashKey=t:delete e.$$hashKey}function g(e,t,a){for(var n=e.$$hashKey,i=0,s=t.length;i<s;++i){var o=t[i];if(ye(o)||we(o))for(var r=Object.keys(o),l=0,c=r.length;l<c;l++){var u=r[l],d=o[u];a&&ye(d)?C(d)?e[u]=new Date(d.valueOf()):A(d)?e[u]=new RegExp(d):d.nodeName?e[u]=d.cloneNode(!0):E(d)?e[u]=d.clone():(ye(e[u])||(e[u]=be(d)?[]:{}),g(e[u],[d],!0)):e[u]=d}}return m(e,n),e}function fe(e){return g(e,o.call(arguments,1),!1)}function n(e){return g(e,o.call(arguments,1),!0)}function y(e){return parseInt(e,10)}function he(e,t){return fe(Object.create(e),t)}function N(){}function b(e){return e}function I(e){return function(){return e}}function k(e){return we(e.toString)&&e.toString!==$}function ve(e){return void 0===e}function B(e){return void 0!==e}function ye(e){return null!==e&&"object"==typeof e}function x(e){return null!==e&&"object"==typeof e&&!r(e)}function R(e){return"string"==typeof e}function _(e){return"number"==typeof e}function C(e){return"[object Date]"===$.call(e)}U=h.document.documentMode,N.$inject=[],b.$inject=[];var be=Array.isArray;function we(e){return"function"==typeof e}function A(e){return"[object RegExp]"===$.call(e)}function M(e){return e&&e.window===e}function $e(e){return e&&e.$evalAsync&&e.$watch}function q(e){return"boolean"==typeof e}function D(e){return e&&we(e.then)}var T=/^\[object (?:Uint8|Uint8Clamped|Uint16|Uint32|Int8|Int16|Int32|Float32|Float64)Array\]$/;var ke=function(e){return R(e)?e.trim():e},P=function(e){return e.replace(/([-()\[\]{}+?*.$\^|,:#<!\\])/g,"\\$1").replace(/\x08/g,"\\x08")};function E(e){return!(!e||!(e.nodeName||e.prop&&e.attr&&e.find))}function xe(e){return O(e.nodeName||e[0]&&e[0].nodeName)}function V(e,t){t=e.indexOf(t);return 0<=t&&e.splice(t,1),t}function Y(e,a){var t,n=[],i=[];if(a){if((t=a)&&_(t.length)&&T.test($.call(t))||(t=a,"[object ArrayBuffer]"===$.call(t)))throw l("cpta","Can't copy! TypedArray destination cannot be mutated.");if(e===a)throw l("cpi","Can't copy! Source and destination are identical.");return be(a)?a.length=0:ge(a,function(e,t){"$$hashKey"!==t&&delete a[t]}),n.push(e),i.push(a),s(e,a)}return o(e);function s(e,t){var a,n=t.$$hashKey;if(be(e))for(var i=0,s=e.length;i<s;i++)t.push(o(e[i]));else if(x(e))for(a in e)t[a]=o(e[a]);else if(e&&"function"==typeof e.hasOwnProperty)for(a in e)e.hasOwnProperty(a)&&(t[a]=o(e[a]));else for(a in e)L.call(e,a)&&(t[a]=o(e[a]));return m(t,n),t}function o(e){if(!ye(e))return e;var t=n.indexOf(e);if(-1!==t)return i[t];if(M(e)||$e(e))throw l("cpws","Can't copy! Making copies of Window or Scope instances is not supported.");var a=!1,t=function(e){switch($.call(e)){case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Float32Array]":case"[object Float64Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return new e.constructor(o(e.buffer));case"[object ArrayBuffer]":if(e.slice)return e.slice(0);var t=new ArrayBuffer(e.byteLength);return new Uint8Array(t).set(new Uint8Array(e)),t;case"[object Boolean]":case"[object Number]":case"[object String]":case"[object Date]":return new e.constructor(e.valueOf());case"[object RegExp]":t=new RegExp(e.source,e.toString().match(/[^\/]*$/)[0]);return t.lastIndex=e.lastIndex,t;case"[object Blob]":return new e.constructor([e],{type:e.type})}if(we(e.cloneNode))return e.cloneNode(!0)}(e);return void 0===t&&(t=be(e)?[]:Object.create(r(e)),a=!0),n.push(e),i.push(t),a?s(e,t):t}}function F(e,t){if(be(e)){t=t||[];for(var a=0,n=e.length;a<n;a++)t[a]=e[a]}else if(ye(e))for(var i in t=t||{},e)"$"===i.charAt(0)&&"$"===i.charAt(1)||(t[i]=e[i]);return t||e}function _e(e,t){if(e===t)return!0;if(null===e||null===t)return!1;if(e!=e&&t!=t)return!0;var a,n,i,s=typeof e;if(s==typeof t&&"object"==s){if(!be(e)){if(C(e))return!!C(t)&&_e(e.getTime(),t.getTime());if(A(e))return!!A(t)&&e.toString()==t.toString();if($e(e)||$e(t)||M(e)||M(t)||be(t)||C(t)||A(t))return!1;for(n in i=Ee(),e)if("$"!==n.charAt(0)&&!we(e[n])){if(!_e(e[n],t[n]))return!1;i[n]=!0}for(n in t)if(!(n in i)&&"$"!==n.charAt(0)&&B(t[n])&&!we(t[n]))return!1;return!0}if(!be(t))return!1;if((a=e.length)==t.length){for(n=0;n<a;n++)if(!_e(e[n],t[n]))return!1;return!0}}return!1}var z=function(){var e;return B(z.rules)||((e=h.document.querySelector("[ng-csp]")||h.document.querySelector("[data-ng-csp]"))?(e=e.getAttribute("ng-csp")||e.getAttribute("data-ng-csp"),z.rules={noUnsafeEval:!e||-1!==e.indexOf("no-unsafe-eval"),noInlineStyle:!e||-1!==e.indexOf("no-inline-style")}):z.rules={noUnsafeEval:function(){try{return new Function(""),!1}catch(e){return!0}}(),noInlineStyle:!1}),z.rules},H=function(){if(B(H.name_))return H.name_;for(var e,t,a,n=se.length,i=0;i<n;++i)if(t=se[i],e=h.document.querySelector("["+t.replace(":","\\:")+"jq]")){a=e.getAttribute(t+"jq");break}return H.name_=a};function W(e,t,a){return e.concat(o.call(t,a))}function Se(e,t){return o.call(e,t||0)}function Ie(e,t){var a=2<arguments.length?Se(arguments,2):[];return!we(t)||t instanceof RegExp?t:a.length?function(){return arguments.length?t.apply(e,W(a,arguments,0)):t.apply(e,a)}:function(){return arguments.length?t.apply(e,arguments):t.call(e)}}function G(e,t){var a=t;return"string"==typeof e&&"$"===e.charAt(0)&&"$"===e.charAt(1)?a=void 0:M(t)?a="$WINDOW":t&&h.document===t?a="$DOCUMENT":$e(t)&&(a="$SCOPE"),a}function K(e,t){if(!ve(e))return _(t)||(t=t?2:null),JSON.stringify(e,G,t)}function Q(e){return R(e)?JSON.parse(e):e}var J=/:/g;function Z(e,t){e=e.replace(J,"");e=Date.parse("Jan 01, 1970 00:00:00 "+e)/6e4;return isNaN(e)?t:e}function X(e,t,a){a=a?-1:1;var n=e.getTimezoneOffset(),t=Z(t,n);return e=e,n=a*(t-n),(e=new Date(e.getTime())).setMinutes(e.getMinutes()+n),e}function Ce(e){e=me(e).clone();try{e.empty()}catch(e){}var t=me("<div>").append(e).html();try{return e[0].nodeType===Le?O(t):t.match(/^(<[^>]+>)/)[1].replace(/^<([\w\-]+)/,function(e,t){return"<"+O(t)})}catch(e){return O(t)}}function ee(e){try{return decodeURIComponent(e)}catch(e){}}function te(e){var i={};return ge((e||"").split("&"),function(e){var t,a,n;e&&(a=e=e.replace(/\+/g,"%20"),-1!==(t=e.indexOf("="))&&(a=e.substring(0,t),n=e.substring(t+1)),B(a=ee(a))&&(n=!B(n)||ee(n),L.call(i,a)?be(i[a])?i[a].push(n):i[a]=[i[a],n]:i[a]=n))}),i}function ae(e){var a=[];return ge(e,function(e,t){be(e)?ge(e,function(e){a.push(ie(t,!0)+(!0===e?"":"="+ie(e,!0)))}):a.push(ie(t,!0)+(!0===e?"":"="+ie(e,!0)))}),a.length?a.join("&"):""}function ne(e){return ie(e,!0).replace(/%26/gi,"&").replace(/%3D/gi,"=").replace(/%2B/gi,"+")}function ie(e,t){return encodeURIComponent(e).replace(/%40/gi,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%3B/gi,";").replace(/%20/g,t?"%20":"+")}var se=["ng-","data-ng-","ng:","x-ng-"];function oe(a,e){var n,i,t={};ge(se,function(e){e+="app";!n&&a.hasAttribute&&a.hasAttribute(e)&&(i=(n=a).getAttribute(e))}),ge(se,function(e){var t,e=e+"app";!n&&(t=a.querySelector("["+e.replace(":","\\:")+"]"))&&(i=(n=t).getAttribute(e))}),n&&(t.strictDi=null!==function(e,t){for(var a,n=se.length,i=0;i<n;++i)if(a=se[i]+t,R(a=e.getAttribute(a)))return a;return null}(n,"strict-di"),e(n,i?[i]:[],t))}function re(t,a,n){n=fe({strictDi:!1},n=!ye(n)?{}:n);function i(){if((t=me(t)).injector()){var e=t[0]===h.document?"document":Ce(t);throw l("btstrpd","App already bootstrapped with this element '{0}'",e.replace(/</,"<").replace(/>/,">"))}return(a=a||[]).unshift(["$provide",function(e){e.value("$rootElement",t)}]),n.debugInfoEnabled&&a.push(["$compileProvider",function(e){e.debugInfoEnabled(!0)}]),a.unshift("ng"),(e=Yt(a,n.strictDi)).invoke(["$rootScope","$rootElement","$compile","$injector",function(e,t,a,n){e.$apply(function(){t.data("$injector",n),a(t)(e)})}]),e}var e=/^NG_ENABLE_DEBUG_INFO!/,s=/^NG_DEFER_BOOTSTRAP!/;if(h&&e.test(h.name)&&(n.debugInfoEnabled=!0,h.name=h.name.replace(e,"")),h&&!s.test(h.name))return i();h.name=h.name.replace(s,""),S.resumeBootstrap=function(e){return ge(e,function(e){a.push(e)}),i()},we(S.resumeDeferredBootstrap)&&S.resumeDeferredBootstrap()}function le(){h.name="NG_ENABLE_DEBUG_INFO!"+h.name,h.location.reload()}function ce(e){e=S.element(e).injector();if(!e)throw l("test","no injector found for element argument to getTestability");return e.get("$$testability")}var ue=/[A-Z]/g;function Ae(e,a){return a=a||"_",e.replace(ue,function(e,t){return(t?a:"")+e.toLowerCase()})}var de=!1;function Me(e,t,a){if(!e)throw l("areq","Argument '{0}' is {1}",t||"?",a||"required");return e}function pe(e,t,a){return Me(we(e=a&&be(e)?e[e.length-1]:e),t,"not a function, got "+(e&&"object"==typeof e?e.constructor.name||"Object":typeof e)),e}function De(e,t){if("hasOwnProperty"===e)throw l("badname","hasOwnProperty is not a valid {0} name",t)}function Te(e,t,a){if(!t)return e;for(var n,i=t.split("."),s=e,o=i.length,r=0;r<o;r++)n=i[r],e=e&&(s=e)[n];return!a&&we(e)?Ie(s,e):e}function Pe(e){for(var t,a=e[0],n=e[e.length-1],i=1;a!==n&&(a=a.nextSibling);i++)!t&&e[i]===a||(t=t||me(o.call(e,0,i))).push(a);return t||e}function Ee(){return Object.create(null)}var je=1,Le=3,Oe=8,Ue=9,Ne=11;function Be(e){var u=w("$injector"),a=w("ng");function t(e,t,a){return e[t]||(e[t]=a())}e=t(e,"angular",Object);return e.$$minErr=e.$$minErr||w,t(e,"module",function(){var e={};return function(r,l,c){return function(e,t){if("hasOwnProperty"===e)throw a("badname","hasOwnProperty is not a valid {0} name",t)}(r,"module"),l&&e.hasOwnProperty(r)&&(e[r]=null),t(e,r,function(){if(!l)throw u("nomod","Module '{0}' is not available! You either misspelled the module name or forgot to load it. If registering a module ensure that you specify the dependencies as the second argument.",r);var i=[],e=[],t=[],a=n("$injector","invoke","push",e),s={_invokeQueue:i,_configBlocks:e,_runBlocks:t,requires:l,name:r,provider:o("$provide","provider"),factory:o("$provide","factory"),service:o("$provide","service"),value:n("$provide","value"),constant:n("$provide","constant","unshift"),decorator:o("$provide","decorator"),animation:o("$animateProvider","register"),filter:o("$filterProvider","register"),controller:o("$controllerProvider","register"),directive:o("$compileProvider","directive"),component:o("$compileProvider","component"),config:a,run:function(e){return t.push(e),this}};return c&&a(c),s;function n(e,t,a,n){return n=n||i,function(){return n[a||"push"]([e,t,arguments]),s}}function o(a,n){return function(e,t){return t&&we(t)&&(t.$$moduleName=r),i.push([a,n,arguments]),s}}})}})}function Re(e){return"function"==typeof e?e.toString().replace(/ \{[\s\S]*$/,""):ve(e)?"undefined":"string"!=typeof e?(t=e,a=[],JSON.stringify(t,function(e,t){if(ye(t=G(e,t))){if(0<=a.indexOf(t))return"...";a.push(t)}return t})):e;var t,a}var qe={full:"1.5.6",major:1,minor:5,dot:6,codeName:"arrow-stringification"};rt.expando="ng339";var Ve=rt.cache={},Ye=1,Fe=function(e,t,a){e.addEventListener(t,a,!1)},ze=function(e,t,a){e.removeEventListener(t,a,!1)};rt._data=function(e){return this.cache[e[this.expando]]||{}};var He=/([\:\-\_]+(.))/g,We=/^moz([A-Z])/,Ge={mouseleave:"mouseout",mouseenter:"mouseover"},Ke=w("jqLite");function Qe(e){return e.replace(He,function(e,t,a,n){return n?a.toUpperCase():a}).replace(We,"Moz$1")}var Je=/^<([\w-]+)\s*\/?>(?:<\/\1>|)$/,Ze=/<|&#?\w+;/,Xe=/<([\w:-]+)/,et=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:-]+)[^>]*)\/>/gi,tt={option:[1,'<select multiple="multiple">',"</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};function at(e){return!Ze.test(e)}function nt(e){e=e.nodeType;return e===je||!e||e===Ue}function it(e,t){var a,n,i=t.createDocumentFragment(),s=[];if(at(e))s.push(t.createTextNode(e));else{for(a=a||i.appendChild(t.createElement("div")),t=(Xe.exec(e)||["",""])[1].toLowerCase(),t=tt[t]||tt._default,a.innerHTML=t[1]+e.replace(et,"<$1></$2>")+t[2],n=t[0];n--;)a=a.lastChild;s=W(s,a.childNodes),(a=i.firstChild).textContent=""}return i.textContent="",i.innerHTML="",ge(s,function(e){i.appendChild(e)}),i}function st(e,t){var a=e.parentNode;a&&a.replaceChild(t,e),t.appendChild(e)}tt.optgroup=tt.option,tt.tbody=tt.tfoot=tt.colgroup=tt.caption=tt.thead,tt.th=tt.td;var ot=h.Node.prototype.contains||function(e){return!!(16&this.compareDocumentPosition(e))};function rt(e){if(e instanceof rt)return e;var t,a,n;if(R(e)&&(e=ke(e),n=!0),!(this instanceof rt)){if(n&&"<"!=e.charAt(0))throw Ke("nosel","Looking up elements via selectors is not supported by jqLite! See: http://docs.angularjs.org/api/angular.element");return new rt(e)}vt(this,n?(t=e,a=a||h.document,(n=Je.exec(t))?[a.createElement(n[1])]:(n=it(t,a))?n.childNodes:[]):e)}function lt(e){return e.cloneNode(!0)}function ct(e,t){if(t||dt(e),e.querySelectorAll)for(var a=e.querySelectorAll("*"),n=0,i=a.length;n<i;n++)dt(a[n])}function ut(a,e,n,t){if(B(t))throw Ke("offargs","jqLite#off() does not support the `selector` argument");var t=pt(a),i=t&&t.events,s=t&&t.handle;if(s)if(e){var o=function(e){var t=i[e];B(n)&&V(t||[],n),B(n)&&t&&0<t.length||(ze(a,e,s),delete i[e])};ge(e.split(" "),function(e){o(e),Ge[e]&&o(Ge[e])})}else for(e in i)"$destroy"!==e&&ze(a,e,s),delete i[e]}function dt(e,t){var a=e.ng339,n=a&&Ve[a];n&&(t?delete n.data[t]:(n.handle&&(n.events.$destroy&&n.handle({},"$destroy"),ut(e)),delete Ve[a],e.ng339=void 0))}function pt(e,t){var a=e.ng339,n=a&&Ve[a];return t&&!n&&(e.ng339=a=++Ye,n=Ve[a]={events:{},data:{},handle:void 0}),n}function mt(e,t,a){if(nt(e)){var n=B(a),i=!n&&t&&!ye(t),s=!t,e=pt(e,!i),e=e&&e.data;if(!n)return s?e:i?e&&e[t]:void fe(e,t);e[t]=a}}function gt(e,t){return!!e.getAttribute&&-1<(" "+(e.getAttribute("class")||"")+" ").replace(/[\n\t]/g," ").indexOf(" "+t+" ")}function ft(t,e){e&&t.setAttribute&&ge(e.split(" "),function(e){t.setAttribute("class",ke((" "+(t.getAttribute("class")||"")+" ").replace(/[\n\t]/g," ").replace(" "+ke(e)+" "," ")))})}function ht(e,t){var a;t&&e.setAttribute&&(a=(" "+(e.getAttribute("class")||"")+" ").replace(/[\n\t]/g," "),ge(t.split(" "),function(e){e=ke(e),-1===a.indexOf(" "+e+" ")&&(a+=e+" ")}),e.setAttribute("class",ke(a)))}function vt(e,t){if(t)if(t.nodeType)e[e.length++]=t;else{var a=t.length;if("number"==typeof a&&t.window!==t){if(a)for(var n=0;n<a;n++)e[e.length++]=t[n]}else e[e.length++]=t}}function yt(e,t){return bt(e,"$"+(t||"ngController")+"Controller")}function bt(e,t,a){e.nodeType==Ue&&(e=e.documentElement);for(var n=be(t)?t:[t];e;){for(var i=0,s=n.length;i<s;i++)if(B(a=me.data(e,n[i])))return a;e=e.parentNode||e.nodeType===Ne&&e.host}}function wt(e){for(ct(e,!0);e.firstChild;)e.removeChild(e.firstChild)}function $t(e,t){t||ct(e);t=e.parentNode;t&&t.removeChild(e)}var kt=rt.prototype={ready:function(e){var t=!1;function a(){t||(t=!0,e())}"complete"===h.document.readyState?h.setTimeout(a):(this.on("DOMContentLoaded",a),rt(h).on("load",a))},toString:function(){var t=[];return ge(this,function(e){t.push(""+e)}),"["+t.join(", ")+"]"},eq:function(e){return me(0<=e?this[e]:this[this.length+e])},length:0,push:e,sort:[].sort,splice:[].splice},xt={};ge("multiple,selected,checked,disabled,readOnly,required,open".split(","),function(e){xt[O(e)]=e});var _t={};ge("input,select,option,textarea,button,form,details".split(","),function(e){_t[e]=!0});var St={ngMinlength:"minlength",ngMaxlength:"maxlength",ngMin:"min",ngMax:"max",ngPattern:"pattern"};function It(e,t){t=xt[t.toLowerCase()];return t&&_t[xe(e)]&&t}function Ct(e,t){if(ve(t)){var a=e.nodeType;return a===je||a===Le?e.textContent:""}e.textContent=t}function At(r,l){function e(e,t){e.isDefaultPrevented=function(){return e.defaultPrevented};var a,n=l[t||e.type],i=n?n.length:0;if(i){ve(e.immediatePropagationStopped)&&(a=e.stopImmediatePropagation,e.stopImmediatePropagation=function(){e.immediatePropagationStopped=!0,e.stopPropagation&&e.stopPropagation(),a&&a.call(e)}),e.isImmediatePropagationStopped=function(){return!0===e.immediatePropagationStopped};var s=n.specialHandlerWrapper||Mt;1<i&&(n=F(n));for(var o=0;o<i;o++)e.isImmediatePropagationStopped()||s(r,e,n[o])}}return e.elem=r,e}function Mt(e,t,a){a.call(e,t)}function Dt(e,t,a){var n=t.relatedTarget;n&&(n===e||ot.call(e,n))||a.call(e,t)}function Tt(){this.$get=function(){return fe(rt,{hasClass:function(e,t){return gt(e=e.attr?e[0]:e,t)},addClass:function(e,t){return ht(e=e.attr?e[0]:e,t)},removeClass:function(e,t){return ft(e=e.attr?e[0]:e,t)}})}}function Pt(e,t){var a=e&&e.$$hashKey;if(a)return a="function"==typeof a?e.$$hashKey():a;var n=typeof e;return a="function"==n||"object"==n&&null!==e?e.$$hashKey=n+":"+(t||p)():n+":"+e}function Et(e,t){var a;t&&(a=0,this.nextUid=function(){return++a}),ge(e,this.put,this)}ge({data:mt,removeData:dt,hasData:function(e){for(var t in Ve[e.ng339])return!0;return!1},cleanData:function(e){for(var t=0,a=e.length;t<a;t++)dt(e[t])}},function(e,t){rt[t]=e}),ge({data:mt,inheritedData:bt,scope:function(e){return me.data(e,"$scope")||bt(e.parentNode||e,["$isolateScope","$scope"])},isolateScope:function(e){return me.data(e,"$isolateScope")||me.data(e,"$isolateScopeNoTemplate")},controller:yt,injector:function(e){return bt(e,"$injector")},removeAttr:function(e,t){e.removeAttribute(t)},hasClass:gt,css:function(e,t,a){if(t=Qe(t),!B(a))return e.style[t];e.style[t]=a},attr:function(e,t,a){var n=e.nodeType;if(n!==Le&&2!==n&&n!==Oe){n=O(t);if(xt[n]){if(!B(a))return e[t]||(e.attributes.getNamedItem(t)||N).specified?n:void 0;a?(e[t]=!0,e.setAttribute(t,n)):(e[t]=!1,e.removeAttribute(n))}else if(B(a))e.setAttribute(t,a);else if(e.getAttribute){t=e.getAttribute(t,2);return null===t?void 0:t}}},prop:function(e,t,a){if(!B(a))return e[t];e[t]=a},text:(Ct.$dv="",Ct),val:function(e,t){if(ve(t)){if(e.multiple&&"select"===xe(e)){var a=[];return ge(e.options,function(e){e.selected&&a.push(e.value||e.text)}),0===a.length?null:a}return e.value}e.value=t},html:function(e,t){if(ve(t))return e.innerHTML;ct(e,!0),e.innerHTML=t},empty:wt},function(c,e){rt.prototype[e]=function(e,t){var a,n,i=this.length;if(c!==wt&&ve(2==c.length&&c!==gt&&c!==yt?e:t)){if(ye(e)){for(a=0;a<i;a++)if(c===mt)c(this[a],e);else for(n in e)c(this[a],n,e[n]);return this}for(var s=ve(l=c.$dv)?Math.min(i,1):i,o=0;o<s;o++)var r=c(this[o],e,t),l=l?l+r:r;return l}for(a=0;a<i;a++)c(this[a],e,t);return this}}),ge({removeData:dt,on:function(i,e,s,t){if(B(t))throw Ke("onargs","jqLite#on() does not support the `selector` or `eventData` parameters");if(nt(i))for(var t=pt(i,!0),o=t.events,r=(r=t.handle)||(t.handle=At(i,o)),a=0<=e.indexOf(" ")?e.split(" "):[e],n=a.length,l=function(e,t,a){var n=o[e];n||((n=o[e]=[]).specialHandlerWrapper=t,"$destroy"===e||a||Fe(i,e,r)),n.push(s)};n--;)e=a[n],Ge[e]?(l(Ge[e],Dt),l(e,void 0,!0)):l(e)},off:ut,one:function(t,a,n){(t=me(t)).on(a,function e(){t.off(a,n),t.off(a,e)}),t.on(a,n)},replaceWith:function(t,e){var a,n=t.parentNode;ct(t),ge(new rt(e),function(e){a?n.insertBefore(e,a.nextSibling):n.replaceChild(e,t),a=e})},children:function(e){var t=[];return ge(e.childNodes,function(e){e.nodeType===je&&t.push(e)}),t},contents:function(e){return e.contentDocument||e.childNodes||[]},append:function(e,t){var a=e.nodeType;if(a===je||a===Ne)for(var n=0,i=(t=new rt(t)).length;n<i;n++){var s=t[n];e.appendChild(s)}},prepend:function(t,e){var a;t.nodeType===je&&(a=t.firstChild,ge(new rt(e),function(e){t.insertBefore(e,a)}))},wrap:function(e,t){st(e,me(t).eq(0).clone()[0])},remove:$t,detach:function(e){$t(e,!0)},after:function(e,t){for(var a=e,n=e.parentNode,i=0,s=(t=new rt(t)).length;i<s;i++){var o=t[i];n.insertBefore(o,a.nextSibling),a=o}},addClass:ht,removeClass:ft,toggleClass:function(a,e,n){e&&ge(e.split(" "),function(e){var t=n;((t=ve(t)?!gt(a,e):t)?ht:ft)(a,e)})},parent:function(e){e=e.parentNode;return e&&e.nodeType!==Ne?e:null},next:function(e){return e.nextElementSibling},find:function(e,t){return e.getElementsByTagName?e.getElementsByTagName(t):[]},clone:lt,triggerHandler:function(t,e,a){var n,i,s=e.type||e,o=pt(t),o=o&&o.events,o=o&&o[s];o&&(n={preventDefault:function(){this.defaultPrevented=!0},isDefaultPrevented:function(){return!0===this.defaultPrevented},stopImmediatePropagation:function(){this.immediatePropagationStopped=!0},isImmediatePropagationStopped:function(){return!0===this.immediatePropagationStopped},stopPropagation:N,type:s,target:t},e.type&&(n=fe(n,e)),o=F(o),i=a?[n].concat(a):[n],ge(o,function(e){n.isImmediatePropagationStopped()||e.apply(t,i)}))}},function(o,e){rt.prototype[e]=function(e,t,a){for(var n,i=0,s=this.length;i<s;i++)ve(n)?B(n=o(this[i],e,t,a))&&(n=me(n)):vt(n,o(this[i],e,t,a));return B(n)?n:this},rt.prototype.bind=rt.prototype.on,rt.prototype.unbind=rt.prototype.off}),Et.prototype={put:function(e,t){this[Pt(e,this.nextUid)]=t},get:function(e){return this[Pt(e,this.nextUid)]},remove:function(e){var t=this[e=Pt(e,this.nextUid)];return delete this[e],t}};var jt=[function(){this.$get=[function(){return Et}]}],Lt=/^([^\(]+?)=>/,Ot=/^[^\(]*\(\s*([^\)]*)\)/m,Ut=/,/,Nt=/^\s*(_?)(\S+?)\1\s*$/,Bt=/((\/\/.*$)|(\/\*[\s\S]*?\*\/))/gm,Rt=w("$injector");function qt(e){return Function.prototype.toString.call(e)+" "}function Vt(e){e=qt(e).replace(Bt,"");return e.match(Lt)||e.match(Ot)}function Yt(e,c){c=!0===c;var s={},o="Provider",r=[],l=new Et([],!0),u={$provide:{provider:n(m),factory:n(i),service:n(function(e,t){return i(e,["$injector",function(e){return e.instantiate(t)}])}),value:n(function(e,t){return i(e,I(t),!1)}),constant:n(function(e,t){De(e,"constant"),u[e]=t,a[e]=t}),decorator:function(e,t){var a=d.get(e+o),n=a.$get;a.$get=function(){var e=p.invoke(n,a);return p.invoke(t,null,{$delegate:e})}}}},d=u.$injector=g(u,function(e,t){throw S.isString(t)&&r.push(t),Rt("unpr","Unknown provider: {0}",r.join(" <- "))}),a={},t=g(a,function(e,t){t=d.get(e+o,t);return p.invoke(t.$get,t,void 0,e)}),p=t;u["$injector"+o]={$get:I(t)};e=function a(e){Me(ve(e)||be(e),"modulesToLoad","not an array");var n,i=[];ge(e,function(t){if(!l.get(t)){l.put(t,!0);try{R(t)?(n=f(t),i=i.concat(a(n.requires)).concat(n._runBlocks),e(n._invokeQueue),e(n._configBlocks)):we(t)||be(t)?i.push(d.invoke(t)):pe(t,"module")}catch(e){throw be(t)&&(t=t[t.length-1]),e.message&&e.stack&&-1==e.stack.indexOf(e.message)&&(e=e.message+"\n"+e.stack),Rt("modulerr","Failed to instantiate module {0} due to:\n{1}",t,e.stack||e.message||e)}}function e(e){var t,a;for(t=0,a=e.length;t<a;t++){var n=e[t],i=d.get(n[0]);i[n[1]].apply(i,n[2])}}});return i}(e);return(p=t.get("$injector")).strictDi=c,ge(e,function(e){e&&p.invoke(e)}),p;function n(a){return function(e,t){if(!ye(e))return a(e,t);ge(e,v(a))}}function m(e,t){if(De(e,"service"),!(t=we(t)||be(t)?d.instantiate(t):t).$get)throw Rt("pget","Provider '{0}' must define $get factory method.",e);return u[e+o]=t}function i(e,t,a){return m(e,{$get:!1!==a?(n=e,i=t,function(){var e=p.invoke(i,this);if(ve(e))throw Rt("undef","Provider '{0}' must return a value from $get factory method.",n);return e}):t});var n,i}function g(a,n){function l(t,e){if(a.hasOwnProperty(t)){if(a[t]===s)throw Rt("cdep","Circular dependency found: {0}",t+" <- "+r.join(" <- "));return a[t]}try{return r.unshift(t),a[t]=s,a[t]=n(t,e)}catch(e){throw a[t]===s&&delete a[t],e}finally{r.shift()}}function i(e,t,a){for(var n=[],i=Yt.$$annotate(e,c,a),s=0,o=i.length;s<o;s++){var r=i[s];if("string"!=typeof r)throw Rt("itkn","Incorrect injection token! Expected service name as string, got {0}",r);n.push(t&&t.hasOwnProperty(r)?t[r]:l(r,a))}return n}return{invoke:function(e,t,a,n){return"string"==typeof a&&(n=a,a=null),a=i(e,a,n),be(e)&&(e=e[e.length-1]),n=e,U<=11||("function"!=typeof n||!/^(?:class\s|constructor\()/.test(qt(n)))?e.apply(t,a):(a.unshift(null),new(Function.prototype.bind.apply(e,a)))},instantiate:function(e,t,a){var n=be(e)?e[e.length-1]:e;return(a=i(e,t,a)).unshift(null),new(Function.prototype.bind.apply(n,a))},get:l,annotate:Yt.$$annotate,has:function(e){return u.hasOwnProperty(e+o)||a.hasOwnProperty(e)}}}}function Ft(){var e=!0;this.disableAutoScrolling=function(){e=!1},this.$get=["$window","$location","$rootScope",function(n,i,s){var o=n.document;function r(e){var t,a;e?(e.scrollIntoView(),(a=(we(a=l.yOffset)?a=a():E(a)?(t=a[0],a="fixed"!==n.getComputedStyle(t).position?0:t.getBoundingClientRect().bottom):_(a)||(a=0),a))&&(e=e.getBoundingClientRect().top,n.scrollBy(0,e-a))):n.scrollTo(0,0)}function l(e){var t,a,n;(e=R(e)?e:i.hash())?(t=o.getElementById(e))?r(t):(a=o.getElementsByName(e),n=null,Array.prototype.some.call(a,function(e){if("a"===xe(e))return n=e,!0}),(t=n)?r(t):"top"===e&&r(null)):r(null)}return e&&s.$watch(function(){return i.hash()},function(e,t){var a;e===t&&""===e||(e=function(){s.$evalAsync(l)},"complete"===(a=a||h).document.readyState?a.setTimeout(e):me(a).on("load",e))}),l}]}Yt.$$annotate=function(e,t,a){var n;if("function"==typeof e){if(!(n=e.$inject)){if(n=[],e.length){if(t)throw R(a)&&a||(a=e.name||((t=Vt(t=e))?"function("+(t[1]||"").replace(/[\s\r\n]+/," ")+")":"fn")),Rt("strictdi","{0} is not using explicit annotation and cannot be invoked in strict mode",a);ge(Vt(e)[1].split(Ut),function(e){e.replace(Nt,function(e,t,a){n.push(a)})})}e.$inject=n}}else be(e)?(pe(e[a=e.length-1],"fn"),n=e.slice(0,a)):pe(e,"fn",!0);return n};var zt=w("$animate"),Ht=1,Wt="ng-animate";function Gt(e,t){return e||t?e?t?(e=be(e)?e.join(" "):e)+" "+(t=be(t)?t.join(" "):t):e:t:""}function Kt(e){return ye(e)?e:{}}function Qt(){this.$get=N}function Jt(){var c=new Et,u=[];this.$get=["$$AnimateRunner","$rootScope",function(s,o){return{enabled:N,on:N,off:N,pin:N,push:function(e,t,a,n){n&&n(),(a=a||{}).from&&e.css(a.from),a.to&&e.css(a.to),(a.addClass||a.removeClass)&&(i=e,n=a.addClass,e=a.removeClass,a=c.get(i)||{},n=r(a,n,!0),e=r(a,e,!1),(n||e)&&(c.put(i,a),u.push(i),1===u.length&&o.$$postDigest(l)));var i=new s;return i.complete(),i}};function r(t,e,a){var n=!1;return e&&ge(e=R(e)?e.split(" "):be(e)?e:[],function(e){e&&(n=!0,t[e]=a)}),n}function l(){ge(u,function(e){var a,n,i,t=c.get(e);t&&(a=function(e){R(e)&&(e=e.split(" "));var t=Ee();return ge(e,function(e){e.length&&(t[e]=!0)}),t}(e.attr("class")),i=n="",ge(t,function(e,t){e!==!!a[t]&&(e?n+=(n.length?" ":"")+t:i+=(i.length?" ":"")+t)}),ge(e,function(e){n&&ht(e,n),i&&ft(e,i)}),c.remove(e))}),u.length=0}}]}function Zt(){this.$get=["$$rAF",function(t){var a=[];function n(e){a.push(e),1<a.length||t(function(){for(var e=0;e<a.length;e++)a[e]();a=[]})}return function(){var t=!1;return n(function(){t=!0}),function(e){t?e():n(e)}}}]}function Xt(){this.$get=["$q","$sniffer","$$animateAsyncRun","$document","$timeout",function(t,e,n,i,s){function a(e){this.setHost(e);var a=n();this._doneCallbacks=[],this._tick=function(e){var t=i[0];t&&t.hidden?s(e,0,!1):a(e)},this._state=0}return a.chain=function(e,a){var n=0;!function t(){if(n===e.length)return void a(!0);e[n](function(e){!1!==e?(n++,t()):a(!1)})}()},a.all=function(t,a){var n=0,i=!0;function s(e){i=i&&e,++n===t.length&&a(i)}ge(t,function(e){e.done(s)})},a.prototype={setHost:function(e){this.host=e||{}},done:function(e){2===this._state?e():this._doneCallbacks.push(e)},progress:N,getPromise:function(){var e;return this.promise||((e=this).promise=t(function(t,a){e.done(function(e){(!1===e?a:t)()})})),this.promise},then:function(e,t){return this.getPromise().then(e,t)},catch:function(e){return this.getPromise().catch(e)},finally:function(e){return this.getPromise().finally(e)},pause:function(){this.host.pause&&this.host.pause()},resume:function(){this.host.resume&&this.host.resume()},end:function(){this.host.end&&this.host.end(),this._resolve(!0)},cancel:function(){this.host.cancel&&this.host.cancel(),this._resolve(!1)},complete:function(e){var t=this;0===t._state&&(t._state=1,t._tick(function(){t._resolve(e)}))},_resolve:function(t){2!==this._state&&(ge(this._doneCallbacks,function(e){e(t)}),this._doneCallbacks.length=0,this._state=2)}},a}]}function ea(){this.$get=["$$rAF","$q","$$AnimateRunner",function(o,e,r){return function(e,t){var a=t||{};(a=!a.$$prepared?Y(a):a).cleanupStyles&&(a.from=a.to=null),a.from&&(e.css(a.from),a.from=null);var n,i=new r;return{start:s,end:s};function s(){return o(function(){!function(){a.addClass&&(e.addClass(a.addClass),a.addClass=null);a.removeClass&&(e.removeClass(a.removeClass),a.removeClass=null);a.to&&(e.css(a.to),a.to=null)}(),n||i.complete(),n=!0}),i}}}]}var ta=["$provide",function(n){var i=this;this.$$registeredAnimations=Object.create(null),this.register=function(e,t){if(e&&"."!==e.charAt(0))throw zt("notcsel","Expecting class selector starting with '.' got '{0}'.",e);var a=e+"-animation";i.$$registeredAnimations[e.substr(1)]=a,n.factory(a,t)},this.classNameFilter=function(e){if(1===arguments.length&&(this.$$classNameFilter=e instanceof RegExp?e:null,this.$$classNameFilter&&new RegExp("(\\s+|\\/)"+Wt+"(\\s+|\\/)").test(this.$$classNameFilter.toString())))throw zt("nongcls",'$animateProvider.classNameFilter(regex) prohibits accepting a regex value which matches/contains the "{0}" CSS class.',Wt);return this.$$classNameFilter},this.$get=["$$animateQueue",function(s){function i(e,t,a){var n;a&&(!(n=function(e){for(var t=0;t<e.length;t++){var a=e[t];if(a.nodeType===Ht)return a}}(a))||n.parentNode||n.previousElementSibling||(a=null)),a?a.after(e):t.prepend(e)}return{on:s.on,off:s.off,pin:s.pin,enabled:s.enabled,cancel:function(e){e.end&&e.end()},enter:function(e,t,a,n){return t=t&&me(t),a=a&&me(a),i(e,t=t||a.parent(),a),s.push(e,"enter",Kt(n))},move:function(e,t,a,n){return t=t&&me(t),a=a&&me(a),i(e,t=t||a.parent(),a),s.push(e,"move",Kt(n))},leave:function(e,t){return s.push(e,"leave",Kt(t),function(){e.remove()})},addClass:function(e,t,a){return(a=Kt(a)).addClass=Gt(a.addclass,t),s.push(e,"addClass",a)},removeClass:function(e,t,a){return(a=Kt(a)).removeClass=Gt(a.removeClass,t),s.push(e,"removeClass",a)},setClass:function(e,t,a,n){return(n=Kt(n)).addClass=Gt(n.addClass,t),n.removeClass=Gt(n.removeClass,a),s.push(e,"setClass",n)},animate:function(e,t,a,n,i){return(i=Kt(i)).from=i.from?fe(i.from,t):t,i.to=i.to?fe(i.to,a):a,i.tempClasses=Gt(i.tempClasses,n=n||"ng-inline-animate"),s.push(e,"animate",i)}}}]}];function aa(s,e,t,o){var r=this,l=s.location,c=s.history,n=s.setTimeout,a=s.clearTimeout,i={};r.isMock=!1;var u=0,d=[];function p(e){try{e.apply(null,Se(arguments,1))}finally{if(0===--u)for(;d.length;)try{d.pop()()}catch(e){t.error(e)}}}r.$$completeOutstandingRequest=p,r.$$incOutstandingRequestCount=function(){u++},r.notifyWhenNoOutstandingRequests=function(e){0===u?e():d.push(e)};var m,g,f=l.href,h=e.find("base"),v=null,y=o.history?function(){try{return c.state}catch(e){}}:N;x(),g=m,r.url=function(e,t,a){if(ve(a)&&(a=null),l!==s.location&&(l=s.location),c!==s.history&&(c=s.history),e){var n=g===a;if(f===e&&(!o.history||n))return r;var i=f&&Qa(f)===Qa(e);return f=e,g=a,!o.history||i&&n?(i||(v=e),t?l.replace(e):i?l.hash=-1===(i=(n=e).indexOf("#"))?"":n.substr(i):l.href=e,l.href!==e&&(v=e)):(c[t?"replaceState":"pushState"](a,"",e),x(),g=m),v=v&&e,r}return v||l.href.replace(/%27/g,"'")},r.state=function(){return m};var b=[],w=!1;function $(){v=null,x(),_()}var k=null;function x(){_e(m=ve(m=y())?null:m,k)&&(m=k),k=m}function _(){f===r.url()&&g===m||(f=r.url(),g=m,ge(b,function(e){e(r.url(),m)}))}r.onUrlChange=function(e){return w||(o.history&&me(s).on("popstate",$),me(s).on("hashchange",$),w=!0),b.push(e),e},r.$$applicationDestroyed=function(){me(s).off("hashchange popstate",$)},r.$$checkUrlChange=_,r.baseHref=function(){var e=h.attr("href");return e?e.replace(/^(https?\:)?\/\/[^\/]*/,""):""},r.defer=function(e,t){var a;return u++,a=n(function(){delete i[a],p(e)},t||0),i[a]=!0,a},r.defer.cancel=function(e){return!!i[e]&&(delete i[e],a(e),p(N),!0)}}function na(){this.$get=["$window","$log","$sniffer","$document",function(e,t,a,n){return new aa(e,n,t,a)}]}function ia(){this.$get=function(){var d={};function e(e,t){if(e in d)throw w("$cacheFactory")("iid","CacheId '{0}' is already taken!",e);var a=0,n=fe({},t,{id:e}),i=Ee(),s=t&&t.capacity||Number.MAX_VALUE,o=Ee(),r=null,l=null;return d[e]={put:function(e,t){if(!ve(t))return s<Number.MAX_VALUE&&c(o[e]||(o[e]={key:e})),e in i||a++,i[e]=t,s<a&&this.remove(l.key),t},get:function(e){if(s<Number.MAX_VALUE){var t=o[e];if(!t)return;c(t)}return i[e]},remove:function(e){if(s<Number.MAX_VALUE){var t=o[e];if(!t)return;t==r&&(r=t.p),t==l&&(l=t.n),u(t.n,t.p),delete o[e]}e in i&&(delete i[e],a--)},removeAll:function(){i=Ee(),a=0,o=Ee(),r=l=null},destroy:function(){o=n=i=null,delete d[e]},info:function(){return fe({},n,{size:a})}};function c(e){e!=r&&(l?l==e&&(l=e.n):l=e,u(e.n,e.p),u(e,r),(r=e).n=null)}function u(e,t){e!=t&&(e&&(e.p=t),t&&(t.n=e))}}return e.info=function(){var a={};return ge(d,function(e,t){a[t]=e.info()}),a},e.get=function(e){return d[e]},e}}function sa(){this.$get=["$cacheFactory",function(e){return e("templates")}]}var oa=w("$compile");var ra=new function(){};function la(a,t){var M={},D="Directive",T=/^\s*directive\:\s*([\w\-]+)\s+(.*)$/,P=/(([\w\-]+)(?:\:([^;]+))?;?)/,E=function(e){for(var t={},a=e.split(","),n=0;n<a.length;n++)t[a[n]]=!0;return t}("ngSrc,ngSrcset,src,srcset"),d=/^(?:(\^\^?)?(\?)?(\^\^?)?)?/,j=/^(on[a-z]+|formaction)$/,r=Ee();function f(e,n,i){var s=/^\s*([@&<]|=(\*?))(\??)\s*(\w*)\s*$/,o=Ee();return ge(e,function(e,t){if(e in r)o[t]=r[e];else{var a=e.match(s);if(!a)throw oa("iscp","Invalid {3} for directive '{0}'. Definition: {... {1}: '{2}' ...}",n,t,e,i?"controller bindings definition":"isolate scope definition");o[t]={mode:a[1][0],collection:"*"===a[2],optional:"?"===a[3],attrName:a[4]||t},a[4]&&(r[e]=o[t])}}),o}this.directive=function e(l,t){return De(l,"directive"),R(l)?(function(e){var t=e.charAt(0);if(!t||t!==O(t))throw oa("baddir","Directive/Component name '{0}' is invalid. The first character must be a lowercase letter",e);if(e!==e.trim())throw oa("baddir","Directive/Component name '{0}' is invalid. The name should not contain leading or trailing whitespaces",e)}(l),Me(t,"directiveFactory"),M.hasOwnProperty(l)||(M[l]=[],a.factory(l+D,["$injector","$exceptionHandler",function(s,o){var r=[];return ge(M[l],function(e,t){try{var a=s.invoke(e);we(a)?a={compile:I(a)}:!a.compile&&a.link&&(a.compile=I(a.link)),a.priority=a.priority||0,a.index=t,a.name=a.name||l,a.require=(i=(n=a).require||n.controller&&n.name,!be(i)&&ye(i)&&ge(i,function(e,t){var a=e.match(d);e.substring(a[0].length)||(i[t]=a[0]+t)}),i),a.restrict=a.restrict||"EA",a.$$moduleName=e.$$moduleName,r.push(a)}catch(e){o(e)}var n,i}),r}])),M[l].push(t)):ge(l,v(e)),this},this.component=function(e,i){var s=i.controller||function(){};function a(n){function e(a){return we(a)||be(a)?function(e,t){return n.invoke(a,this,{$element:e,$attrs:t})}:a}var t=i.template||i.templateUrl?i.template:"",a={controller:s,controllerAs:ha(i.controller)||i.controllerAs||"$ctrl",template:e(t),templateUrl:e(i.templateUrl),transclude:i.transclude,scope:{},bindToController:i.bindings||{},restrict:"E",require:i.require};return ge(i,function(e,t){"$"===t.charAt(0)&&(a[t]=e)}),a}return ge(i,function(e,t){"$"===t.charAt(0)&&(a[t]=e,we(s)&&(s[t]=e))}),a.$inject=["$injector"],this.directive(e,a)},this.aHrefSanitizationWhitelist=function(e){return B(e)?(t.aHrefSanitizationWhitelist(e),this):t.aHrefSanitizationWhitelist()},this.imgSrcSanitizationWhitelist=function(e){return B(e)?(t.imgSrcSanitizationWhitelist(e),this):t.imgSrcSanitizationWhitelist()};var i=!0;this.debugInfoEnabled=function(e){return B(e)?(i=e,this):i};var l=10;this.onChangesTtl=function(e){return arguments.length?(l=e,this):l},this.$get=["$injector","$interpolate","$exceptionHandler","$templateRequest","$parse","$controller","$rootScope","$sce","$animate","$$sanitizeUri",function(k,x,F,z,v,H,s,_,n,p){var o,m=/^\w/,g=h.document.createElement("div"),e=l;function r(){try{if(!--e)throw o=void 0,oa("infchng","{0} $onChanges() iterations reached. Aborting!\n",l);s.$apply(function(){for(var e=0,t=o.length;e<t;++e)o[e]();o=void 0})}finally{e++}}function W(e,t){if(t)for(var a,n=Object.keys(t),i=0,s=n.length;i<s;i++)this[a=n[i]]=t[a];else this.$attr={};this.$$element=e}function G(e,t){try{e.addClass(t)}catch(e){}}W.prototype={$normalize:da,$addClass:function(e){e&&0<e.length&&n.addClass(this.$$element,e)},$removeClass:function(e){e&&0<e.length&&n.removeClass(this.$$element,e)},$updateClass:function(e,t){var a=pa(e,t);a&&a.length&&n.addClass(this.$$element,a);e=pa(t,e);e&&e.length&&n.removeClass(this.$$element,e)},$set:function(e,t,a,n){var i=It(this.$$element[0],e),s=St[e],o=e;if(i?(this.$$element.prop(e,t),n=i):s&&(this[s]=t,o=s),this[e]=t,n?this.$attr[e]=n:(n=this.$attr[e])||(this.$attr[e]=n=Ae(e,"-")),"a"===(i=xe(this.$$element))&&("href"===e||"xlinkHref"===e)||"img"===i&&"src"===e)this[e]=t=p(t,"src"===e);else if("img"===i&&"srcset"===e&&B(t)){for(var r="",s=ke(t),i=/\s/.test(s)?/(\s+\d+x\s*,|\s+\d+w\s*,|\s+,|,\s+)/:/(,)/,l=s.split(i),c=Math.floor(l.length/2),u=0;u<c;u++){var d=2*u;r+=p(ke(l[d]),!0),r+=" "+ke(l[1+d])}i=ke(l[2*u]).split(/\s/);r+=p(ke(i[0]),!0),2===i.length&&(r+=" "+ke(i[1])),this[e]=t=r}!1!==a&&(null===t||ve(t)?this.$$element.removeAttr(n):m.test(n)?this.$$element.attr(n,t):function(e,t,a){g.innerHTML="<span "+t+">";var n=g.firstChild.attributes,t=n[0];n.removeNamedItem(t.name),t.value=a,e.attributes.setNamedItem(t)}(this.$$element[0],n,t));n=this.$$observers;n&&ge(n[o],function(e){try{e(t)}catch(e){F(e)}})},$observe:function(e,t){var a=this,n=a.$$observers||(a.$$observers=Ee()),i=n[e]||(n[e]=[]);return i.push(t),s.$evalAsync(function(){i.$$inter||!a.hasOwnProperty(e)||ve(a[e])||t(a[e])}),function(){V(i,t)}}};var t=x.startSymbol(),a=x.endSymbol(),K="{{"==t&&"}}"==a?b:function(e){return e.replace(/\{\{/g,t).replace(/}}/g,a)},S=/^ngAttr[A-Z]/,I=/^(.+)Start$/;return Q.$$addBindingInfo=i?function(e,t){var a=e.data("$binding")||[];be(t)?a=a.concat(t):a.push(t),e.data("$binding",a)}:N,Q.$$addBindingClass=i?function(e){G(e,"ng-binding")}:N,Q.$$addScopeInfo=i?function(e,t,a,n){e.data(a?n?"$isolateScopeNoTemplate":"$isolateScope":"$scope",t)}:N,Q.$$addScopeClass=i?function(e,t){G(e,t?"ng-isolate-scope":"ng-scope")}:N,Q.$$createComment=function(e,t){var a="";return i&&(a=" "+(e||"")+": ",t&&(a+=t+" ")),h.document.createComment(a)},Q;function Q(r,e,t,a,l){for(var n=/\S+/,i=0,s=(r=!(r instanceof me)?me(r):r).length;i<s;i++){var o=r[i];o.nodeType===Le&&o.nodeValue.match(n)&&st(o,r[i]=h.document.createElement("span"))}var c=J(r,e,r,t,a,l);Q.$$addScopeClass(r);var u=null;return function(e,t,a){Me(e,"scope"),l&&l.needsNewScope&&(e=e.$parent.$new());var n,i=(a=a||{}).parentBoundTranscludeFn,s=a.transcludeControllers,a=a.futureParentElement;if(i&&i.$$boundTransclude&&(i=i.$$boundTransclude),n="html"!==(u=u||function(e){e=e&&e[0];return e&&"foreignobject"!==xe(e)&&$.call(e).match(/SVG/)?"svg":"html"}(a))?me(le(u,me("<div>").append(r).html())):t?kt.clone.call(r):r,s)for(var o in s)n.data("$"+o+"Controller",s[o].instance);return Q.$$addScopeInfo(n,e),t&&t(n,e),c&&c(e,n,n,i),n}}function J(e,g,t,a,n,i){for(var s,o,r,l,f,h=[],c=0;c<e.length;c++)r=new W,(s=(s=X(e[c],[],r,0===c?a:void 0,n)).length?ne(s,e[c],r,g,t,null,[],[],i):null)&&s.scope&&Q.$$addScopeClass(r.$$element),r=s&&s.terminal||!(o=e[c].childNodes)||!o.length?null:J(o,s?(s.transcludeOnThisElement||!s.templateOnThisElement)&&s.transclude:g),(s||r)&&(h.push(c,s,r),l=!0,f=f||s),i=null;return l?function(e,t,a,n){var i,s,o,r,l,c,u,d,p;if(f){var m=t.length;for(p=new Array(m),l=0;l<h.length;l+=3)u=h[l],p[u]=t[u]}else p=t;for(l=0,c=h.length;l<c;)o=p[h[l++]],i=h[l++],s=h[l++],i?(i.scope?(r=e.$new(),Q.$$addScopeInfo(me(o),r)):r=e,d=i.transcludeOnThisElement?Z(e,i.transclude,n):!i.templateOnThisElement&&n?n:!n&&g?Z(e,g):null,i(s,r,o,a,d)):s&&s(e,o.childNodes,void 0,n)}:null}function Z(s,o,r){function e(e,t,a,n,i){return e||((e=s.$new(!1,i)).$$transcluded=!0),o(e,t,{parentBoundTranscludeFn:r,transcludeControllers:a,futureParentElement:n})}var t,a=e.$$slots=Ee();for(t in o.$$slots)o.$$slots[t]?a[t]=Z(s,o.$$slots[t],r):a[t]=null;return e}function X(e,t,a,n,i){var s,o,r,l,c,u=e.nodeType,d=a.$attr;switch(u){case je:C(t,da(xe(e)),"E",n,i);for(var p,m=e.attributes,g=0,f=m&&m.length;g<f;g++){var h,v=!1,y=!1,b=(h=m[g]).name,w=ke(h.value),$=da(b);(h=S.test($))&&(b=b.replace(ua,"").substr(8).replace(/_(.)/g,function(e,t){return t.toUpperCase()}));$=$.match(I);$&&function(e){if(M.hasOwnProperty(e))for(var t=k.get(e+D),a=0,n=t.length;a<n;a++)if(t[a].multiElement)return!0;return!1}($[1])&&(y=(v=b).substr(0,b.length-5)+"end",b=b.substr(0,b.length-6)),d[p=da(b.toLowerCase())]=b,!h&&a.hasOwnProperty(p)||(a[p]=w,It(e,p)&&(a[p]=!0)),function(e,t,s,o,r){var l=function(e,t){if("srcdoc"==t)return _.HTML;e=xe(e);if("xlinkHref"==t||"form"==e&&"action"==t||"img"!=e&&("src"==t||"ngSrc"==t))return _.RESOURCE_URL}(e,o);r=E[o]||r;var c=x(s,!0,l,r);if(c){if("multiple"===o&&"select"===xe(e))throw oa("selmulti","Binding to the 'multiple' attribute is not supported. Element: {0}",Ce(e));t.push({priority:100,compile:function(){return{pre:function(e,t,a){var n=a.$$observers||(a.$$observers=Ee());if(j.test(o))throw oa("nodomevents","Interpolations for HTML DOM event attributes are disallowed. Please use the ng- versions (such as ng-click instead of onclick) instead.");var i=a[o];i!==s&&(c=i&&x(i,!0,l,r),s=i),c&&(a[o]=c(e),(n[o]||(n[o]=[])).$$inter=!0,(a.$$observers&&a.$$observers[o].$$scope||e).$watch(c,function(e,t){"class"===o&&e!=t?a.$updateClass(e,t):a.$set(o,e)}))}}}})}}(e,t,w,p,h),C(t,p,"A",n,i,v,y)}if(R(o=ye(o=e.className)?o.animVal:o)&&""!==o)for(;s=P.exec(o);)C(t,p=da(s[2]),"C",n,i)&&(a[p]=ke(s[3])),o=o.substr(s.index+s[0].length);break;case Le:if(11===U)for(;e.parentNode&&e.nextSibling&&e.nextSibling.nodeType===Le;)e.nodeValue=e.nodeValue+e.nextSibling.nodeValue,e.parentNode.removeChild(e.nextSibling);r=t,l=e.nodeValue,(c=x(l,!0))&&r.push({priority:0,compile:function(e){var e=e.parent(),n=!!e.length;return n&&Q.$$addBindingClass(e),function(e,t){var a=t.parent();n||Q.$$addBindingClass(a),Q.$$addBindingInfo(a,c.expressions),e.$watch(c,function(e){t[0].nodeValue=e})}}});break;case Oe:try{(s=T.exec(e.nodeValue))&&C(t,p=da(s[1]),"M",n,i)&&(a[p]=ke(s[2]))}catch(e){}}return t.sort(A),t}function ee(e,t,a){var n=[],i=0;if(t&&e.hasAttribute&&e.hasAttribute(t)){do{if(!e)throw oa("uterdir","Unterminated attribute, found '{0}' but no matching '{1}' found.",t,a)}while(e.nodeType==je&&(e.hasAttribute(t)&&i++,e.hasAttribute(a)&&i--),n.push(e),e=e.nextSibling,0<i)}else n.push(e);return me(n)}function te(s,o,r){return function(e,t,a,n,i){return t=ee(t[0],o,r),s(e,t,a,n,i)}}function ae(e,t,a,n,i,s){var o;return e?Q(t,a,n,i,s):function(){return o||(o=Q(t,a,n,i,s),t=a=s=null),o.apply(this,arguments)}}function ne(e,$,k,t,a,n,x,_,i){i=i||{};for(var s,o,r=-Number.MAX_VALUE,S=i.newScopeDirective,I=i.controllerDirectives,C=i.newIsolateScopeDirective,A=i.templateDirective,l=i.nonTlbTranscludeDirective,c=!1,u=!1,M=i.hasElementTranscludeDirective,d=k.$$element=me($),p=n,m=t,g=!1,f=!1,h=0,v=e.length;h<v;h++){var y,b=(y=e[h]).$$start,w=y.$$end;if(b&&(d=ee($,b,w)),j=void 0,r>y.priority)break;if((o=y.scope)&&(y.templateUrl||(ye(o)?(re("new/isolated scope",C||S,y,d),C=y):re("new/isolated scope",C,y,d)),S=S||y),s=y.name,!g&&(y.replace&&(y.templateUrl||y.template)||y.transclude&&!y.$$tlb)){for(var D,T=h+1;D=e[T++];)if(D.transclude&&!D.$$tlb||D.replace&&(D.templateUrl||D.template)){f=!0;break}g=!0}if(!y.templateUrl&&y.controller&&(o=y.controller,I=I||Ee(),re("'"+s+"' controller",I[s],y,d),I[s]=y),o=y.transclude)if(c=!0,y.$$tlb||(re("transclusion",l,y,d),l=y),"element"==o)M=!0,r=y.priority,j=d,d=k.$$element=me(Q.$$createComment(s,k[s])),$=d[0],ce(a,Se(j),$),j[0].$$parentNode=j[0].parentNode,m=ae(f,j,t,r,p&&p.name,{nonTlbTranscludeDirective:l});else{var P=Ee();if(j=me(lt($)).contents(),ye(o)){var E,j=[],L=Ee(),O=Ee();for(E in ge(o,function(e,t){var a="?"===e.charAt(0);e=a?e.substring(1):e,L[e]=t,P[t]=null,O[t]=a}),ge(d.contents(),function(e){var t=L[da(xe(e))];t?(O[t]=!0,P[t]=P[t]||[],P[t].push(e)):j.push(e)}),ge(O,function(e,t){if(!e)throw oa("reqslot","Required transclusion slot `{0}` was not filled.",t)}),P)P[E]&&(P[E]=ae(f,P[E],t))}d.empty(),(m=ae(f,j,t,void 0,void 0,{needsNewScope:y.$$isolateScope||y.$$newScope})).$$slots=P}if(y.template)if(u=!0,re("template",A,y,d),o=we((A=y).template)?y.template(d,k):y.template,o=K(o),y.replace){if(p=y,j=at(o)?[]:ma(le(y.templateNamespace,ke(o))),$=j[0],1!=j.length||$.nodeType!==je)throw oa("tplrt","Template for directive '{0}' must have exactly one root element. {1}",s,"");ce(a,d,$);var U={$attr:{}},N=X($,[],U),B=e.splice(h+1,e.length-(h+1));(C||S)&&se(N,C,S),e=e.concat(N).concat(B),oe(k,U),v=e.length}else d.html(o);if(y.templateUrl)u=!0,re("template",A,y,d),(A=y).replace&&(p=y),Y=function(u,d,p,m,g,f,h,v){var y,b,w=[],$=d[0],k=u.shift(),x=he(k,{templateUrl:null,transclude:null,replace:null,$$originalDirective:k}),_=we(k.templateUrl)?k.templateUrl(d,p):k.templateUrl,S=k.templateNamespace;return d.empty(),z(_).then(function(e){var a,t;if(e=K(e),k.replace){if(n=at(e)?[]:ma(le(S,ke(e))),a=n[0],1!=n.length||a.nodeType!==je)throw oa("tplrt","Template for directive '{0}' must have exactly one root element. {1}",k.name,_);t={$attr:{}},ce(m,d,a);var n=X(a,[],t);ye(k.scope)&&se(n,!0),u=n.concat(u),oe(p,t)}else a=$,d.html(e);for(u.unshift(x),y=ne(u,a,p,g,d,k,f,h,v),ge(m,function(e,t){e==a&&(m[t]=d[0])}),b=J(d[0].childNodes,g);w.length;){var i,s=w.shift(),o=w.shift(),r=w.shift(),l=w.shift(),c=d[0];s.$$destroyed||(o!==$&&(i=o.className,v.hasElementTranscludeDirective&&k.replace||(c=lt(a)),ce(r,me(o),c),G(me(c),i)),l=y.transcludeOnThisElement?Z(s,y.transclude,l):l,y(b,s,c,m,l))}w=null}),function(e,t,a,n,i){var s=i;t.$$destroyed||(w?w.push(t,a,n,s):(y.transcludeOnThisElement&&(s=Z(t,y.transclude,i)),y(b,t,a,n,s)))}}(e.splice(h,e.length-h),d,k,a,c&&m,x,_,{controllerDirectives:I,newScopeDirective:S!==y&&S,newIsolateScopeDirective:C,templateDirective:A,nonTlbTranscludeDirective:l}),v=e.length;else if(y.compile)try{var R=y.compile(d,k,m),q=y.$$originalDirective||y;we(R)?V(null,Ie(q,R),b,w):R&&V(Ie(q,R.pre),Ie(q,R.post),b,w)}catch(e){F(e,Ce(d))}y.terminal&&(Y.terminal=!0,r=Math.max(r,y.priority))}return Y.scope=S&&!0===S.scope,Y.transcludeOnThisElement=c,Y.templateOnThisElement=u,Y.transclude=m,i.hasElementTranscludeDirective=M,Y;function V(e,t,a,n){e&&((e=a?te(e,a,n):e).require=y.require,e.directiveName=s,C!==y&&!y.$$isolateScope||(e=ue(e,{isolateScope:!0})),x.push(e)),t&&((t=a?te(t,a,n):t).require=y.require,t.directiveName=s,C!==y&&!y.$$isolateScope||(t=ue(t,{isolateScope:!0})),_.push(t))}function Y(e,t,a,n,o){var i,s,r,l,c,u,d,p,m,g,f;for(f in $===a?p=(m=k).$$element:m=new W(p=me(a),k),c=t,C?l=t.$new(!0):S&&(c=t.$parent),o&&((d=function(e,t,a,n){var i;$e(e)||(n=a,a=t,t=e,e=void 0);M&&(i=u);a=a||(M?p.parent():p);{if(!n)return o(e,t,i,a,w);var s=o.$$slots[n];if(s)return s(e,t,i,a,w);if(ve(s))throw oa("noslot",'No parent directive that requires a transclusion with slot name "{0}". Element: {1}',n,Ce(p))}}).$$boundTransclude=o,d.isSlotFilled=function(e){return!!o.$$slots[e]}),I&&(u=function(e,t,a,n,i,s,o){var r,l=Ee();for(r in n){var c=n[r],u={$scope:c===o||c.$$isolateScope?i:s,$element:e,$attrs:t,$transclude:a},d=c.controller;"@"==d&&(d=t[c.name]);u=H(d,u,!0,c.controllerAs);l[c.name]=u,e.data("$"+c.name+"Controller",u.instance)}return l}(p,m,d,I,l,t,C)),C&&(Q.$$addScopeInfo(p,l,!0,!(A&&(A===C||A===C.$$originalDirective))),Q.$$addScopeClass(p,!0),l.$$isolateBindings=C.$$isolateBindings,(g=pe(t,m,l,l.$$isolateBindings,C)).removeWatches&&l.$on("$destroy",g.removeWatches)),u){var h=I[f],v=u[f],y=h.$$bindings.bindToController;v.identifier&&y?v.bindingInfo=pe(c,m,v.instance,y,h):v.bindingInfo={};var b=v();b!==v.instance&&(v.instance=b,p.data("$"+h.name+"Controller",b),v.bindingInfo.removeWatches&&v.bindingInfo.removeWatches(),v.bindingInfo=pe(c,m,v.instance,y,h))}for(ge(I,function(e,t){var a=e.require;e.bindToController&&!be(a)&&ye(a)&&fe(u[t].instance,ie(t,a,p,u))}),ge(u,function(e){var t=e.instance;we(t.$onChanges)&&t.$onChanges(e.bindingInfo.initialChanges),we(t.$onInit)&&t.$onInit(),we(t.$onDestroy)&&c.$on("$destroy",function(){t.$onDestroy()})}),i=0,s=x.length;i<s;i++)de(r=x[i],r.isolateScope?l:t,p,m,r.require&&ie(r.directiveName,r.require,p,u),d);var w=t;for(C&&(C.template||null===C.templateUrl)&&(w=l),e&&e(w,a.childNodes,void 0,o),i=_.length-1;0<=i;i--)de(r=_[i],r.isolateScope?l:t,p,m,r.require&&ie(r.directiveName,r.require,p,u),d);ge(u,function(e){e=e.instance;we(e.$postLink)&&e.$postLink()})}}function ie(a,e,n,i){if(R(e)){var s,t=e.match(d),o=e.substring(t[0].length),r=t[1]||t[3],l="?"===t[2];if("^^"===r?n=n.parent():s=(s=i&&i[o])&&s.instance,s||(t="$"+o+"Controller",s=r?n.inheritedData(t):n.data(t)),!s&&!l)throw oa("ctreq","Controller '{0}', required by directive '{1}', can't be found!",o,a)}else if(be(e)){s=[];for(var c=0,u=e.length;c<u;c++)s[c]=ie(a,e[c],n,i)}else ye(e)&&(s={},ge(e,function(e,t){s[t]=ie(a,e,n,i)}));return s||null}function se(e,t,a){for(var n=0,i=e.length;n<i;n++)e[n]=he(e[n],{$$isolateScope:t,$$newScope:a})}function C(e,t,a,n,i,s,o){if(t!==i){var r=null;if(M.hasOwnProperty(t))for(var l=k.get(t+D),c=0,u=l.length;c<u;c++)try{var d,p=l[c];(ve(n)||n>p.priority)&&-1!=p.restrict.indexOf(a)&&((p=s?he(p,{$$start:s,$$end:o}):p).$$bindings||(d=p.$$bindings=function(e,t){var a={isolateScope:null,bindToController:null};if(ye(e.scope)&&(!0===e.bindToController?(a.bindToController=f(e.scope,t,!0),a.isolateScope={}):a.isolateScope=f(e.scope,t,!1)),ye(e.bindToController)&&(a.bindToController=f(e.bindToController,t,!0)),ye(a.bindToController)){var n=e.controller,e=e.controllerAs;if(!n)throw oa("noctrl","Cannot bind to controller without directive '{0}'s controller.",t);if(!ha(n,e))throw oa("noident","Cannot bind to controller without identifier for directive '{0}'.",t)}return a}(p,p.name),ye(d.isolateScope)&&(p.$$isolateBindings=d.isolateScope)),e.push(p),r=p)}catch(e){F(e)}return r}}function oe(a,n){var i=n.$attr,s=a.$attr,o=a.$$element;ge(a,function(e,t){"$"!=t.charAt(0)&&(n[t]&&n[t]!==e&&(e+=("style"===t?";":" ")+n[t]),a.$set(t,e,!0,i[t]))}),ge(n,function(e,t){"class"==t?(G(o,e),a.class=(a.class?a.class+" ":"")+e):"style"==t?(o.attr("style",o.attr("style")+";"+e),a.style=(a.style?a.style+";":"")+e):"$"==t.charAt(0)||a.hasOwnProperty(t)||(a[t]=e,s[t]=i[t])})}function A(e,t){var a=t.priority-e.priority;return 0!=a?a:e.name!==t.name?e.name<t.name?-1:1:e.index-t.index}function re(e,t,a,n){function i(e){return e?" (module: "+e+")":""}if(t)throw oa("multidir","Multiple directives [{0}{1}, {2}{3}] asking for {4} on: {5}",t.name,i(t.$$moduleName),a.name,i(a.$$moduleName),e,Ce(n))}function le(e,t){switch(e=O(e||"html")){case"svg":case"math":var a=h.document.createElement("div");return a.innerHTML="<"+e+">"+t+"</"+e+">",a.childNodes[0].childNodes;default:return t}}function ce(e,t,a){var n,i=t[0],s=t.length,o=i.parentNode;if(e)for(d=0,n=e.length;d<n;d++)if(e[d]==i){e[d++]=a;for(var r=d,l=r+s-1,c=e.length;r<c;r++,l++)l<c?e[r]=e[l]:delete e[r];e.length-=s-1,e.context===i&&(e.context=a);break}o&&o.replaceChild(a,i);for(var u=h.document.createDocumentFragment(),d=0;d<s;d++)u.appendChild(t[d]);for(me.hasData(i)&&(me.data(a,me.data(i)),me(i).off("$destroy")),me.cleanData(u.querySelectorAll("*")),d=1;d<s;d++)delete t[d];t[0]=a,t.length=1}function ue(e,t){return fe(function(){return e.apply(null,arguments)},e,t)}function de(e,t,a,n,i,s){try{e(t,a,n,i,s)}catch(e){F(e,Ce(a))}}function pe(u,d,p,e,m){var n,g=[],f={};function h(e,t,a){we(p.$onChanges)&&t!==a&&(o||(u.$$postDigest(r),o=[]),n||(n={},o.push(i)),n[e]&&(a=n[e].previousValue),n[e]=new ca(a,t))}function i(){p.$onChanges(n),n=void 0}return ge(e,function(e,a){var t=e.attrName,n=e.optional;switch(e.mode){case"@":n||L.call(d,t)||(p[a]=d[t]=void 0),d.$observe(t,function(e){var t;(R(e)||q(e))&&(t=p[a],h(a,e,t),p[a]=e)}),d.$$observers[t].$$scope=u,R(r=d[t])?p[a]=x(r)(u):q(r)&&(p[a]=r),f[a]=new ca(ra,p[a]);break;case"=":if(!L.call(d,t)){if(n)break;d[t]=void 0}if(n&&!d[t])break;var i,s=(i=v(d[t])).literal?_e:function(e,t){return e===t||e!=e&&t!=t},o=i.assign||function(){throw r=p[a]=i(u),oa("nonassign","Expression '{0}' in attribute '{1}' used with directive '{2}' is non-assignable!",d[t],t,m.name)},r=p[a]=i(u),l=function(e){return s(e,p[a])||(s(e,r)?o(u,e=p[a]):p[a]=e),r=e};l.$stateful=!0,l=e.collection?u.$watchCollection(d[t],l):u.$watch(v(d[t],l),null,i.literal),g.push(l);break;case"<":if(!L.call(d,t)){if(n)break;d[t]=void 0}if(n&&!d[t])break;i=v(d[t]);var c=p[a]=i(u);f[a]=new ca(ra,p[a]),l=u.$watch(i,function(e,t){if(t===e){if(t===c)return;t=c}h(a,e,t),p[a]=e},i.literal),g.push(l);break;case"&":if((i=d.hasOwnProperty(t)?v(d[t]):N)===N&&n)break;p[a]=function(e){return i(u,e)}}}),{initialChanges:f,removeWatches:g.length&&function(){for(var e=0,t=g.length;e<t;++e)g[e]()}}}}]}function ca(e,t){this.previousValue=e,this.currentValue=t}la.$inject=["$provide","$$sanitizeUriProvider"],ca.prototype.isFirstChange=function(){return this.previousValue===ra};var ua=/^((?:x|data)[\:\-_])/i;function da(e){return Qe(e.replace(ua,""))}function pa(e,t){var a="",n=e.split(/\s+/),i=t.split(/\s+/);e:for(var s=0;s<n.length;s++){for(var o=n[s],r=0;r<i.length;r++)if(o==i[r])continue e;a+=(0<a.length?" ":"")+o}return a}function ma(e){var t=(e=me(e)).length;if(t<=1)return e;for(;t--;)e[t].nodeType===Oe&&a.call(e,t,1);return e}var ga=w("$controller"),fa=/^(\S+)(\s+as\s+([\w$]+))?$/;function ha(e,t){if(t&&R(t))return t;if(R(e)){e=fa.exec(e);if(e)return e[3]}}function va(){var u={},d=!1;this.has=function(e){return u.hasOwnProperty(e)},this.register=function(e,t){De(e,"controller"),ye(e)?fe(u,e):u[e]=t},this.allowGlobals=function(){d=!0},this.$get=["$injector","$window",function(r,l){return function(t,a,e,n){var i,s;if(e=!0===e,n&&R(n)&&(s=n),R(t)){if(!(n=t.match(fa)))throw ga("ctrlfmt","Badly formed controller string '{0}'. Must match `__name__ as __id__` or `__name__`.",t);i=n[1],s=s||n[3],pe(t=u.hasOwnProperty(i)?u[i]:Te(a.$scope,i,!0)||(d?Te(l,i,!0):void 0),i,!0)}if(e){var e=(be(t)?t[t.length-1]:t).prototype,o=Object.create(e||null);return s&&c(a,s,o,i||t.name),fe(function(){var e=r.invoke(t,o,a,i);return e!==o&&(ye(e)||we(e))&&(o=e,s&&c(a,s,o,i||t.name)),o},{instance:o,identifier:s})}return o=r.instantiate(t,a,i),s&&c(a,s,o,i||t.name),o};function c(e,t,a,n){if(!e||!ye(e.$scope))throw w("$controller")("noscp","Cannot export controller '{0}' as '{1}'! No $scope object provided via `locals`.",n,t);e.$scope[t]=a}}]}function ya(){this.$get=["$window",function(e){return me(e.document)}]}function ba(){this.$get=["$log",function(a){return function(e,t){a.error.apply(a,arguments)}}]}function wa(){this.$get=["$document",function(t){return function(e){return e?!e.nodeType&&e instanceof me&&(e=e[0]):e=t[0].body,e.offsetWidth+1}}]}var $a="application/json",ka={"Content-Type":$a+";charset=utf-8"},xa=/^\[|^\{(?!\{)/,_a={"[":/]$/,"{":/}$/},Sa=/^\)\]\}',?\n/,Ia=w("$http"),Ca=function(e){return function(){throw Ia("legacy","The method `{0}` on the promise returned from `$http` has been disabled.",e)}};function Aa(e){return ye(e)?C(e)?e.toISOString():K(e):e}function Ma(){this.$get=function(){return function(e){if(!e)return"";var a=[];return c(e,function(e,t){null===e||ve(e)||(be(e)?ge(e,function(e){a.push(ie(t)+"="+ie(Aa(e)))}):a.push(ie(t)+"="+ie(Aa(e))))}),a.join("&")}}}function Da(){this.$get=function(){return function(e){if(!e)return"";var t=[];return function a(e,n,i){if(null===e||ve(e))return;be(e)?ge(e,function(e,t){a(e,n+"["+(ye(e)?t:"")+"]")}):ye(e)&&!C(e)?c(e,function(e,t){a(e,n+(i?"":"[")+t+(i?"":"]"))}):t.push(ie(n)+"="+ie(Aa(e)))}(e,"",!0),t.join("&")}}}function Ta(e,t){var a,n;return R(e)&&(!(a=e.replace(Sa,"").trim())||((n=t("Content-Type"))&&0===n.indexOf($a)||(n=(t=a).match(xa))&&_a[n[0]].test(t))&&(e=Q(a))),e}function Pa(e){var t,a=Ee();function n(e,t){e&&(a[e]=a[e]?a[e]+", "+t:t)}return R(e)?ge(e.split("\n"),function(e){t=e.indexOf(":"),n(O(ke(e.substr(0,t))),ke(e.substr(t+1)))}):ye(e)&&ge(e,function(e,t){n(O(t),ke(e))}),a}function Ea(t){var a;return function(e){if(a=a||Pa(t),e){e=a[O(e)];return e=void 0===e?null:e}return a}}function ja(t,a,n,e){return we(e)?e(t,a,n):(ge(e,function(e){t=e(t,a,n)}),t)}function La(e){return 200<=e&&e<300}function Oa(){var y=this.defaults={transformResponse:[Ta],transformRequest:[function(e){return ye(e)&&(a=e,"[object File]"!==$.call(a))&&(t=e,"[object Blob]"!==$.call(t))&&(t=e,"[object FormData]"!==$.call(t))?K(e):e;var t,a}],headers:{common:{Accept:"application/json, text/plain, */*"},post:F(ka),put:F(ka),patch:F(ka)},xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",paramSerializer:"$httpParamSerializer"},b=!1;this.useApplyAsync=function(e){return B(e)?(b=!!e,this):b};var c=!0;this.useLegacyPromiseExtensions=function(e){return B(e)?(c=!!e,this):c};var t=this.interceptors=[];this.$get=["$httpBackend","$$cookieReader","$cacheFactory","$rootScope","$q","$injector",function(p,m,e,g,f,r){var h=e("$http");y.paramSerializer=R(y.paramSerializer)?r.get(y.paramSerializer):y.paramSerializer;var l=[];function v(e){if(!ye(e))throw w("$http")("badreq","Http request configuration must be an object. Received: {0}",e);if(!R(e.url))throw w("$http")("badreq","Http request configuration url must be a string. Received: {0}",e.url);var a=fe({method:"get",transformRequest:y.transformRequest,transformResponse:y.transformResponse,paramSerializer:y.paramSerializer},e);a.headers=function(e){var t,a,n,i=y.headers,s=fe({},e.headers);e:for(t in i=fe({},i.common,i[O(e.method)])){for(n in a=O(t),s)if(O(n)===a)continue e;s[t]=i[t]}return function(e,a){var n,i={};return ge(e,function(e,t){we(e)?null!=(n=e(a))&&(i[t]=n):i[t]=e}),i}(s,F(e))}(e),a.method=u(a.method),a.paramSerializer=R(a.paramSerializer)?r.get(a.paramSerializer):a.paramSerializer;var t=[function(e){var a=e.headers,t=ja(e.data,Ea(a),void 0,e.transformRequest);return ve(t)&&ge(a,function(e,t){"content-type"===O(t)&&delete a[t]}),ve(e.withCredentials)&&!ve(y.withCredentials)&&(e.withCredentials=y.withCredentials),function(i,e){var s,o=f.defer(),t=o.promise,a=i.headers,r=function(e,t){0<t.length&&(e+=(-1==e.indexOf("?")?"?":"&")+t);return e}(i.url,i.paramSerializer(i.params));v.pendingRequests.push(i),t.then(d,d),!i.cache&&!y.cache||!1===i.cache||"GET"!==i.method&&"JSONP"!==i.method||(s=ye(i.cache)?i.cache:ye(y.cache)?y.cache:h);s&&(B(n=s.get(r))?D(n)?n.then(u,u):be(n)?c(n[1],n[0],F(n[2]),n[3]):c(n,200,{},"OK"):s.put(r,t));{var n;ve(n)&&((n=ti(i.url)?m()[i.xsrfCookieName||y.xsrfCookieName]:void 0)&&(a[i.xsrfHeaderName||y.xsrfHeaderName]=n),p(i.method,r,e,function(e,t,a,n){s&&(La(e)?s.put(r,[e,t,Pa(a),n]):s.remove(r));function i(){c(t,e,a,n)}b?g.$applyAsync(i):(i(),g.$$phase||g.$apply())},a,i.timeout,i.withCredentials,i.responseType,l(i.eventHandlers),l(i.uploadEventHandlers)))}return t;function l(e){if(e){var t={};return ge(e,function(a,e){t[e]=function(e){function t(){a(e)}b?g.$applyAsync(t):g.$$phase?t():g.$apply(t)}}),t}}function c(e,t,a,n){(La(t=-1<=t?t:0)?o.resolve:o.reject)({data:e,status:t,headers:Ea(a),config:i,statusText:n})}function u(e){c(e.data,e.status,F(e.headers()),e.statusText)}function d(){var e=v.pendingRequests.indexOf(i);-1!==e&&v.pendingRequests.splice(e,1)}}(e,t).then(o,o)},void 0],n=f.when(a);for(ge(l,function(e){(e.request||e.requestError)&&t.unshift(e.request,e.requestError),(e.response||e.responseError)&&t.push(e.response,e.responseError)});t.length;)var i=t.shift(),s=t.shift(),n=n.then(i,s);return c?(n.success=function(t){return pe(t,"fn"),n.then(function(e){t(e.data,e.status,e.headers,a)}),n},n.error=function(t){return pe(t,"fn"),n.then(null,function(e){t(e.data,e.status,e.headers,a)}),n}):(n.success=Ca("success"),n.error=Ca("error")),n;function o(e){var t=fe({},e);return t.data=ja(e.data,e.headers,e.status,a.transformResponse),La(e.status)?t:f.reject(t)}}return ge(t,function(e){l.unshift(R(e)?r.get(e):r.invoke(e))}),v.pendingRequests=[],function(){ge(arguments,function(a){v[a]=function(e,t){return v(fe({},t||{},{method:a,url:e}))}})}("get","delete","head","jsonp"),function(){ge(arguments,function(n){v[n]=function(e,t,a){return v(fe({},a||{},{method:n,url:e,data:t}))}})}("post","put","patch"),v.defaults=y,v}]}function Ua(){this.$get=function(){return function(){return new h.XMLHttpRequest}}}function Na(){this.$get=["$browser","$window","$document","$xhrFactory",function(e,t,a,n){return k=n,x=($=e).defer,_=t.angular.callbacks,S=a[0],function(e,n,t,i,a,s,o,r,l,c){if($.$$incOutstandingRequestCount(),n=n||$.url(),"jsonp"==O(e)){var u="_"+(_.counter++).toString(36);_[u]=function(e){_[u].data=e,_[u].called=!0};var d=(m=n.replace("JSON_CALLBACK","angular.callbacks."+u),g=u,f=function(e,t){w(i,e,_[u].data,"",t),_[u]=N},h=S.createElement("script"),v=null,h.type="text/javascript",h.src=m,h.async=!0,v=function(e){ze(h,"load",v),ze(h,"error",v),S.body.removeChild(h),h=null;var t=-1,a="unknown";e&&(a=(e="load"===e.type&&!_[g].called?{type:"error"}:e).type,t="error"===e.type?404:200),f&&f(t,a)},Fe(h,"load",v),Fe(h,"error",v),S.body.appendChild(h),v)}else{var p=k(e,n);p.open(e,n,!0),ge(a,function(e,t){B(e)&&p.setRequestHeader(t,e)}),p.onload=function(){var e=p.statusText||"",t="response"in p?p.response:p.responseText,a=1223===p.status?204:p.status;0===a&&(a=t?200:"file"==ei(n).protocol?404:0),w(i,a,t,p.getAllResponseHeaders(),e)};a=function(){w(i,-1,null,null,"")};if(p.onerror=a,p.onabort=a,ge(l,function(e,t){p.addEventListener(t,e)}),ge(c,function(e,t){p.upload.addEventListener(t,e)}),o&&(p.withCredentials=!0),r)try{p.responseType=r}catch(e){if("json"!==r)throw e}p.send(ve(t)?null:t)}var m,g,f,h,v,y;function b(){d&&d(),p&&p.abort()}function w(e,t,a,n,i){B(y)&&x.cancel(y),d=p=null,e(t,a,n,i),$.$$completeOutstandingRequest(N)}0<s?y=x(b,s):D(s)&&s.then(b)};var $,k,x,_,S}]}var Ba=S.$interpolateMinErr=w("$interpolate");function Ra(){var x="{{",_="}}";this.startSymbol=function(e){return e?(x=e,this):x},this.endSymbol=function(e){return e?(_=e,this):_},this.$get=["$parse","$exceptionHandler","$sce",function(h,v,y){var b=x.length,w=_.length,t=new RegExp(x.replace(/./g,e),"g"),a=new RegExp(_.replace(/./g,e),"g");function e(e){return"\\\\\\"+e}function $(e){return e.replace(t,x).replace(a,_)}function k(e,t,a,n){var i;return i=e.$watch(function(e){return i(),n(e)},t,a)}function n(i,e,t,n){var a;if(!i.length||-1===i.indexOf(x))return e||((a=I($(i))).exp=i,a.expressions=[],a.$$watchDelegate=k),a;n=!!n;for(var s,o,r=0,l=[],c=[],u=i.length,d=[],p=[];r<u;){if(-1==(o=i.indexOf(x,r))||-1==(s=i.indexOf(_,o+b))){r!==u&&d.push($(i.substring(r)));break}r!==o&&d.push($(i.substring(r,o))),o=i.substring(o+b,s),l.push(o),c.push(h(o,f)),r=s+w,p.push(d.length),d.push("")}if(t&&1<d.length&&Ba.throwNoconcat(i),!e||l.length){var m=function(e){for(var t=0,a=l.length;t<a;t++){if(n&&ve(e[t]))return;d[p[t]]=e[t]}return d.join("")},g=function(e){return t?y.getTrusted(t,e):y.valueOf(e)};return fe(function(e){var t=0,a=l.length,n=new Array(a);try{for(;t<a;t++)n[t]=c[t](e);return m(n)}catch(e){v(Ba.interr(i,e))}},{exp:i,expressions:l,$$watchDelegate:function(n,i){var s;return n.$watchGroup(c,function(e,t){var a=m(e);we(i)&&i.call(this,a,e!==t?s:a,n),s=a})}})}function f(e){try{return e=g(e),n&&!B(e)?e:function(e){if(null==e)return"";switch(typeof e){case"string":break;case"number":e=""+e;break;default:e=K(e)}return e}(e)}catch(e){v(Ba.interr(i,e))}}}return n.startSymbol=function(){return x},n.endSymbol=function(){return _},n}]}function qa(){this.$get=["$rootScope","$window","$q","$$q","$browser",function(m,g,f,h,v){var y={};function e(e,t,a,n){var i=4<arguments.length,s=i?Se(arguments,4):[],o=g.setInterval,r=g.clearInterval,l=0,c=B(n)&&!n,u=(c?h:f).defer(),d=u.promise;return a=B(a)?a:0,d.$$intervalId=o(function(){c?v.defer(p):m.$evalAsync(p),u.notify(l++),0<a&&a<=l&&(u.resolve(l),r(d.$$intervalId),delete y[d.$$intervalId]),c||m.$apply()},t),y[d.$$intervalId]=u,d;function p(){i?e.apply(null,s):e(l)}}return e.cancel=function(e){return!!(e&&e.$$intervalId in y)&&(y[e.$$intervalId].reject("canceled"),g.clearInterval(e.$$intervalId),delete y[e.$$intervalId],!0)},e}]}Ba.throwNoconcat=function(e){throw Ba("noconcat","Error while interpolating: {0}\nStrict Contextual Escaping disallows interpolations that concatenate multiple expressions when a trusted value is required. See http://docs.angularjs.org/api/ng.$sce",e)},Ba.interr=function(e,t){return Ba("interr","Can't interpolate: {0}\n{1}",e,t.toString())};var Va=/^([^\?#]*)(\?([^#]*))?(#(.*))?$/,Ya={http:80,https:443,ftp:21},Fa=w("$location");function za(e){for(var t=e.split("/"),a=t.length;a--;)t[a]=ne(t[a]);return t.join("/")}function Ha(e,t){e=ei(e);t.$$protocol=e.protocol,t.$$host=e.hostname,t.$$port=y(e.port)||Ya[e.protocol]||null}function Wa(e,t){var a="/"!==e.charAt(0),e=ei(e=a?"/"+e:e);t.$$path=decodeURIComponent(a&&"/"===e.pathname.charAt(0)?e.pathname.substring(1):e.pathname),t.$$search=te(e.search),t.$$hash=decodeURIComponent(e.hash),t.$$path&&"/"!=t.$$path.charAt(0)&&(t.$$path="/"+t.$$path)}function Ga(e,t){return 0===e.lastIndexOf(t,0)}function Ka(e,t){if(Ga(t,e))return t.substr(e.length)}function Qa(e){var t=e.indexOf("#");return-1==t?e:e.substr(0,t)}function Ja(e){return e.replace(/(#.+)|#$/,"$1")}function Za(n,i,s){this.$$html5=!0,s=s||"",Ha(n,this),this.$$parse=function(e){var t=Ka(i,e);if(!R(t))throw Fa("ipthprfx",'Invalid url "{0}", missing path prefix "{1}".',e,i);Wa(t,this),this.$$path||(this.$$path="/"),this.$$compose()},this.$$compose=function(){var e=ae(this.$$search),t=this.$$hash?"#"+ne(this.$$hash):"";this.$$url=za(this.$$path)+(e?"?"+e:"")+t,this.$$absUrl=i+this.$$url.substr(1)},this.$$parseLinkUrl=function(e,t){return t&&"#"===t[0]?(this.hash(t.slice(1)),!0):(B(t=Ka(n,e))?a=B(t=Ka(s,a=t))?i+(Ka("/",t)||t):n+a:B(t=Ka(i,e))?a=i+t:i==e+"/"&&(a=i),a&&this.$$parse(a),!!a);var a}}function Xa(n,i,s){Ha(n,this),this.$$parse=function(e){var t,a=Ka(n,e)||Ka(i,e);ve(a)||"#"!==a.charAt(0)?this.$$html5?t=a:(t="",ve(a)&&(n=e,this.replace())):ve(t=Ka(s,a))&&(t=a),Wa(t,this),this.$$path=function(e,t,a){var n=/^\/[A-Z]:(\/.*)/;Ga(t,a)&&(t=t.replace(a,""));if(n.exec(t))return e;return(n=n.exec(e))?n[1]:e}(this.$$path,t,n),this.$$compose()},this.$$compose=function(){var e=ae(this.$$search),t=this.$$hash?"#"+ne(this.$$hash):"";this.$$url=za(this.$$path)+(e?"?"+e:"")+t,this.$$absUrl=n+(this.$$url?s+this.$$url:"")},this.$$parseLinkUrl=function(e,t){return Qa(n)==Qa(e)&&(this.$$parse(e),!0)}}function en(n,i,s){this.$$html5=!0,Xa.apply(this,arguments),this.$$parseLinkUrl=function(e,t){return t&&"#"===t[0]?(this.hash(t.slice(1)),!0):(n==Qa(e)?a=e:(t=Ka(i,e))?a=n+s+t:i===e+"/"&&(a=i),a&&this.$$parse(a),!!a);var a},this.$$compose=function(){var e=ae(this.$$search),t=this.$$hash?"#"+ne(this.$$hash):"";this.$$url=za(this.$$path)+(e?"?"+e:"")+t,this.$$absUrl=n+s+this.$$url}}var tn={$$html5:!1,$$replace:!1,absUrl:an("$$absUrl"),url:function(e){if(ve(e))return this.$$url;var t=Va.exec(e);return!t[1]&&""!==e||this.path(decodeURIComponent(t[1])),(t[2]||t[1]||""===e)&&this.search(t[3]||""),this.hash(t[5]||""),this},protocol:an("$$protocol"),host:an("$$host"),port:an("$$port"),path:nn("$$path",function(e){return"/"==(e=null!==e?e.toString():"").charAt(0)?e:"/"+e}),search:function(a,e){switch(arguments.length){case 0:return this.$$search;case 1:if(R(a)||_(a))a=a.toString(),this.$$search=te(a);else{if(!ye(a))throw Fa("isrcharg","The first argument of the `$location#search()` call must be a string or an object.");ge(a=Y(a,{}),function(e,t){null==e&&delete a[t]}),this.$$search=a}break;default:ve(e)||null===e?delete this.$$search[a]:this.$$search[a]=e}return this.$$compose(),this},hash:nn("$$hash",function(e){return null!==e?e.toString():""}),replace:function(){return this.$$replace=!0,this}};function an(e){return function(){return this[e]}}function nn(t,a){return function(e){return ve(e)?this[t]:(this[t]=a(e),this.$$compose(),this)}}function sn(){var f="",h={enabled:!1,requireBase:!0,rewriteLinks:!0};this.hashPrefix=function(e){return B(e)?(f=e,this):f},this.html5Mode=function(e){return q(e)?(h.enabled=e,this):ye(e)?(q(e.enabled)&&(h.enabled=e.enabled),q(e.requireBase)&&(h.requireBase=e.requireBase),q(e.rewriteLinks)&&(h.rewriteLinks=e.rewriteLinks),this):h},this.$get=["$rootScope","$browser","$sniffer","$rootElement","$window",function(o,r,t,i,s){var e,a,n=r.baseHref(),l=r.url();if(h.enabled){if(!n&&h.requireBase)throw Fa("nobase","$location in HTML5 mode requires a <base> tag to be present!");e=(a=l).substring(0,a.indexOf("/",a.indexOf("//")+2))+(n||"/"),a=t.history?Za:en}else e=Qa(l),a=Xa;var c,u=(n=e).substr(0,Qa(n).lastIndexOf("/")+1);(c=new a(e,u,"#"+f)).$$parseLinkUrl(l,l),c.$$state=r.state();var d=/^\s*(javascript|mailto):/i;function p(e,t,a){var n=c.url(),i=c.$$state;try{r.url(e,t,a),c.$$state=r.state()}catch(e){throw c.url(n),c.$$state=i,e}}i.on("click",function(e){if(h.rewriteLinks&&!e.ctrlKey&&!e.metaKey&&!e.shiftKey&&2!=e.which&&2!=e.button){for(var t=me(e.target);"a"!==xe(t[0]);)if(t[0]===i[0]||!(t=t.parent())[0])return;var a=t.prop("href"),n=t.attr("href")||t.attr("xlink:href");ye(a)&&"[object SVGAnimatedString]"===a.toString()&&(a=ei(a.animVal).href),d.test(a)||!a||t.attr("target")||e.isDefaultPrevented()||c.$$parseLinkUrl(a,n)&&(e.preventDefault(),c.absUrl()!=r.url()&&(o.$apply(),s.angular["ff-684208-preventDefault"]=!0))}}),Ja(c.absUrl())!=Ja(l)&&r.url(c.absUrl(),!0);var m=!0;return r.onUrlChange(function(n,i){ve(Ka(u,n))?s.location.href=n:(o.$evalAsync(function(){var e,t=c.absUrl(),a=c.$$state;n=Ja(n),c.$$parse(n),c.$$state=i,e=o.$broadcast("$locationChangeStart",n,t,i,a).defaultPrevented,c.absUrl()===n&&(e?(c.$$parse(t),c.$$state=a,p(t,!1,a)):(m=!1,g(t,a)))}),o.$$phase||o.$digest())}),o.$watch(function(){var a=Ja(r.url()),e=Ja(c.absUrl()),n=r.state(),i=c.$$replace,s=a!==e||c.$$html5&&t.history&&n!==c.$$state;(m||s)&&(m=!1,o.$evalAsync(function(){var e=c.absUrl(),t=o.$broadcast("$locationChangeStart",e,a,c.$$state,n).defaultPrevented;c.absUrl()===e&&(t?(c.$$parse(a),c.$$state=n):(s&&p(e,i,n===c.$$state?null:c.$$state),g(a,n)))})),c.$$replace=!1}),c;function g(e,t){o.$broadcast("$locationChangeSuccess",c.absUrl(),e,c.$$state,t)}}]}function on(){var n=!0,i=this;this.debugEnabled=function(e){return B(e)?(n=e,this):n},this.$get=["$window",function(t){return{log:a("log"),info:a("info"),warn:a("warn"),error:a("error"),debug:(e=a("debug"),function(){n&&e.apply(i,arguments)})};var e;function a(e){var a=t.console||{},n=a[e]||a.log||N,e=!1;try{e=!!n.apply}catch(e){}return e?function(){var t=[];return ge(arguments,function(e){t.push(((e=e)instanceof Error&&(e.stack?e=e.message&&-1===e.stack.indexOf(e.message)?"Error: "+e.message+"\n"+e.stack:e.stack:e.sourceURL&&(e=e.message+"\n"+e.sourceURL+":"+e.line)),e))}),n.apply(a,t)}:function(e,t){n(e,null==t?"":t)}}}]}ge([en,Xa,Za],function(t){t.prototype=Object.create(tn),t.prototype.state=function(e){if(!arguments.length)return this.$$state;if(t!==Za||!this.$$html5)throw Fa("nostate","History API state support is available only in HTML5 mode and only in browsers supporting HTML5 History API");return this.$$state=ve(e)?null:e,this}});var rn=w("$parse");function ln(e,t){if("__defineGetter__"===e||"__defineSetter__"===e||"__lookupGetter__"===e||"__lookupSetter__"===e||"__proto__"===e)throw rn("isecfld","Attempting to access a disallowed field in Angular expressions! Expression: {0}",t);return e}function cn(e){return e+""}function un(e,t){if(e){if(e.constructor===e)throw rn("isecfn","Referencing Function in Angular expressions is disallowed! Expression: {0}",t);if(e.window===e)throw rn("isecwindow","Referencing the Window in Angular expressions is disallowed! Expression: {0}",t);if(e.children&&(e.nodeName||e.prop&&e.attr&&e.find))throw rn("isecdom","Referencing DOM nodes in Angular expressions is disallowed! Expression: {0}",t);if(e===Object)throw rn("isecobj","Referencing Object in Angular expressions is disallowed! Expression: {0}",t)}return e}var dn=Function.prototype.call,pn=Function.prototype.apply,mn=Function.prototype.bind;function gn(e,t){if(e){if(e.constructor===e)throw rn("isecfn","Referencing Function in Angular expressions is disallowed! Expression: {0}",t);if(e===dn||e===pn||e===mn)throw rn("isecff","Referencing call, apply or bind in Angular expressions is disallowed! Expression: {0}",t)}}function fn(e,t){if(e&&(e===0..constructor||e===(!1).constructor||e==="".constructor||e==={}.constructor||e===[].constructor||e===Function.constructor))throw rn("isecaf","Assigning to a constructor is disallowed! Expression: {0}",t)}var hn=Ee();ge("+ - * / % === !== == != < > <= >= && || ! = |".split(" "),function(e){hn[e]=!0});var vn={n:"\n",f:"\f",r:"\r",t:"\t",v:"\v","'":"'",'"':'"'},yn=function(e){this.options=e};yn.prototype={constructor:yn,lex:function(e){for(this.text=e,this.index=0,this.tokens=[];this.index<this.text.length;){var t,a,n,i,s,o=this.text.charAt(this.index);'"'===o||"'"===o?this.readString(o):this.isNumber(o)||"."===o&&this.isNumber(this.peek())?this.readNumber():this.isIdentifierStart(this.peekMultichar())?this.readIdent():this.is(o,"(){}[].,;:?")?(this.tokens.push({index:this.index,text:o}),this.index++):this.isWhitespace(o)?this.index++:(a=(t=o+this.peek())+this.peek(2),n=hn[o],i=hn[t],s=hn[a],n||i||s?(this.tokens.push({index:this.index,text:o=s?a:i?t:o,operator:!0}),this.index+=o.length):this.throwError("Unexpected next character ",this.index,this.index+1))}return this.tokens},is:function(e,t){return-1!==t.indexOf(e)},peek:function(e){e=e||1;return this.index+e<this.text.length&&this.text.charAt(this.index+e)},isNumber:function(e){return"0"<=e&&e<="9"&&"string"==typeof e},isWhitespace:function(e){return" "===e||"\r"===e||"\t"===e||"\n"===e||"\v"===e||" "===e},isIdentifierStart:function(e){return this.options.isIdentifierStart?this.options.isIdentifierStart(e,this.codePointAt(e)):this.isValidIdentifierStart(e)},isValidIdentifierStart:function(e){return"a"<=e&&e<="z"||"A"<=e&&e<="Z"||"_"===e||"$"===e},isIdentifierContinue:function(e){return this.options.isIdentifierContinue?this.options.isIdentifierContinue(e,this.codePointAt(e)):this.isValidIdentifierContinue(e)},isValidIdentifierContinue:function(e,t){return this.isValidIdentifierStart(e,t)||this.isNumber(e)},codePointAt:function(e){return 1===e.length?e.charCodeAt(0):(e.charCodeAt(0)<<10)+e.charCodeAt(1)-56613888},peekMultichar:function(){var e=this.text.charAt(this.index),t=this.peek();if(!t)return e;var a=e.charCodeAt(0),n=t.charCodeAt(0);return 55296<=a&&a<=56319&&56320<=n&&n<=57343?e+t:e},isExpOperator:function(e){return"-"===e||"+"===e||this.isNumber(e)},throwError:function(e,t,a){a=a||this.index;a=B(t)?"s "+t+"-"+this.index+" ["+this.text.substring(t,a)+"]":" "+a;throw rn("lexerr","Lexer Error: {0} at column{1} in expression [{2}].",e,a,this.text)},readNumber:function(){for(var e="",t=this.index;this.index<this.text.length;){var a=O(this.text.charAt(this.index));if("."==a||this.isNumber(a))e+=a;else{var n=this.peek();if("e"==a&&this.isExpOperator(n))e+=a;else if(this.isExpOperator(a)&&n&&this.isNumber(n)&&"e"==e.charAt(e.length-1))e+=a;else{if(!this.isExpOperator(a)||n&&this.isNumber(n)||"e"!=e.charAt(e.length-1))break;this.throwError("Invalid exponent")}}this.index++}this.tokens.push({index:t,text:e,constant:!0,value:Number(e)})},readIdent:function(){var e=this.index;for(this.index+=this.peekMultichar().length;this.index<this.text.length;){var t=this.peekMultichar();if(!this.isIdentifierContinue(t))break;this.index+=t.length}this.tokens.push({index:e,text:this.text.slice(e,this.index),identifier:!0})},readString:function(e){var t=this.index;this.index++;for(var a="",n=e,i=!1;this.index<this.text.length;){var s,o=this.text.charAt(this.index);if(n+=o,i)"u"===o?((s=this.text.substring(this.index+1,this.index+5)).match(/[\da-f]{4}/i)||this.throwError("Invalid unicode escape [\\u"+s+"]"),this.index+=4,a+=String.fromCharCode(parseInt(s,16))):a+=vn[o]||o,i=!1;else if("\\"===o)i=!0;else{if(o===e)return this.index++,void this.tokens.push({index:t,text:n,constant:!0,value:a});a+=o}this.index++}this.throwError("Unterminated quote",t)}};var bn=function(e,t){this.lexer=e,this.options=t};function wn(e,t){return void 0!==e?e:t}function $n(e,t){return void 0===e?t:void 0===t?e:e+t}function kn(e,t){return!e(t).$stateful}function xn(e,t){var a,n;switch(e.type){case bn.Program:a=!0,ge(e.body,function(e){xn(e.expression,t),a=a&&e.expression.constant}),e.constant=a;break;case bn.Literal:e.constant=!0,e.toWatch=[];break;case bn.UnaryExpression:xn(e.argument,t),e.constant=e.argument.constant,e.toWatch=e.argument.toWatch;break;case bn.BinaryExpression:xn(e.left,t),xn(e.right,t),e.constant=e.left.constant&&e.right.constant,e.toWatch=e.left.toWatch.concat(e.right.toWatch);break;case bn.LogicalExpression:xn(e.left,t),xn(e.right,t),e.constant=e.left.constant&&e.right.constant,e.toWatch=e.constant?[]:[e];break;case bn.ConditionalExpression:xn(e.test,t),xn(e.alternate,t),xn(e.consequent,t),e.constant=e.test.constant&&e.alternate.constant&&e.consequent.constant,e.toWatch=e.constant?[]:[e];break;case bn.Identifier:e.constant=!1,e.toWatch=[e];break;case bn.MemberExpression:xn(e.object,t),e.computed&&xn(e.property,t),e.constant=e.object.constant&&(!e.computed||e.property.constant),e.toWatch=[e];break;case bn.CallExpression:a=!!e.filter&&kn(t,e.callee.name),n=[],ge(e.arguments,function(e){xn(e,t),a=a&&e.constant,e.constant||n.push.apply(n,e.toWatch)}),e.constant=a,e.toWatch=e.filter&&kn(t,e.callee.name)?n:[e];break;case bn.AssignmentExpression:xn(e.left,t),xn(e.right,t),e.constant=e.left.constant&&e.right.constant,e.toWatch=[e];break;case bn.ArrayExpression:a=!0,n=[],ge(e.elements,function(e){xn(e,t),a=a&&e.constant,e.constant||n.push.apply(n,e.toWatch)}),e.constant=a,e.toWatch=n;break;case bn.ObjectExpression:a=!0,n=[],ge(e.properties,function(e){xn(e.value,t),a=a&&e.value.constant&&!e.computed,e.value.constant||n.push.apply(n,e.value.toWatch)}),e.constant=a,e.toWatch=n;break;case bn.ThisExpression:case bn.LocalsExpression:e.constant=!1,e.toWatch=[]}}function _n(e){if(1==e.length){var t=e[0].expression,e=t.toWatch;return 1!==e.length||e[0]!==t?e:void 0}}function Sn(e){return e.type===bn.Identifier||e.type===bn.MemberExpression}function In(e){if(1===e.body.length&&Sn(e.body[0].expression))return{type:bn.AssignmentExpression,left:e.body[0].expression,right:{type:bn.NGValueParameter},operator:"="}}function Cn(e){return 0===e.body.length||1===e.body.length&&(e.body[0].expression.type===bn.Literal||e.body[0].expression.type===bn.ArrayExpression||e.body[0].expression.type===bn.ObjectExpression)}function An(e){return e.constant}function Mn(e,t){this.astBuilder=e,this.$filter=t}function Dn(e,t){this.astBuilder=e,this.$filter=t}bn.Program="Program",bn.ExpressionStatement="ExpressionStatement",bn.AssignmentExpression="AssignmentExpression",bn.ConditionalExpression="ConditionalExpression",bn.LogicalExpression="LogicalExpression",bn.BinaryExpression="BinaryExpression",bn.UnaryExpression="UnaryExpression",bn.CallExpression="CallExpression",bn.MemberExpression="MemberExpression",bn.Identifier="Identifier",bn.Literal="Literal",bn.ArrayExpression="ArrayExpression",bn.Property="Property",bn.ObjectExpression="ObjectExpression",bn.ThisExpression="ThisExpression",bn.LocalsExpression="LocalsExpression",bn.NGValueParameter="NGValueParameter",bn.prototype={ast:function(e){this.text=e,this.tokens=this.lexer.lex(e);e=this.program();return 0!==this.tokens.length&&this.throwError("is an unexpected token",this.tokens[0]),e},program:function(){for(var e=[];;)if(0<this.tokens.length&&!this.peek("}",")",";","]")&&e.push(this.expressionStatement()),!this.expect(";"))return{type:bn.Program,body:e}},expressionStatement:function(){return{type:bn.ExpressionStatement,expression:this.filterChain()}},filterChain:function(){for(var e=this.expression();this.expect("|");)e=this.filter(e);return e},expression:function(){return this.assignment()},assignment:function(){var e=this.ternary();return e=this.expect("=")?{type:bn.AssignmentExpression,left:e,right:this.assignment(),operator:"="}:e},ternary:function(){var e,t,a=this.logicalOR();return this.expect("?")&&(e=this.expression(),this.consume(":"))?(t=this.expression(),{type:bn.ConditionalExpression,test:a,alternate:e,consequent:t}):a},logicalOR:function(){for(var e=this.logicalAND();this.expect("||");)e={type:bn.LogicalExpression,operator:"||",left:e,right:this.logicalAND()};return e},logicalAND:function(){for(var e=this.equality();this.expect("&&");)e={type:bn.LogicalExpression,operator:"&&",left:e,right:this.equality()};return e},equality:function(){for(var e,t=this.relational();e=this.expect("==","!=","===","!==");)t={type:bn.BinaryExpression,operator:e.text,left:t,right:this.relational()};return t},relational:function(){for(var e,t=this.additive();e=this.expect("<",">","<=",">=");)t={type:bn.BinaryExpression,operator:e.text,left:t,right:this.additive()};return t},additive:function(){for(var e,t=this.multiplicative();e=this.expect("+","-");)t={type:bn.BinaryExpression,operator:e.text,left:t,right:this.multiplicative()};return t},multiplicative:function(){for(var e,t=this.unary();e=this.expect("*","/","%");)t={type:bn.BinaryExpression,operator:e.text,left:t,right:this.unary()};return t},unary:function(){var e;return(e=this.expect("+","-","!"))?{type:bn.UnaryExpression,operator:e.text,prefix:!0,argument:this.unary()}:this.primary()},primary:function(){var e,t;for(this.expect("(")?(e=this.filterChain(),this.consume(")")):this.expect("[")?e=this.arrayDeclaration():this.expect("{")?e=this.object():this.selfReferential.hasOwnProperty(this.peek().text)?e=Y(this.selfReferential[this.consume().text]):this.options.literals.hasOwnProperty(this.peek().text)?e={type:bn.Literal,value:this.options.literals[this.consume().text]}:this.peek().identifier?e=this.identifier():this.peek().constant?e=this.constant():this.throwError("not a primary expression",this.peek());t=this.expect("(","[",".");)"("===t.text?(e={type:bn.CallExpression,callee:e,arguments:this.parseArguments()},this.consume(")")):"["===t.text?(e={type:bn.MemberExpression,object:e,property:this.expression(),computed:!0},this.consume("]")):"."===t.text?e={type:bn.MemberExpression,object:e,property:this.identifier(),computed:!1}:this.throwError("IMPOSSIBLE");return e},filter:function(e){for(var t=[e],e={type:bn.CallExpression,callee:this.identifier(),arguments:t,filter:!0};this.expect(":");)t.push(this.expression());return e},parseArguments:function(){var e=[];if(")"!==this.peekToken().text)for(;e.push(this.expression()),this.expect(","););return e},identifier:function(){var e=this.consume();return e.identifier||this.throwError("is not a valid identifier",e),{type:bn.Identifier,name:e.text}},constant:function(){return{type:bn.Literal,value:this.consume().value}},arrayDeclaration:function(){var e=[];if("]"!==this.peekToken().text)for(;!this.peek("]")&&(e.push(this.expression()),this.expect(",")););return this.consume("]"),{type:bn.ArrayExpression,elements:e}},object:function(){var e,t=[];if("}"!==this.peekToken().text)for(;!this.peek("}")&&(e={type:bn.Property,kind:"init"},this.peek().constant?(e.key=this.constant(),e.computed=!1,this.consume(":"),e.value=this.expression()):this.peek().identifier?(e.key=this.identifier(),e.computed=!1,this.peek(":")?(this.consume(":"),e.value=this.expression()):e.value=e.key):this.peek("[")?(this.consume("["),e.key=this.expression(),this.consume("]"),e.computed=!0,this.consume(":"),e.value=this.expression()):this.throwError("invalid key",this.peek()),t.push(e),this.expect(",")););return this.consume("}"),{type:bn.ObjectExpression,properties:t}},throwError:function(e,t){throw rn("syntax","Syntax Error: Token '{0}' {1} at column {2} of the expression [{3}] starting at [{4}].",t.text,e,t.index+1,this.text,this.text.substring(t.index))},consume:function(e){if(0===this.tokens.length)throw rn("ueoe","Unexpected end of expression: {0}",this.text);var t=this.expect(e);return t||this.throwError("is unexpected, expecting ["+e+"]",this.peek()),t},peekToken:function(){if(0===this.tokens.length)throw rn("ueoe","Unexpected end of expression: {0}",this.text);return this.tokens[0]},peek:function(e,t,a,n){return this.peekAhead(0,e,t,a,n)},peekAhead:function(e,t,a,n,i){if(this.tokens.length>e){var s=this.tokens[e],e=s.text;if(e===t||e===a||e===n||e===i||!t&&!a&&!n&&!i)return s}return!1},expect:function(e,t,a,n){n=this.peek(e,t,a,n);return!!n&&(this.tokens.shift(),n)},selfReferential:{this:{type:bn.ThisExpression},$locals:{type:bn.LocalsExpression}}},Mn.prototype={compile:function(e,t){var i=this,a=this.astBuilder.ast(e);this.state={nextId:0,filters:{},expensiveChecks:t,fn:{vars:[],body:[],own:{}},assign:{vars:[],body:[],own:{}},inputs:[]},xn(a,i.$filter);var n="";this.stage="assign",(t=In(a))&&(this.state.computing="assign",s=this.nextId(),this.recurse(t,s),this.return_(s),n="fn.assign="+this.generateFunction("assign","s,v,l"));var s=_n(a.body);i.stage="inputs",ge(s,function(e,t){var a="fn"+t;i.state[a]={vars:[],body:[],own:{}},i.state.computing=a;var n=i.nextId();i.recurse(e,n),i.return_(n),i.state.inputs.push(a),e.watchId=t}),this.state.computing="fn",this.stage="main",this.recurse(a);n='"'+this.USE+" "+this.STRICT+'";\n'+this.filterPrefix()+"var fn="+this.generateFunction("fn","s,l,a,i")+n+this.watchFns()+"return fn;",e=new Function("$filter","ensureSafeMemberName","ensureSafeObject","ensureSafeFunction","getStringValue","ensureSafeAssignContext","ifDefined","plus","text",n)(this.$filter,ln,un,gn,cn,fn,wn,$n,e);return this.state=this.stage=void 0,e.literal=Cn(a),e.constant=An(a),e},USE:"use",STRICT:"strict",watchFns:function(){var t=[],e=this.state.inputs,a=this;return ge(e,function(e){t.push("var "+e+"="+a.generateFunction(e,"s"))}),e.length&&t.push("fn.inputs=["+e.join(",")+"];"),t.join("")},generateFunction:function(e,t){return"function("+t+"){"+this.varsPrefix(e)+this.body(e)+"};"},filterPrefix:function(){var a=[],n=this;return ge(this.state.filters,function(e,t){a.push(e+"=$filter("+n.escape(t)+")")}),a.length?"var "+a.join(",")+";":""},varsPrefix:function(e){return this.state[e].vars.length?"var "+this.state[e].vars.join(",")+";":""},body:function(e){return this.state[e].body.join("")},recurse:function(a,t,e,n,i,s){var o,r,l,c,u,d=this;if(n=n||N,!s&&B(a.watchId))return t=t||this.nextId(),void this.if_("i",this.lazyAssign(t,this.computedMember("i",a.watchId)),this.lazyRecurse(a,t,e,n,i,!0));switch(a.type){case bn.Program:ge(a.body,function(e,t){d.recurse(e.expression,void 0,void 0,function(e){r=e}),t!==a.body.length-1?d.current().body.push(r,";"):d.return_(r)});break;case bn.Literal:c=this.escape(a.value),this.assign(t,c),n(c);break;case bn.UnaryExpression:this.recurse(a.argument,void 0,void 0,function(e){r=e}),c=a.operator+"("+this.ifDefined(r,0)+")",this.assign(t,c),n(c);break;case bn.BinaryExpression:this.recurse(a.left,void 0,void 0,function(e){o=e}),this.recurse(a.right,void 0,void 0,function(e){r=e}),c="+"===a.operator?this.plus(o,r):"-"===a.operator?this.ifDefined(o,0)+a.operator+this.ifDefined(r,0):"("+o+")"+a.operator+"("+r+")",this.assign(t,c),n(c);break;case bn.LogicalExpression:t=t||this.nextId(),d.recurse(a.left,t),d.if_("&&"===a.operator?t:d.not(t),d.lazyRecurse(a.right,t)),n(t);break;case bn.ConditionalExpression:t=t||this.nextId(),d.recurse(a.test,t),d.if_(t,d.lazyRecurse(a.alternate,t),d.lazyRecurse(a.consequent,t)),n(t);break;case bn.Identifier:t=t||this.nextId(),e&&(e.context="inputs"===d.stage?"s":this.assign(this.nextId(),this.getHasOwnProperty("l",a.name)+"?l:s"),e.computed=!1,e.name=a.name),ln(a.name),d.if_("inputs"===d.stage||d.not(d.getHasOwnProperty("l",a.name)),function(){d.if_("inputs"===d.stage||"s",function(){i&&1!==i&&d.if_(d.not(d.nonComputedMember("s",a.name)),d.lazyAssign(d.nonComputedMember("s",a.name),"{}")),d.assign(t,d.nonComputedMember("s",a.name))})},t&&d.lazyAssign(t,d.nonComputedMember("l",a.name))),(d.state.expensiveChecks||Pn(a.name))&&d.addEnsureSafeObject(t),n(t);break;case bn.MemberExpression:o=e&&(e.context=this.nextId())||this.nextId(),t=t||this.nextId(),d.recurse(a.object,o,void 0,function(){d.if_(d.notNull(o),function(){i&&1!==i&&d.addEnsureSafeAssignContext(o),a.computed?(r=d.nextId(),d.recurse(a.property,r),d.getStringValue(r),d.addEnsureSafeMemberName(r),i&&1!==i&&d.if_(d.not(d.computedMember(o,r)),d.lazyAssign(d.computedMember(o,r),"{}")),c=d.ensureSafeObject(d.computedMember(o,r)),d.assign(t,c),e&&(e.computed=!0,e.name=r)):(ln(a.property.name),i&&1!==i&&d.if_(d.not(d.nonComputedMember(o,a.property.name)),d.lazyAssign(d.nonComputedMember(o,a.property.name),"{}")),c=d.nonComputedMember(o,a.property.name),(d.state.expensiveChecks||Pn(a.property.name))&&(c=d.ensureSafeObject(c)),d.assign(t,c),e&&(e.computed=!1,e.name=a.property.name))},function(){d.assign(t,"undefined")}),n(t)},!!i);break;case bn.CallExpression:t=t||this.nextId(),a.filter?(r=d.filter(a.callee.name),l=[],ge(a.arguments,function(e){var t=d.nextId();d.recurse(e,t),l.push(t)}),c=r+"("+l.join(",")+")",d.assign(t,c),n(t)):(r=d.nextId(),l=[],d.recurse(a.callee,r,o={},function(){d.if_(d.notNull(r),function(){d.addEnsureSafeFunction(r),ge(a.arguments,function(e){d.recurse(e,d.nextId(),void 0,function(e){l.push(d.ensureSafeObject(e))})}),c=o.name?(d.state.expensiveChecks||d.addEnsureSafeObject(o.context),d.member(o.context,o.name,o.computed)+"("+l.join(",")+")"):r+"("+l.join(",")+")",c=d.ensureSafeObject(c),d.assign(t,c)},function(){d.assign(t,"undefined")}),n(t)}));break;case bn.AssignmentExpression:if(r=this.nextId(),o={},!Sn(a.left))throw rn("lval","Trying to assign a value to a non l-value");this.recurse(a.left,void 0,o,function(){d.if_(d.notNull(o.context),function(){d.recurse(a.right,r),d.addEnsureSafeObject(d.member(o.context,o.name,o.computed)),d.addEnsureSafeAssignContext(o.context),c=d.member(o.context,o.name,o.computed)+a.operator+r,d.assign(t,c),n(t||c)})},1);break;case bn.ArrayExpression:l=[],ge(a.elements,function(e){d.recurse(e,d.nextId(),void 0,function(e){l.push(e)})}),c="["+l.join(",")+"]",this.assign(t,c),n(c);break;case bn.ObjectExpression:u=!(l=[]),ge(a.properties,function(e){e.computed&&(u=!0)}),u?(t=t||this.nextId(),this.assign(t,"{}"),ge(a.properties,function(e){e.computed?(o=d.nextId(),d.recurse(e.key,o)):o=e.key.type===bn.Identifier?e.key.name:""+e.key.value,r=d.nextId(),d.recurse(e.value,r),d.assign(d.member(t,o,e.computed),r)})):(ge(a.properties,function(t){d.recurse(t.value,a.constant?void 0:d.nextId(),void 0,function(e){l.push(d.escape(t.key.type===bn.Identifier?t.key.name:""+t.key.value)+":"+e)})}),c="{"+l.join(",")+"}",this.assign(t,c)),n(t||c);break;case bn.ThisExpression:this.assign(t,"s"),n("s");break;case bn.LocalsExpression:this.assign(t,"l"),n("l");break;case bn.NGValueParameter:this.assign(t,"v"),n("v")}},getHasOwnProperty:function(e,t){var a=e+"."+t,n=this.current().own;return n.hasOwnProperty(a)||(n[a]=this.nextId(!1,e+"&&("+this.escape(t)+" in "+e+")")),n[a]},assign:function(e,t){if(e)return this.current().body.push(e,"=",t,";"),e},filter:function(e){return this.state.filters.hasOwnProperty(e)||(this.state.filters[e]=this.nextId(!0)),this.state.filters[e]},ifDefined:function(e,t){return"ifDefined("+e+","+this.escape(t)+")"},plus:function(e,t){return"plus("+e+","+t+")"},return_:function(e){this.current().body.push("return ",e,";")},if_:function(e,t,a){var n;!0===e?t():((n=this.current().body).push("if(",e,"){"),t(),n.push("}"),a&&(n.push("else{"),a(),n.push("}")))},not:function(e){return"!("+e+")"},notNull:function(e){return e+"!=null"},nonComputedMember:function(e,t){return/[$_a-zA-Z][$_a-zA-Z0-9]*/.test(t)?e+"."+t:e+'["'+t.replace(/[^$_a-zA-Z0-9]/g,this.stringEscapeFn)+'"]'},computedMember:function(e,t){return e+"["+t+"]"},member:function(e,t,a){return a?this.computedMember(e,t):this.nonComputedMember(e,t)},addEnsureSafeObject:function(e){this.current().body.push(this.ensureSafeObject(e),";")},addEnsureSafeMemberName:function(e){this.current().body.push(this.ensureSafeMemberName(e),";")},addEnsureSafeFunction:function(e){this.current().body.push(this.ensureSafeFunction(e),";")},addEnsureSafeAssignContext:function(e){this.current().body.push(this.ensureSafeAssignContext(e),";")},ensureSafeObject:function(e){return"ensureSafeObject("+e+",text)"},ensureSafeMemberName:function(e){return"ensureSafeMemberName("+e+",text)"},ensureSafeFunction:function(e){return"ensureSafeFunction("+e+",text)"},getStringValue:function(e){this.assign(e,"getStringValue("+e+")")},ensureSafeAssignContext:function(e){return"ensureSafeAssignContext("+e+",text)"},lazyRecurse:function(e,t,a,n,i,s){var o=this;return function(){o.recurse(e,t,a,n,i,s)}},lazyAssign:function(e,t){var a=this;return function(){a.assign(e,t)}},stringEscapeRegex:/[^ a-zA-Z0-9]/g,stringEscapeFn:function(e){return"\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4)},escape:function(e){if(R(e))return"'"+e.replace(this.stringEscapeRegex,this.stringEscapeFn)+"'";if(_(e))return e.toString();if(!0===e)return"true";if(!1===e)return"false";if(null===e)return"null";if(void 0===e)return"undefined";throw rn("esc","IMPOSSIBLE")},nextId:function(e,t){var a="v"+this.state.nextId++;return e||this.current().vars.push(a+(t?"="+t:"")),a},current:function(){return this.state[this.state.computing]}},Dn.prototype={compile:function(e,t){var n,i=this,a=this.astBuilder.ast(e);this.expression=e,this.expensiveChecks=t,xn(a,i.$filter),(t=In(a))&&(n=this.recurse(t));var s,t=_n(a.body);t&&(s=[],ge(t,function(e,t){var a=i.recurse(e);e.input=a,s.push(a),e.watchId=t}));var o=[];ge(a.body,function(e){o.push(i.recurse(e.expression))});t=0===a.body.length?N:1===a.body.length?o[0]:function(t,a){var n;return ge(o,function(e){n=e(t,a)}),n};return n&&(t.assign=function(e,t,a){return n(e,a,t)}),s&&(t.inputs=s),t.literal=Cn(a),t.constant=An(a),t},recurse:function(e,l,t){var s,c,u,d=this;if(e.input)return this.inputs(e.input,e.watchId);switch(e.type){case bn.Literal:return this.value(e.value,l);case bn.UnaryExpression:return c=this.recurse(e.argument),this["unary"+e.operator](c,l);case bn.BinaryExpression:case bn.LogicalExpression:return s=this.recurse(e.left),c=this.recurse(e.right),this["binary"+e.operator](s,c,l);case bn.ConditionalExpression:return this["ternary?:"](this.recurse(e.test),this.recurse(e.alternate),this.recurse(e.consequent),l);case bn.Identifier:return ln(e.name,d.expression),d.identifier(e.name,d.expensiveChecks||Pn(e.name),l,t,d.expression);case bn.MemberExpression:return s=this.recurse(e.object,!1,!!t),e.computed||(ln(e.property.name,d.expression),c=e.property.name),e.computed&&(c=this.recurse(e.property)),e.computed?this.computedMember(s,c,l,t,d.expression):this.nonComputedMember(s,c,d.expensiveChecks,l,t,d.expression);case bn.CallExpression:return u=[],ge(e.arguments,function(e){u.push(d.recurse(e))}),e.filter&&(c=this.$filter(e.callee.name)),e.filter||(c=this.recurse(e.callee,!0)),e.filter?function(e,t,a,n){for(var i=[],s=0;s<u.length;++s)i.push(u[s](e,t,a,n));var o=c.apply(void 0,i,n);return l?{context:void 0,name:void 0,value:o}:o}:function(e,t,a,n){var i,s=c(e,t,a,n);if(null!=s.value){un(s.context,d.expression),gn(s.value,d.expression);for(var o=[],r=0;r<u.length;++r)o.push(un(u[r](e,t,a,n),d.expression));i=un(s.value.apply(s.context,o),d.expression)}return l?{value:i}:i};case bn.AssignmentExpression:return s=this.recurse(e.left,!0,1),c=this.recurse(e.right),function(e,t,a,n){var i=s(e,t,a,n),n=c(e,t,a,n);return un(i.value,d.expression),fn(i.context),i.context[i.name]=n,l?{value:n}:n};case bn.ArrayExpression:return u=[],ge(e.elements,function(e){u.push(d.recurse(e))}),function(e,t,a,n){for(var i=[],s=0;s<u.length;++s)i.push(u[s](e,t,a,n));return l?{value:i}:i};case bn.ObjectExpression:return u=[],ge(e.properties,function(e){e.computed?u.push({key:d.recurse(e.key),computed:!0,value:d.recurse(e.value)}):u.push({key:e.key.type===bn.Identifier?e.key.name:""+e.key.value,computed:!1,value:d.recurse(e.value)})}),function(e,t,a,n){for(var i={},s=0;s<u.length;++s)u[s].computed?i[u[s].key(e,t,a,n)]=u[s].value(e,t,a,n):i[u[s].key]=u[s].value(e,t,a,n);return l?{value:i}:i};case bn.ThisExpression:return function(e){return l?{value:e}:e};case bn.LocalsExpression:return function(e,t){return l?{value:t}:t};case bn.NGValueParameter:return function(e,t,a){return l?{value:a}:a}}},"unary+":function(i,s){return function(e,t,a,n){n=B(n=i(e,t,a,n))?+n:0;return s?{value:n}:n}},"unary-":function(i,s){return function(e,t,a,n){n=B(n=i(e,t,a,n))?-n:0;return s?{value:n}:n}},"unary!":function(i,s){return function(e,t,a,n){n=!i(e,t,a,n);return s?{value:n}:n}},"binary+":function(i,s,o){return function(e,t,a,n){n=$n(i(e,t,a,n),s(e,t,a,n));return o?{value:n}:n}},"binary-":function(s,o,r){return function(e,t,a,n){var i=s(e,t,a,n),n=o(e,t,a,n),n=(B(i)?i:0)-(B(n)?n:0);return r?{value:n}:n}},"binary*":function(i,s,o){return function(e,t,a,n){n=i(e,t,a,n)*s(e,t,a,n);return o?{value:n}:n}},"binary/":function(i,s,o){return function(e,t,a,n){n=i(e,t,a,n)/s(e,t,a,n);return o?{value:n}:n}},"binary%":function(i,s,o){return function(e,t,a,n){n=i(e,t,a,n)%s(e,t,a,n);return o?{value:n}:n}},"binary===":function(i,s,o){return function(e,t,a,n){n=i(e,t,a,n)===s(e,t,a,n);return o?{value:n}:n}},"binary!==":function(i,s,o){return function(e,t,a,n){n=i(e,t,a,n)!==s(e,t,a,n);return o?{value:n}:n}},"binary==":function(i,s,o){return function(e,t,a,n){n=i(e,t,a,n)==s(e,t,a,n);return o?{value:n}:n}},"binary!=":function(i,s,o){return function(e,t,a,n){n=i(e,t,a,n)!=s(e,t,a,n);return o?{value:n}:n}},"binary<":function(i,s,o){return function(e,t,a,n){n=i(e,t,a,n)<s(e,t,a,n);return o?{value:n}:n}},"binary>":function(i,s,o){return function(e,t,a,n){n=i(e,t,a,n)>s(e,t,a,n);return o?{value:n}:n}},"binary<=":function(i,s,o){return function(e,t,a,n){n=i(e,t,a,n)<=s(e,t,a,n);return o?{value:n}:n}},"binary>=":function(i,s,o){return function(e,t,a,n){n=i(e,t,a,n)>=s(e,t,a,n);return o?{value:n}:n}},"binary&&":function(i,s,o){return function(e,t,a,n){n=i(e,t,a,n)&&s(e,t,a,n);return o?{value:n}:n}},"binary||":function(i,s,o){return function(e,t,a,n){n=i(e,t,a,n)||s(e,t,a,n);return o?{value:n}:n}},"ternary?:":function(i,s,o,r){return function(e,t,a,n){n=(i(e,t,a,n)?s:o)(e,t,a,n);return r?{value:n}:n}},value:function(e,t){return function(){return t?{context:void 0,name:void 0,value:e}:e}},identifier:function(i,s,o,r,l){return function(e,t,a,n){t=t&&i in t?t:e;r&&1!==r&&t&&!t[i]&&(t[i]={});e=t?t[i]:void 0;return s&&un(e,l),o?{context:t,name:i,value:e}:e}},computedMember:function(r,l,c,u,d){return function(e,t,a,n){var i,s,o=r(e,t,a,n);return null!=o&&(i=l(e,t,a,n),ln(i+="",d),u&&1!==u&&(fn(o),o&&!o[i]&&(o[i]={})),un(s=o[i],d)),c?{context:o,name:i,value:s}:s}},nonComputedMember:function(i,s,o,r,l,c){return function(e,t,a,n){a=i(e,t,a,n);l&&1!==l&&(fn(a),a&&!a[s]&&(a[s]={}));n=null!=a?a[s]:void 0;return(o||Pn(s))&&un(n,c),r?{context:a,name:s,value:n}:n}},inputs:function(i,s){return function(e,t,a,n){return n?n[s]:i(e,t,a)}}};var Tn=function(e,t,a){this.lexer=e,this.$filter=t,this.options=a,this.ast=new bn(e,a),this.astCompiler=new(a.csp?Dn:Mn)(this.ast,t)};function Pn(e){return"constructor"==e}Tn.prototype={constructor:Tn,parse:function(e){return this.astCompiler.compile(e,this.options.expensiveChecks)}};var En=Object.prototype.valueOf;function jn(e){return we(e.valueOf)?e.valueOf():En.call(e)}function Ln(){var a,n,b=Ee(),w=Ee(),i={true:!0,false:!1,null:null,undefined:void 0};this.addLiteral=function(e,t){i[e]=t},this.setIdentifierFns=function(e,t){return a=e,n=t,this},this.$get=["$filter",function(c){var e=z().noUnsafeEval,u={csp:e,expensiveChecks:!1,literals:Y(i),isIdentifierStart:we(a)&&a,isIdentifierContinue:we(n)&&n},d={csp:e,expensiveChecks:!0,literals:Y(i),isIdentifierStart:we(a)&&a,isIdentifierContinue:we(n)&&n},p=!1;return t.$$runningExpensiveChecks=function(){return p},t;function t(e,t,a){var n;switch(a=a||p,typeof e){case"string":e=e.trim();var i,s,o,r,l=a?w:b;return(r=l[i=e])||(":"===e.charAt(0)&&":"===e.charAt(1)&&(n=!0,e=e.substring(2)),o=new yn(s=a?d:u),(r=new Tn(o,c,s).parse(e)).constant?r.$$watchDelegate=v:n?r.$$watchDelegate=r.literal?h:f:r.inputs&&(r.$$watchDelegate=g),a&&(r=function e(s){if(!s)return s;a.$$watchDelegate=s.$$watchDelegate;a.assign=e(s.assign);a.constant=s.constant;a.literal=s.literal;for(var t=0;s.inputs&&t<s.inputs.length;++t)s.inputs[t]=e(s.inputs[t]);a.inputs=s.inputs;return a;function a(e,t,a,n){var i=p;p=!0;try{return s(e,t,a,n)}finally{p=i}}}(r)),l[i]=r),y(r,t);case"function":return y(e,t);default:return y(N,t)}}function m(e,t){return null==e||null==t?e===t:("object"!=typeof e||"object"!=typeof(e=jn(e)))&&(e===t||e!=e&&t!=t)}function g(e,t,a,s,n){var o;if(1===(r=s.inputs).length){var i=m,r=r[0];return e.$watch(function(e){var t=r(e);return m(t,i)||(o=s(e,void 0,void 0,[t]),i=t&&jn(t)),o},t,a,n)}for(var l=[],c=[],u=0,d=r.length;u<d;u++)l[u]=m,c[u]=null;return e.$watch(function(e){for(var t=!1,a=0,n=r.length;a<n;a++){var i=r[a](e);(t=t||!m(i,l[a]))&&(c[a]=i,l[a]=i&&jn(i))}return o=t?s(e,void 0,void 0,c):o},t,a,n)}function f(e,n,t,a){var i,s;return i=e.$watch(function(e){return a(e)},function(e,t,a){s=e,we(n)&&n.apply(this,arguments),B(e)&&a.$$postDigest(function(){B(s)&&i()})},t)}function h(e,n,t,a){var i,s;return i=e.$watch(function(e){return a(e)},function(e,t,a){s=e,we(n)&&n.call(this,e,t,a),o(e)&&a.$$postDigest(function(){o(s)&&i()})},t);function o(e){var t=!0;return ge(e,function(e){B(e)||(t=!1)}),t}}function v(e,t,a,n){var i;return i=e.$watch(function(e){return i(),n(e)},t,a)}function y(i,s){if(!s)return i;var e=i.$$watchDelegate,o=!1,e=e!==h&&e!==f?function(e,t,a,n){n=o&&n?n[0]:i(e,t,a,n);return s(n,e,t)}:function(e,t,a,n){n=i(e,t,a,n),t=s(n,e,t);return B(n)?t:n};return i.$$watchDelegate&&i.$$watchDelegate!==g?e.$$watchDelegate=i.$$watchDelegate:s.$stateful||(e.$$watchDelegate=g,o=!i.inputs,e.inputs=i.inputs||[i]),e}}]}function On(){this.$get=["$rootScope","$exceptionHandler",function(t,e){return Nn(function(e){t.$evalAsync(e)},e)}]}function Un(){this.$get=["$browser","$exceptionHandler",function(t,e){return Nn(function(e){t.defer(e)},e)}]}function Nn(t,o){var a=w("$q",TypeError);function e(){this.$$state={status:0}}function s(t,a){return function(e){a.call(t,e)}}function r(e){!e.processScheduled&&e.pending&&(e.processScheduled=!0,t(function(){!function(e){var t,a,n=e.pending;e.processScheduled=!1,e.pending=void 0;for(var i=0,s=n.length;i<s;++i){a=n[i][0],t=n[i][e.status];try{we(t)?a.resolve(t(e.value)):1===e.status?a.resolve(e.value):a.reject(e.value)}catch(e){a.reject(e),o(e)}}}(e)}))}function l(){this.promise=new e}fe(e.prototype,{then:function(e,t,a){if(ve(e)&&ve(t)&&ve(a))return this;var n=new l;return this.$$state.pending=this.$$state.pending||[],this.$$state.pending.push([n,e,t,a]),0<this.$$state.status&&r(this.$$state),n.promise},catch:function(e){return this.then(null,e)},finally:function(t,e){return this.then(function(e){return n(e,!0,t)},function(e){return n(e,!1,t)},e)}}),fe(l.prototype,{resolve:function(e){this.promise.$$state.status||(e===this.promise?this.$$reject(a("qcycle","Expected promise to be resolved with value other than itself '{0}'",e)):this.$$resolve(e))},$$resolve:function(e){var t,a=this,n=!1;try{(ye(e)||we(e))&&(t=e&&e.then),we(t)?(this.promise.$$state.status=-1,t.call(e,function(e){n||(n=!0,a.$$resolve(e))},i,s(this,this.notify))):(this.promise.$$state.value=e,this.promise.$$state.status=1,r(this.promise.$$state))}catch(e){i(e),o(e)}function i(e){n||(n=!0,a.$$reject(e))}},reject:function(e){this.promise.$$state.status||this.$$reject(e)},$$reject:function(e){this.promise.$$state.value=e,this.promise.$$state.status=2,r(this.promise.$$state)},notify:function(i){var s=this.promise.$$state.pending;this.promise.$$state.status<=0&&s&&s.length&&t(function(){for(var e,t,a=0,n=s.length;a<n;a++){t=s[a][0],e=s[a][3];try{t.notify(we(e)?e(i):i)}catch(e){o(e)}}})}});function i(e,t){var a=new l;return t?a.resolve(e):a.reject(e),a.promise}function c(e,t,a,n){var i=new l;return i.resolve(e),i.promise.then(t,a,n)}var n=function(e,t,a){var n=null;try{we(a)&&(n=a())}catch(e){return i(e,!1)}return D(n)?n.then(function(){return i(e,t)},function(e){return i(e,!1)}):i(e,t)},u=c;function d(e){if(!we(e))throw a("norslvr","Expected resolverFn, got '{0}'",e);var t=new l;return e(function(e){t.resolve(e)},function(e){t.reject(e)}),t.promise}return d.prototype=e.prototype,d.defer=function(){var e=new l;return e.resolve=s(e,e.resolve),e.reject=s(e,e.reject),e.notify=s(e,e.notify),e},d.reject=function(e){var t=new l;return t.reject(e),t.promise},d.when=c,d.resolve=u,d.all=function(e){var a=new l,n=0,i=be(e)?[]:{};return ge(e,function(e,t){n++,c(e).then(function(e){i.hasOwnProperty(t)||(i[t]=e,--n||a.resolve(i))},function(e){i.hasOwnProperty(t)||a.reject(e)})}),0===n&&a.resolve(i),a.promise},d}function Bn(){this.$get=["$window","$timeout",function(e,a){var n=e.requestAnimationFrame||e.webkitRequestAnimationFrame,i=e.cancelAnimationFrame||e.webkitCancelAnimationFrame||e.webkitCancelRequestAnimationFrame,t=!!n,e=t?function(e){var t=n(e);return function(){i(t)}}:function(e){var t=a(e,16.66,!1);return function(){a.cancel(t)}};return e.supported=t,e}]}function Rn(){var _=10,S=w("$rootScope"),I=null,C=null;this.digestTtl=function(e){return _=arguments.length?e:_},this.$get=["$exceptionHandler","$parse","$browser",function(m,g,f){function i(e){e.currentScope.$$destroyed=!0}function s(){this.$id=p(),this.$$phase=this.$parent=this.$$watchers=this.$$nextSibling=this.$$prevSibling=this.$$childHead=this.$$childTail=null,(this.$root=this).$$destroyed=!1,this.$$listeners={},this.$$listenerCount={},this.$$watchersCount=0,this.$$isolateBindings=null}s.prototype={constructor:s,$new:function(e,t){var a;function n(){this.$$watchers=this.$$nextSibling=this.$$childHead=this.$$childTail=null,this.$$listeners={},this.$$listenerCount={},this.$$watchersCount=0,this.$id=p(),this.$$ChildScope=null}return t=t||this,e?(a=new s).$root=this.$root:(this.$$ChildScope||(this.$$ChildScope=(n.prototype=this,n)),a=new this.$$ChildScope),a.$parent=t,a.$$prevSibling=t.$$childTail,t.$$childHead?(t.$$childTail.$$nextSibling=a,t.$$childTail=a):t.$$childHead=t.$$childTail=a,!e&&t==this||a.$on("$destroy",i),a},$watch:function(e,t,a,n){var i=g(e);if(i.$$watchDelegate)return i.$$watchDelegate(this,t,a,i,e);var s=this,o=s.$$watchers,r={fn:t,last:k,get:i,exp:n||e,eq:!!a};return I=null,we(t)||(r.fn=N),(o=o||(s.$$watchers=[])).unshift(r),l(this,1),function(){0<=V(o,r)&&l(s,-1),I=null}},$watchGroup:function(e,n){var i=new Array(e.length),s=new Array(e.length),t=[],o=this,r=!1,a=!0;if(e.length)return 1===e.length?this.$watch(e[0],function(e,t,a){s[0]=e,i[0]=t,n(s,e===t?s:i,a)}):(ge(e,function(e,a){e=o.$watch(e,function(e,t){s[a]=e,i[a]=t,r||(r=!0,o.$evalAsync(c))});t.push(e)}),function(){for(;t.length;)t.shift()()});var l=!0;return o.$evalAsync(function(){l&&n(s,s,o)}),function(){l=!1};function c(){r=!1,a?(a=!1,n(s,s,o)):n(s,i,o)}},$watchCollection:function(e,a){t.$stateful=!0;var o,r,n,i=this,s=1<a.length,l=0,e=g(e,t),c=[],u={},d=!0,p=0;function t(e){var t,a,n,i;if(!ve(o=e)){if(ye(o))if(j(o)){r!==c&&(p=(r=c).length=0,l++),t=o.length,p!==t&&(l++,r.length=p=t);for(var s=0;s<t;s++)i=r[s],n=o[s],i!=i&&n!=n||i===n||(l++,r[s]=n)}else{for(a in r!==u&&(r=u={},p=0,l++),t=0,o)L.call(o,a)&&(t++,n=o[a],i=r[a],a in r?i!=i&&n!=n||i===n||(l++,r[a]=n):(p++,r[a]=n,l++));if(t<p)for(a in l++,r)L.call(o,a)||(p--,delete r[a])}else r!==o&&(r=o,l++);return l}}return this.$watch(e,function(){if(d?(d=!1,a(o,o,i)):a(o,n,i),s)if(ye(o))if(j(o)){n=new Array(o.length);for(var e=0;e<o.length;e++)n[e]=o[e]}else for(var t in n={},o)L.call(o,t)&&(n[t]=o[t]);else n=o})},$digest:function(){var e,t,a,n,i,s,o,r,l=_,c=[];w("$digest"),f.$$checkUrlChange(),this===h&&null!==C&&(f.defer.cancel(C),x()),I=null;do{for(var u=!1,d=this,p=0;p<v.length;p++){try{(r=v[p]).scope.$eval(r.expression,r.locals)}catch(e){m(e)}I=null}v.length=0;e:do{if(n=d.$$watchers)for(i=n.length;i--;)try{if(e=n[i])if((t=(0,e.get)(d))===(a=e.last)||(e.eq?_e(t,a):"number"==typeof t&&"number"==typeof a&&isNaN(t)&&isNaN(a))){if(e===I){u=!1;break e}}else u=!0,(I=e).last=e.eq?Y(t,null):t,(0,e.fn)(t,a===k?t:a,d),l<5&&(c[o=4-l]||(c[o]=[]),c[o].push({msg:we(e.exp)?"fn: "+(e.exp.name||e.exp.toString()):e.exp,newVal:t,oldVal:a}))}catch(e){m(e)}if(!(s=d.$$watchersCount&&d.$$childHead||d!==this&&d.$$nextSibling))for(;d!==this&&!(s=d.$$nextSibling);)d=d.$parent}while(d=s);if((u||v.length)&&!l--)throw $(),S("infdig","{0} $digest() iterations reached. Aborting!\nWatchers fired in the last 5 iterations: {1}",_,c)}while(u||v.length);for($();b<y.length;)try{y[b++]()}catch(e){m(e)}y.length=b=0},$destroy:function(){if(!this.$$destroyed){var e,t=this.$parent;for(e in this.$broadcast("$destroy"),this.$$destroyed=!0,this===h&&f.$$applicationDestroyed(),l(this,-this.$$watchersCount),this.$$listenerCount)o(this,this.$$listenerCount[e],e);t&&t.$$childHead==this&&(t.$$childHead=this.$$nextSibling),t&&t.$$childTail==this&&(t.$$childTail=this.$$prevSibling),this.$$prevSibling&&(this.$$prevSibling.$$nextSibling=this.$$nextSibling),this.$$nextSibling&&(this.$$nextSibling.$$prevSibling=this.$$prevSibling),this.$destroy=this.$digest=this.$apply=this.$evalAsync=this.$applyAsync=N,this.$on=this.$watch=this.$watchGroup=function(){return N},this.$$listeners={},this.$$nextSibling=null,function e(t){9===U&&(t.$$childHead&&e(t.$$childHead),t.$$nextSibling&&e(t.$$nextSibling)),t.$parent=t.$$nextSibling=t.$$prevSibling=t.$$childHead=t.$$childTail=t.$root=t.$$watchers=null}(this)}},$eval:function(e,t){return g(e)(this,t)},$evalAsync:function(e,t){h.$$phase||v.length||f.defer(function(){v.length&&h.$digest()}),v.push({scope:this,expression:g(e),locals:t})},$$postDigest:function(e){y.push(e)},$apply:function(e){try{w("$apply");try{return this.$eval(e)}finally{$()}}catch(e){m(e)}finally{try{h.$digest()}catch(e){throw m(e),e}}},$applyAsync:function(e){var t=this;e&&a.push(function(){t.$eval(e)}),e=g(e),null===C&&(C=f.defer(function(){h.$apply(x)}))},$on:function(t,a){var n=this.$$listeners[t];n||(this.$$listeners[t]=n=[]),n.push(a);for(var e=this;e.$$listenerCount[t]||(e.$$listenerCount[t]=0),e.$$listenerCount[t]++,e=e.$parent;);var i=this;return function(){var e=n.indexOf(a);-1!==e&&(n[e]=null,o(i,1,t))}},$emit:function(e,t){var a,n,i,s=[],o=this,r=!1,l={name:e,targetScope:o,stopPropagation:function(){r=!0},preventDefault:function(){l.defaultPrevented=!0},defaultPrevented:!1},c=W([l],arguments,1);do{for(a=o.$$listeners[e]||s,l.currentScope=o,n=0,i=a.length;n<i;n++)if(a[n])try{a[n].apply(null,c)}catch(e){m(e)}else a.splice(n,1),n--,i--;if(r)return l.currentScope=null,l}while(o=o.$parent);return l.currentScope=null,l},$broadcast:function(e,t){var a=this,n=a,i=a,s={name:e,targetScope:a,preventDefault:function(){s.defaultPrevented=!0},defaultPrevented:!1};if(!a.$$listenerCount[e])return s;for(var o,r,l,c=W([s],arguments,1);n=i;){for(r=0,l=(o=(s.currentScope=n).$$listeners[e]||[]).length;r<l;r++)if(o[r])try{o[r].apply(null,c)}catch(e){m(e)}else o.splice(r,1),r--,l--;if(!(i=n.$$listenerCount[e]&&n.$$childHead||n!==a&&n.$$nextSibling))for(;n!==a&&!(i=n.$$nextSibling);)n=n.$parent}return s.currentScope=null,s}};var h=new s,v=h.$$asyncQueue=[],y=h.$$postDigestQueue=[],a=h.$$applyAsyncQueue=[],b=0;return h;function w(e){if(h.$$phase)throw S("inprog","{0} already in progress",h.$$phase);h.$$phase=e}function $(){h.$$phase=null}function l(e,t){for(;e.$$watchersCount+=t,e=e.$parent;);}function o(e,t,a){for(;e.$$listenerCount[a]-=t,0===e.$$listenerCount[a]&&delete e.$$listenerCount[a],e=e.$parent;);}function k(){}function x(){for(;a.length;)try{a.shift()()}catch(e){m(e)}C=null}}]}function qn(){var n=/^\s*(https?|ftp|mailto|tel|file):/,i=/^\s*((https?|ftp|file|blob):|data:image\/)/;this.aHrefSanitizationWhitelist=function(e){return B(e)?(n=e,this):n},this.imgSrcSanitizationWhitelist=function(e){return B(e)?(i=e,this):i},this.$get=function(){return function(e,t){var a=t?i:n,t=ei(e).href;return""===t||t.match(a)?e:"unsafe:"+t}}}var Vn=w("$sce"),Yn={HTML:"html",CSS:"css",URL:"url",RESOURCE_URL:"resourceUrl",JS:"js"};function Fn(e){var t=[];return B(e)&&ge(e,function(e){t.push(function(e){if("self"===e)return e;if(R(e)){if(-1<e.indexOf("***"))throw Vn("iwcard","Illegal sequence *** in string matcher. String: {0}",e);return e=P(e).replace("\\*\\*",".*").replace("\\*","[^:/.?&;]*"),new RegExp("^"+e+"$")}if(A(e))return new RegExp("^"+e.source+"$");throw Vn("imatcher",'Matchers may only be "self", string patterns or RegExp objects')}(e))}),t}function zn(){this.SCE_CONTEXTS=Yn;var o=["self"],r=[];this.resourceUrlWhitelist=function(e){return o=arguments.length?Fn(e):o},this.resourceUrlBlacklist=function(e){return r=arguments.length?Fn(e):r},this.$get=["$injector",function(e){var n=function(e){throw Vn("unsafe","Attempting to use an unsafe value in a safe context.")};function s(e,t){return"self"===e?ti(t):e.exec(t.href)}function t(e){function t(e){this.$$unwrapTrustedValue=function(){return e}}return(t.prototype=e?new e:t.prototype).valueOf=function(){return this.$$unwrapTrustedValue()},t.prototype.toString=function(){return this.$$unwrapTrustedValue().toString()},t}e.has("$sanitize")&&(n=e.get("$sanitize"));var a=t(),i={};return i[Yn.HTML]=t(a),i[Yn.CSS]=t(a),i[Yn.URL]=t(a),i[Yn.JS]=t(a),i[Yn.RESOURCE_URL]=t(i[Yn.URL]),{trustAs:function(e,t){var a=i.hasOwnProperty(e)?i[e]:null;if(!a)throw Vn("icontext","Attempted to trust a value in invalid context. Context: {0}; Value: {1}",e,t);if(null===t||ve(t)||""===t)return t;if("string"!=typeof t)throw Vn("itype","Attempted to trust a non-string value in a content requiring a string: Context: {0}",e);return new a(t)},getTrusted:function(e,t){if(null===t||ve(t)||""===t)return t;var a=i.hasOwnProperty(e)?i[e]:null;if(a&&t instanceof a)return t.$$unwrapTrustedValue();if(e===Yn.RESOURCE_URL){if(function(e){for(var t=ei(e.toString()),a=!1,n=0,i=o.length;n<i;n++)if(s(o[n],t)){a=!0;break}if(a)for(n=0,i=r.length;n<i;n++)if(s(r[n],t)){a=!1;break}return a}(t))return t;throw Vn("insecurl","Blocked loading resource from url not allowed by $sceDelegate policy. URL: {0}",t.toString())}if(e===Yn.HTML)return n(t);throw Vn("unsafe","Attempting to use an unsafe value in a safe context.")},valueOf:function(e){return e instanceof a?e.$$unwrapTrustedValue():e}}}]}function Hn(){var t=!0;this.enabled=function(e){return t=arguments.length?!!e:t},this.$get=["$parse","$sceDelegate",function(n,e){if(t&&U<8)throw Vn("iequirks","Strict Contextual Escaping does not support Internet Explorer version < 11 in quirks mode. You can fix this by adding the text <!doctype html> to the top of your HTML document. See http://docs.angularjs.org/api/ng.$sce for more information.");var i=F(Yn);i.isEnabled=function(){return t},i.trustAs=e.trustAs,i.getTrusted=e.getTrusted,i.valueOf=e.valueOf,t||(i.trustAs=i.getTrusted=function(e,t){return t},i.valueOf=b),i.parseAs=function(t,e){var a=n(e);return a.literal&&a.constant?a:n(e,function(e){return i.getTrusted(t,e)})};var a=i.parseAs,s=i.getTrusted,o=i.trustAs;return ge(Yn,function(t,e){e=O(e);i[Qe("parse_as_"+e)]=function(e){return a(t,e)},i[Qe("get_trusted_"+e)]=function(e){return s(t,e)},i[Qe("trust_as_"+e)]=function(e){return o(t,e)}}),i}]}function Wn(){this.$get=["$window","$document",function(e,t){var a,n={},i=!(e.chrome&&e.chrome.app&&e.chrome.app.runtime)&&e.history&&e.history.pushState,s=y((/android (\d+)/.exec(O((e.navigator||{}).userAgent))||[])[1]),o=/Boxee/i.test((e.navigator||{}).userAgent),r=t[0]||{},l=/^(Moz|webkit|ms)(?=[A-Z])/,c=r.body&&r.body.style,e=!1,t=!1;if(c){for(var u in c)if(u=l.exec(u)){a=(a=u[0])[0].toUpperCase()+a.substr(1);break}a=a||"WebkitOpacity"in c&&"webkit",e=!!("transition"in c||a+"Transition"in c),t=!!("animation"in c||a+"Animation"in c),!s||e&&t||(e=R(c.webkitTransition),t=R(c.webkitAnimation))}return{history:!(!i||s<4||o),hasEvent:function(e){return!("input"===e&&U<=11)&&(ve(n[e])&&(t=r.createElement("div"),n[e]="on"+e in t),n[e]);var t},csp:z(),vendorPrefix:a,transitions:e,animations:t,android:s}}]}var Gn=w("$compile");function Kn(){var l;this.httpOptions=function(e){return e?(l=e,this):l},this.$get=["$templateCache","$http","$q","$sce",function(n,i,s,o){function r(t,a){r.totalPendingRequests++,R(t)&&!ve(n.get(t))||(t=o.getTrustedResourceUrl(t));var e=i.defaults&&i.defaults.transformResponse;return be(e)?e=e.filter(function(e){return e!==Ta}):e===Ta&&(e=null),i.get(t,fe({cache:n,transformResponse:e},l)).finally(function(){r.totalPendingRequests--}).then(function(e){return n.put(t,e.data),e.data},function(e){if(a)return s.reject(e);throw Gn("tpload","Failed to load template: {0} (HTTP status: {1} {2})",t,e.status,e.statusText)})}return r.totalPendingRequests=0,r}]}function Qn(){this.$get=["$rootScope","$browser","$location",function(t,a,n){var e={findBindings:function(e,a,n){var e=e.getElementsByClassName("ng-binding"),i=[];return ge(e,function(t){var e=S.element(t).data("$binding");e&&ge(e,function(e){n?new RegExp("(^|\\s)"+P(a)+"(\\s|\\||$)").test(e)&&i.push(t):-1!=e.indexOf(a)&&i.push(t)})}),i},findModels:function(e,t,a){for(var n=["ng-","data-ng-","ng\\:"],i=0;i<n.length;++i){var s=e.querySelectorAll("["+n[i]+"model"+(a?"=":"*=")+'"'+t+'"]');if(s.length)return s}},getLocation:function(){return n.url()},setLocation:function(e){e!==n.url()&&(n.url(e),t.$digest())},whenStable:function(e){a.notifyWhenNoOutstandingRequests(e)}};return e}]}function Jn(){this.$get=["$rootScope","$browser","$q","$$q","$exceptionHandler",function(r,l,c,u,d){var p={};function e(e,t,a){we(e)||(a=t,t=e,e=N);var n=Se(arguments,3),i=B(a)&&!a,s=(i?u:c).defer(),o=s.promise,t=l.defer(function(){try{s.resolve(e.apply(null,n))}catch(e){s.reject(e),d(e)}finally{delete p[o.$$timeoutId]}i||r.$apply()},t);return o.$$timeoutId=t,p[t]=s,o}return e.cancel=function(e){return!!(e&&e.$$timeoutId in p)&&(p[e.$$timeoutId].reject("canceled"),delete p[e.$$timeoutId],l.defer.cancel(e.$$timeoutId))},e}]}var Zn=h.document.createElement("a"),Xn=ei(h.location.href);function ei(e){return U&&(Zn.setAttribute("href",e),e=Zn.href),Zn.setAttribute("href",e),{href:Zn.href,protocol:Zn.protocol?Zn.protocol.replace(/:$/,""):"",host:Zn.host,search:Zn.search?Zn.search.replace(/^\?/,""):"",hash:Zn.hash?Zn.hash.replace(/^#/,""):"",hostname:Zn.hostname,port:Zn.port,pathname:"/"===Zn.pathname.charAt(0)?Zn.pathname:"/"+Zn.pathname}}function ti(e){e=R(e)?ei(e):e;return e.protocol===Xn.protocol&&e.host===Xn.host}function ai(){this.$get=I(h)}function ni(e){var o=e[0]||{},r={},l="";function c(t){try{return decodeURIComponent(t)}catch(e){return t}}return function(){var e,t,a,n,i,s=o.cookie||"";if(s!==l)for(e=(l=s).split("; "),r={},a=0;a<e.length;a++)0<(n=(t=e[a]).indexOf("="))&&(i=c(t.substring(0,n)),ve(r[i])&&(r[i]=c(t.substring(n+1))));return r}}function ii(){this.$get=ni}function si(n){var i="Filter";function s(e,t){if(ye(e)){var a={};return ge(e,function(e,t){a[t]=s(t,e)}),a}return n.factory(e+i,t)}this.register=s,this.$get=["$injector",function(t){return function(e){return t.get(e+i)}}],s("currency",pi),s("date",_i),s("filter",oi),s("json",Si),s("limitTo",Ai),s("lowercase",Ii),s("number",mi),s("orderBy",Mi),s("uppercase",Ci)}function oi(){return function(e,t,a){if(!j(e)){if(null==e)return e;throw w("filter")("notarray","Expected array but received: {0}",e)}var n,i;switch(li(t)){case"function":n=t;break;case"boolean":case"null":case"number":case"string":i=!0;case"object":n=function(t,a,n){var i=ye(t)&&"$"in t;!0===a?a=_e:we(a)||(a=function(e,t){return!ve(e)&&(null===e||null===t?e===t:!(ye(t)||ye(e)&&!k(e))&&(e=O(""+e),t=O(""+t),-1!==e.indexOf(t)))});return function(e){return i&&!ye(e)?ri(e,t.$,a,!1):ri(e,t,a,n)}}(t,a,i);break;default:return e}return Array.prototype.filter.call(e,n)}}function ri(e,t,a,n,i){var s,o=li(e),r=li(t);if("string"===r&&"!"===t.charAt(0))return!ri(e,t.substring(1),a,n);if(be(e))return e.some(function(e){return ri(e,t,a,n)});switch(o){case"object":if(n){for(s in e)if("$"!==s.charAt(0)&&ri(e[s],t,a,!0))return!0;return!i&&ri(e,t,a,!1)}if("object"!==r)return a(e,t);for(s in t){var l=t[s];if(!we(l)&&!ve(l)){var c="$"===s;if(!ri(c?e:e[s],l,a,c,c))return!1}}return!0;case"function":return!1;default:return a(e,t)}}function li(e){return null===e?"null":typeof e}ni.$inject=["$document"],si.$inject=["$provide"];var ci=22,ui=".",di="0";function pi(e){var n=e.NUMBER_FORMATS;return function(e,t,a){return ve(t)&&(t=n.CURRENCY_SYM),ve(a)&&(a=n.PATTERNS[1].maxFrac),null==e?e:gi(e,n.PATTERNS[1],n.GROUP_SEP,n.DECIMAL_SEP,a).replace(/\u00A4/g,t)}}function mi(e){var a=e.NUMBER_FORMATS;return function(e,t){return null==e?e:gi(e,a.PATTERNS[0],a.GROUP_SEP,a.DECIMAL_SEP,t)}}function gi(e,t,a,n,i){if(!R(e)&&!_(e)||isNaN(e))return"";var s=!isFinite(e),o=!1,r=Math.abs(e)+"",l="";if(s)l="∞";else{(function(e,t,a,n){var i=e.d,s=i.length-e.i,o=(t=ve(t)?Math.min(Math.max(a,s),n):+t)+e.i,n=i[o];if(0<o){i.splice(Math.max(e.i,o));for(var r=o;r<i.length;r++)i[r]=0}else{s=Math.max(0,s),e.i=1,i.length=Math.max(1,o=t+1),i[0]=0;for(var l=1;l<o;l++)i[l]=0}if(5<=n)if(o-1<0){for(var c=0;o<c;c--)i.unshift(0),e.i++;i.unshift(1),e.i++}else i[o-1]++;for(;s<Math.max(0,t);s++)i.push(0);(n=i.reduceRight(function(e,t,a,n){return n[a]=(t+=e)%10,Math.floor(t/10)},0))&&(i.unshift(n),e.i++)})(r=function(e){var t,a,n,i,s,o=0;for(0<(n=(e=-1<(a=e.indexOf(ui))?e.replace(ui,""):e).search(/e/i))?(a<0&&(a=n),a+=+e.slice(n+1),e=e.substring(0,n)):a<0&&(a=e.length),n=0;e.charAt(n)==di;n++);if(n==(s=e.length))t=[0],a=1;else{for(s--;e.charAt(s)==di;)s--;for(a-=n,t=[],i=0;n<=s;n++,i++)t[i]=+e.charAt(n)}return ci<a&&(t=t.splice(0,ci-1),o=a-1,a=1),{d:t,e:o,i:a}}(r),i,t.minFrac,t.maxFrac);for(var c=r.d,u=r.i,i=r.e,r=[],o=c.reduce(function(e,t){return e&&!t},!0);u<0;)c.unshift(0),u++;0<u?r=c.splice(u,c.length):(r=c,c=[0]);var d=[];for(c.length>=t.lgSize&&d.unshift(c.splice(-t.lgSize,c.length).join(""));c.length>t.gSize;)d.unshift(c.splice(-t.gSize,c.length).join(""));c.length&&d.unshift(c.join("")),l=d.join(a),r.length&&(l+=n+r.join("")),i&&(l+="e+"+i)}return e<0&&!o?t.negPre+l+t.negSuf:t.posPre+l+t.posSuf}function fi(e,t,a,n){var i="";for((e<0||n&&e<=0)&&(n?e=1-e:(e=-e,i="-")),e=""+e;e.length<t;)e=di+e;return i+(e=a?e.substr(e.length-t):e)}function hi(t,a,n,i,s){return n=n||0,function(e){e=e["get"+t]();return(0<n||-n<e)&&(e+=n),fi(e=0===e&&-12==n?12:e,a,i,s)}}function vi(a,n,i){return function(e,t){e=e["get"+a]();return t[u((i?"STANDALONE":"")+(n?"SHORT":"")+a)][e]}}function yi(e){var t=new Date(e,0,1).getDay();return new Date(e,0,(t<=4?5:12)-t)}function bi(a){return function(e){var t=yi(e.getFullYear()),e=(e=e,new Date(e.getFullYear(),e.getMonth(),e.getDate()+(4-e.getDay())));return fi(1+Math.round((+e-+t)/6048e5),a)}}function wi(e,t){return e.getFullYear()<=0?t.ERAS[0]:t.ERAS[1]}pi.$inject=["$locale"];var $i={yyyy:hi("FullYear",4,0,!(mi.$inject=["$locale"]),!0),yy:hi("FullYear",2,0,!0,!0),y:hi("FullYear",1,0,!1,!0),MMMM:vi("Month"),MMM:vi("Month",!0),MM:hi("Month",2,1),M:hi("Month",1,1),LLLL:vi("Month",!1,!0),dd:hi("Date",2),d:hi("Date",1),HH:hi("Hours",2),H:hi("Hours",1),hh:hi("Hours",2,-12),h:hi("Hours",1,-12),mm:hi("Minutes",2),m:hi("Minutes",1),ss:hi("Seconds",2),s:hi("Seconds",1),sss:hi("Milliseconds",3),EEEE:vi("Day"),EEE:vi("Day",!0),a:function(e,t){return e.getHours()<12?t.AMPMS[0]:t.AMPMS[1]},Z:function(e,t,a){var n=-1*a,a=0<=n?"+":"";return a+=fi(Math[0<n?"floor":"ceil"](n/60),2)+fi(Math.abs(n%60),2)},ww:bi(2),w:bi(1),G:wi,GG:wi,GGG:wi,GGGG:function(e,t){return e.getFullYear()<=0?t.ERANAMES[0]:t.ERANAMES[1]}},ki=/((?:[^yMLdHhmsaZEwG']+)|(?:'(?:[^']|'')*')|(?:E+|y+|M+|L+|d+|H+|h+|m+|s+|a|Z|G+|w+))(.*)/,xi=/^\-?\d+$/;function _i(l){var c=/^(\d{4})-?(\d\d)-?(\d\d)(?:T(\d\d)(?::?(\d\d)(?::?(\d\d)(?:\.(\d+))?)?)?(Z|([+-])(\d\d):?(\d\d))?)?$/;return function(t,e,a){var n,i,s="",o=[];if(e=l.DATETIME_FORMATS[e=e||"mediumDate"]||e,!C(t=_(t=R(t)?(xi.test(t)?y:function(e){if(o=e.match(c)){var t=new Date(0),a=0,n=0,i=o[8]?t.setUTCFullYear:t.setFullYear,s=o[8]?t.setUTCHours:t.setHours;o[9]&&(a=y(o[9]+o[10]),n=y(o[9]+o[11])),i.call(t,y(o[1]),y(o[2])-1,y(o[3]));var i=y(o[4]||0)-a,a=y(o[5]||0)-n,n=y(o[6]||0),o=Math.round(1e3*parseFloat("0."+(o[7]||0)));return s.call(t,i,a,n,o),t}return e})(t):t)?new Date(t):t)||!isFinite(t.getTime()))return t;for(;e;)e=(i=ki.exec(e))?(o=W(o,i,1)).pop():(o.push(e),null);var r=t.getTimezoneOffset();return a&&(r=Z(a,r),t=X(t,a,!0)),ge(o,function(e){n=$i[e],s+=n?n(t,l.DATETIME_FORMATS,r):"''"===e?"'":e.replace(/(^'|'$)/g,"").replace(/''/g,"'")}),s}}function Si(){return function(e,t){return K(e,t=ve(t)?2:t)}}_i.$inject=["$locale"];var Ii=I(O),Ci=I(u);function Ai(){return function(e,t,a){return t=(Math.abs(Number(t))===1/0?Number:y)(t),isNaN(t)?e:(_(e)&&(e=e.toString()),be(e)||R(e)?(a=(a=!a||isNaN(a)?0:y(a))<0?Math.max(0,e.length+a):a,0<=t?e.slice(a,a+t):0===a?e.slice(t,e.length):e.slice(Math.max(0,a+t),a)):e)}}function Mi(o){return function(e,t,a){if(null==e)return e;if(!j(e))throw w("orderBy")("notarray","Expected array but received: {0}",e);0===(t=!be(t)?[t]:t).length&&(t=["+"]);var i,s=(i=(i=a)?-1:1,t.map(function(e){var t,a=1,n=b;return we(e)?n=e:R(e)&&("+"!=e.charAt(0)&&"-"!=e.charAt(0)||(a="-"==e.charAt(0)?-1:1,e=e.substring(1)),""!==e&&(n=o(e)).constant&&(t=n(),n=function(e){return e[t]})),{get:n,descending:a*i}}));s.push({get:function(){return{}},descending:a?-1:1});a=Array.prototype.map.call(e,function(t,a){return{value:t,predicateValues:s.map(function(e){return function(e,t){var a=typeof e;null===e?(a="string",e="null"):"string"===a?e=e.toLowerCase():"object"===a&&(e=function(e,t){if("function"==typeof e.valueOf&&n(e=e.valueOf()))return e;if(k(e)&&n(e=e.toString()))return e;return t}(e,t));return{value:e,type:a}}(e.get(t),a)})}});return a.sort(function(e,t){for(var a=0,n=0,i=s.length;n<i&&!(a=function(e,t){var a=0;e.type===t.type?e.value!==t.value&&(a=e.value<t.value?-1:1):a=e.type<t.type?-1:1;return a}(e.predicateValues[n],t.predicateValues[n])*s[n].descending);++n);return a}),e=a.map(function(e){return e.value})};function n(e){switch(typeof e){case"number":case"boolean":case"string":return 1;default:return}}}function Di(e){return(e=we(e)?{link:e}:e).restrict=e.restrict||"AC",I(e)}Mi.$inject=["$parse"];var Ti=I({restrict:"E",compile:function(e,t){if(!t.href&&!t.xlinkHref)return function(e,t){var a;"a"===t[0].nodeName.toLowerCase()&&(a="[object SVGAnimatedString]"===$.call(t.prop("href"))?"xlink:href":"href",t.on("click",function(e){t.attr(a)||e.preventDefault()}))}}}),Pi={};ge(xt,function(e,n){var i,t;function s(e,t,a){e.$watch(a[i],function(e){a.$set(n,!!e)})}"multiple"!=e&&(i=da("ng-"+n),t="checked"===e?function(e,t,a){a.ngModel!==a[i]&&s(e,0,a)}:s,Pi[i]=function(){return{restrict:"A",priority:100,link:t}})}),ge(St,function(e,i){Pi[i]=function(){return{priority:100,link:function(e,t,a){if("ngPattern"===i&&"/"==a.ngPattern.charAt(0)){var n=a.ngPattern.match(s);if(n)return void a.$set("ngPattern",new RegExp(n[1],n[2]))}e.$watch(a[i],function(e){a.$set(i,e)})}}}}),ge(["src","srcset","href"],function(s){var o=da("ng-"+s);Pi[o]=function(){return{priority:99,link:function(e,t,a){var n=s,i=s;"href"===s&&"[object SVGAnimatedString]"===$.call(t.prop("href"))&&(a.$attr[i="xlinkHref"]="xlink:href",n=null),a.$observe(o,function(e){e?(a.$set(i,e),U&&n&&t.prop(n,a[i])):"href"===s&&a.$set(i,null)})}}}});var Ei={$addControl:N,$$renameControl:function(e,t){e.$name=t},$removeControl:N,$setValidity:N,$setDirty:N,$setPristine:N,$setSubmitted:N},ji="ng-submitted";function Li(e,t,a,n,i){var s=this,o=[];s.$error={},s.$$success={},s.$pending=void 0,s.$name=i(t.name||t.ngForm||"")(a),s.$dirty=!1,s.$pristine=!0,s.$valid=!0,s.$invalid=!1,s.$submitted=!1,s.$$parentForm=Ei,s.$rollbackViewValue=function(){ge(o,function(e){e.$rollbackViewValue()})},s.$commitViewValue=function(){ge(o,function(e){e.$commitViewValue()})},s.$addControl=function(e){De(e.$name,"input"),o.push(e),e.$name&&(s[e.$name]=e),e.$$parentForm=s},s.$$renameControl=function(e,t){var a=e.$name;s[a]===e&&delete s[a],(s[t]=e).$name=t},s.$removeControl=function(a){a.$name&&s[a.$name]===a&&delete s[a.$name],ge(s.$pending,function(e,t){s.$setValidity(t,null,a)}),ge(s.$error,function(e,t){s.$setValidity(t,null,a)}),ge(s.$$success,function(e,t){s.$setValidity(t,null,a)}),V(o,a),a.$$parentForm=Ei},Ls({ctrl:this,$element:e,set:function(e,t,a){var n=e[t];n?-1===n.indexOf(a)&&n.push(a):e[t]=[a]},unset:function(e,t,a){var n=e[t];n&&(V(n,a),0===n.length&&delete e[t])},$animate:n}),s.$setDirty=function(){n.removeClass(e,_s),n.addClass(e,Ss),s.$dirty=!0,s.$pristine=!1,s.$$parentForm.$setDirty()},s.$setPristine=function(){n.setClass(e,_s,Ss+" "+ji),s.$dirty=!1,s.$pristine=!0,s.$submitted=!1,ge(o,function(e){e.$setPristine()})},s.$setUntouched=function(){ge(o,function(e){e.$setUntouched()})},s.$setSubmitted=function(){n.addClass(e,ji),s.$submitted=!0,s.$$parentForm.$setSubmitted()}}Li.$inject=["$element","$attrs","$scope","$animate","$interpolate"];var Oi=function(a){return["$timeout","$parse",function(l,t){return{name:"form",restrict:a?"EAC":"E",require:["form","^^?form"],controller:Li,compile:function(e,t){e.addClass(_s).addClass(ks);var r=t.name?"name":!(!a||!t.ngForm)&&"ngForm";return{pre:function(t,e,a,n){var i,s=n[0];"action"in a||(Fe(e[0],"submit",i=function(e){t.$apply(function(){s.$commitViewValue(),s.$setSubmitted()}),e.preventDefault()}),e.on("$destroy",function(){l(function(){ze(e[0],"submit",i)},0,!1)})),(n[1]||s.$$parentForm).$addControl(s);var o=r?c(s.$name):N;r&&(o(t,s),a.$observe(r,function(e){s.$name!==e&&(o(t,void 0),s.$$parentForm.$$renameControl(s,e),(o=c(s.$name))(t,s))})),e.on("$destroy",function(){s.$$parentForm.$removeControl(s),o(t,void 0),fe(s,Ei)})}}}};function c(e){return""===e?t('this[""]').assign:t(e).assign||N}}]},Ui=Oi(),Ni=Oi(!0),Bi=/^\d{4,}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+(?:[+-][0-2]\d:[0-5]\d|Z)$/,Ri=/^[a-z][a-z\d.+-]*:\/*(?:[^:@]+(?::[^@]+)?@)?(?:[^\s:/?#]+|\[[a-f\d:]+\])(?::\d+)?(?:\/[^?#]*)?(?:\?[^#]*)?(?:#.*)?$/i,qi=/^[a-z0-9!#$%&'*+\/=?^_`{|}~.-]+@[a-z0-9]([a-z0-9-]*[a-z0-9])?(\.[a-z0-9]([a-z0-9-]*[a-z0-9])?)*$/i,Vi=/^\s*(\-|\+)?(\d+|(\d*(\.\d*)))([eE][+-]?\d+)?\s*$/,Yi=/^(\d{4,})-(\d{2})-(\d{2})$/,Fi=/^(\d{4,})-(\d\d)-(\d\d)T(\d\d):(\d\d)(?::(\d\d)(\.\d{1,3})?)?$/,zi=/^(\d{4,})-W(\d\d)$/,e=/^(\d{4,})-(\d\d)$/,Oi=/^(\d\d):(\d\d)(?::(\d\d)(\.\d{1,3})?)?$/,Hi="keydown wheel mousedown",Wi=Ee();ge("date,datetime-local,month,time,week".split(","),function(e){Wi[e]=!0});var Gi={text:function(e,t,a,n,i,s){Qi(0,t,a,n,i,s),Ki(n)},date:Zi("date",Yi,Ji(Yi,["yyyy","MM","dd"]),"yyyy-MM-dd"),"datetime-local":Zi("datetimelocal",Fi,Ji(Fi,["yyyy","MM","dd","HH","mm","ss","sss"]),"yyyy-MM-ddTHH:mm:ss.sss"),time:Zi("time",Oi,Ji(Oi,["HH","mm","ss","sss"]),"HH:mm:ss.sss"),week:Zi("week",zi,function(e,t){if(C(e))return e;if(R(e)){zi.lastIndex=0;var a=zi.exec(e);if(a){var n=+a[1],i=+a[2],s=0,o=0,r=0,e=0,a=yi(n),i=7*(i-1);return t&&(s=t.getHours(),o=t.getMinutes(),r=t.getSeconds(),e=t.getMilliseconds()),new Date(n,0,a.getDate()+i,s,o,r,e)}}return NaN},"yyyy-Www"),month:Zi("month",e,Ji(e,["yyyy","MM"]),"yyyy-MM"),number:function(e,t,a,n,i,s){{var o;Xi(0,t,0,n),Qi(0,t,a,n,i,s),n.$$parserName="number",n.$parsers.push(function(e){return n.$isEmpty(e)?null:Vi.test(e)?parseFloat(e):void 0}),n.$formatters.push(function(e){if(!n.$isEmpty(e)){if(!_(e))throw Ts("numfmt","Expected `{0}` to be a number",e);e=e.toString()}return e}),(B(a.min)||a.ngMin)&&(n.$validators.min=function(e){return n.$isEmpty(e)||ve(o)||o<=e},a.$observe("min",function(e){B(e)&&!_(e)&&(e=parseFloat(e,10)),o=_(e)&&!isNaN(e)?e:void 0,n.$validate()}))}{var r;(B(a.max)||a.ngMax)&&(n.$validators.max=function(e){return n.$isEmpty(e)||ve(r)||e<=r},a.$observe("max",function(e){B(e)&&!_(e)&&(e=parseFloat(e,10)),r=_(e)&&!isNaN(e)?e:void 0,n.$validate()}))}},url:function(e,t,a,n,i,s){Qi(0,t,a,n,i,s),Ki(n),n.$$parserName="url",n.$validators.url=function(e,t){t=e||t;return n.$isEmpty(t)||Ri.test(t)}},email:function(e,t,a,n,i,s){Qi(0,t,a,n,i,s),Ki(n),n.$$parserName="email",n.$validators.email=function(e,t){t=e||t;return n.$isEmpty(t)||qi.test(t)}},radio:function(e,t,a,n){ve(a.name)&&t.attr("name",p());t.on("click",function(e){t[0].checked&&n.$setViewValue(a.value,e&&e.type)}),n.$render=function(){var e=a.value;t[0].checked=e==n.$viewValue},a.$observe("value",n.$render)},checkbox:function(e,t,a,n,i,s,o,r){var l=es(r,e,"ngTrueValue",a.ngTrueValue,!0),c=es(r,e,"ngFalseValue",a.ngFalseValue,!1);t.on("click",function(e){n.$setViewValue(t[0].checked,e&&e.type)}),n.$render=function(){t[0].checked=n.$viewValue},n.$isEmpty=function(e){return!1===e},n.$formatters.push(function(e){return _e(e,l)}),n.$parsers.push(function(e){return e?l:c})},hidden:N,button:N,submit:N,reset:N,file:N};function Ki(t){t.$formatters.push(function(e){return t.$isEmpty(e)?e:e.toString()})}function Qi(e,a,n,i,t,s){var o,r,l=O(a[0].type);t.android||(o=!1,a.on("compositionstart",function(){o=!0}),a.on("compositionend",function(){o=!1,u()}));var c,u=function(e){var t;r&&(s.defer.cancel(r),r=null),o||(t=a.val(),e=e&&e.type,"password"===l||n.ngTrim&&"false"===n.ngTrim||(t=ke(t)),(i.$viewValue!==t||""===t&&i.$$hasNativeValidators)&&i.$setViewValue(t,e))};t.hasEvent("input")?a.on("input",u):(c=function(e,t,a){r=r||s.defer(function(){r=null,t&&t.value===a||u(e)})},a.on("keydown",function(e){var t=e.keyCode;91===t||15<t&&t<19||37<=t&&t<=40||c(e,this,this.value)}),t.hasEvent("paste")&&a.on("paste cut",c)),a.on("change",u),Wi[l]&&i.$$hasNativeValidators&&l===n.type&&a.on(Hi,function(e){var t,a,n;r||(t=this[d],a=t.badInput,n=t.typeMismatch,r=s.defer(function(){r=null,t.badInput===a&&t.typeMismatch===n||u(e)}))}),i.$render=function(){var e=i.$isEmpty(i.$viewValue)?"":i.$viewValue;a.val()!==e&&a.val(e)}}function Ji(n,i){return function(e,t){var a;if(C(e))return e;if(R(e)){if('"'==e.charAt(0)&&'"'==e.charAt(e.length-1)&&(e=e.substring(1,e.length-1)),Bi.test(e))return new Date(e);if(n.lastIndex=0,e=n.exec(e))return e.shift(),a=t?{yyyy:t.getFullYear(),MM:t.getMonth()+1,dd:t.getDate(),HH:t.getHours(),mm:t.getMinutes(),ss:t.getSeconds(),sss:t.getMilliseconds()/1e3}:{yyyy:1970,MM:1,dd:1,HH:0,mm:0,ss:0,sss:0},ge(e,function(e,t){t<i.length&&(a[i[t]]=+e)}),new Date(a.yyyy,a.MM-1,a.dd,a.HH,a.mm,a.ss||0,1e3*a.sss||0)}return NaN}}function Zi(m,g,f,h){return function(e,t,a,n,i,s,o){Xi(0,t,0,n),Qi(0,t,a,n,i,s);var r,l,c,u=n&&n.$options&&n.$options.timezone;function d(e){return e&&(!e.getTime||e.getTime()===e.getTime())}function p(e){return B(e)&&!C(e)?f(e)||void 0:e}n.$$parserName=m,n.$parsers.push(function(e){if(n.$isEmpty(e))return null;if(g.test(e)){e=f(e,r);return e=u?X(e,u):e}}),n.$formatters.push(function(e){if(e&&!C(e))throw Ts("datefmt","Expected `{0}` to be a date",e);return d(e)?((r=e)&&u&&(r=X(r,u,!0)),o("date")(e,h,u)):(r=null,"")}),(B(a.min)||a.ngMin)&&(n.$validators.min=function(e){return!d(e)||ve(l)||f(e)>=l},a.$observe("min",function(e){l=p(e),n.$validate()})),(B(a.max)||a.ngMax)&&(n.$validators.max=function(e){return!d(e)||ve(c)||f(e)<=c},a.$observe("max",function(e){c=p(e),n.$validate()}))}}function Xi(e,a,t,n){var i=a[0];(n.$$hasNativeValidators=ye(i.validity))&&n.$parsers.push(function(e){var t=a.prop(d)||{};return t.badInput||t.typeMismatch?void 0:e})}function es(e,t,a,n,i){if(B(n)){if(!(e=e(n)).constant)throw Ts("constexpr","Expected constant expression for `{0}`, but saw `{1}`.",a,n);return e(t)}return i}function ts(){return{restrict:"A",priority:100,compile:function(e,t){return ns.test(t.ngValue)?function(e,t,a){a.$set("value",e.$eval(a.ngValue))}:function(e,t,a){e.$watch(a.ngValue,function(e){a.$set("value",e)})}}}}var as=["$browser","$sniffer","$filter","$parse",function(i,s,o,r){return{restrict:"E",require:["?ngModel"],link:{pre:function(e,t,a,n){n[0]&&(Gi[O(a.type)]||Gi.text)(e,t,a,n[0],s,i,o,r)}}}}],ns=/^(true|false|\d+)$/,is=["$compile",function(n){return{restrict:"AC",compile:function(e){return n.$$addBindingClass(e),function(e,t,a){n.$$addBindingInfo(t,a.ngBind),t=t[0],e.$watch(a.ngBind,function(e){t.textContent=ve(e)?"":e})}}}}],ss=["$interpolate","$compile",function(i,s){return{compile:function(e){return s.$$addBindingClass(e),function(e,t,a){var n=i(t.attr(a.$attr.ngBindTemplate));s.$$addBindingInfo(t,n.expressions),t=t[0],a.$observe("ngBindTemplate",function(e){t.textContent=ve(e)?"":e})}}}}],os=["$sce","$parse","$compile",function(s,a,o){return{restrict:"A",compile:function(e,t){var n=a(t.ngBindHtml),i=a(t.ngBindHtml,function(e){return s.valueOf(e)});return o.$$addBindingClass(e),function(t,a,e){o.$$addBindingInfo(a,e.ngBindHtml),t.$watch(i,function(){var e=n(t);a.html(s.getTrustedHtml(e)||"")})}}}}],rs=I({restrict:"A",require:"ngModel",link:function(e,t,a,n){n.$viewChangeListeners.push(function(){e.$eval(a.ngChange)})}});function ls(n,m){return n="ngClass"+n,["$animate",function(u){return{restrict:"AC",link:function(s,o,a){var r;function l(e){e=c(e,1);a.$addClass(e)}function c(e,t){var a=o.data("$classCounts")||Ee(),n=[];return ge(e,function(e){(0<t||a[e])&&(a[e]=(a[e]||0)+t,a[e]===+(0<t)&&n.push(e))}),o.data("$classCounts",a),n.join(" ")}function t(e){var t,a,n,i;!0!==m&&(1&s.$index)!==m||(t=p(e||[]),r?_e(e,r)||(i=p(r),i=d(n=t,a=i),n=d(a,n),i=c(i,1),n=c(n,-1),i&&i.length&&u.addClass(o,i),n&&n.length&&u.removeClass(o,n)):l(t)),r=be(e)?e.map(function(e){return F(e)}):F(e)}s.$watch(a[n],t,!0),a.$observe("class",function(e){t(s.$eval(a[n]))}),"ngClass"!==n&&s.$watch("$index",function(e,t){e&=1;e!=(1&t)&&(t=p(s.$eval(a[n])),(e===m?l:function(e){e=c(e,-1);a.$removeClass(e)})(t))})}};function d(e,t){var a=[];e:for(var n=0;n<e.length;n++){for(var i=e[n],s=0;s<t.length;s++)if(i==t[s])continue e;a.push(i)}return a}function p(e){var a=[];return be(e)?(ge(e,function(e){a=a.concat(p(e))}),a):R(e)?e.split(" "):ye(e)?(ge(e,function(e,t){e&&(a=a.concat(t.split(" ")))}),a):e}}]}var cs=ls("",!0),us=ls("Odd",0),ds=ls("Even",1),ps=Di({compile:function(e,t){t.$set("ngCloak",void 0),e.removeClass("ng-cloak")}}),ms=[function(){return{restrict:"A",scope:!0,controller:"@",priority:500}}],gs={},fs={blur:!0,focus:!0};ge("click dblclick mousedown mouseup mouseover mouseout mousemove mouseenter mouseleave keydown keyup keypress submit focus blur copy cut paste".split(" "),function(s){var o=da("ng-"+s);gs[o]=["$parse","$rootScope",function(a,i){return{restrict:"A",compile:function(e,t){var n=a(t[o],null,!0);return function(a,e){e.on(s,function(e){function t(){n(a,{$event:e})}fs[s]&&i.$$phase?a.$evalAsync(t):a.$apply(t)})}}}}]});function hs(){return{restrict:"A",priority:100,require:"ngModel",link:function(e,t,a,n){var i=t.attr(a.$attr.ngList)||", ",s="false"!==a.ngTrim,o=s?ke(i):i;n.$parsers.push(function(e){if(!ve(e)){var t=[];return e&&ge(e.split(o),function(e){e&&t.push(s?ke(e):e)}),t}}),n.$formatters.push(function(e){if(be(e))return e.join(i)}),n.$isEmpty=function(e){return!e||!e.length}}}}function vs(){return{restrict:"A",controller:["$scope","$attrs",function(e,t){var a=this;this.$options=Y(e.$eval(t.ngModelOptions)),B(this.$options.updateOn)?(this.$options.updateOnDefault=!1,this.$options.updateOn=ke(this.$options.updateOn.replace(js,function(){return a.$options.updateOnDefault=!0," "}))):this.$options.updateOnDefault=!0}]}}var ys=["$animate","$compile",function(l,c){return{multiElement:!0,transclude:"element",priority:600,terminal:!0,restrict:"A",$$tlb:!0,link:function(e,a,n,t,i){var s,o,r;e.$watch(n.ngIf,function(e){e?o||i(function(e,t){o=t,e[e.length++]=c.$$createComment("end ngIf",n.ngIf),s={clone:e},l.enter(e,a.parent(),a)}):(r&&(r.remove(),r=null),o&&(o.$destroy(),o=null),s&&(r=Pe(s.clone),l.leave(r).then(function(){r=null}),s=null))})}}}],bs=["$templateRequest","$anchorScroll","$animate",function(f,h,v){return{restrict:"ECA",priority:400,terminal:!0,transclude:"element",controller:S.noop,compile:function(e,t){var a=t.ngInclude||t.src,m=t.onload||"",g=t.autoscroll;return function(s,o,e,r,l){function c(){t&&(t.remove(),t=null),u&&(u.$destroy(),u=null),d&&(v.leave(d).then(function(){t=null}),t=d,d=null)}var u,t,d,p=0;s.$watch(a,function(a){function n(){!B(g)||g&&!s.$eval(g)||h()}var i=++p;a?(f(a,!0).then(function(e){var t;s.$$destroyed||i===p&&(t=s.$new(),r.template=e,e=l(t,function(e){c(),v.enter(e,null,o).then(n)}),d=e,(u=t).$emit("$includeContentLoaded",a),s.$eval(m))},function(){s.$$destroyed||i===p&&(c(),s.$emit("$includeContentError",a))}),s.$emit("$includeContentRequested",a)):(c(),r.template=null)})}}}}],ws=["$compile",function(i){return{restrict:"ECA",priority:-400,require:"ngInclude",link:function(e,t,a,n){if($.call(t[0]).match(/SVG/))return t.empty(),void i(it(n.template,h.document).childNodes)(e,function(e){t.append(e)},{futureParentElement:t});t.html(n.template),i(t.contents())(e)}}}],$s=Di({priority:450,compile:function(){return{pre:function(e,t,a){e.$eval(a.ngInit)}}}}),ks="ng-valid",xs="ng-invalid",_s="ng-pristine",Ss="ng-dirty",Is="ng-untouched",Cs="ng-touched",As="ng-pending",Ms="ng-empty",Ds="ng-not-empty",Ts=w("ngModel"),Ps=["$scope","$exceptionHandler","$attrs","$element","$parse","$animate","$timeout","$rootScope","$q","$interpolate",function(s,t,i,o,r,a,n,l,c,e){this.$viewValue=Number.NaN,this.$modelValue=Number.NaN,this.$$rawModelValue=void 0,this.$validators={},this.$asyncValidators={},this.$parsers=[],this.$formatters=[],this.$viewChangeListeners=[],this.$untouched=!0,this.$touched=!1,this.$pristine=!0,this.$dirty=!1,this.$valid=!0,this.$invalid=!1,this.$error={},this.$$success={},this.$pending=void 0,this.$name=e(i.name||"",!1)(s),this.$$parentForm=Ei;var u,d=r(i.ngModel),p=d.assign,m=d,g=p,f=null,h=this;this.$$setOptions=function(e){if((h.$options=e)&&e.getterSetter){var a=r(i.ngModel+"()"),n=r(i.ngModel+"($$$p)");m=function(e){var t=d(e);return t=we(t)?a(e):t},g=function(e,t){we(d(e))?n(e,{$$$p:t}):p(e,t)}}else if(!d.assign)throw Ts("nonassign","Expression '{0}' is non-assignable. Element: {1}",i.ngModel,Ce(o))},this.$render=N,this.$isEmpty=function(e){return ve(e)||""===e||null===e||e!=e},this.$$updateEmptyClasses=function(e){h.$isEmpty(e)?(a.removeClass(o,Ds),a.addClass(o,Ms)):(a.removeClass(o,Ms),a.addClass(o,Ds))};var v=0;Ls({ctrl:this,$element:o,set:function(e,t){e[t]=!0},unset:function(e,t){delete e[t]},$animate:a}),this.$setPristine=function(){h.$dirty=!1,h.$pristine=!0,a.removeClass(o,Ss),a.addClass(o,_s)},this.$setDirty=function(){h.$dirty=!0,h.$pristine=!1,a.removeClass(o,_s),a.addClass(o,Ss),h.$$parentForm.$setDirty()},this.$setUntouched=function(){h.$touched=!1,h.$untouched=!0,a.setClass(o,Is,Cs)},this.$setTouched=function(){h.$touched=!0,h.$untouched=!1,a.setClass(o,Cs,Is)},this.$rollbackViewValue=function(){n.cancel(f),h.$viewValue=h.$$lastCommittedViewValue,h.$render()},this.$validate=function(){var e,t,a,n,i;_(h.$modelValue)&&isNaN(h.$modelValue)||(e=h.$$lastCommittedViewValue,t=h.$$rawModelValue,a=h.$valid,n=h.$modelValue,i=h.$options&&h.$options.allowInvalid,h.$$runValidators(t,e,function(e){i||a===e||(h.$modelValue=e?t:void 0,h.$modelValue!==n&&h.$$writeModelToScope())}))},this.$$runValidators=function(a,n,t){var i,s,o,r=++v;function l(e,t){r===v&&h.$setValidity(e,t)}function e(e){r===v&&t(e)}!function(){var e=h.$$parserName||"parse";{if(!ve(u))return u||(ge(h.$validators,function(e,t){l(t,null)}),ge(h.$asyncValidators,function(e,t){l(t,null)})),l(e,u),u;l(e,null)}return!0}()?e(!1):(i=!0,ge(h.$validators,function(e,t){e=e(a,n);i=i&&e,l(t,e)}),i||(ge(h.$asyncValidators,function(e,t){l(t,null)}),0)?(s=[],o=!0,ge(h.$asyncValidators,function(e,t){e=e(a,n);if(!D(e))throw Ts("nopromise","Expected asynchronous validator to return a promise but got '{0}' instead.",e);l(t,void 0),s.push(e.then(function(){l(t,!0)},function(){l(t,o=!1)}))}),s.length?c.all(s).then(function(){e(o)},N):e(!0)):e(!1))},this.$commitViewValue=function(){var e=h.$viewValue;n.cancel(f),(h.$$lastCommittedViewValue!==e||""===e&&h.$$hasNativeValidators)&&(h.$$updateEmptyClasses(e),h.$$lastCommittedViewValue=e,h.$pristine&&this.$setDirty(),this.$$parseAndValidate())},this.$$parseAndValidate=function(){var t=h.$$lastCommittedViewValue;if(u=!ve(t)||void 0)for(var e=0;e<h.$parsers.length;e++)if(ve(t=h.$parsers[e](t))){u=!1;break}_(h.$modelValue)&&isNaN(h.$modelValue)&&(h.$modelValue=m(s));var a=h.$modelValue,n=h.$options&&h.$options.allowInvalid;function i(){h.$modelValue!==a&&h.$$writeModelToScope()}h.$$rawModelValue=t,n&&(h.$modelValue=t,i()),h.$$runValidators(t,h.$$lastCommittedViewValue,function(e){n||(h.$modelValue=e?t:void 0,i())})},this.$$writeModelToScope=function(){g(s,h.$modelValue),ge(h.$viewChangeListeners,function(e){try{e()}catch(e){t(e)}})},this.$setViewValue=function(e,t){h.$viewValue=e,h.$options&&!h.$options.updateOnDefault||h.$$debounceViewValueCommit(t)},this.$$debounceViewValueCommit=function(e){var t=0,a=h.$options;a&&B(a.debounce)&&(_(a=a.debounce)?t=a:_(a[e])?t=a[e]:_(a.default)&&(t=a.default)),n.cancel(f),t?f=n(function(){h.$commitViewValue()},t):l.$$phase?h.$commitViewValue():s.$apply(function(){h.$commitViewValue()})},s.$watch(function(){var e=m(s);if(e!==h.$modelValue&&(h.$modelValue==h.$modelValue||e==e)){h.$modelValue=h.$$rawModelValue=e,u=void 0;for(var t=h.$formatters,a=t.length,n=e;a--;)n=t[a](n);h.$viewValue!==n&&(h.$$updateEmptyClasses(n),h.$viewValue=h.$$lastCommittedViewValue=n,h.$render(),h.$$runValidators(e,n,N))}return e})}],Es=["$rootScope",function(s){return{restrict:"A",require:["ngModel","^?form","^?ngModelOptions"],controller:Ps,priority:1,compile:function(e){return e.addClass(_s).addClass(Is).addClass(ks),{pre:function(e,t,a,n){var i=n[0],s=n[1]||i.$$parentForm;i.$$setOptions(n[2]&&n[2].$options),s.$addControl(i),a.$observe("name",function(e){i.$name!==e&&i.$$parentForm.$$renameControl(i,e)}),e.$on("$destroy",function(){i.$$parentForm.$removeControl(i)})},post:function(e,t,a,n){var i=n[0];i.$options&&i.$options.updateOn&&t.on(i.$options.updateOn,function(e){i.$$debounceViewValueCommit(e&&e.type)}),t.on("blur",function(){i.$touched||(s.$$phase?e.$evalAsync(i.$setTouched):e.$apply(i.$setTouched))})}}}}}],js=/(\s+|^)default(\s+|$)/;function Ls(e){var n=e.ctrl,a=e.$element,i={},s=e.set,o=e.unset,r=e.$animate;function l(e,t){t&&!i[e]?(r.addClass(a,e),i[e]=!0):!t&&i[e]&&(r.removeClass(a,e),i[e]=!1)}function c(e,t){e=e?"-"+Ae(e,"-"):"",l(ks+e,!0===t),l(xs+e,!1===t)}i[xs]=!(i[ks]=a.hasClass(ks)),n.$setValidity=function(e,t,a){(ve(t)?function(e,t,a){n[e]||(n[e]={});s(n[e],t,a)}:function(e,t,a){n[e]&&o(n[e],t,a);Os(n[e])&&(n[e]=void 0)})("$pending",e,a);q(t)?t?(o(n.$error,e,a),s(n.$$success,e,a)):(s(n.$error,e,a),o(n.$$success,e,a)):(o(n.$error,e,a),o(n.$$success,e,a));n.$pending?(l(As,!0),n.$valid=n.$invalid=void 0,c("",null)):(l(As,!1),n.$valid=Os(n.$error),n.$invalid=!n.$valid,c("",n.$valid));a=n.$pending&&n.$pending[e]?void 0:!n.$error[e]&&(!!n.$$success[e]||null);c(e,a),n.$$parentForm.$setValidity(e,a,n)}}function Os(e){if(e)for(var t in e)if(e.hasOwnProperty(t))return!1;return!0}var Us=Di({terminal:!0,priority:1e3}),Ns=w("ngOptions"),Bs=/^\s*([\s\S]+?)(?:\s+as\s+([\s\S]+?))?(?:\s+group\s+by\s+([\s\S]+?))?(?:\s+disable\s+when\s+([\s\S]+?))?\s+for\s+(?:([\$\w][\$\w]*)|(?:\(\s*([\$\w][\$\w]*)\s*,\s*([\$\w][\$\w]*)\s*\)))\s+in\s+([\s\S]+?)(?:\s+track\s+by\s+([\s\S]+?))?$/,Rs=["$compile","$document","$parse",function(w,$,o){function k(e,t,c){var r=e.match(Bs);if(!r)throw Ns("iexp","Expected expression in form of '_select_ (as _label_)? for (_key_,)?_value_ in _collection_' but got '{0}'. Element: {1}",e,Ce(t));function u(e,t){return m(e,y(e,t))}var a=r[5]||r[7],n=r[6],e=/ as /.test(r[0])&&r[1],d=r[9],t=o(r[2]?r[1]:a),p=e&&o(e)||t,i=d&&o(d),m=d?function(e,t){return i(c,t)}:function(e){return Pt(e)},g=o(r[2]||r[1]),f=o(r[3]||""),h=o(r[4]||""),v=o(r[8]),s={},y=n?function(e,t){return s[n]=t,s[a]=e,s}:function(e){return s[a]=e,s};function b(e,t,a,n,i){this.selectValue=e,this.viewValue=t,this.label=a,this.group=n,this.disabled=i}function w(e){var t;if(!n&&j(e))t=e;else for(var a in t=[],e)e.hasOwnProperty(a)&&"$"!==a.charAt(0)&&t.push(a);return t}return{trackBy:d,getTrackByValue:u,getWatchables:o(v,function(e){for(var t=[],a=w(e=e||[]),n=a.length,i=0;i<n;i++){var s=e===a?i:a[i],o=e[s],s=y(o,s),o=m(o,s);t.push(o),(r[2]||r[1])&&(o=g(c,s),t.push(o)),r[4]&&(s=h(c,s),t.push(s))}return t}),getOptions:function(){for(var e=[],t={},a=v(c)||[],n=w(a),i=n.length,s=0;s<i;s++){var o=a===n?s:n[s],r=a[o],l=y(r,o),r=p(c,l),o=m(r,l),l=new b(o,r,g(c,l),f(c,l),h(c,l));e.push(l),t[o]=l}return{items:e,selectValueMap:t,getOptionFromViewValue:function(e){return t[u(e)]},getViewValueFromOption:function(e){return d?S.copy(e.viewValue):e.viewValue}}}}}var x=h.document.createElement("option"),_=h.document.createElement("optgroup");return{restrict:"A",terminal:!0,require:["select","ngModel"],link:{pre:function(e,t,a,n){n[0].registerOption=N},post:function(e,s,t,a){for(var o,r=a[0],l=a[1],c=t.multiple,n=0,i=s.children(),u=i.length;n<u;n++)if(""===i[n].value){o=i.eq(n);break}var d,p=!!o,m=me(x.cloneNode(!1));function g(){p||o.remove()}function f(){m.remove()}m.val("?");var h=k(t.ngOptions,s,e),v=$[0].createDocumentFragment();function y(e,t){var a=x.cloneNode(!1);t.appendChild(a),function(e,t){(e.element=t).disabled=e.disabled,e.label!==t.label&&(t.label=e.label,t.textContent=e.label);e.value!==t.value&&(t.value=e.selectValue)}(e,a)}function b(){var e=d&&r.readValue();if(d)for(var t=d.items.length-1;0<=t;t--){var a=d.items[t];a.group?$t(a.element.parentNode):$t(a.element)}d=h.getOptions();var n,i={};p&&s.prepend(o),d.items.forEach(function(e){var t;B(e.group)?((t=i[e.group])||(t=_.cloneNode(!1),v.appendChild(t),t.label=e.group,i[e.group]=t),y(e,t)):y(e,v)}),s[0].appendChild(v),l.$render(),l.$isEmpty(e)||(n=r.readValue(),(h.trackBy||c?_e(e,n):e===n)||(l.$setViewValue(n),l.$render()))}c?(l.$isEmpty=function(e){return!e||0===e.length},r.writeValue=function(e){d.items.forEach(function(e){e.element.selected=!1}),e&&e.forEach(function(e){e=d.getOptionFromViewValue(e);e&&(e.element.selected=!0)})},r.readValue=function(){var e=s.val()||[],t=[];return ge(e,function(e){e=d.selectValueMap[e];e&&!e.disabled&&t.push(d.getViewValueFromOption(e))}),t},h.trackBy&&e.$watchCollection(function(){if(be(l.$viewValue))return l.$viewValue.map(function(e){return h.getTrackByValue(e)})},function(){l.$render()})):(r.writeValue=function(e){var t=d.getOptionFromViewValue(e);t?(s[0].value!==t.selectValue&&(f(),g(),s[0].value=t.selectValue,t.element.selected=!0),t.element.setAttribute("selected","selected")):null===e||p?(f(),p||s.prepend(o),s.val(""),o.prop("selected",!0),o.attr("selected",!0)):(g(),s.prepend(m),s.val("?"),m.prop("selected",!0),m.attr("selected",!0))},r.readValue=function(){var e=d.selectValueMap[s.val()];return e&&!e.disabled?(g(),f(),d.getViewValueFromOption(e)):null},h.trackBy&&e.$watch(function(){return h.getTrackByValue(l.$viewValue)},function(){l.$render()})),p?(o.remove(),w(o)(e),o.removeClass("ng-scope")):o=me(x.cloneNode(!1)),s.empty(),b(),e.$watchCollection(h.getWatchables,b)}}}}],qs=["$locale","$interpolate","$log",function(g,f,h){var v=/{}/g,y=/^when(Minus)?(.+)$/;return{link:function(n,i,s){var o,e=s.count,r=s.$attr.when&&i.attr(s.$attr.when),l=s.offset||0,c=n.$eval(r)||{},u={},t=f.startSymbol(),a=f.endSymbol(),d=t+e+"-"+l+a,p=S.noop;function m(e){i.text(e||"")}ge(s,function(e,t){var a=y.exec(t);a&&(a=(a[1]?"-":"")+O(a[2]),c[a]=i.attr(s.$attr[t]))}),ge(c,function(e,t){u[t]=f(e.replace(v,d))}),n.$watch(e,function(e){var t=parseFloat(e),a=isNaN(t);(t=!(a||t in c)?g.pluralCat(t-l):t)===o||a&&_(o)&&isNaN(o)||(p(),ve(a=u[t])?(null!=e&&h.debug("ngPluralize: no rule defined for '"+t+"' in "+r),p=N,m()):p=n.$watch(a,m),o=t)})}}}],Vs=["$parse","$animate","$compile",function(r,D,l){function T(e,t,a,n,i,s,o){e[a]=n,i&&(e[i]=s),e.$index=t,e.$first=0===t,e.$last=t===o-1,e.$middle=!(e.$first||e.$last),e.$odd=!(e.$even=0==(1&t))}var P="$$NG_REMOVED",E=w("ngRepeat");return{restrict:"A",multiElement:!0,transclude:"element",priority:1e3,terminal:!0,$$tlb:!0,compile:function(e,t){var k=t.ngRepeat,x=l.$$createComment("end ngRepeat",k),a=k.match(/^\s*([\s\S]+?)\s+in\s+([\s\S]+?)(?:\s+as\s+([\s\S]+?))?(?:\s+track\s+by\s+([\s\S]+?))?\s*$/);if(!a)throw E("iexp","Expected expression in form of '_item_ in _collection_[ track by _id_]' but got '{0}'.",k);var n=a[1],i=a[2],_=a[3],t=a[4];if(!(a=n.match(/^(?:(\s*[\$\w]+)|\(\s*([\$\w]+)\s*,\s*([\$\w]+)\s*\))$/)))throw E("iidexp","'_item_' in '_item_ in _collection_' should be an identifier or '(_key_, _value_)' expression, but got '{0}'.",n);var s,S,I,C,A=a[3]||a[1],M=a[2];if(_&&(!/^[$a-zA-Z_][$a-zA-Z0-9_]*$/.test(_)||/^(null|undefined|this|\$index|\$first|\$middle|\$last|\$even|\$odd|\$parent|\$root|\$id)$/.test(_)))throw E("badident","alias '{0}' is invalid --- must be a valid JS identifier which is not a reserved name.",_);var o={$id:Pt};return t?s=r(t):(I=function(e,t){return Pt(t)},C=function(e){return e}),function(y,b,e,t,w){s&&(S=function(e,t,a){return M&&(o[M]=e),o[A]=t,o.$index=a,s(y,o)});var $=Ee();y.$watchCollection(i,function(e){var a,t,n,i,s,o,r,l,c,u,d,p,m,g,f=b[0],h=Ee();if(_&&(y[_]=e),j(e))c=e,l=S||I;else for(var v in l=S||C,c=[],e)L.call(e,v)&&"$"!==v.charAt(0)&&c.push(v);for(i=c.length,d=new Array(i),a=0;a<i;a++)if(s=e===c?a:c[a],o=e[s],r=l(s,o,a),$[r])u=$[r],delete $[r],h[r]=u,d[a]=u;else{if(h[r])throw ge(d,function(e){e&&e.scope&&($[e.id]=e)}),E("dupes","Duplicates in a repeater are not allowed. Use 'track by' expression to specify unique keys. Repeater: {0}, Duplicate key: {1}, Duplicate value: {2}",k,r,o);d[a]={id:r,scope:void 0,clone:void 0},h[r]=!0}for(m in $){if(p=Pe((u=$[m]).clone),D.leave(p),p[0].parentNode)for(a=0,t=p.length;a<t;a++)p[a][P]=!0;u.scope.$destroy()}for(a=0;a<i;a++)if(s=e===c?a:c[a],o=e[s],(u=d[a]).scope){for(n=f;(n=n.nextSibling)&&n[P];);u.clone[0]!=n&&D.move(Pe(u.clone),null,f),f=(g=u).clone[g.clone.length-1],T(u.scope,a,A,o,M,s,i)}else w(function(e,t){u.scope=t;t=x.cloneNode(!1);e[e.length++]=t,D.enter(e,null,f),f=t,u.clone=e,h[u.id]=u,T(u.scope,a,A,o,M,s,i)});$=h})}}}}],Ys="ng-hide",Fs="ng-hide-animate",zs=["$animate",function(n){return{restrict:"A",multiElement:!0,link:function(e,t,a){e.$watch(a.ngShow,function(e){n[e?"removeClass":"addClass"](t,Ys,{tempClasses:Fs})})}}}],Hs=["$animate",function(n){return{restrict:"A",multiElement:!0,link:function(e,t,a){e.$watch(a.ngHide,function(e){n[e?"addClass":"removeClass"](t,Ys,{tempClasses:Fs})})}}}],Ws=Di(function(e,a,t){e.$watch(t.ngStyle,function(e,t){t&&e!==t&&ge(t,function(e,t){a.css(t,"")}),e&&a.css(e)},!0)}),Gs=["$animate","$compile",function(c,u){return{require:"ngSwitch",controller:["$scope",function(){this.cases={}}],link:function(e,t,a,i){var s,a=a.ngSwitch||a.on,o=[],r=[],l=[];e.$watch(a,function(e){for(var t=0,a=r.length;t<a;++t)c.cancel(r[t]);for(t=r.length=0,a=l.length;t<a;++t){var n=Pe(o[t].clone);l[t].$destroy(),(r[t]=c.leave(n)).then(function(e,t){return function(){e.splice(t,1)}}(r,t))}o.length=0,l.length=0,(s=i.cases["!"+e]||i.cases["?"])&&ge(s,function(a){a.transclude(function(e,t){l.push(t);t=a.element;e[e.length++]=u.$$createComment("end ngSwitchWhen"),o.push({clone:e}),c.enter(e,t.parent(),t)})})})}}}],Ks=Di({transclude:"element",priority:1200,require:"^ngSwitch",multiElement:!0,link:function(e,t,a,n,i){n.cases["!"+a.ngSwitchWhen]=n.cases["!"+a.ngSwitchWhen]||[],n.cases["!"+a.ngSwitchWhen].push({transclude:i,element:t})}}),Qs=Di({transclude:"element",priority:1200,require:"^ngSwitch",multiElement:!0,link:function(e,t,a,n,i){n.cases["?"]=n.cases["?"]||[],n.cases["?"].push({transclude:i,element:t})}}),Js=w("ngTransclude"),Zs=Di({restrict:"EAC",link:function(e,t,a,n,i){if(a.ngTransclude===a.$attr.ngTransclude&&(a.ngTransclude=""),!i)throw Js("orphan","Illegal use of ngTransclude directive in the template! No parent directive that requires a transclusion found. Element: {0}",Ce(t));i(function(e){e.length&&(t.empty(),t.append(e))},null,a.ngTransclude||a.ngTranscludeSlot)}}),Xs=["$templateCache",function(a){return{restrict:"E",terminal:!0,compile:function(e,t){"text/ng-template"==t.type&&(t=t.id,e=e[0].text,a.put(t,e))}}}],eo={$setViewValue:N,$render:N};function to(){return{restrict:"E",require:["select","?ngModel"],controller:lo,priority:1,link:{pre:function(e,a,t,n){var i,s,o,r=n[1];r&&((i=n[0]).ngModelCtrl=r,a.on("change",function(){e.$apply(function(){r.$setViewValue(i.readValue())})}),t.multiple&&(i.readValue=function(){var t=[];return ge(a.find("option"),function(e){e.selected&&t.push(e.value)}),t},i.writeValue=function(e){var t=new Et(e);ge(a.find("option"),function(e){e.selected=B(t.get(e.value))})},o=NaN,e.$watch(function(){o!==r.$viewValue||_e(s,r.$viewValue)||(s=F(r.$viewValue),r.$render()),o=r.$viewValue}),r.$isEmpty=function(e){return!e||0===e.length}))},post:function(e,t,a,n){var i,s=n[1];s&&(i=n[0],s.$render=function(){i.writeValue(s.$viewValue)})}}}}function ao(){return{restrict:"A",require:"?ngModel",link:function(e,t,a,n){n&&(a.required=!0,n.$validators.required=function(e,t){return!a.required||!n.$isEmpty(t)},a.$observe("required",function(){n.$validate()}))}}}function no(){return{restrict:"A",require:"?ngModel",link:function(e,t,a,n){var i,s;n&&(s=a.ngPattern||a.pattern,a.$observe("pattern",function(e){if((e=R(e)&&0<e.length?new RegExp("^"+e+"$"):e)&&!e.test)throw w("ngPattern")("noregexp","Expected {0} to be a RegExp but was {1}. Element: {2}",s,e,Ce(t));i=e||void 0,n.$validate()}),n.$validators.pattern=function(e,t){return n.$isEmpty(t)||ve(i)||i.test(t)})}}}function io(){return{restrict:"A",require:"?ngModel",link:function(e,t,a,n){var i;n&&(i=-1,a.$observe("maxlength",function(e){e=y(e);i=isNaN(e)?-1:e,n.$validate()}),n.$validators.maxlength=function(e,t){return i<0||n.$isEmpty(t)||t.length<=i})}}}function so(){return{restrict:"A",require:"?ngModel",link:function(e,t,a,n){var i;n&&(i=0,a.$observe("minlength",function(e){i=y(e)||0,n.$validate()}),n.$validators.minlength=function(e,t){return n.$isEmpty(t)||t.length>=i})}}}var oo,ro,lo=["$element","$scope",function(t,e){var o=this,n=new Et;o.ngModelCtrl=eo,o.unknownOption=me(h.document.createElement("option")),o.renderUnknownOption=function(e){e="? "+Pt(e)+" ?";o.unknownOption.val(e),t.prepend(o.unknownOption),t.val(e)},e.$on("$destroy",function(){o.renderUnknownOption=N}),o.removeUnknownOption=function(){o.unknownOption.parent()&&o.unknownOption.remove()},o.readValue=function(){return o.removeUnknownOption(),t.val()},o.writeValue=function(e){o.hasOption(e)?(o.removeUnknownOption(),t.val(e),""===e&&o.emptyOption.prop("selected",!0)):null==e&&o.emptyOption?(o.removeUnknownOption(),t.val("")):o.renderUnknownOption(e)},o.addOption=function(e,t){var a;t[0].nodeType!==Oe&&(De(e,'"option value"'),""===e&&(o.emptyOption=t),a=n.get(e)||0,n.put(e,a+1),o.ngModelCtrl.$render(),(t=t)[0].hasAttribute("selected")&&(t[0].selected=!0))},o.removeOption=function(e){var t=n.get(e);t&&(1===t?(n.remove(e),""===e&&(o.emptyOption=void 0)):n.put(e,t-1))},o.hasOption=function(e){return!!n.get(e)},o.registerOption=function(e,a,n,t,i){var s;t?n.$observe("value",function(e){B(s)&&o.removeOption(s),s=e,o.addOption(e,a)}):i?e.$watch(i,function(e,t){n.$set("value",e),t!==e&&o.removeOption(t),o.addOption(e,a)}):o.addOption(n.value,a),a.on("$destroy",function(){o.removeOption(n.value),o.ngModelCtrl.$render()})}}],co=["$interpolate",function(a){return{restrict:"E",priority:100,compile:function(e,t){var s,o;return B(t.value)?s=a(t.value,!0):(o=a(e.text(),!0))||t.$set("value",e.text()),function(e,t,a){var n="$selectController",i=t.parent(),n=i.data(n)||i.parent().data(n);n&&n.registerOption(e,t,a,s,o)}}}}],uo=I({restrict:"E",terminal:!1});h.angular.bootstrap?h.console&&console.log("WARNING: Tried to load angular more than once."):(de||(ro=H(),(i=ve(ro)?h.jQuery:ro?h[ro]:void 0)&&i.fn.on?(fe((me=i).fn,{scope:kt.scope,isolateScope:kt.isolateScope,controller:kt.controller,injector:kt.injector,inheritedData:kt.inheritedData}),oo=i.cleanData,i.cleanData=function(e){for(var t,a,n=0;null!=(a=e[n]);n++)(t=i._data(a,"events"))&&t.$destroy&&i(a).triggerHandler("$destroy");oo(e)}):me=rt,S.element=me,de=!0),fe(S,{bootstrap:re,copy:Y,extend:fe,merge:n,equals:_e,element:me,forEach:ge,injector:Yt,noop:N,bind:Ie,toJson:K,fromJson:Q,identity:b,isUndefined:ve,isDefined:B,isString:R,isFunction:we,isObject:ye,isNumber:_,isElement:E,isArray:be,version:qe,isDate:C,lowercase:O,uppercase:u,callbacks:{counter:0},getTestability:ce,$$minErr:w,$$csp:z,reloadWithDebugInfo:le}),(f=Be(h))("ng",["ngLocale"],["$provide",function(e){e.provider({$$sanitizeUri:qn}),e.provider("$compile",la).directive({a:Ti,input:as,textarea:as,form:Ui,script:Xs,select:to,style:uo,option:co,ngBind:is,ngBindHtml:os,ngBindTemplate:ss,ngClass:cs,ngClassEven:ds,ngClassOdd:us,ngCloak:ps,ngController:ms,ngForm:Ni,ngHide:Hs,ngIf:ys,ngInclude:bs,ngInit:$s,ngNonBindable:Us,ngPluralize:qs,ngRepeat:Vs,ngShow:zs,ngStyle:Ws,ngSwitch:Gs,ngSwitchWhen:Ks,ngSwitchDefault:Qs,ngOptions:Rs,ngTransclude:Zs,ngModel:Es,ngList:hs,ngChange:rs,pattern:no,ngPattern:no,required:ao,ngRequired:ao,minlength:so,ngMinlength:so,maxlength:io,ngMaxlength:io,ngValue:ts,ngModelOptions:vs}).directive({ngInclude:ws}).directive(Pi).directive(gs),e.provider({$anchorScroll:Ft,$animate:ta,$animateCss:ea,$$animateJs:Qt,$$animateQueue:Jt,$$AnimateRunner:Xt,$$animateAsyncRun:Zt,$browser:na,$cacheFactory:ia,$controller:va,$document:ya,$exceptionHandler:ba,$filter:si,$$forceReflow:wa,$interpolate:Ra,$interval:qa,$http:Oa,$httpParamSerializer:Ma,$httpParamSerializerJQLike:Da,$httpBackend:Na,$xhrFactory:Ua,$location:sn,$log:on,$parse:Ln,$rootScope:Rn,$q:On,$$q:Un,$sce:Hn,$sceDelegate:zn,$sniffer:Wn,$templateCache:sa,$templateRequest:Kn,$$testability:Qn,$timeout:Jn,$window:ai,$$rAF:Bn,$$jqLite:Tt,$$HashMap:jt,$$cookieReader:ii})}]),S.module("ngLocale",[],["$provide",function(e){var n="one",i="other";e.value("$locale",{DATETIME_FORMATS:{AMPMS:["AM","PM"],DAY:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],ERANAMES:["Before Christ","Anno Domini"],ERAS:["BC","AD"],FIRSTDAYOFWEEK:6,MONTH:["January","February","March","April","May","June","July","August","September","October","November","December"],SHORTDAY:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],SHORTMONTH:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],STANDALONEMONTH:["January","February","March","April","May","June","July","August","September","October","November","December"],WEEKENDRANGE:[5,6],fullDate:"EEEE, MMMM d, y",longDate:"MMMM d, y",medium:"MMM d, y h:mm:ss a",mediumDate:"MMM d, y",mediumTime:"h:mm:ss a",short:"M/d/yy h:mm a",shortDate:"M/d/yy",shortTime:"h:mm a"},NUMBER_FORMATS:{CURRENCY_SYM:"$",DECIMAL_SEP:".",GROUP_SEP:",",PATTERNS:[{gSize:3,lgSize:3,maxFrac:3,minFrac:0,minInt:1,negPre:"-",negSuf:"",posPre:"",posSuf:""},{gSize:3,lgSize:3,maxFrac:2,minFrac:2,minInt:1,negPre:"-¤",negSuf:"",posPre:"¤",posSuf:""}]},id:"en-us",localeID:"en_US",pluralCat:function(e,t){var a=0|e,t=function(e,t){var a=t;void 0===a&&(a=Math.min((t=e,-1==(n=(t+="").indexOf("."))?0:t.length-n-1),3));var n=Math.pow(10,a);return{v:a,f:(e*n|0)%n}}(e,t);return 1==a&&0==t.v?n:i}})}]),me(h.document).ready(function(){oe(h.document,re)}))}(window),window.angular.$$csp().noInlineStyle||window.angular.element(document.head).prepend('<style type="text/css">@charset "UTF-8";[ng\\:cloak],[ng-cloak],[data-ng-cloak],[x-ng-cloak],.ng-cloak,.x-ng-cloak,.ng-hide:not(.ng-hide-animate){display:none !important;}ng\\:form{display:block;}.ng-animate-shim{visibility:hidden;}.ng-anchor{position:absolute;}</style>'),function(c,u){"use strict";var te,ae,ne=u.noop,ie=u.copy,d=u.extend,O=u.element,se=u.forEach,oe=u.isArray,U=u.isString,N=u.isObject,B=u.isUndefined,R=u.isDefined,w=u.isFunction,p=u.isElement,q=1,re="-add",le="-remove",ce="ng-",k="ng-animate",V="$$ngAnimateChildren",ue=B(c.ontransitionend)&&R(c.onwebkittransitionend)?(te="WebkitTransition","webkitTransitionEnd transitionend"):(te="transition","transitionend"),de=B(c.onanimationend)&&R(c.onwebkitanimationend)?(ae="WebkitAnimation","webkitAnimationEnd animationend"):(ae="animation","animationend"),n="Duration",pe="TimingFunction",i="PlayState",a=ae+"Delay",me=ae+n,s=te+"Delay",e=te+n,o=u.$$minErr("ng");function m(e,t,a){if(!e)throw o("areq","Argument '{0}' is {1}",t||"?",a||"required");return e}function x(e,t){return e||t?e?t?(e=oe(e)?e.join(" "):e)+" "+(t=oe(t)?t.join(" "):t):e:t:""}function ge(e,a,n){var i="";return e=oe(e)?e:e&&U(e)&&e.length?e.split(/\s+/):[],se(e,function(e,t){e&&0<e.length&&(i+=0<t?" ":"",i+=n?a+e:e+a)}),i}function Y(e){if(!e[0])return e;for(var t=0;t<e.length;t++){var a=e[t];if(a.nodeType==q)return a}}function fe(r){return function(e,t){var a,n,i,s,o;t.addClass&&(a=r,n=e,i=t.addClass,se(n,function(e){a.addClass(e,i)}),t.addClass=null),t.removeClass&&(s=r,e=e,o=t.removeClass,se(e,function(e){s.removeClass(e,o)}),t.removeClass=null)}}function he(e){var t;return(e=e||{}).$$prepared||(t=e.domOperation||ne,e.domOperation=function(){e.$$domOperationFired=!0,t(),t=ne},e.$$prepared=!0),e}function ve(e,t){ye(e,t),be(e,t)}function ye(e,t){t.from&&(e.css(t.from),t.from=null)}function be(e,t){t.to&&(e.css(t.to),t.to=null)}function F(e,t,a){var n=t.options||{},i=a.options||{},s=(n.addClass||"")+" "+(i.addClass||""),a=(n.removeClass||"")+" "+(i.removeClass||""),s=function(i,e,t){var a={};i=n(i),e=n(e),se(e,function(e,t){a[t]=1}),t=n(t),se(t,function(e,t){a[t]=1===a[t]?null:-1});var s={addClass:"",removeClass:""};function n(e){U(e)&&(e=e.split(" "));var t={};return se(e,function(e){e.length&&(t[e]=!0)}),t}return se(a,function(e,t){var a,n;1===e?(a="addClass",n=!i[t]):-1===e&&(a="removeClass",n=i[t]),n&&(s[a].length&&(s[a]+=" "),s[a]+=t)}),s}(e.attr("class"),s,a);i.preparationClasses&&(n.preparationClasses=z(i.preparationClasses,n.preparationClasses),delete i.preparationClasses);a=n.domOperation!==ne?n.domOperation:null;return d(n,i),a&&(n.domOperation=a),s.addClass?n.addClass=s.addClass:n.addClass=null,s.removeClass?n.removeClass=s.removeClass:n.removeClass=null,t.addClass=n.addClass,t.removeClass=n.removeClass,n}function we(e){return e instanceof u.element?e[0]:e}function $e(e,t){t=t?"-"+t+"s":"";return xe(e,[s,t]),1}function ke(e,t){var a=t?"paused":"",t=ae+i;return xe(e,[t,a]),[t,a]}function xe(e,t){var a=t[0],t=t[1];e.style[a]=t}function z(e,t){return e?t?e+" "+t:e:t}var t=["$interpolate",function(s){return{link:function(e,t,a){var n=a.ngAnimateChildren;function i(e){t.data(V,e="on"===e||"true"===e)}u.isString(n)&&0===n.length?t.data(V,!0):(i(s(n)(e)),a.$observe("ngAnimateChildren",i))}}}],_e="$$animateCss",r={transitionDuration:e,transitionDelay:s,transitionProperty:te+"Property",animationDuration:me,animationDelay:a,animationIterationCount:ae+"IterationCount"},Se={transitionDuration:e,transitionDelay:s,animationDuration:me,animationDelay:a};function Ie(e,t){return[t?a:s,e+"s"]}function Ce(e,t,a){var i=Object.create(null),s=e.getComputedStyle(t)||{};return se(a,function(e,t){var a,n=s[e];n&&(("-"===(e=n.charAt(0))||"+"===e||0<=e)&&(a=0,e=(e=n).split(/\s*,\s*/),se(e,function(e){"s"==e.charAt(e.length-1)&&(e=e.substring(0,e.length-1)),e=parseFloat(e)||0,a=a?Math.max(e,a):e}),n=a),i[t]=n=0===n?null:n)}),i}function Ae(e){return 0===e||null!=e}function Me(e,t){var a=te,e=e+"s";return t?a+=n:e+=" linear all",[a,e]}function l(){var a=Object.create(null);return{flush:function(){a=Object.create(null)},count:function(e){e=a[e];return e?e.total:0},get:function(e){e=a[e];return e&&e.value},put:function(e,t){a[e]?a[e].total++:a[e]={total:1,value:t}}}}function De(t,a,e){se(e,function(e){t[e]=R(t[e])?t[e]:a.style.getPropertyValue(e)})}var g=["$animateProvider",function(e){var X=l(),ee=l();this.$get=["$window","$$jqLite","$$AnimateRunner","$timeout","$$forceReflow","$sniffer","$$rAFScheduler","$$animateQueue",function(Y,F,z,H,a,W,t,G){var K=fe(F),i=0;function Q(e,t){var a="$$ngAnimateParentKey",n=e.parentNode;return(n[a]||(n[a]=++i))+"-"+e.getAttribute("class")+"-"+t}var n=[];function J(e){n.push(e),t.waitUntilQuiet(function(){X.flush(),ee.flush();for(var e=a(),t=0;t<n.length;t++)n[t](e);n.length=0})}function Z(e,t,a){var n,e=(n=e,i=a,e=r,(a=X.get(i))||"infinite"===(a=Ce(Y,n,e)).animationIterationCount&&(a.animationIterationCount=1),X.put(i,a),a),i=e.animationDelay,a=e.transitionDelay;return e.maxDelay=i&&a?Math.max(i,a):i||a,e.maxDuration=Math.max(e.animationDuration*e.animationIterationCount,e.transitionDuration),e}return function(o,e){var r=e||{};r.$$prepared||(r=he(ie(r)));var l={},c=we(o);if(!c||!c.parentNode||!G.enabled())return R();var u,n,i,a,d,p,m,g,f=[],t=o.attr("class"),s=(y={},(v=r)&&(v.to||v.from)&&(y.to=v.to,y.from=v.from),y),h=[];if(0===r.duration||!W.animations&&!W.transitions)return R();var e=r.event&&oe(r.event)?r.event.join(" "):r.event,v="",y="";e&&r.structural?v=ge(e,ce,!0):e&&(v=e),r.addClass&&(y+=ge(r.addClass,re)),r.removeClass&&(y.length&&(y+=" "),y+=ge(r.removeClass,le)),r.applyClassesEarly&&y.length&&K(o,r);var b,w,$,k,x,_,S=[v,y].join(" ").trim(),I=t+" "+S,C=ge(S,"-active"),e=s.to&&0<Object.keys(s.to).length;if(!(0<(r.keyframeStyle||"").length)&&!e&&!S)return R();w=0<r.stagger?{transitionDelay:$=parseFloat(r.stagger),animationDelay:$,transitionDuration:0,animationDuration:0}:(b=Q(c,I),v=c,t=S,s=b,$=Se,0<X.count(s)&&((k=ee.get(s))||(t=ge(t,"-stagger"),F.addClass(v,t),(k=Ce(Y,v,$)).animationDuration=Math.max(k.animationDuration,0),k.transitionDuration=Math.max(k.transitionDuration,0),F.removeClass(v,t),ee.put(s,k))),k||{}),r.$$skipPreparationClasses||F.addClass(o,S),r.transitionStyle&&(_=[te,r.transitionStyle],xe(c,_),f.push(_)),0<=r.duration&&(x=0<c.style[te].length,_=Me(r.duration,x),xe(c,_),f.push(_)),r.keyframeStyle&&(M=[ae,r.keyframeStyle],xe(c,M),f.push(M));var A=w?0<=r.staggerIndex?r.staggerIndex:X.count(b):0,M=0===A;M&&!r.skipBlocking&&$e(c,9999);var D,T=Z(c,0,b),P=T.maxDelay,E=Math.max(P,0),j=T.maxDuration,L={};return L.hasTransitions=0<T.transitionDuration,L.hasAnimations=0<T.animationDuration,L.hasTransitionAll=L.hasTransitions&&"all"==T.transitionProperty,L.applyTransitionDuration=e&&(L.hasTransitions&&!L.hasTransitionAll||L.hasAnimations&&!L.hasTransitions),L.applyAnimationDuration=r.duration&&L.hasAnimations,L.applyTransitionDelay=Ae(r.delay)&&(L.applyTransitionDuration||L.hasTransitions),L.applyAnimationDelay=Ae(r.delay)&&L.hasAnimations,L.recalculateTimingStyles=0<y.length,(L.applyTransitionDuration||L.applyAnimationDuration)&&(j=r.duration?parseFloat(r.duration):j,L.applyTransitionDuration&&(L.hasTransitions=!0,T.transitionDuration=j,x=0<c.style[te+"Property"].length,f.push(Me(j,x))),L.applyAnimationDuration&&(L.hasAnimations=!0,T.animationDuration=j,f.push([me,j+"s"]))),0!==j||L.recalculateTimingStyles?(null!=r.delay&&("boolean"!=typeof r.delay&&(D=parseFloat(r.delay),E=Math.max(D,0)),L.applyTransitionDelay&&f.push(Ie(D)),L.applyAnimationDelay&&f.push(Ie(D,!0))),null==r.duration&&0<T.transitionDuration&&(L.recalculateTimingStyles=L.recalculateTimingStyles||M),p=1e3*E,m=1e3*j,r.skipBlocking||(L.blockTransition=0<T.transitionDuration,L.blockKeyframeAnimation=0<T.animationDuration&&0<w.animationDelay&&0===w.animationDuration),r.from&&(r.cleanupStyles&&De(l,c,Object.keys(r.from)),ye(o,r)),L.blockTransition||L.blockKeyframeAnimation?B(j):r.skipBlocking||$e(c,!1),{$$willAnimate:!0,end:O,start:function(){if(!u)return a=new z(d={end:O,cancel:U,resume:null,pause:null}),J(V),a}}):R();function O(){N()}function U(){N(!0)}function N(e){var t;u||i&&n||(n=!(u=!0),r.$$skipPreparationClasses||F.removeClass(o,S),F.removeClass(o,C),ke(c,!1),$e(c,!1),se(f,function(e){c.style[e[0]]=""}),K(o,r),ve(o,r),Object.keys(l).length&&se(l,function(e,t){e?c.style.setProperty(t,e):c.style.removeProperty(t)}),r.onDone&&r.onDone(),h&&h.length&&o.off(h.join(" "),q),(t=o.data(_e))&&(H.cancel(t[0].timer),o.removeData(_e)),a&&a.complete(!e))}function B(e){L.blockTransition&&$e(c,e),L.blockKeyframeAnimation&&ke(c,!!e)}function R(){return a=new z({end:O,cancel:U}),J(ne),N(),{$$willAnimate:!1,start:function(){return a},end:O}}function q(e){e.stopPropagation();var t=e.originalEvent||e,e=t.$manualTimeStamp||Date.now(),t=parseFloat(t.elapsedTime.toFixed(3));Math.max(e-g,0)>=p&&j<=t&&(i=!0,N())}function V(){var e,t;function a(){if(!u){if(B(!1),se(f,function(e){var t=e[0],e=e[1];c.style[t]=e}),K(o,r),F.addClass(o,C),L.recalculateTimingStyles){if(I=c.className+" "+S,b=Q(c,I),T=Z(c,0,b),P=T.maxDelay,E=Math.max(P,0),0===(j=T.maxDuration))return void N();L.hasTransitions=0<T.transitionDuration,L.hasAnimations=0<T.animationDuration}L.applyAnimationDelay&&(P="boolean"!=typeof r.delay&&Ae(r.delay)?parseFloat(r.delay):P,E=Math.max(P,0),T.animationDelay=P,D=Ie(P,!0),f.push(D),c.style[D[0]]=D[1]),p=1e3*E,m=1e3*j,r.easing&&(e=r.easing,L.hasTransitions&&(f.push([i=te+pe,e]),c.style[i]=e),L.hasAnimations&&(f.push([i=ae+pe,e]),c.style[i]=e)),T.transitionDuration&&h.push(ue),T.animationDuration&&h.push(de),g=Date.now();var e,t=p+1.5*m,a=g+t,n=o.data(_e)||[],i=!0;n.length&&((i=a>(e=n[0]).expectedEndTime)?H.cancel(e.timer):n.push(N)),i&&(t=H(s,t,!1),n[0]={timer:t,expectedEndTime:a},n.push(N),o.data(_e,n)),h.length&&o.on(h.join(" "),q),r.to&&(r.cleanupStyles&&De(l,c,Object.keys(r.to)),be(o,r))}}function s(){var e=o.data(_e);if(e){for(var t=1;t<e.length;t++)e[t]();o.removeData(_e)}}u||(c.parentNode?(e=function(e){var t,a;i?n&&e&&(n=!1,N()):(n=!e,T.animationDuration&&(a=ke(c,n),n?f.push(a):(t=a,a=(e=f).indexOf(t),0<=t&&e.splice(a,1))))},(t=0<A&&(T.transitionDuration&&0===w.transitionDuration||T.animationDuration&&0===w.animationDuration)&&Math.max(w.animationDelay,w.transitionDelay))?H(a,Math.floor(t*A*1e3),!1):a(),d.resume=function(){e(!0)},d.pause=function(){e(!1)}):N())}}}]}],f=["$$animationProvider",function(e){e.drivers.push("$$animateCssDriver");var b="ng-animate-shim",w="ng-anchor-out";this.$get=["$animateCss","$rootScope","$$AnimateRunner","$rootElement","$sniffer","$$jqLite","$document",function(m,e,g,t,a,n,i){if(!a.animations&&!a.transitions)return ne;var f=i[0].body,i=we(t),h=O((t=i).parentNode&&11===t.parentNode.nodeType||f.contains(i)?i:f);fe(n);return function(e){return e.from&&e.to?function(e,t,a,n){var i=l(e),s=l(t),o=[];if(se(n,function(e){var t=e["out"];var a=e["in"];var n=r(0,t,a);if(n)o.push(n)}),i||s||0!==o.length)return{start:function(){var t=[];i&&t.push(i.start()),s&&t.push(s.start()),se(o,function(e){t.push(e.start())});var a=new g({end:e,cancel:e});return g.all(t,function(e){a.complete(e)}),a;function e(){se(t,function(e){e.end()})}}}}(e.from,e.to,e.classes,e.anchors):l(e)};function v(e){return e.replace(/\bng-\S+\b/g,"")}function y(e,t){return U(e)&&(e=e.split(" ")),U(t)&&(t=t.split(" ")),e.filter(function(e){return-1===t.indexOf(e)}).join(" ")}function r(e,t,a){var n=O(we(t).cloneNode(!0)),i=v(u(n));t.addClass(b),a.addClass(b),n.addClass("ng-anchor"),h.append(n);var s,o,r=(o=m(n,{addClass:w,delay:!0,from:c(t)})).$$willAnimate?o:null;if(!r&&!(s=d()))return p();var l=r||s;return{start:function(){var e,t=l.start();return t.done(function(){return t=null,!s&&(s=d())?((t=s.start()).done(function(){t=null,p(),e.complete()}),t):(p(),void e.complete())}),e=new g({end:a,cancel:a});function a(){t&&t.end()}}};function c(e){var a={},n=we(e).getBoundingClientRect();return se(["width","height","top","left"],function(e){var t=n[e];switch(e){case"top":t+=f.scrollTop;break;case"left":t+=f.scrollLeft}a[e]=Math.floor(t)+"px"}),a}function u(e){return e.attr("class")||""}function d(){var e=v(u(a)),t=y(e,i),e=y(i,e),e=m(n,{to:c(a),addClass:"ng-anchor-in "+t,removeClass:w+" "+e,delay:!0});return e.$$willAnimate?e:null}function p(){n.remove(),t.removeClass(b),a.removeClass(b)}}function l(e){var t=e.element,a=e.options||{};e.structural&&(a.event=e.event,a.structural=!0,a.applyClassesEarly=!0,"leave"===e.event&&(a.onDone=a.domOperation)),a.preparationClasses&&(a.event=z(a.event,a.preparationClasses));a=m(t,a);return a.$$willAnimate?a:null}}]}],h=["$animateProvider",function(b){this.$get=["$injector","$$AnimateRunner","$$jqLite",function(h,v,e){var y=fe(e);return function(e,t,a,n){var i=!1;3===arguments.length&&N(a)&&(n=a,a=null),n=he(n),a||(a=e.attr("class")||"",n.addClass&&(a+=" "+n.addClass),n.removeClass&&(a+=" "+n.removeClass));var s,o,r,l,c=n.addClass,u=n.removeClass,d=function(e){e=oe(e)?e:e.split(" ");for(var t=[],a={},n=0;n<e.length;n++){var i=e[n],s=b.$$registeredAnimations[i];s&&!a[i]&&(t.push(h.get(s)),a[i]=!0)}return t}(a);if(d.length&&(a="leave"==t?(r="leave","afterLeave"):(r="before"+t.charAt(0).toUpperCase()+t.substr(1),t),"enter"!==t&&"move"!==t&&(s=f(e,t,n,d,r)),o=f(e,t,n,d,a)),s||o)return{$$willAnimate:!0,end:function(){return l?l.end():(m(),(l=new v).complete(!0)),l},start:function(){if(l)return l;var t;l=new v;var e=[];return s&&e.push(function(e){t=s(e)}),e.length?e.push(function(e){p(),e(!0)}):p(),o&&e.push(function(e){t=o(e)}),l.setHost({end:function(){n()},cancel:function(){n(!0)}}),v.chain(e,a),l;function a(e){m(),l.complete(e)}function n(e){i||((t||ne)(e),a(e))}}};function p(){n.domOperation(),y(e,n)}function m(){i=!0,p(),ve(e,n)}function g(o,r,l,e,t){var a=[];return se(e,function(e){var s=e[t];s&&a.push(function(){function t(e){a||(a=!0,(i||ne)(e),n.complete(!e))}var a=!1,n=new v({end:function(){t()},cancel:function(){t(!0)}}),i=function(e,t,a,n,i){var s;switch(a){case"animate":s=[t,n.from,n.to,i];break;case"setClass":s=[t,c,u,i];break;case"addClass":s=[t,c,i];break;case"removeClass":s=[t,u,i];break;default:s=[t,i]}if(s.push(n),e=e.apply(e,s))if((e=w(e.start)?e.start():e)instanceof v)e.done(i);else if(w(e))return e;return ne}(s,o,r,l,function(e){t(!1===e)});return n})}),a}function f(e,t,a,n,i){var s,o,r=g(e,t,a,n,i);if(0===r.length&&("beforeSetClass"===i?(s=g(e,"removeClass",a,n,"beforeRemoveClass"),o=g(e,"addClass",a,n,"beforeAddClass")):"setClass"===i&&(s=g(e,"removeClass",a,n,"removeClass"),o=g(e,"addClass",a,n,"addClass")),s&&(r=r.concat(s)),o&&(r=r.concat(o))),0!==r.length)return function(e){var a=[];return r.length&&se(r,function(e){a.push(e())}),a.length?v.all(a,e):e(),function(t){se(a,function(e){t?e.cancel():e.end()})}}}}}]}],v=["$$animationProvider",function(e){e.drivers.push("$$animateJsDriver"),this.$get=["$$animateJs","$$AnimateRunner",function(i,s){return function(e){if(!e.from||!e.to)return t(e);var n=t(e.from),i=t(e.to);return n||i?{start:function(){var e=[];n&&e.push(n.start()),i&&e.push(i.start()),s.all(e,function(e){t.complete(e)});var t=new s({end:a(),cancel:a()});return t;function a(){return function(){se(e,function(e){e.end()})}}}}:void 0};function t(e){var t=e.element,a=e.event,n=e.options,e=e.classes;return i(t,a,e,n)}}]}],H="data-ng-animate",W="$ngAnimatePin",y=["$animateProvider",function(l){var n=" ",i=this.rules={skip:[],cancel:[],join:[]};function s(e,t){if(e&&t){var a=function(e){if(!e)return null;var e=e.split(n),t=Object.create(null);return se(e,function(e){t[e]=!0}),t}(t);return e.split(n).some(function(e){return a[e]})}}function j(e,t,a,n){return i[e].some(function(e){return e(t,a,n)})}function L(e,t){var a=0<(e.addClass||"").length,e=0<(e.removeClass||"").length;return t?a&&e:a||e}i.join.push(function(e,t,a){return!t.structural&&L(t)}),i.skip.push(function(e,t,a){return!t.structural&&!L(t)}),i.skip.push(function(e,t,a){return"leave"==a.event&&t.structural}),i.skip.push(function(e,t,a){return a.structural&&2===a.state&&!t.structural}),i.cancel.push(function(e,t,a){return a.structural&&t.structural}),i.cancel.push(function(e,t,a){return 2===a.state&&t.structural}),i.cancel.push(function(e,t,a){if(a.structural)return!1;var n=t.addClass,i=t.removeClass,t=a.addClass,a=a.removeClass;return!(B(n)&&B(i)||B(t)&&B(a))&&(s(n,a)||s(i,t))}),this.$get=["$$rAF","$rootScope","$rootElement","$document","$$HashMap","$$animation","$$AnimateRunner","$templateRequest","$$jqLite","$$forceReflow",function(h,v,y,b,e,w,$,t,a,n){var k=new e,x=new e,_=null;var i=v.$watch(function(){return 0===t.totalPendingRequests},function(e){e&&(i(),v.$$postDigest(function(){v.$$postDigest(function(){null===_&&(_=!0)})}))}),S={},s=l.classNameFilter(),I=s?function(e){return s.test(e)}:function(){return!0},C=fe(a);function A(e,t){return F(e,t,{})}var M=c.Node.prototype.contains||function(e){return this===e||!!(16&this.compareDocumentPosition(e))};function o(e,t,a){var n=Y(t);return e.filter(function(e){return!(e.node===n&&(!a||e.callback===a))})}function D(e,t){"close"!==e||t[0].parentNode||r.off(t)}var r={on:function(e,t,a){var n=Y(t);S[e]=S[e]||[],S[e].push({node:n,callback:a}),O(t).on("$destroy",function(){k.get(n)||r.off(e,t,a)})},off:function(e,t,a){if(1!==arguments.length||u.isString(e)){var n=S[e];n&&(S[e]=1===arguments.length?null:o(n,t,a))}else for(var i in t=e,S)S[i]=o(S[i],t)},pin:function(e,t){m(p(e),"element","not an element"),m(p(t),"parentElement","not an element"),e.data(W,t)},push:function(e,t,a,n){return(a=a||{}).domOperation=n,function(c,n,e){var i,u,s=ie(e);(c=function(e){if(e instanceof O)switch(e.length){case 0:return e;case 1:if(e[0].nodeType===q)return e;break;default:return O(Y(e))}if(e.nodeType===q)return O(e)}(c))&&(i=we(c),u=c.parent());s=he(s);var o=new $,t=function(){var t=!1;return function(e){t?e():v.$$postDigest(function(){t=!0,e()})}}();oe(s.addClass)&&(s.addClass=s.addClass.join(" "));s.addClass&&!U(s.addClass)&&(s.addClass=null);oe(s.removeClass)&&(s.removeClass=s.removeClass.join(" "));s.removeClass&&!U(s.removeClass)&&(s.removeClass=null);s.from&&!N(s.from)&&(s.from=null);s.to&&!N(s.to)&&(s.to=null);if(!i)return f(),o;var a=[i.className,s.addClass,s.removeClass].join(" ");if(!I(a))return f(),o;var r=0<=["enter","move","leave"].indexOf(n),l=b[0].hidden,d=!_||l||x.get(i),e=!d&&k.get(i)||{},a=!!e.state;d||a&&1==e.state||(d=!function(e,t){var a,n=O(b[0].body),i=P(e,n)||"HTML"===e[0].nodeName,s=P(e,y),o=!1,r=x.get(we(e)),l=O.data(e[0],W);l&&(t=l);t=we(t);for(;t&&(s=s||P(t,y),t.nodeType===q);){var c=k.get(t)||{};if(!o){var u=x.get(t);if(!0===u&&!1!==r){r=!0;break}!1===u&&(r=!1),o=c.structural}if(!B(a)&&!0!==a||(c=O.data(t,V),R(c)&&(a=c)),o&&!1===a)break;if((i=i||P(t,n))&&s)break;t=s||!(l=O.data(t,W))?t.parentNode:we(l)}return(!o||a)&&!0!==r&&s&&i}(c,u));if(d)return l&&g(o,n,"start"),f(),l&&g(o,n,"close"),o;r&&function(e){e=we(e).querySelectorAll("["+H+"]");se(e,function(e){var t=parseInt(e.getAttribute(H)),a=k.get(e);if(a)switch(t){case 2:a.runner.end();case 1:k.remove(e)}})}(c);l={structural:r,element:c,event:n,addClass:s.addClass,removeClass:s.removeClass,close:f,options:s,runner:o};if(a){if(j("skip",c,l,e))return 2===e.state?(f(),o):(F(c,e,l),e.runner);var p=j("cancel",c,l,e);if(p)if(2===e.state)e.runner.end();else{if(!e.structural)return F(c,e,l),e.runner;e.close()}else if(j("join",c,l,e)){if(2!==e.state)return function(e,t,a){var n="";t&&(n=ge(t,ce,!0)),a.addClass&&(n=z(n,ge(a.addClass,re))),(n=a.removeClass?z(n,ge(a.removeClass,le)):n).length&&(a.preparationClasses=n,e.addClass(n))}(c,r?n:null,s),n=l.event=e.event,s=F(c,e,l),e.runner;A(c,l)}}else A(c,l);p=l.structural;p=p||("animate"===l.event&&0<Object.keys(l.options.to||{}).length||L(l));if(!p)return f(),T(c),o;var m=(e.counter||0)+1;return l.counter=m,E(c,1,l),v.$$postDigest(function(){var e=!(t=k.get(i)),t=t||{},a=0<(c.parent()||[]).length&&("animate"===t.event||t.structural||L(t));if(e||t.counter!==m||!a)return e&&(C(c,s),ve(c,s)),(e||r&&t.event!==n)&&(s.domOperation(),o.end()),void(a||T(c));n=!t.structural&&L(t,!0)?"setClass":t.event,E(c,2);t=w(c,n,t.options);o.setHost(t),g(o,n,"start",{}),t.done(function(e){f(!e);e=k.get(i);e&&e.counter===m&&T(we(c)),g(o,n,"close",{})})}),o;function g(e,o,r,l){t(function(){var e,t,a,n,i,s=(e=u,t=o,a=we(c),n=we(e),i=[],(e=S[t])&&se(e,function(e){(M.call(e.node,a)||"leave"===t&&M.call(e.node,n))&&i.push(e.callback)}),i);s.length?h(function(){se(s,function(e){e(c,r,l)}),D(r,c)}):D(r,c)}),e.progress(o,r,l)}function f(e){var t,a;t=c,(a=s).preparationClasses&&(t.removeClass(a.preparationClasses),a.preparationClasses=null),a.activeClasses&&(t.removeClass(a.activeClasses),a.activeClasses=null),C(c,s),ve(c,s),s.domOperation(),o.complete(!e)}}(e,t,a)},enabled:function(e,t){var a,n,i=arguments.length;return 0===i?t=!!_:p(e)?(a=we(e),n=x.get(a),1===i?t=!n:x.put(a,!t)):t=_=!!e,t}};return r;function T(e){e=we(e);e.removeAttribute(H),k.remove(e)}function P(e,t){return we(e)===we(t)}function E(e,t,a){(a=a||{}).state=t;e=we(e);e.setAttribute(H,t);t=k.get(e),a=t?d(t,a):a;k.put(e,a)}}]}],e=["$animateProvider",function(e){var y="ng-animate-ref",b=this.drivers=[],w="$$animationRunner";function $(e){return e.data(w)}this.$get=["$$jqLite","$rootScope","$injector","$$AnimateRunner","$$HashMap","$$rAFScheduler",function(u,d,p,m,n,g){var f=[],h=fe(u);function v(e){for(var s={children:[]},o=new n,t=0;t<e.length;t++){var a=e[t];o.put(a.domNode,e[t]={domNode:a.domNode,fn:a.fn,children:[]})}for(t=0;t<e.length;t++)!function e(t){if(t.processed)return t;t.processed=!0;var a=t.domNode;var n=a.parentNode;o.put(a,t);var i;for(;n;){if(i=o.get(n)){i.processed||(i=e(i));break}n=n.parentNode}(i||s).children.push(t);return t}(e[t]);return function(e){var t,a=[],n=[];for(t=0;t<e.children.length;t++)n.push(e.children[t]);var i=n.length,s=0,o=[];for(t=0;t<n.length;t++){var r=n[t];i<=0&&(i=s,s=0,a.push(o),o=[]),o.push(r.fn),r.children.forEach(function(e){s++,n.push(e)}),i--}o.length&&a.push(o);return a}(s)}return function(t,a,n){n=he(n);var e=0<=["enter","move","leave"].indexOf(a),i=new m({end:function(){c()},cancel:function(){c(!0)}});if(!b.length)return c(),i;o=i,t.data(w,o);var s,o=x(t.attr("class"),x(n.addClass,n.removeClass)),r=n.tempClasses;return r&&(o+=" "+r,n.tempClasses=null),e&&u.addClass(t,s="ng-"+a+"-prepare"),f.push({element:t,classes:o,event:a,structural:e,options:n,beforeStart:function(){t.addClass(k),r&&u.addClass(t,r);s&&(u.removeClass(t,s),s=null)},close:c}),t.on("$destroy",l),1<f.length||d.$$postDigest(function(){var t=[];se(f,function(e){$(e.element)?t.push(e):e.close()}),f.length=0;var e=function(r){var l=[],c={};se(r,function(e,a){var t,n,i,s=we(e.element),o=e.event,o=0<=["enter","move"].indexOf(o),t=e.structural?(t=(t=s).hasAttribute(y)?[t]:t.querySelectorAll("[ng-animate-ref]"),n=[],se(t,function(e){var t=e.getAttribute(y);t&&t.length&&n.push(e)}),n):[];t.length?(i=o?"to":"from",se(t,function(e){var t=e.getAttribute(y);c[t]=c[t]||{},c[t][i]={animationID:a,element:O(e)}})):l.push(e)});var u={},d={};return se(c,function(e,t){var a,n,i,s=e.from,o=e.to;s&&o?(a=r[s.animationID],n=r[o.animationID],i=s.animationID.toString(),d[i]||((e=d[i]={structural:!0,beforeStart:function(){a.beforeStart(),n.beforeStart()},close:function(){a.close(),n.close()},classes:function(e,t){e=e.split(" "),t=t.split(" ");for(var a=[],n=0;n<e.length;n++){var i=e[n];if("ng-"!==i.substring(0,3))for(var s=0;s<t.length;s++)if(i===t[s]){a.push(i);break}}return a.join(" ")}(a.classes,n.classes),from:a,to:n,anchors:[]}).classes.length?l.push(e):(l.push(a),l.push(n))),d[i].anchors.push({out:s.element,in:o.element})):(o=(s=(s||o).animationID).toString(),u[o]||(u[o]=!0,l.push(r[s])))}),l}(t),a=[];se(e,function(s){a.push({domNode:we((s.from||s).element),fn:function(){s.beforeStart();var e,t,a,n=s.close;function i(e){e=$(e);e&&e.setHost(a)}!$(s.anchors?s.from.element||s.to.element:s.element)||(e=function(e){for(var t=b.length-1;0<=t;t--){var a=b[t];if(p.has(a)){a=p.get(a)(e);if(a)return a}}}(s))&&(t=e.start),t?((t=t()).done(function(e){n(!e)}),a=t,(t=s).from&&t.to?(i(t.from.element),i(t.to.element)):i(t.element)):n()}})}),g(v(a))}),i;function l(){var e=$(t);!e||"leave"===a&&n.$$domOperationFired||e.end()}function c(e){t.off("$destroy",l),t.removeData(w),h(t,n),ve(t,n),n.domOperation(),r&&u.removeClass(t,r),t.removeClass(k),i.complete(!e)}}}]}];u.module("ngAnimate",[]).directive("ngAnimateSwap",["$animate","$rootScope",function(r,e){return{restrict:"A",transclude:"element",terminal:!0,priority:600,link:function(t,a,e,n,i){var s,o;t.$watchCollection(e.ngAnimateSwap||e.for,function(e){s&&r.leave(s),o&&(o.$destroy(),o=null),!e&&0!==e||(o=t.$new(),i(o,function(e){s=e,r.enter(e,null,a)}))})}}}]).directive("ngAnimateChildren",t).factory("$$rAFScheduler",["$$rAF",function(a){var n,i;function e(e){n=n.concat(e),s()}return n=e.queue=[],e.waitUntilQuiet=function(e){i&&i(),i=a(function(){i=null,e(),s()})},e;function s(){if(n.length){for(var e=n.shift(),t=0;t<e.length;t++)e[t]();i||a(function(){i||s()})}}}]).provider("$$animateQueue",y).provider("$$animation",e).provider("$animateCss",g).provider("$$animateCssDriver",f).provider("$$animateJs",h).provider("$$animateJsDriver",v)}(window,window.angular),angular.module("ui.bootstrap",["ui.bootstrap.tpls","ui.bootstrap.collapse","ui.bootstrap.tabindex","ui.bootstrap.accordion","ui.bootstrap.alert","ui.bootstrap.buttons","ui.bootstrap.carousel","ui.bootstrap.dateparser","ui.bootstrap.isClass","ui.bootstrap.datepicker","ui.bootstrap.position","ui.bootstrap.datepickerPopup","ui.bootstrap.debounce","ui.bootstrap.dropdown","ui.bootstrap.stackedMap","ui.bootstrap.modal","ui.bootstrap.paging","ui.bootstrap.pager","ui.bootstrap.pagination","ui.bootstrap.tooltip","ui.bootstrap.popover","ui.bootstrap.progressbar","ui.bootstrap.rating","ui.bootstrap.tabs","ui.bootstrap.timepicker","ui.bootstrap.typeahead"]),angular.module("ui.bootstrap.tpls",["uib/template/accordion/accordion-group.html","uib/template/accordion/accordion.html","uib/template/alert/alert.html","uib/template/carousel/carousel.html","uib/template/carousel/slide.html","uib/template/datepicker/datepicker.html","uib/template/datepicker/day.html","uib/template/datepicker/month.html","uib/template/datepicker/year.html","uib/template/datepickerPopup/popup.html","uib/template/modal/window.html","uib/template/pager/pager.html","uib/template/pagination/pagination.html","uib/template/tooltip/tooltip-html-popup.html","uib/template/tooltip/tooltip-popup.html","uib/template/tooltip/tooltip-template-popup.html","uib/template/popover/popover-html.html","uib/template/popover/popover-template.html","uib/template/popover/popover.html","uib/template/progressbar/bar.html","uib/template/progressbar/progress.html","uib/template/progressbar/progressbar.html","uib/template/rating/rating.html","uib/template/tabs/tab.html","uib/template/tabs/tabset.html","uib/template/timepicker/timepicker.html","uib/template/typeahead/typeahead-match.html","uib/template/typeahead/typeahead-popup.html"]),angular.module("ui.bootstrap.collapse",[]).directive("uibCollapse",["$animate","$q","$parse","$injector",function(m,g,f,e){var h=e.has("$animateCss")?e.get("$animateCss"):null;return{link:function(t,a,e){var n=f(e.expanding),i=f(e.expanded),s=f(e.collapsing),o=f(e.collapsed),r=!1,l={},c={};function u(e){return r?{width:e.scrollWidth+"px"}:{height:e.scrollHeight+"px"}}function d(){a.removeClass("collapsing").addClass("collapse").css(l),i(t)}function p(){a.css(c),a.removeClass("collapsing").addClass("collapse"),o(t)}!function(){c=(r=!!("horizontal"in e))?(l={width:"auto",height:"inherit"},{width:"0"}):(l={width:"inherit",height:"auto"},{height:"0"});t.$eval(e.uibCollapse)||a.addClass("in").addClass("collapse").attr("aria-expanded",!0).attr("aria-hidden",!1).css(l)}(),t.$watch(e.uibCollapse,function(e){e?function(){if(!a.hasClass("collapse")&&!a.hasClass("in"))return p();g.resolve(s(t)).then(function(){a.css(u(a[0])).removeClass("collapse").addClass("collapsing").attr("aria-expanded",!1).attr("aria-hidden",!0),h?h(a,{removeClass:"in",to:c}).start().finally(p):m.removeClass(a,"in",{to:c}).then(p)})}():a.hasClass("collapse")&&a.hasClass("in")||g.resolve(n(t)).then(function(){a.removeClass("collapse").addClass("collapsing").attr("aria-expanded",!0).attr("aria-hidden",!1),h?h(a,{addClass:"in",easing:"ease",to:u(a[0])}).start().finally(d):m.addClass(a,"in",{to:u(a[0])}).then(d)})})}}}]),angular.module("ui.bootstrap.tabindex",[]).directive("uibTabindexToggle",function(){return{restrict:"A",link:function(e,t,a){a.$observe("disabled",function(e){a.$set("tabindex",e?-1:null)})}}}),angular.module("ui.bootstrap.accordion",["ui.bootstrap.collapse","ui.bootstrap.tabindex"]).constant("uibAccordionConfig",{closeOthers:!0}).controller("UibAccordionController",["$scope","$attrs","uibAccordionConfig",function(e,a,n){this.groups=[],this.closeOthers=function(t){(angular.isDefined(a.closeOthers)?e.$eval(a.closeOthers):n.closeOthers)&&angular.forEach(this.groups,function(e){e!==t&&(e.isOpen=!1)})},this.addGroup=function(t){var a=this;this.groups.push(t),t.$on("$destroy",function(e){a.removeGroup(t)})},this.removeGroup=function(e){e=this.groups.indexOf(e);-1!==e&&this.groups.splice(e,1)}}]).directive("uibAccordion",function(){return{controller:"UibAccordionController",controllerAs:"accordion",transclude:!0,templateUrl:function(e,t){return t.templateUrl||"uib/template/accordion/accordion.html"}}}).directive("uibAccordionGroup",function(){return{require:"^uibAccordion",transclude:!0,restrict:"A",templateUrl:function(e,t){return t.templateUrl||"uib/template/accordion/accordion-group.html"},scope:{heading:"@",panelClass:"@?",isOpen:"=?",isDisabled:"=?"},controller:function(){this.setHeading=function(e){this.heading=e}},link:function(t,a,e,n){a.addClass("panel"),n.addGroup(t),t.openClass=e.openClass||"panel-open",t.panelClass=e.panelClass||"panel-default",t.$watch("isOpen",function(e){a.toggleClass(t.openClass,!!e),e&&n.closeOthers(t)}),t.toggleOpen=function(e){t.isDisabled||e&&32!==e.which||(t.isOpen=!t.isOpen)};e="accordiongroup-"+t.$id+"-"+Math.floor(1e4*Math.random());t.headingId=e+"-tab",t.panelId=e+"-panel"}}}).directive("uibAccordionHeading",function(){return{transclude:!0,template:"",replace:!0,require:"^uibAccordionGroup",link:function(e,t,a,n,i){n.setHeading(i(e,angular.noop))}}}).directive("uibAccordionTransclude",function(){return{require:"^uibAccordionGroup",link:function(e,a,t,n){e.$watch(function(){return n[t.uibAccordionTransclude]},function(e){var t;e&&((t=angular.element(a[0].querySelector("uib-accordion-header,data-uib-accordion-header,x-uib-accordion-header,uib\\:accordion-header,[uib-accordion-header],[data-uib-accordion-header],[x-uib-accordion-header]"))).html(""),t.append(e))})}}}),angular.module("ui.bootstrap.alert",[]).controller("UibAlertController",["$scope","$element","$attrs","$interpolate","$timeout",function(e,t,a,n,i){e.closeable=!!a.close,t.addClass("alert"),a.$set("role","alert"),e.closeable&&t.addClass("alert-dismissible");a=angular.isDefined(a.dismissOnTimeout)?n(a.dismissOnTimeout)(e.$parent):null;a&&i(function(){e.close()},parseInt(a,10))}]).directive("uibAlert",function(){return{controller:"UibAlertController",controllerAs:"alert",restrict:"A",templateUrl:function(e,t){return t.templateUrl||"uib/template/alert/alert.html"},transclude:!0,scope:{close:"&"}}}),angular.module("ui.bootstrap.buttons",[]).constant("uibButtonConfig",{activeClass:"active",toggleEvent:"click"}).controller("UibButtonsController",["uibButtonConfig",function(e){this.activeClass=e.activeClass||"active",this.toggleEvent=e.toggleEvent||"click"}]).directive("uibBtnRadio",["$parse",function(o){return{require:["uibBtnRadio","ngModel"],controller:"UibButtonsController",controllerAs:"buttons",link:function(t,a,n,e){var i=e[0],s=e[1],e=o(n.uibUncheckable);a.find("input").css({display:"none"}),s.$render=function(){a.toggleClass(i.activeClass,angular.equals(s.$modelValue,t.$eval(n.uibBtnRadio)))},a.on(i.toggleEvent,function(){var e;n.disabled||((e=a.hasClass(i.activeClass))&&!angular.isDefined(n.uncheckable)||t.$apply(function(){s.$setViewValue(e?null:t.$eval(n.uibBtnRadio)),s.$render()}))}),n.uibUncheckable&&t.$watch(e,function(e){n.$set("uncheckable",e?"":void 0)})}}}]).directive("uibBtnCheckbox",function(){return{require:["uibBtnCheckbox","ngModel"],controller:"UibButtonsController",controllerAs:"button",link:function(a,e,t,n){var i=n[0],s=n[1];function o(){return r(t.btnCheckboxTrue,!0)}function r(e,t){return angular.isDefined(e)?a.$eval(e):t}e.find("input").css({display:"none"}),s.$render=function(){e.toggleClass(i.activeClass,angular.equals(s.$modelValue,o()))},e.on(i.toggleEvent,function(){t.disabled||a.$apply(function(){s.$setViewValue(e.hasClass(i.activeClass)?r(t.btnCheckboxFalse,!1):o()),s.$render()})})}}}),angular.module("ui.bootstrap.carousel",[]).controller("UibCarouselController",["$scope","$element","$interval","$timeout","$animate",function(i,s,t,e,o){var a,n,r=this,l=r.slides=i.slides=[],c="uib-slideDirection",u=i.active,d=[],p=!1;function m(){for(;d.length;)d.shift()}function g(e){for(var t=0;t<l.length;t++)l[t].slide.active=t===e}function f(e){for(var t=0;t<l.length;t++)if(l[t].slide===e)return t}function h(){a&&(t.cancel(a),a=null)}function v(){h();var e=+i.interval;!isNaN(e)&&0<e&&(a=t(y,e))}function y(){var e=+i.interval;n&&!isNaN(e)&&0<e&&l.length?i.next():i.pause()}s.addClass("carousel"),r.addSlide=function(e,t){l.push({slide:e,element:t}),l.sort(function(e,t){return+e.slide.index-+t.slide.index}),e.index!==i.active&&(1!==l.length||angular.isNumber(i.active))||(i.$currentTransition&&(i.$currentTransition=null),u=e.index,i.active=e.index,g(u),r.select(l[f(e)]),1===l.length&&i.play())},r.getCurrentIndex=function(){for(var e=0;e<l.length;e++)if(l[e].slide.index===u)return e},r.next=i.next=function(){var e=(r.getCurrentIndex()+1)%l.length;if(0!=e||!i.noWrap())return r.select(l[e],"next");i.pause()},r.prev=i.prev=function(){var e=r.getCurrentIndex()-1<0?l.length-1:r.getCurrentIndex()-1;if(!i.noWrap()||e!=l.length-1)return r.select(l[e],"prev");i.pause()},r.removeSlide=function(e){var t=f(e),e=d.indexOf(l[t]);-1!==e&&d.splice(e,1),l.splice(t,1),0<l.length&&u===t?t>=l.length?(u=l.length-1,g(i.active=u),r.select(l[l.length-1])):(u=t,g(i.active=u),r.select(l[t])):t<u&&(u--,i.active=u),0===l.length&&(u=null,i.active=null,m())},r.select=i.select=function(e,t){var a=f(e.slide);void 0===t&&(t=a>r.getCurrentIndex()?"next":"prev"),e.slide.index===u||i.$currentTransition?e&&e.slide.index!==u&&i.$currentTransition&&d.push(l[a]):function n(e,t,a){if(p)return;angular.extend(e,{direction:a});angular.extend(l[u].slide||{},{direction:a});o.enabled(s)&&!i.$currentTransition&&l[t].element&&1<r.slides.length&&(l[t].element.data(c,e.direction),a=r.getCurrentIndex(),angular.isNumber(a)&&l[a].element&&l[a].element.data(c,e.direction),i.$currentTransition=!0,o.on("addClass",l[t].element,function(e,t){var a;"close"===t&&(i.$currentTransition=null,o.off("addClass",e),d.length&&(a=d.pop().slide,t=a.index,e=t>r.getCurrentIndex()?"next":"prev",m(),n(a,t,e)))}));i.active=e.index;u=e.index;g(t);v()}(e.slide,a,t)},i.indexOfSlide=function(e){return+e.slide.index},i.isActive=function(e){return i.active===e.slide.index},i.isPrevDisabled=function(){return 0===i.active&&i.noWrap()},i.isNextDisabled=function(){return i.active===l.length-1&&i.noWrap()},i.pause=function(){i.noPause||(n=!1,h())},i.play=function(){n||(n=!0,v())},s.on("mouseenter",i.pause),s.on("mouseleave",i.play),i.$on("$destroy",function(){p=!0,h()}),i.$watch("noTransition",function(e){o.enabled(s,!e)}),i.$watch("interval",v),i.$watchCollection("slides",function(e){e.length||(i.$currentTransition=null,m())}),i.$watch("active",function(e){if(angular.isNumber(e)&&u!==e){for(var t=0;t<l.length;t++)if(l[t].slide.index===e){e=t;break}l[e]&&(g(e),r.select(l[e]),u=e)}})}]).directive("uibCarousel",function(){return{transclude:!0,controller:"UibCarouselController",controllerAs:"carousel",restrict:"A",templateUrl:function(e,t){return t.templateUrl||"uib/template/carousel/carousel.html"},scope:{active:"=",interval:"=",noTransition:"=",noPause:"=",noWrap:"&"}}}).directive("uibSlide",["$animate",function(i){return{require:"^uibCarousel",restrict:"A",transclude:!0,templateUrl:function(e,t){return t.templateUrl||"uib/template/carousel/slide.html"},scope:{actual:"=?",index:"=?"},link:function(e,t,a,n){t.addClass("item"),n.addSlide(e,t),e.$on("$destroy",function(){n.removeSlide(e)}),e.$watch("active",function(e){i[e?"addClass":"removeClass"](t,"active")})}}}]).animation(".item",["$animateCss",function(s){var o="uib-slideDirection";function r(e,t,a){e.removeClass(t),a&&a()}return{beforeAddClass:function(e,t,a){if("active"===t){var n=e.data(o),i="next"===n?"left":"right",t=r.bind(this,e,i+" "+n,a);return e.addClass(n),s(e,{addClass:i}).start().done(t),function(){}}a()},beforeRemoveClass:function(e,t,a){if("active"===t){var n="next"===e.data(o)?"left":"right",t=r.bind(this,e,n,a);return s(e,{addClass:n}).start().done(t),function(){}}a()}}}]),angular.module("ui.bootstrap.dateparser",[]).service("uibDateParser",["$log","$locale","dateFilter","orderByFilter",function(p,m,a,g){var f,h,v=/[\\\^\$\*\+\?\|\[\]\(\)\.\{\}]/g;function t(e){for(var t,a,n=[],i=0;i<e.length;)if(angular.isNumber(a)){if("'"===e.charAt(i))(i+1>=e.length||"'"!==e.charAt(i+1))&&(n.push(function(e,t,a){return function(){return e.substr(t+1,a-t-1)}}(e,a,i)),a=null);else if(i===e.length)for(;a<e.length;)t=s(e,a),n.push(t),a=t.endIdx;i++}else"'"!==e.charAt(i)?(t=s(e,i),n.push(t.parser),i=t.endIdx):(a=i,i++);return n}function s(e,t){for(var a=e.substr(t),n=0;n<h.length;n++)if(new RegExp("^"+h[n].key).test(a)){var i=h[n];return{endIdx:t+i.key.length,parser:i.formatter}}return{endIdx:t+1,parser:function(){return a.charAt(0)}}}function n(e){return parseInt(e,10)}function i(e,t){e=e.replace(/:/g,"");e=Date.parse("Jan 01, 1970 00:00:00 "+e)/6e4;return isNaN(e)?t:e}function o(e,t){return(e=new Date(e.getTime())).setMinutes(e.getMinutes()+t),e}function r(e,t,a){a=a?-1:1;var n=e.getTimezoneOffset();return o(e,a*(i(t,n)-n))}this.init=function(){f=m.id,this.parsers={},this.formatters={},h=[{key:"yyyy",regex:"\\d{4}",apply:function(e){this.year=+e},formatter:function(e){var t=new Date;return t.setFullYear(Math.abs(e.getFullYear())),a(t,"yyyy")}},{key:"yy",regex:"\\d{2}",apply:function(e){this.year=(e=+e)<69?e+2e3:e+1900},formatter:function(e){var t=new Date;return t.setFullYear(Math.abs(e.getFullYear())),a(t,"yy")}},{key:"y",regex:"\\d{1,4}",apply:function(e){this.year=+e},formatter:function(e){var t=new Date;return t.setFullYear(Math.abs(e.getFullYear())),a(t,"y")}},{key:"M!",regex:"0?[1-9]|1[0-2]",apply:function(e){this.month=e-1},formatter:function(e){var t=e.getMonth();return/^[0-9]$/.test(t)?a(e,"MM"):a(e,"M")}},{key:"MMMM",regex:m.DATETIME_FORMATS.MONTH.join("|"),apply:function(e){this.month=m.DATETIME_FORMATS.MONTH.indexOf(e)},formatter:function(e){return a(e,"MMMM")}},{key:"MMM",regex:m.DATETIME_FORMATS.SHORTMONTH.join("|"),apply:function(e){this.month=m.DATETIME_FORMATS.SHORTMONTH.indexOf(e)},formatter:function(e){return a(e,"MMM")}},{key:"MM",regex:"0[1-9]|1[0-2]",apply:function(e){this.month=e-1},formatter:function(e){return a(e,"MM")}},{key:"M",regex:"[1-9]|1[0-2]",apply:function(e){this.month=e-1},formatter:function(e){return a(e,"M")}},{key:"d!",regex:"[0-2]?[0-9]{1}|3[0-1]{1}",apply:function(e){this.date=+e},formatter:function(e){var t=e.getDate();return/^[1-9]$/.test(t)?a(e,"dd"):a(e,"d")}},{key:"dd",regex:"[0-2][0-9]{1}|3[0-1]{1}",apply:function(e){this.date=+e},formatter:function(e){return a(e,"dd")}},{key:"d",regex:"[1-2]?[0-9]{1}|3[0-1]{1}",apply:function(e){this.date=+e},formatter:function(e){return a(e,"d")}},{key:"EEEE",regex:m.DATETIME_FORMATS.DAY.join("|"),formatter:function(e){return a(e,"EEEE")}},{key:"EEE",regex:m.DATETIME_FORMATS.SHORTDAY.join("|"),formatter:function(e){return a(e,"EEE")}},{key:"HH",regex:"(?:0|1)[0-9]|2[0-3]",apply:function(e){this.hours=+e},formatter:function(e){return a(e,"HH")}},{key:"hh",regex:"0[0-9]|1[0-2]",apply:function(e){this.hours=+e},formatter:function(e){return a(e,"hh")}},{key:"H",regex:"1?[0-9]|2[0-3]",apply:function(e){this.hours=+e},formatter:function(e){return a(e,"H")}},{key:"h",regex:"[0-9]|1[0-2]",apply:function(e){this.hours=+e},formatter:function(e){return a(e,"h")}},{key:"mm",regex:"[0-5][0-9]",apply:function(e){this.minutes=+e},formatter:function(e){return a(e,"mm")}},{key:"m",regex:"[0-9]|[1-5][0-9]",apply:function(e){this.minutes=+e},formatter:function(e){return a(e,"m")}},{key:"sss",regex:"[0-9][0-9][0-9]",apply:function(e){this.milliseconds=+e},formatter:function(e){return a(e,"sss")}},{key:"ss",regex:"[0-5][0-9]",apply:function(e){this.seconds=+e},formatter:function(e){return a(e,"ss")}},{key:"s",regex:"[0-9]|[1-5][0-9]",apply:function(e){this.seconds=+e},formatter:function(e){return a(e,"s")}},{key:"a",regex:m.DATETIME_FORMATS.AMPMS.join("|"),apply:function(e){12===this.hours&&(this.hours=0),"PM"===e&&(this.hours+=12)},formatter:function(e){return a(e,"a")}},{key:"Z",regex:"[+-]\\d{4}",apply:function(e){var t=e.match(/([+-])(\d{2})(\d{2})/),a=t[1],e=t[2],t=t[3];this.hours+=n(a+e),this.minutes+=n(a+t)},formatter:function(e){return a(e,"Z")}},{key:"ww",regex:"[0-4][0-9]|5[0-3]",formatter:function(e){return a(e,"ww")}},{key:"w",regex:"[0-9]|[1-4][0-9]|5[0-3]",formatter:function(e){return a(e,"w")}},{key:"GGGG",regex:m.DATETIME_FORMATS.ERANAMES.join("|").replace(/\s/g,"\\s"),formatter:function(e){return a(e,"GGGG")}},{key:"GGG",regex:m.DATETIME_FORMATS.ERAS.join("|"),formatter:function(e){return a(e,"GGG")}},{key:"GG",regex:m.DATETIME_FORMATS.ERAS.join("|"),formatter:function(e){return a(e,"GG")}},{key:"G",regex:m.DATETIME_FORMATS.ERAS.join("|"),formatter:function(e){return a(e,"G")}}]},this.init(),this.filter=function(a,e){return angular.isDate(a)&&!isNaN(a)&&e?(e=m.DATETIME_FORMATS[e]||e,m.id!==f&&this.init(),this.formatters[e]||(this.formatters[e]=t(e)),this.formatters[e].reduce(function(e,t){return e+t(a)},"")):""},this.parse=function(e,t,a){if(!angular.isString(e)||!t)return e;t=(t=m.DATETIME_FORMATS[t]||t).replace(v,"\\$&"),m.id!==f&&this.init(),this.parsers[t]||(this.parsers[t]=function(i){var s=[],o=i.split(""),e=i.indexOf("'");if(-1<e){var t=!1;i=i.split("");for(var a=e;a<i.length;a++)t?("'"===i[a]&&(a+1<i.length&&"'"===i[a+1]?(i[a+1]="$",o[a+1]=""):(o[a]="",t=!1)),i[a]="$"):"'"===i[a]&&(i[a]="$",t=!(o[a]=""));i=i.join("")}return angular.forEach(h,function(e){var t=i.indexOf(e.key);if(-1<t){i=i.split(""),o[t]="("+e.regex+")",i[t]="$";for(var a=t+1,n=t+e.key.length;a<n;a++)o[a]="",i[a]="$";i=i.join(""),s.push({index:t,key:e.key,apply:e.apply,matcher:e.regex})}}),{regex:new RegExp("^"+o.join("")+"$"),map:g(s,"index")}}(t));var n=this.parsers[t],t=n.regex,i=n.map,s=e.match(t),o=!1;if(s&&s.length){for(var r,l=angular.isDate(a)&&!isNaN(a.getTime())?{year:a.getFullYear(),month:a.getMonth(),date:a.getDate(),hours:a.getHours(),minutes:a.getMinutes(),seconds:a.getSeconds(),milliseconds:a.getMilliseconds()}:(a&&p.warn("dateparser:","baseDate is not a valid date"),{year:1900,month:0,date:1,hours:0,minutes:0,seconds:0,milliseconds:0}),c=1,u=s.length;c<u;c++){var d=i[c-1];"Z"===d.matcher&&(o=!0),d.apply&&d.apply.call(l,s[c])}e=o?Date.prototype.setUTCFullYear:Date.prototype.setFullYear,t=o?Date.prototype.setUTCHours:Date.prototype.setHours;return function(e,t,a){if(a<1)return!1;if(1===t&&28<a)return 29===a&&(e%4==0&&e%100!=0||e%400==0);return 3!==t&&5!==t&&8!==t&&10!==t||a<31}(l.year,l.month,l.date)&&(!angular.isDate(a)||isNaN(a.getTime())||o?(r=new Date(0),e.call(r,l.year,l.month,l.date),t.call(r,l.hours||0,l.minutes||0,l.seconds||0,l.milliseconds||0)):(r=new Date(a),e.call(r,l.year,l.month,l.date),t.call(r,l.hours,l.minutes,l.seconds,l.milliseconds))),r}},this.toTimezone=function(e,t){return e&&t?r(e,t):e},this.fromTimezone=function(e,t){return e&&t?r(e,t,!0):e},this.timezoneToOffset=i,this.addDateMinutes=o,this.convertTimezoneToLocal=r}]),angular.module("ui.bootstrap.isClass",[]).directive("uibIsClass",["$animate",function(c){var a=/^\s*([\s\S]+?)\s+on\s+([\s\S]+?)\s*$/,u=/^\s*([\s\S]+?)\s+for\s+([\s\S]+?)\s*$/;return{restrict:"A",compile:function(e,t){var n=[],o=[],r={},t=t.uibIsClass.match(a),l=t[2],i=t[1].split(",");return function(a,e,t){n.push(a),o.push({scope:a,element:e}),i.forEach(function(e,t){!function(e,t){var a=e.match(u),n=t.$eval(a[1]),i=a[2],s=r[e];s||(a=function(t){var a=null;o.some(function(e){if(e.scope.$eval(l)===t)return a=e,!0}),s.lastActivated!==a&&(s.lastActivated&&c.removeClass(s.lastActivated.element,n),a&&c.addClass(a.element,n),s.lastActivated=a)},r[e]=s={lastActivated:null,scope:t,watchFn:a,compareWithExp:i,watcher:t.$watch(i,a)});s.watchFn(t.$eval(i))}(e,a)}),a.$on("$destroy",s)};function s(e){var t,a=e.targetScope,e=n.indexOf(a);n.splice(e,1),o.splice(e,1),n.length?(t=n[0],angular.forEach(r,function(e){e.scope===a&&(e.watcher=t.$watch(e.compareWithExp,e.watchFn),e.scope=t)})):r={}}}}}]),angular.module("ui.bootstrap.datepicker",["ui.bootstrap.dateparser","ui.bootstrap.isClass"]).value("$datepickerSuppressError",!1).value("$datepickerLiteralWarning",!0).constant("uibDatepickerConfig",{datepickerMode:"day",formatDay:"dd",formatMonth:"MMMM",formatYear:"yyyy",formatDayHeader:"EEE",formatDayTitle:"MMMM yyyy",formatMonthTitle:"yyyy",maxDate:null,maxMode:"year",minDate:null,minMode:"day",monthColumns:3,ngModelOptions:{},shortcutPropagation:!1,showWeeks:!0,yearColumns:5,yearRows:4}).controller("UibDatepickerController",["$scope","$element","$attrs","$parse","$interpolate","$locale","$log","dateFilter","uibDatepickerConfig","$datepickerLiteralWarning","$datepickerSuppressError","uibDateParser",function(i,e,t,a,n,s,o,r,l,c,u,d){var p=this,m={$setViewValue:angular.noop},g={},f=[];e.addClass("uib-datepicker"),t.$set("role","application"),i.datepickerOptions||(i.datepickerOptions={}),this.modes=["day","month","year"],["customClass","dateDisabled","datepickerMode","formatDay","formatDayHeader","formatDayTitle","formatMonth","formatMonthTitle","formatYear","maxDate","maxMode","minDate","minMode","monthColumns","showWeeks","shortcutPropagation","startingDay","yearColumns","yearRows"].forEach(function(t){switch(t){case"customClass":case"dateDisabled":i[t]=i.datepickerOptions[t]||angular.noop;break;case"datepickerMode":i.datepickerMode=(angular.isDefined(i.datepickerOptions.datepickerMode)?i.datepickerOptions:l).datepickerMode;break;case"formatDay":case"formatDayHeader":case"formatDayTitle":case"formatMonth":case"formatMonthTitle":case"formatYear":p[t]=angular.isDefined(i.datepickerOptions[t])?n(i.datepickerOptions[t])(i.$parent):l[t];break;case"monthColumns":case"showWeeks":case"shortcutPropagation":case"yearColumns":case"yearRows":p[t]=(angular.isDefined(i.datepickerOptions[t])?i.datepickerOptions:l)[t];break;case"startingDay":angular.isDefined(i.datepickerOptions.startingDay)?p.startingDay=i.datepickerOptions.startingDay:angular.isNumber(l.startingDay)?p.startingDay=l.startingDay:p.startingDay=(s.DATETIME_FORMATS.FIRSTDAYOFWEEK+8)%7;break;case"maxDate":case"minDate":i.$watch("datepickerOptions."+t,function(e){e?angular.isDate(e)?p[t]=d.fromTimezone(new Date(e),g.timezone):(c&&o.warn("Literal date support has been deprecated, please switch to date object usage"),p[t]=new Date(r(e,"medium"))):p[t]=l[t]?d.fromTimezone(new Date(l[t]),g.timezone):null,p.refreshView()});break;case"maxMode":case"minMode":i.datepickerOptions[t]?i.$watch(function(){return i.datepickerOptions[t]},function(e){p[t]=i[t]=angular.isDefined(e)?e:datepickerOptions[t],("minMode"===t&&p.modes.indexOf(i.datepickerOptions.datepickerMode)<p.modes.indexOf(p[t])||"maxMode"===t&&p.modes.indexOf(i.datepickerOptions.datepickerMode)>p.modes.indexOf(p[t]))&&(i.datepickerMode=p[t],i.datepickerOptions.datepickerMode=p[t])}):p[t]=i[t]=l[t]||null}}),i.uniqueId="datepicker-"+i.$id+"-"+Math.floor(1e4*Math.random()),i.disabled=angular.isDefined(t.disabled)||!1,angular.isDefined(t.ngDisabled)&&f.push(i.$parent.$watch(t.ngDisabled,function(e){i.disabled=e,p.refreshView()})),i.isActive=function(e){return 0===p.compare(e.date,p.activeDate)&&(i.activeDateId=e.uid,!0)},this.init=function(e){g=(m=e).$options||i.datepickerOptions.ngModelOptions||l.ngModelOptions,i.datepickerOptions.initDate?(p.activeDate=d.fromTimezone(i.datepickerOptions.initDate,g.timezone)||new Date,i.$watch("datepickerOptions.initDate",function(e){e&&(m.$isEmpty(m.$modelValue)||m.$invalid)&&(p.activeDate=d.fromTimezone(e,g.timezone),p.refreshView())})):p.activeDate=new Date;e=m.$modelValue?new Date(m.$modelValue):new Date;this.activeDate=isNaN(e)?d.fromTimezone(new Date,g.timezone):d.fromTimezone(e,g.timezone),m.$render=function(){p.render()}},this.render=function(){var e;m.$viewValue&&(e=new Date(m.$viewValue),!isNaN(e)?this.activeDate=d.fromTimezone(e,g.timezone):u||o.error('Datepicker directive: "ng-model" value must be a Date object')),this.refreshView()},this.refreshView=function(){var e;this.element&&(i.selectedDt=null,this._refreshView(),i.activeDt&&(i.activeDateId=i.activeDt.uid),e=m.$viewValue?new Date(m.$viewValue):null,e=d.fromTimezone(e,g.timezone),m.$setValidity("dateDisabled",!e||this.element&&!this.isDisabled(e)))},this.createDateObject=function(e,t){var a=m.$viewValue?new Date(m.$viewValue):null,a=d.fromTimezone(a,g.timezone),n=new Date,n=d.fromTimezone(n,g.timezone),n=this.compare(e,n),n={date:e,label:d.filter(e,t),selected:a&&0===this.compare(e,a),disabled:this.isDisabled(e),past:n<0,current:0===n,future:0<n,customClass:this.customClass(e)||null};return a&&0===this.compare(e,a)&&(i.selectedDt=n),p.activeDate&&0===this.compare(n.date,p.activeDate)&&(i.activeDt=n),n},this.isDisabled=function(e){return i.disabled||this.minDate&&this.compare(e,this.minDate)<0||this.maxDate&&0<this.compare(e,this.maxDate)||i.dateDisabled&&i.dateDisabled({date:e,mode:i.datepickerMode})},this.customClass=function(e){return i.customClass({date:e,mode:i.datepickerMode})},this.split=function(e,t){for(var a=[];0<e.length;)a.push(e.splice(0,t));return a},i.select=function(e){var t;i.datepickerMode===p.minMode?((t=m.$viewValue?d.fromTimezone(new Date(m.$viewValue),g.timezone):new Date(0,0,0,0,0,0,0)).setFullYear(e.getFullYear(),e.getMonth(),e.getDate()),t=d.toTimezone(t,g.timezone),m.$setViewValue(t),m.$render()):(p.activeDate=e,h(p.modes[p.modes.indexOf(i.datepickerMode)-1]),i.$emit("uib:datepicker.mode")),i.$broadcast("uib:datepicker.focus")},i.move=function(e){var t=p.activeDate.getFullYear()+e*(p.step.years||0),e=p.activeDate.getMonth()+e*(p.step.months||0);p.activeDate.setFullYear(t,e,1),p.refreshView()},i.toggleMode=function(e){e=e||1,i.datepickerMode===p.maxMode&&1===e||i.datepickerMode===p.minMode&&-1===e||(h(p.modes[p.modes.indexOf(i.datepickerMode)+e]),i.$emit("uib:datepicker.mode"))},i.keys={13:"enter",32:"space",33:"pageup",34:"pagedown",35:"end",36:"home",37:"left",38:"up",39:"right",40:"down"};function h(e){i.datepickerMode=e,i.datepickerOptions.datepickerMode=e}i.$on("uib:datepicker.focus",function(){p.element[0].focus()}),i.keydown=function(e){var t=i.keys[e.which];!t||e.shiftKey||e.altKey||i.disabled||(e.preventDefault(),p.shortcutPropagation||e.stopPropagation(),"enter"===t||"space"===t?p.isDisabled(p.activeDate)||i.select(p.activeDate):!e.ctrlKey||"up"!==t&&"down"!==t?(p.handleKeyDown(t,e),p.refreshView()):i.toggleMode("up"===t?1:-1))},e.on("keydown",function(e){i.$apply(function(){i.keydown(e)})}),i.$on("$destroy",function(){for(;f.length;)f.shift()()})}]).controller("UibDaypickerController",["$scope","$element","dateFilter",function(c,e,u){var a=[31,28,31,30,31,30,31,31,30,31,30,31];function i(e,t){return 1!==t||e%4!=0||e%100==0&&e%400!=0?a[t]:29}this.step={months:1},this.element=e,this.init=function(e){angular.extend(e,this),c.showWeeks=e.showWeeks,e.refreshView()},this.getDates=function(e,t){for(var a,n=new Array(t),i=new Date(e),s=0;s<t;)a=new Date(i),n[s++]=a,i.setDate(i.getDate()+1);return n},this._refreshView=function(){var e=this.activeDate.getFullYear(),t=this.activeDate.getMonth(),a=new Date(this.activeDate);a.setFullYear(e,t,1);e=this.startingDay-a.getDay(),e=0<e?7-e:-e,a=new Date(a);0<e&&a.setDate(1-e);for(var n=this.getDates(a,42),i=0;i<42;i++)n[i]=angular.extend(this.createDateObject(n[i],this.formatDay),{secondary:n[i].getMonth()!==t,uid:c.uniqueId+"-"+i});c.labels=new Array(7);for(var s=0;s<7;s++)c.labels[s]={abbr:u(n[s].date,this.formatDayHeader),full:u(n[s].date,"EEEE")};if(c.title=u(this.activeDate,this.formatDayTitle),c.rows=this.split(n,7),c.showWeeks){c.weekNumbers=[];for(var o=(11-this.startingDay)%7,r=c.rows.length,l=0;l<r;l++)c.weekNumbers.push(function(e){var t=new Date(e);t.setDate(t.getDate()+4-(t.getDay()||7));e=t.getTime();return t.setMonth(0),t.setDate(1),Math.floor(Math.round((e-t)/864e5)/7)+1}(c.rows[l][o].date))}},this.compare=function(e,t){var a=new Date(e.getFullYear(),e.getMonth(),e.getDate()),n=new Date(t.getFullYear(),t.getMonth(),t.getDate());return a.setFullYear(e.getFullYear()),n.setFullYear(t.getFullYear()),a-n},this.handleKeyDown=function(e,t){var a,n=this.activeDate.getDate();"left"===e?n-=1:"up"===e?n-=7:"right"===e?n+=1:"down"===e?n+=7:"pageup"===e||"pagedown"===e?(a=this.activeDate.getMonth()+("pageup"===e?-1:1),this.activeDate.setMonth(a,1),n=Math.min(i(this.activeDate.getFullYear(),this.activeDate.getMonth()),n)):"home"===e?n=1:"end"===e&&(n=i(this.activeDate.getFullYear(),this.activeDate.getMonth())),this.activeDate.setDate(n)}}]).controller("UibMonthpickerController",["$scope","$element","dateFilter",function(i,e,s){this.step={years:1},this.element=e,this.init=function(e){angular.extend(e,this),e.refreshView()},this._refreshView=function(){for(var e,t=new Array(12),a=this.activeDate.getFullYear(),n=0;n<12;n++)(e=new Date(this.activeDate)).setFullYear(a,n,1),t[n]=angular.extend(this.createDateObject(e,this.formatMonth),{uid:i.uniqueId+"-"+n});i.title=s(this.activeDate,this.formatMonthTitle),i.rows=this.split(t,this.monthColumns),i.yearHeaderColspan=3<this.monthColumns?this.monthColumns-2:1},this.compare=function(e,t){var a=new Date(e.getFullYear(),e.getMonth()),n=new Date(t.getFullYear(),t.getMonth());return a.setFullYear(e.getFullYear()),n.setFullYear(t.getFullYear()),a-n},this.handleKeyDown=function(e,t){var a,n=this.activeDate.getMonth();"left"===e?n-=1:"up"===e?n-=this.monthColumns:"right"===e?n+=1:"down"===e?n+=this.monthColumns:"pageup"===e||"pagedown"===e?(a=this.activeDate.getFullYear()+("pageup"===e?-1:1),this.activeDate.setFullYear(a)):"home"===e?n=0:"end"===e&&(n=11),this.activeDate.setMonth(n)}}]).controller("UibYearpickerController",["$scope","$element","dateFilter",function(i,e,t){var s,o;function r(e){return parseInt((e-1)/o,10)*o+1}this.element=e,this.yearpickerInit=function(){s=this.yearColumns,o=this.yearRows*s,this.step={years:o}},this._refreshView=function(){for(var e,t=new Array(o),a=0,n=r(this.activeDate.getFullYear());a<o;a++)(e=new Date(this.activeDate)).setFullYear(n+a,0,1),t[a]=angular.extend(this.createDateObject(e,this.formatYear),{uid:i.uniqueId+"-"+a});i.title=[t[0].label,t[o-1].label].join(" - "),i.rows=this.split(t,s),i.columns=s},this.compare=function(e,t){return e.getFullYear()-t.getFullYear()},this.handleKeyDown=function(e,t){var a=this.activeDate.getFullYear();"left"===e?a-=1:"up"===e?a-=s:"right"===e?a+=1:"down"===e?a+=s:"pageup"===e||"pagedown"===e?a+=("pageup"===e?-1:1)*o:"home"===e?a=r(this.activeDate.getFullYear()):"end"===e&&(a=r(this.activeDate.getFullYear())+o-1),this.activeDate.setFullYear(a)}}]).directive("uibDatepicker",function(){return{templateUrl:function(e,t){return t.templateUrl||"uib/template/datepicker/datepicker.html"},scope:{datepickerOptions:"=?"},require:["uibDatepicker","^ngModel"],restrict:"A",controller:"UibDatepickerController",controllerAs:"datepicker",link:function(e,t,a,n){var i=n[0],n=n[1];i.init(n)}}}).directive("uibDaypicker",function(){return{templateUrl:function(e,t){return t.templateUrl||"uib/template/datepicker/day.html"},require:["^uibDatepicker","uibDaypicker"],restrict:"A",controller:"UibDaypickerController",link:function(e,t,a,n){var i=n[0];n[1].init(i)}}}).directive("uibMonthpicker",function(){return{templateUrl:function(e,t){return t.templateUrl||"uib/template/datepicker/month.html"},require:["^uibDatepicker","uibMonthpicker"],restrict:"A",controller:"UibMonthpickerController",link:function(e,t,a,n){var i=n[0];n[1].init(i)}}}).directive("uibYearpicker",function(){return{templateUrl:function(e,t){return t.templateUrl||"uib/template/datepicker/year.html"},require:["^uibDatepicker","uibYearpicker"],restrict:"A",controller:"UibYearpickerController",link:function(e,t,a,n){var i=n[0];angular.extend(i,n[1]),i.yearpickerInit(),i.refreshView()}}}),angular.module("ui.bootstrap.position",[]).factory("$uibPosition",["$document","$window",function(l,c){var a,n,u={normal:/(auto|scroll)/,hidden:/(auto|scroll|hidden)/},d={auto:/\s?auto?\s?/i,primary:/^(top|bottom|left|right)$/,secondary:/^(top|bottom|left|right|center)$/,vertical:/^(top|bottom)$/},i=/(HTML|BODY)/;return{getRawNode:function(e){return!e.nodeName&&e[0]||e},parseStyle:function(e){return e=parseFloat(e),isFinite(e)?e:0},offsetParent:function(e){var t,a=(e=this.getRawNode(e)).offsetParent||l[0].documentElement;for(;a&&a!==l[0].documentElement&&(t=a,"static"===(c.getComputedStyle(t).position||"static"));)a=a.offsetParent;return a||l[0].documentElement},scrollbarWidth:function(e){var t;return e?(angular.isUndefined(n)&&((t=l.find("body")).addClass("uib-position-body-scrollbar-measure"),n=c.innerWidth-t[0].clientWidth,n=isFinite(n)?n:0,t.removeClass("uib-position-body-scrollbar-measure")),n):(angular.isUndefined(a)&&(t=angular.element('<div class="uib-position-scrollbar-measure"></div>'),l.find("body").append(t),a=t[0].offsetWidth-t[0].clientWidth,a=isFinite(a)?a:0,t.remove()),a)},scrollbarPadding:function(e){e=this.getRawNode(e);var t=c.getComputedStyle(e),a=this.parseStyle(t.paddingRight),n=this.parseStyle(t.paddingBottom),t=this.scrollParent(e,!1,!0),e=this.scrollbarWidth(t,i.test(t.tagName));return{scrollbarWidth:e,widthOverflow:t.scrollWidth>t.clientWidth,right:a+e,originalRight:a,heightOverflow:t.scrollHeight>t.clientHeight,bottom:n+e,originalBottom:n}},isScrollable:function(e,t){e=this.getRawNode(e);t=t?u.hidden:u.normal,e=c.getComputedStyle(e);return t.test(e.overflow+e.overflowY+e.overflowX)},scrollParent:function(e,t,a){e=this.getRawNode(e);var n=t?u.hidden:u.normal,i=l[0].documentElement,t=c.getComputedStyle(e);if(a&&n.test(t.overflow+t.overflowY+t.overflowX))return e;var s="absolute"===t.position,o=e.parentElement||i;if(o===i||"fixed"===t.position)return i;for(;o.parentElement&&o!==i;){var r=c.getComputedStyle(o);if(!(s=s&&"static"!==r.position?!1:s)&&n.test(r.overflow+r.overflowY+r.overflowX))break;o=o.parentElement}return o},position:function(e,t){e=this.getRawNode(e);var a=this.offset(e);t&&(n=c.getComputedStyle(e),a.top-=this.parseStyle(n.marginTop),a.left-=this.parseStyle(n.marginLeft));var t=this.offsetParent(e),n={top:0,left:0};return t!==l[0].documentElement&&((n=this.offset(t)).top+=t.clientTop-t.scrollTop,n.left+=t.clientLeft-t.scrollLeft),{width:Math.round(angular.isNumber(a.width)?a.width:e.offsetWidth),height:Math.round(angular.isNumber(a.height)?a.height:e.offsetHeight),top:Math.round(a.top-n.top),left:Math.round(a.left-n.left)}},offset:function(e){var t=(e=this.getRawNode(e)).getBoundingClientRect();return{width:Math.round(angular.isNumber(t.width)?t.width:e.offsetWidth),height:Math.round(angular.isNumber(t.height)?t.height:e.offsetHeight),top:Math.round(t.top+(c.pageYOffset||l[0].documentElement.scrollTop)),left:Math.round(t.left+(c.pageXOffset||l[0].documentElement.scrollLeft))}},viewportOffset:function(e,t,a){a=!1!==a;var n=(e=this.getRawNode(e)).getBoundingClientRect(),i={top:0,left:0,bottom:0,right:0},t=t?l[0].documentElement:this.scrollParent(e),e=t.getBoundingClientRect();return i.top=e.top+t.clientTop,i.left=e.left+t.clientLeft,t===l[0].documentElement&&(i.top+=c.pageYOffset,i.left+=c.pageXOffset),i.bottom=i.top+t.clientHeight,i.right=i.left+t.clientWidth,a&&(t=c.getComputedStyle(t),i.top+=this.parseStyle(t.paddingTop),i.bottom-=this.parseStyle(t.paddingBottom),i.left+=this.parseStyle(t.paddingLeft),i.right-=this.parseStyle(t.paddingRight)),{top:Math.round(n.top-i.top),bottom:Math.round(i.bottom-n.bottom),left:Math.round(n.left-i.left),right:Math.round(i.right-n.right)}},parsePlacement:function(e){var t=d.auto.test(e);return(e=(e=t?e.replace(d.auto,""):e).split("-"))[0]=e[0]||"top",d.primary.test(e[0])||(e[0]="top"),e[1]=e[1]||"center",d.secondary.test(e[1])||(e[1]="center"),e[2]=!!t,e},positionElements:function(e,t,a,n){e=this.getRawNode(e),t=this.getRawNode(t);var i=angular.isDefined(t.offsetWidth)?t.offsetWidth:t.prop("offsetWidth"),s=angular.isDefined(t.offsetHeight)?t.offsetHeight:t.prop("offsetHeight");a=this.parsePlacement(a);var o,r=n?this.offset(e):this.position(e),l={top:0,left:0,placement:""};switch(a[2]&&(o=this.viewportOffset(e,n),e=c.getComputedStyle(t),n=i+Math.round(Math.abs(this.parseStyle(e.marginLeft)+this.parseStyle(e.marginRight))),t=s+Math.round(Math.abs(this.parseStyle(e.marginTop)+this.parseStyle(e.marginBottom))),a[0]="top"===a[0]&&t>o.top&&t<=o.bottom?"bottom":"bottom"===a[0]&&t>o.bottom&&t<=o.top?"top":"left"===a[0]&&n>o.left&&n<=o.right?"right":"right"===a[0]&&n>o.right&&n<=o.left?"left":a[0],a[1]="top"===a[1]&&t-r.height>o.bottom&&t-r.height<=o.top?"bottom":"bottom"===a[1]&&t-r.height>o.top&&t-r.height<=o.bottom?"top":"left"===a[1]&&n-r.width>o.right&&n-r.width<=o.left?"right":"right"===a[1]&&n-r.width>o.left&&n-r.width<=o.right?"left":a[1],"center"===a[1]&&(d.vertical.test(a[0])?(e=r.width/2-i/2,o.left+e<0&&n-r.width<=o.right?a[1]="left":o.right+e<0&&n-r.width<=o.left&&(a[1]="right")):(n=r.height/2-t/2,o.top+n<0&&t-r.height<=o.bottom?a[1]="top":o.bottom+n<0&&t-r.height<=o.top&&(a[1]="bottom")))),a[0]){case"top":l.top=r.top-s;break;case"bottom":l.top=r.top+r.height;break;case"left":l.left=r.left-i;break;case"right":l.left=r.left+r.width}switch(a[1]){case"top":l.top=r.top;break;case"bottom":l.top=r.top+r.height-s;break;case"left":l.left=r.left;break;case"right":l.left=r.left+r.width-i;break;case"center":d.vertical.test(a[0])?l.left=r.left+r.width/2-i/2:l.top=r.top+r.height/2-s/2}return l.top=Math.round(l.top),l.left=Math.round(l.left),l.placement="center"===a[1]?a[0]:a[0]+"-"+a[1],l},adjustTop:function(e,t,a,n){if(-1!==e.indexOf("top")&&a!==n)return{top:t.top-n+"px"}},positionArrow:function(e,t){var a=(e=this.getRawNode(e)).querySelector(".tooltip-inner, .popover-inner");if(a){var n=angular.element(a).hasClass("tooltip-inner"),i=n?e.querySelector(".tooltip-arrow"):e.querySelector(".arrow");if(i){var s={top:"",bottom:"",left:"",right:""};if("center"!==(t=this.parsePlacement(t))[1]){var o="border-"+t[0]+"-width",r=c.getComputedStyle(i)[o],o="border-";d.vertical.test(t[0])?o+=t[0]+"-"+t[1]:o+=t[1]+"-"+t[0],o+="-radius";o=c.getComputedStyle(n?a:e)[o];switch(t[0]){case"top":s.bottom=n?"0":"-"+r;break;case"bottom":s.top=n?"0":"-"+r;break;case"left":s.right=n?"0":"-"+r;break;case"right":s.left=n?"0":"-"+r}s[t[1]]=o,angular.element(i).css(s)}else angular.element(i).css(s)}}}}}]),angular.module("ui.bootstrap.datepickerPopup",["ui.bootstrap.datepicker","ui.bootstrap.position"]).value("$datepickerPopupLiteralWarning",!0).constant("uibDatepickerPopupConfig",{altInputFormats:[],appendToBody:!1,clearText:"Clear",closeOnDateSelection:!0,closeText:"Done",currentText:"Today",datepickerPopup:"yyyy-MM-dd",datepickerPopupTemplateUrl:"uib/template/datepickerPopup/popup.html",datepickerTemplateUrl:"uib/template/datepicker/datepicker.html",html5Types:{date:"yyyy-MM-dd","datetime-local":"yyyy-MM-ddTHH:mm:ss.sss",month:"yyyy-MM"},onOpenFocus:!0,showButtonBar:!0,placement:"auto bottom-left"}).controller("UibDatepickerPopupController",["$scope","$element","$attrs","$compile","$log","$parse","$window","$document","$rootScope","$uibPosition","dateFilter","uibDateParser","uibDatepickerPopupConfig","$timeout","uibDatepickerConfig","$datepickerPopupLiteralWarning",function(n,i,a,t,s,e,o,r,l,c,u,d,p,m,g,f){var h,v,y,b,w,$,k,x,_,S,I,C=!1,A=[];function M(e){var t=d.parse(e,h,n.date);if(isNaN(t))for(var a=0;a<I.length;a++)if(t=d.parse(e,I[a],n.date),!isNaN(t))return t;return t}function D(e){if(!(e=angular.isNumber(e)?new Date(e):e))return null;if(angular.isDate(e)&&!isNaN(e))return e;if(angular.isString(e)){var t=M(e);if(!isNaN(t))return t}return _.$options&&_.$options.allowInvalid?e:void 0}function T(e,t){t=e||t;return!a.ngRequired&&!t||(!(t=angular.isNumber(t)?new Date(t):t)||(!(!angular.isDate(t)||isNaN(t))||!!angular.isString(t)&&!isNaN(M(t))))}function P(e){var t,a;!n.isOpen&&n.disabled||(t=S[0],a=i[0].contains(e.target),e=void 0!==t.contains&&t.contains(e.target),!n.isOpen||a||e||n.$apply(function(){n.isOpen=!1}))}function E(e){27===e.which&&n.isOpen?(e.preventDefault(),e.stopPropagation(),n.$apply(function(){n.isOpen=!1}),i[0].focus()):40!==e.which||n.isOpen||(e.preventDefault(),e.stopPropagation(),n.$apply(function(){n.isOpen=!0}))}function j(){var e,t;n.isOpen&&(e=angular.element(S[0].querySelector(".uib-datepicker-popup")),t=a.popupPlacement||p.placement,t=c.positionElements(i,e,t,y),e.css({top:t.top+"px",left:t.left+"px"}),e.hasClass("uib-position-measure")&&e.removeClass("uib-position-measure"))}this.init=function(e){if((_=e).$options,v=angular.isDefined(a.closeOnDateSelection)?n.$parent.$eval(a.closeOnDateSelection):p.closeOnDateSelection,y=angular.isDefined(a.datepickerAppendToBody)?n.$parent.$eval(a.datepickerAppendToBody):p.appendToBody,b=angular.isDefined(a.onOpenFocus)?n.$parent.$eval(a.onOpenFocus):p.onOpenFocus,k=(angular.isDefined(a.datepickerPopupTemplateUrl)?a:p).datepickerPopupTemplateUrl,w=(angular.isDefined(a.datepickerTemplateUrl)?a:p).datepickerTemplateUrl,I=angular.isDefined(a.altInputFormats)?n.$parent.$eval(a.altInputFormats):p.altInputFormats,n.showButtonBar=angular.isDefined(a.showButtonBar)?n.$parent.$eval(a.showButtonBar):p.showButtonBar,p.html5Types[a.type]?(h=p.html5Types[a.type],C=!0):(h=a.uibDatepickerPopup||p.datepickerPopup,a.$observe("uibDatepickerPopup",function(e,t){e=e||p.datepickerPopup;if(e!==h&&(h=e,_.$modelValue=null,!h))throw new Error("uibDatepickerPopup must have a date format specified.")})),!h)throw new Error("uibDatepickerPopup must have a date format specified.");if(C&&a.uibDatepickerPopup)throw new Error("HTML5 date input types do not support custom formats.");($=angular.element("<div uib-datepicker-popup-wrap><div uib-datepicker></div></div>")).attr({"ng-model":"date","ng-change":"dateSelection(date)","template-url":k}),(k=angular.element($.children()[0])).attr("template-url",w),n.datepickerOptions||(n.datepickerOptions={}),C&&"month"===a.type&&(n.datepickerOptions.datepickerMode="month",n.datepickerOptions.minMode="month"),k.attr("datepicker-options","datepickerOptions"),C?_.$formatters.push(function(e){return n.date=e}):(_.$$parserName="date",_.$validators.date=T,_.$parsers.unshift(D),_.$formatters.push(function(e){return _.$isEmpty(e)?n.date=e:(angular.isNumber(e)&&(e=new Date(e)),n.date=e,d.filter(n.date,h))})),_.$viewChangeListeners.push(function(){n.date=M(_.$viewValue)}),i.on("keydown",E),S=t($)(n),$.remove(),y?r.find("body").append(S):i.after(S),n.$on("$destroy",function(){for(!0===n.isOpen&&(l.$$phase||n.$apply(function(){n.isOpen=!1})),S.remove(),i.off("keydown",E),r.off("click",P),x&&x.off("scroll",j),angular.element(o).off("resize",j);A.length;)A.shift()()})},n.getText=function(e){return n[e+"Text"]||p[e+"Text"]},n.isDisabled=function(e){"today"===e&&(e=new Date);var t={};return angular.forEach(["minDate","maxDate"],function(e){n.datepickerOptions[e]?angular.isDate(n.datepickerOptions[e])?t[e]=new Date(n.datepickerOptions[e]):(f&&s.warn("Literal date support has been deprecated, please switch to date object usage"),t[e]=new Date(u(n.datepickerOptions[e],"medium"))):t[e]=null}),n.datepickerOptions&&t.minDate&&n.compare(e,t.minDate)<0||t.maxDate&&0<n.compare(e,t.maxDate)},n.compare=function(e,t){return new Date(e.getFullYear(),e.getMonth(),e.getDate())-new Date(t.getFullYear(),t.getMonth(),t.getDate())},n.dateSelection=function(e){n.date=e;e=n.date?d.filter(n.date,h):null;i.val(e),_.$setViewValue(e),v&&(n.isOpen=!1,i[0].focus())},n.keydown=function(e){27===e.which&&(e.stopPropagation(),n.isOpen=!1,i[0].focus())},n.select=function(e,t){t.stopPropagation(),"today"===e&&(t=new Date,angular.isDate(n.date)?(e=new Date(n.date)).setFullYear(t.getFullYear(),t.getMonth(),t.getDate()):e=new Date(t.setHours(0,0,0,0))),n.dateSelection(e)},n.close=function(e){e.stopPropagation(),n.isOpen=!1,i[0].focus()},n.disabled=angular.isDefined(a.disabled)||!1,a.ngDisabled&&A.push(n.$parent.$watch(e(a.ngDisabled),function(e){n.disabled=e})),n.$watch("isOpen",function(e){e?n.disabled?n.isOpen=!1:m(function(){j(),b&&n.$broadcast("uib:datepicker.focus"),r.on("click",P);var e=a.popupPlacement||p.placement;y||c.parsePlacement(e)[2]?(x=x||angular.element(c.scrollParent(i)))&&x.on("scroll",j):x=null,angular.element(o).on("resize",j)},0,!1):(r.off("click",P),x&&x.off("scroll",j),angular.element(o).off("resize",j))}),n.$on("uib:datepicker.mode",function(){m(j,0,!1)})}]).directive("uibDatepickerPopup",function(){return{require:["ngModel","uibDatepickerPopup"],controller:"UibDatepickerPopupController",scope:{datepickerOptions:"=?",isOpen:"=?",currentText:"@",clearText:"@",closeText:"@"},link:function(e,t,a,n){var i=n[0];n[1].init(i)}}}).directive("uibDatepickerPopupWrap",function(){return{restrict:"A",transclude:!0,templateUrl:function(e,t){return t.templateUrl||"uib/template/datepickerPopup/popup.html"}}}),angular.module("ui.bootstrap.debounce",[]).factory("$$debounce",["$timeout",function(s){return function(a,n){var i;return function(){var e=this,t=Array.prototype.slice.call(arguments);i&&s.cancel(i),i=s(function(){a.apply(e,t)},n)}}}]),angular.module("ui.bootstrap.dropdown",["ui.bootstrap.position"]).constant("uibDropdownConfig",{appendToOpenClass:"uib-dropdown-open",openClass:"open"}).service("uibDropdownService",["$document","$rootScope",function(a,n){var i=null;this.open=function(e,t){i||a.on("click",s),i&&i!==e&&(i.isOpen=!1),i=e},this.close=function(e,t){i===e&&(i=null,a.off("click",s),(e=e.getDropdownElement())&&e.off("keydown",this.keybindFilter))};var s=function(e){var t;i&&(e&&"disabled"===i.getAutoClose()||e&&3===e.which||(t=i.getToggleElement(),e&&t&&t[0].contains(e.target)||(t=i.getDropdownElement(),e&&"outsideClick"===i.getAutoClose()&&t&&t[0].contains(e.target)||(i.isOpen=!1,i.focusToggleElement(),n.$$phase||i.$apply()))))};this.keybindFilter=function(e){27===e.which?(e.stopPropagation(),i.focusToggleElement(),s()):i.isKeynavEnabled()&&-1!==[38,40].indexOf(e.which)&&i.isOpen&&(e.preventDefault(),e.stopPropagation(),i.focusDropdownEntry(e.which))}}]).controller("UibDropdownController",["$scope","$element","$attrs","$parse","uibDropdownConfig","uibDropdownService","$animate","$uibPosition","$document","$compile","$templateRequest",function(r,l,t,a,e,c,u,d,n,p,m){var g,i,f=this,h=r.$new(),v=e.appendToOpenClass,y=e.openClass,b=angular.noop,w=t.onToggle?a(t.onToggle):angular.noop,$=!1,k=null,s=!1,o=n.find("body");l.addClass("dropdown"),this.init=function(){var e;t.isOpen&&(i=a(t.isOpen),b=i.assign,r.$watch(i,function(e){h.isOpen=!!e})),!angular.isDefined(t.dropdownAppendTo)||(e=a(t.dropdownAppendTo)(h))&&(k=angular.element(e)),$=angular.isDefined(t.dropdownAppendToBody),s=angular.isDefined(t.keyboardNav),(k=$&&!k?o:k)&&f.dropdownMenu&&(k.append(f.dropdownMenu),l.on("$destroy",function(){f.dropdownMenu.remove()}))},this.toggle=function(e){return h.isOpen=arguments.length?!!e:!h.isOpen,angular.isFunction(b)&&b(h,h.isOpen),h.isOpen},this.isOpen=function(){return h.isOpen},h.getToggleElement=function(){return f.toggleElement},h.getAutoClose=function(){return t.autoClose||"always"},h.getElement=function(){return l},h.isKeynavEnabled=function(){return s},h.focusDropdownEntry=function(e){var t=(f.dropdownMenu?angular.element(f.dropdownMenu):l.find("ul").eq(0)).find("a");switch(e){case 40:angular.isNumber(f.selectedOption)?f.selectedOption=f.selectedOption===t.length-1?f.selectedOption:f.selectedOption+1:f.selectedOption=0;break;case 38:angular.isNumber(f.selectedOption)?f.selectedOption=0===f.selectedOption?0:f.selectedOption-1:f.selectedOption=t.length-1}t[f.selectedOption].focus()},h.getDropdownElement=function(){return f.dropdownMenu},h.focusToggleElement=function(){f.toggleElement&&f.toggleElement[0].focus()},h.$watch("isOpen",function(e,t){var a,n,i,s;k&&f.dropdownMenu&&(o={top:(a=d.positionElements(l,f.dropdownMenu,"bottom-left",!(i=0))).top+"px",display:e?"block":"none"},(s=f.dropdownMenu.hasClass("dropdown-menu-right"))?(o.left="auto",(n=d.scrollbarPadding(k)).heightOverflow&&n.scrollbarWidth&&(i=n.scrollbarWidth),o.right=window.innerWidth-i-(a.left+l.prop("offsetWidth"))+"px"):(o.left=a.left+"px",o.right="auto"),$||(i=d.offset(k),o.top=a.top-i.top+"px",s?o.right=window.innerWidth-(a.left-i.left+l.prop("offsetWidth"))+"px":o.left=a.left-i.left+"px"),f.dropdownMenu.css(o));var o=k||l;o.hasClass(k?v:y)===!e&&u[e?"addClass":"removeClass"](o,k?v:y).then(function(){angular.isDefined(e)&&e!==t&&w(r,{open:!!e})}),e?(f.dropdownMenuTemplateUrl?m(f.dropdownMenuTemplateUrl).then(function(e){g=h.$new(),p(e.trim())(g,function(e){f.dropdownMenu.replaceWith(e),f.dropdownMenu=e,f.dropdownMenu.on("keydown",c.keybindFilter)})}):f.dropdownMenu&&f.dropdownMenu.on("keydown",c.keybindFilter),h.focusToggleElement(),c.open(h,l)):(c.close(h,l),f.dropdownMenuTemplateUrl&&(g&&g.$destroy(),o=angular.element('<ul class="dropdown-menu"></ul>'),f.dropdownMenu.replaceWith(o),f.dropdownMenu=o),f.selectedOption=null),angular.isFunction(b)&&b(r,e)})}]).directive("uibDropdown",function(){return{controller:"UibDropdownController",link:function(e,t,a,n){n.init()}}}).directive("uibDropdownMenu",function(){return{restrict:"A",require:"?^uibDropdown",link:function(e,t,a,n){n&&!angular.isDefined(a.dropdownNested)&&(t.addClass("dropdown-menu"),(a=a.templateUrl)&&(n.dropdownMenuTemplateUrl=a),n.dropdownMenu||(n.dropdownMenu=t))}}}).directive("uibDropdownToggle",function(){return{require:"?^uibDropdown",link:function(t,a,n,i){var e;i&&(a.addClass("dropdown-toggle"),i.toggleElement=a,e=function(e){e.preventDefault(),a.hasClass("disabled")||n.disabled||t.$apply(function(){i.toggle()})},a.bind("click",e),a.attr({"aria-haspopup":!0,"aria-expanded":!1}),t.$watch(i.isOpen,function(e){a.attr("aria-expanded",!!e)}),t.$on("$destroy",function(){a.unbind("click",e)}))}}}),angular.module("ui.bootstrap.stackedMap",[]).factory("$$stackedMap",function(){return{createNew:function(){var n=[];return{add:function(e,t){n.push({key:e,value:t})},get:function(e){for(var t=0;t<n.length;t++)if(e===n[t].key)return n[t]},keys:function(){for(var e=[],t=0;t<n.length;t++)e.push(n[t].key);return e},top:function(){return n[n.length-1]},remove:function(e){for(var t=-1,a=0;a<n.length;a++)if(e===n[a].key){t=a;break}return n.splice(t,1)[0]},removeTop:function(){return n.pop()},length:function(){return n.length}}}}}),angular.module("ui.bootstrap.modal",["ui.bootstrap.stackedMap","ui.bootstrap.position"]).factory("$$multiMap",function(){return{createNew:function(){var n={};return{entries:function(){return Object.keys(n).map(function(e){return{key:e,value:n[e]}})},get:function(e){return n[e]},hasKey:function(e){return!!n[e]},keys:function(){return Object.keys(n)},put:function(e,t){n[e]||(n[e]=[]),n[e].push(t)},remove:function(e,t){var a=n[e];a&&(-1!==(t=a.indexOf(t))&&a.splice(t,1),a.length||delete n[e])}}}}}).provider("$uibResolve",function(){var e=this;this.resolver=null,this.setResolver=function(e){this.resolver=e},this.$get=["$injector","$q",function(s,o){var r=e.resolver?s.get(e.resolver):null;return{resolve:function(e,t,a,n){if(r)return r.resolve(e,t,a,n);var i=[];return angular.forEach(e,function(e){angular.isFunction(e)||angular.isArray(e)?i.push(o.resolve(s.invoke(e))):angular.isString(e)?i.push(o.resolve(s.get(e))):i.push(o.resolve(e))}),o.all(i).then(function(a){var n={},i=0;return angular.forEach(e,function(e,t){n[t]=a[i++]}),n})}}}]}).directive("uibModalBackdrop",["$animate","$injector","$uibModalStack",function(s,e,t){return{restrict:"A",compile:function(e,t){return e.addClass(t.backdropClass),a}};function a(a,n,i){i.modalInClass&&(s.addClass(n,i.modalInClass),a.$on(t.NOW_CLOSING_EVENT,function(e,t){t=t();a.modalOptions.animation?s.removeClass(n,i.modalInClass).then(t):t()}))}}]).directive("uibModalWindow",["$uibModalStack","$q","$animateCss","$document",function(i,s,o,r){return{scope:{index:"@"},restrict:"A",transclude:!0,templateUrl:function(e,t){return t.templateUrl||"uib/template/modal/window.html"},link:function(t,a,n){a.addClass(n.windowTopClass||""),t.size=n.size,t.close=function(e){var t=i.getTop();t&&t.value.backdrop&&"static"!==t.value.backdrop&&e.target===e.currentTarget&&(e.preventDefault(),e.stopPropagation(),i.dismiss(t.key,"backdrop click"))},a.on("click",t.close),t.$isRendered=!0;var e=s.defer();t.$$postDigest(function(){e.resolve()}),e.promise.then(function(){var e=null;n.modalInClass&&(e=o(a,{addClass:n.modalInClass}).start(),t.$on(i.NOW_CLOSING_EVENT,function(e,t){t=t();o(a,{removeClass:n.modalInClass}).start().then(t)})),s.when(e).then(function(){var e=i.getTop();e&&i.modalRendered(e.key),r[0].activeElement&&a[0].contains(r[0].activeElement)||(a[0].querySelector("[autofocus]")||a[0]).focus()})})}}}]).directive("uibModalAnimationClass",function(){return{compile:function(e,t){t.modalAnimation&&e.addClass(t.uibModalAnimationClass)}}}).directive("uibModalTransclude",["$animate",function(s){return{link:function(e,t,a,n,i){i(e.$parent,function(e){t.empty(),s.enter(e,t)})}}}]).factory("$uibModalStack",["$animate","$animateCss","$document","$compile","$rootScope","$q","$$multiMap","$$stackedMap","$uibPosition",function(r,e,s,o,l,c,t,a,u){var d,p,m,g="modal-open",f=a.createNew(),h=t.createNew(),v={NOW_CLOSING_EVENT:"modal.stack.now-closing"},y=0,b=null;function w(){for(var e=-1,t=f.keys(),a=0;a<t.length;a++)f.get(t[a]).value.backdrop&&(e=a);return e=-1<e&&e<y?y:e}function n(a,e){var n=f.get(a).value,i=n.appendTo;f.remove(a),(b=f.top())&&(y=parseInt(b.value.modalDomEl.attr("index"),10)),k(n.modalDomEl,n.modalScope,function(){var e=n.openedClass||g;h.remove(e,a);var t=h.hasKey(e);i.toggleClass(e,t),!t&&m&&m.heightOverflow&&m.scrollbarWidth&&(m.originalRight?i.css({paddingRight:m.originalRight+"px"}):i.css({paddingRight:""}),m=null),$(!0)},n.closedDeferred),d&&-1===w()&&(k(d,p,function(){0}),p=d=void 0),e&&e.focus?e.focus():i.focus&&i.focus()}function $(e){var t;0<f.length()&&(t=f.top().value).modalDomEl.toggleClass(t.windowTopClass||"",e)}function k(e,t,a,n){var i,s=null;return t.$broadcast(v.NOW_CLOSING_EVENT,function(){return i||(i=c.defer(),s=i.promise),function(){i.resolve()}}),c.when(s).then(o);function o(){o.done||(o.done=!0,r.leave(e).then(function(){a&&a(),e.remove(),n&&n.resolve()}),t.$destroy())}}function i(e){if(e.isDefaultPrevented())return e;var t=f.top();if(t)switch(e.which){case 27:t.value.keyboard&&(e.preventDefault(),l.$apply(function(){v.dismiss(t.key,"escape key press")}));break;case 9:var a=v.loadFocusElementList(t),n=!1;e.shiftKey?(v.isFocusInFirstItem(e,a)||v.isModalFocused(e,t))&&(n=v.focusLastFocusableElement(a)):v.isFocusInLastItem(e,a)&&(n=v.focusFirstFocusableElement(a)),n&&(e.preventDefault(),e.stopPropagation())}}function x(e,t,a){return!e.value.modalScope.$broadcast("modal.closing",t,a).defaultPrevented}return l.$watch(w,function(e){p&&(p.index=e)}),s.on("keydown",i),l.$on("$destroy",function(){s.off("keydown",i)}),v.open=function(e,t){var a=s[0].activeElement,n=t.openedClass||g;$(!1),b=f.top(),f.add(e,{deferred:t.deferred,renderDeferred:t.renderDeferred,closedDeferred:t.closedDeferred,modalScope:t.scope,backdrop:t.backdrop,keyboard:t.keyboard,openedClass:t.openedClass,windowTopClass:t.windowTopClass,animation:t.animation,appendTo:t.appendTo}),h.put(n,e);var i=t.appendTo,e=w();if(!i.length)throw new Error("appendTo element not found. Make sure that the element passed is in DOM.");0<=e&&!d&&((p=l.$new(!0)).modalOptions=t,p.index=e,(d=angular.element('<div uib-modal-backdrop="modal-backdrop"></div>')).attr({class:"modal-backdrop","ng-style":"{'z-index': 1040 + (index && 1 || 0) + index*10}","uib-modal-animation-class":"fade","modal-in-class":"in"}),t.backdropClass&&d.addClass(t.backdropClass),t.animation&&d.attr("modal-animation","true"),o(d)(p),r.enter(d,i),u.isScrollable(i)&&(m=u.scrollbarPadding(i)).heightOverflow&&m.scrollbarWidth&&i.css({paddingRight:m.right+"px"})),y=b?parseInt(b.value.modalDomEl.attr("index"),10)+1:0;e=angular.element('<div uib-modal-window="modal-window"></div>');e.attr({class:"modal","template-url":t.windowTemplateUrl,"window-top-class":t.windowTopClass,role:"dialog",size:t.size,index:y,animate:"animate","ng-style":"{'z-index': 1050 + index*10, display: 'block'}",tabindex:-1,"uib-modal-animation-class":"fade","modal-in-class":"in"}).html(t.content),t.windowClass&&e.addClass(t.windowClass),t.animation&&e.attr("modal-animation","true"),i.addClass(n),r.enter(o(e)(t.scope),i),f.top().value.modalDomEl=e,f.top().value.modalOpener=a},v.close=function(e,t){var a=f.get(e);return a&&x(a,t,!0)?(a.value.modalScope.$$uibDestructionScheduled=!0,a.value.deferred.resolve(t),n(e,a.value.modalOpener),!0):!a},v.dismiss=function(e,t){var a=f.get(e);return a&&x(a,t,!1)?(a.value.modalScope.$$uibDestructionScheduled=!0,a.value.deferred.reject(t),n(e,a.value.modalOpener),!0):!a},v.dismissAll=function(e){for(var t=this.getTop();t&&this.dismiss(t.key,e);)t=this.getTop()},v.getTop=function(){return f.top()},v.modalRendered=function(e){e=f.get(e);e&&e.value.renderDeferred.resolve()},v.focusFirstFocusableElement=function(e){return 0<e.length&&(e[0].focus(),!0)},v.focusLastFocusableElement=function(e){return 0<e.length&&(e[e.length-1].focus(),!0)},v.isModalFocused=function(e,t){if(e&&t){t=t.value.modalDomEl;if(t&&t.length)return(e.target||e.srcElement)===t[0]}return!1},v.isFocusInFirstItem=function(e,t){return 0<t.length&&(e.target||e.srcElement)===t[0]},v.isFocusInLastItem=function(e,t){return 0<t.length&&(e.target||e.srcElement)===t[t.length-1]},v.loadFocusElementList=function(e){if(e){e=e.value.modalDomEl;if(e&&e.length){e=e[0].querySelectorAll("a[href], area[href], input:not([disabled]):not([tabindex='-1']), button:not([disabled]):not([tabindex='-1']),select:not([disabled]):not([tabindex='-1']), textarea:not([disabled]):not([tabindex='-1']), iframe, object, embed, *[tabindex]:not([tabindex='-1']), *[contenteditable=true]");return e&&Array.prototype.filter.call(e,function(e){return!!((e=e).offsetWidth||e.offsetHeight||e.getClientRects().length)})}}},v}]).provider("$uibModal",function(){var y={options:{animation:!0,backdrop:!0,keyboard:!0},$get:["$rootScope","$q","$document","$templateRequest","$controller","$uibResolve","$uibModalStack",function(p,i,s,m,g,f,h){var e={};var v=null;return e.getPromiseChain=function(){return v},e.open=function(o){var r=i.defer(),l=i.defer(),c=i.defer(),u=i.defer(),d={result:r.promise,opened:l.promise,closed:c.promise,rendered:u.promise,close:function(e){return h.close(d,e)},dismiss:function(e){return h.dismiss(d,e)}};if((o=angular.extend({},y.options,o)).resolve=o.resolve||{},o.appendTo=o.appendTo||s.find("body").eq(0),!o.template&&!o.templateUrl)throw new Error("One of template or templateUrl options is required.");var e,t,a=i.all([(e=o).template?i.when(e.template):m(angular.isFunction(e.templateUrl)?e.templateUrl():e.templateUrl),f.resolve(o.resolve,{},null,null)]);function n(){return a}return t=v=i.all([v]).then(n,n).then(function(e){var t=o.scope||p,a=t.$new();a.$close=d.close,a.$dismiss=d.dismiss,a.$on("$destroy",function(){a.$$uibDestructionScheduled||a.$dismiss("$uibUnscheduledDestruction")});var n,i,s={};o.controller&&(s.$scope=a,s.$scope.$resolve={},s.$uibModalInstance=d,angular.forEach(e[1],function(e,t){s[t]=e,s.$scope.$resolve[t]=e}),i=g(o.controller,s,!0,o.controllerAs),o.controllerAs&&o.bindToController&&((n=i.instance).$close=a.$close,n.$dismiss=a.$dismiss,angular.extend(n,{$resolve:s.$scope.$resolve},t)),n=i(),angular.isFunction(n.$onInit)&&n.$onInit()),h.open(d,{scope:a,deferred:r,renderDeferred:u,closedDeferred:c,content:e[0],animation:o.animation,backdrop:o.backdrop,keyboard:o.keyboard,backdropClass:o.backdropClass,windowTopClass:o.windowTopClass,windowClass:o.windowClass,windowTemplateUrl:o.windowTemplateUrl,size:o.size,openedClass:o.openedClass,appendTo:o.appendTo}),l.resolve(!0)},function(e){l.reject(e),r.reject(e)}).finally(function(){v===t&&(v=null)}),d},e}]};return y}),angular.module("ui.bootstrap.paging",[]).factory("uibPaging",["$parse",function(e){return{create:function(a,n,i){a.setNumPages=i.numPages?e(i.numPages).assign:angular.noop,a.ngModelCtrl={$setViewValue:angular.noop},a._watchers=[],a.init=function(e,t){a.ngModelCtrl=e,a.config=t,e.$render=function(){a.render()},i.itemsPerPage?a._watchers.push(n.$parent.$watch(i.itemsPerPage,function(e){a.itemsPerPage=parseInt(e,10),n.totalPages=a.calculateTotalPages(),a.updatePage()})):a.itemsPerPage=t.itemsPerPage,n.$watch("totalItems",function(e,t){!angular.isDefined(e)&&e===t||(n.totalPages=a.calculateTotalPages(),a.updatePage())})},a.calculateTotalPages=function(){var e=a.itemsPerPage<1?1:Math.ceil(n.totalItems/a.itemsPerPage);return Math.max(e||0,1)},a.render=function(){n.page=parseInt(a.ngModelCtrl.$viewValue,10)||1},n.selectPage=function(e,t){t&&t.preventDefault(),(!n.ngDisabled||!t)&&n.page!==e&&0<e&&e<=n.totalPages&&(t&&t.target&&t.target.blur(),a.ngModelCtrl.$setViewValue(e),a.ngModelCtrl.$render())},n.getText=function(e){return n[e+"Text"]||a.config[e+"Text"]},n.noPrevious=function(){return 1===n.page},n.noNext=function(){return n.page===n.totalPages},a.updatePage=function(){a.setNumPages(n.$parent,n.totalPages),n.page>n.totalPages?n.selectPage(n.totalPages):a.ngModelCtrl.$render()},n.$on("$destroy",function(){for(;a._watchers.length;)a._watchers.shift()()})}}}]),angular.module("ui.bootstrap.pager",["ui.bootstrap.paging","ui.bootstrap.tabindex"]).controller("UibPagerController",["$scope","$attrs","uibPaging","uibPagerConfig",function(e,t,a,n){e.align=angular.isDefined(t.align)?e.$parent.$eval(t.align):n.align,a.create(this,e,t)}]).constant("uibPagerConfig",{itemsPerPage:10,previousText:"« Previous",nextText:"Next »",align:!0}).directive("uibPager",["uibPagerConfig",function(i){return{scope:{totalItems:"=",previousText:"@",nextText:"@",ngDisabled:"="},require:["uibPager","?ngModel"],restrict:"A",controller:"UibPagerController",controllerAs:"pager",templateUrl:function(e,t){return t.templateUrl||"uib/template/pager/pager.html"},link:function(e,t,a,n){t.addClass("pager");t=n[0],n=n[1];n&&t.init(n,i)}}}]),angular.module("ui.bootstrap.pagination",["ui.bootstrap.paging","ui.bootstrap.tabindex"]).controller("UibPaginationController",["$scope","$attrs","$parse","uibPaging","uibPaginationConfig",function(t,a,e,n,i){var s=this,u=angular.isDefined(a.maxSize)?t.$parent.$eval(a.maxSize):i.maxSize,d=angular.isDefined(a.rotate)?t.$parent.$eval(a.rotate):i.rotate,p=angular.isDefined(a.forceEllipses)?t.$parent.$eval(a.forceEllipses):i.forceEllipses,m=angular.isDefined(a.boundaryLinkNumbers)?t.$parent.$eval(a.boundaryLinkNumbers):i.boundaryLinkNumbers,g=angular.isDefined(a.pageLabel)?function(e){return t.$parent.$eval(a.pageLabel,{$page:e})}:angular.identity;function f(e,t,a){return{number:e,text:t,active:a}}t.boundaryLinks=angular.isDefined(a.boundaryLinks)?t.$parent.$eval(a.boundaryLinks):i.boundaryLinks,t.directionLinks=angular.isDefined(a.directionLinks)?t.$parent.$eval(a.directionLinks):i.directionLinks,n.create(this,t,a),a.maxSize&&s._watchers.push(t.$parent.$watch(e(a.maxSize),function(e){u=parseInt(e,10),s.render()}));var o=this.render;this.render=function(){o(),0<t.page&&t.page<=t.totalPages&&(t.pages=function(e,t){var a=[],n=1,i=t,s=angular.isDefined(u)&&u<t;s&&(d?t<(i=(n=Math.max(e-Math.floor(u/2),1))+u-1)&&(n=(i=t)-u+1):(n=(Math.ceil(e/u)-1)*u+1,i=Math.min(n+u-1,t)));for(var o,r,l=n;l<=i;l++){var c=f(l,g(l),l===e);a.push(c)}return s&&0<u&&(!d||p||m)&&(1<n&&((!m||3<n)&&(s=f(n-1,"...",!1),a.unshift(s)),m&&(3===n&&(o=f(2,"2",!1),a.unshift(o)),o=f(1,"1",!1),a.unshift(o))),i<t&&((!m||i<t-2)&&(r=f(i+1,"...",!1),a.push(r)),m&&(i===t-2&&(r=f(t-1,t-1,!1),a.push(r)),t=f(t,t,!1),a.push(t)))),a}(t.page,t.totalPages))}}]).constant("uibPaginationConfig",{itemsPerPage:10,boundaryLinks:!1,boundaryLinkNumbers:!1,directionLinks:!0,firstText:"First",previousText:"Previous",nextText:"Next",lastText:"Last",rotate:!0,forceEllipses:!1}).directive("uibPagination",["$parse","uibPaginationConfig",function(e,i){return{scope:{totalItems:"=",firstText:"@",previousText:"@",nextText:"@",lastText:"@",ngDisabled:"="},require:["uibPagination","?ngModel"],restrict:"A",controller:"UibPaginationController",controllerAs:"pagination",templateUrl:function(e,t){return t.templateUrl||"uib/template/pagination/pagination.html"},link:function(e,t,a,n){t.addClass("pagination");t=n[0],n=n[1];n&&t.init(n,i)}}}]),angular.module("ui.bootstrap.tooltip",["ui.bootstrap.position","ui.bootstrap.stackedMap"]).provider("$uibTooltip",function(){var r={placement:"top",placementClassPrefix:"",animation:!0,popupDelay:0,popupCloseDelay:0,useContentExp:!1},l={mouseenter:"mouseleave",click:"click",outsideClick:"outsideClick",focus:"blur",none:""},c={};this.options=function(e){angular.extend(c,e)},this.setTriggers=function(e){angular.extend(l,e)},this.$get=["$window","$compile","$timeout","$document","$uibPosition","$interpolate","$rootScope","$parse","$$stackedMap",function(e,s,R,q,V,o,t,Y,a){var F=a.createNew();function n(e){27!==e.which||(e=F.top())&&(e.value.close(),F.removeTop(),e=null)}return q.on("keypress",n),t.$on("$destroy",function(){q.off("keypress",n)}),function(O,U,a,N){function B(e){var t=(e||N.trigger||a).split(" "),e=t.map(function(e){return l[e]||e});return{show:t,hide:e}}N=angular.extend({},r,c,N);var e=O.replace(/[A-Z]/g,function(e,t){return(t?"-":"")+e.toLowerCase()}),t=o.startSymbol(),n=o.endSymbol(),i="<div "+e+'-popup uib-title="'+t+"title"+n+'" '+(N.useContentExp?'content-exp="contentExp()" ':'content="'+t+"content"+n+'" ')+'origin-scope="origScope" class="uib-position-measure '+U+'" tooltip-animation-class="fade"uib-tooltip-classes ng-class="{ in: isOpen }" ></div>';return{compile:function(e,t){var L=s(i);return function(a,i,n,e){var s,t,o,r,l,c,u,d=!!angular.isDefined(N.appendToBody)&&N.appendToBody,p=B(void 0),m=angular.isDefined(n[U+"Enable"]),g=a.$new(!0),f=!1,h=!!angular.isDefined(n[U+"IsOpen"])&&Y(n[U+"IsOpen"]),v=!!N.useContentExp&&Y(n[O]),y=[],b=function(){s&&s.html()&&(c=c||R(function(){var e=V.positionElements(i,s,g.placement,d),t=angular.isDefined(s.offsetHeight)?s.offsetHeight:s.prop("offsetHeight"),a=d?V.offset(i):V.position(i);s.css({top:e.top+"px",left:e.left+"px"});var n=e.placement.split("-");s.hasClass(n[0])||(s.removeClass(u.split("-")[0]),s.addClass(n[0])),s.hasClass(N.placementClassPrefix+e.placement)||(s.removeClass(N.placementClassPrefix+u),s.addClass(N.placementClassPrefix+e.placement)),R(function(){var e=angular.isDefined(s.offsetHeight)?s.offsetHeight:s.prop("offsetHeight"),e=V.adjustTop(n,a,t,e);e&&s.css(e)},0,!1),s.hasClass("uib-position-measure")?(V.positionArrow(s,e.placement),s.removeClass("uib-position-measure")):u!==e.placement&&V.positionArrow(s,e.placement),u=e.placement,c=null},0,!1))};function w(){(g.isOpen?k:$)()}function $(){m&&!a.$eval(n[U+"Enable"])||(I(),function(){g.title=n[U+"Title"],g.content=v?v(a):n[O];g.popupClass=n[U+"Class"],g.placement=angular.isDefined(n[U+"Placement"])?n[U+"Placement"]:N.placement;var e=V.parsePlacement(g.placement);u=e[1]?e[0]+"-"+e[1]:e[0];var t=parseInt(n[U+"PopupDelay"],10),e=parseInt(n[U+"PopupCloseDelay"],10);g.popupDelay=isNaN(t)?N.popupDelay:t,g.popupCloseDelay=isNaN(e)?N.popupCloseDelay:e}(),g.popupDelay?r=r||R(x,g.popupDelay,!1):x())}function k(){_(),g.popupCloseDelay?l=l||R(S,g.popupCloseDelay,!1):S()}function x(){if(_(),I(),!g.content)return angular.noop;s||(t=g.$new(),s=L(t,function(e){d?q.find("body").append(e):i.after(e)}),function(){y.length=0,v?(y.push(a.$watch(v,function(e){!(g.content=e)&&g.isOpen&&S()})),y.push(t.$watch(function(){f||(f=!0,t.$$postDigest(function(){f=!1,g&&g.isOpen&&b()}))}))):y.push(n.$observe(O,function(e){(!(g.content=e)&&g.isOpen?S:b)()}));y.push(n.$observe(U+"Title",function(e){g.title=e,g.isOpen&&b()})),y.push(n.$observe(U+"Placement",function(e){g.placement=e||N.placement,g.isOpen&&b()}))}()),g.$evalAsync(function(){A(g.isOpen=!0),b()})}function _(){r&&(R.cancel(r),r=null),c&&(R.cancel(c),c=null)}function S(){g&&g.$evalAsync(function(){g&&(A(g.isOpen=!1),g.animation?o=o||R(C,150,!1):C())})}function I(){l&&(R.cancel(l),l=null),o&&(R.cancel(o),o=null)}function C(){_(),I(),y.length&&(angular.forEach(y,function(e){e()}),y.length=0),s&&(s.remove(),s=null),t&&(t.$destroy(),t=null)}function A(e){h&&angular.isFunction(h.assign)&&h.assign(a,e)}function M(e){g&&g.isOpen&&s&&(i[0].contains(e.target)||s[0].contains(e.target)||k())}g.origScope=a,g.isOpen=!1,F.add(g,{close:S}),g.contentExp=function(){return g.content},n.$observe("disabled",function(e){e&&_(),e&&g.isOpen&&S()}),h&&a.$watch(h,function(e){g&&!e===g.isOpen&&w()});function D(){p.show.forEach(function(e){"outsideClick"===e?i.off("click",w):(i.off(e,$),i.off(e,w))}),p.hide.forEach(function(e){"outsideClick"===e?q.off("click",M):i.off(e,k)})}var T,P,E;T=[],P=[],E=a.$eval(n[U+"Trigger"]),D(),"none"!==(p=angular.isObject(E)?(Object.keys(E).forEach(function(e){T.push(e),P.push(E[e])}),{show:T,hide:P}):B(E)).show&&p.show.forEach(function(e,t){"outsideClick"===e?(i.on("click",w),q.on("click",M)):e===p.hide[t]?i.on(e,w):e&&(i.on(e,$),i.on(p.hide[t],k)),i.on("keypress",function(e){27===e.which&&k()})});var j=a.$eval(n[U+"Animation"]);g.animation=angular.isDefined(j)?!!j:N.animation;var j=U+"AppendToBody",j=j in n&&void 0===n[j]||a.$eval(n[j]),d=angular.isDefined(j)?j:d;a.$on("$destroy",function(){D(),C(),F.remove(g),g=null})}}}}}]}).directive("uibTooltipTemplateTransclude",["$animate","$sce","$compile","$templateRequest",function(u,n,d,p){return{link:function(e,i,t){function s(){a&&(a.remove(),a=null),o&&(o.$destroy(),o=null),r&&(u.leave(r).then(function(){a=null}),a=r,r=null)}var o,a,r,l=e.$eval(t.tooltipTemplateTranscludeScope),c=0;e.$watch(n.parseAsResourceUrl(t.uibTooltipTemplateTransclude),function(a){var n=++c;a?(p(a,!0).then(function(e){var t;n===c&&(t=l.$new(),e=d(e)(t,function(e){s(),u.enter(e,i)}),r=e,(o=t).$emit("$includeContentLoaded",a))},function(){n===c&&(s(),e.$emit("$includeContentError",a))}),e.$emit("$includeContentRequested",a)):s()}),e.$on("$destroy",s)}}}]).directive("uibTooltipClasses",["$uibPosition",function(i){return{restrict:"A",link:function(e,t,a){var n;e.placement&&(n=i.parsePlacement(e.placement),t.addClass(n[0])),e.popupClass&&t.addClass(e.popupClass),e.animation&&t.addClass(a.tooltipAnimationClass)}}}]).directive("uibTooltipPopup",function(){return{restrict:"A",scope:{content:"@"},templateUrl:"uib/template/tooltip/tooltip-popup.html"}}).directive("uibTooltip",["$uibTooltip",function(e){return e("uibTooltip","tooltip","mouseenter")}]).directive("uibTooltipTemplatePopup",function(){return{restrict:"A",scope:{contentExp:"&",originScope:"&"},templateUrl:"uib/template/tooltip/tooltip-template-popup.html"}}).directive("uibTooltipTemplate",["$uibTooltip",function(e){return e("uibTooltipTemplate","tooltip","mouseenter",{useContentExp:!0})}]).directive("uibTooltipHtmlPopup",function(){return{restrict:"A",scope:{contentExp:"&"},templateUrl:"uib/template/tooltip/tooltip-html-popup.html"}}).directive("uibTooltipHtml",["$uibTooltip",function(e){return e("uibTooltipHtml","tooltip","mouseenter",{useContentExp:!0})}]),angular.module("ui.bootstrap.popover",["ui.bootstrap.tooltip"]).directive("uibPopoverTemplatePopup",function(){return{restrict:"A",scope:{uibTitle:"@",contentExp:"&",originScope:"&"},templateUrl:"uib/template/popover/popover-template.html"}}).directive("uibPopoverTemplate",["$uibTooltip",function(e){return e("uibPopoverTemplate","popover","click",{useContentExp:!0})}]).directive("uibPopoverHtmlPopup",function(){return{restrict:"A",scope:{contentExp:"&",uibTitle:"@"},templateUrl:"uib/template/popover/popover-html.html"}}).directive("uibPopoverHtml",["$uibTooltip",function(e){return e("uibPopoverHtml","popover","click",{useContentExp:!0})}]).directive("uibPopoverPopup",function(){return{restrict:"A",scope:{uibTitle:"@",content:"@"},templateUrl:"uib/template/popover/popover.html"}}).directive("uibPopover",["$uibTooltip",function(e){return e("uibPopover","popover","click")}]),angular.module("ui.bootstrap.progressbar",[]).constant("uibProgressConfig",{animate:!0,max:100}).controller("UibProgressController",["$scope","$attrs","uibProgressConfig",function(e,t,a){var n=this,i=angular.isDefined(t.animate)?e.$parent.$eval(t.animate):a.animate;function s(){return angular.isDefined(e.maxParam)?e.maxParam:a.max}this.bars=[],e.max=s(),this.addBar=function(t,e,a){i||e.css({transition:"none"}),this.bars.push(t),t.max=s(),t.title=a&&angular.isDefined(a.title)?a.title:"progressbar",t.$watch("value",function(e){t.recalculatePercentage()}),t.recalculatePercentage=function(){var e=n.bars.reduce(function(e,t){return t.percent=+(100*t.value/t.max).toFixed(2),e+t.percent},0);100<e&&(t.percent-=e-100)},t.$on("$destroy",function(){e=null,n.removeBar(t)})},this.removeBar=function(e){this.bars.splice(this.bars.indexOf(e),1),this.bars.forEach(function(e){e.recalculatePercentage()})},e.$watch("maxParam",function(e){n.bars.forEach(function(e){e.max=s(),e.recalculatePercentage()})})}]).directive("uibProgress",function(){return{replace:!0,transclude:!0,controller:"UibProgressController",require:"uibProgress",scope:{maxParam:"=?max"},templateUrl:"uib/template/progressbar/progress.html"}}).directive("uibBar",function(){return{replace:!0,transclude:!0,require:"^uibProgress",scope:{value:"=",type:"@"},templateUrl:"uib/template/progressbar/bar.html",link:function(e,t,a,n){n.addBar(e,t,a)}}}).directive("uibProgressbar",function(){return{replace:!0,transclude:!0,controller:"UibProgressController",scope:{value:"=",maxParam:"=?max",type:"@"},templateUrl:"uib/template/progressbar/progressbar.html",link:function(e,t,a,n){n.addBar(e,angular.element(t.children()[0]),{title:a.title})}}}),angular.module("ui.bootstrap.rating",[]).constant("uibRatingConfig",{max:5,stateOn:null,stateOff:null,enableReset:!0,titles:["one","two","three","four","five"]}).controller("UibRatingController",["$scope","$attrs","uibRatingConfig",function(t,a,n){var i={$setViewValue:angular.noop},s=this;this.init=function(e){(i=e).$render=this.render,i.$formatters.push(function(e){return e=angular.isNumber(e)&&e<<0!==e?Math.round(e):e}),this.stateOn=angular.isDefined(a.stateOn)?t.$parent.$eval(a.stateOn):n.stateOn,this.stateOff=angular.isDefined(a.stateOff)?t.$parent.$eval(a.stateOff):n.stateOff,this.enableReset=angular.isDefined(a.enableReset)?t.$parent.$eval(a.enableReset):n.enableReset;e=angular.isDefined(a.titles)?t.$parent.$eval(a.titles):n.titles;this.titles=angular.isArray(e)&&0<e.length?e:n.titles;e=angular.isDefined(a.ratingStates)?t.$parent.$eval(a.ratingStates):new Array(angular.isDefined(a.max)?t.$parent.$eval(a.max):n.max);t.range=this.buildTemplateObjects(e)},this.buildTemplateObjects=function(e){for(var t=0,a=e.length;t<a;t++)e[t]=angular.extend({index:t},{stateOn:this.stateOn,stateOff:this.stateOff,title:this.getTitle(t)},e[t]);return e},this.getTitle=function(e){return e>=this.titles.length?e+1:this.titles[e]},t.rate=function(e){!t.readonly&&0<=e&&e<=t.range.length&&(e=s.enableReset&&i.$viewValue===e?0:e,i.$setViewValue(e),i.$render())},t.enter=function(e){t.readonly||(t.value=e),t.onHover({value:e})},t.reset=function(){t.value=i.$viewValue,t.onLeave()},t.onKeydown=function(e){/(37|38|39|40)/.test(e.which)&&(e.preventDefault(),e.stopPropagation(),t.rate(t.value+(38===e.which||39===e.which?1:-1)))},this.render=function(){t.value=i.$viewValue,t.title=s.getTitle(t.value-1)}}]).directive("uibRating",function(){return{require:["uibRating","ngModel"],restrict:"A",scope:{readonly:"=?readOnly",onHover:"&",onLeave:"&"},controller:"UibRatingController",templateUrl:"uib/template/rating/rating.html",link:function(e,t,a,n){var i=n[0],n=n[1];i.init(n)}}}),angular.module("ui.bootstrap.tabs",[]).controller("UibTabsetController",["$scope",function(e){var n,i,s=this;function o(e){for(var t=0;t<s.tabs.length;t++)if(s.tabs[t].index===e)return t}s.tabs=[],s.select=function(e,t){if(!i){var a=o(n),a=s.tabs[a];if(a){if(a.tab.onDeselect({$event:t,$selectedIndex:e}),t&&t.isDefaultPrevented())return;a.tab.active=!1}e=s.tabs[e];e?(e.tab.onSelect({$event:t}),e.tab.active=!0,s.active=e.index,n=e.index):!e&&angular.isDefined(n)&&(s.active=null,n=null)}},s.addTab=function(e){s.tabs.push({tab:e,index:e.index}),s.tabs.sort(function(e,t){return e.index>t.index?1:e.index<t.index?-1:0}),e.index!==s.active&&(angular.isDefined(s.active)||1!==s.tabs.length)||(e=o(e.index),s.select(e))},s.removeTab=function(e){for(var t,a,n=0;n<s.tabs.length;n++)if(s.tabs[n].tab===e){t=n;break}s.tabs[t].index===s.active&&(a=t===s.tabs.length-1?t-1:t+1%s.tabs.length,s.select(a)),s.tabs.splice(t,1)},e.$watch("tabset.active",function(e){angular.isDefined(e)&&e!==n&&s.select(o(e))}),e.$on("$destroy",function(){i=!0})}]).directive("uibTabset",function(){return{transclude:!0,replace:!0,scope:{},bindToController:{active:"=?",type:"@"},controller:"UibTabsetController",controllerAs:"tabset",templateUrl:function(e,t){return t.templateUrl||"uib/template/tabs/tabset.html"},link:function(e,t,a){e.vertical=!!angular.isDefined(a.vertical)&&e.$parent.$eval(a.vertical),e.justified=!!angular.isDefined(a.justified)&&e.$parent.$eval(a.justified)}}}).directive("uibTab",["$parse",function(s){return{require:"^uibTabset",replace:!0,templateUrl:function(e,t){return t.templateUrl||"uib/template/tabs/tab.html"},transclude:!0,scope:{heading:"@",index:"=?",classes:"@?",onSelect:"&select",onDeselect:"&deselect"},controller:function(){},controllerAs:"tab",link:function(n,e,t,i,a){n.disabled=!1,t.disable&&n.$parent.$watch(s(t.disable),function(e){n.disabled=!!e}),angular.isUndefined(t.index)&&(i.tabs&&i.tabs.length?n.index=Math.max.apply(null,i.tabs.map(function(e){return e.index}))+1:n.index=0),angular.isUndefined(t.classes)&&(n.classes=""),n.select=function(e){if(!n.disabled){for(var t,a=0;a<i.tabs.length;a++)if(i.tabs[a].tab===n){t=a;break}i.select(t,e)}},i.addTab(n),n.$on("$destroy",function(){i.removeTab(n)}),n.$transcludeFn=a}}}]).directive("uibTabHeadingTransclude",function(){return{restrict:"A",require:"^uibTab",link:function(e,t){e.$watch("headingElement",function(e){e&&(t.html(""),t.append(e))})}}}).directive("uibTabContentTransclude",function(){return{restrict:"A",require:"^uibTabset",link:function(e,a,t){var n=e.$eval(t.uibTabContentTransclude).tab;n.$transcludeFn(n.$parent,function(e){angular.forEach(e,function(e){var t;(t=e).tagName&&(t.hasAttribute("uib-tab-heading")||t.hasAttribute("data-uib-tab-heading")||t.hasAttribute("x-uib-tab-heading")||"uib-tab-heading"===t.tagName.toLowerCase()||"data-uib-tab-heading"===t.tagName.toLowerCase()||"x-uib-tab-heading"===t.tagName.toLowerCase()||"uib:tab-heading"===t.tagName.toLowerCase())?n.headingElement=e:a.append(e)})})}}}),angular.module("ui.bootstrap.timepicker",[]).constant("uibTimepickerConfig",{hourStep:1,minuteStep:1,secondStep:1,showMeridian:!0,showSeconds:!1,meridians:null,readonlyInput:!1,mousewheel:!0,arrowkeys:!0,showSpinners:!0,templateUrl:"uib/template/timepicker/timepicker.html"}).controller("UibTimepickerController",["$scope","$element","$attrs","$parse","$log","$locale","uibTimepickerConfig",function(i,e,n,t,a,s,o){var r=new Date,l=[],c={$setViewValue:angular.noop},u=angular.isDefined(n.meridians)?i.$parent.$eval(n.meridians):o.meridians||s.DATETIME_FORMATS.AMPMS,d=!angular.isDefined(n.padHours)||i.$parent.$eval(n.padHours);i.tabindex=angular.isDefined(n.tabindex)?n.tabindex:0,e.removeAttr("tabindex"),this.init=function(e,t){(c=e).$render=this.render,c.$formatters.unshift(function(e){return e?new Date(e):null});var a=t.eq(0),e=t.eq(1),t=t.eq(2);(angular.isDefined(n.mousewheel)?i.$parent.$eval(n.mousewheel):o.mousewheel)&&this.setupMousewheelEvents(a,e,t),(angular.isDefined(n.arrowkeys)?i.$parent.$eval(n.arrowkeys):o.arrowkeys)&&this.setupArrowkeyEvents(a,e,t),i.readonlyInput=angular.isDefined(n.readonlyInput)?i.$parent.$eval(n.readonlyInput):o.readonlyInput,this.setupInputEvents(a,e,t)};var p=o.hourStep;n.hourStep&&l.push(i.$parent.$watch(t(n.hourStep),function(e){p=+e}));var m,g,f=o.minuteStep;n.minuteStep&&l.push(i.$parent.$watch(t(n.minuteStep),function(e){f=+e})),l.push(i.$parent.$watch(t(n.min),function(e){e=new Date(e);m=isNaN(e)?void 0:e})),l.push(i.$parent.$watch(t(n.max),function(e){e=new Date(e);g=isNaN(e)?void 0:e}));var h=!1;n.ngDisabled&&l.push(i.$parent.$watch(t(n.ngDisabled),function(e){h=e})),i.noIncrementHours=function(){var e=S(r,60*p);return h||g<e||e<r&&e<m},i.noDecrementHours=function(){var e=S(r,60*-p);return h||e<m||r<e&&g<e},i.noIncrementMinutes=function(){var e=S(r,f);return h||g<e||e<r&&e<m},i.noDecrementMinutes=function(){var e=S(r,-f);return h||e<m||r<e&&g<e},i.noIncrementSeconds=function(){var e=I(r,v);return h||g<e||e<r&&e<m},i.noDecrementSeconds=function(){var e=I(r,-v);return h||e<m||r<e&&g<e},i.noToggleMeridian=function(){return r.getHours()<12?h||S(r,720)>g:h||S(r,-720)<m};var v=o.secondStep;function y(){var e=+i.hours;if((i.showMeridian?0<e&&e<13:0<=e&&e<24)&&""!==i.hours)return i.showMeridian&&(12===e&&(e=0),i.meridian===u[1]&&(e+=12)),e}function b(){var e=+i.minutes;if(0<=e&&e<60&&""!==i.minutes)return e}function w(e,t){return null===e?"":angular.isDefined(e)&&e.toString().length<2&&!t?"0"+e:e.toString()}function $(e){k(),c.$setViewValue(new Date(r)),x(e)}function k(){c.$setValidity("time",!0),i.invalidHours=!1,i.invalidMinutes=!1,i.invalidSeconds=!1}function x(e){var t,a,n;c.$modelValue?(t=r.getHours(),a=r.getMinutes(),n=r.getSeconds(),i.showMeridian&&(t=0===t||12===t?12:t%12),i.hours="h"===e?t:w(t,!d),"m"!==e&&(i.minutes=w(a)),i.meridian=r.getHours()<12?u[0]:u[1],"s"!==e&&(i.seconds=w(n)),i.meridian=r.getHours()<12?u[0]:u[1]):(i.hours=null,i.minutes=null,i.seconds=null,i.meridian=u[0])}function _(e){r=I(r,e),$()}function S(e,t){return I(e,60*t)}function I(e,t){t=new Date(e.getTime()+1e3*t),e=new Date(e);return e.setHours(t.getHours(),t.getMinutes(),t.getSeconds()),e}function C(){return(null===i.hours||""===i.hours)&&(null===i.minutes||""===i.minutes)&&(!i.showSeconds||i.showSeconds&&(null===i.seconds||""===i.seconds))}n.secondStep&&l.push(i.$parent.$watch(t(n.secondStep),function(e){v=+e})),i.showSeconds=o.showSeconds,n.showSeconds&&l.push(i.$parent.$watch(t(n.showSeconds),function(e){i.showSeconds=!!e})),i.showMeridian=o.showMeridian,n.showMeridian&&l.push(i.$parent.$watch(t(n.showMeridian),function(e){var t;i.showMeridian=!!e,c.$error.time?(t=y(),e=b(),angular.isDefined(t)&&angular.isDefined(e)&&(r.setHours(t),$())):x()})),this.setupMousewheelEvents=function(e,t,a){function n(e){var t=(e=e.originalEvent?e.originalEvent:e).wheelDelta||-e.deltaY;return e.detail||0<t}e.bind("mousewheel wheel",function(e){h||i.$apply(n(e)?i.incrementHours():i.decrementHours()),e.preventDefault()}),t.bind("mousewheel wheel",function(e){h||i.$apply(n(e)?i.incrementMinutes():i.decrementMinutes()),e.preventDefault()}),a.bind("mousewheel wheel",function(e){h||i.$apply(n(e)?i.incrementSeconds():i.decrementSeconds()),e.preventDefault()})},this.setupArrowkeyEvents=function(e,t,a){e.bind("keydown",function(e){h||(38===e.which?(e.preventDefault(),i.incrementHours(),i.$apply()):40===e.which&&(e.preventDefault(),i.decrementHours(),i.$apply()))}),t.bind("keydown",function(e){h||(38===e.which?(e.preventDefault(),i.incrementMinutes(),i.$apply()):40===e.which&&(e.preventDefault(),i.decrementMinutes(),i.$apply()))}),a.bind("keydown",function(e){h||(38===e.which?(e.preventDefault(),i.incrementSeconds(),i.$apply()):40===e.which&&(e.preventDefault(),i.decrementSeconds(),i.$apply()))})},this.setupInputEvents=function(e,t,a){if(i.readonlyInput)return i.updateHours=angular.noop,i.updateMinutes=angular.noop,void(i.updateSeconds=angular.noop);function n(e,t,a){c.$setViewValue(null),c.$setValidity("time",!1),angular.isDefined(e)&&(i.invalidHours=e),angular.isDefined(t)&&(i.invalidMinutes=t),angular.isDefined(a)&&(i.invalidSeconds=a)}i.updateHours=function(){var e=y(),t=b();c.$setDirty(),angular.isDefined(e)&&angular.isDefined(t)?(r.setHours(e),r.setMinutes(t),r<m||g<r?n(!0):$("h")):n(!0)},e.bind("blur",function(e){c.$setTouched(),C()?k():null===i.hours||""===i.hours?n(!0):!i.invalidHours&&i.hours<10&&i.$apply(function(){i.hours=w(i.hours,!d)})}),i.updateMinutes=function(){var e=b(),t=y();c.$setDirty(),angular.isDefined(e)&&angular.isDefined(t)?(r.setHours(t),r.setMinutes(e),r<m||g<r?n(void 0,!0):$("m")):n(void 0,!0)},t.bind("blur",function(e){c.$setTouched(),C()?k():null===i.minutes?n(void 0,!0):!i.invalidMinutes&&i.minutes<10&&i.$apply(function(){i.minutes=w(i.minutes)})}),i.updateSeconds=function(){var e,e=0<=(e=+i.seconds)&&e<60?e:void 0;c.$setDirty(),angular.isDefined(e)?(r.setSeconds(e),$("s")):n(void 0,void 0,!0)},a.bind("blur",function(e){C()?k():!i.invalidSeconds&&i.seconds<10&&i.$apply(function(){i.seconds=w(i.seconds)})})},this.render=function(){var e=c.$viewValue;isNaN(e)?(c.$setValidity("time",!1),a.error('Timepicker directive: "ng-model" value must be a Date object, a number of milliseconds since 01.01.1970 or a string representing an RFC2822 or ISO 8601 date.')):((r=e?e:r)<m||g<r?(c.$setValidity("time",!1),i.invalidHours=!0,i.invalidMinutes=!0):k(),x())},i.showSpinners=angular.isDefined(n.showSpinners)?i.$parent.$eval(n.showSpinners):o.showSpinners,i.incrementHours=function(){i.noIncrementHours()||_(60*p*60)},i.decrementHours=function(){i.noDecrementHours()||_(60*-p*60)},i.incrementMinutes=function(){i.noIncrementMinutes()||_(60*f)},i.decrementMinutes=function(){i.noDecrementMinutes()||_(60*-f)},i.incrementSeconds=function(){i.noIncrementSeconds()||_(v)},i.decrementSeconds=function(){i.noDecrementSeconds()||_(-v)},i.toggleMeridian=function(){var e=b(),t=y();i.noToggleMeridian()||(angular.isDefined(e)&&angular.isDefined(t)?_(720*(r.getHours()<12?60:-60)):i.meridian=i.meridian===u[0]?u[1]:u[0])},i.blur=function(){c.$setTouched()},i.$on("$destroy",function(){for(;l.length;)l.shift()()})}]).directive("uibTimepicker",["uibTimepickerConfig",function(a){return{require:["uibTimepicker","?^ngModel"],restrict:"A",controller:"UibTimepickerController",controllerAs:"timepicker",scope:{},templateUrl:function(e,t){return t.templateUrl||a.templateUrl},link:function(e,t,a,n){var i=n[0],n=n[1];n&&i.init(n,t.find("input"))}}}]),angular.module("ui.bootstrap.typeahead",["ui.bootstrap.debounce","ui.bootstrap.position"]).factory("uibTypeaheadParser",["$parse",function(a){var n=/^\s*([\s\S]+?)(?:\s+as\s+([\s\S]+?))?\s+for\s+(?:([\$\w][\$\w\d]*))\s+in\s+([\s\S]+?)$/;return{parse:function(e){var t=e.match(n);if(!t)throw new Error('Expected typeahead specification in form of "_modelValue_ (as _label_)? for _item_ in _collection_" but got "'+e+'".');return{itemName:t[3],source:a(t[4]),viewMapper:a(t[2]||t[1]),modelMapper:a(t[1])}}}}]).controller("UibTypeaheadController",["$scope","$element","$attrs","$compile","$parse","$q","$timeout","$document","$window","$rootScope","$$debounce","$uibPosition","uibTypeaheadParser",function(l,c,o,e,a,t,r,n,i,s,u,d,p){var m,g,f=[9,13,27,38,40],h=l.$eval(o.typeaheadMinLength);h||0===h||(h=1),l.$watch(o.typeaheadMinLength,function(e){h=e||0===e?e:1});var v=l.$eval(o.typeaheadWaitMs)||0,y=!1!==l.$eval(o.typeaheadEditable);l.$watch(o.typeaheadEditable,function(e){y=!1!==e});var b,w,$=a(o.typeaheadLoading).assign||angular.noop,k=o.typeaheadShouldSelect?a(o.typeaheadShouldSelect):function(e,t){t=t.$event;return 13===t.which||9===t.which},x=a(o.typeaheadOnSelect),_=!!angular.isDefined(o.typeaheadSelectOnBlur)&&l.$eval(o.typeaheadSelectOnBlur),S=a(o.typeaheadNoResults).assign||angular.noop,I=o.typeaheadInputFormatter?a(o.typeaheadInputFormatter):void 0,C=!!o.typeaheadAppendToBody&&l.$eval(o.typeaheadAppendToBody),A=o.typeaheadAppendTo?l.$eval(o.typeaheadAppendTo):null,M=!1!==l.$eval(o.typeaheadFocusFirst),D=!!o.typeaheadSelectOnExact&&l.$eval(o.typeaheadSelectOnExact),T=a(o.typeaheadIsOpen).assign||angular.noop,P=l.$eval(o.typeaheadShowHint)||!1,E=a(o.ngModel),j=a(o.ngModel+"($$$p)"),L=p.parse(o.uibTypeahead),O=l.$new(),p=l.$on("$destroy",function(){O.$destroy()});O.$on("$destroy",p);var U,N,B="typeahead-"+O.$id+"-"+Math.floor(1e4*Math.random());c.attr({"aria-autocomplete":"list","aria-expanded":!1,"aria-owns":B}),P&&((U=angular.element("<div></div>")).css("position","relative"),c.after(U),(N=c.clone()).attr("placeholder",""),N.attr("tabindex","-1"),N.val(""),N.css({position:"absolute",top:"0px",left:"0px","border-color":"transparent","box-shadow":"none",opacity:1,background:"none 0% 0% / auto repeat scroll padding-box border-box rgb(255, 255, 255)",color:"#999"}),c.css({position:"relative","vertical-align":"top","background-color":"transparent"}),N.attr("id")&&N.removeAttr("id"),U.append(N),N.after(c));var R=angular.element("<div uib-typeahead-popup></div>");R.attr({id:B,matches:"matches",active:"activeIdx",select:"select(activeIdx, evt)","move-in-progress":"moveInProgress",query:"query",position:"position","assign-is-open":"assignIsOpen(isOpen)",debounce:"debounceUpdate"}),angular.isDefined(o.typeaheadTemplateUrl)&&R.attr("template-url",o.typeaheadTemplateUrl),angular.isDefined(o.typeaheadPopupTemplateUrl)&&R.attr("popup-template-url",o.typeaheadPopupTemplateUrl);function q(){O.matches=[],O.activeIdx=-1,c.attr("aria-expanded",!1),P&&N.val("")}function V(e){return B+"-option-"+e}O.$watch("activeIdx",function(e){e<0?c.removeAttr("aria-activedescendant"):c.attr("aria-activedescendant",V(e))});function Y(s,o){var r={$viewValue:s};$(l,!0),S(l,!1),t.when(L.source(l,r)).then(function(e){var t,a=s===m.$viewValue;if(a&&b)if(e&&0<e.length){O.activeIdx=M?0:-1,S(l,!1);for(var n,i=O.matches.length=0;i<e.length;i++)r[L.itemName]=e[i],O.matches.push({id:V(i),label:L.viewMapper(O,r),model:e[i]});O.query=s,W(),c.attr("aria-expanded",!0),D&&1===O.matches.length&&(t=s,n=0,!!(O.matches.length>n&&t)&&t.toUpperCase()===O.matches[n].label.toUpperCase())&&(angular.isNumber(O.debounceUpdate)||angular.isObject(O.debounceUpdate)?u(function(){O.select(0,o)},angular.isNumber(O.debounceUpdate)?O.debounceUpdate:O.debounceUpdate.default):O.select(0,o)),P&&(n=O.matches[0].label,angular.isString(s)&&0<s.length&&n.slice(0,s.length).toUpperCase()===s.toUpperCase()?N.val(s+n.slice(s.length)):N.val(""))}else q(),S(l,!0);a&&$(l,!1)},function(){q(),$(l,!1),S(l,!0)})}C&&(angular.element(i).on("resize",H),n.find("body").on("scroll",H));var F,z=u(function(){O.matches.length&&W(),O.moveInProgress=!1},200);function H(){O.moveInProgress||(O.moveInProgress=!0,O.$digest()),z()}function W(){O.position=C?d.offset(c):d.position(c),O.position.top+=c.prop("offsetHeight")}O.moveInProgress=!1,O.query=void 0;function G(){F&&r.cancel(F)}q(),O.assignIsOpen=function(e){T(l,e)},O.select=function(e,t){var a,n,i,s={};w=!0,s[L.itemName]=n=O.matches[e].model,a=L.modelMapper(l,s),i=l,e=a,angular.isFunction(E(l))&&g&&g.$options&&g.$options.getterSetter?j(i,{$$$p:e}):E.assign(i,e),m.$setValidity("editable",!0),m.$setValidity("parse",!0),x(l,{$item:n,$model:a,$label:L.viewMapper(l,s),$event:t}),q(),!1!==O.$eval(o.typeaheadFocusOnSelect)&&r(function(){c[0].focus()},0,!1)},c.on("keydown",function(e){if(0!==O.matches.length&&-1!==f.indexOf(e.which)){var t,a=k(l,{$event:e});if(-1===O.activeIdx&&a||9===e.which&&e.shiftKey)return q(),void O.$digest();switch(e.preventDefault(),e.which){case 27:e.stopPropagation(),q(),l.$digest();break;case 38:O.activeIdx=(0<O.activeIdx?O.activeIdx:O.matches.length)-1,O.$digest(),(t=R[0].querySelectorAll(".uib-typeahead-match")[O.activeIdx]).parentNode.scrollTop=t.offsetTop;break;case 40:O.activeIdx=(O.activeIdx+1)%O.matches.length,O.$digest(),(t=R[0].querySelectorAll(".uib-typeahead-match")[O.activeIdx]).parentNode.scrollTop=t.offsetTop;break;default:a&&O.$apply(function(){angular.isNumber(O.debounceUpdate)||angular.isObject(O.debounceUpdate)?u(function(){O.select(O.activeIdx,e)},angular.isNumber(O.debounceUpdate)?O.debounceUpdate:O.debounceUpdate.default):O.select(O.activeIdx,e)})}}}),c.bind("focus",function(e){b=!0,0!==h||m.$viewValue||r(function(){Y(m.$viewValue,e)},0)}),c.bind("blur",function(e){_&&O.matches.length&&-1!==O.activeIdx&&!w&&(w=!0,O.$apply(function(){angular.isObject(O.debounceUpdate)&&angular.isNumber(O.debounceUpdate.blur)?u(function(){O.select(O.activeIdx,e)},O.debounceUpdate.blur):O.select(O.activeIdx,e)})),!y&&m.$error.editable&&(m.$setViewValue(),O.$apply(function(){m.$setValidity("editable",!0),m.$setValidity("parse",!0)}),c.val("")),w=b=!1});function K(e){c[0]!==e.target&&3!==e.which&&0!==O.matches.length&&(q(),s.$$phase||l.$digest())}n.on("click",K),l.$on("$destroy",function(){n.off("click",K),(C||A)&&Q.remove(),C&&(angular.element(i).off("resize",H),n.find("body").off("scroll",H)),R.remove(),P&&U.remove()});var Q=e(R)(O);C?n.find("body").append(Q):A?angular.element(A).eq(0).append(Q):c.after(Q),this.init=function(e,t){m=e,g=t,O.debounceUpdate=m.$options&&a(m.$options.debounce)(l),m.$parsers.unshift(function(e){var t;return b=!0,0===h||e&&e.length>=h?0<v?(G(),t=e,F=r(function(){Y(t)},v)):Y(e):($(l,!1),G(),q()),y?e:e?void m.$setValidity("editable",!1):(m.$setValidity("editable",!0),null)}),m.$formatters.push(function(e){var t,a={};return y||m.$setValidity("editable",!0),I?(a.$model=e,I(l,a)):(a[L.itemName]=e,t=L.viewMapper(l,a),a[L.itemName]=void 0,t!==L.viewMapper(l,a)?t:e)})}}]).directive("uibTypeahead",function(){return{controller:"UibTypeaheadController",require:["ngModel","^?ngModelOptions","uibTypeahead"],link:function(e,t,a,n){n[2].init(n[0],n[1])}}}).directive("uibTypeaheadPopup",["$$debounce",function(i){return{scope:{matches:"=",query:"=",active:"=",position:"&",moveInProgress:"=",select:"&",assignIsOpen:"&",debounce:"&"},replace:!0,templateUrl:function(e,t){return t.popupTemplateUrl||"uib/template/typeahead/typeahead-popup.html"},link:function(n,e,t){n.templateUrl=t.templateUrl,n.isOpen=function(){var e=0<n.matches.length;return n.assignIsOpen({isOpen:e}),e},n.isActive=function(e){return n.active===e},n.selectActive=function(e){n.active=e},n.selectMatch=function(e,t){var a=n.debounce();angular.isNumber(a)||angular.isObject(a)?i(function(){n.select({activeIdx:e,evt:t})},angular.isNumber(a)?a:a.default):n.select({activeIdx:e,evt:t})}}}}]).directive("uibTypeaheadMatch",["$templateRequest","$compile","$parse",function(n,i,s){return{scope:{index:"=",match:"=",query:"="},link:function(t,a,e){e=s(e.templateUrl)(t.$parent)||"uib/template/typeahead/typeahead-match.html";n(e).then(function(e){e=angular.element(e.trim());a.replaceWith(e),i(e)(t)})}}}]).filter("uibTypeaheadHighlight",["$sce","$injector","$log",function(a,e,n){var i;return i=e.has("$sanitize"),function(e,t){return!i&&/<.*>/g.test(e)&&n.warn("Unsafe use of typeahead please use ngSanitize"),e=t?(""+e).replace(new RegExp(t.replace(/([.?*+^$[\]\\(){}|-])/g,"\\$1"),"gi"),"<strong>$&</strong>"):e,e=!i?a.trustAsHtml(e):e}}]),angular.module("uib/template/accordion/accordion-group.html",[]).run(["$templateCache",function(e){e.put("uib/template/accordion/accordion-group.html",'<div role="tab" id="{{::headingId}}" aria-selected="{{isOpen}}" class="panel-heading" ng-keypress="toggleOpen($event)">\n <h4 class="panel-title">\n <a role="button" data-toggle="collapse" href aria-expanded="{{isOpen}}" aria-controls="{{::panelId}}" tabindex="0" class="accordion-toggle" ng-click="toggleOpen()" uib-accordion-transclude="heading" ng-disabled="isDisabled" uib-tabindex-toggle><span uib-accordion-header ng-class="{\'text-muted\': isDisabled}">{{heading}}</span></a>\n </h4>\n</div>\n<div id="{{::panelId}}" aria-labelledby="{{::headingId}}" aria-hidden="{{!isOpen}}" role="tabpanel" class="panel-collapse collapse" uib-collapse="!isOpen">\n <div class="panel-body" ng-transclude></div>\n</div>\n')}]),angular.module("uib/template/accordion/accordion.html",[]).run(["$templateCache",function(e){e.put("uib/template/accordion/accordion.html",'<div role="tablist" class="panel-group" ng-transclude></div>')}]),angular.module("uib/template/alert/alert.html",[]).run(["$templateCache",function(e){e.put("uib/template/alert/alert.html",'<button ng-show="closeable" type="button" class="close" ng-click="close({$event: $event})">\n <span aria-hidden="true">×</span>\n <span class="sr-only">Close</span>\n</button>\n<div ng-transclude></div>\n')}]),angular.module("uib/template/carousel/carousel.html",[]).run(["$templateCache",function(e){e.put("uib/template/carousel/carousel.html",'<div class="carousel-inner" ng-transclude></div>\n<a role="button" href class="left carousel-control" ng-click="prev()" ng-class="{ disabled: isPrevDisabled() }" ng-show="slides.length > 1">\n <span aria-hidden="true" class="glyphicon glyphicon-chevron-left"></span>\n <span class="sr-only">previous</span>\n</a>\n<a role="button" href class="right carousel-control" ng-click="next()" ng-class="{ disabled: isNextDisabled() }" ng-show="slides.length > 1">\n <span aria-hidden="true" class="glyphicon glyphicon-chevron-right"></span>\n <span class="sr-only">next</span>\n</a>\n<ol class="carousel-indicators" ng-show="slides.length > 1">\n <li ng-repeat="slide in slides | orderBy:indexOfSlide track by $index" ng-class="{ active: isActive(slide) }" ng-click="select(slide)">\n <span class="sr-only">slide {{ $index + 1 }} of {{ slides.length }}<span ng-if="isActive(slide)">, currently active</span></span>\n </li>\n</ol>\n')}]),angular.module("uib/template/carousel/slide.html",[]).run(["$templateCache",function(e){e.put("uib/template/carousel/slide.html",'<div class="text-center" ng-transclude></div>\n')}]),angular.module("uib/template/datepicker/datepicker.html",[]).run(["$templateCache",function(e){e.put("uib/template/datepicker/datepicker.html",'<div ng-switch="datepickerMode">\n <div uib-daypicker ng-switch-when="day" tabindex="0" class="uib-daypicker"></div>\n <div uib-monthpicker ng-switch-when="month" tabindex="0" class="uib-monthpicker"></div>\n <div uib-yearpicker ng-switch-when="year" tabindex="0" class="uib-yearpicker"></div>\n</div>\n')}]),angular.module("uib/template/datepicker/day.html",[]).run(["$templateCache",function(e){e.put("uib/template/datepicker/day.html",'<table role="grid" aria-labelledby="{{::uniqueId}}-title" aria-activedescendant="{{activeDateId}}">\n <thead>\n <tr>\n <th><button type="button" class="btn btn-default btn-sm pull-left uib-left" ng-click="move(-1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-left"></i></button></th>\n <th colspan="{{::5 + showWeeks}}"><button id="{{::uniqueId}}-title" role="heading" aria-live="assertive" aria-atomic="true" type="button" class="btn btn-default btn-sm uib-title" ng-click="toggleMode()" ng-disabled="datepickerMode === maxMode" tabindex="-1"><strong>{{title}}</strong></button></th>\n <th><button type="button" class="btn btn-default btn-sm pull-right uib-right" ng-click="move(1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-right"></i></button></th>\n </tr>\n <tr>\n <th ng-if="showWeeks" class="text-center"></th>\n <th ng-repeat="label in ::labels track by $index" class="text-center"><small aria-label="{{::label.full}}">{{::label.abbr}}</small></th>\n </tr>\n </thead>\n <tbody>\n <tr class="uib-weeks" ng-repeat="row in rows track by $index">\n <td ng-if="showWeeks" class="text-center h6"><em>{{ weekNumbers[$index] }}</em></td>\n <td ng-repeat="dt in row" class="uib-day text-center" role="gridcell"\n id="{{::dt.uid}}"\n ng-class="::dt.customClass">\n <button type="button" class="btn btn-default btn-sm"\n uib-is-class="\n \'btn-info\' for selectedDt,\n \'active\' for activeDt\n on dt"\n ng-click="select(dt.date)"\n ng-disabled="::dt.disabled"\n tabindex="-1"><span ng-class="::{\'text-muted\': dt.secondary, \'text-info\': dt.current}">{{::dt.label}}</span></button>\n </td>\n </tr>\n </tbody>\n</table>\n')}]),angular.module("uib/template/datepicker/month.html",[]).run(["$templateCache",function(e){e.put("uib/template/datepicker/month.html",'<table role="grid" aria-labelledby="{{::uniqueId}}-title" aria-activedescendant="{{activeDateId}}">\n <thead>\n <tr>\n <th><button type="button" class="btn btn-default btn-sm pull-left uib-left" ng-click="move(-1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-left"></i></button></th>\n <th colspan="{{::yearHeaderColspan}}"><button id="{{::uniqueId}}-title" role="heading" aria-live="assertive" aria-atomic="true" type="button" class="btn btn-default btn-sm uib-title" ng-click="toggleMode()" ng-disabled="datepickerMode === maxMode" tabindex="-1"><strong>{{title}}</strong></button></th>\n <th><button type="button" class="btn btn-default btn-sm pull-right uib-right" ng-click="move(1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-right"></i></button></th>\n </tr>\n </thead>\n <tbody>\n <tr class="uib-months" ng-repeat="row in rows track by $index">\n <td ng-repeat="dt in row" class="uib-month text-center" role="gridcell"\n id="{{::dt.uid}}"\n ng-class="::dt.customClass">\n <button type="button" class="btn btn-default"\n uib-is-class="\n \'btn-info\' for selectedDt,\n \'active\' for activeDt\n on dt"\n ng-click="select(dt.date)"\n ng-disabled="::dt.disabled"\n tabindex="-1"><span ng-class="::{\'text-info\': dt.current}">{{::dt.label}}</span></button>\n </td>\n </tr>\n </tbody>\n</table>\n')}]),angular.module("uib/template/datepicker/year.html",[]).run(["$templateCache",function(e){e.put("uib/template/datepicker/year.html",'<table role="grid" aria-labelledby="{{::uniqueId}}-title" aria-activedescendant="{{activeDateId}}">\n <thead>\n <tr>\n <th><button type="button" class="btn btn-default btn-sm pull-left uib-left" ng-click="move(-1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-left"></i></button></th>\n <th colspan="{{::columns - 2}}"><button id="{{::uniqueId}}-title" role="heading" aria-live="assertive" aria-atomic="true" type="button" class="btn btn-default btn-sm uib-title" ng-click="toggleMode()" ng-disabled="datepickerMode === maxMode" tabindex="-1"><strong>{{title}}</strong></button></th>\n <th><button type="button" class="btn btn-default btn-sm pull-right uib-right" ng-click="move(1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-right"></i></button></th>\n </tr>\n </thead>\n <tbody>\n <tr class="uib-years" ng-repeat="row in rows track by $index">\n <td ng-repeat="dt in row" class="uib-year text-center" role="gridcell"\n id="{{::dt.uid}}"\n ng-class="::dt.customClass">\n <button type="button" class="btn btn-default"\n uib-is-class="\n \'btn-info\' for selectedDt,\n \'active\' for activeDt\n on dt"\n ng-click="select(dt.date)"\n ng-disabled="::dt.disabled"\n tabindex="-1"><span ng-class="::{\'text-info\': dt.current}">{{::dt.label}}</span></button>\n </td>\n </tr>\n </tbody>\n</table>\n')}]),angular.module("uib/template/datepickerPopup/popup.html",[]).run(["$templateCache",function(e){e.put("uib/template/datepickerPopup/popup.html",'<ul class="uib-datepicker-popup dropdown-menu uib-position-measure" dropdown-nested ng-if="isOpen" ng-keydown="keydown($event)" ng-click="$event.stopPropagation()">\n <li ng-transclude></li>\n <li ng-if="showButtonBar" class="uib-button-bar">\n <span class="btn-group pull-left">\n <button type="button" class="btn btn-sm btn-info uib-datepicker-current" ng-click="select(\'today\', $event)" ng-disabled="isDisabled(\'today\')">{{ getText(\'current\') }}</button>\n <button type="button" class="btn btn-sm btn-danger uib-clear" ng-click="select(null, $event)">{{ getText(\'clear\') }}</button>\n </span>\n <button type="button" class="btn btn-sm btn-success pull-right uib-close" ng-click="close($event)">{{ getText(\'close\') }}</button>\n </li>\n</ul>\n')}]),angular.module("uib/template/modal/window.html",[]).run(["$templateCache",function(e){e.put("uib/template/modal/window.html","<div class=\"modal-dialog {{size ? 'modal-' + size : ''}}\"><div class=\"modal-content\" uib-modal-transclude></div></div>\n")}]),angular.module("uib/template/pager/pager.html",[]).run(["$templateCache",function(e){e.put("uib/template/pager/pager.html",'<li ng-class="{disabled: noPrevious()||ngDisabled, previous: align}"><a href ng-click="selectPage(page - 1, $event)" ng-disabled="noPrevious()||ngDisabled" uib-tabindex-toggle>{{::getText(\'previous\')}}</a></li>\n<li ng-class="{disabled: noNext()||ngDisabled, next: align}"><a href ng-click="selectPage(page + 1, $event)" ng-disabled="noNext()||ngDisabled" uib-tabindex-toggle>{{::getText(\'next\')}}</a></li>\n')}]),angular.module("uib/template/pagination/pagination.html",[]).run(["$templateCache",function(e){e.put("uib/template/pagination/pagination.html",'<li ng-if="::boundaryLinks" ng-class="{disabled: noPrevious()||ngDisabled}" class="pagination-first"><a href ng-click="selectPage(1, $event)" ng-disabled="noPrevious()||ngDisabled" uib-tabindex-toggle>{{::getText(\'first\')}}</a></li>\n<li ng-if="::directionLinks" ng-class="{disabled: noPrevious()||ngDisabled}" class="pagination-prev"><a href ng-click="selectPage(page - 1, $event)" ng-disabled="noPrevious()||ngDisabled" uib-tabindex-toggle>{{::getText(\'previous\')}}</a></li>\n<li ng-repeat="page in pages track by $index" ng-class="{active: page.active,disabled: ngDisabled&&!page.active}" class="pagination-page"><a href ng-click="selectPage(page.number, $event)" ng-disabled="ngDisabled&&!page.active" uib-tabindex-toggle>{{page.text}}</a></li>\n<li ng-if="::directionLinks" ng-class="{disabled: noNext()||ngDisabled}" class="pagination-next"><a href ng-click="selectPage(page + 1, $event)" ng-disabled="noNext()||ngDisabled" uib-tabindex-toggle>{{::getText(\'next\')}}</a></li>\n<li ng-if="::boundaryLinks" ng-class="{disabled: noNext()||ngDisabled}" class="pagination-last"><a href ng-click="selectPage(totalPages, $event)" ng-disabled="noNext()||ngDisabled" uib-tabindex-toggle>{{::getText(\'last\')}}</a></li>\n')}]),angular.module("uib/template/tooltip/tooltip-html-popup.html",[]).run(["$templateCache",function(e){e.put("uib/template/tooltip/tooltip-html-popup.html",'<div class="tooltip-arrow"></div>\n<div class="tooltip-inner" ng-bind-html="contentExp()"></div>\n')}]),angular.module("uib/template/tooltip/tooltip-popup.html",[]).run(["$templateCache",function(e){e.put("uib/template/tooltip/tooltip-popup.html",'<div class="tooltip-arrow"></div>\n<div class="tooltip-inner" ng-bind="content"></div>\n')}]),angular.module("uib/template/tooltip/tooltip-template-popup.html",[]).run(["$templateCache",function(e){e.put("uib/template/tooltip/tooltip-template-popup.html",'<div class="tooltip-arrow"></div>\n<div class="tooltip-inner"\n uib-tooltip-template-transclude="contentExp()"\n tooltip-template-transclude-scope="originScope()"></div>\n')}]),angular.module("uib/template/popover/popover-html.html",[]).run(["$templateCache",function(e){e.put("uib/template/popover/popover-html.html",'<div class="arrow"></div>\n\n<div class="popover-inner">\n <h3 class="popover-title" ng-bind="uibTitle" ng-if="uibTitle"></h3>\n <div class="popover-content" ng-bind-html="contentExp()"></div>\n</div>\n')}]),angular.module("uib/template/popover/popover-template.html",[]).run(["$templateCache",function(e){e.put("uib/template/popover/popover-template.html",'<div class="arrow"></div>\n\n<div class="popover-inner">\n <h3 class="popover-title" ng-bind="uibTitle" ng-if="uibTitle"></h3>\n <div class="popover-content"\n uib-tooltip-template-transclude="contentExp()"\n tooltip-template-transclude-scope="originScope()"></div>\n</div>\n')}]),angular.module("uib/template/popover/popover.html",[]).run(["$templateCache",function(e){e.put("uib/template/popover/popover.html",'<div class="arrow"></div>\n\n<div class="popover-inner">\n <h3 class="popover-title" ng-bind="uibTitle" ng-if="uibTitle"></h3>\n <div class="popover-content" ng-bind="content"></div>\n</div>\n')}]),angular.module("uib/template/progressbar/bar.html",[]).run(["$templateCache",function(e){e.put("uib/template/progressbar/bar.html",'<div class="progress-bar" ng-class="type && \'progress-bar-\' + type" role="progressbar" aria-valuenow="{{value}}" aria-valuemin="0" aria-valuemax="{{max}}" ng-style="{width: (percent < 100 ? percent : 100) + \'%\'}" aria-valuetext="{{percent | number:0}}%" aria-labelledby="{{::title}}" ng-transclude></div>\n')}]),angular.module("uib/template/progressbar/progress.html",[]).run(["$templateCache",function(e){e.put("uib/template/progressbar/progress.html",'<div class="progress" ng-transclude aria-labelledby="{{::title}}"></div>')}]),angular.module("uib/template/progressbar/progressbar.html",[]).run(["$templateCache",function(e){e.put("uib/template/progressbar/progressbar.html",'<div class="progress">\n <div class="progress-bar" ng-class="type && \'progress-bar-\' + type" role="progressbar" aria-valuenow="{{value}}" aria-valuemin="0" aria-valuemax="{{max}}" ng-style="{width: (percent < 100 ? percent : 100) + \'%\'}" aria-valuetext="{{percent | number:0}}%" aria-labelledby="{{::title}}" ng-transclude></div>\n</div>\n')}]),angular.module("uib/template/rating/rating.html",[]).run(["$templateCache",function(e){e.put("uib/template/rating/rating.html",'<span ng-mouseleave="reset()" ng-keydown="onKeydown($event)" tabindex="0" role="slider" aria-valuemin="0" aria-valuemax="{{range.length}}" aria-valuenow="{{value}}" aria-valuetext="{{title}}">\n <span ng-repeat-start="r in range track by $index" class="sr-only">({{ $index < value ? \'*\' : \' \' }})</span>\n <i ng-repeat-end ng-mouseenter="enter($index + 1)" ng-click="rate($index + 1)" class="glyphicon" ng-class="$index < value && (r.stateOn || \'glyphicon-star\') || (r.stateOff || \'glyphicon-star-empty\')" ng-attr-title="{{r.title}}"></i>\n</span>\n')}]),angular.module("uib/template/tabs/tab.html",[]).run(["$templateCache",function(e){e.put("uib/template/tabs/tab.html",'<li ng-class="[{active: active, disabled: disabled}, classes]" class="uib-tab nav-item">\n <a href ng-click="select($event)" class="nav-link" uib-tab-heading-transclude>{{heading}}</a>\n</li>\n')}]),angular.module("uib/template/tabs/tabset.html",[]).run(["$templateCache",function(e){e.put("uib/template/tabs/tabset.html",'<div>\n <ul class="nav nav-{{tabset.type || \'tabs\'}}" ng-class="{\'nav-stacked\': vertical, \'nav-justified\': justified}" ng-transclude></ul>\n <div class="tab-content">\n <div class="tab-pane"\n ng-repeat="tab in tabset.tabs"\n ng-class="{active: tabset.active === tab.index}"\n uib-tab-content-transclude="tab">\n </div>\n </div>\n</div>\n')}]),angular.module("uib/template/timepicker/timepicker.html",[]).run(["$templateCache",function(e){e.put("uib/template/timepicker/timepicker.html",'<table class="uib-timepicker">\n <tbody>\n <tr class="text-center" ng-show="::showSpinners">\n <td class="uib-increment hours"><a ng-click="incrementHours()" ng-class="{disabled: noIncrementHours()}" class="btn btn-link" ng-disabled="noIncrementHours()" tabindex="-1"><span class="glyphicon glyphicon-chevron-up"></span></a></td>\n <td> </td>\n <td class="uib-increment minutes"><a ng-click="incrementMinutes()" ng-class="{disabled: noIncrementMinutes()}" class="btn btn-link" ng-disabled="noIncrementMinutes()" tabindex="-1"><span class="glyphicon glyphicon-chevron-up"></span></a></td>\n <td ng-show="showSeconds"> </td>\n <td ng-show="showSeconds" class="uib-increment seconds"><a ng-click="incrementSeconds()" ng-class="{disabled: noIncrementSeconds()}" class="btn btn-link" ng-disabled="noIncrementSeconds()" tabindex="-1"><span class="glyphicon glyphicon-chevron-up"></span></a></td>\n <td ng-show="showMeridian"></td>\n </tr>\n <tr>\n <td class="form-group uib-time hours" ng-class="{\'has-error\': invalidHours}">\n <input type="text" placeholder="HH" ng-model="hours" ng-change="updateHours()" class="form-control text-center" ng-readonly="::readonlyInput" maxlength="2" tabindex="{{::tabindex}}" ng-disabled="noIncrementHours()" ng-blur="blur()">\n </td>\n <td class="uib-separator">:</td>\n <td class="form-group uib-time minutes" ng-class="{\'has-error\': invalidMinutes}">\n <input type="text" placeholder="MM" ng-model="minutes" ng-change="updateMinutes()" class="form-control text-center" ng-readonly="::readonlyInput" maxlength="2" tabindex="{{::tabindex}}" ng-disabled="noIncrementMinutes()" ng-blur="blur()">\n </td>\n <td ng-show="showSeconds" class="uib-separator">:</td>\n <td class="form-group uib-time seconds" ng-class="{\'has-error\': invalidSeconds}" ng-show="showSeconds">\n <input type="text" placeholder="SS" ng-model="seconds" ng-change="updateSeconds()" class="form-control text-center" ng-readonly="readonlyInput" maxlength="2" tabindex="{{::tabindex}}" ng-disabled="noIncrementSeconds()" ng-blur="blur()">\n </td>\n <td ng-show="showMeridian" class="uib-time am-pm"><button type="button" ng-class="{disabled: noToggleMeridian()}" class="btn btn-default text-center" ng-click="toggleMeridian()" ng-disabled="noToggleMeridian()" tabindex="{{::tabindex}}">{{meridian}}</button></td>\n </tr>\n <tr class="text-center" ng-show="::showSpinners">\n <td class="uib-decrement hours"><a ng-click="decrementHours()" ng-class="{disabled: noDecrementHours()}" class="btn btn-link" ng-disabled="noDecrementHours()" tabindex="-1"><span class="glyphicon glyphicon-chevron-down"></span></a></td>\n <td> </td>\n <td class="uib-decrement minutes"><a ng-click="decrementMinutes()" ng-class="{disabled: noDecrementMinutes()}" class="btn btn-link" ng-disabled="noDecrementMinutes()" tabindex="-1"><span class="glyphicon glyphicon-chevron-down"></span></a></td>\n <td ng-show="showSeconds"> </td>\n <td ng-show="showSeconds" class="uib-decrement seconds"><a ng-click="decrementSeconds()" ng-class="{disabled: noDecrementSeconds()}" class="btn btn-link" ng-disabled="noDecrementSeconds()" tabindex="-1"><span class="glyphicon glyphicon-chevron-down"></span></a></td>\n <td ng-show="showMeridian"></td>\n </tr>\n </tbody>\n</table>\n')}]),angular.module("uib/template/typeahead/typeahead-match.html",[]).run(["$templateCache",function(e){e.put("uib/template/typeahead/typeahead-match.html",'<a href\n tabindex="-1"\n ng-bind-html="match.label | uibTypeaheadHighlight:query"\n ng-attr-title="{{match.label}}"></a>\n')}]),angular.module("uib/template/typeahead/typeahead-popup.html",[]).run(["$templateCache",function(e){e.put("uib/template/typeahead/typeahead-popup.html",'<ul class="dropdown-menu" ng-show="isOpen() && !moveInProgress" ng-style="{top: position().top+\'px\', left: position().left+\'px\'}" role="listbox" aria-hidden="{{!isOpen()}}">\n <li class="uib-typeahead-match" ng-repeat="match in matches track by $index" ng-class="{active: isActive($index) }" ng-mouseenter="selectActive($index)" ng-click="selectMatch($index, $event)" role="option" id="{{::match.id}}">\n <div uib-typeahead-match index="$index" match="match" query="query" template-url="templateUrl"></div>\n </li>\n</ul>\n')}]),angular.module("ui.bootstrap.carousel").run(function(){angular.$$csp().noInlineStyle||angular.$$uibCarouselCss||angular.element(document).find("head").prepend('<style type="text/css">.ng-animate.item:not(.left):not(.right){-webkit-transition:0s ease-in-out left;transition:0s ease-in-out left}</style>'),angular.$$uibCarouselCss=!0}),angular.module("ui.bootstrap.datepicker").run(function(){angular.$$csp().noInlineStyle||angular.$$uibDatepickerCss||angular.element(document).find("head").prepend('<style type="text/css">.uib-datepicker .uib-title{width:100%;}.uib-day button,.uib-month button,.uib-year button{min-width:100%;}.uib-left,.uib-right{width:100%}</style>'),angular.$$uibDatepickerCss=!0}),angular.module("ui.bootstrap.position").run(function(){angular.$$csp().noInlineStyle||angular.$$uibPositionCss||angular.element(document).find("head").prepend('<style type="text/css">.uib-position-measure{display:block !important;visibility:hidden !important;position:absolute !important;top:-9999px !important;left:-9999px !important;}.uib-position-scrollbar-measure{position:absolute !important;top:-9999px !important;width:50px !important;height:50px !important;overflow:scroll !important;}.uib-position-body-scrollbar-measure{overflow:scroll !important;}</style>'),angular.$$uibPositionCss=!0}),angular.module("ui.bootstrap.datepickerPopup").run(function(){angular.$$csp().noInlineStyle||angular.$$uibDatepickerpopupCss||angular.element(document).find("head").prepend('<style type="text/css">.uib-datepicker-popup.dropdown-menu{display:block;float:none;margin:0;}.uib-button-bar{padding:10px 9px 2px;}</style>'),angular.$$uibDatepickerpopupCss=!0}),angular.module("ui.bootstrap.tooltip").run(function(){angular.$$csp().noInlineStyle||angular.$$uibTooltipCss||angular.element(document).find("head").prepend('<style type="text/css">[uib-tooltip-popup].tooltip.top-left > .tooltip-arrow,[uib-tooltip-popup].tooltip.top-right > .tooltip-arrow,[uib-tooltip-popup].tooltip.bottom-left > .tooltip-arrow,[uib-tooltip-popup].tooltip.bottom-right > .tooltip-arrow,[uib-tooltip-popup].tooltip.left-top > .tooltip-arrow,[uib-tooltip-popup].tooltip.left-bottom > .tooltip-arrow,[uib-tooltip-popup].tooltip.right-top > .tooltip-arrow,[uib-tooltip-popup].tooltip.right-bottom > .tooltip-arrow,[uib-tooltip-html-popup].tooltip.top-left > .tooltip-arrow,[uib-tooltip-html-popup].tooltip.top-right > .tooltip-arrow,[uib-tooltip-html-popup].tooltip.bottom-left > .tooltip-arrow,[uib-tooltip-html-popup].tooltip.bottom-right > .tooltip-arrow,[uib-tooltip-html-popup].tooltip.left-top > .tooltip-arrow,[uib-tooltip-html-popup].tooltip.left-bottom > .tooltip-arrow,[uib-tooltip-html-popup].tooltip.right-top > .tooltip-arrow,[uib-tooltip-html-popup].tooltip.right-bottom > .tooltip-arrow,[uib-tooltip-template-popup].tooltip.top-left > .tooltip-arrow,[uib-tooltip-template-popup].tooltip.top-right > .tooltip-arrow,[uib-tooltip-template-popup].tooltip.bottom-left > .tooltip-arrow,[uib-tooltip-template-popup].tooltip.bottom-right > .tooltip-arrow,[uib-tooltip-template-popup].tooltip.left-top > .tooltip-arrow,[uib-tooltip-template-popup].tooltip.left-bottom > .tooltip-arrow,[uib-tooltip-template-popup].tooltip.right-top > .tooltip-arrow,[uib-tooltip-template-popup].tooltip.right-bottom > .tooltip-arrow,[uib-popover-popup].popover.top-left > .arrow,[uib-popover-popup].popover.top-right > .arrow,[uib-popover-popup].popover.bottom-left > .arrow,[uib-popover-popup].popover.bottom-right > .arrow,[uib-popover-popup].popover.left-top > .arrow,[uib-popover-popup].popover.left-bottom > .arrow,[uib-popover-popup].popover.right-top > .arrow,[uib-popover-popup].popover.right-bottom > .arrow,[uib-popover-html-popup].popover.top-left > .arrow,[uib-popover-html-popup].popover.top-right > .arrow,[uib-popover-html-popup].popover.bottom-left > .arrow,[uib-popover-html-popup].popover.bottom-right > .arrow,[uib-popover-html-popup].popover.left-top > .arrow,[uib-popover-html-popup].popover.left-bottom > .arrow,[uib-popover-html-popup].popover.right-top > .arrow,[uib-popover-html-popup].popover.right-bottom > .arrow,[uib-popover-template-popup].popover.top-left > .arrow,[uib-popover-template-popup].popover.top-right > .arrow,[uib-popover-template-popup].popover.bottom-left > .arrow,[uib-popover-template-popup].popover.bottom-right > .arrow,[uib-popover-template-popup].popover.left-top > .arrow,[uib-popover-template-popup].popover.left-bottom > .arrow,[uib-popover-template-popup].popover.right-top > .arrow,[uib-popover-template-popup].popover.right-bottom > .arrow{top:auto;bottom:auto;left:auto;right:auto;margin:0;}[uib-popover-popup].popover,[uib-popover-html-popup].popover,[uib-popover-template-popup].popover{display:block !important;}</style>'),angular.$$uibTooltipCss=!0}),angular.module("ui.bootstrap.timepicker").run(function(){angular.$$csp().noInlineStyle||angular.$$uibTimepickerCss||angular.element(document).find("head").prepend('<style type="text/css">.uib-time input{width:50px;}</style>'),angular.$$uibTimepickerCss=!0}),angular.module("ui.bootstrap.typeahead").run(function(){angular.$$csp().noInlineStyle||angular.$$uibTypeaheadCss||angular.element(document).find("head").prepend('<style type="text/css">[uib-typeahead-popup].dropdown-menu{display:block;}</style>'),angular.$$uibTypeaheadCss=!0}),function(e,t){"function"==typeof define&&define.amd?define(["angular"],t):"object"==typeof module&&module.exports?module.exports=t(require("angular")):e.angularClipboard=t(e.angular)}(this,function(i){return i.module("angular-clipboard",[]).factory("clipboard",["$document","$window",function(n,i){return{copyText:function(e,t){var a,e=(a=e,(e=n[0].createElement("textarea")).style.position="absolute",e.textContent=a,e.style.left="-10000px",e.style.top=(i.pageYOffset||n[0].documentElement.scrollTop)+"px",e);n[0].body.appendChild(e),function(e){try{n[0].body.style.webkitUserSelect="initial";var t=n[0].getSelection();if(t.removeAllRanges(),e.select(),!n[0].execCommand("copy"))throw"failure copy";t.removeAllRanges()}finally{n[0].body.style.webkitUserSelect=""}}(e),n[0].body.removeChild(e)},supported:"queryCommandSupported"in n[0]&&n[0].queryCommandSupported("copy")}}]).directive("clipboard",["clipboard",function(n){return{restrict:"A",scope:{onCopied:"&",onError:"&",text:"=",supported:"=?"},link:function(t,a){t.supported=n.supported,a.on("click",function(e){try{n.copyText(t.text,a[0]),i.isFunction(t.onCopied)&&t.$evalAsync(t.onCopied())}catch(e){i.isFunction(t.onError)&&t.$evalAsync(t.onError({err:e}))}})}}}])}),function(){"use strict";angular.module("cfp.hotkeys",[]).provider("hotkeys",["$injector",function(e){this.includeCheatSheet=!0,this.useNgRoute=e.has("ngViewDirective"),this.templateTitle="Keyboard Shortcuts:",this.templateHeader=null,this.templateFooter=null,this.template='<div class="cfp-hotkeys-container fade" ng-class="{in: helpVisible}" style="display: none;"><div class="cfp-hotkeys"><h4 class="cfp-hotkeys-title" ng-if="!header">{{ title }}</h4><div ng-bind-html="header" ng-if="header"></div><table><tbody><tr ng-repeat="hotkey in hotkeys | filter:{ description: \'!$$undefined$$\' }"><td class="cfp-hotkeys-keys"><span ng-repeat="key in hotkey.format() track by $index" class="cfp-hotkeys-key">{{ key }}</span></td><td class="cfp-hotkeys-text">{{ hotkey.description }}</td></tr></tbody></table><div ng-bind-html="footer" ng-if="footer"></div><div class="cfp-hotkeys-close" ng-click="toggleCheatSheet()">×</div></div></div>',this.cheatSheetHotkey="?",this.cheatSheetDescription="Show / hide this help menu",this.$get=["$rootElement","$rootScope","$compile","$window","$document",function(e,s,t,n,a){var i=!0;function u(e,t,a,n,i,s){this.combo=e instanceof Array?e:[e],this.description=t,this.callback=a,this.action=n,this.allowIn=i,this.persistent=s,this._formated=null}Mousetrap.prototype.stopCallback=function(e,t){return!i||!(-1<(" "+t.className+" ").indexOf(" mousetrap "))&&(t.contentEditable&&"true"==t.contentEditable)},u.prototype.format=function(){if(null===this._formated){for(var e=this.combo[0].split(/[\s]/),t=0;t<e.length;t++)e[t]=function(e){var t={command:"⌘",shift:"⇧",left:"â†",right:"→",up:"↑",down:"↓",return:"âŽ",backspace:"⌫"};e=e.split("+");for(var a=0;a<e.length;a++)"mod"===e[a]&&(n.navigator&&0<=n.navigator.platform.indexOf("Mac")?e[a]="command":e[a]="ctrl"),e[a]=t[e[a]]||e[a];return e.join(" + ")}(e[t]);this._formated=e}return this._formated};var d=s.$new();d.hotkeys=[],d.helpVisible=!1,d.title=this.templateTitle,d.header=this.templateHeader,d.footer=this.templateFooter,d.toggleCheatSheet=p;var o,r={};function l(){for(var e=d.hotkeys.length;e--;){var t=d.hotkeys[e];t&&!t.persistent&&g(t)}}this.useNgRoute&&s.$on("$routeChangeSuccess",function(e,a){l(),a&&a.hotkeys&&angular.forEach(a.hotkeys,function(e){var t=e[2];("string"==typeof t||t instanceof String)&&(e[2]=[t,a]),e[5]=!1,m.apply(this,e)})}),this.includeCheatSheet&&(o=a[0],a=e[0],e=angular.element(this.template),m(this.cheatSheetHotkey,this.cheatSheetDescription,p),a!==o&&a!==o.documentElement||(a=o.body),angular.element(a).append(t(e)(d)));var c=!1;function p(){d.helpVisible=!d.helpVisible,d.helpVisible?(c=f("esc"),g("esc"),m("esc",c.description,p,null,["INPUT","SELECT","TEXTAREA"])):(g("esc"),!1!==c&&m(c))}function m(e,t,a,n,i,s){var o=["INPUT","SELECT","TEXTAREA"];if("[object Object]"===Object.prototype.toString.call(e)&&(t=e.description,a=e.callback,n=e.action,s=e.persistent,i=e.allowIn,e=e.combo),g(e),t instanceof Function?(n=a,a=t,t="$$undefined$$"):angular.isUndefined(t)&&(t="$$undefined$$"),void 0===s&&(s=!0),"function"==typeof a){var r,l=a;i instanceof Array||(i=[]);for(var c=0;c<i.length;c++)i[c]=i[c].toUpperCase(),-1!==(r=o.indexOf(i[c]))&&o.splice(r,1);a=function(e){var t=!0;if(e){var e=e.target||e.srcElement,a=e.nodeName.toUpperCase();if(-1<(" "+e.className+" ").indexOf(" mousetrap "))t=!0;else for(var n=0;n<o.length;n++)if(o[n]===a){t=!1;break}}t&&h(l.apply(this,arguments))}}"string"==typeof n?Mousetrap.bind(e,h(a),n):Mousetrap.bind(e,h(a));s=new u(e,t,a,n,i,s);return d.hotkeys.push(s),s}function g(e){var t=e instanceof u?e.combo:e;if(Mousetrap.unbind(t),angular.isArray(t)){for(var a=!0,n=t.length;n--;)a=g(t[n])&&a;return a}var i=d.hotkeys.indexOf(f(t));return-1<i&&(1<d.hotkeys[i].combo.length?d.hotkeys[i].combo.splice(d.hotkeys[i].combo.indexOf(t),1):(angular.forEach(r,function(e){var t=e.indexOf(d.hotkeys[i]);-1!==t&&e.splice(t,1)}),d.hotkeys.splice(i,1)),!0)}function f(e){if(!e)return d.hotkeys;for(var t,a=0;a<d.hotkeys.length;a++)if(-1<(t=d.hotkeys[a]).combo.indexOf(e))return t;return!1}function h(i){return function(e,t){var a,n;i instanceof Array&&(a=i[0],n=i[1],i=function(e){n.scope.$eval(a)}),s.$apply(function(){i(e,f(t))})}}return{add:m,del:g,get:f,bindTo:function(t){return t.$id in r||(r[t.$id]=[],t.$on("$destroy",function(){for(var e=r[t.$id].length;e--;)g(r[t.$id].pop())})),{add:function(e){e=1<arguments.length?m.apply(this,arguments):m(e);return r[t.$id].push(e),this}}},template:this.template,toggleCheatSheet:p,includeCheatSheet:this.includeCheatSheet,cheatSheetHotkey:this.cheatSheetHotkey,cheatSheetDescription:this.cheatSheetDescription,useNgRoute:this.useNgRoute,purgeHotkeys:l,templateTitle:this.templateTitle,pause:function(){i=!1},unpause:function(){i=!0}}}]}]).directive("hotkey",["hotkeys",function(s){return{restrict:"A",link:function(e,t,a){var n,i=[];angular.forEach(e.$eval(a.hotkey),function(e,t){n="string"==typeof a.hotkeyAllowIn?a.hotkeyAllowIn.split(/[\s,]+/):[],i.push(t),s.add({combo:t,description:a.hotkeyDescription,callback:e,action:a.hotkeyAction,allowIn:n})}),t.bind("$destroy",function(){angular.forEach(i,s.del)})}}}]).run(["hotkeys",function(e){}])}(),function(e,n){for(var i,s={8:"backspace",9:"tab",13:"enter",16:"shift",17:"ctrl",18:"alt",20:"capslock",27:"esc",32:"space",33:"pageup",34:"pagedown",35:"end",36:"home",37:"left",38:"up",39:"right",40:"down",45:"ins",46:"del",91:"meta",93:"meta",224:"meta"},a={106:"*",107:"+",109:"-",110:".",111:"/",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"},o={"~":"`","!":"1","@":"2","#":"3",$:"4","%":"5","^":"6","&":"7","*":"8","(":"9",")":"0",_:"-","+":"=",":":";",'"':"'","<":",",">":".","?":"/","|":"\\"},r={option:"alt",command:"meta",return:"enter",escape:"esc",plus:"+",mod:/Mac|iPod|iPhone|iPad/.test(navigator.platform)?"meta":"ctrl"},t=1;t<20;++t)s[111+t]="f"+t;for(t=0;t<=9;++t)s[t+96]=t;function y(e,t,a){e.addEventListener?e.addEventListener(t,a,!1):e.attachEvent("on"+t,a)}function b(e){if("keypress"!=e.type)return s[e.which]||a[e.which]||String.fromCharCode(e.which).toLowerCase();var t=String.fromCharCode(e.which);return t=!e.shiftKey?t.toLowerCase():t}function w(e){return"shift"==e||"ctrl"==e||"alt"==e||"meta"==e}function l(e,t,a){return a="keypress"==(a=a||(function(){if(!i)for(var e in i={},s)95<e&&e<112||s.hasOwnProperty(e)&&(i[s[e]]=e);return i}()[e]?"keydown":"keypress"))&&t.length?"keydown":a}function $(e,t){for(var a,n=[],i="+"===(e=e)?["+"]:(e=e.replace(/\+{2}/g,"+plus")).split("+"),s=0;s<i.length;++s)a=i[s],r[a]&&(a=r[a]),t&&"keypress"!=t&&o[a]&&(a=o[a],n.push("shift")),w(a)&&n.push(a);return{key:a,modifiers:n,action:t=l(a,n,t)}}function k(e){var p=this;if(e=e||n,!(p instanceof k))return new k(e);p.target=e,p._callbacks={},p._directMap={};var l,m={},c=!1,u=!1,d=!1;function g(e){e=e||{};var t,a=!1;for(t in m)e[t]?a=!0:m[t]=0;a||(d=!1)}function f(e,t,a,n,i,s){var o,r=[],l=a.type;if(!p._callbacks[e])return[];for("keyup"==l&&w(e)&&(t=[e]),o=0;o<p._callbacks[e].length;++o){var c,u,d=p._callbacks[e][o];!n&&d.seq&&m[d.seq]!=d.level||l==d.action&&(("keypress"!=l||a.metaKey||a.ctrlKey)&&(c=t,u=d.modifiers,c.sort().join(",")!==u.sort().join(","))||(c=!n&&d.combo==i,u=n&&d.seq==n&&d.level==s,(c||u)&&p._callbacks[e].splice(o,1),r.push(d)))}return r}function h(e,t,a,n){p.stopCallback(t,t.target||t.srcElement,a,n)||!1===e(t,a)&&((a=t).preventDefault?a.preventDefault():a.returnValue=!1,(t=t).stopPropagation?t.stopPropagation():t.cancelBubble=!0)}function t(e){"number"!=typeof e.which&&(e.which=e.keyCode);var t,a=b(e);a&&("keyup"!=e.type||c!==a?p.handleKey(a,(t=[],(a=e).shiftKey&&t.push("shift"),a.altKey&&t.push("alt"),a.ctrlKey&&t.push("ctrl"),a.metaKey&&t.push("meta"),t),e):c=!1)}function o(t,e,a,n){function i(e){return function(){d=e,++m[t],clearTimeout(l),l=setTimeout(g,1e3)}}function s(e){h(a,e,t),"keyup"!==n&&(c=b(e)),setTimeout(g,10)}for(var o=m[t]=0;o<e.length;++o){var r=o+1===e.length?s:i(n||$(e[o+1]).action);v(e[o],r,n,t,o)}}function v(e,t,a,n,i){p._directMap[e+":"+a]=t;var s=(e=e.replace(/\s+/g," ")).split(" ");1<s.length?o(e,s,t,a):(a=$(e,a),p._callbacks[a.key]=p._callbacks[a.key]||[],f(a.key,a.modifiers,{type:a.action},n,e,i),p._callbacks[a.key][n?"unshift":"push"]({callback:t,modifiers:a.modifiers,action:a.action,seq:n,level:i,combo:e}))}p._handleKey=function(e,t,a){for(var n=f(e,t,a),i={},s=0,o=!1,r=0;r<n.length;++r)n[r].seq&&(s=Math.max(s,n[r].level));for(r=0;r<n.length;++r)n[r].seq?n[r].level==s&&(o=!0,i[n[r].seq]=1,h(n[r].callback,a,n[r].combo,n[r].seq)):o||h(n[r].callback,a,n[r].combo);t="keypress"==a.type&&u;a.type!=d||w(e)||t||g(i),u=o&&"keydown"==a.type},p._bindMultiple=function(e,t,a){for(var n=0;n<e.length;++n)v(e[n],t,a)},y(e,"keypress",t),y(e,"keydown",t),y(e,"keyup",t)}k.prototype.bind=function(e,t,a){return e=e instanceof Array?e:[e],this._bindMultiple.call(this,e,t,a),this},k.prototype.unbind=function(e,t){return this.bind.call(this,e,function(){},t)},k.prototype.trigger=function(e,t){return this._directMap[e+":"+t]&&this._directMap[e+":"+t]({},e),this},k.prototype.reset=function(){return this._callbacks={},this._directMap={},this},k.prototype.stopCallback=function(e,t){return!(-1<(" "+t.className+" ").indexOf(" mousetrap "))&&(!function e(t,a){return t!==n&&(t===a||e(t.parentNode,a))}(t,this.target)&&("INPUT"==t.tagName||"SELECT"==t.tagName||"TEXTAREA"==t.tagName||t.isContentEditable))},k.prototype.handleKey=function(){return this._handleKey.apply(this,arguments)},(k.init=function(){var e,t=k(n);for(e in t)"_"!==e.charAt(0)&&(k[e]=function(e){return function(){return t[e].apply(t,arguments)}}(e))})(),e.Mousetrap=k,"undefined"!=typeof module&&module.exports&&(module.exports=k),"function"==typeof define&&define.amd&&define(function(){return k})}(window,document),function(l,g){"use strict";var s=g.$$minErr("$sanitize");var o,t=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,a=/([^\#-~ |!])/g,n=f("area,br,col,hr,img,wbr"),e=f("colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr"),i=f("rp,rt"),r=g.extend({},i,e),e=g.extend({},e,f("address,article,aside,blockquote,caption,center,del,dir,div,dl,figure,figcaption,footer,h1,h2,h3,h4,h5,h6,header,hgroup,hr,ins,map,menu,nav,ol,pre,section,table,ul")),i=g.extend({},i,f("a,abbr,acronym,b,bdi,bdo,big,br,cite,code,del,dfn,em,font,i,img,ins,kbd,label,map,mark,q,ruby,rp,rt,s,samp,small,span,strike,strong,sub,sup,time,tt,u,var")),c=f("circle,defs,desc,ellipse,font-face,font-face-name,font-face-src,g,glyph,hkern,image,linearGradient,line,marker,metadata,missing-glyph,mpath,path,polygon,polyline,radialGradient,rect,stop,svg,switch,text,title,tspan"),u=f("script,style"),d=g.extend({},n,e,i,r),p=f("background,cite,href,longdesc,src,xlink:href"),i=f("abbr,align,alt,axis,bgcolor,border,cellpadding,cellspacing,class,clear,color,cols,colspan,compact,coords,dir,face,headers,height,hreflang,hspace,ismap,lang,language,nohref,nowrap,rel,rev,rows,rowspan,rules,scope,scrolling,shape,size,span,start,summary,tabindex,target,title,type,valign,value,vspace,width"),r=f("accent-height,accumulate,additive,alphabetic,arabic-form,ascent,baseProfile,bbox,begin,by,calcMode,cap-height,class,color,color-rendering,content,cx,cy,d,dx,dy,descent,display,dur,end,fill,fill-rule,font-family,font-size,font-stretch,font-style,font-variant,font-weight,from,fx,fy,g1,g2,glyph-name,gradientUnits,hanging,height,horiz-adv-x,horiz-origin-x,ideographic,k,keyPoints,keySplines,keyTimes,lang,marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,mathematical,max,min,offset,opacity,orient,origin,overline-position,overline-thickness,panose-1,path,pathLength,points,preserveAspectRatio,r,refX,refY,repeatCount,repeatDur,requiredExtensions,requiredFeatures,restart,rotate,rx,ry,slope,stemh,stemv,stop-color,stop-opacity,strikethrough-position,strikethrough-thickness,stroke,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke-width,systemLanguage,target,text-anchor,to,transform,type,u1,u2,underline-position,underline-thickness,unicode,unicode-range,units-per-em,values,version,viewBox,visibility,width,widths,x,x-height,x1,x2,xlink:actuate,xlink:arcrole,xlink:role,xlink:show,xlink:title,xlink:type,xml:base,xml:lang,xml:space,xmlns,xmlns:xlink,y,y1,y2,zoomAndPan",!0),m=g.extend({},p,r,i);function f(e,t){for(var a={},n=e.split(","),i=0;i<n.length;i++)a[t?g.lowercase(n[i]):n[i]]=!0;return a}function h(e){return e.replace(/&/g,"&").replace(t,function(e){return"&#"+(1024*(e.charCodeAt(0)-55296)+(e.charCodeAt(1)-56320)+65536)+";"}).replace(a,function(e){return"&#"+e.charCodeAt(0)+";"}).replace(/</g,"<").replace(/>/g,">")}function v(e,i){var t=!1,s=g.bind(e,e.push);return{start:function(n,e){n=g.lowercase(n),(t=!t&&u[n]?n:t)||!0!==d[n]||(s("<"),s(n),g.forEach(e,function(e,t){var a=g.lowercase(t);!0!==m[a]||!0===p[a]&&!i(e,"img"===n&&"src"===a||"background"===a)||(s(" "),s(t),s('="'),s(h(e)),s('"'))}),s(">"))},end:function(e){e=g.lowercase(e),t||!0!==d[e]||!0===n[e]||(s("</"),s(e),s(">")),e==t&&(t=!1)},chars:function(e){t||s(h(e))}}}!function(e){if(!e.document||!e.document.implementation)throw s("noinert","Can't create an inert html document");var t,e=((t=e.document.implementation.createHTMLDocument("inert")).documentElement||t.getDocumentElement()).getElementsByTagName("body");1===e.length?o=e[0]:(e=t.createElement("html"),o=t.createElement("body"),e.appendChild(o),t.appendChild(e))}(l),g.module("ngSanitize",[]).provider("$sanitize",function(){var t=!1;this.$get=["$$sanitizeUri",function(a){return t&&g.extend(d,c),function(e){var t=[];return function(e,t){null==e?e="":"string"!=typeof e&&(e=""+e);o.innerHTML=e;var a=5;do{if(0===a)throw s("uinput","Failed to sanitize html because the input is unstable");a--,l.document.documentMode&&function e(t){if(t.nodeType===l.Node.ELEMENT_NODE)for(var a=t.attributes,n=0,i=a.length;n<i;n++){var s=a[n],o=s.name.toLowerCase();"xmlns:ns1"!==o&&0!==o.lastIndexOf("ns1:",0)||(t.removeAttributeNode(s),n--,i--)}var r=t.firstChild;r&&e(r);r=t.nextSibling;r&&e(r)}(o),e=o.innerHTML,o.innerHTML=e}while(e!==o.innerHTML);var n,i=o.firstChild;for(;i;){switch(i.nodeType){case 1:t.start(i.nodeName.toLowerCase(),function(e){for(var t={},a=0,n=e.length;a<n;a++){var i=e[a];t[i.name]=i.value}return t}(i.attributes));break;case 3:t.chars(i.textContent)}if(!((n=i.firstChild)||(1==i.nodeType&&t.end(i.nodeName.toLowerCase()),n=i.nextSibling)))for(;null==n&&(i=i.parentNode)!==o;)n=i.nextSibling,1==i.nodeType&&t.end(i.nodeName.toLowerCase());i=n}for(;i=o.firstChild;)o.removeChild(i)}(e,v(t,function(e,t){return!/^unsafe:/.test(a(e,t))})),t.join("")}}],this.enableSvg=function(e){return g.isDefined(e)?(t=e,this):t}}),g.module("ngSanitize").filter("linky",["$sanitize",function(c){var u=/((ftp|https?):\/\/|(www\.)|(mailto:)?[A-Za-z0-9._%+-]+@)\S*[^\s.;,(){}<>"\u201d\u2019]/i,d=/^mailto:/i,p=g.$$minErr("linky"),m=g.isString;return function(e,n,i){if(null==e||""===e)return e;if(!m(e))throw p("notstring","Expected string but received: {0}",e);for(var t,a,s,o=e,r=[];t=o.match(u);)a=t[0],t[2]||t[4]||(a=(t[3]?"http://":"mailto:")+a),s=t.index,l(o.substr(0,s)),function(e,t){r.push("<a "),g.isFunction(i)&&(i=i(e));if(g.isObject(i))for(var a in i)r.push(a+'="'+i[a]+'" ');else i={};!g.isDefined(n)||"target"in i||r.push('target="',n,'" ');r.push('href="',e.replace(/"/g,"""),'">'),l(t),r.push("</a>")}(a,t[0].replace(d,"")),o=o.substring(s+t[0].length);return l(o),c(r.join(""));function l(e){var t;e&&r.push((t=e,v(e=[],g.noop).chars(t),e.join("")))}}}])}(window,window.angular),mod=angular.module("infinite-scroll",[]),mod.directive("infiniteScroll",["$rootScope","$window","$timeout",function(l,c,e){return{link:function(t,a,n){var i,s,o,r;return c=angular.element(c),o=0,null!=n.infiniteScrollDistance&&t.$watch(n.infiniteScrollDistance,function(e){return o=parseInt(e,10)}),i=!(r=!0),null!=n.infiniteScrollDisabled&&t.$watch(n.infiniteScrollDisabled,function(e){if((r=!e)&&i)return i=!1,s()}),s=function(){var e=c.height()+c.scrollTop(),e=a.offset().top+a.height()-e<=c.height()*o;return e&&r?l.$$phase?t.$eval(n.infiniteScroll):t.$apply(n.infiniteScroll):e?i=!0:void 0},c.on("scroll",s),t.$on("$destroy",function(){return c.off("scroll",s)}),e(function(){return!n.infiniteScrollImmediateCheck||t.$eval(n.infiniteScrollImmediateCheck)?s():void 0},0)}}}]),function(b){"use strict";var e=b.module("ngTouch",[]);function t(t,a){var n=!1,i=!1;this.ngClickOverrideEnabled=function(e){return b.isDefined(e)?(e&&!i&&(i=!0,s.$$moduleName="ngTouch",a.directive("ngClick",s),t.decorator("ngClickDirective",["$delegate",function(e){if(n)e.shift();else for(var t=e.length-1;0<=t;){if("ngTouch"===e[t].$$moduleName){e.splice(t,1);break}t--}return e}])),n=e,this):n},this.$get=function(){return{ngClickOverrideEnabled:function(){return n}}}}e.provider("$touch",t),t.$inject=["$provide","$compileProvider"],e.factory("$swipe",[function(){var n={mouse:{start:"mousedown",move:"mousemove",end:"mouseup"},touch:{start:"touchstart",move:"touchmove",end:"touchend",cancel:"touchcancel"}};function c(e){var t=e.originalEvent||e,e=t.touches&&t.touches.length?t.touches:[t],e=t.changedTouches&&t.changedTouches[0]||e[0];return{x:e.clientX,y:e.clientY}}function u(e,t){var a=[];return b.forEach(e,function(e){e=n[e][t];e&&a.push(e)}),a.join(" ")}return{bind:function(e,a,t){var n,i,s,o,r=!1;e.on(u(t=t||["mouse","touch"],"start"),function(e){s=c(e),r=!0,i=n=0,o=s,a.start&&a.start(s,e)});var l=u(t,"cancel");l&&e.on(l,function(e){r=!1,a.cancel&&a.cancel(e)}),e.on(u(t,"move"),function(e){var t;r&&s&&(t=c(e),n+=Math.abs(t.x-o.x),i+=Math.abs(t.y-o.y),o=t,n<10&&i<10||(n<i?(r=!1,a.cancel&&a.cancel(e)):(e.preventDefault(),a.move&&a.move(t,e))))}),e.on(u(t,"end"),function(e){r&&(r=!1,a.end&&a.end(c(e),e))})}}}]);var s=["$parse","$timeout","$rootElement",function(e,n,m){var g,f,i,s=2500,l=25,t="ng-click-active";function h(e,t,a){for(var n,i,s,o,r=0;r<e.length;r+=2)if(n=e[r],i=e[r+1],s=t,o=a,Math.abs(n-s)<l&&Math.abs(i-o)<l)return e.splice(r,r+2),1}function v(e){var t,a,n;Date.now()-g>s||(t=(n=e.touches&&e.touches.length?e.touches:[e])[0].clientX,a=n[0].clientY,t<1&&a<1||i&&i[0]===t&&i[1]===a||(i=i&&null,"label"===(n=e.target,b.lowercase(n.nodeName||n[0]&&n[0].nodeName))&&(i=[t,a]),h(f,t,a)||(e.stopPropagation(),e.preventDefault(),e.target&&e.target.blur&&e.target.blur())))}function y(e){var e=e.touches&&e.touches.length?e.touches:[e],t=e[0].clientX,a=e[0].clientY;f.push(t,a),n(function(){for(var e=0;e<f.length;e+=2)if(f[e]==t&&f[e+1]==a)return void f.splice(e,e+2)},s,!1)}return function(a,s,o){var r,l,c,u,n=e(o.ngClick),d=!1;function p(){d=!1,s.removeClass(t)}s.on("touchstart",function(e){d=!0,3==(r=e.target||e.srcElement).nodeType&&(r=r.parentNode),s.addClass(t),l=Date.now();e=e.originalEvent||e,e=(e.touches&&e.touches.length?e.touches:[e])[0];c=e.clientX,u=e.clientY}),s.on("touchcancel",function(e){p()}),s.on("touchend",function(e){var t=Date.now()-l,a=e.originalEvent||e,n=(a.changedTouches&&a.changedTouches.length?a.changedTouches:a.touches&&a.touches.length?a.touches:[a])[0],i=n.clientX,a=n.clientY,n=Math.sqrt(Math.pow(i-c,2)+Math.pow(a-u,2));d&&t<750&&n<12&&(i=i,a=a,f||(m[0].addEventListener("click",v,!0),m[0].addEventListener("touchstart",y,!0),f=[]),g=Date.now(),h(f,i,a),r&&r.blur(),b.isDefined(o.disabled)&&!1!==o.disabled||s.triggerHandler("click",[e])),p()}),s.onclick=function(e){},s.on("click",function(e,t){a.$apply(function(){n(a,{$event:t||e})})}),s.on("mousedown",function(e){s.addClass(t)}),s.on("mousemove mouseup",function(e){s.removeClass(t)})}}];function a(c,u,d){e.directive(c,["$parse","$swipe",function(r,l){return function(a,n,e){var i,s,o=r(e[c]);var t=["touch"];b.isDefined(e.ngSwipeDisableMouse)||t.push("mouse"),l.bind(n,{start:function(e,t){i=e,s=!0},cancel:function(e){s=!1},end:function(e,t){!function(e){if(i){var t=Math.abs(e.y-i.y),e=(e.x-i.x)*u;return s&&t<75&&0<e&&30<e&&t/e<.3}}(e)||a.$apply(function(){n.triggerHandler(d),o(a,{$event:t})})}},t)}}])}a("ngSwipeLeft",-1,"swipeleft"),a("ngSwipeRight",1,"swiperight")}((window,window.angular)),angular.module("we7app",["ngAnimate","ngSanitize","ui.bootstrap","angular-clipboard"]),angular.module("we7app").run(["$rootScope","we7TypeDefault",function(e,t){e.URL="test",e.we7TypeDefault=t}]),angular.module("we7app").factory("interceptors",[function(){return{request:function(e){return e.beforeSend&&e.beforeSend(),e},response:function(e){return e.config.complete&&e.config.complete(e),e}}}]),angular.module("we7app").config(["$httpProvider",function(e){e.interceptors.push("interceptors"),e.defaults.headers.post["Content-Type"]="application/x-www-form-urlencoded;charset=utf-8",e.defaults.headers.common["X-Requested-With"]="XMLHttpRequest";var l=function(e){var t,a,n,i,s,o,r="";for(t in e)if((a=e[t])instanceof Array)for(o=0;o<a.length;++o)i=a[o],(s={})[t+"["+o+"]"]=i,r+=l(s)+"&";else if(a instanceof Object)for(n in a)i=a[n],(s={})[t+"["+n+"]"]=i,r+=l(s)+"&";else null!=a&&(r+=encodeURIComponent(t)+"="+encodeURIComponent(a)+"&");return r.length?r.substr(0,r.length-1):r};e.defaults.transformRequest=[function(e){return angular.isObject(e)&&"[object File]"!==String(e)?l(e):e}]}]),window.we7ImgError=function(e){var t;$(e).attr("onerror")||(console.log(1),t="resource/images/nopic-107.png",$(e).width()==$(e).height()?t="resource/images/nopic-107.png":$(e).width()<$(e).height()&&(t="resource/images/nopic-203.png"),$(e).hasClass("user-avatar")&&(t="resource/images/nopic-user.png"),$(e).hasClass("module-img")&&(t="resource/images/nopic-module.png"),$(e).hasClass("template-img")&&(t="resource/images/nopic-template.png"),$(e).hasClass("account-img")&&(t="resource/images/nopic-account.png"),$(e).attr("src",t))},window.addEventListener("error",function(e){var t=e.target,a=t.tagName,n=Number(t.dataset.times)||0;"IMG"===a.toUpperCase()&&0==n&&(we7ImgError(e.target),t.dataset.times=n+1)},!0),window.parent&&window.postMessage&&window.parent.postMessage({loaded:location.href},"*"),$(function(){var t,n;window.parent&&window.postMessage&&(setTimeout(function(){window.parent.postMessage({height:document.body.scrollHeight},"*")},400),t=null,window.addEventListener("message",function(e){e.data.scrollTop&&(t=e.data.scrollTop)}),$("body").on("show.bs.modal",".modal",function(){t&&document.documentElement.scrollHeight-t<360&&window.parent&&window.postMessage&&(window.parent.postMessage({loaded:""},"*"),t=null)}),$("body").on("shown.bs.modal",".modal",function(){$(this).removeClass("fade"),t&&$(this).find(".modal-dialog").css({top:t+100+"px"})}),$("body").on("hidden.bs.modal",".modal",function(){window.parent.postMessage({height:document.body.scrollHeight},"*")})),util.cookie_message(),setTimeout(util.check(),1e4),window.sysinfo.uid&&util.cookie.set("__lastvisit_"+window.sysinfo.uid,[window.sysinfo.uniacid,window.sysinfo.siteurl],604800),$(".js-clip").each(function(){util.clip(this,$(this).attr("data-url"))}),$.fn.tooltip&&($('[data-toggle="tooltip"]').tooltip(),$('[data-toggle="dropdown"]').dropdown(),$('[data-toggle="popover"]').popover()),$(function(){$(".we7-group-show").each(function(){$(this).removeClass("low"),$(this).removeClass("closed"),70<$(this).find(".group-app-list").outerHeight()?($(this).addClass("closed"),$(this).find(".action").off("click").on("click",function(){$(this).parent().toggleClass("closed")})):$(this).addClass("low")})}),window.sysinfo.module&&window.sysinfo.module.name&&(null===util.cookie.get("module_status:"+window.sysinfo.module.name)&&null===util.cookie.get("module_status:"+window.sysinfo.module.name)||(module_status=util.cookie.get("module_status:"+window.sysinfo.module.name),module_status=$.parseJSON(module_status),1==module_status.ban?$(".head").after('<div class="system-tips we7-body-alert"><div class="container text-right"> <span class="alert-info"><a href="javascript:;">您的站点å˜åœ¨ç›—版模å—, è¯·åˆ é™¤æ–‡ä»¶åŽè”系客æœ</a></span></div></div>'):1==module_status.upgrade.upgrade&&1==window.sysinfo.isfounder&&$(".head").after('<div class="system-tips we7-body-alert"><div class="container text-right"> <span class="alert-info"><a href="javascript:;">ã€'+module_status.upgrade.name+"】检测最新版为"+module_status.upgrade.version+",请尽快更新ï¼</a></span></div></div>"))),window.sysinfo.isfounder,$(".js-big-main").click(function(){var e=$(".skin-default").hasClass("main-lg-body")?"0":"1";util.cookie.set("main-lg",e),1==util.cookie.get("main-lg")?($(".skin-default").addClass("main-lg-body"),$(".js-big-main").text("æ£å¸¸")):($(".skin-default").removeClass("main-lg-body"),$(".js-big-main").text("宽å±"))}),window.sysinfo.uid&&(n=new Date,$.getJSON("./index.php?c=message&a=notice&do=event_notice",function(e){var a="";0==e.message.errno&&(a+='<a href="javascript:;" class="dropdown-toogle" data-toggle="dropdown"><span class="wi wi-bell"></span><span class="caret"></span>',a+="</a>",a+='<div class="dropdown-menu"><div class="clearfix top">消æ¯<a href="'+e.message.message.more_url+'" class="pull-right">查看更多</a>',0<e.message.message.total&&(a+='<a href="'+e.message.message.all_read_url+'" class="pull-right" style="margin-right: 5px">全部已读</a>'),a+='</div><div class="msg-list-container"><div class="msg-list">',0<e.message.message.total?$.each(e.message.message.lists,function(e,t){a+='<div class="item"><div class="info clearifx"><div class="pull-right date">'+t.create_time+"</div>",1==t.type&&(a+="æ¥è‡ª <span>订å•æ¶ˆæ¯</span>"),2!=t.type&&5!=t.type||(a+="æ¥è‡ª <span>过期消æ¯</span>"),4==t.type&&(a+="æ¥è‡ª <span>注册消æ¯</span>"),3==t.type&&(a+="æ¥è‡ª <span>å·¥å•æ¶ˆæ¯</span>"),8==t.type&&(a+="æ¥è‡ª <span>å°ç¨‹åºå‡çº§æ¨¡å—消æ¯</span>"),10==t.type&&(a+="æ¥è‡ª <span>系统更新通知消æ¯</span>"),11==t.type&&(a+="æ¥è‡ª <span>官方动æ€æ¶ˆæ¯</span>"),a+='</div><div class="msg-content">',a+="<a href="+t.url+">"+t.message+"</a>",a+="</div></div>"}):a+='<div class="we7-empty-block">æš‚æ— æ¶ˆæ¯</div>',a+="</div></div></div>",$(".header-notice").html(a));var t=parseInt(n.getTime()/1e3),e=21600+Math.ceil(1800*Math.random());util.cookie.set("__notice",t+e,e)})),$.get(window.sysinfo.siteroot+"web/index.php?c=utility&a=visit&do=showjs&type="+window.sysinfo.frame),0<$("#js-market-menu").length&&$.post("./index.php?c=module&a=service-market&do=get_market",{method:"util/market/menu-we7",module_name:window.sysinfo.module.name},function(e){if(e&&e.message&&0==e.message.errno){var t,a=e.message.message,n="";for(t in a)a[t]&&a[t].name&&(n=(n=""==n?'<ul class="list-group collapse in">':n)+'<li class="list-group-item '+(we7MarketId==t?"active":"")+'"><a href="./index.php?c=module&a=service-market&do=display&module_name='+window.sysinfo.module.name+"&id="+t+'" class="text-over" target="_blank"><span class="nav-icon" ><img src="'+a[t].icon+'" /></span><span class="nav-title">'+a[t].name+"</span></a></li>");n&&(n+="</ul>",$("#js-market-menu").append(n))}},"json"),$(".js-market-go-optimize").click(function(){var e=["https://jq.qq.com/?_wv=1027&k=REFXKWny","https://jq.qq.com/?_wv=1027&k=REFXKWny","https://jq.qq.com/?_wv=1027&k=REFXKWny"];window.open(e[Math.floor(Math.random()*e.length+1)-1],"_blank")}),$(".js-market-go-database").click(function(){var e=["https://jq.qq.com/?_wv=1027&k=REFXKWny","https://jq.qq.com/?_wv=1027&k=REFXKWny","https://jq.qq.com/?_wv=1027&k=REFXKWny"];window.open(e[Math.floor(Math.random()*e.length+1)-1],"_blank")}),$(".js-market-go-scan").click(function(){var e=["https://jq.qq.com/?_wv=1027&k=REFXKWny","https://jq.qq.com/?_wv=1027&k=REFXKWny","https://jq.qq.com/?_wv=1027&k=REFXKWny"];window.open(e[Math.floor(Math.random()*e.length+1)-1],"_blank")})}),window.UEDITOR_HOME_URL="./resource/components/ueditor/",$(function(){var a,n,i,s,e;1==$("[data-skin='black']").length&&resizeView(),3==$(".menu-fixed, .left-menu, .right-content").length&&(require(["slimscroll"],function(){$(".plugin-menu-sub").slimscroll({width:"210px",height:"100%",opacity:.4,color:"#aaa"})}),s=document.documentElement.clientHeight,a=$(".left-menu"),n=a.offset().top,i=a.css("position"),e=0<$(".footer").length?$(".footer").css("height"):0,"default"==$(".skin-default").attr("data-skin")&&$(".left-menu, .skin-default .right-content").css("min-height",s-174-parseInt(e)+"px"),"black"==$(".skin-black").attr("data-skin")&&$(".left-menu, .skin-default .right-content").css("min-height",s-51+"px"),$(window).scroll(function(){var e=0<$(".footer").length&&!$(".footer").is(":hidden")?$(".footer").offset().top:0,t=$(document).scrollTop(),e=e?e-t:s;"default"==$(".skin-default").attr("data-skin")?(n<t?a.css({position:"fixed",height:"auto",top:0,bottom:e<s?s-e+31+"px":"0"}):a.css({position:i,height:s}),n<t?$(".right-content").css({marginLeft:a.css("width")}):$(".right-content").css({marginLeft:0,minHeight:a.height()})):"black"==$(".skin-black").attr("data-skin")&&(n<t?a.css({position:"fixed",top:0,bottom:0}):a.css({position:i,top:t}),n<t?$(".right-content").css({marginLeft:a.css("width")}):$(".right-content").css({marginLeft:0,minHeight:a.height()}))})),1==$("[data-skin='classical']").length&&(s=document.documentElement.clientHeight,e=0<$(".footer").length?$(".footer").css("height"):0,2==$(".left-menu, .right-content").length&&$(".right-content>.content").css("min-height",s-parseInt(e)-71),0<$(".panel-cut").length&&$(".panel-cut").css("min-height",s-parseInt(e)-71)),1==$("[data-skin='2']").length&&require(["slimscroll"],function(){var e,t,a;$(".skin-2__left .main-nav").slimScroll({height:"calc(100vh - 90px)",opacity:.4,color:"#989898"}),$(".js-menu").length&&(e=$(".sub-top").outerHeight(),t=$(".js-menu").attr("id"),(a=util.cookie.get("jsMenuScroll"))&&-1!==a.indexOf(t+":")?a=a.split(":")[1]:(a="",util.cookie.set("jsMenuScroll","")),setTimeout(function(){$(".js-menu").slimScroll({width:"200px",height:$(".skin-2__sub")[0].clientHeight-e+"px",opacity:.4,color:"#989898",scrollTo:"100px"}).bind("scroll",function(e,t){util.cookie.set("jsMenuScroll",e.currentTarget.id+":"+$(e.currentTarget).scrollTop())})},window.parent?450:0),a&&$(".js-menu").slimScroll({scrollTo:a+"px"}),setTimeout(function(){$(".js-menu").trigger("mouseenter")},100),$(".slimScrollBar").css("display","none")),$(".js-lock-menu").on("click",function(){$(".skin-2__left").toggleClass("skin-2__left--small"),$(".js-lock-menu").toggleClass("lock"),util.cookie.set("jsMenuLock",1==util.cookie.get("jsMenuLock")?0:1)}),$(".action-cut").each(function(){$(this).hover(function(){$(this).hasClass("open")&&$(this).find('[data-toggle="dropdown"]').dropdown("toggle")}),$(this).offset().left<350?$(this).find(".dropdown-menu").addClass("dropdown-menu-left"):$(this).offset().left+350>$(document).width()&&$(this).find(".dropdown-menu").addClass("dropdown-menu-right")})})}),angular.module("we7app").directive("we7Colorpicker",[function(){return{restrict:"AE",templateUrl:"directive-colorpicker-colorpicker.html",scope:{colorValue:"=we7MyColor",colorDefault:"=we7MyDefaultColor",colorFormName:"=we7FormName"},link:function(t,a,e){$(a).data("data-colorpicker-init")||(util.colorpicker(a,function(e){$(a).parent().parent().find(":text").val(e.toHexString()),t.colorValue=e.toHexString(),t.$apply("colorValue"),t.$watch("colorValue",function(e){$(a).spectrum("get")!=e&&($(a).spectrum("set",e||t.colorDefault),$(a).parent().parent().find(":text").val(e||t.colorDefault),$(a).parent().parent().find(".input-group-addon").css("background-color",e||t.colorDefault))})}),$(a).find(".colorclean").click(function(){return $(a).find(":text").val("rgba(0,0,0,0)"),$(a).find(".input-group-addon").css("background-color","rgba(0,0,0,0)"),t.colorValue=t.colorDefault="rgba(0,0,0,0)",$(a).spectrum("set",t.colorDefault),t.$apply("colorValue"),!1}),$(a).data("data-colorpicker-init",!0))}}}]),angular.module("we7app").directive("we7DatePicker",["$http","$parse",function(){return{transclude:!0,template:"<span ng-transclude></span>",scope:{dateValue:"=we7DateValue",type:"@dateType"},link:function(n,t,e){require(["datetimepicker"],function(){var a="time"===n.type?"H:i:s":"date"===n.type?"Y-m-d":"Y-m-d H:i:s",e={lang:"zh",step:"1",format:a,closeOnDateSelect:!0,datepicker:"time"!=n.type,timepicker:"date"!=n.type,onSelectDate:function(e,t){n.dateValue=e.dateFormat(a),n.$apply("dateValue")},onSelectTime:function(e,t){n.dateValue=e.dateFormat(a),n.$apply("dateValue")}};$(t).datetimepicker(e)})}}}]),angular.module("we7app").directive("we7DateRangePicker",["$compile","$parse","$filter",function(e,r,l){return{restrict:"A",require:"?ngModel",link:function(i,s,e,o){require(["daterangepicker"],function(){var t={};function a(e){return moment.isMoment(e)?e:moment(e)}function n(e){return l("date")((e=e,moment.isMoment(e)?e.toDate():e),t.format.replace(/Y/g,"y").replace(/D/g,"d"))}t.format=e.format||"YYYY-MM-DD",t.separator=e.separator||" - ",t.minDate=e.minDate&&moment(e.minDate),t.maxDate=e.maxDate&&moment(e.maxDate),t.dateLimit=e.limit&&moment.duration.apply(this,e.limit.split(" ").map(function(e,t){return 0===t&&parseInt(e,10)||e})),t.ranges=e.ranges&&r(e.ranges)(i),t.locale=e.locale&&r(e.locale)(i),t.opens=e.opens||r(e.opens)(i),e.enabletimepicker&&(t.timePicker=!0,angular.extend(t,r(e.enabletimepicker)(i))),o.$render=function(){var e;o.$viewValue&&o.$viewValue.startDate&&s.val([n((e=o.$viewValue).startDate),n(e.endDate)].join(t.separator))},i.$watch(function(){return e.ngModel},function(e,t){i[e]&&i[e].startDate?t===e&&(s.data("daterangepicker").startDate=a(i[e].startDate),s.data("daterangepicker").endDate=a(i[e].endDate),s.data("daterangepicker").updateView(),s.data("daterangepicker").updateCalendars(),s.data("daterangepicker").updateInputText()):o.$setViewValue({startDate:moment().startOf("day"),endDate:moment().startOf("day")})}),s.daterangepicker(t,function(e,t,a){var n=o.$viewValue;angular.equals(e,n.startDate)&&angular.equals(t,n.endDate)||i.$apply(function(){o.$setViewValue({startDate:moment.isMoment(n.startDate)?e:e.toDate(),endDate:moment.isMoment(n.endDate)?t:t.toDate()}),o.$render()})})})}}}]),angular.module("we7app").directive("we7Editor",function(){return{scope:{value:"=?we7MyValue",params:"=?we7MyParams",options:"@options",global:"@global"},template:'<textarea id="" rows="10" style="height:600px;width:100%"></textarea>',link:function(a,n,e){var t;n.data("editor")||(n.find("textarea").attr("id","editor"+(new Date).getTime()),t={callback:function(e,t){n.data("editor","true"),t.addListener("contentChange",function(){a.value=t.getContent(),a.value&&(a.params=a.value.replace(/\"/g,"#quot;")),a.$root.$$phase||a.$apply("value")}),t.addListener("ready",function(){!a.value&&a.params&&(a.value=a.params.replace(/\#quot;/g,""")),a.value&&t&&t.getContent()!=a.value&&t.setContent(a.value),a.$watch("value",function(e){t&&t.getContent()!=e&&t.setContent(e||"")})})}},a.options&&"object"==typeof a.options&&Object.assign(t,a.options),a.global&&(t.global=!0,t.uniacid=0),util.editor(n.find("textarea").attr("id"),t))}}}),angular.module("we7app").directive("we7FileUp",["$http","$parse",function(){return{scope:{type:"@type",multiple:"@multiple",value:"=we7File",onConfirm:"=?onConfirm",options:"@options",global:"@global"},link:function(t,a,n){var i={type:t.type||"image",direct:!1,multiple:t.multiple||!1,dest_dir:"",global:!1,thumb:!1,width:0,needType:2};t.options&&"object"==typeof t.options&&(i=$.extend({},i,t.options)),t.global&&(i.global=!0,i.uniacid=0),a.on("click",function(e){require(["fileUploader"],function(e){e.show(function(e){e&&(t.value=e,t.onConfirm&&"function"==typeof t.onConfirm&&t.onConfirm(e,a,n),t.$root.$$phase||t.$apply("value"))},i)})})}}}]),angular.module("we7app").directive("we7Iconer",["$templateCache",function(e){e.get("directive-iconer-nav-pills-inline.html"),e.get("directive-iconer-tab-content-inline.html");return{scope:{image:"=we7MyImage",icon:"=we7MyIcon",iconcolor:"=we7MyIconColor"},transclude:!0,templateUrl:"directive-iconer-iconer.html",link:function(t,e,a){t.selectIcon=function(){require(["fileUploader"],function(e){e.show(function(e){t.icon={},t.icon.name=e.name,t.icon.color=e.color,t.$apply("image"),t.$apply("icon")},{direct:!0,multiple:!1,type:"icon",otherVal:t.iconcolor})})},t.removeIcon=function(){t.image="",t.icon={}}}}}]),angular.module("we7app").directive("we7InitialSearchbar",function(){return{templateUrl:"directive-initialsearchbar-searchbar.html",scope:{doSearch:"&we7SearchCallback"},link:function(t,e,a){t.alphabet=["A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"],t.searchResult=function(e){t.activeLetter=e,t.doSearch({letter:e})}}}}),angular.module("we7app").directive("we7Linker",["$http","$templateCache",function(a,e){var n=e.get("directive-linker-cms-header-inline.html"),s=e.get("directive-linker-cms-content-inline.html"),l=e.get("directive-linker-cms-article-item-inline.html"),c=e.get("directive-linker-cms-cate-item-inline.html"),u=e.get("directive-linker-news-content-inline.html"),d=e.get("directive-linker-news-item-inline.html"),p=e.get("directive-linker-page-content-inline.html"),m=e.get("directive-linker-page-item-inline.html"),o=e.get("directive-linker-map-content-inline.html"),g=e.get("directive-linker-tel-content-inline.html");return{templateUrl:"directive-linker-linker.html",scope:{url:"=we7MyUrl",title:"=we7MyTitle"},link:function(r,t,e){t.find(".input-group-btn").mouseover(function(e){clearTimeout(r.timer),t.find(".dropdown-menu").show()}).mouseout(function(){r.timer=setTimeout(function(){t.find(".dropdown-menu").hide()},500)}),t.find(".dropdown-menu").mouseover(function(){clearTimeout(r.timer),t.find(".dropdown-menu").show()}).mouseout(function(){r.timer=setTimeout(function(){t.find(".dropdown-menu").hide()},500)}),r.addLink=function(e,t){r.url=e,t&&(r.title=t)},r.searchSystemLinker=function(){r.modalobj=util.dialog("请选择链接",["./index.php?c=utility&a=link&callback=selectLinkComplete"],"",{containerName:"link-search-system"}),r.modalobj.modal({keyboard:!1}),r.modalobj.find(".modal-body").css({height:"680px","overflow-y":"auto"}),r.modalobj.modal("show"),window.selectLinkComplete=function(e,t){r.addLink(e,t),r.$apply("url","title"),r.modalobj.modal("hide")}},r.searchCmsLinker=function(e){var o={};o.header=n,o.content=s,o.footer="",o.articleitem=l,o.cateitem=c,$("#link-search-cms")[0]?r.modalobj=$("#link-search-cms").data("modal"):(r.modalobj=util.dialog(o.header,o.content,o.footer,{containerName:"link-search-cms"}),r.modalobj.find(".modal-body").css({height:"680px","overflow-y":"auto"}),r.modalobj.modal("show"),r.modalobj.on("hidden.bs.modal",function(){r.modalobj.remove()}),$("#link-search-cms").data("modal",r.modalobj)),e=e||1;var t=$("#articlelist .article-list-input").val();a.get("./index.php?c=utility&a=link&do=articlelist&page="+e+"&keyword="+t).success(function(e,t,a,n){var s={items:[]};if(e.message=e.message.message,e.message.list){for(i in e.message.list)s.items.push({title:e.message.list[i].title,id:e.message.list[i].id,uniacid:e.message.list[i].uniacid,attachment:e.message.list[i].thumb_url,createtime:e.message.list[i].createtime});r.modalobj.find("#articlelist tbody").html(_.template(o.articleitem)(s)),r.modalobj.find("#pager").html(e.message.pager),r.modalobj.find("#pager .pagination li[class!='active'] a").click(function(){return r.searchCmsLinker($(this).attr("page")),!1}),r.modalobj.find("#articlelist .input-group-btn").click(function(){return r.searchCmsLinker(),!1}),r.modalobj.find(".js-btn-select").click(function(){r.addLink($(this).attr("js-url"),$(this).attr("js-title")),r.$apply("url","title"),r.modalobj.modal("hide")})}});t=$("#category .category-list-input").val();a.get("./index.php?c=utility&a=link&do=catelist&page="+e+"&keyword="+t).success(function(e,t,a,n){var s={items:[]};if(e.message=e.message.message,e.message){for(i in e.message)s.items.push({id:e.message[i].id,uniacid:e.message[i].uniacid,name:e.message[i].name,children:e.message[i].children});r.modalobj.find("#category tbody").html(_.template(o.cateitem)(s)),r.modalobj.find("#category .input-group-btn").click(function(){return r.searchCmsLinker(),!1}),r.modalobj.find(".js-btn-select").click(function(){r.addLink($(this).attr("js-url"),$(this).attr("js-title")),r.$apply("url","title"),r.modalobj.modal("hide")})}})},r.searchNewsLinker=function(e){var o={};o.content=u,o.footer="",o.newsitem=d,$("#link-search-news")[0]?r.modalobj=$("#link-search-news").data("modal"):(r.modalobj=util.dialog(o.header,o.content,o.footer,{containerName:"link-search-news"}),r.modalobj.find(".modal-body").css({height:"680px","overflow-y":"auto"}),r.modalobj.modal("show"),r.modalobj.on("hidden.bs.modal",function(){r.modalobj.remove()}),$("#link-search-news").data("modal",r.modalobj)),e=e||1;var t=$("#newslist .news-list-input").val();a.get("./index.php?c=utility&a=link&do=newslist&page="+e+"&keyword="+t).success(function(e,t,a,n){var s={items:[]};if(e.message=e.message.message,e.message.list){for(i in e.message.list)s.items.push({title:e.message.list[i].title,id:e.message.list[i].id,uniacid:window.sysinfo.uniacid,attachment:e.message.list[i].thumb_url,createtime:e.message.list[i].createtime,url:e.message.list[i].url});r.modalobj.find("#newslist tbody").html(_.template(o.newsitem)(s)),r.modalobj.find("#pager").html(e.message.pager),r.modalobj.find("#pager .pagination li[class!='active'] a").click(function(){return r.searchNewsLinker($(this).attr("page")),!1}),r.modalobj.find("#newslist .input-group-btn").click(function(){return r.searchNewsLinker(),!1}),r.modalobj.find(".js-btn-select").click(function(){r.addLink($(this).attr("js-url"),$(this).attr("js-title")),r.$apply("url","title"),r.modalobj.modal("hide")})}})},r.searchPageLinker=function(e){var o={};o.content=p,o.footer="",o.pageItem=m,$("#link-search-page")[0]?r.modalobj=$("#link-search-page").data("modal"):(r.modalobj=util.dialog(o.header,o.content,o.footer,{containerName:"link-search-page"}),r.modalobj.find(".modal-body").css({height:"680px","overflow-y":"auto"}),r.modalobj.modal("show"),r.modalobj.on("hidden.bs.modal",function(){r.modalobj.remove()}),$("#link-search-page").data("modal",r.modalobj)),e=e||1;var t=$("#pageList .page-list-input").val();a.get("./index.php?c=utility&a=link&do=pagelist&&page="+e+"&keyword="+t).success(function(e,t,a,n){var s={items:[]};if(e.message=e.message.message,e.message.list){for(i in e.message.list)s.items.push({title:e.message.list[i].title,id:e.message.list[i].id,uniacid:window.sysinfo.uniacid,createtime:e.message.list[i].createtime});r.modalobj.find("#pageList tbody").html(_.template(o.pageItem)(s)),r.modalobj.find("#pager").html(e.message.pager),r.modalobj.find("#pager .pagination li[class!='active'] a").click(function(){return r.searchPageLinker($(this).attr("page")),!1}),r.modalobj.find("#pageList .input-group-btn").click(function(){return r.searchPageLinker(),!1}),r.modalobj.find(".js-btn-select").click(function(){r.addLink($(this).attr("js-url"),$(this).attr("js-title")),r.$apply("url","title"),r.modalobj.modal("hide")})}})},r.searchMapPosLinker=function(){var e={};e.content=o,r.modalobj=util.dialog(e.content),r.modalobj.modal("show"),r.modalobj.find("#getnav").click(function(){r.addLink("https://api.map.baidu.com/marker?location="+$("#navlat").val()+","+$("#navlng").val()+"&title="+$("#navtitle").val()+"&name="+$("#navtitle").val()+"&output=html&src=we7",$("#navtitle").val()),r.$apply("url","title"),r.modalobj.modal("hide")})},r.addTelLinker=function(){var e={};e.content=g,r.modalobj=util.dialog("一键拨å·",e.content),r.modalobj.modal("show"),r.modalobj.find(".btn-primary").click(function(){r.addLink("tel:"+r.modalobj.find("#telphone").val(),""),r.$apply("url","title"),r.modalobj.modal("hide")})}}}}]),angular.module("we7app").directive("we7ModalAccount",["we7TypeDefault",function(n){return{restrict:"AE",templateUrl:"directive-modal_account-modal_account.html",scope:{account:"=account",multiple:"=multiple",title:"=title",confirm:"&onConfirm",type:"=type"},transclude:!0,link:function(o,t,e,a){o.type=o.type||1,o.showType=3!=o.type?"account":"number",o.we7TypeDefault=n,o.module_keyword="",o.time=(new Date).getTime(),o.checkAllStatus=!1,o.changePage=function(e,t){var a=-1,n=(e-1)*t;for(index in o.groups=[],o.checkAllStatus=!0,o.activeList)if(!(++a<n)){if(n+t<=a)break;o.activeList[a].checked||(o.checkAllStatus=!1),o.groups.push(o.activeList[index])}},o.loadMore=function(e){o.pageindex=e;for(var t in o.activeList=[],o.accountList){var a=o.accountList[t];a.checked=a.checked||0,a.group_name=a.group_name||"",o.module_keyword&&-1===a.group_name.indexOf(o.module_keyword)||o.activeList.push(a)}if(totalPage=Math.ceil(o.activeList.length/3),o.totalPage=totalPage,o.changePage(e,3),totalPage<e)return!1;if(totalPage<2)return!(o.pageList=[]);e=+e;var n=Math.max(1,e-4),i=Math.min(totalPage,e+4);i-n<9&&(i=Math.min(totalPage,n+8),n=Math.max(1,i-8)),o.pageList=[];for(var s=n;s<=i;s++)o.pageList.push(s)},o.checkAll=function(){for(var e in console.log(o.checkAllStatus),o.groups)o.groups[e].checked=o.checkAllStatus?1:0,console.log(o.groups[e])},o.tabChange=function(e){o.showType=e},o.ngConfirm=function(){3!=o.type&&(o.account.create_groups=JSON.parse(JSON.stringify(o.accountList))),2!=o.type&&(o.account.create_numbers=JSON.parse(JSON.stringify(o.numberList))),setTimeout(function(){o.confirm&&"function"==typeof o.confirm&&o.confirm()},0),t.find(".modal").modal("hide")},o.check=function(e){for(var t in e.checked=e.checked?0:1,o.multiple||o.ngConfirm(),o.checkAllStatus=!0,o.groups)o.groups[t].checked||(o.checkAllStatus=!1)},t.on("click","ng-transclude",function(e){o.type=o.type||1,o.accountList=3!=o.type?JSON.parse(JSON.stringify(o.account.create_groups)):[],o.numberList=2!=o.type?JSON.parse(JSON.stringify(o.account.create_numbers)):{},3!=o.type&&o.loadMore(o.pageindex),o.$apply(),t.find(".modal").modal("show")})},controller:["$scope",function(e){this.$onInit=function(){}}]}}]),angular.module("we7app").directive("we7ModalAccountList",["we7TypeDefault",function(n){return{restrict:"AE",templateUrl:"directive-modal_account_list-modal_account_list.html",scope:{accountList:"=accountList",multiple:"=multiple",title:"=title",confirm:"&onConfirm"},transclude:!0,link:function(i,t,e,a){i.typeList=n,i.modules=[],i.activeList=[],i.appList=[],i.checkAllStatus=!1,i.pageindex=1,i.changePage=function(e,t){var a=-1,n=(e-1)*t;for(index in i.modules=[],i.checkAllStatus=!0,i.accountModalList)if(!(++a<n)){if(n+t<=a)break;i.accountModalList[a].checked||(i.checkAllStatus=!1),i.modules.push(i.accountModalList[index])}},i.loadMore=function(e){i.pageindex=e;if(totalPage=Math.ceil(i.accountModalList.length/21),i.totalPage=totalPage,i.changePage(e,21),totalPage<e)return!1;if(totalPage<2)return!(i.pageList=[]);e=+e;var t=Math.max(1,e-4),a=Math.min(totalPage,e+4);a-t<9&&(a=Math.min(totalPage,t+8),t=Math.max(1,a-8));i.pageList=[];for(var n=t;n<=a;n++)i.pageList.push(n)},i.itemCheck=function(e){for(var t in e.checked=e.checked?0:1,i.checkAllStatus=!0,i.modules)i.modules[t].checked||(i.checkAllStatus=!1);i.multiple||i.ngConfirm()},i.ngConfirm=function(){i.accountList=i.accountModalList,setTimeout(function(){i.confirm&&"function"==typeof i.confirm&&(console.log(i.accountList),i.confirm())},0),t.find(".modal").modal("hide")},i.checkAll=function(){for(var e in i.modules)i.modules[e].checked=i.checkAllStatus?1:0},t.on("click","ng-transclude",function(e){i.accountModalList=i.accountList,i.loadMore(i.pageindex),i.$apply(),t.find(".modal").modal("show")})},controller:["$scope",function(e){this.$onInit=function(){}}]}}]),angular.module("we7app").directive("we7ModalApp",["we7TypeDefault",function(n){return{restrict:"AE",templateUrl:"directive-modal_app-modal_app.html",scope:{moduleList:"=moduleList",multiple:"=multiple",title:"=title",confirm:"&onConfirm"},transclude:!0,link:function(i,t,e,a){i.showType="app",i.typeList=n,i.modules=[],i.activeList=[],i.appList=[],i.checkAllStatus={checkAllStatus:!0},i.time=(new Date).getTime(),i.manage=function(){var e;i.modalType=0,i.moduleList&&(((e=JSON.parse(JSON.stringify(i.moduleList))).modules||e.templates)&&(i.modalType=1,i.appList=e.modules,i.templateList=e.templates),e.groups&&(i.modalType=i.modalType?2:3,i.groupList=e.groups),3==i.modalType&&(i.showType="group"))},i.copy=function(e){var t,a=[];for(t in i[e]){var n=i[e][t];n.title=n.title||"",n.checked=n.checked||0,i.module_keyword&&-1===n.title.indexOf(i.module_keyword)&&-1===n.name.indexOf(i.module_keyword)||"appList"==e&&i.moduleType&&n.support!=i.moduleType||a.push(n)}return a},i.changePage=function(e,t){var a=-1,n=(e-1)*t;for(index in i.modules=[],i.checkAllStatus.checkAllStatus=!0,i.activeList)if(!(++a<n)){if(n+t<=a)break;i.activeList[a].checked||(i.checkAllStatus.checkAllStatus=!1),i.modules.push(i.activeList[index])}},i.loadMore=function(e){i.pageindex=e;var t=14;if(i.showType=i.showType||"app","app"==i.showType?i.activeList=i.copy("appList"):"template"==i.showType?(i.activeList=i.copy("templateList"),t=6):"group"==i.showType&&(i.activeList=i.copy("groupList"),t=3),totalPage=Math.ceil(i.activeList.length/t),i.totalPage=totalPage,i.changePage(e,t),totalPage<e)return!1;if(totalPage<2)return!(i.pageList=[]);e=+e;var t=Math.max(1,e-4),a=Math.min(totalPage,e+4);a-t<9&&(a=Math.min(totalPage,t+8),t=Math.max(1,a-8));i.pageList=[];for(var n=t;n<=a;n++)i.pageList.push(n)},i.tabChange=function(e){i.showType=e,i.loadMore(1),setTimeout(function(){t.find("select").niceSelect&&t.find("select").niceSelect()})},i.itemCheck=function(e){for(var t in e.checked=e.checked?0:1,i.multiple||i.ngConfirm(),i.checkAllStatus.checkAllStatus=!0,i.modules)i.modules[t].checked||(i.checkAllStatus.checkAllStatus=!1)},i.ngConfirm=function(){3!=i.modalType&&(i.appList&&(i.moduleList.modules=JSON.parse(JSON.stringify(i.appList))),i.templateList&&(i.moduleList.templates=JSON.parse(JSON.stringify(i.templateList)))),1!=i.modalType&&i.groupList&&(i.moduleList.groups=JSON.parse(JSON.stringify(i.groupList))),setTimeout(function(){i.confirm&&"function"==typeof i.confirm&&i.confirm()},0),t.find(".modal").modal("hide")},i.checkAll=function(){for(var e in i.modules)i.modules[e].checked=i.checkAllStatus.checkAllStatus?1:0},i.manage(),i.loadMore(1),t.on("click","ng-transclude",function(e){i.manage(),i.tabChange(i.showType),i.$apply(),t.find(".modal").modal("show")})},controller:["$scope",function(e){this.$onInit=function(){}}]}}]),angular.module("we7app").directive("we7ModalForm",function(){return{restrict:"AE",templateUrl:"directive-modal_form-modal_form.html",scope:{type:"=type",rows:"@rows",label:"=label",name:"=name",options:"=options",key:"=key",value:"=value",help:"=help",confirm:"&onConfirm",cancel:"&onCancel",text:"=text"},transclude:!1,link:function(t,a,e){if(t.formRows=t.rows||3,t.formValue=t.value||"",t.value&&t.key)for(var n in t.options)t.options[n][t.key]==t.value[t.key]&&(t.formValue=t.options[n]);t.showModal=function(){a.find(".modal").modal("show"),a.find("select").niceSelect&&a.find("select").niceSelect()},t.ngConfirm=function(){a.find(".modal").modal("hide");var e={value:JSON.parse(JSON.stringify(t.formValue))};e.value&&e.value.$$hashKey&&delete e.value.$$hashKey,t.confirm&&"function"==typeof t.confirm&&t.confirm({formValue:e})}},controller:["$scope",function(e){this.$onInit=function(){e.formValue=e.value||""}}]}}),angular.module("we7app").directive("we7ModalTip",function(){return{restrict:"AE",template:'<ng-transclude ></ng-transclude><div class="modal fade modal-tip" tabindex="-1" role="dialog" >\t<div class="modal-dialog" role="document">\t\t<div class="modal-content">\t\t\t<div class="modal-header clearfix">\t\t\t\t<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>\t\t\t</div>\t\t\t<div class="modal-body"> \t\t\t\t<i class="wi wi-info"></i> \t<p class="title">{{titile || "系统æ示"}}</p> \t\t\t\t<p class="content">{{content}}</p>\t\t\t</div>\t\t\t<div class="modal-footer">\t\t\t\t<button type="button" class="btn btn-primary" ng-click="ngConfirm()">确定</button>\t\t\t\t<button type="button" class="btn btn-default" data-dismiss="modal">å–消</button>\t\t\t</div>\t\t</div>\t</div></div>',scope:{title:"=title",type:"=type",content:"=content",confirm:"&onConfirm",cancel:"&onCancel"},transclude:!0,link:function(e,t,a){t.on("click","ng-transclude",function(e){t.find(".modal").modal("show")}),e.ngConfirm=function(){t.find(".modal").modal("hide"),e.confirm&&"function"==typeof e.confirm&&e.confirm()}},controller:["$scope",function(e){this.$onInit=function(){}}]}}),angular.module("we7app").directive("we7ModalType",function(){return{restrict:"AE",templateUrl:"directive-modal_type-modal_type.html",scope:{typeList:"=typeList",multiple:"=multiple",title:"=title",confirm:"&onConfirm"},transclude:!0,link:function(a,n,e,t){a.typeText={wxapp_support:"å°ç¨‹åº",account_support:"公众å·",welcome_support:"系统首页",webapp_support:"PC",phoneapp_support:"APP",xzapp_support:"熊掌å·",aliapp_support:"支付å®å°ç¨‹åº"},a.typeDefault=["wxapp_support","account_support","welcome_support","webapp_support","phoneapp_support","xzapp_support","aliapp_support"],a.list=a.typeList||a.typeDefault,n.on("click","ng-transclude",function(e){a.list=a.typeList||a.typeDefault,a.$apply("list"),n.find(".modal").modal("show")}),a.checkArray={},a.check=function(e){a.checkArray[e]=!a.checkArray[e],a.multiple||a.ngConfirm()},a.ngConfirm=function(){var e,t=[];for(e in a.checkArray)a.checkArray[e]&&t.push(e);a.checkArray={},n.find(".modal").modal("hide"),setTimeout(function(){a.confirm({type:t})},100)}},controller:["$scope",function(e){this.$onInit=function(){}}]}}),angular.module("we7app").directive("img",["$timeout",function(e){return{restrict:"E",priority:-1,link:function(e,t,a){t.bind("error",function(){e.setSrc(t,a)}),e.setSrc=function(e,t){var a="resource/images/nopic-107.png";$(e).width()==$(e).height()?a="resource/images/nopic-107.png":$(e).width()<$(e).height()&&(a="resource/images/nopic-203.png"),$(e).hasClass("user-avatar")&&(a="resource/images/nopic-user.png"),$(e).hasClass("module-img")&&(a="resource/images/nopic-module.png"),$(e).hasClass("template-img")&&(a="resource/images/nopic-template.png"),$(e).hasClass("account-img")&&(a="resource/images/nopic-account.png"),t.$set("src",a)},setTimeout(function(){a.src||a.ngSrc||e.setSrc(t,a)},10)}}}]),angular.module("we7app").directive("ngModel",["$timeout",function(n){return{restrict:"A",priority:-1,link:function(e,a,t){e.$watch(t.ngModel,function(e,t){e&&n(function(){var e;"createEvent"in document?((e=document.createEvent("HTMLEvents")).initEvent("change",!1,!0),a[0].dispatchEvent(e)):a[0].fireEvent("onchange")},0,!1)})}}}]),angular.module("we7app").directive("we7ResourcePicker",function(){return{scope:{type:"@type",isWechat:"@isWechat",multiple:"@mutiple",showType:"@showType",needType:"@needType",global:"@global",dest_dir:"@dest_dir",onSelect:"&onSelect"},link:function(a,e,t){$(e).unbind("click").on("click",function(){a.show()}),$(window).unbind("resource_selected").on("resource_selected",function(e,t){a.finish(t.type,t.items)})},controller:function(a){a.show=function(){var e={type:a.type,isWechat:"true"===a.isWechat,multiple:"true"===a.multiple,needType:a.needType<=3?a.needType:3,global:"true"===a.global,dest_dir:a.dest_dir};$("#material-Modal").remove();t="<div "+("we7-resource-"+(t=a.type)+"-dialog")+' class="uploader-modal modal fade '+("music"==t?"music voice":t)+'" id="material-Modal" role="dialog" aria-labelledby="myModalLabel2"></div>';$(document.body).prepend(t);var t=$("#material-Modal");t.modal("show"),angular.module("we7resource").value("config",e),angular.bootstrap(t,["we7resource"])},a.finish=function(e,t){a.onSelect({type:e,items:t}),$("#material-Modal").modal("hide")}}}}),angular.module("we7app").directive("we7Page",[function(){return{restrict:"EA",template:'<div class="page-list page-list--flex" ng-show="conf.totalItems > conf.itemsPerPage"><ul class="pagination pagination-centered" ng-show="conf.totalItems > 1"><li ng-class="{disabled: conf.currentPage == 1}"><a href="javascript:;" ng-click="prevPage()"><span>«</span></a></li><li ng-repeat="item in pageList track by $index" ng-class="{active: item == conf.currentPage, separate: item == \'...\'}" ng-click="changeCurrentPage(item)"><a href="javascript:;"><span>{{ item }}</span></a></li><li ng-class="{disabled: conf.currentPage == conf.numberOfPages}" ng-click="nextPage()"><a href="javascript:;"><span>»</span></a></li></ul><div class="search-page we7-form" ng-show="conf.totalItems > conf.itemsPerPage" ng-if="conf.showGo"><input type="number" min="1" max="{{conf.numberOfPages}}" ng-model="goPage" class="form-control"><a href="javascript:;" ng-click="changeCurrentPage(goPage)">跳转</a></div></div>',replace:!0,scope:{conf:"="},link:function(i,e,t){i.goPage="",i.changeCurrentPage=function(e){"..."==e||(i.conf.currentPage=e,i.conf.onChange&&i.conf.onChange())},i.conf.pagesLength=parseInt(i.conf.pagesLength)?parseInt(i.conf.pagesLength):9,i.conf.pagesLength%2==0&&(i.conf.pagesLength=i.conf.pagesLength-1),i.conf.perPageOptions||(i.conf.perPageOptions=[10,15,20,30,50]),i.prevPage=function(){1<i.conf.currentPage&&(--i.conf.currentPage,i.conf.onChange&&i.conf.onChange())},i.nextPage=function(){i.conf.currentPage<i.conf.numberOfPages&&(i.conf.currentPage+=1,i.conf.onChange&&i.conf.onChange())},i.jumpToPage=function(){i.jumpPageNum=i.jumpPageNum.replace(/[^0-9]/g,""),""!==i.jumpPageNum&&(i.conf.currentPage=i.jumpPageNum,i.conf.onChange&&i.conf.onChange())},i.changeItemsPerPage=function(){i.conf.rememberPerPage&&localStorage.removeItem(i.conf.rememberPerPage)},i.$watch("conf",function(e,t){t.currentPage==e.currentPage&&t.totalItems==e.totalItems&&t.itemsPerPage==e.itemsPerPage||function(){i.conf.currentPage=parseInt(i.conf.currentPage)?parseInt(i.conf.currentPage):1,i.conf.totalItems=parseInt(i.conf.totalItems),i.conf.rememberPerPage?(parseInt(localStorage[i.conf.rememberPerPage])||(localStorage[i.conf.rememberPerPage]=parseInt(i.conf.itemsPerPage)?parseInt(i.conf.itemsPerPage):15),i.conf.itemsPerPage=parseInt(localStorage[i.conf.rememberPerPage])):i.conf.itemsPerPage=parseInt(i.conf.itemsPerPage)?parseInt(i.conf.itemsPerPage):15,i.conf.numberOfPages=Math.ceil(i.conf.totalItems/i.conf.itemsPerPage),i.conf.currentPage<1&&(i.conf.currentPage=1),i.conf.currentPage>i.conf.numberOfPages&&0<i.conf.numberOfPages&&(i.conf.currentPage=i.conf.numberOfPages),i.jumpPageNum=i.conf.currentPage;for(var e,t=i.conf.perPageOptions.length,a=0;a<t;a++)i.conf.perPageOptions[a]==i.conf.itemsPerPage&&(e=!0);if(e||i.conf.perPageOptions.push(i.conf.itemsPerPage),i.conf.perPageOptions.sort(function(e,t){return e-t}),i.pageList=[],i.conf.numberOfPages<=i.conf.pagesLength)for(a=1;a<=i.conf.numberOfPages;a++)i.pageList.push(a);else{var n=(i.conf.pagesLength-1)/2;if(i.conf.currentPage<=n){for(a=1;a<=1+n;a++)i.pageList.push(a);i.pageList.push("..."),i.pageList.push(i.conf.numberOfPages)}else if(i.conf.currentPage>i.conf.numberOfPages-n){for(i.pageList.push(1),i.pageList.push("..."),a=1+n;1<=a;a--)i.pageList.push(i.conf.numberOfPages-a);i.pageList.push(i.conf.numberOfPages)}else{for(i.pageList.push(1),i.pageList.push("..."),a=Math.ceil(n/2);1<=a;a--)i.pageList.push(i.conf.currentPage-a);for(i.pageList.push(i.conf.currentPage),a=1;a<=n/2;a++)i.pageList.push(i.conf.currentPage+a);i.pageList.push("..."),i.pageList.push(i.conf.numberOfPages)}}i.$parent.conf=i.conf}()},!0)}}}]),angular.module("we7app").filter("we7IsEmpty",function(){return function(e){for(var t in e)if(e[t])return!1;return!0}}).filter("mobile",function(){return function(e){return e?e.substr(0,3)+"****"+e.substr(7,11):"还未绑定手机å·"}}),angular.module("we7app").constant("we7TypeDefault",{account:{name:"公众å·",icon:"wi wi-account"},wxapp:{name:"å°ç¨‹åº",icon:"wi wi-wxapp"},welcome:{name:"系统首页",icon:"wi wi-system-welcome"},webapp:{name:"PC",icon:"wi wi-pc"},phoneapp:{name:"APP",icon:"wi wi-app"},aliapp:{name:"支付å®å°ç¨‹åº",icon:"wi wi-aliapp"},toutiaoapp:{name:"å—节跳动å°ç¨‹åº",icon:"wi wi-toutiaoapp"},baiduapp:{name:"百度å°ç¨‹åº",icon:"wi wi-baiduapp"}}),angular.module("we7app").filter("moduleInfo",["we7TypeDefault",function(s){return function(e,t){var a=s;if(!e)return!1;if("string"==typeof e)return a[e=-1!==e.indexOf("_support")?e.replace("_support",""):e][t];if("object"==typeof e&&!e.length){var n,i=[];for(n in e)2==e[n]&&(-1!==n.indexOf("_support")&&(n=n.replace("_support","")),t?i.push(a[n][t]):i.push(a[n]));return i}}}]),angular.module("we7app").run(["$templateCache",function(e){"use strict";e.put("directive-colorpicker-colorpicker.html",'<div class="input-group"><input type="text" name="{{colorFormName}}" value="" ng-model="colorValue" class="form-control"> <span class="input-group-addon" style="width:35px; border-left:none" ng-style="{\'background-color\' : colorValue}"></span> <span class="input-group-btn"><button class="btn btn-default colorpicker" type="button">选择颜色 <i class="fa fa-caret-down"></i></button> <button class="btn btn-default colorclean" type="button"><span><i class="fa fa-remove"></i></span></button></span></div>'),e.put("directive-iconer-iconer.html",'<div class="nav-img-box" style="background-color: #2B2D30"><div class="btns"><a style="height:19px" ng-click="removeIcon()" href="javascript:;"><i class="fa fa-times"></i></a></div><div class="nav-img" ng-style="{\'background-image\': image ? \'url(\'+image+\')\' : \'\'}"><i ng-hide="menu.image" class="fa" ng-style="{\'color\' : icon.color}" ng-class="icon.name"></i></div><a href="javascript:;" ng-click="selectIcon()"><span ng-transclude></span></a></div>'),e.put("directive-iconer-nav-pills-inline.html",'<li id="li_icon" role="presentation"><a href="#icon" aria-controls="icon" role="tab" data-toggle="tab">å›¾æ ‡</a></li>'),e.put("directive-iconer-tab-content-inline.html",'<div id="icon" class="tab-pane icon form-horizontal" role="tabpanel"><div class="form-group" style="border-bottom:1px solid #e5e5e5; padding:0 0 15px 0; margin:10px 0 0 0"><label class="col-xs-3 control-label">å›¾æ ‡é¢œè‰²</label><div class="col-xs-9"><input type="color" value="" class="form-control" id="iconcolor" onchange="$(this).parents(\'#icon\').attr(\'color\', this.value);$(this).parents(\'#icon\').find(\'i\').css(\'color\', this.value)"></div></div></div>'),e.put("directive-initialsearchbar-searchbar.html",'<ul class="letters-list cut-wechat-letters"><li ng-click="searchResult(\'\')"><a href="javascript:;">ä¸é™</a></li><li ng-repeat="letter in alphabet" ng-style="{\'background-color\': letter == activeLetter ? \'#ddd\' : \'none\'}" ng-class="{\'active\': letter == activeLetter}" ng-click="searchResult(letter)"><a href="javascript:;" ng-bind="letter"></a></li></ul>'),e.put("directive-linker-cms-article-item-inline.html",'<%_.each(items, function(item) {%><tr><td><a href="#" data-cover-attachment-url="<%=item.attachment%>" title="<%=item.title%>"><%=item.title%></a></td><td><%=item.createtime%></td><td class="text-right"><button class="btn btn-default js-btn-select" js-url="./index.php?c=site&a=site&do=detail&id=<%=item.id%>&i=<%=item.uniacid%>" js-title="<%=item.title%>">选å–</button></td></tr><%});%>'),e.put("directive-linker-cms-cate-item-inline.html",'<%_.each(items, function(item) {%><tr><td colspan="2"><a href="#"><%=item.name%></a></td><td class="text-right"><a class="btn btn-default js-btn-select" js-url="./index.php?c=site&a=site&cid=<%=item.id%>&i=<%=item.uniacid%>" js-title="<%=item.name%>">选å–</a></td></tr><%_.each(item.children, function(child) {%><tr><td colspan="2" style="padding-left:50px;height:30px;line-height:30px;background-image:url(\\\'./resource/images/bg_repno.gif\\\'); background-repeat:no-repeat; background-position: -245px -540px"><a href="#"><%=child.name%></a></td><td class="text-right"><a class="btn btn-default js-btn-select" js-url="./index.php?c=site&a=site&cid=<%=child.id%>&i=<%=child.uniacid%>" js-title="<%=child.name%>">选å–</a></td></tr><%});%><%});%>'),e.put("directive-linker-cms-content-inline.html",'<div class="tab-content"><div id="articlelist" class="tab-pane active" role="tabpanel"><table class="table table-hover"><thead class="navbar-inner"><tr><th style="width:40%">æ ‡é¢˜</th><th style="width:30%">创建时间</th><th style="width:30%; text-align:right"><div class="input-group input-group-sm"><input type="text" class="form-control article-list-input"> <span class="input-group-btn"><button class="btn btn-default" type="button"><i class="fa fa-search"></i></button></span></div></th></tr></thead><tbody></tbody></table><div id="pager" style="text-align:center"></div></div><div id="category" class="tab-pane" role="tabpanel"><table class="table table-hover"><thead class="navbar-inner"><tr><th style="width:40%">æ ‡é¢˜</th><th style="width:30%">创建时间</th><th style="width:30%; text-align:right"><div class="input-group input-group-sm"><input type="text" class="form-control category-list-input"> <span class="input-group-btn"><button class="btn btn-default" type="button"><i class="fa fa-search"></i></button></span></div></th></tr></thead><tbody></tbody></table><div id="pager" style="text-align:center"></div></div></div>'),e.put("directive-linker-cms-header-inline.html",'<ul role="tablist" class="nav nav-pills" style="font-size:14px; margin-top:-20px"><li role="presentation" class="active" id="li_goodslist"><a data-toggle="tab" role="tab" aria-controls="articlelist" href="#articlelist">æ–‡ç« </a></li><li role="presentation" class="" id="li_category"><a data-toggle="tab" role="tab" aria-controls="category" href="#category">分类</a></li></ul>'),e.put("directive-linker-linker.html",'<div class="dropdown link"><div class="input-group"><input type="text" value="" placeholder="链接地å€:http://example.com" ng-model="url" class="form-control"> <span class="input-group-btn"><button class="btn btn-default" type="button" onclick="">选择链接 <i class="fa fa-caret-down"></i></button></span></div><ul class="dropdown-menu" role="menu" style="left: 0; right:0"><li><a href="javascript:;" ng-click="searchSystemLinker()">系统èœå•</a></li><li><a href="javascript:;" ng-click="searchPageLinker()">微页é¢</a></li><li><a href="javascript:;" ng-click="searchCmsLinker()">æ–‡ç« åŠåˆ†ç±»</a></li><li><a href="javascript:;" ng-click="searchNewsLinker()">图文回å¤</a></li><li><a href="javascript:;" ng-click="searchMapPosLinker()">一键导航</a></li><li><a href="javascript:;" ng-click="addTelLinker()">一键拨å·</a></li></ul></div>'),e.put("directive-linker-map-content-inline.html",'<div class="model-dialog"><div class="model-content"><div class="modal-header"><h4 class="modal-title" id="myModalLabel">一键导航</h4></div><div class="modal-body"><form action="" class="form-horizontal" role="form" enctype="multipart/form-data"><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 col-lg-2 control-label"><span style="font-size:16px">æ ‡é¢˜</span></label><div class="col-sm-9 col-xs-12"><input type="text" id="navtitle" class="form-control" name="navtitle" value=""></div></div><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 col-lg-2 control-label"><span style="font-size:16px">地ç†ä½ç½®</span></label><div class="col-sm-9 col-xs-12"><div class="row row-fix"><div class="col-xs-4 col-sm-4"><input type="text" name="navtitle[lng]" id="navlng" value="" placeholder="地ç†ç»åº¦" class="form-control"></div><div class="col-xs-4 col-sm-4"><input type="text" name="navtitle[lat]" id="navlat" value="" placeholder="地ç†çº¬åº¦" class="form-control"></div><div class="col-xs-4 col-sm-4"><button onclick="showCoordinate(this)" class="btn btn-default" type="button">选择åæ ‡</button></div></div><script type="text/javascript">function showCoordinate(elm) {\r\n\t\t\t\t\tvar val = {};\r\n\t\t\t\t\tval.lng = parseFloat($(elm).parent().prev().prev().find(":text").val());\r\n\t\t\t\t\tval.lat = parseFloat($(elm).parent().prev().find(":text").val());\r\n\t\t\t\t\tutil.qqmap(val, function(r){\r\n\t\t\t\t\t\t$(elm).parent().prev().prev().find(":text").val(r.lng);\r\n\t\t\t\t\t\t$(elm).parent().prev().find(":text").val(r.lat);\r\n\t\t\t\t\t});\r\n\t\t\t\t};<\/script></div></div></form></div></div><div class="modal-footer"><button type="button" class="btn btn-default" data-dismiss="modal" id="getnav">确定</button></div></div>'),e.put("directive-linker-news-content-inline.html",'<div id="newslist" class="tab-pane active" role="tabpanel"><table class="table table-hover"><thead class="navbar-inner"><tr><th style="width:40%">æ ‡é¢˜</th><th style="width:30%">创建时间</th><th style="width:30%; text-align:right"><div class="input-group input-group-sm"><input type="text" class="form-control news-list-input"> <span class="input-group-btn"><button class="btn btn-default" type="button"><i class="fa fa-search"></i></button></span></div></th></tr></thead><tbody></tbody></table><div id="pager" style="text-align:center"></div></div>'),e.put("directive-linker-news-item-inline.html",'<%_.each(items, function(item) {%><tr><td><a href="#" data-cover-attachment-url="<%=item.attachment%>" title="<%=item.title%>"><%=item.title%></a></td><td><%=item.createtime%></td><td class="text-right"><button class="btn btn-default js-btn-select" js-url="<%=item.url%>" js-title="<%=item.title%>">选å–</button></td></tr><%});%>'),e.put("directive-linker-page-content-inline.html",'<div id="pageList" class="tab-pane active" role="tabpanel"><table class="table table-hover"><thead class="navbar-inner"><tr><th style="width:40%">å称</th><th style="width:30%">创建间</th><th style="width:30%; text-align:right"><div class="input-group input-group-sm"><input type="text" class="form-control page-list-input"> <span class="input-group-btn"><button class="btn btn-default" type="button"><i class="fa fa-search"></i></button></span></div></th></tr></thead><tbody></tbody></table><div id="pager" style="text-align:center"></div></div>'),e.put("directive-linker-page-item-inline.html",'<%_.each(items, function(item) {%><tr><td><a href="#" title="<%=item.title%>"><%=item.title%></a></td><td><%=item.createtime%></td><td class="text-right"><button class="btn btn-default js-btn-select" js-url="./index.php?i=<%=item.uniacid%>&c=home&a=page&id=<%=item.id%>" js-title="<%=item.title%>">选å–</button></td></tr><%});%>'),e.put("directive-linker-tel-content-inline.html",'<div class="" id="telphone-modal"><div class="form-group list-group-item clearfix"><label style="margin-top:5px" class="col-xs-12 col-sm-2 col-md-2 control-label">å·ç </label><div class="col-sm-6"><input type="text" value="" id="telphone" name="telphone" class="form-control"></div><div class="col-sm-4"><a class="btn btn-primary" href="javascript:;">确定</a></div></div></div>'),e.put("directive-modal_account-modal_account.html",'<ng-transclude></ng-transclude><div class="modal fade modal-account" tabindex="-1" role="dialog"><div class="modal-dialog" role="document"><div class="modal-content"><div class="modal-header clearfix"><h4 class="text-over">{{title || \'系统æ示\'}}</h4><div class="type"><a href="javascript:;" ng-click="tabChange(\'account\')" ng-if="type != 3" ng-class="{\'active\': showType == \'account\'}">è´¦å·æƒé™ç»„</a> <a href="javascript:;" ng-click="tabChange(\'number\')" ng-if="type != 2" ng-class="{\'active\': showType == \'number\'}">é™„åŠ è´¦å·</a></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button></div><div class="modal-body"><div class="" ng-if="showType == \'account\'"><div class="search-box"><div class="search-form"><div class="input-group"><input class="form-control" name="keyword" type="text" ng-model="$parent.module_keyword" autocomplete="false"> <span class="input-group-btn" ng-click="loadMore(1)"><button class="btn btn-default"><i class="fa fa-search"></i></button></span></div></div></div><div class="account-list"><div class="item" ng-repeat="group in groups" ng-class="{active: group.checked == 1}" ng-click="check(group)"><div class="title">{{group.group_name}}</div><div class="type-list"><div class="type-item" ng-repeat="(key, type) in we7TypeDefault" ng-if="group.hasOwnProperty(\'max\' + key)"><div ng-show="group[\'max\' + key] > 0"><i class="{{type.icon}}"></i> {{group[\'max\' + key]}}</div></div></div><div class="mark"><i class="wi wi-right"></i></div></div></div><div class="js-pager"><div class="checkAll pull-left we7-form" ng-if="multiple"><input type="checkbox" id="{{\'select-group-all\' + time}}" ng-model="$parent.$parent.checkAllStatus" ng-change="checkAll()"><label for="{{\'select-group-all\' + time}}">全选</label></div><ul ng-if="totalPage > 1" class="pagination"><li ng-if="pageindex != 1"><a href="javascript:;" page="1" ng-click="loadMore(1)">首页</a></li><li ng-repeat="(i, page) in pageList" ng-class="{active: page == pageindex}"><a href="javascript:;" page="page" ng-click="loadMore(page)">{{page}}</a></li><li ng-if="pageindex != totalPage"><a href="javascript:;" page="totalPage" ng-click="loadMore(totalPage)">尾页</a></li></ul></div></div><div class="account-form we7-form" ng-if="showType == \'number\'"><div class="form-group"><label for="" class="control-label col-sm-2">创建账å·ä¸ªæ•°</label><div class="form-controls col-sm-10"><div class="we7-account-num-box"><div class="item" ng-repeat="(key, type) in we7TypeDefault" ng-if="numberList.hasOwnProperty(\'max\' + key)" ng-if="key != \'welcome\'"><div class="name"><i ng-class="type.icon"></i>{{type.name}}</div><input type="text" ng-model="numberList[\'max\' + key]" required class="form-control"></div></div><span class="help-block">é™åˆ¶å„å¹³å°è´¦å·çš„创建数é‡ï¼Œä¸º0则ä¸å…è®¸æ·»åŠ ã€‚</span></div></div></div></div><div class="modal-footer"><button type="button" class="btn btn-primary" ng-click="ngConfirm()">确定</button> <button type="button" class="btn btn-default" data-dismiss="modal">å–消</button></div></div></div></div>'),e.put("directive-modal_account_list-modal_account_list.html",'<ng-transclude></ng-transclude><div class="modal fade modal-app" tabindex="-1" role="dialog"><div class="modal-dialog" role="document"><div class="modal-content"><div class="modal-header clearfix"><h4 class="text-over">{{title || \'系统æ示\'}}</h4><div class="type"></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button></div><div class="modal-body"><div class="search-box"><div class="input-group search-form"><input class="form-control" name="keyword" type="text" ng-model="module_keyword" autocomplete="false"> <span class="input-group-btn" ng-click="loadMore(1)"><button class="btn btn-default"><i class="fa fa-search"></i></button></span></div></div><div class="modal-app-list"><div class="modal-item" ng-repeat="item in modules" ng-class="{\'active\': item.checked == 1}" ng-click="itemCheck(item)"><div class="logo"><img ng-src="{{item.logo}}" class="account-logo" alt=""><div class="mark"><i class="wi wi-right"></i></div></div><div class="name text-over"><i class="{{we7TypeDefault[item.type_sign][\'icon\']}}"></i>{{item.name}}</div></div></div><div class="js-pager"><div class="form-group pull-left"><input type="checkbox" id="select-app-all" ng-model="checkAllStatus" ng-change="checkAll()"><label for="select-app-all">全选</label></div><ul ng-if="totalPage > 1" class="pagination"><li ng-if="pageindex != 1"><a href="javascript:;" page="1" ng-click="loadMore(1)">首页</a></li><li ng-repeat="(i, page) in pageList" ng-class="{active: page == pageindex}"><a href="javascript:;" page="page" ng-click="loadMore(page)">{{page}}</a></li><li ng-if="pageindex != totalPage"><a href="javascript:;" page="totalPage" ng-click="loadMore(totalPage)">尾页</a></li></ul></div></div><div class="modal-footer"><button type="button" class="btn btn-primary" ng-click="ngConfirm()">确定</button> <button type="button" class="btn btn-default" data-dismiss="modal">å–消</button></div></div></div></div>'),e.put("directive-modal_app-modal_app.html",'<ng-transclude></ng-transclude><div class="modal fade modal-app" tabindex="-1" role="dialog"><div class="modal-dialog" role="document"><div class="modal-content"><div class="modal-header clearfix"><h3 class="modal-title text-over">{{title || \'系统æ示\'}}</h3><div class="type"><a href="javascript:;" ng-click="tabChange(\'group\')" ng-if="modalType != 1" ng-class="{\'active\': showType == \'group\'}">应用组</a> <a href="javascript:;" ng-click="tabChange(\'app\')" ng-if="modalType != 3 && appList" ng-class="{\'active\': showType == \'app\'}">应用</a> <a href="javascript:;" ng-click="tabChange(\'template\')" ng-if="modalType != 3 && !(templateList | we7IsEmpty)" ng-class="{\'active\': showType == \'template\'}">模æ¿</a></div><a class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></a></div><div class="modal-body"><div class="search-box"><select class="we7-margin-right" ng-model="$parent.moduleType" ng-change="loadMore(1)" ng-if="showType == \'app\'"><option value="">全部</option><option value="{{key + \'_support\'}}" ng-repeat="(key,value) in typeList">{{value.name}}</option></select><div class="search-form"><div class="input-group"><input class="form-control" name="keyword" type="text" ng-model="module_keyword" autocomplete="false"> <span class="input-group-btn" ng-click="loadMore(1)"><a class="btn btn-default"><i class="wi wi-search"></i></a></span></div></div></div><div class="modal-app-list" ng-if="showType == \'app\'"><div class="modal-item" title="{{item.title}}" ng-repeat="item in modules" ng-class="{\'active\': item.checked == 1}" ng-click="itemCheck(item)"><div class="logo"><img ng-src="{{item.logo}}" alt=""><div class="mark"><i class="wi wi-right"></i></div></div><div class="name text-over" title="{{item.title}}"><i class="{{item.support | moduleInfo:\'icon\'}}"></i>{{item.title}}</div></div></div><div class="modal-app-list template" ng-if="showType == \'template\'"><div class="modal-item" ng-repeat="item in modules" ng-class="{\'active\': item.checked == 1}" ng-click="itemCheck(item)"><div class="logo"><img src="{{item.logo || \'\'}}" alt=""><div class="mark"><i class="wi wi-right"></i></div></div><div class="name text-over">{{item.title}}</div></div></div><div class="modal-app-list groups" ng-if="showType == \'group\'"><div class="modal-group-item" ng-repeat="item in modules" ng-class="{\'active\': item.checked == 1}" ng-click="itemCheck(item)"><div class="group-header">{{item.name}}</div><div class="group-modules"><div class="module" ng-repeat="module in item.modules_all"><div class="logo"><img ng-src="{{module.logo || \'\'}}" class="module-img" alt=""></div><div class="info"><div class="name text-over">{{module.title}}</div><div class="support"><i ng-repeat="icon in module.group_support | moduleInfo:\'icon\'" class="{{icon}}"></i></div></div></div><div class="module" ng-repeat="module in item.templates"><div class="logo"><img ng-src="{{module.logo || \'\'}}" class="template-img" alt=""></div><div class="info"><div class="name text-over">{{module.title}}</div><div class="support"><i class="wi wi-template"></i></div></div></div></div><div class="mark"><i class="wi wi-right"></i></div></div></div><div class="js-pager"><div class="checkAll pull-left we7-form" ng-if="multiple"><input type="checkbox" id="{{\'select-app-all\' + time}}" ng-model="checkAllStatus.checkAllStatus" ng-change="checkAll()"><label for="{{\'select-app-all\' + time}}">全选</label></div><ul ng-if="totalPage > 1" class="pagination"><li ng-if="pageindex != 1"><a href="javascript:;" page="1" ng-click="loadMore(1)">首页</a></li><li ng-repeat="(i, page) in pageList" ng-class="{active: page == pageindex}"><a href="javascript:;" page="page" ng-click="loadMore(page)">{{page}}</a></li><li ng-if="pageindex != totalPage"><a href="javascript:;" page="totalPage" ng-click="loadMore(totalPage)">尾页</a></li></ul></div></div><div class="modal-footer"><button type="button" class="btn btn-primary" ng-click="ngConfirm()">确定</button> <button type="button" class="btn btn-default" data-dismiss="modal">å–消</button></div></div></div></div>'),e.put("directive-modal_form-modal_form.html",'<a href="javascript:;" ng-click="showModal()">{{text ? text : \'修改\'}}</a><div class="modal fade modal-form" tabindex="-1" role="dialog"><div class="modal-dialog" role="document"><div class="modal-content"><div class="modal-header clearfix"><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button><h4>修改{{label}}{{formType}}</h4></div><div class="modal-body marbot0 we7-form" ng-switch="type"><div class="form-group marbot0" style="margin-bottom: 0" ng-switch-when="select"><label class="col-sm-2 control-label">{{label}}</label><div class="col-sm-10" ng-if="options.length"><select ng-model="$parent.$parent.formValue" ng-options="x[key] for x in options"></select></div><div class="col-sm-10" ng-if="!options.length"><select ng-model="$parent.$parent.formValue"><option ng-repeat="(x, y) in options" value="{{x}}">{{y}}</option></select></div></div><div class="form-group marbot0" style="margin-bottom: 0" ng-switch-when="textarea"><label class="col-sm-2 control-label">{{label}}</label><div class="col-sm-10"><textarea class="form-control" rows="{{formRows}}" ng-name="{{name}}" ng-model="$parent.formValue" autocomplete="off"></textarea><span class="help-block" ng-if="help">{{help}}</span></div></div><div class="form-group marbot0" style="margin-bottom: 0" ng-switch-default><label class="col-sm-2 control-label">{{label}}</label><div class="col-sm-10"><input type="text" class="form-control" ng-name="{{name}}" ng-model="$parent.formValue" autocomplete="off"> <span class="help-block" ng-if="help">{{help}}</span></div></div></div><div class="modal-footer"><button type="button" class="btn btn-primary" ng-click="ngConfirm()">确定</button> <button type="button" class="btn btn-default" data-dismiss="modal">å–消</button></div></div></div></div>'),e.put("directive-modal_type-modal_type.html",'<ng-transclude></ng-transclude><div class="modal fade modal-type" tabindex="-1" role="dialog"><div class="modal-dialog" role="document"><div class="modal-content"><div class="modal-header clearfix"><h4 class="text-over">{{title || \'é€‰æ‹©åˆ é™¤åº”ç”¨çš„ç±»åž‹\'}}</h4><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button></div><div class="modal-body"><div class="type-list"><div class="item" ng-repeat="value in list" ng-click="check(value)" ng-class="{active: checkArray[value]}"><i class="{{value | moduleInfo:\'icon\'}}"></i><div class="name">{{value | moduleInfo:\'name\'}}</div><div class="mark"><i class="wi wi-right"></i></div></div></div></div><div class="modal-footer"><button type="button" class="btn btn-primary" ng-click="ngConfirm()">确定</button> <button type="button" class="btn btn-default" data-dismiss="modal">å–消</button></div></div></div></div>'),e.put("fans-tag-selector.html",'<div style="text-align:left" class="modal fade {{modalClass}}" tabindex="-1" role="dialog" aria-labelledby="myModalLabel"><div class="modal-dialog" role="document"><div class="modal-content"><div class="modal-header"><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button><h4 class="modal-title" id="myModalLabel">勾选粉ä¸æ ‡ç¾ï¼ˆæ¯ä¸ªç²‰ä¸æœ€å¤š3ä¸ªæ ‡ç¾ï¼‰</h4></div><div class="modal-body row"><label class="checkbox-inline col-md-3" style="margin-left:0px" ng-repeat="tag in tags" ng-click="checkMaxNumb($event)"><input type="checkbox" value="{{tag.id}}" ng-model="selectTags[tag.id]"> {{tag.name}}</label></div><div class="modal-footer"><button type="button" class="btn btn-default" data-dismiss="modal">å–消</button> <button type="button" class="btn btn-primary" ng-click="tagSubmit($event)" data-dismiss="modal">确定</button></div></div></div></div>'),e.put("directive-basic-basic.html",'<div class="modal-dialog" ng-controller="we7resource-basic-controller"><div class="modal-content"><div class="modal-header"><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button><h4 class="modal-title" id="myModalLabel">æ–‡å—</h4></div><div class="modal-body material-content clearfix"><div id="basic" class="material-body we7-form"><textarea id="basictext" rows="10" class="form-control" placeholder="文本输入"></textarea><div class="input-emoji"><a href="javascript:;" class="emoji-triggers" ng-click="emoji()"><span class="fa fa-github-alt"></span>选择表情</a> <a href="javascript:;" class="emotion-triggers" title="æ·»åŠ è¡¨æƒ…" ng-click="emotion()"><span class="fa fa-github-alt"></span>选择Emoji</a> <a href="javascript:;" class="link-triggers" title="æ’入链接" ng-click="showLink()"><span class="wi wi-link"></span>æ’入链接</a></div><div class="modal-content" ng-show="linkStatus" style="position: absolute; width: 600px"><div class="modal-body"><div class="we7-padding"><div class="form-group"><label class="col-sm-2 control-label">显示文å—</label><div class="col-sm-10"><input type="text" class="form-control" ng-model="link.text" autocomplete="off"></div></div><div class="form-group" style="margin-bottom: 0"><label class="col-sm-2 control-label">跳转链接</label><div class="col-sm-10"><input type="text" class="form-control" ng-model="link.url" autocomplete="off"></div></div></div></div><div class="modal-footer"><button type="button" class="btn btn-primary" ng-disabled="!link.url" ng-click="changeLink()">确定</button> <button type="button" class="btn btn-default" ng-click="showLink()">å–消</button></div></div></div></div><div class="modal-footer"><button type="button" class="btn btn-primary" ng-click="ok()">确定</button> <button type="button" class="btn btn-default" data-dismiss="modal">å–消</button></div></div></div>'),e.put("directive-icon-icon.html",'<div class="modal-dialog modal-lg modal-material" ng-controller="we7resource-icon-controller"><div class="modal-content"><div class="modal-header"><h4 class="modal-title" id="myModalLabel2">å›¾æ ‡</h4><div class="material-nav"><a href="javascript:;" ng-click="setIndex(0)" ng-class="{true:\'active\',false:\'\'}[index==0]">Web Icons</a> <a href="javascript:;" ng-click="setIndex(1)" ng-class="{true:\'active\',false:\'\'}[index==1]">File Type Icons</a> <a href="javascript:;" ng-click="setIndex(2)" ng-class="{true:\'active\',false:\'\'}[index==2]">Spinner Icons</a> <a href="javascript:;" ng-click="setIndex(3)" ng-class="{true:\'active\',false:\'\'}[index==3]">Form Control Icons</a> <a href="javascript:;" ng-click="setIndex(4)" ng-class="{true:\'active\',false:\'\'}[index==4]">Currency Icons</a> <a href="javascript:;" ng-click="setIndex(5)" ng-class="{true:\'active\',false:\'\'}[index==5]">Text Editor Icons</a> <a href="javascript:;" ng-click="setIndex(6)" ng-class="{true:\'active\',false:\'\'}[index==6]">Directional Icons</a> <a href="javascript:;" ng-click="setIndex(7)" ng-class="{true:\'active\',false:\'\'}[index==7]">Video Player Icons</a> <a href="javascript:;" ng-click="setIndex(8)" ng-class="{true:\'active\',false:\'\'}[index==8]">Brand Icons</a> <a href="javascript:;" ng-click="setIndex(9)" ng-class="{true:\'active\',false:\'\'}[index==9]">Medical Icons</a> <a href="javascript:;" id="we7colorpicker">颜色选择</a></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button></div><div class="modal-body material-content clearfix"><div class="material-body"><div class="row"><div class="col-sm-2" ng-repeat="(index, value) in icons()" ng-click="itemClick(value)"><div class="item" ng-class="{true:\'active\',false:\'\'}[index == selectIndex]"><i class="fa {{value}}" style="color: {{color}};font-size: 48px;position:relative; top:-15px; margin: 0"></i><div class="name">{{value}}</div><div class="mask"><span class="wi wi-right"></span></div></div></div></div></div><div class="material-pager text-right"></div></div><div class="modal-footer"><button type="button" class="btn btn-primary" ng-show="multiple">确定</button> <button type="button" class="btn btn-default" data-dismiss="modal">å–消</button></div></div></div>'),e.put("directive-images-images.html",'<div class="modal-dialog modal-lg modal-material" ng-controller="we7resource-image-controller"><div class="modal-content"><div class="modal-header"><h4 class="modal-title" id="myModalLabel1">图片</h4><div class="material-nav"></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button></div><div class="modal-body material-content clearfix"><div class="material-nav"><a href="javascript:;" ng-click="setIndex(0)" ng-show="showWx()" ng-class="{true:\'active\',false:\'\'}[index==0]">{{ config.typeName }}</a> <a href="javascript:;" ng-click="setIndex(1)" ng-show="showLocal()" ng-class="{true:\'active\',false:\'\'}[index==1]">本地æœåŠ¡å™¨</a> <a href="javascript:;" ng-click="setIndex(2)" ng-class="{true:\'active\',false:\'\'}[index==2]">æå–网络图片</a></div><div id="image" class="material-body" ng-show="index!=2"><div class="category"><div class="category-menu panel-group" id="category-menu" role="tablist" aria-multiselectable="true"><ul><li ng-click="loadAll()" ng-class="{true : \'active\', false : \'\'}[groupid == -1]"><div class="name">全部图片</div><a class="edit"></a></li><li ng-click="loadNoGroup()" ng-class="{true : \'active\', false : \'\'}[groupid == 0]"><div class="name">未分组</div><a href="javascript:;" class="edit"></a></li><li ng-repeat="(key, value) in groups" ng-class="{active: groupid == value.id, \'show-sub\' : showSubGroups[value.id]}"><div class="caret-box" ng-click="showSubGroups[value.id] = !showSubGroups[value.id];$event.stopPropagation();" ng-if="value.sub_group && !(value.sub_group | we7IsEmpty)"><span class="caret"></span></div><div class="name" ng-click="loadImages(value)">{{value.name}} <span class="setting js-show-action group" data-action-id="{{value.id}}" v-show="!value.editable && !value.editing" ng-click="showGroupAction($event, value)"><i class="js-show-del"></i> <i class="wi wi-more"></i></span></div><ul><li ng-repeat="(sub_key, sub_value) in value.sub_group" ng-class="{true : \'active\', false : \'\'}[groupid == sub_value.id]"><div class="name" ng-click="loadImages(sub_value)">{{sub_value.name}} <span class="setting js-show-action group" data-action-id="{{sub_value.id}}" ng-click="showGroupAction($event, sub_value)"><i class="js-show-del"></i> <i class="wi wi-more"></i></span></div></li></ul></li></ul></div><div class="category-add"><a href="javascript:;" ng-click="showRenameGroup($event)">新建分组</a></div></div><div class="image-box"><div class="material-head"><div class="search-box" role="form"><div class="input-group we7-margin-right-sm" style="width: 250px"><input class="form-control" ng-model="keyword" type="text" placeholder="请输入图片å称"> <span class="input-group-btn" ng-click="search()"><button class="btn btn-default"><i class="fa fa-search"></i></button></span></div><select name="" id="" class="we7-margin-right-sm" ng-change="search()" ng-model="order"><option value="asc">ä¸Šä¼ æ—¶é—´æ£åº</option><option value="desc">ä¸Šä¼ æ—¶é—´å€’åº</option><option value="filename_asc">å称æ£åº</option><option value="filename_desc">å称倒åº</option></select><div class="search-form"></div><div ng-show="index<2"><we7-uploader-btn upload-url="uploadurl" concurrency="1" on-upload-start="onUploadStart(files)" on-uploaded="uploaded()" on-progress="onprogress(file, progress)" on-upload-error="uploaderror(mes)" multiple name="uploadname" accept="accept"></we7-uploader-btn></div></div></div><div class="img-container we7-flex"><div ng-if="files.length == 0 && images.length == 0" class="color-gray font-lg text-center we7-margin we7-padding">æš‚æ— ç›¸å…³å›¾ç‰‡</div><div class="item" ng-repeat="(key, value) in files" ng-show="loading" style="background-image: url(\'{{value.res && value.res.url}}\')"><div class="name text-over">{{value.name}}</div><div class="progress"><div class="progress-bar" role="progressbar" aria-valuenow="60" aria-valuemin="0" aria-valuemax="100" style="width: {{value.progress}}%"></div></div></div><div class="item" ng-class="{true:\'active\',false:\'\'}[value.selected]" ng-repeat="(key, value) in images" ng-click="itemClick(value)" style="background-image: {{getImage(value)}}"><div class="check" data-check-id="{{value.id}}" ng-class="{checked: value.selected}"><i class="wi wi-right"></i></div><div class="action js-show-action" data-action-id="{{value.id}}" ng-click="showAction($event, value)"><i class="js-show-del"></i> <i class="wi wi-checking"></i></div><div class="name">{{value.filename}}</div></div></div><div class="material-pager text-right"><div class="we7-form form-inline selected-all"><input type="checkbox" id="selected-all" ng-model="selectedAllImage" ng-change="selectedAll(selectedAllImage)"><label for="selected-all">全选</label></div><div class="search-pager-aciton" ng-show="index < 2"><a href="javascript:;" class="color-default js-show-del" ng-disabled="getSelectedKeys().length == 0" ng-if="index==0 || role != \'operator\'" ng-click="showMove($event)">移动</a> <a href="javascript:;" class="color-red has-popover js-show-del" ng-click="showDel($event)" ng-disabled="getSelectedKeys().length == 0" ng-if="index==0 || role != \'operator\'">åˆ é™¤</a></div><div class="page-box"><we7-page conf="page" style="display: block; line-height: 1"></we7-page></div><div class="search-page we7-form" ng-show="maxPage > 1"><input type="number" min="1" ng-max="maxPage" ng-model="goPage" class="form-control"> <a href="javascript:;" ng-click="setCurrentPage(goPage)">跳转</a></div></div></div></div><div class="img-net text-center" ng-show="index==2"><form action="" method="get" class="we7-form"><img class="img" src="{{netWorkurl}}" alt=""><div class="color-gray">输入图片链接</div><input type="text" class="form-control text-center" placeholder="图片链接" ng-model="netWorkurl"><div><button class="btn btn-default" type="button" ng-click="fetchNetwork()">转化</button></div></form></div></div><div class="modal-footer"><button type="button" class="btn btn-primary" ng-click="ok()">确定</button> <button type="button" class="btn btn-default" data-dismiss="modal">å–消</button></div></div></div>'),e.put("directive-keyword-keyword.html",'<div class="modal-dialog modal-lg" ng-controller="we7resource-keyword-controller"><div class="modal-content"><div class="modal-header"><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button><h4 class="modal-title" id="myModalLabel">关键å—</h4></div><div class="modal-body material-content clearfix"><div class="material-head"><form action="" method="get" class="form-horizontal clearfix form-inline" role="form" onsubmit="return false"><div class="input-group pull-left"><input type="text" name="keyword" id="" ng-model="keyword" class="form-control" placeholder="æœç´¢å…³é”®å—"> <span class="input-group-btn" ng-click="search()"><button type="button" class="btn btn-default"><i class="wi wi-search"></i></button></span></div><div class="pull-right"><a href="./index.php?c=platform&a=reply&do=post&m=keyword" target="_blank" class="btn btn-primary">新建关键å—</a></div></form></div><div id="keyword" class="material-body"><div class="row"><div class="col-sm-2" ng-repeat="(key, value) in keywords" ng-click="itemClick(value)"><div class="item" ng-class="{true:\'active\',false:\'\'}[value.selected]"><a><span>{{value.content}}</span></a><div class="mask"><span class="wi wi-right"></span></div></div></div></div></div><div class="material-pager text-right" ng-bind-html="pager"></div></div><div class="modal-footer"><button type="button" class="btn btn-primary" ng-show="multiple">确定</button> <button type="button" class="btn btn-default" data-dismiss="modal">å–消</button></div></div></div>'),e.put("directive-module-module.html",'<div class="modal-dialog modal-lg" ng-controller="we7resource-module-controller"><div class="modal-content"><div class="modal-header"><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button><h4 class="modal-title" id="myModalLabel2">应用</h4></div><div class="modal-body material-content clearfix"><div class="material-head"><form action="" method="get" class="form-horizontal clearfix form-inline" role="form" onsubmit="return false"><div class="input-group pull-left"><input type="text" name="keyword" id="" ng-model="keyword" class="form-control" placeholder="æœç´¢å…³é”®å—"> <span class="input-group-btn"><button type="button" class="btn btn-default"><i class="wi wi-search"></i></button></span></div></form></div><div id="module" class="material-body"><div class="row"><a style="display: inline-block" title="{{value.title}}" class="col-sm-2" ng-repeat="(key, value) in modules | filter:keyword" ng-click="itemClick(value)"><div class="item" ng-class="{true:\'active\',false:\'\'}[value.selected]"><img ng-src="{{value.logo}}" alt="{{value.title}}" title="{{value.title}}" class="icon" onerror="this.src=\'./resource/images/nopic-107.png\'"><div class="name">{{value.title}}</div><div class="mask"><span class="wi wi-right"></span></div></div></a></div></div><div class="material-pager text-right"></div></div><div class="modal-footer"><button type="button" class="btn btn-primary" ng-show="multiple" ng-click="ok()">确定</button> <button type="button" class="btn btn-default" data-dismiss="modal">å–消</button></div></div></div>'),e.put("directive-music-music.html",'<div class="modal-dialog modal-lg modal-material" ng-controller="we7resource-music-controller"><div class="modal-content"><we7-resource-musicform ng-show="showMusicForm" doselect="selectVoice()" musicname="musicname" musicurl="musicurl"></we7-resource-musicform><we7-resource-voice ng-show="!showMusicForm" is-wechat="false" show-type="2" doselect="selectVoice()"></we7-resource-voice></div></div>'),e.put("directive-news-news.html",'<div class="modal-dialog modal-lg modal-material" ng-controller="we7resource-news-controller"><div class="modal-content"><div class="modal-header"><h4 class="modal-title" id="myModalLabel5">图文</h4><div class="material-nav"><a href="javascript:;" ng-class="{true:\'active\',false:\'\'}[index==0]" ng-show="showWx()" ng-click="setIndex(0)">å¹³å°</a> <a href="javascript:;" ng-show="showLocal()" ng-class="{true:\'active\',false:\'\'}[index==1]" ng-click="setIndex(1)">本地æœåŠ¡å™¨</a></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button></div><div class="modal-body material-content clearfix"><div class="material-head"><form action="" method="get" class="form-horizontal clearfix form-inline" role="form" onsubmit="return false"><div class="input-group pull-left" ng-show="index == 1"><input type="text" name="keyword" ng-model="keyword" class="form-control" placeholder="æ ‡é¢˜/作者/摘è¦"> <span class="input-group-btn" ng-click="search()"><button type="button" href="javascript:;" class="btn btn-default"><i class="wi wi-search"></i></button></span></div><div class="pull-right"><a href="./index.php?c=platform&a=material-post&&new_type=reply" class="btn btn-primary">新建图文</a></div></form></div><div id="news" class="material-body"><div class="row"><div class="col-sm-4" ng-repeat="(key, value) in news" ng-click="itemClick(value)"><div class="material-appmsg-item multi item" ng-class="{true:\'active\',false:\'\'}[value.selected]"><div class="appmsg-content"><div class="appmsg-info"><em class="appmsg-date">{{ timeToDate(value.createtime) | date:\'yyyy-MM-dd\' }}</em></div><div ng-repeat="(childkey, child) in value.items"><div class="cover-appmsg-item" ng-if="$index==0"><h4 class="appmsg-title"><a href="#" target="_blank">{{child.title}}</a></h4><div class="appmsg-thumb" style="background-image: url(\'{{child.thumb_url}}\')"></div><p class="appmsg-desc">{{child.content}}</p></div><div class="appmsg-item" ng-if="$index>0"><div class="appmsg-thumb" style="background-image: url(\'{{child.thumb_url}}\')"></div><h4 class="appmsg-title"><a href="#" target="_blank">{{child.title}}</a></h4></div></div></div><div class="mask"><span class="wi wi-right"></span></div><div class="del" ng-click="delItem(value,$event)"><span class="wi wi-delete2"></span></div></div></div></div></div><div class="material-pager text-right" ng-bind-html="pager"></div></div><div class="modal-footer"><button type="button" class="btn btn-primary" ng-show="multiple">确定</button> <button type="button" class="btn btn-default" data-dismiss="modal">å–消</button></div></div></div>'),e.put("directive-video-video.html",'<div class="modal-dialog modal-lg modal-material" ng-controller="we7resource-video-controller"><div class="modal-content"><div class="modal-header"><h4 class="modal-title" id="myModalLabel3">视频</h4><div class="material-nav"><a href="javascript:;" ng-class="{true:\'active\',false:\'\'}[index == 0]" ng-show="showWx()" ng-click="setIndex(0)">微信</a> <a href="javascript:;" ng-class="{true:\'active\',false:\'\'}[index == 1]" ng-show="showLocal()" ng-click="setIndex(1)">本地æœåŠ¡å™¨</a> <a href="javascript:;" ng-show="showNetWork()" ng-click="setIndex(2)" ng-class="{true:\'active\',false:\'\'}[index==2]">æå–网络视频</a></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button></div><div class="modal-body material-content clearfix"><div class="material-head" ng-show="index!=2"><div class="search-box" role="form"><div class="input-group we7-margin-right-sm" style="width: 250px"><input class="form-control" ng-model="keyword" type="text" placeholder="请输入图片å称"> <span class="input-group-btn" ng-click="search()"><button class="btn btn-default"><i class="fa fa-search"></i></button></span></div><select name="" id="" class="we7-margin-right-sm" ng-change="search()" ng-model="order"><option value="asc">ä¸Šä¼ æ—¶é—´æ£åº</option><option value="desc">ä¸Šä¼ æ—¶é—´å€’åº</option><option value="filename_asc">å称æ£åº</option><option value="filename_desc">å称倒åº</option></select><div class="search-form"></div><div><we7-uploader-btn upload-url="uploadurl" on-uploaded="uploaded()" on-upload-error="uploaderror(mes)" multiple name="uploadname" accept="accept"></we7-uploader-btn></div></div></div><div id="video" class="material-body" ng-show="index!=2"><div class="row"><div class="col-sm-3" ng-repeat="(key, value) in videos" ng-click="itemClick(value)"><div class="item" ng-class="{true:\'active\',false:\'\'}[value.selected]"><img src="/web/resource/images/icon-video.png" alt="" class="icon"><div class="time">创建于:{{ timeToDate(value.createtime) | date:\'yyyy-MM-dd HH:mm\' }}</div><div class="name">{{getTitle(value)}}</div><div class="check" ng-click="itemSelect($event, value)" data-check-id="{{value.id}}" ng-class="{checked: value.selected}"><i class="wi wi-right"></i></div><div class="action js-show-action" data-action-id="{{value.id}}" ng-click="showAction($event, value)"><i class="js-show-del"></i> <i class="wi wi-checking"></i></div></div></div></div></div><div class="material-pager text-right" ng-show="index!=2"><div class="we7-form form-inline selected-all"><input type="checkbox" id="selected-all" ng-model="selectedAllStatus" ng-change="selectedAll(selectedAllStatus)"><label for="selected-all">全选</label></div><div class="search-pager-aciton" ng-show="index < 2"><a href="javascript:;" class="color-red has-popover js-show-del" ng-click="showDel($event)" ng-disabled="getSelectedKeys().length == 0">åˆ é™¤</a></div><div class="page-box text-right" ng-bind-html="pager"></div></div><div class="img-net text-center" ng-show="index==2"><form action="" method="get" class="we7-form"><img class="img" src="data:image/jpg;base64,/9j/4AAQSkZJRgABAQEAYABgAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAxNDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjL/wgARCADxAecDASIAAhEBAxEB/8QAGwABAAIDAQEAAAAAAAAAAAAAAAIEAQMFBgf/xAAaAQEAAwEBAQAAAAAAAAAAAAAAAgMEAQUG/9oADAMBAAIQAxAAAAHu9rmdvkq6w4rrArrArrArrArrArrArrArrAr7NjvNULDna6wK6wK6wK6wK6wK6wK6wK6wK6wK6wK6wK6wK6wK6wK6wK6wK6wK6wKiwOP2+J25RAAFCULmri7b8ncz57s13WBVoQp8rFo7m/zk6p+hV7HoZRwk+vW8VjP6P0KfgPX25egLcjTyPMZqva3Pnm6uH0Bz+hrvCXQBgyAAoUoVdxQvymavL8t9Vq+a4zbPqMvlvdnX7VCejIABAHH7fE7YABDz/b4mrz+l0dezPs42vocrVg9FCdfB6nD26ul43obuX0NOmqv3vOejshp8D7Xx9uzp79+lxyujxIX/AEPTuoa/D8V2eJ1/Oy9Hm4hZLV7n539EtmGq4BjODIHE7fla6Nr0GiMfI9yHLqz1ebv05/qMy36Y2Rlrsc56Xu+X63ofP9gXXAQBx+3xO2AAY8/6GvbnqWObquy2sOtGc8ZZd/nt3T5Pk7t+jVZhJ2oT9PHDwX0Dnyv85KvVzenO89ZOjdCbX5Hz+76Py3n5r1Ol0oxey0b9ugLZgMZwZA8V7XiVZ91nyNmun1vkrfGWVfT+R9Zn9yr3vOegnT523zexyflvQ8/sT76QbPPAgDj9vidsAAAAAAAAAAAAAAAAAAYzgyAChS7iFVDHQds+Vdj1Pnsu/twu8i3Le8p7TytWnu9GFi/NvFtYEAcft8TtgiYw1mxpG5DJJpybWvJNDWb0JhDJJATRmZSolxUyWmiRtaBvVRaSBjIxnBkDn9D5afQrPzbsHrbfze+e15nmeTHvuXK4rnunjelyXoseFtd5661887MuewBAHH7dS2IyGvVtwVYXRSlbGnRdFGVwUd1gUtlkUdtkVY3Br3RybOV0xzNHaFOv1Bz3QHKh2BDbEZyDGcGQPmf0zhHkbs+YdKt3OaUZWdRo3c7vnM7PI7Zu5UKRv7XQ7QBAGZRkAEcE0BNATQE0BNATQE0BNATQE0RJESREkRJESRyZAxnBkD5Z9T+WljreU9ueN6G2yVOhpsFPjdDJZjGY31LBX+i/LvqIBAGZRkMZiRIE1PWX88vYdDFDeWXN3lvVDBYUInSc7aWZ16h086N5Ovv4J2pcaR2NVC2WJcO4W1CJ0tnO6RjMZDGcGQPmH0/5wXur5ysQ9HS1HZoYqFmhPYQ4fu+SbeJmJZ9hzvWAEAZlGQxka2yJFIRSEUhFIRSEcTEcTEMyEc5EtchjISREkQxkYykAMZwZA+efQ/Fnnbui0bLWjeXvK9ORX6vE7Jw72j0R511OSb/dfPvpBMEAZlGQMGYxEkRJESREkRJESREkRJESRq87caDu9oG9oG9oG9oG+VbRzvQEoMZwZA8D77yh4z2Pmdh0tdvkm+n2KBvn0vLHbt6hZpU+kVfXfNvpJeBAGZRkIywQhMVtNvJUntmaNdrJXbpFTO/JqjYwVd2zYV424EYWK/JXOT1q/Y8zHTkcrV1sHMtdDBQrdWRmG7RyViWM9ixnBkD579C+YnrvL6uoba2jvHH5mvtnnO7o9GcvRxPSlShbFX6B8w+mnQBAGZRkARxMQTEExBMQTEExBMQTEExDTZc7WWTtZZFZZFZZFZZFaFw6HYMZwZA+W/UvPnjvfU+2eHu3+seW5P0nmnj8e60HkqfvqJ4/H0blHjPcLBcBAGZRkAU1TYbd9aRszogW1fJY11pFiGnJZlTmWNuiJYlV1FyGvJv11thYlWybZVslnFPcbqeapelSsF4DGcGQANeznFtRydBW1FrPM3F9ztJ1Z822WgAQBmUMkkRJESREkRJESREkRJESREkRJESREkRJESREkRJESREkRJESREohmORiWAxkRngZYEkRJEYRGYAAAAAAAAAAAAAAAAAAAAAAAAAAAAABkH//xAAvEAABBAEDAwMEAgICAwAAAAABAAIDBBEFEhMQICEUMkEVIjE1M1AjNDBABkJD/9oACAEBAAEFAtKijdp3BEuCJcES4IlwRLgiXBEuCJcES4IlwRLgiXBEuCJcES4IlwRLgiXBEuCJNY1idFG88ES4IlwRLgiXBEuCJcES4IlwRLgiXBEuCJcES4IlwRLgiXBEuCJcES4IlwRLgiXBEuCJcES4IlwRLgiXBEuCJcES4IlwRLgiXBEuCJcESdBFjSP1v92726R+t7y9rVzRoEHtL2tXPGgQe18sca9bXTXNeOx8sca9bXTXNeP+k57WLnhKDmu/4He3SP1vdNNtXknieA1xaYpeQdJptvVri0xS8g6XbvGSSSmSPhdVsiwzpdu8ZJJKjkfE6rZFhnd89kluKNfUVFbik6OkYxXNScScuOEMg1tSkiLHtkZ2u9ukfre152sVZvhWG7ZInbZE921iETynw/4TG8KJ22RSv44ScmrRMwkoPbYkJIqycVhSv44ScmrvdF96uF4VWTisd3z1u2CFHRe8SUXsCq2HuFmWQOQWQspjOR7WPhijkEsfY726R+t7Zv4Uxu1istywflT/AMKglysB7p5DkflXf9OIB0zpt005kqy6gxsUg9yu/wCmqex8bY6rn3HNLx7u756wnku7P8h/mmpv3McWSTTGxNgoxu4+N46Qycbze+3T/ui7He3SP1vaRkObtdBK1rfUR5nc17oGbpERkObtdC8Rn1L90rg98DN0ic0PZIwxSNtkH1YDpJHSvow8thOaHskjMUkU8EaFuBssskL20YeWx3fPVwMcrbsYbGGS19jS+2Rz1cGzLI1gq3WSSp12B8npIpFJ/Jo0nnsd7dI/W90kQkDont6Mge5NaGN6SxCQOie1YTIHuTWhjelmq2w2SrNEsFQ0ZZTFE2FnSzVbYbJVmiWCoaMspiibCzu+et2uT0inkhXrpSpncaDtr2x8kFbT3RTHY9rdOmbPKfTmlXE7q0MdSfsd7dI/W/03z2SVIpF9OUVSKNXa/qa3sNbUuNsc8U7Y4GRvkniiVuxHYlqRcVdoyex3t0j9b/TfP/BaoQ2lLoxa6JjK8DLsrn267LEEOlyNkUfa726R+t65XleV5XleV5XleV5XleV5XleV5XleV5QWFhYWFhYWFhYWO756+upr11RSTRQgWq5YjIxrzaq5FqsXGpHEWTwzF7GxtPExptVYj66mo5Y5m9He3SP1vQ/hOeGoysBErCt7du4LeuRi3sxvaAHNcjKxbmgIPaUHBy3N3b2kAhwH5T7LWSCy0j1A4xLkslY8GdgTp2NLbMbj6lmzoPx0+esboK2kPdBZ0nWqU8sOjOgZp9sTaerjpLktJtFmpWqbmST2RHp0L6wllOa9iCy/UJBELVOetdk/8c/X9He3SP1vQ9HDLg1zU7IaWuRzj8yNjOw/45Iw5iLJHO8uOxy2u4vLiwlbXbSxzi0YI/KlD3TNYXMEJaxkXkMmTI37uN+G5Tw9R7dqH46fPWHb9Pl2ihqLn2LtNj4RqLo5XS14rNZum1hqM9SDgkgrULsjfRalR1B7mV77tkp47sPp6x0CN8VDo721oG1oev4WQshZCyFkLIWQshZCyFkLIWQshZCyFkLIQIzkLIWQshZCyFkLIWQshZC/PZ89dO1Jl9hfK+Si06pIyzFTdWjoT2I9XqVWQi3qc88Wp7tUbDXZNXdZtvoVoTp0diw67qdirrFo2ZqfV3tH9P8APW3JYrGhIa1fmrRMhEsMkz36q+2yWqaNm7ZFOk6AV2uL5KkmsTXGwm9DTq2G2rXqWtdHal6u9o7MrJWSslZKyVkrJWSslZKyVkrJWSslZKyVkrJXleV5XleV5XleV5Xlee3563TWo6pFBJ66Kg50E0T6kIgb9OijfJeuUdRbDBXdWg2S3468GqQ1b0tcXKdnTm2X6UHihTtN1Xq72jqfx2E4HQHPYJGnt3DHQflc8WeWPaXNB3Bc0RW9uAQVyswZWtc2Rrj2fPV2jvsqGGCPTas0l7R9PNyOwNOpMU1e3Jp83PbgdBFPp8lWmIbO3T5Z2TSWWxxxR2f9LS5IzqGl2LFmt0d7R1PR27BJ4x5TvEWfGfEX8TfuLTktEm57Ru8Z+1rS7xn7f/duSyND8n8eWGWP/E0KPdj/AO7WO4o3jiDPsc7EkW9sqH46fPW3emsXKk0s8B5qd+pHMLVmXTmC9HYmowVrFay9jg6zWOoXbFWrBYtWKE1nZ6SCxpMUMVIV4bvV3tH/AESM9CMrGD0H5QjY0BjQ3a3d2YG3Y0LY0O7PnrBTbYq0pmsLpOTUmWpYLWn0YTHyPgnbasV9Rke9zoDusPnsWK5rVqupy6ffnVi66Z8YsyapBYitM6O9o7cBbQtoW0LaFtC2hbQtoW0LaFtC2hbQtoW0LaFtCwsLCwsLCwsLCwsLHb89abnubZqcGpwvhsWrFOvJrUEEXHdrGgJ9Sle2BsmpXKcDq0FmWG3PrFNslaprDmV7nNqVjTasc1prGsHR3tHbkLIWQshZCyFkLIWQshZCyFkLIWQshZCyFlZWVlZWVlZWVlZWe3566nDGLdO/Z3C7VNF9Q16zJYbNBjIp7TXwaU7T9YtSN1GxWmVaG7SkhsXHajXuF1DT4XaVA97r2s1YpoYujvaP+vK0Of6eFenhXp4V6eFenhXp4V6eFenhXp4V6eFenhUsMbG9fnrHGIqJoS0dUp6c17LuOSGjx2JmR15RplsRunFahTgoW1XhFiK5UDJ/qjm1Y3yMZemFnUqtYVY+jvaOp6OdtBc7ZFuC5XLe8KORzzJnkc9zTvkK5nLc4O5HIPeRyFrN7kDyAt+6M5jf/KrX2yMLio3vy7/Xrt2JrW7oy4lgc2H7GiIgxTewfjp89XN1OXUrdRrq2ouimeLF+OTUo69vUPqPpxE+96yFtjSxXiil0B8TKcl21PqdVznaTRvP1N09AahftVY5ooujvaOp/HTY1bGhCJgW0IMa0loKMbSdoXG0rjbu2N3GNpHG0gADo5od0f8Ayp0Qc4QgLiGfTtXpwnMyWxhqMLS4RbWMaGMn/j6/PWHjGny8TqEsrYdZrvtx39WZVMMLY7AsTsqarLNDJFM1mmw2bD7TA6fT2ag62RZ1CtPBXtGpYqPnfF0d7R2YWCsFYKwVgrBWCsFYKwVgrBWCsFYKwVgrBT43E4mWJliZYmWJliZYmWJliZYmWJkY5Hdnz1jFezpDxXraVZZF6axru2VptXoG6fZpu1PUJZzVl1WxabB6exUdZN/UbkEF76ZarR0AKd988dHV6DajYOjvaP6f56/RNPX0TT0+Nskf0TT1BXiqxKWhWmscEYsWaNe4m1oWzy6VSnl2N44tKpQS2NOq25K9WGpH0d7R2STOjXP/AIxYyTJhc2W73ZMwCMzQOUb+ZcuGmZ24ykOMu1vKt7du9gBc0Ivw4SgkPaRyjYZA129u4yND+RmN4CY7e1rt0ZskAT/aJmud1+e0vaFysxyNReGouAQlC5W55GoPaU6VjU17XdrvaOxzNyY042kHhBEmZAYyA5oLsDZwDeYyvJbsKc3w9u9hi8FrtzYzkxuxguayMhbJCvJc6NzjsKDXZDXNAje0sOxkWxrOJ2NpDGgiTr89rfscXeMyAAOEn5gj/lO4TYIQDCXfaoDlvY72j+tADVgLa0rY0jAwAGgNa1bG4wFgdzvbnC3BbgtwW4LcFuC3BbgtwW4LcFuC3BbgtwW4LcFuC3BbgtwW4LcFuC3BbgtwW4LcFuC3BbgtwW4LcFuC3BbgtwW4LcFuC3BbgtwW4LcFuC3BbgtwW4LcFuC3BbgtwW4LcESCD/e//8QALBEAAgEEAQMDAwMFAAAAAAAAAQIAAxESUSEEIjEgMkEQE0AFFGEjMGBwgf/aAAgBAwEBPwHNtzNtzNtzNtzNtzNtzNtzNtzNtzNtwsTMm3M23M23M23M23M23M23M23M23M23M23M23M23M23M23M23M23M23M23M236HcILmfuXPtEpVw/Hz9KdDLkw9MPgwgg2Mp02qNisH6eluTK/SGl3DkfRqlvEFXcBv6jVQfMDBvEpoahss/Z/zH6Rh7f7HVnuAlJcUAlUYVeIouY5Ki4lMsDjOpHInQABC0zqs/n/AJKKhqX8GHxE8wniUfTWY8KPmfYS0XKk0pIqLwLQGMbKTLuamVjz669LMcQV6idtpTptUfNvorrUFjLInMqPmZ0lf7Rs3gwU6TcidT1KouCfQqVMuTxEXEenqEJFxF6jnuh/rEKglXmxjWvxPB7J1FRbFPyjSQ/EQYe2Curixj9WKXafmUqijujg+4/mA2j2f3QMR4hYn/Rai5nbudu527nbudu4FUm1/wAlPPqp+4fkg2mZmZmZmZmZmZ/yv//EACoRAAIBBAECBQMFAAAAAAAAAAABAgMREiExBCAQEyJAQRQyYTBRYHDB/9oACAECAQE/AcUYoxRijFGKMUYoxRiiyMUYoxRijFGKMUYoxRijFGKMUYoxRijFGKMUYrsjFydkeTFcsnScd+Fbq1B4xI9c7+pEZKSuiUlFXZ57IVVLXhUrqOkLqX8oTTV13OcUJ34JyUFdn1P4I9Qnz+hQWibvK5TeUCbtFsoxjOVpFeMGszoXpor8pFopE3aRJ2iyn9xJ+k6V6a7aj+Dy4m4Mbb5dyxZ/B06lGGEvj8r/ADvpTxezy4y2TmoxxXhOjOjLKJlVq+nkoUvLjYqwyWjKSKdNt3fhKnKm7ovOeilTwjbtqxuhVP3Kkk1ohyI+NlGD+73ThFmKtYlScdkemc9onT3YhJfaveSipckI4cEoRlyKKXH9GbNmzZs37l9z491YsWLFi38r/8QARxAAAQMBBAcEBwUFBgYDAAAAAQACAxEEEiExEyIzQVFhkRAgMnEUIzBCgZLhBVJysdE0UKHB8EBDRFOTohUkYmNzgmCDwv/aAAgBAQAGPwKMuYCcd3NbNvRbNvRbNvRbNvRbNvRbNvRbNvRbNvRbNvRbNvRbNvRbNvRbNvRbNvRbNvRbNvRbNvRbNvRbNvRbNvRarQPJVcwE+S2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2bei2beij+P5/v2P4/n7DErxLA93E0XiWB7uu8BbRVaQRy7uu8BbRVa4Ecv7HrOA8ytqz5lqkHy9jH8fz791ua4lVulVBXPtutz7agrn26OPxbzwVSansq0lpXB4zHbo4/FvPBVJqey8x1CuDxmPaU8R5LZ/xVPCefZrPA+KLIDQfeVSann2VBoVdm12cd4Qc01B78fx/PvE9hd2eaB7CezwlXRmFi0oHsc/gFU5q/Jqt3c0DB4c6kpzJDfwd4hi0hNduyPY5/AKpzRutgo3fIF/gk1jmw461Ywmu3ZH2eiZ8VVxuqrTe7NFUXvdvItcwNcc+3LsomvZgK5IOHej+P5953YB2V3jtd2XHYrWbQcLquDAdsiYDkXBSB73RxR4au9M0b3kO9xxqg5ho59aodknZJA6tX8EGgzVPIJjG11G3cUPZgu3mqv3jlSivNJ4YnBFzbuON1A8CnSHeskyjTzwXgd07Kq7XDgnPB1Scu9H8fz71EQUbxxW9VaVXcOyiIKJKru4K8FXcOwtORwRYcwquFXfeBoVfEVX/ee6qvPNSgfdbj2FpyOCLHZhNOgJeN95aQWfW43lqQlruN6qB91uPsyN7Sm3zrUxomVx3/ABQfTWCkIyUYOSeXVDGYUbmSrl1zK5Vde7KOv3fvCn5JzaUcPebvCfTipY//AG70fx/Pv81iOzHAKg7eaxHZjgFQdvB4yK1mGnELJYi43iVcZl28HjIrWYacQsliLjeJVxmXs9Kz49mqfgsQ2iAcM0HN3GoTyx5rLjrCtEJJXNo3gi2+014Fe4W8T+ifLfwuhobROLxVoWk1m3tW6ce9H8fz/dlfCeS2v8FXxHmiweLNvmi12BCDJW4DeFqOqr1VrvAQ0daBNG84nvx/H8/3hV2q/wC8FqTC7zGKuRNy3VzQ9U014ItePI8Exz3x3a5A9le9H8fz7mCzWazWazWazWazWazWazWazWazWazWazWazWazWazWazWax9h+1Qf6gX7VB/qBAySMYDvcaIvE8RYM3XxQdgYXtDnZCuJWNrg/1ArotMJJ/wC4EJXShjWGuOAV2O0RvPBr6oufIGtG8ppdK0A5EnNXHWiJrhmC8L9qg/1Ar0UjXji017kfx/Puiu9AXhivEOqreFONVnkm4eJeIdVW8KcarFwx5rBwKGsOqreFOPZg4Yc1gQfJXbwrwVbwp5qoNUey7T41ARN04cKFXrp6I0Y7DM4IawvEeGqGs0itCa5JoqNbmqVRIIJFcAfZQzOsscrnvI1lPM2yRxOY5oBahMx7nMaKlm4YZq1G0gGK82tRVQTG3TOjMgqDwUckLiyX/DXffG/yRZK7Ssc2gvN96qIsv2dCRTCStCCp7PaLS99pdSrHe78VpbAdfRXXtApdG9ysspldLYwDpnO97hgorPFM+WOglAJyC+05pIWS6O7QOUkfoELKRl1QpP8Ayn8h3I/j+fdZyKabtc0QW+9X+KLrprWopTBXS0CtBUb07kKKhGNQr5y8003a6tPJGvAhM1KUQz35UWjA93Oqdq08OCdq+8nspnXWVbtMsE7mUeyrbw3UFcfyTmubrVGY/VO1Ty1c8+CeTXPDW5Jgc00b5UyTKg3WnC9SuSa25vdmU2gfUUwuogtOTvC0nNajbo/DT2MdmtNhtbrjidVqks9msNrbfIOs1ejPeBFGA+77zuQUkNlGMxvC8K6Pk7moJxWK0aQNLZN3OitEsYe+1RkVLDgTyT4i2QtbBpKA41UEjGTx35gwiQ40Wna1zWwnWDzjJ+FOdZXsjvQ3/W7+SabSWOY/7gwj/Ejpoy6TSXWtaMbvHyVuZLZbRJHNdxjanOhsFtDi0txCeJGOYdIcHCm4dwRMJLW8e9ms1ms1ms1ms1ms1ms1ms1ms1ms1ms1ms1ms1ms1ms1muXsPuyjNqtkklvlhjilu4CquvcWzR6+n3lOA1mNwtE2+8pZpLT6VRlTfZkFaPR4WNxFwD31JbIqwal0XTmeChFre8NMgAN6tCrO60SaaSMGjXDaKKe2x+jwkNa2mtXkpbNpbnpfhaG5URxI0brvpG+g91SUe50bT4K4ZKF1mqHktcaHd3T+63y6ezPMwuO0S0Ilh0s+uHOOq3zT/s+yte9zxTSNxArzU9kljfLDe9ZoxU1WjguwQjIyClTwVjEDWyyQtIfdbexU8U8eiZojQ3LuKtDnWmGX1LsGvrRWaSFr2uFb0k3gTbRG8CNuo4E8OCsljcJGRR3hfcaV+KvWOUseyTWD37gvtCEaN1KaK7mVDMdJdjaIjE061Rvpw7p7uSyWSyWSyWSyWSyWSyWSyWSyWSyWXs8vYyN9EZIy6KNrkmP9CDmyguZFewog6NnoM1cbmNQrTNB9oPc9rhpBdpirM6CTSxxz6R7qUoN6lcy1ugFodeioK3wvVWuSe9gW4DBCK5dtIdem/wDErWyyTO0DCAyIZFNszITH6y8ZA4KyQ2ibS6K8JS4J85LYRQx6MAmo4o237Pl5xtaKK5I90MhbfJzrj3T7Cp7cO5ge6OeXaewjSNw5qt8U5KhKGIxyW0Z8yBvChyxWCrXBUxryaVQVrzaR7Ezwu0cX/fOspWuZO66QHFm/8PJSOcWte4ObXKikssGjfV2s9wq1eqtPrfdbpcKqVlofZ2PwuObgAmwOdedEb7nxZFvAc1dh0jLj77xKde6ofR3yxvtAqwvfQDzTYLO+QzyNAJeatoUywyuiDo8L/wCpWkmMcs5bogIcQBxKbAyZodZBrUd4q8Feg0hIgNb+OKc+0suvv08NMO4e7q5p1Cb2+uFEBewvbncl4jvGafccSMMarF+pezDv5rqmi8c8SHZo62vjhVaxw8/omDLHd5Jhc47xWqOuQb33ua8erXCrs/inULrxAFDuVNzQq3nZgZpw4FFGqIxa33caf/pMzrdPi/opp3Vph8VZqkU8uSk/CP5qL7mqR5pzA9ofV2/moXOe67SnCiAY7ClGjj1TQ77tMvr7GQ2ZxlsrW1e3IEb1LN6a6ywRuoGgVoo7Bpy+BxF4UzqrZZrMNFHpNqPc+CaLHEyS0F1BSooeKggdMfSHNxh++n2RttdGxkelJuqK1MtxnErxC7VpUIWSKLRw2bVLhimWu1SC61oYARv4pvo9lZapZM8SFo6aC1ySU/8ArKncy1X3w+JtxRRR2drXugvmSvdP9hx7PJHn2nsIaxorwCuhoA4UV6grx7t2mHBeEK8GivH2Mlril9Eie0h7AL2CmsTIPS2vdUY3a0UxtEOin0Y0La11tygZA3STkH0iOtKuTo5mBltFXc28CmOtdnq2HD0on+Sf6REZXytuBpNMCo7K2w6ARPEztatArVdm0RtRBgfTOijinaZI/SaaUnPkr9mlDpmnVswH80LXI1zpg/CLDw+ansjbDctE2DtdRh9bK6ODzqAr8L77QaV7h/dbJyYo3PN2WN+Au8gjK8P0MlXAwZqOe1R2hs94YtbRvJRBkrvXXnOLHZLT2WVwEh0chndjd5c0y0wTaRgzbK+9X4Jtos0UL25ULKvB/RSy2tsjKRf3YpVSyRuYL9NBpziFC6Fk18SNDqDUTrQ0OE0eVzeqWqCW8Pus3KF8FwNeTcI8Q/EjFaHTi0t54UVGtDRy7h/ddqmtDdV0VIifvJkJtuhiAzu1onwS/aDZHuBF+6oXfZ8GklLf2hp/kjE6x6NmOiN6tZF9n2SUXjGxzZGcCpJLPaBM94LLoFLvNaLQG0SZ1vUwUUs9NLFW9Zjv+KuQtdJZ5G1FMLhKZZgS5kBpM/73BWg2iTEyOjbX+ARc/WtE/hhyyTfRp9E8Q6xpWmOSLZp9M6vipTuH+zxhwBF7f5FbGP5VsY/lWxj+VbGP5VsY/lWxj+VbGP5VsY/lWxj+VbGP5VsY/lQc2NoN5uQ5+wZY7b6yR5Lat1qVTWs0RvVLNLlTmoJy5oeJddrzTBevMrY/7r0XhzUURlpLG8SODnat39VaTOHkWh15j4RUgJsYFmo12k1jrfFPdKyLTOq3/lwmCV9o0x8Tty0bJ5BZA7xF9H3uHkrHA2SRrDevyA4/Eoxx2dr5GyYerqKcfNR2+QA6TGRpzb+AJjrMySOoANBdOaLA976mtXmvcPdqVXDEiib4dYVJosKHKhpRY3cHUyWWBHBF2ButqKhDEHldQ8OJIWAxHLNOOFLyrhdJom+GpFck0NHug5VTjhQbkWubQU5/ortTTEppOZCi/F/I9jCXYbv6qE8h+Tfv/Uoip8Qz8xyQF0eEY/FPw9139ZJuq3w/5BUQDRgyoqaIvdQi7QspwVDHHUDln8U2mVEPxt/MewM0UL7PpKNccDRMfNB6XMwUzpVQOdZqWovAdFexIUWisEjIGChjvZoQOIhloPWHG9yX/Db+iMerp/opxJC6aV8N3hhxUr5rO67Iwx9VKyyi9O4C+BxqmiZl2yNZfAP+aoxYwSCPWsG7go4I5q2h0gcW03FelGJ8bI8W5aq0+mLaNu6W6OiInn0zq+KlO4e9lzWW6iy/ivjVVH5o134KpCHJZfxVf5qtEBwQw5Zo8+zHsi/F/I9lakeSOLqHMIkEgnehRzsEdY454D9FW8QaUwTc9UURNT5K61zhzQaNyH4m/n7CO02m12sX3EajlLaLNa7WSwga7k8uZee+NrYqjC8pbVaS7Rxuo9rSd/AKOWfSN1sHRjFWizRhzpJnAxPkG4c0/TXw10AZVg3qz2eP0iT14cTKFap7NQyOobibZob72F968/O9+islkgZAZ31D6qN9ojs9GvGMWLlahCbQ98wGBGATfQi91W6zZMryJtGjv1/uzhTuHu5rNZrNZrNZrNZrNZrNZrNZrNZrNNIcAQa5LaR/J9VtI/k+q2kfyfVbSP5PqtpH8n1W0j+T6raR/J9VtI/k+q2kfyfVbSP5Pqtoz5PqhekbSoPh+vsIYX2tkTmPJxU8LLWyV73NOCE0jL+hGkGO8KzyRmrC31kY4owMtFWnOe7gf+lRTmT0jQCjI2toooPRnxTNeHCpRs8loMLg29rMCtElqnEdor6qZwz44L0eEmzR00hBFb/P4qbR2cttTThLe/kvSYp6mXx0bkDmoY4LY2Vsp1w0JznWV0bXtLSC7OpzR9Dpo72NDv7h/df7P/vd+q/Z/wDe79UY3CrSKEL9n/3u/VaOFt1nCvYJ5I6yDI1KM931pbdrXcm6eO9dyxIWmDfWXbla7k6SSGr3Zm8Vo6atKUTZI4aPbkbxV+eK86lPEUWQMutJrnXuHueCvxV4tANaUJXuZ0wencAaKrQDjTxLwtzpmhg75SuGO/BXaHoUaDGu/BEluI4HlVUuKmjdhniFVzSOixBGWavXhTjVVLh1QqQKqnKqyI5qocKDmnuGNP4prTmVdvCvBBtRXzVb7aeaxNFeQdTMVoq6PqmktNTuoVTHOmXssXAearWo5Yr3vlKx4VW/4Cqyf8pVNav4Ss1gUbzgFquB8u8e4dUtzpqq6KjWrl9EdZ51uCkF3GuBKHq3Ybk3OvAAolkVa8WpjG38+CaOf3R+icBeqTv8l4Ku/wCpu+i8OHIKUG+ScqA8FRgd/wC1eHNb3GorVXqV160+CqRx+CGDvBSgopab9UKpzqaBEuBrhwVCKVdVPdUg7gjhm8FAXciTVR6taNpRNNK3aKjga45CqbqEOpncQutd/RVLrhmcFW6bm7z9k/GKPFE6RtL+Y8le3Vrl9UQ1zeZIX4t25bM4b7v0WLgMa4u+ioeVeiHGuRXixvH+s0ca4/1v7x/duAoskNUYZKl0U8lTcqAUWAAVLop5LJZd8/8Azr//xAAqEAACAQIFAwQCAwEAAAAAAAABEQAhMUFRYXGRECChgbHB8dHwMFDhQP/aAAgBAQABPyFqyVnU/wCX3ve973ve973ve973h5Ak3SagEP8ATPe973ve973ve973ve973ve973ve973vAmRF5fvf3l6eX738FpxK9vECsBGnbaeKtvECsBGnbxpk1gKUvBmqGifbxpk1gKUvBmqEif8AxhmP2ILQ+wTzqH/Benl+93vP1HKaokLwqMyBgMsbjq8/UcoSSWSzEU1SNyBgssbjqQh4xEQS5PT5rxDtr7B1IQ8YiIJcno0DSxh219g78O3adLEOEo8v7yhUMcnpuxZGFVmhG52hGFExJ9CIoFiDAwh/YawAYJgjuvTy/e7tGxCSSSbmDZFbDoBoCAOZPNHpoWISSSTcyxccERC6o1gFhDNTL5o9N+obwhyMiyYEEJbBeGKAAElDClAK0IncYQr6o+gemvURCHIyLJhi2+pjrrP1rAINYuIV9UfQPfh27CrEcY9oOjicCGYaiCMAEehKBRFWLSElQWBZgpCWD6JMopw4w3JBszGCuMj23p5fvfwQQnDoCMqBdiIJAUDGMDc4rCTO5h1g+ZUC6ASjIe8tngdnDGVAtJKF/wDCqQp4RIN4JIBcmnQCUZD36YFIRjpWEzjICAQBUeOkEkAuTTvw7dgsbP4SzY3NIxZEHoP+YcWI2HxLCy6DrTUGQwgJYjsIWxmpAWV/yG6BuUNLwTQoby90qQalNEGB7b08v3u4RysQoS8hAcUEcYDIwGagSQaVirUnoI5WIUJeQgZiSkBBUkYFICHnFWpPS0MkpR9LLcYqq3znr6QsJDSwxEYo64dLQySgpKi3gk1RqYrHThyYHjCW5wYiMUdcO/Dt2AQVQGBJhMmgh1BQoEgUCBgdnHzjBBoJGxh8g4KgVg8IH5UHA+pqOh8+1hB6hX1hMOCJFgliv20XKOuZUZpQPY/Hbenl+935SGxhmqsxESUjCtGsYudOuShsYdqrMRiUjCtGsYvdOr8/2LhksbgQHKBE5KBhNkNeILgQeer8/wBi4ZLG4EBygROSgYTZDXiD4EHnvw7dhVDKpHv0IYZuVoaTACAFAG2VkZZPzFHtMgaMwSBiStlSX6ODGWwhKrB5KnPChQgDznDXvF3hZpmYBRQXEg0I27b08v3v6fDt2nShLjKPJ+84VCHNmjRaxgsOJVQcIF8iQmfJHERMkTg8IP8ATyamFAlFWx2jNC5gxCO29PL97+nw7fw0GPqfrnAQkYhIfFUMXC3gDBxoC6mUwETxDiowxKJI46DQ9q9PL97sP+03JuTcm5Nybk3JuTcm5Nybk3JuTcm5NybkYkho2fxGz+I2fxGz+I2fxGz+I2fxGz+I2fxGz+IjmjLXLsw7dn7T8z95+ZQLkAQPMo/RF6gYCCGLS9eLD0BHNTj9kAioQAqeZWTAkAM5wzWzIBL0l0Jx0BHbOAAAI2UM7bCET9p+YeAcohg/Trenl+9183QzSAJMlKEVQMFhR+qZxCfheSiaCjNYKcapO1IKFEnBJnf2IQhDFhN0KEGBcAwIoUEonBCJMBWI06AySxcRZBTGZk57wVYEg9jhYQZgzxB0LTZCt09SIPRQlzCcAiY8qmtCQsCbnaJhTKwFHnFrVFwiGlMUDgcc7wURbUURvg65Rj8Coa6EMKE+rDt2H/8AMjlA6ugrUiORgJACKggIxVQ0pvDgha2F8XwRqb4nRBZRBD3hT/ZhJluZDaAf8ABIIGwsigDabwQ4kUpDGt3AM1xrKDBtg7DYQ/8AGi5iGikQmWOxDenl+91tByPQ5CYYeDCDCFwCMTAKEhQNKxRASUJqFjSDVB72RPaTc/og6mr9ApXhDEqgYCtdoEIbDQnylRAojRVssYnBCdWRlCMGBQXFap1hqCBS2LKELjIAnIqjGzBs1gkUCEuSzIUIuMRVLLAw7IVUcCeIOiMEFhSzbDzHyCuJQebhp2hGXQiiyQYGqi8KFclkIA0YOV0E0dCjduD0EEoA2UJkBAIUJF/mCBMi9mBQIskb4wUFzUEF11NeFm8en5uuHbsAyIAkwFYB2B8mIoZeAvVRrmEwTECUYI4YqvnFABiyQShZscakRgoEWa65Y/ldEAAiWLAV106xBe0zqLTWD87cAR4PCCmIz2Hr7oYkMAyAzhtaceKw+wmYJdS9CVIKN9a/PYjqE1BNBNBNBNBNBNBNBNBNBNBNBNBNBNBNBNBNBGFFppOZpOZpOZpOZpOZpOZpOZpOZpOZpOZpJw93Zh27D+gqBsoOlYoqwFKmktKuCtag9ILgEtggMDGL0h1ZHCQKxjIAVgFzNKQ0Q3KMqgMoPQamkOezD5NnBQHQAyQ3SjMOCs1RSLtI+20AIdFuWMBAT1oUISWUW17L0u3f0+HbspPniaC8RoZLEAXGuAk5aAzGQwBhk/UzoWR3gcJFWNuoXvaU8Z1Bq/2A3EakAsvLB9HpZwNkkrffKESeCAEm4pvSExaW+A6QGPTud4oelYAwTFAL7rONRoRdmF6XbuwgKXM0nM0nM0nM0nM0nM0nM0nM0nM0nM0nM0nM0nM0nM0nM0nM0nM0nM0nMBCk5mwczYOZsHM2DmbBzNg5mwczYOZsHM2DmPI5gL37MO3ZeWKoCV4Y004Akz0j00QvciC/3XoyqmPMwrhWjSYGOBoX09YqnifFQN5YkgBrnZstLx5wKiCd7Wg+WaggDQhRE6ZJxFHCZUpR2PXKHjgngq5O8fm0BEP5dl6XbupKBTsAciAv1ALJi3YTAuWpo4w06nCAg2L6vK6SBBDBYPTxB0rgZJEFJYS5icCgATRfuxlEqWZeAwAGJwSNrURWGAGQI0iNSLWRRgodazD4Eouo/wAgIQ98ICw+uHbsFlk2MAV3S0Pw68iWZwOOAtYATMSzgcBnKxSFkB8LGTmKpBCutcIkZh5WCZjpg2VomGAqtI3igIleSwkOVGmrhbqkSoC6wJXICENAe5hEnYHouY1whvBLHTpFsIgDWhnuet6XbuuHfoYUgdUei6Mghk608UdjjsayZtQP8QmFzGIWddoKaLBIKCt6oQrBo6r4mGWIKCZFB4gmyDoarKkHCrsH4RZBDoYpYIBWGMaSg4jqoIQao3gIvlCKt0AQikMnufqVe7HcQJRWJCQy8BPEEWsQVYTV0JIMw2T2hFEVBIFXUVVzlMadVCphQHtAfPwgKb8XBPAMFB3wj/eYTQZhcKsIimEQBRhmK3UscwdZqR8Im6BQCAoNi7bDt2BkuHsNFaxNgF2JsIAbbOgN4hh5L0GjBruM/u2MOrVQVLbgrBBNbBRCNqErOkOky7zcRn7ElQwxT0j7S821FEBpDN1Y3hq9jhUjAyTi7JBok7VcGsCATrcLsvS7d1IYU0N/5QCgxfQCMXMQAQBW7r4g6CQFwAHC4u4KITARhoEqO3DFKoooEkFWQtAUAncBUwl0HOUt1w7dlHOiJL1gmeWkxQVBOKwZZhCJcBi8T+IiKSTUD2JfOWt0aZ2h9UsbGpaIuUxSbmWFGLLcQPzB8wBgaKIc1ixDKt7oQHDBLArFCz0MSRUaWiFOs0dfPxD0JhAG/wCnrel27sIBvN7mbnM3OZuczc5m5zNzmbnM3OZuczc5m5zNzmbnM3OZuczc5m5zF15i68mLryYuvJi68mLryYuvJi68mLryYuvJi68mLrzLdmHbsZ1uSwPLGpTVqAwgd5UggGovzLLMJZLBWhz2CrmfBBIxSUx6BYrx3kilBihAIec1KWFbyszAaTi8vSJHkcEakLGCpAzoJEgVxMGbTgnSDFm8W21D3AtakILgkEKQkZ1vMbKIF1vS7d2EgXm9xN7ib3E3uJvcTe4m9xN7ib3E3uJvcTe4m9xN7ib3E3uJvcTe4i68RdeDF14MXXgxdeDF14MXXgxdeDF14MXXgxdeDF14l+zDt2B1gDFhGCjVlAMAACgj1w+QvpDA2AQXqzEBKMhDwSGsDIKBkNGBm8CK9brpQ9R2Yh7EoZhYFkVRMryr8IQMRqoRRihuDYYRxUmhioUCAMcSRo9jLEMgrBVVvCAiOCpBCnW9Lt3UlBzU3/4yfVWAYn9In0ifSJ9In0ifSJ9In0ifSJ9In0iCkesEYZfrh27C+G/gwizbeALGDh/kR9Bg8FOAhCIrzKPzRhyRGthFKjFSa4Q9inNQPhBeoBVkCKE4wjollO5hsaoBwGlVqIpx5SWX+kdSMXEIHELA2igyNYGR5pQzSB7121h+Ot6XbuuHfoKuLSKKVgLxiAAiy8++scwWcIVKjxqABoqv11gS7heF64xGCgZAoTqMCxObpAQiAZQ0T10hssAyjNxGFrQAiqIIN6qBguEQqhP8QHMKu1BzA0wi8tpS0wZlBC8P20K6D9KhAARAQOiq+m8JbQJ6jkU4TANI/ZMUMxFayENr4j2PvKinFQFkhBZa6wRAEBqEZFXSIPPcud4WeFsBNNMjEkYhHZorXTKMd2QnXQjZDGJFAA9uaw7dgkm0BLOH4A6W5zSGxGTLIj1ghONAdFY9M2pUoF9YKJi3UBVe60eVfCQO0Arg0kpH6QKVr9TY+YjKJah3XfiGaqpzfcfQwGwAqFFuRHj7Vauh3i1PI4gzo9Y3MuLIIU9+t6XbuoOBXpeSM2ZwIKxG0sBYXI2tL9L8kWAj1Ieko5Y20dw6YnCAdAuJEOOY2IXmClt3J7QCK9vCABQIIkUhGGQFhCkogXM9E6GmIKgAAQoB1HKa8mEqtU/MJVw0Qt+t/MXh2htsLYRAQkAAWDQaELWVzNOqEn1EUICqJ87QkQNjeVPxFoQWwNGQnBGZC6mfMaAgVYe5S4wBBdcO3YB9AENtAJYeEipgyJAPsquEZ58mB0DMDgcCIQ+E3OUrWHFGoXshMWa4dkoLjR0teMgtlIVVAN4F4WIJQqEPdB0RMzCoZG8KWkzhD8S5ZAy8soFwIQ0hXKHpMLmitQHm/W9Lt3YQOhmk4mk4mk4mk4mk4mk4mk4mk4mk4mk4mk4mk4mk4mk4mk4mk4mk4mk4iEYjcWIz1n3mPvMfeY+8x95j7zH3mPvMfeY+8x97hMJaIwSi/Z2Yduw87mBd4HtsAqxEwg00UIB3aSgxgDUFKCJABGaUZh3iJMzoINL+YuBLASThSXrB6o1G5cSsGYLNIh4K69XRBIxgNFXwWhGLZalEYp1/KRT3mqVIYNsApmyqNgz0XW9Lt39Ph27kELlppcdEBhULqH36UdvoyVqNQDW4HehWhonWwR7GBSYDVemPjxo3wZ5p2Fo+PGzXJgopIKKehlZJkNV67db0u3dnrNbBnaArAhEBb0lAyrgnakBYoiLzl2sMEWxsCR/iZ0yv0EFiTUApPugPlN/8obVEl9CJdtITq0JMcAiogXJJpugRCigBlY8xgLDM1eYRALQFgljjPwjIRAMGxN00Uhm8FSWIi4OAjEkAkioXE7hFkcgA0EYdV7M90asCchGouFHE4gTSFpAAAskQKVmcdegIBJgBdSPwDAERlsJTiLjIF6+OzDt3N6QVUoQLrEx+ErAIHSoPiGiCszaDQSwOZ7IThb/ilTaX+iUSVQVd4RACSaQuBQYGMaDdn23pdu7BoSt13SsCrbxYBlYKgtQHiEILAlKjbSA6BgXQV5hMCPVLlGExsRFB8oQKXGIhX1/dYTqAAMOMc1DQp1BSRxhupGtmB+Yk64PJoY0wiSUuOkrWGNoqsk1RRlKqqb3AjOEsJYGBEChgKiiCjgKdRtE5gIGX5fEJtUQ4P9cGNKEIkGTAyhKTciyKQB128nAAfKlrAWqqo8xoOk+gUgbxFHFW/wAwqY4FUNJZcqAb0P5iYORJFxaQKRaEDb3UJqgILb+QgrxA0hZOFn7wRQso2NZdmDbuQxgpUaDGkMcwFuxZxAtQOQqbfpTOHDJL1rEkIkE0BRHCh4igSQg7PwEwQwEKUVw+kFDJIWUBApgCLC7uf0wlIJNUadtEy+Jd/LtvS7d/WjkINAo64Z2hMIkORaFrOzRjABQlFxBkAo8rl0E4BmD1VBNcDRWwii0e0AAJQvftvQATZzU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8TU8Q5A/vYn//aAAwDAQACAAMAAAAQkPPPPPPPPPdOPPPPPPPPPPPPPPPPPP8A1PPPHHPJqdODdPIm/vPOPPN9eGndfPPFPPGdur9+tVik6Dl3PPKPOPqzQU2vPPFPPHOwrhldvWWvCj//ADyjz6/4NXELTzxTzzzzzzzzzzzzzzzzzyjzx89NHyHzzxTyggAwgwwQhjzDDjDjSjzzQgkiD3TzxSjDDACDCDBCCxzwxxhyjyxCxjBQyTzzzzjDDDDDDDDTzzzzzzyjzzhAAzRhTzzyhzxyThDTCSCBRhiATyjyhCgzTDwzzzzxDDDDDCCBCSwzzyzhyjyjAxihCyjzzzwQwwwwwwwxv33332vSjziyjjARTzzzyjSjxSxxRDjXjjCxjXyjyxjRTAjxzzzzywwwwwwwwx733333zyjyxCxjgjAzzzzyzhhhzAgSDTBCBShzyjzzzgixzjzzzDDDDDDDDDDDDDDDDDDDDDDBADCBDDDxzzzzzzzzzzzzzzzzzzzzzzzzzzzzzwD/xAApEQACAQMDAwQCAwEAAAAAAAAAAREhYZExUdEQIEFAcaGxgeFgcMHw/9oACAEDAQE/EEhQmyXGS4yXGS4yXGS4yXGS4yXGRNDbEpQmyXGS4yXGS4yXGS4yXGS4yXGS4yXGS4yXGS4yXGS4yXGS4yXGe3vNbo/lj2SjoYksIiE9agtIqKVc2j9iqT/DotoqGzQISV3PYYVS8j34tbCWK/ESS0jTTh97thHRl83uQpKe5HWTzhNXbkQmHkfP0haYTaoyppOu8Ds/B7bp0/7ceGa6MzjOGu1RMQ2gaINV3kZNtU+0QpUquNxLWo9SphNwvImjQapTSn84jvep6kIVQizIwwtfcTipOaH5JniV3wJbwFxHSas3H3pYZWS3SmiXSfLQVGXwUDz2oeoh1CyhqpVlitPCxU2SqUw67qvVPZYQyaRAhUWP3Il8hRIYb1H6x+kWGEwa+NQf9Fpib3+FJG9hckb2FyRvYXJG9hckb2FyKyNW379Tqez+n3fKX36lzyiwsLgsLC4LCwuCwsLgsLC4EtyowuP5X//EACkRAQACAQMDAgUFAAAAAAAAAAEAEWEhMUEQIFFAcWCRsdHwcIGhwfH/2gAIAQIBAT8QVdphJhJhJhJhJhJhJhJhIE2EV1SYSYSYSYSYSYSYSYSYSYSYSYSYSYSYSYSYSYSYSPYA2mpCaanRQFp8oXRViH3segBv0IzbR6KU2y9xYhrY7lKWALU8odsxV6QlQqDfY9Suy2gKH2jGbgy2aXLO0rQrn3K0jrtiv5/yJZON255iU8kZBwR/V+fOOt/u4j2hABzEiqhuYw2ZNv1jrixW9iDhFajk1OnJe2p2PUatjFzfeWZtiCUyplhs/eAN+q/x4mvt3eLduI6JnAv6xL0YzCz2uGkl/sfaak357UsOI9+PRSlrgUtjS6QqDbsfTKWk4DSWg2h941FNS4/Q27H1AFRqL7ytrNfH6FrRL8JfhL8JfhL8IoLr1Ozu3PUpcpKSkpKSnxX/AP/EACoQAQABAwIEBwEBAQEBAAAAAAERACExQWFRkdHwECBxgaGx8cHhMFBA/9oACAEBAAE/EE44EytX5mvzNfma/M1+Zr8zX5mvzNfma/M1+Zr8zX5mvzNfma/M1+Zr8zX5mvzNIAiQBPrVo7RCWPWvzNfma/M1+Zr8zX5mvzNfma/M1+Zr8zX5mvzNfma/M1+Zr8zX5mvzNfma/M1+Zr8zX5mvzNfma/M1+Zr8zX5mvzNfma/M1+Zr8zX5mvzNCxJGnj/7rL6f3/xZFe1rflQ0CTdH8reOSk8pXty35UJAk3R/K3vkpPKPLMSDl6GWoXn3M5pFH2zQj48o8uxIOXoZah+fczmkVt+Yj4/4STGv/Msjal9qmLRxf9ohRzKP0/4fT+/+DJEB3wb1uQ9VatQHAl5UL2S19eNNVDBvs28XYHfBvSpSZVlaQCUmBizQPZLX140lUMG+zbxDfbAX9Bvvp64dsEplXdoFQCVwFBTHhYHBNT1pIECHjYbPx4hvtgL+g3309cO2CVyru+AsUzK2xMJ60mCBDxsNn4+/M/I/nlMtoN4HdxXHd1SlYsWhdnHg8hbRDyqVNoa79DfLpGudvjE+74G9omGT3qfxIVi4z/V96kHuayeb6f352Qo6yTx0pGlSVdWtYhO6Gvgp0RcTr3vTEML2D4AjrJPHSmaVJV1aRC61WHzUBQScWvOmAJmWD3pJiF7B7nwJuJUHXQc4p9ySMq3WrlWsC43wb60EuJQa2NXA41q1U4i+5kQlGaAd9oeWfbwJuFEOroc4p9zSMq3WowEXgkxZbbl4QXOBYQuBLpryozQDvtDyz7ed+R/PIiapLrg4H9oKCScwlo50bNJbA2Lzz8J6AJyAy0v6N6QkFIjN/S9TGXnQTUh41Y4vSrVoUmLV2aBmnregLPjJi8Z4lWpw/YHl+n9+dkVMzA/J4P3MLvFy+AWQKRfRYoIMlA8AomYH5PAqK6BKDSNalUWfWAB8FMyYcmHoNqCDJQPAnnMlibBX4ot5I1i4D8UCk4SooXCYs40ihlBqQybsyYvm9EkiZsbL7ykYtWJOkDWfAnzmxoFfjwSRMKCQ5RNtKNKWKXWPaoGBkF0jRSsSdIGs+d+R/PJBSkY8YUc4plmjqN5mONNto5DynEK+jnSewZKO92aBoiIbNm5RIMb08OXzNAqUWlGjp+OKqQTbgGvjOX8oKgI8EoGZKFqa/YUZBBWNvQpcn3ElIzw0+PL9P787LKOl70VULHrvUmONikRpFKWBrteV/iscppEM2zSoFwbfQ74eGVdL3ouoWPXelaOK1vx0xR0LeGANnM0GIJJoYincLg2+h3w8DFn0ISKOFhZxJomyXoo8g2jMSJIWyTQxbMDn0EAe1ZBirocA0KWZKaaGHO/oPgas+hCRUHxUow0TZL1F0G6w1jHtT9puVu5Yxq6Vf9enXGzxpZk5Gs6HO/oPnfkfzyNodA0Rs0joRZU4Zz6UeoGVLcttZmjtqpbYc08JIZOA/qajhVRkWGPmK1oZozCLgIWEb5tcKImIrC8Uta6PCYpQFUAyrAU1b4QGlIhHudjFYKnlFnSaIxxRA2jJSZW0qbMAXg3Tvp5fp/f/AAZHFYn+LtS4UNOSiMM8AogrqDf2KNQBlcrxfEIrE/xdqTChpyUQhngFEldYb+xRiALq5Xi+IBQEATbgNT6+zoVpr+5j3itl+kta0NQEbZc4Ky2QrdWqvHxBKAgCbcBqfX2dCtNf3Me8Vsv0lrWhqAjbJ94rJZCt1aq8fO/I/nkRJGBroYHtnwdWmkMr26VnQCiSJGZYanU1l3LocWFGYJ1oXYgF9xmHlVtiPoAIOECWbTPEVJYkSmFUIDPtVg87IoSGKnVhTPuyXbE660ZxDAWbDOJTAfV2TRUlJ3L2B5lX4J4gSDors8dKGQePHyfT+/8AyGT8j+eUy3g2hdzFcY2Z0UpFy8DsYqzYpYAEwOyKe9BpqBwoyNIECMuBYk19SmduREiDxG5SIamKIlUreSSwNjLTpa0mLmR+aVb4G/wPYg9q4WZfTy/T+/8AyGT8j+f8beSQQiOAwPW/BKbHkkAGsRI/FRKyNkvKrXHK1Ma6WiYLct4fQ51F5gAB40fh2pUU4wF4hGWD0Wlu0PFTHl+n9+VkipCDV/Knog6VP+I6VP8AiOlT/iOlT/iOlT/iOlT/AIjpU/4jpU/4jpU/4jpU/wCI6VP+I6VP+I6VP+I6VP8AiOlT/iOlT/iOlT/iOlS5EA4N9tq/B6K/B6K/B6K/B6K/B6K/B6K/B6K/B6K/B6K/B6Kjx7wdKCAAuBh8j8j+eao0eukrCJgUTamdCIiOCSCdJoAgokRs0IglHCXZGWNYpUamwRR4RQHSHVSwAZO1XvDSG4KYCYKn1OG2Coli5zoplSUWYJVA01p4KMfAJYV0jNK7GF2zcUS0eFREFSCgMKkmEY3PH6f35GTSBlRQQQYqRqRREBZ+KKnmZaes66ejRLBMJoGJzh/tJhyGCCTwnFXkxgDBEjSLsSlobn+HvSiRCZzYnR4UgWKQISeE1f2cQHo41jqUanrFATdGYtW/KsdahF6NCJIycaG8kkIN+FIzNiAJ9qTkHKzonGaemDIhB4TWjD4Scyu0b+EIzPqQkBMwyjZtUSKTcRa5nL7UAIiIRXBBo8TE0o/kBDI1BwmlGhQMGUTEZt6VJVQEEVdyjSkseajFCicZSDdpuEQgkE2EWRDl0ahswrQcTIWkh99aLk0DLDTAucPr4vyP55IhfPEEpeNoqdhdKEq8WtahSKdnrhuvA41PWAFHYFcKt6XYuFYZbERFSkP2K0SkTA2Ymk0KXWhhHqaL1DDxC7NhcqEaBaiVaoJUl5nSlMA1BULgSsGaKRAcSoLSOAYije4TTsILiANb0nt5UCw3005VaRLEARk38mr6f35GR94fz++AtKckWsDzSiTAksCQboacdabpiCgoYJZm+tt6XIOwIbhSm8w8Kn5h0GjQXABzRCLgl7j8Uu8iBRkJ8oaatRyuvZSOI40VzgkEFURFmfik0qsGORgwgvNF4qwkLy0LrHChWYirEw6ce9/WkzAgEpCJR9lHOAwBFJFNKtbCCm8NpH0Kx2ADkEm8zeMaUgmSjKSVbKRDBrTfA9SIJ5jXaN/ByEZiRSiNrNjibzYVIux6BZHCsSetOaBCuyFgQuWW4Uc54QAC4g3EuU5twCcGtxicPWmIl4EQZtSUjXNFRyZGpC0qwGIjcqC6EmWVAJBhhMZpmQkQSAJguS2IzegYOO6OMg50sEuKwvGeZnxfkfzyTrFbpPG+GgvfHCTpfBUj/wBN0ArRKBxp9RyhlUtQkC96eNBDk8aWYM6lO/J4dXFqcKESoVcEhu3A40dnvYKZQ0nR2oAugTZjgFz2VhTT4um4gg2ank6CDKZtpo9jQ3DHgcTSly4KUyIBEmeZMcGgN3UgHh7FDHipEOYTEjy8fp/dTNAIKlKUAytPFBESRzTYI6CXfetq9Wv2K/Yr9iv2K/Yr9iv2K/Yr9iv2K/Yr9iv2K/Yr9iv2K/YozoENfWvz1fnq/PV+er89X56vz1fnq/PV+erhp6M1e1HUnP8AjyPyP55CKMsWWykAzamtGeAQCC+YKVpGAjgHGIJCelaI7oAuFWmJkE1Ou8vIYLmC0HGob7hnJCmgLZq7tFZ4ilEFS8Rap2fTobAWQlomKy0TBFOQd4ofmQ72YUglyQRSjmMrlCFtdYqEsbEuBTkc3cag1jRQi2OLNRHHjgpGWJLnk+n913Gx/wCO/I/nkzCTuPICNGeNOIZ9kJl3GTBDeiG5ITIlJEE2tU5jCzKzcEBZyTReOsSrxMJu9FSUW6WgghIwsWNKwwbdAVaAq+m1F+YmoQSKWiM70nRJ+UIIpCEl9UpBLNA5IEhLk1DQ+WISfMNl3ioQeD3gnJIzBWzSXYYwwZhVkaYoHIJAsMw4zCt58n0/uu42PI7Y8Ar/AEP8V2HpXYeldh6V2HpXYeldh6V2HpXYeldh6V2HpXYeldh6V2HpXYeldh6V2HpXYelKhIA942qf9/pU/wC/0qf9/pU/7/Sp/wB/pU/7/Sp/3+lT/v8ASp/3+lT/AL/Socp6f4oUlwZHPkfkfzyTeQmmgos3aAy9iFJErAveG1A4ILCMJkIWH2o7CxsBcN27iogmJyxFXfRK0rFxRkFzwNIN6keILZkst2hG9MIQpFLSMrMH0Ulio9VMSxApvQjsL4RcbhnOlQemFLAwBfTE4ojZdpAyBZFrNKC/8dAl4CjCuVcctuIkYYhDy8n0/uu42PF2TLY9aEPt4+SPY5UTB45/BlEXGH5PFQFcFMoVhcJmDJwvSRYAUldjNCqQFGGYTJ4LBLigx4xDe0/RQMwJEZE8O0b+F0DTaEzmpspyDKMxGad6YNUop6cR4UOdsqMWzbjYmmr1AEV4ZoIGIESrADq1cRSSpJGE50muKAkiATGBS/vipx4zAfQoVASYBMBAxBOTnUaSwuqi8JMeL8j+eRkAgYaleCQpfFWA/F2hqJvxV1mmDAoSxGrUN80/lIx0YtJdowFcS5IHKgJqWqaJCwEUKJlAEVD3SYKIs5MrUNkmbtjCWQ2m01dryUUuGLSETdrPiMzyYokAjFiaQTOawDUJcASU2l7j3EpCPBEotfMfHSTTrIRTes9gKLY6og9ayHCcBxi7Nzbx+n913Gx44vQ/h8Ebw0votLtJ60AomGSkJgCxE3Jxlir2YmNJMrVvfb2rKVNsQRs20XzS1dJMJW26MG2KeAK1rbJQ6OcTRGuKilRmvdpyqC5UmGysSGLUGnSRgvZikQzDxpkzMn1D7qTIpmc7QXL4IoGmbRLaUS8D6xSiwoFmUXhbWc71M5Ezha8BLkxximSJJ1kIHGbq+lCkxhtLByFzqItcRAEm28tSUuMsgkiW7da7RvSLIKkKQa3L0URiynVgzZtBLEgsU5gDbFgrCBQ0NrtMDRippu2SLjMM0NjongwSkPIrv3Gi+E8yYVI2vq5cEozEmUxco5Vi6AYskIC65KBvAGATHUsgslgvFK93MkOTLuTPA8NTRVOfi/I/nkU1+QAJoEG4xe9IAM5xrbMFjFByWQOiYuwimdagayYBmguWIzaaDARpZMMIUxVekRmVAzsBc3ioJnrCUhdpxnTFMKLF8S8uIOGuaOQTqDMTRzCy5pkVr4FgKWYG0RTvUXBARhDIPKggMybGbiVB62q7Z+kzINi5e01L/PkWEi10mZ8n0/uu42PE3WtSjh+3p/1OSAAvqMngu5nIYYT+1HEQVOYI/nj2jekEhJGigNBJ6gL02CJRCfQtQPbklDgOTL5EEhJGuUZMERGIjSiCYQAkBkjhDRHTg0Ddy4q5e+o7XoAAWCx4vyP55CGuLBONSKMLYqUPJtEkglsTmgeLBsYEFpWIm3GjLLGCUrESXdFqfYssasoZQohtSyQyKWGrJJIXialJpgE5hIS2mahtrjMQu0OitsU5HmUZFY4FsM0PuUgQtmSWVmlOGWFIpahAstopoWUyQlgxAqYmjhyOJgkI+QzRTgky3xtYLvSj3aggEFLhoOfj9P7ruNjyAwBN62vYq7D612H1rsPrXYfWuw+tdh9a7D612H1rsPrXYfWuw+tdh9a7D612H1rsPrXYfWuw+tBskH19a3O9vW53t63O9vW53t63O9vW53t63O9vW53t63O9vW53t64svVNACAA4HkfkfzyYUZGmS2GGWzNKQPapzGQgyWHFGzNgWpNwQEp404qCPRSCFjvNKBhzAOcxYSX2q/HKWQxQEuzaBp+4s8BWRaUQzTcvE+Gca4W2tqSB2KjUJYmj8JoGc4ZOxpZJd0pMURJCLCwb8aZFfBWArgGWiylCMUBZmS9FQTpSPIkSGWyUheGQyvGDWx4/T+67jY8gEoDet72Ku4+ldx9K7j6V3H0ruPpXcfSu4+ldx9K7j6V3H0ruPpXcfSu4+ldx9K7j6V3H0ruPpQ7BJN/StjvbVsd7atjvbVsd7atjvbVsd7atjvbVsd7atjvbVsd7auLD1RQgkROJ5H5H88igmCYJtJm2tqWqvjkgiXAZpCYiChQsNJ43oQj5kVhZUuJtNL6YkFEEQiVza1ITiZEmENZJs6U4EKZJCUiQEazV4f0MkERZZfmrRxpxIkUFhqmKsYohrNcsIW1ockVCT0gmCRZagcqwSoBB65ozUEhdYLxsulIdovNycgKIvtTi2EbUIm4s7+P0/uu42PEnWlQrl+np/wDHYkERIS4712H/ACuw/wCV2H/K7D/ldh/yuw/5XYf8rsP+V2H/ACuw/wCV2H/KhnjrMNkLUIBGRueL8j+eSXRNL8y3IjotRbPWdImgLMb1le+obdJVjWyUb7QEr326Ii0TSYxj8SMy+MnrQRuHkl99kLTJNBGG01AOL8Z80px7GUqBgCXdLVHHt9tq3JQQ11qzs2cpDJNIZmrHggOAoiFmw+ylwpKQ+BI3aCu9T8YelUkunN16L0NKs2DIuXeFM7woGoQMFuDd8fp/ddxseOJ0f4fBeSHB9uA3UKagjQSAi6iTnBbdpLIV1KEy5N16JWMzFDQKybjFCNwYBsXLoiFrztUw84plSBVpDk4VjyNJBlwzZkLxUuK41INQ9xeKnFMEzqHVs+aQIVRlxAOJK7OdmrTw6cRkZgiS0NSuMUKbIs3ytGtSNCUggLRky5+KeA2EqZYOw3aGSYF4GFdJ46KnyNCgG9tJ9077ydsjWDBK1X0EDiweLcQUGY4vM1yEzBYi8t5ycKBTdAtiYYzFmosOUIKQLLIwg2WcVCAWqJKGW5KGEaE0hEkrm0LmxklvdBtUoLdMzGbkm7k50FBclAlSE2gxq8KEZsAGQkwUyYW9Cs46fipuRnH8oMKEBIFtFNOPhy0NBQ5vi/I/nkEkYoDAqS4RNquAyVMSAUGrFKYTwORMWMAS96H5JcLCmSR80+LlWVYSgMynaogWnfHScFk2moVMUTCEAQm29CFxeRSOs2VqnzpwknIWCxhUsFuQhMF0gNuSrsOHNhCBmQjhR9V7rEb5MBNTJOMiQXIyTU1ptHXlAmiOKanmBG2oQNxTv4/T+67jY8XYM5PWlDg6nDwhAIFCQgyMGs89aIIQwKt0SfBX1IBKRdwOlL3Yju3EQ/BSFRCBJIywmD2KeUrlW91vlqVRmghlJIMMb1hzlTZZl+WjoQwZhFKMNyXDWbbFUsRN0TGsUMFNXOBcoTAvEKCyulDCJGUsU0QhpjYo3PWkVE5DLAfQeAl0lCUTkkRjagZAIAwHi2/YkENyTQewjJeoSiL0MRdi8+iiTb8mLEyDdC8TRiKthAxIyCUTJZKJAlFCqyiBv61Cu4JECi4JRXRWYX1G2bKWoVCXhRizD6axNaSr4bbUvDWkXUQqV3agESUZri+AjxfkfzyNi9mBTo7HGk6bHRIwZs8aie/nmSqwnKXKRIdYyZJgEelCBkElGJCQF9kKL/Q68LkFDjNAMzSBRla9mParrdvpbIeC+I40uV10YsQ0ITFMS1ylgyQEIIkrWdHBnAOFmmeDYiJQyrq94ohIBNKMBsYZ40fpzZIBKWIub5ohiHKYhKrk+yPH6f3XcbHkdmXiFf6H+q7D1rsPWuw9a7D1rsPWuw9a7D1rsPWuw9a7D1rsPWuw9a7D1rsPWuw9a7D1rsPWpd3xmxkBo9dP+YMGDBgwYMGDBrlj9KYwksWGQVBfg8j8j+eRsjH0iQsJxmns4fYSrKza9MRKBpiEuemslDAmsSLjkJM24UDIHo0jbHENKeYCKbmEnE5Tis/6O0EYaqcqsSSkmAWA4/FabdpwhDIhLsTQoA56IhKSBi9ooc4boQpkHIkUWY0hkdyUgi8BSlvReBmSy3ViMU4QIdqXWYQYOFLfbIXMulnxfp/ddxsf+O/I/nlcBZKyQ68gSkJIyW8HJo0nIuWUvz4T6W8uZsCx2qOKDNAzk1GYmoPtDtEJxTgzUCcWTAZILGmYnetZpCCIwIY0K+dU02TnGua1mkIIjCjnUqCa1qwqEAZWp6k3OYCy1wOXj9P7ruNjyGEzKoRtibVASTMbTmsHRSZg3JjOgm9YG8W6EJGZf4acUVUwJRPIRolGpx5YIQZn2+KCMATSRYWBMwM5pMCQuTjfi9KQJuGWFIExm1ADdkW0zHs3xR8TQhcUS1WigQCBAQ1EItbFKiQCCtiBCNxym9IO8YING8Is5TFEE4sIYCsQpxUPrzxCwSFIzrpXt9tbM4o1PyAA4jN6YDygmezjU6zIWEAgZte+UxV1gz4lJZUw5DFXL2GJ6nSgZy4NFAkPqxQGXMJc9TvgpAKYwQ7sZpgngBCKSe3zTMwyMUxMTOYpufYOLzGu2tGhJARIQRM7xNOUpABFuTEsU9o0sUjESDRc6Oy20gPUgc7X9KYFfglRLwEXmeHkfkfzzateoCYGL5slRW3xxHeDGaJpIARJbF2BUEFQAWBqx3nhQcYh+sNC3fKRxWbUFIJABanF9G9IqmQjHBDrM6UtAEBtM+1m9B0MVIb8DX2r0NQw9Y8v0/uu42PIcsSgRwLiCnAtxpUUx2u9YKc1PUjpAjNUt5mPWmaU2VZUuzujeoOwZRCSWbIWhmGaCiORJWFUmRmQ1pnuIimWQirfYbWRQhn9z2KuCLsiFFRNNUcIoJMwQz9NTLTUExZGtpJWMxEQSDTRclLCAiF5K20JaHdzS0JvnuDXaZsNXc8ipOA0oNoZ+6eaNlA3BDuTFJeIdOAYgAgu41peMBDJhIliR4xii8gvcMjTknFqn4B4okyKcM54PShQYwXIUy7qT63elQGxNx1WJaWZiKicI4OEvq0YxCxdchTChgIgVuUVFLnUpezCckwv5Q0scRiAjaZmwxQtctwKF10NEb606GRorgWJTEMxS2AigFpcJrQTCoGIQvFpoe8kG+qYlA44PWmCJiKki5LjqMS00VlC1ICWQgt6q5PIjNpL+eYLSEEskyEplxiMzV+5FsJEBKMhl0pRGJoZAyJRqeik/CIk1gUdJYtBFr02BwHrpYRjBdJwimpHaZYSI1TDFRdNIFTYTJta73pECk6jpsHFuTwm5Qjyeq5GbPMZNlPf8Tvo4D9CWhjJTlegbO7o+3l+n913Gx/5ql+ZQgvG1KlWrKRdiJ5WrPCklfTwrTiJEnjHG9BRloNo4RwqFP3hDkUi33KP3IzQZKSIBcTFSN6SkM8HpRCxksgm+fo5UoAKlBliL+weX6f3Qw0mRZ4Fb7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mrfc1b7mpiFWLQ8ay/9zKv/9k=" alt="示例"><div class="color-gray">输入通用代ç (æš‚åªæ”¯æŒè…¾è®¯è§†é¢‘)</div><input type="text" class="form-control text-center" placeholder="通用代ç " ng-model="netWorkurl"><div><button class="btn btn-default" type="button" ng-click="fetchNetwork()">æå–</button></div></form></div></div><div class="modal-footer"><button type="button" class="btn btn-primary" data-dismiss="modal">确定</button> <button type="button" class="btn btn-default" data-dismiss="modal">å–消</button></div></div></div>'),e.put("directive-voice-voice.html",'<div class="modal-dialog modal-lg modal-material" ng-controller="we7resource-voice-controller as vctrl"><div class="modal-content"><we7-resource-voice is-wechat="isWechat" show-type="3"></we7-resource-voice></div></div>'),e.put("directive-wxapp-wxapp.html",'<div ng-controller="we7resource-wxapp-controller"><div class="modal-dialog modal-lg modal-material" ng-show="showWxapp"><div class="modal-content"><div class="modal-header"><h4 class="modal-title" id="myModalLabel4">å°ç¨‹åºå¡ç‰‡</h4><div class="material-nav"></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button></div><div class="modal-body material-content clearfix"><div id="wxapp" class="material-body we7-padding we7-form"><form action="" style="width: 100%" method="post" class="form-horizontal"><div class="form-group"><label class="col-sm-2 control-label">å¡ç‰‡æ ‡é¢˜</label><div class="col-sm-10"><input type="text" class="form-control" placeholder="å¡ç‰‡æ ‡é¢˜" ng-model="wxapp.title"></div></div><div class="form-group"><label class="col-sm-2 control-label">å°ç¨‹åºè·¯å¾„</label><div class="col-sm-10"><input type="text" class="form-control" placeholder="å°ç¨‹åºè·¯å¾„" ng-model="wxapp.pagepath"><div class="help-block">请è”ç³»å°ç¨‹åºå¼€å‘者获å–路径,比如/pages/index/index, 注æ„,路径建议以/开头。</div></div></div><div class="form-group"><label class="col-sm-2 control-label">å°ç¨‹åºAppid</label><div class="col-sm-10"><input type="text" class="form-control" placeholder="å°ç¨‹åºAppid" ng-model="wxapp.appid"><div class="help-block">å°ç¨‹åºå³ä¸Šè§’三个点>åå—>更多资料>Appid; 公众å·å†…回å¤æ—¶å¿…须跟å°ç¨‹åºæ˜¯å…³è”关系。</div></div></div><div class="form-group"><label for="" class="control-label col-sm-2">图片</label><div class="col-sm-10"><div class="we7-input-img input-more input-img" ng-click="showImage()" ng-class="{\'active\': wxapp.mediaid}"><img src="{{wxapp.mediaUrl}}" ng-if="wxapp.mediaid"> <a href="javascript:;" class="input-addon" ng-hide="wxapp.mediaid"><span>+</span></a> <input type="text" ng-model="wxapp.mediaid" ng-hide="true"><div class="cover-dark"><a href="" class="cut">æ›´æ¢</a></div></div><span class="help-block">图片建议控制在500K以内</span></div></div></form></div></div><div class="modal-footer"><button type="button" class="btn btn-primary" ng-click="add_wxapp()">确定</button> <button type="button" class="btn btn-default" data-dismiss="modal">å–消</button></div></div></div><we7-resource-image-dialog ng-show="!showWxapp"></we7-resource-image-dialog></div>'),e.put("widget-musicform-musicform.html",'<div class="modal-body material-content clearfix"><div id="music" class="material-body we7-form"><form action="" method="post" class="form-horizontal"><div class="form-group"><label class="col-sm-2 control-label">音ä¹æ ‡é¢˜</label><div class="col-sm-10"><input type="text" class="form-control" placeholder="æ·»åŠ éŸ³ä¹æ¶ˆæ¯çš„æ ‡é¢˜" ng-model="$ctrl.music.title"></div></div><div class="form-group"><label class="col-sm-2 control-label">选择音ä¹</label><div class="col-sm-10"><div class="input-group"><input type="text" class="form-control" readonly ng-model="$ctrl.music.name"> <input type="hidden" class="form-control" readonly ng-model="$ctrl.music.url"> <span class="input-group-btn"><button class="btn btn-default" type="button" ng-click="$ctrl.selectVoice()">选择媒体文件</button></span></div><div class="help-block">é€‰æ‹©ä¸Šä¼ çš„éŸ³é¢‘æ–‡ä»¶æˆ–ç›´æŽ¥è¾“å…¥URL地å€ï¼Œå¸¸ç”¨æ ¼å¼ï¼šmp3</div></div></div><div class="form-group"><label class="col-sm-2 control-label">高å“质链接</label><div class="col-sm-10"><input type="text" class="form-control" ng-model="$ctrl.music.HQUrl"><div class="help-block">没有高å“质音ä¹é“¾æŽ¥ï¼Œè¯·ç•™ç©ºã€‚高质é‡éŸ³ä¹é“¾æŽ¥ï¼ŒWIFI环境优先使用该链接æ’放音ä¹</div></div></div><div class="form-group"><label class="col-sm-2 control-label">æè¿°</label><div class="col-sm-10"><input type="text" class="form-control" ng-model="$ctrl.music.description"><div class="help-block">æ述内容将出现在音ä¹å称下方,建议控制在20个汉å—以内最佳</div></div></div></form></div></div><div class="modal-footer"><button type="button" class="btn btn-primary" ng-click="$ctrl.ok()">确定</button> <button type="button" class="btn btn-default" data-dismiss="modal">å–消</button></div>'),e.put("widget-upload-upload.html",'<label for="we7resourceFile" class="btn btn-primary">{{$ctrl.name}}</label><input type="file" id="we7resourceFile" multiple name="file" accept="{{$ctrl.accept}}" style="display: none"><div class="progress-uploader row" ng-repeat="(key, value) in $ctrl.files" ng-show="uploading" style="z-index: 9900"><div class="col-sm-3 text-over">{{value.name}}</div><div class="col-sm-2 color-gray">({{value.filesize}}KB)</div><div class="col-sm-7"><div class="progress"><div class="progress-bar" role="progressbar" aria-valuenow="60" aria-valuemin="0" aria-valuemax="100" style="width: {{value.progress}}%"></div></div></div></div>'),e.put("widget-voice-voice.html",'<div class="modal-header"><h4 class="modal-title" id="myModalLabel4">音ä¹</h4><div class="material-nav"><a href="javascript:;" ng-class="{true:\'active\',false:\'\'}[index==0]" ng-show="showWx()" ng-click="setIndex(0)">å¹³å°</a> <a href="javascript:;" ng-class="{true:\'active\',false:\'\'}[index == 1]" ng-show="showLocal()" ng-click="setIndex(1)">本地æœåŠ¡å™¨</a></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button></div><div class="modal-body material-content clearfix"><div class="material-head" ng-show="index!=2"><div class="search-box" role="form"><div class="input-group we7-margin-right-sm" style="width: 250px"><input class="form-control" ng-model="keyword" type="text" placeholder="请输入图片å称"> <span class="input-group-btn" ng-click="search()"><button class="btn btn-default"><i class="fa fa-search"></i></button></span></div><select name="" id="" class="we7-margin-right-sm" ng-change="search()" ng-model="order"><option value="asc">ä¸Šä¼ æ—¶é—´æ£åº</option><option value="desc">ä¸Šä¼ æ—¶é—´å€’åº</option><option value="filename_asc">å称æ£åº</option><option value="filename_desc">å称倒åº</option></select><div class="search-form"></div><div><we7-uploader-btn upload-url="uploadurl" on-uploaded="uploaded()" on-upload-error="uploaderror(mes)" name="uploadname" accept="accept"></we7-uploader-btn></div></div></div><div id="voice" class="material-body voice-content"><div class="row"><div class="col-sm-3" ng-repeat="(key, value) in $ctrl.voices" ng-click="$ctrl.itemClick(value)"><div class="item" ng-class="{true:\'active\',false:\'\'}[value.selected]"><img src="/web/resource/images/icon-voice.png" alt="" class="icon"><div class="time">创建于:{{ $ctrl.timeToDate(value.createtime) | date:\'yyyy-MM-dd HH:mm\' }}</div><div class="name">{{$ctrl.getTitle(value)}}</div><div class="check" ng-click="itemSelect($event, value)" data-check-id="{{value.id}}" ng-class="{checked: value.selected}"><i class="wi wi-right"></i></div><div class="action js-show-action" data-action-id="{{value.id}}" ng-click="showAction($event, value)"><i class="js-show-del"></i> <i class="wi wi-checking"></i></div></div></div></div></div><div class="material-pager text-right" ng-show="index!=2"><div class="we7-form form-inline selected-all"><input type="checkbox" id="selected-all" ng-model="selectedAllStatus" ng-change="selectedAll(selectedAllStatus)"><label for="selected-all">全选</label></div><div class="search-pager-aciton" ng-show="index < 2"><a href="javascript:;" class="color-red has-popover js-show-del" ng-click="showDel($event)" ng-disabled="getSelectedKeys().length == 0">åˆ é™¤</a></div><div class="page-box text-right" ng-bind-html="$ctrl.pager"></div></div></div><div class="modal-footer"><button type="button" class="btn btn-primary" ng-show="$ctrl.multiple">确定</button> <button type="button" class="btn btn-default" data-dismiss="modal">å–消</button></div>'),e.put("directive-multipage-multipage.html",'<div class="page-navigator"><div class="top-title">页é¢</div><div class="page-list"><ul><li class="page-menu" ng-repeat="page in allPages track by $index" ng-click="navToPage($index)" ng-init="" ng-class="{\'current\' : page.num-1 == $index}"><div class="page-thumb-block" ng-class="{active : page.active}"><div class="page-thumb"><div class="page-thumb-con"></div></div><div class="page-menu-title" ng-bind="{{$index+1}}"></div><div class="icon icon-remove" ng-click="removePage($index);"><span class="fa fa-trash"></span></div><div class="icon icon-copy" ng-click="copyPage($index, $event);" ng-if="isMultiPage"><span class="fa fa-copy"></span></div></div></li></ul></div><div class="add-blank-page" ng-click="insertPage();" ng-if="isMultiPage">+</div><div class="template hidden"><ul class="nav nav-tabs nav-justified"><li class="active"><a href="#">普通版å¼</a></li><li><a href="#">统计版å¼</a></li><li><a href="#">特效版å¼</a></li></ul><div class="template-area"><div class="template-item"><div class="add-icon"><span class="fa fa-plus-circle"></span></div><div class="text">空白页</div></div><div class="template-item"><img src="" alt=""></div><div class="template-item"><img src="" alt=""></div><div class="template-item"><img src="" alt=""></div><div class="template-item"><img src="" alt=""></div><div class="template-item"><img src="" alt=""></div><div class="template-item"><img src="" alt=""></div></div></div></div>'),e.put("widget-cardactivity-display.html",'<div ng-controller="CardActivityCtrl"><div class="nav-container" ng-if="module.params.discount_type != 0 && module.params.discount_style == 1"><div class="list-group"><div class="list-group-item"><a href="#">ä¼˜æƒ è¯´æ˜Ž <span class="pull-right"><i class="fa fa-angle-right"></i></span></a></div></div></div><div class="app-richText" ng-if="module.params.discount_type != 0 && module.params.discount_style == 2" ng-style="{\'background-color\' : module.params.bgColor}"><div class="inner" ng-bind-html="module.params.content" ng-if="module.params.content"></div><div class="inner js-default-content" ng-if="!module.params.content"><p>点æ¤ç¼–辑『富文本ã€å†…容 ——></p><p>ä½ å¯ä»¥å¯¹æ–‡å—进行 <strong>åŠ ç²—</strong>ã€<em>斜体</em>ã€<span style="text-decoration: underline">下划线</span>〠<span style="text-decoration: line-through">åˆ é™¤çº¿</span>ã€æ–‡å—<span style="color: rgb(0, 176, 240)">颜色</span>〠<span style="background-color: rgb(255, 192, 0); color: rgb(255, 255, 255)">背景色</span>〠以åŠå—å·<span style="font-size: 20px">大</span><span style="font-size: 14px">å°</span>ç‰ç®€å•æŽ’版æ“作。</p><p>还å¯ä»¥åœ¨è¿™é‡ŒåŠ å…¥è¡¨æ ¼äº†</p><table class="table-bordered"><tbody><tr><td>ä¸å¥–客户</td><td>å‘放奖å“</td><td>备注</td></tr><tr><td>猪猪</td><td>内测ç </td><td><em><span class="red">å·²ç»å‘放</span></em></td></tr><tr><td>大麦</td><td>积分</td><td><a href="#" target="_blank">领å–地å€</a></td></tr></tbody></table><p style="text-align: left"><span style="text-align: left">也å¯åœ¨è¿™é‡Œæ’入图片ã€å¹¶å¯¹å›¾ç‰‡åŠ 上超级链接,方便用户点击。</span></p></div></div></div>'),e.put("widget-cardactivity-editor.html",'<div ng-controller="CardActivityCtrl"><div class="app-header-setting"><div class="arrow-left"></div><div class="app-header-setting-inner"><div class="panel panel-default"><ul class="nav nav-tabs" style="margin:10px 15px 0 15px"><li ng-class="{\'active\' : activeItem.id == \'cardBasic\'}"><a href="javascript:;" ng-click="editItem(\'cardBasic\');">基本设置</a></li><li ng-class="{\'active\' : activeItem.id == \'cardActivity\'}"><a href="javascript:;" ng-click="editItem(\'cardActivity\');">æ¶ˆè´¹ä¼˜æƒ è®¾ç½®</a></li><li ng-class="{\'active\' : activeItem.id == \'cardRecharge\'}"><a href="javascript:;" ng-click="editItem(\'cardRecharge\');">å……å€¼ä¼˜æƒ è®¾ç½®</a></li><li ng-class="{\'active\' : activeItem.id == \'cardNums\'}"><a href="javascript:;" ng-click="editItem(\'cardNums\');">计次设置</a></li><li ng-class="{\'active\' : activeItem.id == \'cardTimes\'}"><a href="javascript:;" ng-click="editItem(\'cardTimes\');">计时设置</a></li></ul><div class="panel-body form-horizontal"><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 control-label">付款返积分比率</label><div class="col-sm-9 col-xs-12"><div class="input-group"><span class="input-group-addon">æ¯æ¶ˆè´¹ 1 å…ƒèµ é€</span> <input type="text" ng-model="activeItem.params.grant_rate" class="form-control"> <span class="input-group-addon">积分</span></div><div class="help-block">设置消费返积分的比率.如果开å¯äº†å……å€¼ä¼˜æƒ è®¾ç½®,è¯·åˆ°å……å€¼ä¼˜æƒ è®¾ç½®ä¸->设置消费是å¦è¿”还积分的开关.</div><div class="help-block"><strong class="text-danger">例:å…‘æ¢æ¯”率:1元返10积分,那用户æ¯æ¶ˆè´¹1å…ƒ,将得到10积分.</strong></div></div></div><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 control-label">ä¼˜æƒ è®¾ç½®</label><div class="col-sm-9 col-xs-12"><input type="radio" value="0" ng-model="activeItem.params.discount_type" id="discount_type1"><label class="radio-inline" for="discount_type1">ä¸å¼€å¯</label><input type="radio" value="1" ng-model="activeItem.params.discount_type" id="discount_type2"><label class="radio-inline" for="discount_type2">使用满å‡åŠŸèƒ½</label><input type="radio" value="2" ng-model="activeItem.params.discount_type" id="discount_type3"><label class="radio-inline" for="discount_type3">使用折扣功能</label></div></div><div class="form-group" ng-show="activeItem.params.discount_type == 1" ng-repeat="discount in activeItem.params.discounts"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><div class="input-group"><span class="input-group-addon">{{discount.title}}</span> <span class="input-group-addon">满</span> <input type="hidden" ng-model="discount.groupid"> <input type="text" class="form-control" ng-model="discount.condition_1"> <span class="input-group-addon">å…ƒ</span> <span class="input-group-addon">å‡</span> <input type="text" class="form-control" ng-model="discount.discount_1"> <span class="input-group-addon">å…ƒ</span></div></div></div><div class="form-group" ng-show="activeItem.params.discount_type == 2" ng-repeat="discount in activeItem.params.discounts"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><div class="input-group"><span class="input-group-addon">{{discount.title}}</span> <span class="input-group-addon">满</span> <input type="hidden" ng-model="discount.groupid"> <input type="text" class="form-control" ng-model="discount.condition_2"> <span class="input-group-addon">å…ƒ</span> <span class="input-group-addon">打</span> <input type="text" class="form-control" ng-model="discount.discount_2"> <span class="input-group-addon">折</span></div></div></div><div class="form-group" ng-show="activeItem.params.discount_type != 0"><label class="col-xs-12 col-sm-3 col-md-2 control-label">æ ·å¼è®¾ç½®</label><div class="col-sm-9 col-xs-12"><label class="radio-inline"><input type="radio" value="1" ng-model="activeItem.params.discount_style"> 系统默认</label><label class="radio-inline"><input type="radio" value="2" ng-model="activeItem.params.discount_style"> 自定义</label></div></div><div class="form-group" ng-show="activeItem.params.discount_type != 0 && activeItem.params.discount_style == 2"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><div class="input-group"><div we7-colorpicker we7-my-color="activeItem.params.bgColor" we7-my-default-color="\'#ffffff\'"></div></div></div></div><div class="form-group" ng-show="activeItem.params.discount_type != 0 && activeItem.params.discount_style == 2"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><div we7-editor we7-my-value="activeItem.params.content"></div></div></div></div></div></div></div></div>'),e.put("widget-cardbasic-display.html",'<div ng-controller="CardBasicCtrl"><div class="title"><h1><span>会员å¡</span></h1></div><div class="card"><div class="card-panel"><div class="card-logo"><img src="" ng-if="module.params.logo" ng-src="{{module.params.logo}}"></div><img class="card-bg" src="" ng-if="module.params.background.image" ng-src="{{module.params.background.image}}"><div class="card-grade" ng-if="module.params.card_level.type == \'1\'" ng-style="{\'color\' : module.params.color.rank}">默认会员组</div><div class="card-info"><div class="text-center" ng-if="module.params.card_label.type == \'1\'"><span class="card-rank" ng-style="{\'color\' : module.params.color.title}" ng-bind="module.params.card_label.title"></span></div><div class="card-no text-right" ng-if="!module.params.format_type" ng-style="{\'color\' : module.params.color.number}" ng-bind="module.params.format">会员å¡å·:<span>{$setting[\'format\']}</span></div></div></div></div><div class="btn-manage clearfix"><a href="javascript:;" class="recharge"><img ng-src="{{recharge_src}}" alt=""> <span>充值</span></a> <a href="javascript:;" class="payment"><img ng-src="{{scanpay_src}}" alt=""> <span>付款</span></a></div><div class="list-group"><div class="list-group-item"><a href="#">æˆ‘çš„ä½™é¢ <span class="pull-right">0.00 <i class="fa fa-angle-right"></i></span></a></div><div class="list-group-item"><a href="#">我的积分 <span class="pull-right">0.00 <i class="fa fa-angle-right"></i></span></a></div><div class="list-group-item"><a href="#">我的å¡åˆ¸ <span class="pull-right">0å¼ <i class="fa fa-angle-right"></i></span></a></div></div><div class="list-group"><div class="list-group-item"><a href="#">æ¶ˆæ¯ <span class="pull-right"><i class="fa fa-angle-right"></i></span></a></div></div><div class="list-group"><div class="list-group-item"><a href="#">ä¸ªäººä¿¡æ¯ <span class="pull-right"><i class="fa fa-angle-right"></i></span></a></div><div class="list-group-item"><a href="#">è´¦å• <span class="pull-right"><i class="fa fa-angle-right"></i></span></a></div></div></div>'),e.put("widget-cardbasic-editor.html",'<div ng-controller="CardBasicCtrl"><div class="app-header-setting"><div class="arrow-left"></div><div class="app-header-setting-inner"><div class="panel panel-default"><ul class="nav nav-tabs" style="margin:10px 15px 0 15px"><li ng-class="{\'active\' : activeItem.id == \'cardBasic\'}"><a href="javascript:;" ng-click="editItem(\'cardBasic\');">基本设置</a></li><li ng-class="{\'active\' : activeItem.id == \'cardActivity\'}"><a href="javascript:;" ng-click="editItem(\'cardActivity\');">æ¶ˆè´¹ä¼˜æƒ è®¾ç½®</a></li><li ng-class="{\'active\' : activeItem.id == \'cardRecharge\'}"><a href="javascript:;" ng-click="editItem(\'cardRecharge\');">å……å€¼ä¼˜æƒ è®¾ç½®</a></li><li ng-class="{\'active\' : activeItem.id == \'cardNums\'}"><a href="javascript:;" ng-click="editItem(\'cardNums\');">计次设置</a></li><li ng-class="{\'active\' : activeItem.id == \'cardTimes\'}"><a href="javascript:;" ng-click="editItem(\'cardTimes\');">计时设置</a></li></ul><div class="panel-body form-horizontal"><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 control-label">å称<span style="color:red">*</span></label><div class="col-sm-9 col-xs-12"><input type="text" class="form-control" ng-model="activeItem.params.title"></div></div><div class="form-group" ng-if="newcard"><label class="col-xs-12 col-sm-3 col-md-2 control-label">商户å称<span style="color:red">*</span></label><div class="col-sm-9 col-xs-12"><input type="text" class="form-control" ng-model="activeItem.params.brand_name"></div></div><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 control-label">背景图案<span style="color:red">*</span></label><div class="col-sm-9 col-xs-12"><label class="radio-inline"><input type="radio" value="system" ng-init="activeItem.params.background && activeItem.params.background == 0 ? activeItem.params.background = {} : \'\'" ng-model="activeItem.params.background.type"> 系统</label><label class="radio-inline"><input type="radio" value="user" ng-init="activeItem.params.background && activeItem.params.background == 0 ? activeItem.params.background = {} : \'\'" ng-model="activeItem.params.background.type"> 自定义</label></div></div><div class="form-group" ng-if="activeItem.params.background.type == \'user\'"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-xs-9"><span ng-click="addBgThumb()" class="form-control-static"><i class="fa fa-plus-circle green"></i> 选择图片</span><div style="margin-top:.5em" class="input-group" ng-show="activeItem.params.background.image"><img width="150" class="img-responsive img-thumbnail" ng-src="{{activeItem.params.background.image}}"> <em ng-click="activeItem.params.background.image = \'\';" title="åˆ é™¤è¿™å¼ å›¾ç‰‡" style="position:absolute; top: 0px; right: -14px" class="close">×</em></div></div></div><div class="form-group" ng-if="activeItem.params.background.type == \'system\'"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><select class="form-control" ng-model="activeItem.params.background.image"><option value="{{tomedia(\'images/global/card/1.png\')}}">背景1</option><option value="{{tomedia(\'images/global/card/2.png\')}}">背景2</option><option value="{{tomedia(\'images/global/card/3.png\')}}">背景3</option><option value="{{tomedia(\'images/global/card/4.png\')}}">背景4</option><option value="{{tomedia(\'images/global/card/5.png\')}}">背景5</option><option value="{{tomedia(\'images/global/card/6.png\')}}">背景6</option><option value="{{tomedia(\'images/global/card/7.png\')}}">背景7</option><option value="{{tomedia(\'images/global/card/8.png\')}}">背景8</option><option value="{{tomedia(\'images/global/card/9.png\')}}">背景9</option><option value="{{tomedia(\'images/global/card/10.png\')}}">背景10</option><option value="{{tomedia(\'images/global/card/11.png\')}}">背景11</option><option value="{{tomedia(\'images/global/card/12.png\')}}">背景12</option><option value="{{tomedia(\'images/global/card/13.png\')}}">背景13</option><option value="{{tomedia(\'images/global/card/14.png\')}}">背景14</option><option value="{{tomedia(\'images/global/card/15.png\')}}">背景15</option><option value="{{tomedia(\'images/global/card/16.png\')}}">背景16</option><option value="{{tomedia(\'images/global/card/17.png\')}}">背景17</option><option value="{{tomedia(\'images/global/card/18.png\')}}">背景18</option><option value="{{tomedia(\'images/global/card/19.png\')}}">背景19</option><option value="{{tomedia(\'images/global/card/20.png\')}}">背景20</option><option value="{{tomedia(\'images/global/card/21.png\')}}">背景21</option><option value="{{tomedia(\'images/global/card/22.png\')}}">背景22</option><option value="{{tomedia(\'images/global/card/23.png\')}}">背景23</option></select></div></div><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 control-label">LOGO<span style="color:red">*</span></label><div class="col-sm-9 col-xs-12"><span ng-click="addThumb(\'logo\')" class="form-control-static"><i class="fa fa-plus-circle green"></i> 选择图片</span><div style="margin-top:.5em" class="input-group" ng-show="activeItem.params.logo"><img width="150" class="img-responsive img-thumbnail" ng-src="{{activeItem.params.logo}}"> <em ng-click="activeItem.params.logo = \'\';" title="åˆ é™¤è¿™å¼ å›¾ç‰‡" style="position:absolute; top: 0px; right: -14px" class="close">×</em></div></div></div><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 control-label">会员å¡ç‰çº§</label><div class="col-sm-9 col-xs-12"><input type="radio" value="1" ng-model="activeItem.params.card_level.type" id="card-label-type1"><label class="radio-inline" for="card-level-type1">å¼€å¯</label><input type="radio" value="2" ng-model="activeItem.params.card_level.type" id="card-label-type2"><label class="radio-inline" for="card-level-type2">å…³é—</label></div></div><div class="form-group" ng-show="activeItem.params.card_level.type == \'1\'"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><div we7-colorpicker we7-my-color="activeItem.params.color.rank" we7-my-default-color="\'#fff\'"></div></div></div><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 control-label">会员å¡æ ‡é¢˜</label><div class="col-sm-9 col-xs-12"><input type="radio" value="1" ng-model="activeItem.params.card_label.type" id="card-label-type1"><label class="radio-inline" for="card-label-type1">å¼€å¯</label><input type="radio" value="2" ng-model="activeItem.params.card_label.type" id="card-label-type2"><label class="radio-inline" for="card-label-type2">å…³é—</label></div></div><div class="form-group" ng-show="activeItem.params.card_label.type == \'1\'"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><input type="text" ng-model="activeItem.params.card_label.title" class="form-control"><br><span><span><div we7-colorpicker we7-my-color="activeItem.params.color.title" we7-my-default-color="\'Color010\'"></div></span></span></div></div><div class="form-group" style="display:none"><label class="col-xs-12 col-sm-3 col-md-2 control-label">å¡å·è®¾ç½®<span style="color:red">*</span></label><div class="col-sm-9 col-xs-12"><label class="checkbox-inline"><input type="checkbox" value="1" ng-model="activeItem.params.format_type" ng-init="activeItem.params.format_type = (activeItem.params.format_type == 1 ? true : false)"> 使用手机å·ä½œä¸ºå¡å·</label><span class="help-block">强烈推è使用手机å·ä½œä¸ºå¡å·</span><div ng-show="activeItem.params.format_type != 1"><input name="format" type="text" ng-model="activeItem.params.format" ng-init="activeItem.params.format = \'\'" class="form-control"> <span class="help-block"><p>"*"代表任æ„éšæœºæ•°å—,<span style="color:red">"#"代表æµæ°´å·ç , "#"必须连ç»å‡ºçŽ°,且åªèƒ½å˜åœ¨ä¸€ç»„.</span></p><p>å¡å·è§„åˆ™æ ·æœ¬ï¼š"WQ2015*****#####***"</p>注æ„:规则ä½æ•°è¿‡å°ä¼šé€ æˆå¡å·ç”Ÿæˆé‡å¤æ¦‚率增大,过多的é‡å¤å¡å¯†ä¼šé€ æˆå¡å¯†ç”Ÿæˆç»ˆæ¢ å¡å¯†è§„则ä¸ä¸èƒ½å¸¦æœ‰ä¸æ–‡åŠå…¶ä»–ç‰¹æ®Šç¬¦å· ä¸ºäº†é¿å…å¡å¯†é‡å¤ï¼Œéšæœºä½æ•°æœ€å¥½ä¸è¦å°‘于8ä½</span></div></div></div><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 control-label">使用说明<span style="color:red">*</span></label><div class="col-sm-9 col-xs-12"><textarea class="form-control" rows="6" ng-model="activeItem.params.description"></textarea><span class="help-block">请填写会员å¡çš„使用说明。</span></div></div><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 control-label">会员å¡èµ„æ–™</label><div class="col-sm-10 col-xs-9"><div ng-repeat="field in activeItem.params.fields" style="margin-left:-15px"><div class="col-sm-10" style="margin-bottom:10px"><div class="input-group"><input type="text" class="form-control" ng-model="field.title" ng-disabled="(field.bind == \'realname\' || field.bind == \'mobile\') && $index <= \'1\'"> <span class="input-group-addon"><label><input type="checkbox" ng-init="field.require = field.require == 1 ? true : false;" ng-model="field.require" ng-disabled="(field.bind == \'realname\' || field.bind == \'mobile\') && $index <= \'1\'"> å¿…å¡«</label></span><select ng-model="field.bind" class="form-control" ng-disabled="(field.bind == \'realname\' || field.bind == \'mobile\') && $index <= \'1\'"><option value="{{fansfield.bind}}" ng-repeat="fansfield in fansFields" ng-model="field.bind" ng-selected="{{field.bind == fansfield.bind}}">{{fansfield.title}}</option></select></div></div><div class="col-sm-1" style="margin-top:5px" ng-show="field.bind != \'mobile\' && field.bind != \'realname\'"><a href="javascript:;" ng-click="removeFields(field);"><i class="fa fa-times-circle"></i></a></div></div><span class="help-block col-sm-9" style="margin-left:-15px">系统会自动绑定:真实姓å和手机å·ç </span> <span class="help-block col-sm-9" style="margin-left:-15px"><a href="javascript:;" ng-click="addFields();"><i class="fa fa-plus-circle" title="æ·»åŠ å¡«å†™é¡¹ç›®"></i> æ·»åŠ å¡«å†™é¡¹ç›®</a></span></div></div><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 control-label">领å¡èµ é€<span style="color:red">*</span></label><div class="col-sm-9 col-xs-12"><div class="input-group"><span class="input-group-addon" ng-init="activeItem.params.grant && activeItem.params.grant == 0 ? activeItem.params.grant = {} : \'\'">èµ é€</span> <input type="text" ng-model="activeItem.params.grant.credit1" class="form-control"> <span class="input-group-addon">积分</span></div></div></div><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><div class="input-group"><span class="input-group-addon">èµ é€</span> <input type="text" ng-model="activeItem.params.grant.credit2" class="form-control"> <span class="input-group-addon">ä½™é¢</span></div></div></div><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><div class="input-group"><input type="hidden" ng-model="activeItem.params.grant.coupon"> <span class="input-group-addon text-over" style="max-width: 240px">已选:<span ng-repeat="grant in activeItem.params.grant.coupon"><span ng-bind="grant.couponTitle">{{grant.couponTitle}}</span>|</span></span> <span class="input-group-btn"><button class="btn btn-primary" type="button" ng-click="selectCoupon();">æœç´¢ä¼˜æƒ 券</button> <button class="btn btn-default" type="button" ng-click="clearCoupon();"><span><i class="fa fa-remove"></i></span></button></span></div><div class="help-block"><a href="{{url(\'activity/coupon\');}}" target="_blank">æ·»åŠ ä¼˜æƒ åˆ¸</a>.注æ„:èµ é€çš„ä¼˜æƒ åˆ¸åº”è¯¥å„个会员组都å¯ä»¥é¢†å–.å¦åˆ™ä¼šé€ æˆèµ é€å¤±è´¥çš„问题</div></div></div><div class="form-group" ng-if="newcard"><label class="col-xs-12 col-sm-3 col-md-2 control-label">å•æ¬¡ç§¯åˆ†<span style="color:red">*</span></label><div class="col-sm-9 col-xs-12"><input type="text" ng-model="activeItem.params.bonus_rule.max_increase_bonus" class="form-control"> <span class="help-block">å•æ¬¡æœ€å¤šå¯èŽ·å–积分数é‡</span></div></div><div class="form-group" ng-if="newcard"><label class="col-xs-12 col-sm-3 col-md-2 control-label">抵扣æ¡ä»¶<span style="color:red">*</span></label><div class="col-sm-9 col-xs-12"><input type="text" ng-model="activeItem.params.bonus_rule.least_money_to_use_bonus" class="form-control"> <span class="help-block">满足xx元,å¯ä½¿ç”¨ç§¯åˆ†æŠµæ‰£</span></div></div><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 control-label">抵现比率<span style="color:red">*</span></label><div class="col-sm-9 col-xs-12"><div class="input-group"><input type="text" ng-model="activeItem.params.offset_rate" class="form-control"> <span class="input-group-addon">积分抵 1 å…ƒ</span></div><br><div class="input-group"><span class="input-group-addon">å•æ¬¡æœ€å¤šå¯æŠµçŽ°</span> <input type="text" ng-model="activeItem.params.offset_max" class="form-control"> <span class="input-group-addon">å…ƒ</span></div><div class="help-block"><strong class="text-danger">例:积分抵现金比率:100积分抵1å…ƒ,那用户在消费的时候,å°†å¯ç”¨è´¦æˆ·ç§¯åˆ†æŠµæ¶ˆéƒ¨åˆ†é‡‘é¢.</strong></div><div class="help-block"><strong class="text-danger">ç›®å‰ä»…支æŒåŽå°äº¤æ˜“抵现,暂ä¸æ”¯æŒæ‰‹æœºäº¤æ˜“抵现.</strong></div></div></div><div class="form-group" ng-if="newcard"><label class="col-xs-12 col-sm-3 col-md-2 control-label">库å˜<span style="color:red">*</span></label><div class="col-sm-9 col-xs-12"><input type="text" ng-model="activeItem.params.quantity" class="form-control"> <span class="help-block">å¡åˆ¸åº“å˜çš„æ•°é‡ï¼Œä¸æ”¯æŒå¡«å†™0,上é™ä¸º100000000.</span></div></div><div class="form-group" ng-if="newcard"><label class="col-xs-12 col-sm-3 col-md-2 control-label">使用æ醒<span style="color:red">*</span></label><div class="radio"><div class="col-sm-9 col-xs-12"><input type="text" ng-model="activeItem.params.notice" class="form-control"> <span class="help-block">å¡åˆ¸ä½¿ç”¨æ醒,å—数上é™ä¸º16个汉å—。</span></div></div></div><div class="form-group" ng-if="newcard"><label class="col-xs-12 col-sm-3 col-md-2 control-label">刷å¡æ”¯ä»˜<span style="color:red">*</span></label><div class="col-sm-9 col-xs-12"><label class="radio-inline"><input type="radio" ng-model="activeItem.params.swipe_card" value="1">å¼€å¯</label><label class="radio-inline"><input type="radio" ng-checked="activeItem.params.swipe_card == null || activeItem.params.swipe_card == 2" ng-model="activeItem.params.swipe_card" value="2">å…³é—</label><span class="help-block">选择是å¦å¼€å¯åˆ·å¡æ”¯ä»˜</span></div></div><div class="form-group" ng-if="newcard"><label class="col-xs-12 col-sm-3 col-md-2 control-label">有效日期<span style="color:red">*</span></label><div class="col-sm-9 col-xs-12"><label class="radio-inline"><input type="radio" ng-model="activeItem.params.date_info.type" value="DATE_TYPE_PERMANENT"> 永久有效</label></div></div><div class="form-group" ng-if="newcard"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><div class="radio"><div class="col-sm-3"><label class="radio-inline"><input type="radio" ng-model="activeItem.params.date_info.type" value="DATE_TYPE_FIX_TIME_RANGE"> 固定日期</label></div><div class="input-group" style="width: 240px"><input we7-date-picker we7-date-value="activeItem.params.date_info.begin_timestamp" ng-model="activeItem.params.date_info.begin_timestamp" class="form-control" style="width: 100px"><div class="input-group-addon">到</div><input we7-date-picker we7-date-value="activeItem.params.date_info.end_timestamp" ng-model="activeItem.params.date_info.end_timestamp" class="form-control" style="width: 100px"></div></div></div></div><div class="form-group" ng-if="newcard"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><label class="radio-inline"><input ng-model="activeItem.params.date_info.type" type="radio" value="DATE_TYPE_FIX_TERM">领å–åŽ</label><div class="input-group" style="width: 240px"><input ng-model="activeItem.params.date_info.fixed_begin_term" class="form-control" style="width: 100px"> <span class="input-group-addon">天生效,有效期</span> <input ng-model="activeItem.params.date_info.fixed_term" class="form-control" style="width: 100px"></div></div></div><div class="form-group" ng-if="newcard"><label class="col-xs-12 col-sm-3 col-md-2 control-label">å¯ç”¨é—¨åº—</label><div class="col-sm-9 col-xs-12"><label class="radio-inline"><a href="#" class="location_list">选择适用门店</a></label></div></div></div></div></div></div></div>'),e.put("widget-cardnums-display.html",'<div ng-controller="CardNumsCtrl"><div class="nav-container" ng-if="module.params.nums_status == 1 && module.params.nums_style == 1"><ul><li class="collapse-link"><a class="nav-container-list" href="javascript:;"><span class="nav-title"><i class="fa fa-eye"></i>{{module.params.nums_text}}充值</span> <span class="pull-right"><i class="fa fa-angle-right"></i></span></a><div class="collapse-con padding-b-0"><a href="./index.php?i={$_W[\'uniacid\']}&j={$_W[\'acid\']}&c=entry&m=recharge&do=pay&type=card_nums&fee={{num.recharge}}" class="btn btn-warning btn-recharge" ng-repeat="num in module.params.nums">å……{{num.recharge}}è¿”{{num.num}}次</a></div></li></ul></div><div class="app-richText" ng-if="module.params.nums_status == 1 && module.params.nums_style == 2" ng-style="{\'background-color\' : module.params.bgColor}"><div class="inner" ng-bind-html="module.params.content" ng-if="module.params.content"></div><div class="inner js-default-content" ng-if="!module.params.content"><p>点æ¤ç¼–辑『富文本ã€å†…容 ——></p><p>ä½ å¯ä»¥å¯¹æ–‡å—进行 <strong>åŠ ç²—</strong>ã€<em>斜体</em>ã€<span style="text-decoration: underline">下划线</span>〠<span style="text-decoration: line-through">åˆ é™¤çº¿</span>ã€æ–‡å—<span style="color: rgb(0, 176, 240)">颜色</span>〠<span style="background-color: rgb(255, 192, 0); color: rgb(255, 255, 255)">背景色</span>〠以åŠå—å·<span style="font-size: 20px">大</span><span style="font-size: 14px">å°</span>ç‰ç®€å•æŽ’版æ“作。</p><p>还å¯ä»¥åœ¨è¿™é‡ŒåŠ å…¥è¡¨æ ¼äº†</p><table class="table-bordered"><tbody><tr><td>ä¸å¥–客户</td><td>å‘放奖å“</td><td>备注</td></tr><tr><td>猪猪</td><td>内测ç </td><td><em><span class="red">å·²ç»å‘放</span></em></td></tr><tr><td>大麦</td><td>积分</td><td><a href="#" target="_blank">领å–地å€</a></td></tr></tbody></table><p style="text-align: left"><span style="text-align: left">也å¯åœ¨è¿™é‡Œæ’入图片ã€å¹¶å¯¹å›¾ç‰‡åŠ 上超级链接,方便用户点击。</span></p></div></div></div>'),e.put("widget-cardnums-editor.html",'<div ng-controller="CardNumsCtrl"><div class="app-header-setting"><div class="arrow-left"></div><div class="app-header-setting-inner"><div class="panel panel-default"><ul class="nav nav-tabs" style="margin:10px 15px 0 15px"><li ng-class="{\'active\' : activeItem.id == \'cardBasic\'}"><a href="javascript:;" ng-click="editItem(\'cardBasic\');">基本设置</a></li><li ng-class="{\'active\' : activeItem.id == \'cardActivity\'}"><a href="javascript:;" ng-click="editItem(\'cardActivity\');">æ¶ˆè´¹ä¼˜æƒ è®¾ç½®</a></li><li ng-class="{\'active\' : activeItem.id == \'cardRecharge\'}"><a href="javascript:;" ng-click="editItem(\'cardRecharge\');">å……å€¼ä¼˜æƒ è®¾ç½®</a></li><li ng-class="{\'active\' : activeItem.id == \'cardNums\'}"><a href="javascript:;" ng-click="editItem(\'cardNums\');">计次设置</a></li><li ng-class="{\'active\' : activeItem.id == \'cardTimes\'}"><a href="javascript:;" ng-click="editItem(\'cardTimes\');">计时设置</a></li></ul><div class="panel-body form-horizontal"><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 control-label">计次设置</label><div class="col-sm-9 col-xs-12"><input type="radio" value="1" ng-model="activeItem.params.nums_status" id="nums_status1"><label class="radio-inline" for="nums_status1">å¼€å¯</label><input type="radio" value="0" ng-model="activeItem.params.nums_status" id="nums_status2"><label class="radio-inline" for="nums_status2">å…³é—</label><span class="help-block">å¦‚ä½ çš„ä¸šåŠ¡æœ‰éœ€è¦æ¬¡æ•°é™åˆ¶ï¼Œå¯å¼€å¯è¿›è¡Œè®¾ç½®ã€‚</span></div></div><div class="form-group" ng-show="activeItem.params.nums_status == 1"><label class="col-xs-12 col-sm-3 col-md-2 control-label">计次设置</label><div class="col-sm-9 col-xs-12"><input type="text" class="form-control" ng-model="activeItem.params.nums_text"> <span class="help-block">例如:设置为â€æ´—å‘剩余次数“,å‰å°å°†æ˜¾ç¤ºä¸ºï¼šâ€æ´—å‘剩余次数:n次“,è¯·æ ¹æ®è‡ªå·±çš„业务需求设置。</span></div></div><div class="form-group" ng-show="activeItem.params.nums_status == 1"><label class="col-xs-12 col-sm-3 col-md-2 control-label">充值返次数</label><div class="col-sm-9 col-xs-12"><div ng-repeat="num in activeItem.params.nums" style="margin-left:-15px"><div class="col-sm-8" style="margin-bottom:10px"><div class="input-group"><span class="input-group-addon">å……</span> <input type="text" class="form-control" ng-model="num.recharge"> <span class="input-group-addon">å…ƒ</span> <input type="text" class="form-control" ng-model="num.num"> <span class="input-group-addon">次</span></div></div><div class="col-sm-1" style="margin-top:5px"><a href="javascript:;" ng-click="removeNums(num);"><i class="fa fa-times-circle"></i></a></div></div><div class="help-block col-sm-9" style="margin-left:-15px"><a href="javascript:;" ng-click="addNums();"><i class="fa fa-plus-circle" title="æ·»åŠ å……å€¼è®¾ç½®"></i> æ·»åŠ å……å€¼è®¾ç½®</a></div></div></div><div class="form-group" ng-show="activeItem.params.nums_status != 0"><label class="col-xs-12 col-sm-3 col-md-2 control-label">æ ·å¼è®¾ç½®</label><div class="col-sm-9 col-xs-12"><label class="radio-inline"><input type="radio" value="1" ng-model="activeItem.params.nums_style"> 系统默认</label><label class="radio-inline"><input type="radio" value="2" ng-model="activeItem.params.nums_style"> 自定义</label></div></div><div class="form-group" ng-show="activeItem.params.nums_status != 0 && activeItem.params.nums_style == 2"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><div class="input-group"><div we7-colorpicker we7-my-color="activeItem.params.bgColor" we7-my-default-color="\'#ffffff\'"></div></div></div></div><div class="form-group" ng-show="activeItem.params.nums_status != 0 && activeItem.params.nums_style == 2"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><div we7-editor we7-my-value="activeItem.params.content"></div></div></div></div></div></div></div></div>'),e.put("widget-cardrecharge-display.html",'<div ng-controller="CardRechargeCtrl"><div class="nav-container" ng-if="module.params.recharge_type != 0 && module.params.recharge_style == 1"><div class="list-group"><div class="list-group-item"><a href="#">å……å€¼ä¼˜æƒ è¯´æ˜Ž <span class="pull-right"><i class="fa fa-angle-right"></i></span></a></div></div></div><div class="app-richText" ng-if="module.params.discount_type != 0 && module.params.discount_style == 2" ng-style="{\'background-color\' : module.params.bgColor}"><div class="inner" ng-bind-html="module.params.content" ng-if="module.params.content"></div><div class="inner js-default-content" ng-if="!module.params.content"><p>点æ¤ç¼–辑『富文本ã€å†…容 ——></p><p>ä½ å¯ä»¥å¯¹æ–‡å—进行 <strong>åŠ ç²—</strong>ã€<em>斜体</em>ã€<span style="text-decoration: underline">下划线</span>〠<span style="text-decoration: line-through">åˆ é™¤çº¿</span>ã€æ–‡å—<span style="color: rgb(0, 176, 240)">颜色</span>〠<span style="background-color: rgb(255, 192, 0); color: rgb(255, 255, 255)">背景色</span>〠以åŠå—å·<span style="font-size: 20px">大</span><span style="font-size: 14px">å°</span>ç‰ç®€å•æŽ’版æ“作。</p><p>还å¯ä»¥åœ¨è¿™é‡ŒåŠ å…¥è¡¨æ ¼äº†</p><table class="table-bordered"><tbody><tr><td>ä¸å¥–客户</td><td>å‘放奖å“</td><td>备注</td></tr><tr><td>猪猪</td><td>内测ç </td><td><em><span class="red">å·²ç»å‘放</span></em></td></tr><tr><td>大麦</td><td>积分</td><td><a href="#" target="_blank">领å–地å€</a></td></tr></tbody></table><p style="text-align: left"><span style="text-align: left">也å¯åœ¨è¿™é‡Œæ’入图片ã€å¹¶å¯¹å›¾ç‰‡åŠ 上超级链接,方便用户点击。</span></p></div></div></div>'),e.put("widget-cardrecharge-editor.html",'<div ng-controller="CardRechargeCtrl"><div class="app-header-setting"><div class="arrow-left"></div><div class="app-header-setting-inner"><div class="panel panel-default"><ul class="nav nav-tabs" style="margin:10px 15px 0 15px"><li ng-class="{\'active\' : activeItem.id == \'cardBasic\'}"><a href="javascript:;" ng-click="editItem(\'cardBasic\');">基本设置</a></li><li ng-class="{\'active\' : activeItem.id == \'cardActivity\'}"><a href="javascript:;" ng-click="editItem(\'cardActivity\');">æ¶ˆè´¹ä¼˜æƒ è®¾ç½®</a></li><li ng-class="{\'active\' : activeItem.id == \'cardRecharge\'}"><a href="javascript:;" ng-click="editItem(\'cardRecharge\');">å……å€¼ä¼˜æƒ è®¾ç½®</a></li><li ng-class="{\'active\' : activeItem.id == \'cardNums\'}"><a href="javascript:;" ng-click="editItem(\'cardNums\');">计次设置</a></li><li ng-class="{\'active\' : activeItem.id == \'cardTimes\'}"><a href="javascript:;" ng-click="editItem(\'cardTimes\');">计时设置</a></li></ul><div class="panel-body form-horizontal"><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 control-label">ä¼˜æƒ è®¾ç½®</label><div class="col-sm-9 col-xs-12"><input type="radio" value="1" ng-model="activeItem.params.recharge_type" id="recharge_type1"><label class="radio-inline" for="recharge_type1">å¼€å¯</label><input type="radio" value="0" ng-model="activeItem.params.recharge_type" id="recharge_type2"><label class="radio-inline" for="recharge_type2">ä¸å¼€å¯</label></div></div><div class="form-group" ng-show="activeItem.params.recharge_type == 1" ng-repeat="recharge in activeItem.params.recharges"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><div class="input-group"><span class="input-group-addon">å……</span> <input type="text" class="form-control" ng-model="recharge.condition"> <span class="input-group-addon">å…ƒ</span> <span class="input-group-addon" ng-if="recharge.backtype == \'0\'">é€</span> <span class="input-group-addon" ng-if="recharge.backtype == \'1\'">é€</span> <input type="text" class="form-control" ng-model="recharge.back"><div class="input-group-btn"><button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" style="width:88px"><span ng-switch on="recharge.backtype"><span ng-switch-when="0">å…ƒ</span> <span ng-switch-when="1">积分</span></span> <i class="fa fa-angle-down"></i></button><ul class="dropdown-menu dropdown-menu-right select-back"><li><a href="#" ng-click="recharge.backtype=\'0\';recharge.backunit=\'å…ƒ\'">å…ƒ</a></li><li><a href="#" ng-click="recharge.backtype=\'1\';recharge.backunit=\'积分\'">积分</a></li></ul></div></div></div><div class="col-sm-1" style="margin-top:5px"><a href="javascript:;" ng-click="removeRecharges(recharge);"><i class="fa fa-times-circle"></i></a></div></div><div class="form-group" ng-show="activeItem.params.recharge_type != 0"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="help-block col-sm-9 col-xs-12" style="margin-left:-15px"><a href="javascript:;" ng-click="addRecharges();"><i class="fa fa-plus-circle" title="æ·»åŠ å……å€¼è®¾ç½®"></i> æ·»åŠ å……å€¼è®¾ç½®</a></div></div><div class="form-group" ng-show="activeItem.params.recharge_type == 1"><label class="col-xs-12 col-sm-3 col-md-2 control-label">消费返积分</label><div class="col-sm-9 col-xs-12"><label class="radio-inline"><input type="radio" value="1" ng-model="activeItem.params.grant_rate_switch"> 是</label><label class="radio-inline"><input type="radio" value="0" ng-model="activeItem.params.grant_rate_switch"> å¦</label><div class="help-block"><strong class="text-danger">å¼€å¯å……å€¼ä¼˜æƒ è®¾ç½®åŽ,用户是å¦ç»§ç»äº«å—æ¶ˆè´¹è¿”ç§¯åˆ†çš„ä¼˜æƒ </strong></div></div></div><div class="form-group" ng-show="activeItem.params.discount_type != 0 && activeItem.params.discount_style == 2"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><div class="input-group"><div we7-colorpicker we7-my-color="activeItem.params.bgColor" we7-my-default-color="\'#ffffff\'"></div></div></div></div><div class="form-group" ng-show="activeItem.params.discount_type != 0 && activeItem.params.discount_style == 2"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><div we7-editor we7-my-value="activeItem.params.content"></div></div></div></div></div></div></div></div>'),e.put("widget-cardtimes-display.html",'<div ng-controller="CardTimesCtrl"><div class="nav-container" ng-if="module.params.times_status == 1 && module.params.times_style == 1"><ul><li class="collapse-link"><a class="nav-container-list" href="javascript:;"><span class="nav-title"><i class="fa fa-eye"></i>{{module.params.times_text}}充值</span> <span class="pull-right"><i class="fa fa-angle-right"></i></span></a><div class="collapse-con padding-b-0"><a href="./index.php?i={$_W[\'uniacid\']}&j={$_W[\'acid\']}&c=entry&m=recharge&do=pay&type=card_times&fee={{time.recharge}}" class="btn btn-warning btn-recharge" ng-repeat="time in module.params.times">å……{{time.recharge}}è¿”{{time.time}}天</a></div></li></ul></div><div class="app-richText" ng-if="module.params.times_status == 1 && module.params.times_style == 2" ng-style="{\'background-color\' : module.params.bgColor}"><div class="inner" ng-bind-html="module.params.content" ng-if="module.params.content"></div><div class="inner js-default-content" ng-if="!module.params.content"><p>点æ¤ç¼–辑『富文本ã€å†…容 ——></p><p>ä½ å¯ä»¥å¯¹æ–‡å—进行 <strong>åŠ ç²—</strong>ã€<em>斜体</em>ã€<span style="text-decoration: underline">下划线</span>〠<span style="text-decoration: line-through">åˆ é™¤çº¿</span>ã€æ–‡å—<span style="color: rgb(0, 176, 240)">颜色</span>〠<span style="background-color: rgb(255, 192, 0); color: rgb(255, 255, 255)">背景色</span>〠以åŠå—å·<span style="font-size: 20px">大</span><span style="font-size: 14px">å°</span>ç‰ç®€å•æŽ’版æ“作。</p><p>还å¯ä»¥åœ¨è¿™é‡ŒåŠ å…¥è¡¨æ ¼äº†</p><table class="table-bordered"><tbody><tr><td>ä¸å¥–客户</td><td>å‘放奖å“</td><td>备注</td></tr><tr><td>猪猪</td><td>内测ç </td><td><em><span class="red">å·²ç»å‘放</span></em></td></tr><tr><td>大麦</td><td>积分</td><td><a href="#" target="_blank">领å–地å€</a></td></tr></tbody></table><p style="text-align: left"><span style="text-align: left">也å¯åœ¨è¿™é‡Œæ’入图片ã€å¹¶å¯¹å›¾ç‰‡åŠ 上超级链接,方便用户点击。</span></p></div></div></div>'),e.put("widget-cardtimes-editor.html",'<div ng-controller="CardTimesCtrl"><div class="app-header-setting"><div class="arrow-left"></div><div class="app-header-setting-inner"><div class="panel panel-default"><ul class="nav nav-tabs" style="margin:10px 15px 0 15px"><li ng-class="{\'active\' : activeItem.id == \'cardBasic\'}"><a href="javascript:;" ng-click="editItem(\'cardBasic\');">基本设置</a></li><li ng-class="{\'active\' : activeItem.id == \'cardActivity\'}"><a href="javascript:;" ng-click="editItem(\'cardActivity\');">æ¶ˆè´¹ä¼˜æƒ è®¾ç½®</a></li><li ng-class="{\'active\' : activeItem.id == \'cardRecharge\'}"><a href="javascript:;" ng-click="editItem(\'cardRecharge\');">å……å€¼ä¼˜æƒ è®¾ç½®</a></li><li ng-class="{\'active\' : activeItem.id == \'cardNums\'}"><a href="javascript:;" ng-click="editItem(\'cardNums\');">计次设置</a></li><li ng-class="{\'active\' : activeItem.id == \'cardTimes\'}"><a href="javascript:;" ng-click="editItem(\'cardTimes\');">计时设置</a></li></ul><div class="panel-body form-horizontal"><div class="form-group"><label class="col-xs-12 col-sm-3 col-md-2 control-label">计时设置</label><div class="col-sm-9 col-xs-12"><input type="radio" value="1" ng-model="activeItem.params.times_status" id="times_status1"><label class="radio-inline" for="times_status1">å¼€å¯</label><input type="radio" value="0" ng-model="activeItem.params.times_status" id="times_status2"><label class="radio-inline" for="times_status2">å…³é—</label><span class="help-block">å¦‚ä½ çš„ä¸šåŠ¡æœ‰éœ€è¦æ—¶é•¿é™åˆ¶ï¼Œå¯å¼€å¯è¿›è¡Œè®¾ç½®ã€‚</span></div></div><div class="form-group" ng-show="activeItem.params.times_status == 1"><label class="col-xs-12 col-sm-3 col-md-2 control-label">计时设置</label><div class="col-sm-9 col-xs-12"><input type="text" class="form-control" ng-model="activeItem.params.times_text"> <span class="help-block">例如:设置为â€åˆ°æœŸæ—¶é—´â€œ,ç³»ç»Ÿå°†æ ¹æ®ç”¨æˆ·çš„领å¡æ—¶é—´,åŠ ä¸Šç”¨æˆ·çš„å¯ç”¨æ—¶é•¿ï¼Œè®¡ç®—到期时间,å‰å°å°†æ˜¾ç¤ºä¸ºï¼šâ€åˆ°æœŸæ—¶é—´ï¼šxå¹´x月x日“,è¯·æ ¹æ®è‡ªå·±çš„业务需求设置。</span></div></div><div class="form-group" ng-show="activeItem.params.times_status == 1"><label class="col-xs-12 col-sm-3 col-md-2 control-label">充值返时长</label><div class="col-sm-9 col-xs-12"><div ng-repeat="time in activeItem.params.times" style="margin-left:-15px"><div class="col-sm-8" style="margin-bottom:10px"><div class="input-group"><span class="input-group-addon">å……</span> <input type="text" class="form-control" ng-model="time.recharge"> <span class="input-group-addon">å…ƒ</span> <input type="text" class="form-control" ng-model="time.time"> <span class="input-group-addon">天</span></div></div><div class="col-sm-1" style="margin-top:5px"><a href="javascript:;" ng-click="removeTimes(time);"><i class="fa fa-times-circle"></i></a></div></div><div class="help-block col-sm-9" style="margin-left:-15px"><a href="javascript:;" ng-click="addTimes();"><i class="fa fa-plus-circle" title="æ·»åŠ å……å€¼è®¾ç½®"></i> æ·»åŠ å……å€¼è®¾ç½®</a></div></div></div><div class="form-group" ng-show="activeItem.params.times_status != 0"><label class="col-xs-12 col-sm-3 col-md-2 control-label">æ ·å¼è®¾ç½®</label><div class="col-sm-9 col-xs-12"><label class="radio-inline"><input type="radio" value="1" ng-model="activeItem.params.times_style"> 系统默认</label><label class="radio-inline"><input type="radio" value="2" ng-model="activeItem.params.times_style"> 自定义</label></div></div><div class="form-group" ng-show="activeItem.params.times_status != 0 && activeItem.params.times_style == 2"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><div class="input-group"><div we7-colorpicker we7-my-color="activeItem.params.bgColor" we7-my-default-color="\'#ffffff\'"></div></div></div></div><div class="form-group" ng-show="activeItem.params.times_status != 0 && activeItem.params.times_style == 2"><label class="col-xs-12 col-sm-3 col-md-2 control-label"></label><div class="col-sm-9 col-xs-12"><div we7-editor we7-my-value="activeItem.params.content"></div></div></div></div></div></div></div></div>'),e.put("widget-ucheader-display.html",'<div ng-controller="HeaderCtrl"><div class="title"><h1><span>{{module.params.title}}</span></h1></div><div class="head" style="background-repeat:no-repeat; background-position: center center;height: 150px" ng-style="{\'background-image\' : module.params.bgImage ? \'url(\' + module.params.bgImage + \')\' : \'url(\\\'./resource/images/app/head-bg.png\\\')\'}"><a class="ptool" href="{{url(\'mc/profile\')}}">设置</a><div class="logo-img"><img ng-src="{{logo_url}}" class="img-circle"></div><div class="banner-info"><div class="name">设置昵称</div><div class="name">会员ç‰çº§: 默认会员组</div><div class="tel">1884512367</div></div><div class="head-nav"><a class="head-nav-list" href="{{url(\'mc/bond/credits\')}}&credittype=credit1"><span class="fa fa-rmb"></span>ä½™é¢: <span>4000.00</span></a> <a class="head-nav-list" href="{{url(\'mc/bond/credits\')}}&credittype=credit2"><span class="fa fa-database"></span>积分: <span>900.00</span></a></div></div></div>'),e.put("widget-ucheader-editor.html",'<div ng-controller="HeaderCtrl"><div class="app-header-setting"><div class="arrow-left"></div><div class="app-header-setting-inner"><div class="panel panel-default"><div class="panel-body form-horizontal"><div class="form-group"><label class="col-xs-3 control-label"><span class="red">*</span> 页é¢å称</label><div class="col-xs-9"><input type="text" ng-model="activeItem.params.title" placeholder="微页é¢æ ‡é¢˜" class="form-control"></div></div><div class="form-group"><label class="control-label col-xs-3">背景图片</label><div class="col-xs-9"><span ng-click="addThumb(\'bgImage\')"><i class="fa fa-plus-circle green"></i> 选择图片</span><div style="margin-top:.5em" class="input-group" ng-show="activeItem.params.bgImage"><img width="150" class="img-responsive img-thumbnail" ng-src="{{activeItem.params.bgImage}}"> <em ng-click="activeItem.params.bgImage = \'\';" title="åˆ é™¤è¿™å¼ å›¾ç‰‡" style="position:absolute; top: 0px; right: -14px" class="close">×</em></div></div></div><div class="form-group"><label class="col-xs-3 control-label">触å‘关键å—</label><div class="col-xs-9"><input type="text" ng-model="activeItem.params.keyword" class="form-control"> <span class="help-block">用户触å‘关键å—,系统回å¤æ¤é¡µé¢çš„图文链接</span></div></div><div class="form-group"><label class="control-label col-xs-3">å°é¢</label><div class="col-xs-9"><span ng-click="addThumb(\'cover\')"><i class="fa fa-plus-circle green"></i> 选择图片</span><div style="margin-top:.5em" class="input-group" ng-show="activeItem.params.cover"><img width="150" class="img-responsive img-thumbnail" ng-src="{{activeItem.params.cover}}"> <em ng-click="activeItem.params.cover = \'\';" title="åˆ é™¤è¿™å¼ å›¾ç‰‡" style="position:absolute; top: 0px; right: -14px" class="close">×</em></div><span class="help-block">用于用户触å‘关键å—åŽï¼Œç³»ç»Ÿå›žå¤æ—¶çš„å°é¢å›¾ç‰‡</span></div></div><div class="form-group"><label class="col-xs-3 control-label">页é¢æè¿°</label><div class="col-xs-9"><input type="text" ng-model="activeItem.params.description" class="form-control"></div></div><div class="form-group"><label class="col-xs-3 control-label">è”系方å¼</label><div class="col-xs-9"><input type="text" ng-model="activeItem.params.contact" class="form-control"> <span class="help-block">用于用户点击会员ä¸å¿ƒ->设置->è”系我们时拨打的电è¯</span></div></div><div class="shopNav-edit-header clearfix">个人ä¸å¿ƒæ‰©å±•èœå•</div><div class="shopNav-wx"><div class="card" ng-repeat="menu in activeMenus"><div class="btns"><a href="javascript:;" ng-click="removeMenu(menu)"><i class="fa fa-times"></i></a></div><div class="nav-region"><div class="first-nav"><div class="alert"><div class="form-group"><label class="control-label col-xs-3">æ ‡é¢˜</label><div class="col-xs-9"><input type="text" class="form-control" name="" value="" ng-model="menu.name"></div></div><div class="form-group"><label class="control-label col-xs-3">链接到</label><div class="col-xs-9"><input ng-if="menu.module_info" type="text" ng-model="menu.url" class="form-control" disabled><div ng-if="!menu.module_info" we7-linker we7-my-url="menu.url" we7-my-title="menu.name"></div></div></div><div class="form-group" ng-if="menu.module_info"><label class="control-label col-xs-3">是å¦æ˜¾ç¤º</label><div class="col-xs-9"><label class="radio-inline"><input type="radio" value="1" ng-model="menu.status">显示</label><label class="radio-inline"><input type="radio" value="0" ng-model="menu.status">éšè—</label><span class="help-block"><strong class="text-danger">该èœå•æ¥æºäºŽ{{menu.module_info.title}}模å—,ä»…å¯è®¾ç½®æ ‡é¢˜å’Œæ˜¯å¦æ˜¾ç¤º</strong></span></div></div></div></div></div></div><div class="add-shopNav text-center" ng-click="addMenu();">+æ·»åŠ ä¸€çº§å¯¼èˆª</div></div></div></div></div></div></div>'),e.put("directive-pagelength-pagelength.html",'<div class="app-plength" ng-if="isLongPage"><div class="btn btn-default col-sm-3 app-plength-change" ng-class="{\'disabled\' : pageLength <= 1}" ng-style="{\'cursor\' : pageLength <= 1 ? \'not-allowed\' : \'pointer\'}" ng-click="changePageLength(\'minus\');"><span>-</span></div><div class="col-sm-6 app-plength-info"><div>页é¢é•¿åº¦(页):<span ng-bind="pageLength"></span></div></div><div class="btn btn-default col-sm-3 app-plength-change" ng-class="{\'disabled\' : pageLength >= 5}" ng-style="{\'cursor\' : pageLength >= 5 ? \'not-allowed\' : \'pointer\'}" ng-click="changePageLength(\'plus\');"><span>+</span></div></div>'),e.put("directive-style-style.html",'<div class="app-text-edit" ng-if="activeItem.id != \'header\' && activeItem.id != \'UCheader\'"><div class="inner"><div class="panel panel-default"><div class="panel-body"><ul class="nav nav-tabs"><li class="active"><a href="#attribute" role="tab" data-toggle="tab">属性</a></li><li><a href="#action" role="tab" data-toggle="tab">动作</a></li></ul><div class="tab-content"><div class="tab-pane active" id="attribute"><div class="panel-group" id="accordion"><div class="panel panel-default"><div class="panel-heading" role="tab" id="heading-basic"><h4 class="panel-title"><a role="button" data-toggle="collapse" data-parent="#accordion" href="#collapse-basic" aria-expanded="true" aria-controls="collapse-basic">åŸºç¡€æ ·å¼</a></h4></div><div id="collapse-basic" class="panel-collapse collapse in" role="tabpanel" aria-labelledby="heading-basic"><div class="panel-body"><div class="form-group"><label class="col-xs-3 control-label">背景颜色</label><div class="col-xs-9"><div class="input-group"><div we7-colorpicker we7-my-color="activeItem.params.baseStyle.backgroundColor" we7-my-default-color="activeItem.params.baseStyle.backgroundColor"></div></div></div></div><div class="form-group" ng-show="activeItem.id == \'onlyText\' || activeItem.id == \'countDown\' || activeItem.id == \'line\'"><label class="col-xs-3 control-label" ng-show="activeItem.id == \'line\'">辅助线颜色</label><label class="col-xs-3 control-label" ng-show="activeItem.id != \'line\'">æ–‡å—颜色</label><div class="col-xs-9"><div class="input-group"><div we7-colorpicker we7-my-color="activeItem.params.baseStyle.color" we7-my-default-color="activeItem.params.baseStyle.color"></div></div></div></div><div class="form-group"><label class="col-xs-3 control-label">é€æ˜Žåº¦</label><div class="col-xs-9"><input type="number" class="form-control" max="100" min="0" step="1" placeholder="0" value="" name="" ng-model="activeItem.params.baseStyle.opacity"></div></div><div class="form-group" ng-show="activeItem.id == \'onlyText\' || activeItem.id == \'pureLink\' || activeItem.id == \'dial\' || activeItem.id == \'good\' || activeItem.id == \'countDown\' || activeItem.id == \'line\'"><label class="col-xs-3 control-label">上å移</label><div class="col-xs-9"><input type="number" class="form-control" max="100" min="0" step="1" placeholder="0" value="" name="" ng-model="activeItem.params.baseStyle.paddingTop"></div></div><div class="form-group" ng-if="activeItem.id == \'onlyText\'"><label class="control-label col-xs-3">è¡Œè·</label><div class="col-xs-8"><div class="input-group"><select class="form-control" id="lineheight" ng-model="activeItem.params.baseStyle.lineHeight" ng-options="lhKey for (lhKey, lhVal) in lineHeights"></select><span class="input-group-addon">å€</span></div></div></div><div class="form-group" ng-show="activeItem.id == \'onlyText\' || activeItem.id == \'pureLink\' || activeItem.id == \'dial\' || activeItem.id == \'good\' || activeItem.id == \'countDown\'"><label class="control-label col-xs-3">å—体大å°</label><div class="col-xs-8"><div class="input-group"><select class="form-control" id="fontsize" ng-model="activeItem.params.baseStyle.fontSize" ng-options="fzKey for (fzKey, fzVal) in fontSizes"></select><span class="input-group-addon">px</span></div></div></div><div class="form-group" ng-show="isLongPage"><label class="col-xs-3 control-label">固定组件</label><div class="col-xs-9"><label class="checkbox-inline"><input type="checkbox" ng-click="changeLock()" ng-checked="activeItem.params.baseStyle.lock"> 固定组件åªèƒ½åœ¨é•¿é¡µé¢ä¸ä½¿ç”¨</label></div></div></div></div></div><div class="panel panel-default"><div class="panel-heading" role="tab" id="heading-border"><h4 class="panel-title"><a role="button" data-toggle="collapse" data-parent="#accordion" href="#collapse-border" aria-expanded="true" aria-controls="collapse-border">è¾¹æ¡†æ ·å¼</a></h4></div><div id="collapse-border" class="panel-collapse collapse" role="tabpanel" aria-labelledby="heading-border"><div class="panel-body"><div class="form-group"><label class="col-xs-3 control-label">尺寸</label><div class="col-xs-9"><input type="number" class="form-control" max="20" min="0" step="1" placeholder="0" value="" name="" ng-model="activeItem.params.borderStyle.borderWidth" ng-change="changeBorderWidth()"></div></div><div class="form-group"><label class="col-xs-3 control-label">弧度</label><div class="col-xs-9"><input type="number" class="form-control" max="29" min="0" step="1" placeholder="0" value="" name="" ng-model="activeItem.params.borderStyle.borderRadius"></div></div><div class="form-group"><label class="col-xs-3 control-label">æ ·å¼</label><div class="col-xs-9"><select name="" class="form-control" ng-model="activeItem.params.borderStyle.borderStyle"><option value="solid">直线</option><option value="dashed">ç ´æŠ˜çº¿</option><option value="dotted">点状线</option><option value="double">åŒåˆ’线</option><option value="groove">3D凹槽</option><option value="ridge">3D垄状</option><option value="inset">3D内嵌</option><option value="outset">3D外嵌</option></select></div></div><div class="form-group"><label class="col-xs-3 control-label">颜色</label><div class="col-xs-9"><div class="input-group"><div we7-colorpicker we7-my-color="activeItem.params.borderStyle.borderColor" we7-my-default-color="activeItem.params.borderStyle.borderColor"></div></div></div></div><div class="form-group"><label class="col-xs-3 control-label">旋转度</label><div class="col-xs-9"><input type="number" class="form-control" max="360" min="0" step="1" placeholder="0" value="" name="" ng-model="activeItem.params.borderStyle.transform"></div></div></div></div></div><div class="panel panel-default"><div class="panel-heading" role="tab" id="heading-shadow"><h4 class="panel-title"><a role="button" data-toggle="collapse" data-parent="#accordion" href="#collapse-shadow" aria-expanded="true" aria-controls="collapse-shadow">é˜´å½±æ ·å¼</a></h4></div><div id="collapse-shadow" class="panel-collapse collapse" role="tabpanel" aria-labelledby="heading-shadow"><div class="panel-body"><div class="form-group"><label class="col-xs-3 control-label">大å°</label><div class="col-xs-9"><input type="number" class="form-control" max="20" min="0" step="1" placeholder="0" value="" name="" ng-model="activeItem.params.shadowStyle.shadowSize"></div></div><div class="form-group"><label class="col-xs-3 control-label">模糊</label><div class="col-xs-9"><input type="number" class="form-control" max="20" min="0" step="1" placeholder="0" value="" name="" ng-model="activeItem.params.shadowStyle.shadowBlur"></div></div><div class="form-group"><label class="col-xs-3 control-label">颜色</label><div class="col-xs-9"><div class="input-group"><div we7-colorpicker we7-my-color="activeItem.params.shadowStyle.shadowColor" we7-my-default-color="activeItem.params.shadowStyle.shadowColor"></div></div></div></div><div class="form-group"><label class="col-xs-3 control-label">æ–¹å‘</label><div class="col-xs-9"><input type="number" class="form-control" max="359" min="0" step="1" placeholder="0" value="" name="" ng-model="activeItem.params.shadowStyle.shadowDirection"></div></div></div></div></div></div><div><a class="btn btn-primary" ng-click="clearModuleStyle()">é‡ç½®å±žæ€§</a></div></div><div class="tab-pane" id="action"><div class="form-group"><label class="col-xs-3 control-label">速度</label><div class="col-xs-9"><div class="input-group"><input type="number" ng-model="activeItem.params.animationStyle.animationDuration" max="30" min="0" step="0.1" class="form-control"> <span class="input-group-btn"><button class="btn btn-default" type="reset">秒(S)</button></span></div></div></div><div class="form-group"><label class="col-xs-3 control-label">延迟</label><div class="col-xs-9"><div class="input-group"><input type="number" ng-model="activeItem.params.animationStyle.animationDelay" max="10" min="0" step="0.1" class="form-control"> <span class="input-group-btn"><button class="btn btn-default" type="reset">秒(S)</button></span></div></div></div><div class="clearfix icons"><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'noEffect\'}" ng-click="eleAnimationIns(\'noEffect\', $event)"><div class="icon no-effect"></div><div class="name">æ— æ•ˆæžœ</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'fadeInNormal\'}" ng-click="eleAnimationIns(\'fadeInNormal\', $event);"><div class="icon fade-in-normal"></div><div class="name">æ·¡å…¥</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'rotateInDownLeft\'}" ng-click="eleAnimationIns(\'rotateInDownLeft\', $event);"><div class="icon rotate-in-down-left"></div><div class="name">从左滚入</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'rotateInDownRight\'}" ng-click="eleAnimationIns(\'rotateInDownRight\', $event);"><div class="icon rotate-in-down-right"></div><div class="name">从å³æ»šå…¥</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'zoomIn\'}" ng-click="eleAnimationIns(\'zoomIn\', $event);"><div class="icon zoom-in"></div><div class="name">放大</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'zoomInDown\'}" ng-click="eleAnimationIns(\'zoomInDown\', $event);"><div class="icon zoom-in-down"></div><div class="name">下è½æ”¾å¤§</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'fadeIn\'}" ng-click="eleAnimationIns(\'fadeIn\', $event);"><div class="icon fade-in"></div><div class="name">弹性放大</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'expandOpen\'}" ng-click="eleAnimationIns(\'expandOpen\', $event);"><div class="icon expand-open"></div><div class="name">弹性缩å°</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'fadeInRight\'}" ng-click="eleAnimationIns(\'fadeInRight\', $event);"><div class="icon fade-in-right"></div><div class="name">å‘å³é£žå…¥</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'fadeInLeft\'}" ng-click="eleAnimationIns(\'fadeInLeft\', $event);"><div class="icon fade-in-left"></div><div class="name">å‘左飞入</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'fadeInUp\'}" ng-click="eleAnimationIns(\'fadeInUp\', $event);"><div class="icon fade-in-up"></div><div class="name">å‘上飞入</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'fadeInDown\'}" ng-click="eleAnimationIns(\'fadeInDown\', $event);"><div class="icon fade-in-down"></div><div class="name">å‘下飞入</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'rotateIn\'}" ng-click="eleAnimationIns(\'rotateIn\', $event);"><div class="icon rotate-in"></div><div class="name">旋转出现</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'flipInY\'}" ng-click="eleAnimationIns(\'flipInY\', $event);"><div class="icon flip-in-y"></div><div class="name">å·¦å³ç¿»è½¬</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'flipInX\'}" ng-click="eleAnimationIns(\'flipInX\', $event);"><div class="icon flip-in-x"></div><div class="name">上下翻转</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'lightSpeedIn\'}" ng-click="eleAnimationIns(\'lightSpeedIn\', $event);"><div class="icon light-speed-in"></div><div class="name">刹车</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'slideRight\'}" ng-click="eleAnimationIns(\'slideRight\', $event);"><div class="icon slide-right"></div><div class="name">å‘å³æ»‘å…¥</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'slideLeft\'}" ng-click="eleAnimationIns(\'slideLeft\', $event);"><div class="icon slide-left"></div><div class="name">å‘左滑入</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'slideUp\'}" ng-click="eleAnimationIns(\'slideUp\', $event);"><div class="icon slide-up"></div><div class="name">å‘上滑入</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'slideDown\'}" ng-click="eleAnimationIns(\'slideDown\', $event);"><div class="icon slide-down"></div><div class="name">å‘下滑入</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'stretchRight\'}" ng-click="eleAnimationIns(\'stretchRight\', $event);"><div class="icon stretch-right"></div><div class="name">å‘å³å±•å¼€</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'stretchLeft\'}" ng-click="eleAnimationIns(\'stretchLeft\', $event);"><div class="icon stretch-left"></div><div class="name">å‘左展开</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'pullUp\'}" ng-click="eleAnimationIns(\'pullUp\', $event);"><div class="icon pull-up"></div><div class="name">å‘上展开</div></div><div class="icon-container" ng-class="{\'select\': activeItem.params.animationStyle.animationName == \'pullDown\'}" ng-click="eleAnimationIns(\'pullDown\', $event);"><div class="icon pull-down"></div><div class="name">å‘下展开</div></div></div></div></div></div></div></div></div>'),e.put("widget-adimg-display.html",'<div ng-controller="AdImgCtrl" style="{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)" we7-context-menu><link href="./resource/components/swiper/swiper.min.css" rel="stylesheet"><div style="{{module.transform}}" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-adImg" style="{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><div class="inner"><div class="appstyle js-default-content" ng-if="module.params.items.length == 0"><img ng-show="module.params.listStyle == 1" src="./resource/images/app/adImg-lg.jpg" width="100%"> <img ng-show="module.params.listStyle == 2" src="./resource/images/app/adImg-separate.jpg" width="100%"></div><div class="swiper-container swiper-container-horizontal" ng-if="module.params.items.length != 0 && module.params.listStyle == 1"><div class="swiper-wrapper"><div class="swiper-slide" ng-class="{\'swiper-slide-active\' : $index == 0}" style="width: 100%" ng-repeat="item in module.params.items"><a href="{{item.url}}" style="display:block; width:100%; text-align:center"><img ng-src="{{item.imgurl}}" title="{{item.title}}" style="display:block; height:auto; max-width:100%; margin:0 auto"></a></div></div><div class="swiper-pagination swiper-pagination-clickable"><span class="swiper-pagination-bullet" ng-class="{\'swiper-pagination-bullet-active\': $index == 0}" ng-repeat="item in module.params.items"></span></div><div class="swiper-button-next hidden"></div><div class="swiper-button-prev hidden"></div></div><div class="show-separate" ng-if="module.params.items.length != 0 && module.params.listStyle == 2"><div class="ad-list lg" ng-if="module.params.sizeType == 1"><div class="ad-list-item" ng-repeat="item in module.params.items"><a href="{{item.url}}"><h3 ng-bind="item.title">å¹¿å‘Šæ ‡é¢˜</h3><img ng-src="{{item.imgurl}}"></a></div></div><div class="ad-list clearfix sm" ng-if="module.params.sizeType == 2"><div class="ad-list-item col-xs-6 col-sm-6" ng-repeat="item in module.params.items"><a href="{{item.url}}"><h3 ng-bind="item.title">å¹¿å‘Šæ ‡é¢˜</h3><img ng-src="{{item.imgurl}}"></a></div></div></div></div></div><div we7-drag></div></div></div>'),e.put("widget-adimg-editor.html",'<div ng-controller="AdImgCtrl"><div class="app-adImg-edit"><div class="arrow-left"></div><div class="inner"><div class="panel panel-default"><div class="panel-body form-horizontal"><div class="form-group"><label class="control-label col-xs-3">显示方å¼</label><div class="col-xs-9"><input type="radio" class="carousel-style" ng-model="activeItem.params.listStyle" value="1" ng-click="activeItem.params.sizeType=1;changeInnerHeight()" name="ad-show-style" id="list-style1"><label class="radio-inline" for="list-style1">折å è½®æ’</label><input type="radio" class="separate-style" ng-model="activeItem.params.listStyle" value="2" name="ad-show-style" ng-click="changeInnerHeight()" id="list-style2"><label class="radio-inline" for="list-style2">分开显示</label></div></div><div class="form-group"><label class="control-label col-xs-3">显示大å°</label><div class="col-xs-9"><input type="radio" class="size-lg-style" ng-model="activeItem.params.sizeType" value="1" name="ad-size" ng-click="changeInnerHeight()" id="size-type1"><label class="radio-inline" for="size-type1">大图</label><input type="radio" class="size-sm-style" ng-model="activeItem.params.sizeType" value="2" name="ad-size" ng-click="changeInnerHeight()" id="size-type2"><label class="radio-inline" for="size-type2" ng-show="activeItem.params.listStyle == 2">å°å›¾</label></div></div><div class="add-adImg-item card clearfix" ng-repeat="item in activeItem.params.items"><div class="btns"><a href="#" ng-click="addEmpty()"><i class="fa fa-plus"></i></a> <a href="#" ng-click="removeItem(item)"><i class="fa fa-times"></i></a></div><div class="col-xs-3 img"><h3 ng-click="changeItem(item)">é‡æ–°ä¸Šä¼ </h3><img src="" ng-src="{{ item.imgurl }}" width="100%"></div><div class="col-xs-9"><div class="form-group"><label class="control-label col-xs-3">æ ‡é¢˜</label><div class="col-xs-9"><input class="form-control" name="title" ng-model="item.title" value="" type="text"></div></div><div class="form-group"><label class="control-label col-xs-3">链接</label><div class="col-xs-9 form-control-static"><div we7-linker we7-my-url="item.url" we7-my-title="item.title"></div></div></div></div></div><div class="add-adImg card" ng-click="addItem()"><a href="#"><i class="fa fa-plus-circle green"></i>æ·»åŠ ä¸€ä¸ªå¹¿å‘Š</a></div></div></div></div></div></div>'),e.put("widget-audio-display.html",'<div ng-controller="AudioCtrl" style="{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)" we7-context-menu><div style="{{module.transform}}" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-audio" style="{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><div class="inner"><div ng-if="module.params.style == \'1\'" id="audio-music-{{$index+0}}" data-reload="{{module.params.reload}}" class="wx audioLeft clearfix" data-src="{{module.params.audio.url}}" ng-class="{\'audioLeft\': module.params.align == \'left\', \'audioRight\': module.params.align == \'right\'}" style="width:100%;height:100%"><img ng-init="module.params.headimg = module.params.headimg ? module.params.headimg : \'./resource/images/app/shop.png!80x80.jpg\'" ng-src="{{module.params.headimg}}" alt="è¯éŸ³å¤´åƒ" class="audioLogo" width="40" height="40"> <span class="audioBar js-play"><img style="display:none" ng-if="module.params.align == \'left\'" src="./resource/images/app/player.gif" class="audioAnimation"> <img style="display:none" ng-if="module.params.align == \'right\'" src="./resource/images/app/green_player.gif" class="audioAnimation"> <i class="audioStatic"></i> <span style="display:none" class="audioLoading"><i class="fa fa-spinner fa-pulse"></i></span></span> <span class="audioBar js-pause" style="display:none"><img ng-if="module.params.align == \'left\'" src="./resource/images/app/player.gif" class="audioAnimation"> <img ng-if="module.params.align == \'right\'" src="./resource/images/app/green_player.gif" class="audioAnimation"> <i class="audioStatic"></i></span> <span class="audio-time"></span><div class="js-audio-wx" data-id="audio-music-{{$index+0}}"></div></div><div class="music music-play" id="audio-music-{{$index+0}}" data-src="{{module.params.audio.url}}" data-reload="{{module.params.reload}}" data-loop="{{module.params.isloop}}" ng-if="module.params.style == \'2\'"><span class="audioStatic js-play"><a href="javascript:;"><i class="fa fa-play-circle-o"></i></a></span> <span class="audioAnimation js-pause" style="display:none"><a href="javascript:;"><i class="fa fa-pause"></i></a></span> <span class="musicTitle" ng-if="module.params.title == \'\'">æŒåå„¿</span> <span class="musicTitle" ng-if="module.params.title != \'\'">{{module.params.title}}</span> <span class="audioLoading" style="display:none"><i class="fa fa-spinner fa-pulse"></i></span> <span class="audio-time" style="display:none"><span class="audio-current-time">00:00</span>/<span class="audio-duration">00:00</span></span><div class="slider-bar"><div class="slider-fill"></div></div><div class="js-audio-music" data-id="audio-music-{{$index+0}}"></div></div></div></div><div we7-drag></div></div></div>'),e.put("widget-audio-editor.html",'<div ng-controller="AudioCtrl"><div class="app-audio-edit"><div class="arrow-left"></div><div class="inner"><div class="panel panel-default"><div class="panel-body form-horizontal"><div class="form-group"><label class="col-xs-2 control-label">音频</label><div class="col-xs-10"><span class="input-group-btn"><button type="button" class="btn btn-default audio-player-play" style="display:none"><i class="fa fa-play"></i></button> <button ng-click="addAudioItem()" type="button" class="btn btn-default">选择媒体文件</button></span></div></div><div class="form-group"><label class="col-xs-2 control-label">æ ·å¼</label><div class="col-xs-10"><div class=""><input id="wx-music-type" type="radio" name="wx-music" value="1" ng-model="activeItem.params.style" ng-click="changeInnerHeight()"><label class="radio-inline" for="wx-music-type">模仿微信对è¯æ ·å¼</label><div class="form-group" ng-show="activeItem.params.style == \'1\'"><label class="control-label col-xs-3">头åƒ:</label><div class="col-xs-3" style="padding-top:10px"><img ng-init="activeItem.params.headimg = activeItem.params.headimg ? activeItem.params.headimg : \'./resource/images/app/shop.png!80x80.jpg\'" ng-src="{{activeItem.params.headimg}}" alt="è¯éŸ³å¤´åƒ" width="62" height="62"></div><div class="help-block col-xs-6" style="padding-left:0;padding-top:10px"><a href="#" ng-click="addImgItem()">ä¸Šä¼ å¤´åƒ</a><br>建议尺寸80*80åƒç´ <br>如果ä¸è®¾ç½®,默认将使用店铺logo</div></div><div class="form-group" ng-show="activeItem.params.style == \'1\'"><label class="control-label col-xs-3">气泡:</label><div class="col-xs-9"><input id="bubble-left" type="radio" name="bubble" value="left" ng-model="activeItem.params.align"><label class="radio-inline" for="bubble-left">å±…å·¦</label><input id="bubble-right" type="radio" name="bubble" value="right" ng-model="activeItem.params.align"><label class="radio-inline" for="bubble-right">å±…å³</label></div></div></div><div class=""><input id="simple-music-type" type="radio" name="wx-music" value="2" ng-model="activeItem.params.style" ng-click="changeInnerHeight()"><label class="radio-inline" for="simple-music-type">简易音ä¹æ’放器</label><div><div class="form-group" ng-show="activeItem.params.style == \'2\'"><label class="control-label col-xs-3">æ ‡é¢˜:</label><div class="col-xs-9"><input class="form-control" type="text" ng-model="activeItem.params.title"></div></div><div class="form-group" ng-show="activeItem.params.style == \'2\'"><label class="control-label col-xs-3">循环:</label><div class="col-xs-9"><label class="checkbox-inline"><input type="checkbox" ng-model="activeItem.params.isloop">å¼€å¯å¾ªçŽ¯æ’放</label></div></div></div></div></div></div><div class="form-group"><label class="col-xs-2 control-label">æ’放</label><div class="col-xs-10"><div><input id="play-type1" type="radio" name="play" ng-model="activeItem.params.reload" value="true"><label class="radio-inline" for="play-type1">æš‚åœåŽå†å›žå¤æ’放时,从头开始</label></div><div><input id="play-type2" type="radio" name="play" ng-model="activeItem.params.reload" value="false"><label class="radio-inline" for="play-type2">æš‚åœåŽå†å›žå¤æ’放时,从暂åœä½ç½®å¼€å§‹</label></div></div></div></div></div></div></div></div>'),e.put("widget-countdown-display.html",'<div ng-controller="CountDownCtrl" style="{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)" we7-context-menu><div style="{{module.transform}}width:100%;height:100%" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-countDown" style="width:100%;height:100%;overflow:hidden;{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><div class="timer" data="{{module.params.deadtime}}"><span class="day" ng-bind="module.params.leftTimeText.day"></span> <small style="vertical-align:middle;margin:3px">天</small> <span class="hours" ng-bind="module.params.leftTimeText.hour"></span> <small style="vertical-align:middle;margin:3px">æ—¶</small> <span class="minutes" ng-bind="module.params.leftTimeText.min"></span> <small style="vertical-align:middle;margin:3px">分</small> <span class="seconds" ng-bind="module.params.leftTimeText.sec"></span> <small style="vertical-align:middle;margin:3px">秒</small></div><script type="text/javascript">$(document).ready(function(){\r\n\t\t\t\t\tsetInterval(function(){\r\n\t\t\t\t\t\tvar timer = $(\'.timer\');\r\n\t\t\t\t\t\tfor (var i = 0; i < timer.length; i++) {\r\n\t\t\t\t\t\t\tvar dead = $(timer.get(i)).attr(\'data\');\r\n\t\t\t\t\t\t\tvar deadtime = dead.replace(/-/g,\'/\');\r\n\t\t\t\t\t\t\tdeadtime = new Date(deadtime).getTime();\r\n\t\t\t\t\t\t\tvar nowtime = Date.parse(Date());\r\n\t\t\t\t\t\t\tvar diff = deadtime - nowtime > 0 ? deadtime - nowtime : 0;\r\n\t\t\t\t\t\t\tvar res = {};\r\n\t\t\t\t\t\t\tres.day = parseInt(diff / (24 * 60 * 60 * 1000));\r\n\t\t\t\t\t\t\tres.hour = parseInt(diff / (60 * 60 * 1000) % 24);\r\n\t\t\t\t\t\t\tres.min = parseInt(diff / (60 * 1000) % 60);\r\n\t\t\t\t\t\t\tres.sec = parseInt(diff / 1000 % 60);\r\n\t\t\t\t\t\t\t$(\'.timer[data="\'+dead+\'"] .day\').text(res.day);\r\n\t\t\t\t\t\t\t$(\'.timer[data="\'+dead+\'"] .hours\').text(res.hour);\r\n\t\t\t\t\t\t\t$(\'.timer[data="\'+dead+\'"] .minutes\').text(res.min);\r\n\t\t\t\t\t\t\t$(\'.timer[data="\'+dead+\'"] .seconds\').text(res.sec);\r\n\t\t\t\t\t\t};\r\n\t\t\t\t\t}, 1000);\r\n\t\t\t\t});<\/script></div><div we7-drag we7-resize we7-rotate></div></div></div>'),e.put("widget-countdown-editor.html",'<div ng-controller="CountDownCtrl"><div class="app-countDown-edit"><div class="arrow-left"></div><div class="inner"><div class="panel panel-default"><div class="panel-body"><div class="form-group"><label class="col-xs-3 control-label">倒计时截æ¢æ—¶</label><div class="col-xs-6"><input type="text" class="form-control" ng-model="activeItem.params.deadtimeToMin" disabled></div><div class="col-xs-3 form-control-static"><span class="date"><a href="javascript:;" we7-date-picker we7-date-value="activeItem.params.deadtime">日期</a></span></div></div></div></div></div></div></div>'),e.put("widget-cube-display.html",'<div ng-controller="CubeCtrl" style="{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)" we7-context-menu><div style="{{module.transform}}" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-cube" style="{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><div class="inner"><table><tr ng-repeat="row in module.params.layout" ng-init="rowindex=$index"><td ng-init="colindex=$index" ng-repeat="col in row" class="{{col.classname}} rows-{{col.rows}} cols-{{col.cols}}" ng-class="{\'empty\' : col.isempty, \'not-empty\' : !col.isempty}" rowspan="{{col.rows}}" colspan="{{col.cols}}"><div ng-if="!col.isempty && col.imgurl"><a href="{{col.url}}"><img ng-src="{{col.imgurl}}" width="{{col.cols * 60}}" height="{{col.rows * 60}}"></a></div></td></tr></table></div></div><div we7-drag></div></div></div>'),e.put("widget-cube-editor.html",'<div ng-controller="CubeCtrl"><div class="app-cube-edit"><div class="arrow-left"></div><div class="inner"><div class="panel panel-default"><div class="panel-body form-horizontal"><div class="form-group"><label class="col-xs-3 control-label">布局</label><div class="col-xs-9"><table id="cube-editor"><tr ng-repeat="(x, row) in activeItem.params.layout"><td ng-repeat="(y, col) in row" class="{{col.classname}} rows-{{col.rows}} cols-{{col.cols}}" ng-click="col[\'isempty\'] ? showSelection(x, y) : changeItem(x, y)" ng-class="{\'empty\' : col.isempty, \'not-empty\' : !col.isempty}" rowspan="{{col.rows}}" colspan="{{col.cols}}" x="{{x}}" y="{{y}}"><div ng-if="col.isempty">+</div><div ng-if="!col.imgurl && !col.isempty">{{col.cols * 160}} * {{col.rows * 160}}</div><div ng-if="!col.isempty && col.imgurl"><img ng-src="{{col.imgurl}}" width="{{col.cols * 60}}" height="{{col.rows * 60}}"></div></td></tr></table><span class="help-block">点击"+",æ·»åŠ å†…å®¹</span><img ng-src="{{col.imgurl}}" width="{{col.cols * 60}}" height="{{col.cols * 60}}"></div></div><div ng-show="activeItem.params.currentLayout.isempty == false" class="add-cube-item card clearfix"><div class="btns"><a href="#" ng-click="removeItem()"><i class="fa fa-times"></i></a></div><div class="form-group"><label class="control-label col-xs-3"><span class="red">*</span>选择图片</label><div class="col-xs-9"><div style="width:50px; height:50px; overflow:hidden; float:left; margin-right:10px"><img ng-src="{{activeItem.params.currentLayout.imgurl}}" id="thumb" width="100%"></div><span ng-click="addItem()"><i class="fa fa-plus-circle green"></i> æ·»åŠ å›¾ç‰‡</span> <span class="help-block">建议尺寸:{{activeItem.params.currentLayout.cols * 160}} * {{activeItem.params.currentLayout.rows * 160}} åƒç´ </span></div></div><div class="form-group"><label class="control-label col-xs-3">链接</label><div class="col-xs-9 form-control-static"><div we7-linker we7-my-url="activeItem.params.currentLayout.url" we7-my-title="activeItem.params.currentLayout.title"></div></div></div></div></div></div></div></div><div id="modal-cube-layout" class="modal fade in" role="dialog" aria-hidden="false"><div class="modal-dialog"><div class="modal-content"><div class="modal-header"><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button><h3>选择布局</h3></div><div class="modal-body text-center"><div class="layout-table"><ul class="layout-cols layout-rows-{{col.rows}} clearfix" ng-repeat="row in activeItem.params.selection"><li data-cols="{{col.cols}}" data-rows="{{col.rows}}" ng-click="selectLayout(activeItem.params.currentPos.row, activeItem.params.currentPos.col, col.rows, col.cols)" ng-repeat="col in row"></li></ul></div></div></div></div></div></div>'),e.put("widget-dial-display.html",'<div ng-controller="DialCtrl" style="{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)" we7-context-menu><div style="{{module.transform}}width:100%;height:100%" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-dial" style="width:100%;height:100%;{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><div ng-repeat="item in module.params.items" ng-if="item.active" style="width:100%;height:100%"><div class="app-dialphone animated" ng-if="item.type==\'text\'" style="width:100%;height:100%"><a ng-href="tel:{{item.tel}}" class="element-link"><div class="element-box" ng-bind="item.title" ng-style="{\'line-height\' : module.params.baseStyle.lineHeight, \'color\' : item.color}"></div></a></div><div ng-if="item.type==\'img\'" style="width:100%;height:100%"><a ng-href="tel:{{item.tel}}" class="element-link" style="width:100%"><img ng-src="{{item.imgurl}}" style="width:100%;height:100%" alt=""></a></div></div></div><div we7-drag we7-resize we7-rotate></div></div></div>'),e.put("widget-dial-editor.html",'<div ng-controller="DialCtrl"><div class="app-dial-edit"><div class="arrow-left"></div><div class="inner"><div class="panel panel-default"><div class="panel-body"><ul class="nav nav-pills nav-justified"><li ng-class="{active : item.active}" ng-repeat="item in activeItem.params.items"><a ng-href="#{{item.id}}" role="tab" data-toggle="tab" ng-click="changeItem(item);"><button ng-class="{\'btn\' : 1,\'btn-danger\' : item.editcolor==\'danger\', \'btn-warning\' : item.editcolor==\'warning\', \'btn-success\' : item.editcolor==\'success\', \'btn-default\' : item.editcolor==\'default\', \'btn-primary\' : item.editcolor==\'primary\'}"><span ng-if="item.type==\'img\'" class="fa fa-picture-o"></span> <span ng-if="item.id==\'1\'">一键拨å·</span> <span ng-if="item.id==\'2\'">çƒçº¿ç”µè¯</span> <span ng-if="item.id==\'3\'">拨打电è¯</span> <span ng-if="item.id==\'4\'">销售专线</span> <span ng-if="item.id==\'5\'">自定义</span></button></a></li></ul><hr><div class="tab-content"><div class="tab-pane active" id="{{item.id}}" ng-repeat="item in activeItem.params.items" ng-if="item.active"><div class="form-group" ng-if="item.type==\'text\'"><label class="col-xs-3 control-label">按钮å称</label><div class="col-xs-9"><input type="text" class="form-control" ng-model="item.title"></div></div><div class="form-group" ng-if="item.type==\'img\'"><label class="col-xs-3 control-label">按钮图片</label><div class="col-xs-9"><div class="img-container"><img ng-src="{{item.imgurl}}" alt=""> <span class="change-img" ng-click="addImage(item);"><span ng-show="item.imgurl">æ›´æ¢</span><span ng-show="!item.imgurl">æ·»åŠ </span>图片</span></div></div></div><div class="form-group"><label class="col-xs-3 control-label">手机/电è¯</label><div class="col-xs-9"><input type="text" class="form-control" ng-model="item.tel" placeholder="010-8888888"></div></div></div></div></div></div></div></div></div>'),e.put("widget-good-display.html",'<div ng-controller="GoodCtrl" style="{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)" we7-context-menu><div style="{{module.transform}}width:100%;height:100%" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-good" style="width:100%;height:100%;{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><div class="element app-good-up" ng-if="module.params.layoutstyle==\'1\'"><div class="counter-container" ng-style="{\'width\': \'100%\', \'height\': \'100%\', \'line-height\' : module.params.baseStyle.lineHeight, \'overflow\' : \'hidden\'}"><i class="fa fa-thumbs-o-up"></i> <span class="counter-num">0</span></div></div><div class="element app-good-up" ng-if="module.params.layoutstyle==\'2\'"><div class="counter-container counter-vertical" style="width:100%; height:100%; line-height:normal;overflow:hidden"><i class="fa fa-thumbs-o-up"></i> <span class="counter-num">0</span></div></div><script type="text/javascript">$(document).ready(function() {\r\n\t\t\t\t\tvar patt = new RegExp(\'c=home&a=page\');\r\n\t\t\t\t\tif (patt.exec(window.location.href)) {\r\n'+"\t\t\t\t\t\t$.post(window.location.href, {'do' : 'getnum'}, function(data) {\r\n\t\t\t\t\t\t\tif (data.message.errno == 0) {\r\n\t\t\t\t\t\t\t\t$('.counter-num').text(data.message.message.goodnum);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}, 'json');\r\n\t\t\t\t\t\t$(\".app-good .element\").click(function() {\r\n\t\t\t\t\t\t\tvar id=GetQueryString(\"id\");\r\n\t\t\t\t\t\t\tif(id !=null && id.toString().length>=1 && localStorage.havegood != id){\r\n\t\t\t\t\t\t\t\t$.post(window.location.href, {'do': 'addnum'}, function(data) {\r\n\t\t\t\t\t\t\t\t\tif (data.message.errno == 0) {\r\n\t\t\t\t\t\t\t\t\t\tvar now = $('.counter-num').text();\r\n\t\t\t\t\t\t\t\t\t\tnow = parseInt(now)+1;\r\n\t\t\t\t\t\t\t\t\t\t$('.counter-num').text(now);\r\n\t\t\t\t\t\t\t\t\t\tlocalStorage.havegood = id;\r\n\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t}, 'json');\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t});\r\n\t\t\t\t\t\tfunction GetQueryString(name){\r\n\t\t\t\t\t\t\tvar reg = new RegExp(\"(^|&)\"+ name +\"=([^&]*)(&|$)\");\r\n\t\t\t\t\t\t\tvar r = window.location.search.substr(1).match(reg);\r\n\t\t\t\t\t\t\tif(r!=null)return unescape(r[2]); return null;\r\n\t\t\t\t\t\t}\t\t\t\t\t\t\r\n\t\t\t\t\t};\r\n\t\t\t\t});<\/script></div><div we7-drag we7-resize we7-rotate></div></div></div>"),e.put("widget-good-editor.html",'<div ng-controller="GoodCtrl"><div class="app-good-edit"><div class="arrow-left"></div><div class="inner"><div class="panel panel-default"><div class="panel-body"><div class="form-group"><label class="col-xs-3 control-label">颜色</label><div class="col-xs-9"><div we7-colorpicker we7-my-color="activeItem.params.baseStyle.color" we7-my-default-color="activeItem.params.baseStyle.color"></div></div></div><div class="form-group"><label class="col-xs-3 control-label">布局</label><div class="col-xs-9"><div class="btn-group"><div ng-class="{\'btn\' : \'1\', \'active\' : activeItem.params.layoutactive==\'lr\',\'btn-default\' : activeItem.params.layoutstyle != \'1\',\'btn-primary\' : activeItem.params.layoutstyle==\'1\'}" ng-click="changeLayout(\'lr\')">å·¦å³</div><div ng-class="{\'btn\' : \'1\', \'active\' : activeItem.params.layoutactive==\'ud\',\'btn-default\' : activeItem.params.layoutstyle != \'2\',\'btn-primary\' : activeItem.params.layoutstyle==\'2\'}" ng-click="changeLayout(\'ud\')">上下</div></div></div></div></div></div></div></div></div>'),e.put("widget-header-display.html",'<div ng-controller="HeaderCtrl" we7-nobar><div class="title js-default-content"><h1><span>{{module.params.title}}</span></h1></div></div>'),e.put("widget-header-editor.html",'<div ng-controller="HeaderCtrl" ng-if="activePageIndex == 0"><div class="app-header-setting"><div class="arrow-left"></div><div class="app-header-setting-inner"><div class="panel panel-default"><div class="panel-body form-horizontal"><div class="form-group"><label class="col-xs-3 control-label"><span class="red">*</span> 页é¢å称</label><div class="col-xs-9"><input type="text" ng-model="activeItem.params.title" placeholder="微页é¢æ ‡é¢˜" class="form-control"></div></div><div class="form-group"><label class="col-xs-3 control-label">页é¢æè¿°</label><div class="col-xs-9"><input type="text" ng-model="activeItem.params.description" placeholder="用户通过微信分享给朋å‹æ—¶,会自动显示页é¢æè¿°" class="form-control"></div></div><div class="form-group"><label class="col-xs-3 control-label">触å‘关键å—</label><div class="col-xs-9"><input type="text" ng-model="activeItem.params.keyword" class="form-control"> <span class="help-block">用户触å‘关键å—,系统回å¤æ¤é¡µé¢çš„图文链接.ä¸æ”¯æŒå¤šå…³é”®å—</span></div></div><div class="form-group"><label class="control-label col-xs-3"><span class="red">*</span>å°é¢</label><div class="col-xs-9"><span ng-click="addThumb(\'thumb\')"><i class="fa fa-plus-circle green"></i> 选择图片</span><div style="margin-top:.5em" class="input-group" ng-show="activeItem.params.thumb"><img width="150" class="img-responsive img-thumbnail" ng-src="{{activeItem.params.thumb}}"> <em ng-click="activeItem.params.thumb = \'\';" title="åˆ é™¤è¿™å¼ å›¾ç‰‡" style="position:absolute; top: 0px; right: -14px" class="close">×</em></div><span class="help-block">用于用户触å‘关键å—åŽï¼Œç³»ç»Ÿå›žå¤æ—¶çš„å°é¢å›¾ç‰‡</span></div></div><div class="form-group"><label class="control-label col-xs-3">å¿«æ·èœå•</label><div class="col-xs-9" style="margin-top:7px"><input type="checkbox" class="from-control" ng-click="ifCheck()" ng-checked="activeItem.params.bottom_menu"> <span>是å¦åœ¨æœ¬ä¸“题页é¢ä¸æ˜¾ç¤ºå¾®ç«™å¿«æ·èœå•</span></div></div></div></div></div></div></div>'),e.put("widget-image-display.html",'<div ng-controller="ImageCtrl" style="{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)" we7-context-menu><div style="{{module.transform}}width:100%;height:100%" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-image" style="width:100%;height:100%;{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><img style="width:100%;height:100%" ng-src="{{module.params.items.imgurl}}" alt=""></div><div we7-drag we7-resize we7-rotate></div></div></div>'),e.put("widget-image-editor.html",'<div ng-controller="ImageCtrl"><div class="app-image-edit"><div class="arrow-left"></div><div class="inner"><div class="panel panel-default"><div class="panel-body"><div class="add-image-item card clearfix" ng-show="activeItem.params.items.imgurl"><div class="col-xs-3 img"><h3 ng-click="changeItem(activeItem.params.items)">é‡æ–°ä¸Šä¼ </h3><img ng-src="{{ activeItem.params.items.imgurl }}" width="100%"></div></div><div class="add-image-editor card" ng-click="addItem()" ng-hide="activeItem.params.items.imgurl"><a href="#"><i class="fa fa-plus-circle green"></i>æ·»åŠ ä¸€ä¸ªå›¾ç‰‡</a></div></div></div></div></div></div>'),e.put("widget-line-display.html",'<div ng-controller="LineCtrl" style="{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)" we7-context-menu><div style="{{module.transform}}width:100%;height:100%" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-line" style="width:100%;height:100%;overflow:hidden;{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><div class="inner"><hr style="border-top-color:{{module.params.baseStyle.color}}"></div></div><div we7-drag we7-resize we7-rotate></div></div></div>'),e.put("widget-line-editor.html",'<div ng-controller="LineCtrl"><div class="app-line-edit"><div class="arrow-left"></div><div class="inner"><div class="panel panel-default"><div class="panel-body">辅助线(请于左侧拖动缩放调整)</div></div></div></div></div>'),e.put("widget-link-display.html",'<div ng-controller="LinkCtrl" style="{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)" we7-context-menu><div class="container-link" style="{{module.transform}}" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-link js-default-content" ng-if="module.params.items.length == 0" style="{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><div class="inner"><div class="list-group"><div class="list-group-item"><a class="clearfix" href="javascript:;"><span class="app-nav-title">点æ¤ç¼–辑第1æ¡ã€Žå…³è”链接ã€<i class="pull-right fa fa-angle-right"></i></span></a></div><div class="list-group-item"><a class="clearfix" href="javascript:;"><span class="app-nav-title">点æ¤ç¼–辑第2æ¡ã€Žå…³è”链接ã€<i class="pull-right fa fa-angle-right"></i></span></a></div><div class="list-group-item"><a class="clearfix" href="javascript:;"><span class="app-nav-title">点æ¤ç¼–辑第næ¡ã€Žå…³è”链接ã€<i class="pull-right fa fa-angle-right"></i></span></a></div></div></div></div><div ng-if="module.params.items.length != 0"><div class="app-link" style="{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.params.animate}}"><div class="inner"><div class="list-group"><div ng-repeat="item in module.params.items"><div ng-if="item.type == \'1\' && (item.selectCate.pid > 0 || item.selectCate.cid > 0)"><div class="list-group-item" ng-repeat="i in pageSize | limitTo:item.pageSize"><a class="clearfix" href="javascript:;"><span class="app-nav-title">第{{$index+1}}æ¡ {{item.selectCate.name}} 的『关è”链接ã€<i class="pull-right fa fa-angle-right"></i></span></a></div></div><div class="list-group-item" ng-if="item.type == \'2\'"><a class="clearfix" href="{{item.url}}"><span class="app-nav-title">{{item.title}} <i class="pull-right fa fa-angle-right"></i></span></a></div></div></div></div></div></div><div we7-drag></div></div></div>'),e.put("widget-link-editor.html",'<div ng-controller="LinkCtrl"><div class="app-textNav-edit"><div class="arrow-left"></div><div class="inner"><div class="panel panel-default"><div class="panel-body form-horizontal"><div class="card add-textNav-con" ng-repeat="item in activeItem.params.items"><div class="btns"><a href="javascript:" ng-click="addItem()"><i class="fa fa-plus"></i></a> <a href="javascript:" ng-click="removeItem(item)"><i class="fa fa-times"></i></a></div><div class="form-group"><label class="control-label col-xs-3"><span class="red">*</span> æ•°æ®æ¥æº</label><div class="col-xs-9"><input id="source-type1" type="radio" value="1" ng-model="item.type" name="link-type-{{$index+0}}" ng-click="changeInnerHeight()"><label class="radio-inline" for="source-type1">分类</label><input id="source-type2" type="radio" value="2" ng-model="item.type" name="link-type-{{$index+0}}" ng-click="changeInnerHeight()"><label class="radio-inline" for="source-type2">自定义</label></div></div><div class="form-group" ng-show="item.type == 2"><label class="control-label col-xs-3"><span class="red">*</span> 导航å称</label><div class="col-xs-9"><input type="text" class="form-control" name="" ng-class="{\'red\': item.title == \'\'}" ng-model="item.title"></div></div><div class="form-group" ng-show="item.type == 2"><label class="control-label col-xs-3"><span class="red">*</span> 链接到</label><div class="col-xs-9 form-control-static"><div we7-linker we7-my-url="item.url" we7-my-title="item.title"></div></div></div><div class="form-group" ng-show="item.type == 1"><label class="control-label col-xs-3"><span class="red">*</span>内容æ¥æº</label><div class="col-xs-9"><div class="input-group"><div class="form-control-static"><label ng-if="item.selectCate.id != 0" class="label label-success">{{item.selectCate.name}}</label><a href="javascript:;" ng-click="showSearchCateList(item)"><span ng-if="item.selectCate.id == 0">从分类ä¸é€‰æ‹©</span><span ng-if="item.selectCate.id != 0">修改</span></a></div></div></div></div><div class="form-group" ng-show="item.type == 1"><label class="control-label col-xs-3">æ–‡ç« å±žæ€§</label><div class="col-xs-9"><input id="article-attr-type1" type="checkbox" ng-model="item.isnew" value="1" name="attribute"><label class="checkbox-inline" for="article-attr-type1">最新</label><input id="article-attr-type2" type="checkbox" ng-model="item.iscommend" value="1" name="attribute"><label class="checkbox-inline" for="article-attr-type2">推è</label><input id="article-attr-type3" type="checkbox" ng-model="item.ishot" value="1" name="attribute"><label class="checkbox-inline" for="article-attr-type3">头æ¡</label></div></div><div class="form-group" ng-show="item.type == 1"><label class="control-label col-xs-3">显示æ¡æ•°</label><div class="col-xs-9"><select class="form-control" ng-model="item.pageSize" ng-change="changePageSize(item)"><option value="1">1æ¡</option><option value="2">2æ¡</option><option value="3">3æ¡</option><option value="4">4æ¡</option><option value="5">5æ¡</option><option value="10">10æ¡</option><option value="15">15æ¡</option><option value="20">20æ¡</option><option value="30">30æ¡</option></select></div></div></div><div class="add-textNav card"><a href="javascript:" ng-click="addItem()"><i class="fa fa-plus-circle green"></i> æ·»åŠ ä¸€ä¸ªå¯¼èˆª</a></div></div></div></div></div><div id="modal-search-cate-link" class="modal fade in" role="dialog" aria-hidden="false"><div class="modal-dialog"><div class="modal-content"><div class="modal-header"><button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button><h3>选择分类</h3></div><div class="modal-body"><table class="table table-hover"><thead class="navbar-inner"><tr><th style="width:60%">æ ‡é¢˜</th><th style="width:30%; text-align:right"><div class="input-group input-group-sm"><input type="text" class="form-control js-search-cate-keyword"> <span class="input-group-btn"><button ng-click="showSearchCateList(currentItem)" class="btn btn-default" type="button"><i class="fa fa-search"></i></button></span></div></th></tr></thead><tbody ng-repeat="pcate in searchCateList"><tr><td><a href="#">{{pcate.name}}</a></td><td class="text-right"><a class="btn btn-default btn-sm" ng-click="selectCateItem(pcate.id, 0, pcate.name)">选å–</a></td></tr><tr ng-repeat="ccate in pcate.children track by $index"><td style="padding-left:50px;height:30px;line-height:30px;background-image:url(\'./resource/images/bg_repno.gif\'); background-repeat:no-repeat; background-position: -245px -540px"><a href="#">{{ccate.name}}</a></td><td class="text-right"><a class="btn btn-default btn-sm" ng-click="selectCateItem(0, ccate.id, ccate.name)">选å–</a></td></tr></tbody></table></div></div></div></div></div>'),e.put("widget-navimg-display.html",'<div ng-controller="NavImgCtrl" style="{{module.positionStyle}}min-height:90px;transform:translate3d(0px, 0px, 0px)" we7-context-menu><div style="{{module.transform}}width:100%;height:100%" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-navImg" style="width:100%;height:100%;{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><div class="inner" style="height:100%"><ul class="clearfix" style="height:100%"><li ng-repeat="item in module.params.items" style="height:100%"><a href="{{item.url}}" style="height:100%;width:100%"><span class="nav-img" style="height:80%;width:100%" ng-if="item.imgurl"><img ng-src="{{item.imgurl}}" style="height:100%;width:95%"></span> <span class="title" title="{{item.title}}" style="height:20%;width:100%;line-height:100%">{{item.title}}</span></a></li></ul></div></div><div we7-drag we7-resize we7-rotate></div></div></div>'),e.put("widget-navimg-editor.html",'<div ng-controller="NavImgCtrl"><div class="app-nav-edit"><div class="arrow-left"></div><div class="inner"><div class="panel panel-default"><div class="panel-body form-horizontal"><div ng-repeat="item in activeItem.params.items"><div class="card nav-item clearfix"><div class="col-xs-3 img" ng-if="item.imgurl == \'\'"><span ng-click="changeItem(item)"><i class="fa fa-plus-circle green"></i> æ·»åŠ å›¾ç‰‡</span></div><div class="col-xs-3 img" ng-if="item.imgurl != \'\'"><h3 ng-click="changeItem(item)">é‡æ–°ä¸Šä¼ </h3><img ng-src="{{ item.imgurl }}"></div><div class="col-xs-9"><div class="form-group"><label class="control-label col-xs-3">æ–‡å—</label><div class="col-xs-9"><input name="title" ng-model="item.title" class="form-control" typel="text" placeholder="æ–‡å—"></div></div><div class="form-group"><label class="control-label col-xs-3">链接</label><div class="col-xs-9 form-control-static"><div we7-linker we7-my-url="item.url" we7-my-title="item.title"></div></div></div></div></div></div></div></div></div></div></div>'),e.put("widget-notice-display.html",'<div ng-controller="NoticeCtrl" style="{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)" we7-context-menu><div style="{{module.transform}}" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-notice" style="{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><div class="inner"><div class="notice-box"><div class="scrollNotice"><span class="js-scroll-notice">公告: {{module.params.notice || \'请填写内容,如果过长,将会在手机上滚动显示!\'}}</span></div></div></div></div><div we7-drag></div></div></div>'),e.put("widget-notice-editor.html",'<div ng-controller="NoticeCtrl"><div class="app-notice-edit"><div class="arrow-left"></div><div class="inner"><div class="panel panel-default"><div class="panel-body form-horizontal"><div class="form-group" style="margin-bottom:0"><label class="col-xs-2 control-label">公告</label><div class="col-xs-10"><input type="text" ng-model="activeItem.params.notice" value="" class="form-control" placeholder="请填写内容,如果过长,将会在手机上滚动显示"></div></div></div></div></div></div></div>'),e.put("widget-onlytext-display.html",'<div ng-controller="OnlyTextCtrl" style="{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)" we7-context-menu><div style="{{module.transform}}width:100%;height:100%" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-onlyText" style="width:100%;height:100%;{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><div class="element" ng-bind="module.params.title" style="overflow:hidden"></div></div><div we7-drag we7-resize we7-rotate></div></div></div>'),e.put("widget-onlytext-editor.html","<div ng-controller=\"OnlyTextCtrl\"><div class=\"app-onlyText-edit\"><div class=\"arrow-left\"></div><div class=\"inner\"><div class=\"panel panel-default\"><div class=\"panel-body\"><div class=\"form-group\"><label class=\"control-label col-xs-3\">æ–‡å—</label><div class=\"col-xs-6\"><input ng-model=\"activeItem.params.title\" class=\"form-control\"></div></div><div class=\"form-group\"><label class=\"col-xs-3 control-label\">ä½ç½®</label><div class=\"col-xs-9\"><div class=\"btn-group\"><div ng-class=\"{'btn' : '1', 'btn-default' : '1', 'active' : activeItem.params.baseStyle.textAlign == 'left', 'btn-primary' : activeItem.params.baseStyle.textAlign == 'left'}\" ng-click=\"changeTextAlign('left')\">å·¦</div><div ng-class=\"{'btn' : '1', 'btn-default' : '1', 'active' : activeItem.params.baseStyle.textAlign == 'center', 'btn-primary' : activeItem.params.baseStyle.textAlign == 'center'}\" ng-click=\"changeTextAlign('center')\">ä¸</div><div ng-class=\"{'btn' : '1', 'btn-default' : '1', 'active' : activeItem.params.baseStyle.textAlign == 'right', 'btn-primary' : activeItem.params.baseStyle.textAlign == 'right'}\" ng-click=\"changeTextAlign('right')\">å³</div></div></div></div></div></div></div></div></div>"),e.put("widget-purelink-display.html",'<div ng-controller="PureLinkCtrl" style="{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)" we7-context-menu><div style="{{module.transform}}width:100%;height:100%" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-pureLink" style="width:100%;height:100%;{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><div ng-repeat="item in module.params.items" ng-if="item.active" style="width:100%;height:100%"><div class="app-pureLink-basic animated" ng-if="item.type==\'text\'" style="width:100%;height:100%"><a ng-href="{{item.url}}" class="element-link"><div class="element-box" ng-bind="item.title" ng-style="{\'line-height\' : module.params.baseStyle.lineHeight, \'color\' : item.color}"></div></a></div><div ng-if="item.type==\'img\'" style="width:100%;height:100%"><a ng-href="{{item.url}}" class="element-link"><img ng-src="{{item.imgurl}}" style="width:100%;height:100%" alt=""></a></div></div></div><div we7-drag we7-resize we7-rotate></div></div></div>'),e.put("widget-purelink-editor.html",'<div ng-controller="PureLinkCtrl"><div class="app-pureLink-edit"><div class="arrow-left"></div><div class="inner"><div class="panel panel-default"><div class="panel-body"><ul class="nav nav-pills nav-justified"><li ng-class="{active : item.active}" ng-repeat="item in activeItem.params.items"><a ng-href="#{{item.id}}" role="tab" data-toggle="tab" ng-click="changeItem(item);"><button ng-class="{\'btn\' : 1,\'btn-danger\' : item.editcolor==\'danger\', \'btn-warning\' : item.editcolor==\'warning\', \'btn-success\' : item.editcolor==\'success\', \'btn-default\' : item.editcolor==\'default\', \'btn-primary\' : item.editcolor==\'primary\'}"><span ng-if="item.type==\'img\'" class="fa fa-picture-o"></span><span ng-if="item.id==\'1\'">点我è´ä¹°</span><span ng-if="item.id==\'2\'">点开链接</span><span ng-if="item.id==\'3\'">马上è´ä¹°</span><span ng-if="item.id==\'4\'">关注我们</span><span ng-if="item.id==\'5\'">自定义</span></button></a></li></ul><hr><div class="tab-content"><div class="tab-pane active" id="{{item.id}}" ng-repeat="item in activeItem.params.items" ng-show="item.active"><div class="form-group" ng-show="item.type==\'text\'"><label class="col-xs-3 control-label">按钮å称</label><div class="col-xs-9"><input type="text" class="form-control" ng-model="item.title"></div></div><div class="form-group" ng-show="item.type==\'img\'"><label class="col-xs-3 control-label">按钮图片</label><div class="col-xs-9"><div class="img-container"><img ng-src="{{item.imgurl}}" alt=""> <span class="change-img" ng-click="addImage(item);"><span ng-show="item.imgurl">æ›´æ¢</span><span ng-show="!item.imgurl">æ·»åŠ </span>图片</span></div></div></div><div class="form-group"><label class="col-xs-3 control-label">网站地å€</label><div class="col-xs-6"><input type="text" ng-model="item.url" class="form-control" placeholder="http://example.com"></div><div class="col-xs-3 form-control-static"><a href="http://dwz.cn/" target="_blank">生æˆçŸé“¾æŽ¥</a></div></div></div></div></div></div></div></div></div>'),e.put("widget-reward-display.html","<div ng-controller=\"RewardCtrl\" style=\"{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)\" we7-context-menu><div style=\"{{module.transform}}width:100%;height:100%\" ng-class=\"{'alock' : module.params.baseStyle.lock}\"><div class=\"app-reward\" style=\"width:100%;height:100%;{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}\"><div class=\"element\" ng-style=\"{'width': '100%', 'height': '100%', 'line-height' : module.params.baseStyle.lineHeight}\"><a style=\"width:100%;height:100%;display:block;color:inherit\" href=\"{php echo url('home/page', array('do' => 'reward', 'id' => $id))}\">打èµ</a></div></div><div we7-drag we7-resize we7-rotate></div></div></div>"),e.put("widget-reward-editor.html","<div ng-controller=\"RewardCtrl\"><div class=\"app-reward-edit\"><div class=\"arrow-left\"></div><div class=\"inner\"><div class=\"panel panel-default\"><div class=\"panel-body\"><div class=\"form-group\"><label class=\"col-xs-3 control-label\">æ–‡å—颜色</label><div class=\"col-xs-9\" ng-my-colorpicker ng-my-color=\"activeItem.params.baseStyle.color\" ng-my-default-color=\"activeItem.params.baseStyle.color\"></div></div><div class=\"form-group\"><label class=\"col-xs-3 control-label\">å—å·</label><div class=\"col-xs-9\"><div class=\"btn-group\" data-toggle=\"buttons\"><div ng-class=\"{'btn' : '1', 'active' : activeItem.params.fontactive=='big','btn-default' : activeItem.params.fonttype != 'big','btn-primary' : activeItem.params.fonttype=='big'}\" ng-click=\"changeSize('big')\">大</div><div ng-class=\"{'btn' : '1', 'active' : activeItem.params.fontactive=='middle','btn-default' : activeItem.params.fonttype != 'middle','btn-primary' : activeItem.params.fonttype=='middle'}\" ng-click=\"changeSize('middle')\">ä¸</div><div ng-class=\"{'btn' : '1', 'active' : activeItem.params.fontactive=='small','btn-default' : activeItem.params.fonttype != 'small','btn-primary' : activeItem.params.fonttype=='small'}\" ng-click=\"changeSize('small')\">å°</div></div></div></div></div></div></div></div></div>"),e.put("widget-richtext-display.html",'<div ng-controller="RichTextCtrl" style="{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)" we7-context-menu><div style="{{module.transform}}width:100%;height:100%" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-richText" style="width:100%;height:100%;word-break:break-all;overflow:hidden;{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><div class="inner" ng-style="{\'padding\' : module.params.isfull ? \'0\' : \'10px\'}" ng-bind-html="trustAsHtml(module.params.content, module.params.params)" ng-if="module.params.content || module.params.params"></div><div class="inner js-default-content" ng-if="!module.params.content && !module.params.params"><p>点æ¤ç¼–辑『富文本ã€å†…容 ——></p><p>ä½ å¯ä»¥å¯¹æ–‡å—进行 <strong>åŠ ç²—</strong>ã€<em>斜体</em>ã€<span style="text-decoration: underline">下划线</span>〠<span style="text-decoration: line-through">åˆ é™¤çº¿</span>ã€æ–‡å—<span style="color: rgb(0, 176, 240)">颜色</span>〠<span style="background-color: rgb(255, 192, 0); color: rgb(255, 255, 255)">背景色</span>〠以åŠå—å·<span style="font-size: 20px">大</span><span style="font-size: 14px">å°</span>ç‰ç®€å•æŽ’版æ“作。</p><p>还å¯ä»¥åœ¨è¿™é‡ŒåŠ å…¥è¡¨æ ¼äº†</p><table class="table-bordered"><tbody><tr><td>ä¸å¥–客户</td><td>å‘放奖å“</td><td>备注</td></tr><tr><td>猪猪</td><td>内测ç </td><td><em><span class="red">å·²ç»å‘放</span></em></td></tr><tr><td>大麦</td><td>积分</td><td><a href="#" target="_blank">领å–地å€</a></td></tr></tbody></table><p style="text-align: left"><span style="text-align: left">也å¯åœ¨è¿™é‡Œæ’入图片ã€å¹¶å¯¹å›¾ç‰‡åŠ 上超级链接,方便用户点击。</span></p></div></div><div we7-drag we7-resize we7-rotate></div></div></div>'),e.put("widget-richtext-editor.html",'<div ng-controller="RichTextCtrl"><div class="app-richText-edit"><div class="arrow-left"></div><div class="app-header-setting-new-inner"><div class="panel panel-default"><div class="panel-body form-horizontal"><div class="form-group"><label class="col-xs-3 control-label">是å¦å…¨å±</label><div class="col-xs-9"><label for="fullScreen" class="checkbox-inline"><input id="fullScreen" name="fullScreen" type="checkbox" ng-model="activeItem.params.isfull">å…¨å±æ˜¾ç¤º</label></div></div><div class="form-group"><div class="col-xs-12"><div we7-editor we7-my-value="activeItem.params.content" we7-my-params="activeItem.params.params"></div></div></div></div></div></div></div></div>'),e.put("widget-shape-display.html",'<div ng-controller="ShapeCtrl" style="{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)" we7-context-menu><div style="{{module.transform}}width:100%;height:100%" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-shape" style="width:100%;height:100%;{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><div style="width:100%;height:100%" class="element" we7-svger we7-svg="module.params.svgValue"></div></div><div we7-drag we7-resize we7-rotate></div></div></div>'),e.put("widget-shape-editor.html",'<div ng-controller="ShapeCtrl"><div class="app-shape-edit"><div class="arrow-left"></div><div class="inner"><div class="panel panel-default"><div class="panel-body"><div class="shape-editor"><a href="javascript:;" ng-click="addItem()" ng-if="!activeItem.params.svgValue"><i class="fa fa-plus-circle green"></i> 填充形状</a> <a href="javascript:;" ng-click="addItem()" ng-if="activeItem.params.svgValue"><i class="fa fa-plus-circle green"></i> 修改形状</a></div><div id="shapeModal" class="modal fade" role="dialog" aria-labelledby="gridSystemModalLabel"><div class="modal-dialog modal-lg" role="document"><div class="modal-content"><div class="modal-header"><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button><h4 class="modal-title" id="gridSystemModalLabel">形状库<span class="action">矢é‡ç´ æ,å¯æ›´æ¢é¢œè‰²ï¼Œæ”¾å¤§ä¸å¤±çœŸ</span></h4></div><div class="dialog-content bg_console sound-flex clearfix"><div class="cate-title"><ul class="nav tabs-left"><li><a href="javascript:;" data-toggle="tab">形状库</a></li></ul></div><div class="cate-list bg-rig"><div id="bg_contain"><div class="tab-pane tab-head"><div class="img_list"><div class="category_list clearfix"><ul class="category_list_container clearfix"><li class="category_item" ng-class="{\'active\' : sysCategory.active}" ng-repeat="sysCategory in sysCategoryList" ng-click="getSysCatAndList(sysCategory)" ng-bind="sysCategory.name"></li></ul></div><div class="cat_two_list"><ul ng-repeat="sysCategory in sysCategoryList" ng-if="sysCategory.active"><li class="cat_two_item" ng-class="{\'active\': sysTag.active}" ng-if="sysCategory.id == sysTag.parentid" ng-repeat="sysTag in sysImageTag" ng-click="getSysImgByTag(sysTag);" ng-bind="sysTag.name"></li></ul></div></div></div><div class="img_list"><div class="img_list_container photo_list"><ul class="img_box" style="height:348px"><li ng-if="img.parentid == activeItem.params.imgListActive" ng-repeat="img in currentImageList" style="width: 100px; height: 100px;cursor:pointer; position: relative; display: inline-block; background:50% 50% / contain no-repeat rgb(230, 235, 237)" ng-style="{backgroundImage: \'url(\' + img.imgurl + \')\'}" data-url="{{img.imgurl}}" ng-click="selectSvg($event,img)"></li></ul></div></div></div></div><div class="modal-footer bg-pagination"><div class="fl mr20" ng-show="page.numPages > 1"><ul class="pagination" style="float: left"><li><a href="" ng-click="selectPage(1)">首页</a></li><li><a href="" ng-click="selectPage(page.currentPage - 1)">‹</a></li><li ng-repeat="p in pages track by $index" ng-class="{active: p.active}"><a href="javascript:;" ng-click="selectPage(p.number)" ng-bind="p.number"></a></li><li><a href="" ng-click="selectPage(page.currentPage + 1)">›</a></li><li><a href="" ng-click="selectPage(page.numPages)">尾页</a></li></ul><div class="current_page"><span class="fl">到</span> <input type="text" ng-model="page.toPage" ng-keyup="$event.keyCode == 13 ? getImgByPage() : null"> <span class="fl">页</span> <a ng-click="getImgByPage()" class="go">确定</a></div></div><a class="modal-cancle" ng-click="cancel()">å–消</a> <a class="btn btn-primary" ng-click="confirm();">确定</a></div></div></div></div></div></div></div></div></div></div>'),e.put("widget-textnav-display.html",'<div ng-controller="TextNavCtrl" style="{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)" we7-context-menu><div style="{{module.transform}}" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-textNav" style="{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><div class="inner"><div class="list-group mnav-box"><div class="list-group-item" ng-repeat="item in module.params.items" ng-style="{\'background-color\': module.params.baseStyle.backgroundColor}"><a class="clearfix" href="{{item.url}}"><span class="app-nav-title">{{item.title}}<i class="pull-right fa fa-angle-right"></i></span></a></div></div></div></div><div we7-drag></div></div></div>'),e.put("widget-textnav-editor.html",'<div ng-controller="TextNavCtrl"><div class="app-textNav-edit"><div class="arrow-left"></div><div class="inner"><div class="panel panel-default"><div class="panel-body form-horizontal"><div class="card add-textNav-con" ng-repeat="item in activeItem.params.items"><div class="btns"><a href="javascript:" ng-click="addItem()"><i class="fa fa-plus"></i></a> <a href="javascript:" ng-click="removeItem(item)"><i class="fa fa-times"></i></a></div><div class="form-group"><label class="control-label col-xs-3"><span class="red">*</span> 导航å称</label><div class="col-xs-9"><input type="text" class="form-control" name="" ng-class="{\'red\': item.title == \'\'}" ng-model="item.title" value=""></div></div><div class="form-group"><label class="control-label col-xs-3"><span class="red">*</span> 链接到</label><div class="col-xs-9 form-control-static"><div we7-linker we7-my-url="item.url" we7-my-title="item.title"></div></div></div></div><div class="add-textNav card"><a href="javascript:" ng-click="addItem()"><i class="fa fa-plus-circle green"></i> æ·»åŠ ä¸€ä¸ªæ–‡æœ¬å¯¼èˆª</a></div></div></div></div></div></div>'),e.put("widget-title-display.html",'<div ng-controller="TitleCtrl" style="{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)" we7-context-menu><div style="{{module.transform}}" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-title" style="{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><div class="inner" style="height:96px"><div ng-if="module.params.template == 1" class="title-detail tradition" style="text-align: {{module.params.tradition.align}}"><h2 class="title-con">{{ module.params.title || "ç‚¹å‡»ç¼–è¾‘ã€Žæ ‡é¢˜ã€"}}<span ng-if="module.params.tradition.nav.enable == 1" class="title-link">- <a href="{{module.params.tradition.nav.url}}" ng-bind="module.params.tradition.nav.title">文本导航</a></span></h2><p class="sub-title" ng-bind="module.params.tradition.subtitle">å‰¯æ ‡é¢˜</p></div><div ng-if="module.params.template == 2" class="title-detail text-left wx"><h2 class="title-con">{{ module.params.title || "ç‚¹å‡»ç¼–è¾‘ã€Žæ ‡é¢˜ã€"}}</h2><p class="sub-title"><span class="date" ng-bind="module.params.news.date">2015-03-12</span> <span class="author" ng-bind="module.params.news.author">zhangsan</span> <span><a href="{{module.params.news.url}}" ng-bind="module.params.news.title">微擎团队</a></span></p></div></div></div><div we7-drag></div></div></div>'),e.put("widget-title-editor.html",'<div ng-controller="TitleCtrl"><div class="app-title-edit"><div class="arrow-left"></div><div class="inner"><div class="panel panel-default"><div class="panel-body form-horizontal"><div class="form-group"><label class="col-xs-3 control-label"><span class="red">*</span> æ ‡é¢˜å</label><div class="col-xs-9"><input type="text" class="form-control" name="" ng-model="activeItem.params.title" value=""></div></div><div class="form-group"><label class="control-label col-xs-3">æ ‡é¢˜æ¨¡æ¿</label><div class="col-xs-9"><input type="radio" name="title-style" ng-model="activeItem.params.template" value="1" class="tradition" id="template-type1"><label class="radio-inline" for="template-type1">ä¼ ç»Ÿæ ·å¼</label><input type="radio" name="title-style" ng-model="activeItem.params.template" value="2" class="wx" id="template-type2"><label class="radio-inline" for="template-type2">æ¨¡ä»¿å¾®ä¿¡å›¾æ–‡é¡µæ ·å¼</label></div></div><div class="form-group" ng-if="activeItem.params.template == 1"><label class="col-xs-3 control-label">å‰¯æ ‡é¢˜</label><div class="col-xs-6"><input type="text" class="form-control" ng-model="activeItem.params.tradition.subtitle" value=""></div><div class="col-xs-3 form-control-static"><span class="date"><a href="javascript:;" we7-date-picker we7-date-value="activeItem.params.tradition.subtitle">日期</a></span></div></div><div class="form-group" ng-if="activeItem.params.template == 1"><label class="control-label col-xs-3">显示</label><div class="col-xs-9"><input type="radio" name="tra-style" value="left" ng-model="activeItem.params.tradition.align" id="show-type1"><label class="radio-inline" for="show-type1">居左显示</label><input type="radio" name="tra-style" value="center" ng-model="activeItem.params.tradition.align" id="show-type2"><label class="radio-inline" for="show-type2">å±…ä¸æ˜¾ç¤º</label><input type="radio" name="tra-style" value="right" ng-model="activeItem.params.tradition.align" id="show-type3"><label class="radio-inline" for="show-type3">å±…å³æ˜¾ç¤º</label></div></div><div class="add-textNav card" ng-if="activeItem.params.template == 1 && activeItem.params.tradition.nav.enable == 0"><a href="javascript:" ng-click="changeNavEnable(1)"><i class="fa fa-plus-circle green"></i> æ·»åŠ ä¸€ä¸ªæ–‡æœ¬å¯¼èˆª</a></div><div class="card" style="padding:20px" ng-if="activeItem.params.template == 1 && activeItem.params.tradition.nav.enable == 1"><div class="btns"><a href="javascript:" ng-click="changeNavEnable(0)"><i class="fa fa-times"></i></a></div><div class="form-group"><label class="col-xs-3 control-label"><span class="red">*</span> å称</label><div class="col-xs-9"><input type="text" class="form-control" name="" ng-model="activeItem.params.tradition.nav.title" value=""></div></div><div class="form-group"><label class="col-xs-3 control-label"><span class="red">*</span> 链接</label><div class="col-xs-9 form-control-static"><div we7-linker we7-my-url="activeItem.params.tradition.nav.url" we7-my-title="activeItem.params.tradition.nav.title"></div></div></div></div><div class="form-group" ng-if="activeItem.params.template == 2"><label class="col-xs-3 control-label">日期</label><div class="col-xs-9"><input type="text" class="form-control" name="" we7-date-picker we7-date-value="activeItem.params.news.date" value=""></div></div><div class="form-group" ng-if="activeItem.params.template == 2"><label class="col-xs-3 control-label">作者</label><div class="col-xs-9"><input type="text" class="form-control" name="" ng-model="activeItem.params.news.author" value=""></div></div><div class="form-group" ng-if="activeItem.params.template == 2"><label class="col-xs-3 control-label">é“¾æŽ¥æ ‡é¢˜</label><div class="col-xs-9"><input type="text" class="form-control" name="" ng-model="activeItem.params.news.title" value=""></div></div><div class="form-group" ng-if="activeItem.params.template == 2"><label class="control-label col-xs-3">链接地å€</label><div class="col-xs-9"><div we7-linker we7-my-url="activeItem.params.news.url" we7-my-title="activeItem.params.news.title"></div></div></div></div></div></div></div></div>'),e.put("widget-white-display.html",'<div ng-controller="WhiteCtrl" style="{{module.positionStyle}}transform:translate3d(0px, 0px, 0px)" we7-context-menu><div style="{{module.transform}}width:100%;height:100%" ng-class="{\'alock\' : module.params.baseStyle.lock}"><div class="app-white" style="width:100%;height:100%;overflow:hidden;{{module.baseStyle}}{{module.borderStyle}}{{module.shadowStyle}}{{module.animationStyle}}"><div class="inner"></div></div><div we7-drag we7-resize we7-rotate></div></div></div>'),e.put("widget-white-editor.html",'<div ng-controller="WhiteCtrl"><div class="app-white-edit"><div class="arrow-left"></div><div class="inner"><div class="panel panel-default"><div class="panel-body">空白高度(请于左侧拖动缩放调整)</div></div></div></div></div>'),e.put("directive-selectmore-module-item.html",'<ul class="app-list"><li class="select" ng-repeat="module in selectModules"><div class="app-info"><img ng-src="{{module.icon}}"><p>{{module.title}}</p></div><div class="cover-dark"><a href="javascript:;" class="cover-delect" ng-click="delModule(module);"><i class="fa fa-minus-circle"></i>åˆ é™¤</a></div><input type="hidden" name="select_modules[]" value="{{module.module}}"> <input type="hidden" name="select_modules_version[]" value="{{module.version}}"></li><li class="select select-more" ng-click="selectMore()"></li></ul><div class="wxapp-modules"><div id="modules-Modal" class="modal fade" tabindex="-1" role="dialog" aria-hidden="true"><div class="modal-dialog modal-dialog-default modal-lg"><div class="modal-content"><div class="modal-header"><button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button><h3><ul role="tablist" class="nav nav-pills" style="font-size:14px; margin-top:-20px"><li role="presentation" class="basic"><a data-toggle="tab" data-type="basic" role="tab" aria-controls="baisc" href="#basic">选择需è¦æ‰“包的应用</a></li></ul></h3></div><div class="modal-body modules-content"><div class="tab-content"><div class="info text-center" ng-show="$scope.apps.length == 0"><i class="fa fa-spinner fa-pulse fa-lg"></i> æ•°æ®åŠ è½½ä¸</div><ul class="app-allow-list"><li ng-repeat="module in wxappModuleList"><div class="app-info"><img ng-src="{{module.logo}}"><p>{{module.title}}</p></div><a href="javascript:;" ng-click="selectModule(module)" class="cover-dark"><i class="fa fa-check cover-selected"></i></a></li></ul></div></div><div class="modal-footer"></div></div></div></div></div>'),e.put("directive-multipage-multipage.html",'<div class="page-navigator"><div class="top-title">页é¢</div><div class="page-list"><ul><li class="page-menu" ng-repeat="page in allPages track by $index" ng-click="navToPage($index)" ng-init="" ng-class="{\'current\' : page.num-1 == $index}"><div class="page-thumb-block" ng-class="{active : page.active}"><div class="page-thumb"><div class="page-thumb-con"></div></div><div class="page-menu-title" ng-bind="{{$index+1}}"></div><div class="icon icon-remove" ng-click="removePage($index);"><span class="fa fa-trash"></span></div><div class="icon icon-copy" ng-click="copyPage($index, $event);" ng-if="isMultiPage"><span class="fa fa-copy"></span></div></div></li></ul></div><div class="add-blank-page" ng-click="insertPage();" ng-if="isMultiPage">+</div><div class="template hidden"><ul class="nav nav-tabs nav-justified"><li class="active"><a href="#">普通版å¼</a></li><li><a href="#">统计版å¼</a></li><li><a href="#">特效版å¼</a></li></ul><div class="template-area"><div class="template-item"><div class="add-icon"><span class="fa fa-plus-circle"></span></div><div class="text">空白页</div></div><div class="template-item"><img src="" alt=""></div><div class="template-item"><img src="" alt=""></div><div class="template-item"><img src="" alt=""></div><div class="template-item"><img src="" alt=""></div><div class="template-item"><img src="" alt=""></div><div class="template-item"><img src="" alt=""></div></div></div></div>')}]),angular.module("wapeditorApp",["we7app"]),angular.module("wapeditorApp").controller("CommonCtrl",["$scope","$sanitize",function(e,t){}]),angular.module("wapeditorApp").directive("we7ContextMenu",["serviceBase","$timeout",function(o,r){return{link:function(s,i,e){$(".right-hand-menu").length||($("body").append('<menu class="right-hand-menu"> <li class="menu-item menu-item-del"> <button type="button" class="menu-btn"> <i class="fa fa-folder-open"></i> <span class="menu-text">åˆ é™¤</span> </button> </li> <li class="menu-item menu-item-top"> <button type="button" class="menu-btn"> <i class="fa fa-folder-open"></i> <span class="menu-text">置顶</span> </button> </li> <li class="menu-item menu-item-up"> <button type="button" class="menu-btn"> <i class="fa fa-folder-open"></i> <span class="menu-text">上移一层</span> </button> </li> <li class="menu-item menu-item-down"> <button type="button" class="menu-btn"> <i class="fa fa-folder-open"></i> <span class="menu-text">下移一层</span> </button> </li> <li class="menu-item menu-item-bottom"> <button type="button" class="menu-btn"> <i class="fa fa-folder-open"></i> <span class="menu-text">置底</span> </button> </li> </menu>'),$(".modules").on("contextmenu",function(e){e.preventDefault()}),$(document).on("mouseup",function(){$(".right-hand-menu").removeClass("show-menu")}),$(".right-hand-menu").on("click",".menu-item-del",function(){var e=$(".right-hand-menu").data("item-index");o.deleteItem(e),r(function(){s.$apply()},100)}).on("click",".menu-item-top",function(){s.savePagePosition();var e,t,a=$(".right-hand-menu").data("item-index"),n=[];for(t in s.activeModules)s.activeModules[t].index==a?e=angular.copy(s.activeModules[t]):n.push(s.activeModules[t]);n.push(e),o.setBaseData("activeModules",n),r(function(){s.$apply()},100)}).on("click",".menu-item-up",function(){s.savePagePosition();var e,t,a,n=$(".right-hand-menu").data("item-index"),i=s.activeModules.length;for(a in s.activeModules)if(s.activeModules[a].index==n){if(parseInt(a)+1==i)break;e=angular.copy(s.activeModules[a]),t=angular.copy(s.activeModules[parseInt(a)+1]),s.activeModules[a]=t,s.activeModules[parseInt(a)+1]=e,o.setBaseData("activeModules",s.activeModules);break}r(function(){s.$apply()},100)}).on("click",".menu-item-down",function(){s.savePagePosition();var e,t,a,n=$(".right-hand-menu").data("item-index");for(a in s.activeModules)if(s.activeModules[a].index==n){if(a<=1)break;e=angular.copy(s.activeModules[a]),t=angular.copy(s.activeModules[a-1]),s.activeModules[a]=t,s.activeModules[parseInt(a)-1]=e,o.setBaseData("activeModules",s.activeModules);break}r(function(){s.$apply()},100)}).on("click",".menu-item-bottom",function(){s.savePagePosition();var e,t,a=$(".right-hand-menu").data("item-index"),n=[];for(t in s.activeModules)0!=t&&(s.activeModules[t].index==a?e=angular.copy(s.activeModules[t]):n.push(s.activeModules[t]));n.unshift(e),n.unshift(s.activeModules[0]),o.setBaseData("activeModules",n),r(function(){s.$apply()},100)})),i.on("contextmenu",function(e){var t,a;t=e.pageX,a=e.pageY,n=$(".right-hand-menu"),e=n.parent().position(),t-=e.left,a-=e.top,n.css({left:t+"px",top:a+"px"}),n.addClass("show-menu");var n=i.parents("div[id^='module-']").attr("index");$(".right-hand-menu").data("item-index",n)})}}}]),angular.module("wapeditorApp").directive("we7Nobar",function(){return{link:function(e,t,a){t.on("mousedown",function(e){$(".bar").hide()})}}}).directive("we7Drag",["serviceBase","$timeout",function(o,e){return{compile:function(e,t){var a=$('<div class="bar bar-n ui-resizable-handle ui-resizable-n we7-hide"></div>'),n=$('<div class="bar bar-s ui-resizable-handle ui-resizable-s we7-hide"></div>'),i=$('<div class="bar bar-e ui-resizable-handle ui-resizable-e we7-hide"></div>'),s=$('<div class="bar bar-w ui-resizable-handle ui-resizable-w we7-hide"></div>');return e.append(a).append(n).append(i).append(s),function(e,t,a){var n=t.parents("div[ng-controller$='Ctrl']").eq(0);n.on("mousedown",function(e){$(".bar").hide(),$(this).find(".bar").show(),$(this).find(".bar-radius").show(),$(this).draggable({containment:""})}),n.mousedown();t=o.getBaseData("activeItem");t.id&&("HeaderCtrl"!=(n=t.id.replace(/[a-z]/,function(e){return e.toLocaleUpperCase()}).replace(/^[a-z]/,function(e){return e.toLocaleUpperCase()})+"Ctrl")?((n=$("#module-"+t.index).find("div[ng-controller='"+n+"']")).on("mousedown",function(e){$(".bar").hide(),$(this).find(".bar").show(),$(this).find(".bar-radius").show(),$(this).draggable({containment:""})}),n.mousedown()):$(".bar").hide())}}}}]).directive("we7Resize",function(){return{compile:function(e,t){var a=$('<div class="bar-radius radius-s we7-hide"></div>'),n=$('<div class="bar bar-nw bar-radius radius-s ui-resizable-handle ui-resizable-nw we7-hide"></div>'),i=$('<div class="bar bar-se bar-radius radius-s ui-resizable-handle ui-resizable-se we7-hide"></div>'),s=$('<div class="bar bar-sw bar-radius radius-s ui-resizable-handle ui-resizable-sw we7-hide"></div>'),o=$('<div class="bar bar-ne bar-radius radius-s ui-resizable-handle ui-resizable-ne we7-hide"></div>');return e.find(".bar-n,.bar-s,.bar-e,.bar-w").append(a),e.append(i).append(s).append(o).append(n),function(e,t,a){t.parents("div[ng-controller$='Ctrl']").eq(0).on("mousedown",function(e){var t={n:$(this).find(".bar-n"),s:$(this).find(".bar-s"),e:$(this).find(".bar-e"),w:$(this).find(".bar-w"),nw:$(this).find(".bar-nw"),se:$(this).find(".bar-se"),sw:$(this).find(".bar-sw"),ne:$(this).find(".bar-ne")};$(this).resizable({handles:t,aspectRatio:!0,onlyCorner:!0})})}}}}).directive("we7Rotate",function(){return{link:function(o,e,t){e.prepend('<div class="bar bar-rotate bar-radius radius-s ui-resizable-handle we7-hide"></div> <div class="bar bar-line ui-resizable-handle we7-hide"></div>');var a=e.parents("div[ng-controller$='Ctrl']").eq(0);a.on("mousedown",function(e){var n,t=a.find(".bar-rotate").get(0),i=a.children(),t=new Hammer(t),s={};t.get("pan").set({threhold:0}),t.on("panstart",function(e){$("body").css({"user-select":"none",cursor:'url("./resource/images/mouserotate.ico"), default'}),s={x:i.offset().left+i.width()/2,y:i.offset().top+i.height()/2}}),t.on("panmove",function(e){var t=e.center,a=t.x-s.x,e=t.y-s.y+$(window).scrollTop(),t=Math.abs(a/e);n=Math.atan(t)/(2*Math.PI)*360,0<a&&e<0?n=360+n:0<a&&0<e?n=180-n:a<0&&0<e?n=180+n:a<0&&e<0&&(n=360-n),360<n&&(n-=360),n=parseInt(n),i.css({transform:"rotateZ("+n+"deg)"}),o.activeItem.params.borderStyle.transform=n,o.$apply()}),t.on("panend",function(){$("body").css({"user-select":"initial",cursor:"default"})})})}}}),angular.module("wapeditorApp").directive("we7EditKeyMap",["serviceBase","$timeout",function(s,o){return{restrict:"A",link:function(i,e,t){$(document).unbind("keydown").keydown(function(e){var t=s.getBaseData("activeModules"),a=s.getBaseData("activeItem"),n=_.findIndex(t,a);46==e.keyCode&&0<n&&(e.preventDefault(),confirm("åˆ é™¤åŽéœ€è¦é‡æ–°æ交æ‰ä¼šç”Ÿæ•ˆï¼Œç¡®è®¤å—?")&&(t.splice(n,1),s.setBaseData({activeModules:t,activeItem:t[0]}))),37!=e.keyCode&&38!=e.keyCode&&39!=e.keyCode&&40!=e.keyCode||(_.isEmpty(a)||e.preventDefault(),37==e.keyCode&&--a.params.positionStyle.left,38==e.keyCode&&--a.params.positionStyle.top,39==e.keyCode&&(a.params.positionStyle.left+=1),40==e.keyCode&&(a.params.positionStyle.top+=1)),o(function(){i.$apply()})}).unbind("keyup").keyup(function(){i.$apply()})}}}]),angular.module("wapeditorApp").directive("we7Pagelength",function(){return{replace:!0,templateUrl:"directive-pagelength-pagelength.html",link:function(e,t,a){}}}),angular.module("wapeditorApp").directive("we7Style",["serviceSetStyle",function(e){return{templateUrl:"directive-style-style.html"}}]),angular.module("wapeditorApp").directive("we7Svger",function(){return{scope:{we7svg:"=we7Svg"},link:function(n,i,e){n.$watch("we7svg",function(){for(var e=$(n.we7svg),t=0;e.length>t;t++)if("svg"==e[t].tagName){var a=e[t];$(a).attr({width:"100%",height:"100%"}),$(a)[0].setAttribute("preserveAspectRatio","none"),i.html(a);break}})}}}),angular.module("wapeditorApp").factory("serviceBase",["$rootScope","widget","config","serviceCommon","serviceSetStyle","$timeout",function(a,s,e,t,o,n){var r={},l={modules:[],editors:[],activeModules:[],index:0,activeItem:{},activeIndex:0,pageLength:1,isNew:!0};return r.setModules=function(e,t){if(_.isNull(e)&&(l.modules=s),_.isArray(e))for(i in e){var a;-1<(n=_.findIndex(s,{id:e[i]}))&&(a=angular.copy(s[n]),l.modules.push(a))}if(_.isArray(t))for(i in t){var n;-1<(n=_.findIndex(l.modules,{id:t[i]}))&&(l.modules[n].defaultshow=!0)}return l.modules},r.setEditors=function(e){l.editors.push(e)},r.updateActiveModules=function(e,t){t&&l.activeModules.push({id:e.id,name:e.name,params:angular.copy(e.params),originParams:angular.copy(e.params),issystem:e.issystem?1:0,index:l.index,displayorder:e.displayorder||l.activeModules.length})},r.initActiveModules=function(e){return l.activeModules=e?angular.copy(e):[],l.activeModules},r.addItem=function(n,i){angular.forEach(l.modules,function(e,t){var a;e.id==n&&(a={},a=angular.copy(e),-1==$.inArray(n,l.editors)&&(r.setEditors(e.id),r.broadcast("editors")),"header"!=n&&"UCheader"!=n&&(a.params="uc"===i?o.UcInitStyleParams(e.params):o.initStyleParams(e.params)),r.updateActiveModules(a,!0),l.activeIndex=_.findIndex(l.activeModules,{index:parseInt(l.index)}),l.activeItem="uc"===i?l.activeModules[l.index]:l.activeModules[l.activeIndex],l.index++,r.triggerActiveItem(l.activeIndex),$(".app-text-edit").find(".nav-tabs").find("a[href='#attribute']").click(),r.broadcast("activeItem"),r.broadcast("activeModules"),"header"!=n&&"UCheader"!=n&&o.initSetStyle(a.params))})},r.editItem=function(e){-1<(e=_.findIndex(l.activeModules,{index:parseInt(e)}))&&(l.activeIndex=e,l.activeItem=l.activeModules[e]),-1==$.inArray(l.activeItem.id,l.editors)&&(r.setEditors(l.activeItem.id),r.broadcast("editors")),r.triggerActiveItem(e),$(".app-text-edit").find(".nav-tabs").find("a[href='#attribute']").click(),r.broadcast("activeItem")},r.deleteItem=function(e){var t;confirm("åˆ é™¤åŽéœ€è¦é‡æ–°æ交æ‰ä¼šç”Ÿæ•ˆï¼Œç¡®è®¤å—?")&&(t=$("#module-"+e).prev().attr("index"),e=_.findIndex(l.activeModules,{index:parseInt(e)}),l.activeModules=_.without(l.activeModules,l.activeModules[e]),l.activeIndex=_.findIndex(l.activeModules,{index:parseInt(t)}),l.activeItem=l.activeModules[l.activeIndex],r.broadcast("activeItem"),r.broadcast("activeModules"))},r.triggerActiveItem=function(e){$("#module-"+l.activeModules[e].index).size()&&$("#editor"+l.activeModules[e].id).size()?clearTimeout(timer):timer=n(function(){r.triggerActiveItem(e)},50)},r.getBaseData=function(e){return l[e]},r.setBaseData=function(e,t){angular.isObject(e)?angular.forEach(e,function(e,t){l[t]=e}):l[e]=t,r.broadcast(e)},r.broadcast=function(e){switch(e){case"activeItem":a.$broadcast("serviceBase.activeItem.update",l.activeItem);break;case"activeModules":a.$broadcast("serviceBase.activeModules.update",l.activeModules);break;case"editors":a.$broadcast("serviceBase.editors.update",l.editors);break;case"modules":case"index":case"activeIndex":case"pageLength":case"isNew":break;default:angular.isObject(e)&&angular.forEach(e,function(e,t){switch(t){case"activeItem":a.$broadcast("serviceBase.activeItem.update",l.activeItem);break;case"activeModules":a.$broadcast("serviceBase.activeModules.update",l.activeModules);break;case"editors":a.$broadcast("serviceBase.editors.update",l.editors)}})}},r}]),angular.module("wapeditorApp").service("serviceCommon",["$window",function(a){var n={getCssname:function(e){for(var t="",a=0,n=parseInt(e.length);a<n;a++)-1!=e[a].search(/[A-Z]/)?t+="-"+e[a].toLowerCase():t+=e[a];return t},getMaxScopeIndex:function(e){var t,a=e[e.length-1].property,n=0;for(t in a)n=n<a[t].index?parseInt(a[t].index):n;return n},getHeaderIndex:function(e){var a=0;return angular.forEach(e,function(e,t){"header"==e.id&&(a=t)}),a},url:function(e){e=e.split("/");var t="./index.php?i="+a.sysinfo.uniacid+"&j="+a.sysinfo.acid+"&c="+e[0];return e[1]&&(t+="&a="+e[1]),e[2]&&(t+="&do="+e[2]),t},tomedia:function(e){return a.sysinfo.attachurl+e},buildDataTagBegin:function(e,t){t={params:t,uniacid:a.sysinfo.uniacid,acid:a.sysinfo.acid};return"{data func='site_widget_"+e+"' module='widget' widgetdata="+encodeURIComponent(JSON.stringify(t))+" }"},buildDataTagEnd:function(){return"{/data}"},stripHaskey:function(e){for(var t in e)"$$hashKey"==t?delete e[t]:"object"==typeof e[t]&&n.stripHaskey(e[t]);return e},copySuccess:function(e,t){var e=parseInt(e),t=t,a=$("#copy-"+e).next().html();(!a||a.indexOf('<span class="label label-success" style="position:absolute;z-index:10;width:90px;height:34px;line-height:28px;"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>')<0)&&$("#copy-"+e).after(t),setTimeout(function(){t.remove()},2e3)}};return n}]),angular.module("wapeditorApp").value("widget",[{id:"header",name:"微页é¢æ ‡é¢˜",issystem:!0,params:{title:"微页é¢æ ‡é¢˜",description:"",pageHeight:568,thumb:"",bgColor:"",bottom_menu:!1,baseStyle:{},borderStyle:{},shadowStyle:{},positionStyle:{},animationStyle:{}}},{id:"UCheader",name:"会员主页",issystem:!0,params:{title:"会员主页",cover:"",bgImage:""}},{id:"cardBasic",name:"会员å¡åŸºæœ¬è®¾ç½®",issystem:!0,params:{title:"会员å¡",color:{title:"#333",rank:"#333",name:"#333",number:"#333"},card_level:{type:1},card_label:{type:1,title:"会员å¡æ ‡é¢˜"},description:"1ã€æœ¬å¡é‡‡å–è®°å消费方å¼\n2ã€æŒå¡äººå¯äº«å—ä¼šå‘˜ä¸“å±žä¼˜æƒ \n3ã€æœ¬å¡ä¸èƒ½ä¸Žå…¶ä»–ä¼˜æƒ æ´»åŠ¨åŒæ—¶ä½¿ç”¨\n4ã€æŒå¡äººå¯ç”¨å¡å†…ä½™é¢è¿›è¡Œæ¶ˆè´¹",background:{type:"system",image:util.tomedia("images/global/card/6.png")},logo:util.tomedia("http://www.baidu.com/img/bdlogo.gif"),format_type:1,format:"WQ2015*****#####***",fields:[{title:"姓å",require:1,bind:"realname"},{title:"手机",require:1,bind:"mobile"}],grant:{credit1:0,credit2:0,coupon:[]},grant_rate:0,offset_rate:0,offset_max:0}},{id:"cardActivity",name:"æ¶ˆè´¹ä¼˜æƒ è®¾ç½®",issystem:!0,params:{discount_type:0,discount_style:1,discounts:[],content:"",bgColor:""}},{id:"cardNums",name:"会员å¡æ¬¡æ•°è®¾ç½®",issystem:!0,params:{nums_status:0,nums_style:1,nums_text:"å¯ç”¨æ¬¡æ•°",nums:[{recharge:100,num:5},{recharge:200,num:10}]}},{id:"cardTimes",name:"会员å¡è®¡æ—¶è®¾ç½®",issystem:!0,params:{times_status:0,times_style:1,times_text:"截至日期",times:[{recharge:100,time:5},{recharge:200,time:10}]}},{id:"cardRecharge",name:"å……å€¼ä¼˜æƒ è®¾ç½®",issystem:!0,params:{recharge_type:0,recharge_style:1,grant_rate_switch:1,recharges:[{condition:"",back:"",backtype:"0",backunit:"å…ƒ"},{condition:"",back:"",backtype:"0",backunit:"å…ƒ"},{condition:"",back:"",backtype:"0",backunit:"å…ƒ"},{condition:"",back:"",backtype:"0",backunit:"å…ƒ"}],content:"",bgColor:""}},{id:"onlyText",name:"æ–‡å—",isbase:!0,params:{title:"请输入文å—",baseStyle:{},borderStyle:{},shadowStyle:{},animationStyle:{},positionStyle:{top:100,left:60,width:200,height:30}}},{id:"image",name:"图片",isbase:!0,params:{items:{id:"",imgurl:""},baseStyle:{},borderStyle:{},shadowStyle:{},animationStyle:{},positionStyle:{top:169,left:0,width:100,height:100}}},{id:"shape",name:"形状",isbase:!0,params:{svgValue:"",baseStyle:{},borderStyle:{},shadowStyle:{},animationStyle:{},positionStyle:{top:64,left:0,width:100,height:100}}},{id:"pureLink",name:"链接",isbase:!0,params:{items:[{id:"1",type:"text",title:"点我è´ä¹°",url:"",color:"#fff",editcolor:"danger",discolor:"#d9534f",active:1},{id:"2",type:"text",title:"点开链接",url:"",color:"#fff",editcolor:"warning",discolor:"#ec971f",active:0},{id:"3",type:"text",title:"马上è´ä¹°",url:"",color:"#fff",editcolor:"success",discolor:"#449d44",active:0},{id:"4",type:"text",title:"关注我们",url:"",color:"#000",editcolor:"default",discolor:"#fff",active:0},{id:"5",type:"img",title:"自定义",url:"",imgurl:"",editcolor:"primary",discolor:"",active:0}],baseStyle:{backgroundColor:"#d9534f",color:"#fff",textAlign:"center",fontSize:"14",lineHeight:"33px"},borderStyle:{borderWidth:1,borderRadius:4,borderStyle:"solid",borderColor:"#ADADAD"},shadowStyle:{},animationStyle:{},positionStyle:{top:244,left:0,width:85,height:35}}},{id:"dial",name:"拨å·",isbase:!0,params:{items:[{id:"1",type:"text",title:"一键拨å·",tel:"",color:"#fff",editcolor:"danger",discolor:"#d9534f",active:1},{id:"2",type:"text",title:"çƒçº¿ç”µè¯",tel:"",color:"#fff",editcolor:"warning",discolor:"#ec971f",active:0},{id:"3",type:"text",title:"拨打电è¯",tel:"",color:"#fff",editcolor:"success",discolor:"#449d44",active:0},{id:"4",type:"text",title:"销售专线",tel:"",color:"#000",editcolor:"default",discolor:"#fff",active:0},{id:"5",type:"img",title:"自定义",tel:"",imgurl:"",editcolor:"primary",discolor:"",active:0}],baseStyle:{backgroundColor:"#d9534f",color:"#fff",textAlign:"center",fontSize:"14",lineHeight:"33px"},borderStyle:{borderWidth:1,borderRadius:4,borderStyle:"solid",borderColor:"#ADADAD"},shadowStyle:{},animationStyle:{},positionStyle:{top:274,left:100,width:85,height:35}}},{id:"good",name:"点赞",isbase:!0,params:{bgcolor:"#d15d82",color:"#fff",layoutstyle:1,layoutactive:"lr",baseStyle:{color:"#fff",backgroundColor:"#d15d82",fontSize:"14px",textAlign:"center",lineHeight:"48px"},borderStyle:{borderWidth:1,borderRadius:4,borderStyle:"solid",borderColor:"#ADADAD"},shadowStyle:{},animationStyle:{},positionStyle:{width:150,height:50,top:174,left:70}}},{id:"countDown",name:"倒计时",isbase:!0,params:{leftTimeText:{day:0,hour:0,min:0,sec:0},deadtime:"",textalign:"center",baseStyle:{fontSize:"13px",textAlign:"center",lineHeight:"48px"},borderStyle:{borderWidth:1,borderRadius:4,borderStyle:"solid",borderColor:"#ccc"},shadowStyle:{},animationStyle:{},positionStyle:{top:315,left:50}}},{id:"richText",name:"富文本",params:{bgColor:"",content:"",isfull:!1,baseStyle:{},borderStyle:{},shadowStyle:{},animationStyle:{},positionStyle:{left:0,top:10,width:320,height:410}}},{id:"adImg",name:"å¹»ç¯ç‰‡",params:{listStyle:1,sizeType:1,items:[],baseStyle:{},borderStyle:{},shadowStyle:{},animationStyle:{},positionStyle:{left:0,width:320,height:80}}},{id:"cube",name:"图片é”æ–¹",params:{layout:{},showIndex:0,selection:{},currentPos:{},currentLayout:{isempty:!0},baseStyle:{},borderStyle:{},shadowStyle:{},animationStyle:{},positionStyle:{left:0,width:320,height:30}}},{id:"title",name:"æ ‡é¢˜",params:{title:"",template:1,tradition:{subtitle:"",align:"left",nav:{title:"",url:"",enable:0}},news:{date:"",author:"",title:"",urlType:1,url:""},baseStyle:{},borderStyle:{},shadowStyle:{},animationStyle:{},positionStyle:{left:0,width:320,height:96}}},{id:"textNav",name:"文本导航",params:{items:[],borderStyle:{},shadowStyle:{},animationStyle:{},positionStyle:{left:0,width:320,height:30}}},{id:"navImg",name:"图片导航",params:{items:[{imgurl:"",title:"",url:""},{imgurl:"",title:"",url:""},{imgurl:"",title:"",url:""},{imgurl:"",title:"",url:""}],borderStyle:{},shadowStyle:{},animationStyle:{},positionStyle:{left:0,width:320,height:100}}},{id:"link",name:"å…³è”链接",params:{items:[],baseStyle:{lineHeight:"inherit"},borderStyle:{},shadowStyle:{},animationStyle:{},positionStyle:{left:0,width:320,height:100}}},{id:"line",name:"辅助线",params:{baseStyle:{},borderStyle:{},shadowStyle:{},animationStyle:{},positionStyle:{height:30}}},{id:"white",name:"辅助空白",params:{baseStyle:{},borderStyle:{},shadowStyle:{},animationStyle:{},positionStyle:{left:0,width:320,height:20}}},{id:"audio",name:"è¯éŸ³",params:{style:"1",headimg:"",align:"left",title:"",isloop:!1,reload:"false",audio:{id:"",url:""},baseStyle:{},borderStyle:{},shadowStyle:{},animationStyle:{},positionStyle:{left:0,width:320,height:60}}},{id:"notice",name:"公告",params:{notice:"",baseStyle:{backgroundColor:"#ffc"},borderStyle:{},shadowStyle:{},animationStyle:{},positionStyle:{left:0,width:320,height:40}}}]),angular.module("wapeditorApp").service("serviceDrag",function(){console.log("serviceDrag")}),angular.module("wapeditorApp").service("serviceSetStyle",["$rootScope","$timeout","serviceCommon","config",function(r,i,s,e){var n={},a=1;return n.defBaseStyle={backgroundColor:"rgba(0,0,0,0)",color:"#000",opacity:0,paddingTop:0,lineHeight:2,fontSize:14,textAlign:"left",lock:!1},n.defBorderStyle={borderWidth:0,borderRadius:2,borderStyle:"solid",borderColor:"rgba(0,0,0,1)",transform:0},n.defShadowStyle={shadowSize:0,shadowBlur:0,shadowColor:"rgba(0,0,0,0.5)",shadowDirection:1},n.defAnimationStyle={animationName:"noEffect",animationDuration:1,animationTimingFunction:"ease",animationDelay:.6,animationFillMode:"both"},n.defPositionStyle={top:259,left:40,width:240,height:50},n.initStyleParams=function(e){var t={};return(t=angular.copy(e)).baseStyle=$.extend(!1,n.defBaseStyle,e.baseStyle),t.borderStyle=$.extend(!1,n.defBorderStyle,e.borderStyle),t.shadowStyle=$.extend(!1,n.defShadowStyle,e.shadowStyle),t.animationStyle=$.extend(!1,n.defAnimationStyle,e.animationStyle),t.positionStyle=$.extend(!1,n.defPositionStyle,e.positionStyle),0<$(".app-preview").scrollTop()&&(t.positionStyle.top+=parseInt($(".app-preview").scrollTop())),200<t.positionStyle.left?t.positionStyle.left=10:t.positionStyle.left+=5*a,t.positionStyle.top+=5*a,20<a?a=1:a++,t},n.UcInitStyleParams=function(e){var t={};return(t=angular.copy(e)).baseStyle=$.extend(!1,n.defBaseStyle,e.baseStyle),t.borderStyle=$.extend(!1,n.defBorderStyle,e.borderStyle),t.shadowStyle=$.extend(!1,n.defShadowStyle,e.shadowStyle),t.animationStyle=$.extend(!1,n.defAnimationStyle,e.animationStyle),t.positionStyle=$.extend(!1,n.defPositionStyle,e.positionStyle),0<$(".app-preview").scrollTop()&&(t.positionStyle.top+=parseInt($(".app-preview").scrollTop())),200<t.positionStyle.left?t.positionStyle.left=10:t.positionStyle.left+=5*a,t.positionStyle.top+=5*a-$(".app-usercenter").height(),10<a?a=1:a++,t},n.initSetStyle=function(e){n.setModuleBaseStyle(e.baseStyle),n.setModuleBorderStyle(e.borderStyle),n.setModuleShadowStyle(e.shadowStyle),n.setModulePositionStyle(e.positionStyle),n.setModuleAnimationStyle(e.animationStyle)},n.setModuleBaseStyle=function(e){var t,a="";for(t in e=$.extend(!1,n.defBaseStyle,e))switch(t){case"fontSize":"number"!=typeof e[t]&&e[t].search(/rem/)?a+=s.getCssname(t)+":14px;":a+=s.getCssname(t)+":"+parseInt(e[t])+"px;";case"paddingTop":case"paddingBottom":a+=s.getCssname(t)+":"+parseInt(e[t])+"px;";break;case"backgroundColor":case"color":case"textAlign":case"lineHeight":a+=s.getCssname(t)+":"+e[t]+";";break;case"opacity":a+=s.getCssname(t)+":"+(100-parseInt(e[t]))/100+";"}r.$broadcast("serviceBase.activeItem.style.update","baseStyle",e,a)},n.setModuleBorderStyle=function(e){e=$.extend(!1,n.defBorderStyle,e);var t,a=newTransformStyle="";for(t in e)switch(t){case"borderWidth":case"borderRadius":a+=s.getCssname(t)+":"+parseInt(e[t])+"px;";break;case"borderStyle":case"borderColor":a+=s.getCssname(t)+":"+e[t]+";";break;case"transform":newTransformStyle+="transform: rotateZ("+parseInt(e[t])+"deg);"}r.$broadcast("serviceBase.activeItem.style.update","borderStyle",e,a,newTransformStyle)},n.setModuleShadowStyle=function(e){e=$.extend(!1,n.defShadowStyle,e);var t,a=shadowY=0,a=-Math.sin(e.shadowDirection*Math.PI/180)*e.shadowSize;shadowY=Math.cos(e.shadowDirection*Math.PI/180)*e.shadowSize,t="box-shadow: "+a+"px "+shadowY+"px "+e.shadowBlur+"px "+e.shadowColor+";",r.$broadcast("serviceBase.activeItem.style.update","shadowStyle",e,t)},n.setModuleAnimationStyle=function(e){var t=(e=$.extend(!1,n.defAnimationStyle,e)).animationName+" "+e.animationDuration+"s "+e.animationTimingFunction+" "+e.animationDelay+"s "+e.animationFillMode,a=n.cssCompatible("animation",t);r.$broadcast("serviceBase.activeItem.style.update","animationStyle",e,a)},n.setModulePositionStyle=function(e){var t,a="position:absolute;";for(t in e=$.extend(!1,n.defPositionStyle,e))switch(t){case"top":case"left":case"width":case"height":a+=" "+t+": "+e[t]+"px;"}r.$broadcast("serviceBase.activeItem.style.update","positionStyle",e,a)},n.clearModuleStyle=function(e){e.params.baseStyle=e.originParams.baseStyle,e.params.borderStyle=e.originParams.borderStyle,e.params.shadowStyle=e.originParams.shadowStyle,e.params.animationStyle=e.originParams.animationStyle,r.$broadcast("serviceBase.activeItem.update",e)},n.eleAnimationIns=function(e){var t=s.getCssname(e);i(function(){$("."+t).parent().addClass("select").siblings(".select").removeClass("select")},100),r.$broadcast("serviceBase.activeItem.animationName.update",e)},n.savePagePosition=function(o){$(".modules").find("div.ng-scope[ng-controller$='Ctrl']").each(function(){var e=$(this).parent().parent(),t=_.findIndex(o,{index:parseInt(e.attr("index"))}),a=$(this).css("top"),n=$(this).css("left"),i=$(this).css("width"),s=$(this).css("height"),e="position:absolute;top:"+a+";left:"+n+";width:"+i+";height:"+s+";";o[t].params.positionStyle.top=parseInt(a),o[t].params.positionStyle.left=parseInt(n),o[t].params.positionStyle.width=parseInt(i),o[t].params.positionStyle.height=parseInt(s),o[t].positionStyle=e}),r.$broadcast("serviceBase.activeModules.update",o)},n.saveModulePosition=function(e){var t="#module-"+e.index,a=$(t).find("div.ng-scope[ng-controller$='Ctrl']"),n=a.css("top"),i=a.css("left"),s=a.css("width"),t=a.css("height"),a="position:absolute;top:"+n+";left:"+i+";width:"+s+";height:"+t+";";return e.params.positionStyle.top=parseInt(n),e.params.positionStyle.left=parseInt(i),e.params.positionStyle.width=parseInt(s),e.params.positionStyle.height=parseInt(t),e.positionStyle=a,r.$broadcast("serviceBase.activeItem.update",e),e},n.changeTextAlign=function(e,t){e.params.baseStyle.textAlign=t,r.$broadcast("serviceBase.activeItem.update",e)},n.changeBorderWidth=function(t){"adImg"!=t.id&&"cube"!=t.id&&"title"!=t.id&&"textNav"!=t.id&&"link"!=t.id&&"audio"!=t.id||i(function(){var e=n.saveModulePosition(t);e.positionStyle.height+=2*e.borderStyle.borderWidth,"audio"==t.id&&(e.positionStyle.height+=20),n.setModulePositionStyle(e.params.positionStyle)},100)},n.changeInnerHeight=function(a){i(function(){var e=n.saveModulePosition(a),t=e.index,t=$("#module-"+t).find(".inner"),t=parseInt(t.css("height"));t+=2*e.params.borderStyle.borderWidth,e.params.positionStyle.height=t,n.setModulePositionStyle(e.params.positionStyle)},100)},n.changePageLength=function(e,t){var a=!(1<(e=parseInt(e))),n=e;return i(function(){$(".app-content").css("height",568*e+"px")},100),t[s.getHeaderIndex(t)].params.pageLength=e,r.$broadcast("updateScope",{isMultiPage:a,pageLength:n,activeModules:t}),t},n.cssCompatible=function(e,t){if(angular.isString(e)&&angular.isString(t))return e+": "+t+";-webkit-"+e+": "+t+";-moz-"+e+": "+t+";-o-"+e+": "+t+";-ms-"+e+": "+t+";"},n}]),angular.module("wapeditorApp").service("serviceSubmit",["serviceBase","serviceCommon",function(a,p){var e={submit:function(){var u="",e={params:{},html:""},t=$($(".modules").html()),d=a.getBaseData("activeModules");t.find("div.ng-scope[ng-controller$='Ctrl']").each(function(){var e=_.findIndex(d,{index:parseInt($(this).parent().parent().attr("index"))}),t=$(this).find("div[class^='app-']").get(0),a=$(t).attr("style");d[e].params.animate=d[e].params.animateTemp,a+="animation:"+d[e].params.animate+";",$(t).attr("style",a);var n,i=angular.copy(d[e].params);$(this).find(".js-default-content").remove();var s,o,r,l=$(this).parent().parent().attr("name").toLowerCase();switch("UCheader"!=l&&"cardBasic"!=l&&"cardActivity"!=l&&"cardNums"!=l&&"cardTimes"!=l&&"cardRecharge"!=l&&(r="position:absolute;top:"+(s=$(this).css("top"))+";left:"+(o=$(this).css("left"))+";width:"+(t=$(this).css("width"))+";height:"+(a=$(this).css("height"))+";",d[e].params.positionStyle.top=parseInt(s),d[e].params.positionStyle.left=parseInt(o),d[e].params.positionStyle.width=parseInt(t),d[e].params.positionStyle.height=parseInt(a),d[e].positionStyle=r),l){case"link":var c=this;angular.forEach(i.items,function(e,t){(e.selectCate.pid||e.selectCate.cid)&&$(c).find(".list-group").children().eq(t).replaceWith("<div>"+p.buildDataTagBegin("link",e)+'<div class="list-group-item ng-scope"><a href="{$row[url]}" class="clearfix"><span class="app-nav-title"> {$row[title]}<i class="pull-right fa fa-angle-right"></i></span></a></div>'+p.buildDataTagEnd()+"</div>")});break;case"richtext":d[e]&&(d[e].params.content="")}n=$(this).html(),"header"!=l&&(r=$(this).attr("style"),u+='<div type="'+l+'" style="'+r+'">'+n+"</div>"),e++});t=d[0].params.bgColor;return u=(u=(u=(u='<div class="js-design-page" style="background-color:'+t+'">'+u+"</div>").replace(/<\!\-\-([^-]*?)\-\->/g,"")).replace(/ ng\-[a-zA-Z-]+=\"[^\"]*\"/g,"")).replace(/ ng\-[a-zA-Z]+/g,""),e.html=u,e.params=angular.copy(d),p.stripHaskey(e.params),e}};return e}]),angular.module("wapeditorApp").service("serviceUpwardCompatible",["$rootScope","$timeout","orderByFilter",function(e,t,s){var a={compatibility:function(e){for(var t in void 0!==e[0].params.pageHeight&&(e[0].params.pageLength=Math.ceil(e[0].params.pageHeight/568)),e=s(e,"displayorder")){e[t].params.baseStyle instanceof Array&&(e[t].params.baseStyle={}),e[t].params.borderStyle instanceof Array&&(e[t].params.borderStyle={}),e[t].params.shadowStyle instanceof Array&&(e[t].params.shadowStyle={}),e[t].params.positionStyle instanceof Array&&(e[t].params.positionStyle={});var a=angular.copy(e[t].params);switch(e[t].animationStyle="",e[t].params.animationStyle={},e[t].params.animate?(i=(i=e[t].params.animate.match(/(\w+)\s1/))?i[1]:"noEffect",e[t].params.animationStyle.name=i):e[t].params.animationStyle.name="noEffect",e[t].params.animationStyle={name:e[t].params.animationStyle.name,speed:1,delay:.6},e[t].animationStyle="animation: "+e[t].params.animate+";",e[t].params.positionStyle=_.isEmpty(e[t].params.positionStyle)?{}:e[t].params.positionStyle,e[t].params.baseStyle=_.isEmpty(e[t].params.baseStyle)?{}:e[t].params.baseStyle,e[t].params.borderStyle=_.isEmpty(e[t].params.borderStyle)?{}:e[t].params.borderStyle,e[t].params.shadowStyle=_.isEmpty(e[t].params.shadowStyle)?{}:e[t].params.shadowStyle,e[t].baseStyle="",e[t].borderStyle="",e[t].shadowStyle="",e[t].positionStyle="",e[t].id){case"onlyText":e[t].params.baseStyle.textAlign=a.postype,e[t].params.baseStyle.fontSize=a.baseStyle.fontsize,e[t].params.baseStyle.lineHeight=a.baseStyle.lineheight,e[t].params.positionStyle.left=a.positionStyle.marginleft||0,e[t].params.positionStyle.width=a.positionStyle.width||290,e[t].params.positionStyle.height=a.positionStyle.height||0,e[t].baseStyle="font-size:"+a.baseStyle.fontsize+"px;text-align:"+a.postype+";line-height:"+a.baseStyle.lineheight+";";break;case"image":e[t].params.positionStyle.left=a.positionStyle.marginleft||0,e[t].params.positionStyle.width=a.positionStyle.width||0,e[t].params.positionStyle.height=a.positionStyle.height||0;break;case"shape":e[t].params.positionStyle.left=a.positionStyle.marginleft||0,e[t].params.positionStyle.width=a.positionStyle.width||100,e[t].params.positionStyle.height=a.positionStyle.height||0;break;case"pureLink":case"dial":for(var n in e[t].params.baseStyle.fontSize=a.baseStyle.fontsize?a.baseStyle.fontsize+"px":"14px",e[t].params.baseStyle.textAlign="center",a.items)if(1==a.items[n].active){e[t].params.baseStyle.backgroundColor=a.items[n].discolor,e[t].params.baseStyle.color=a.items[n].color;break}e[t].params.positionStyle.left=a.positionStyle.marginleft||0,e[t].params.positionStyle.width=a.positionStyle.width||320-a.positionStyle.marginleft,e[t].params.positionStyle.height=a.positionStyle.height||35,e[t].params.baseStyle.lineHeight=e[t].params.positionStyle.height+"px",e[t].params.borderStyle.borderWidth=1,e[t].params.borderStyle.borderRadius=8,e[t].params.borderStyle.borderStyle="solid",e[t].params.borderStyle.borderColor="#ADADAD",e[t].baseStyle="font-size:"+e[t].params.baseStyle.fontSize+";text-align:center;background-color:"+a.items[n].discolor+";color:"+a.items[n].color+";line-height:"+e[t].params.baseStyle.lineHeight+";",e[t].borderStyle="border-radius:8px; border-width: 1px;border-style: solid;border-color: #ADADAD;";break;case"good":e[t].params.baseStyle.fontSize=a.baseStyle.fontsize+"px",e[t].params.baseStyle.textAlign="center",e[t].params.baseStyle.color=a.color,e[t].params.baseStyle.backgroundColor="#d15d82",e[t].params.borderStyle.borderRadius=5,e[t].params.positionStyle.left=a.positionStyle.marginleft||0,e[t].params.positionStyle.width=a.positionStyle.width||320-a.positionStyle.marginleft,1==a.layoutstyle?e[t].params.positionStyle.height=a.positionStyle.height||35:e[t].params.positionStyle.height=a.positionStyle.height||54,e[t].params.baseStyle.lineHeight=e[t].params.positionStyle.height+"px",e[t].baseStyle="font-size:"+e[t].params.baseStyle.fontSize+";text-align:center;background-color:#d15d82;color:"+a.color+";line-height:"+e[t].params.baseStyle.lineHeight+";",e[t].borderStyle="border-radius:5px;";break;case"countDown":e[t].params.baseStyle.fontSize=a.baseStyle.fontsize+"px",e[t].params.baseStyle.textAlign="center",e[t].params.positionStyle.left=a.positionStyle.marginleft||0,e[t].params.positionStyle.width=a.positionStyle.width||320,e[t].params.positionStyle.height=a.positionStyle.height||35,e[t].params.baseStyle.lineHeight=e[t].params.positionStyle.height+"px",e[t].params.borderStyle.borderWidth=1,e[t].params.borderStyle.borderStyle="solid",e[t].params.borderStyle.borderColor="#ccc",e[t].baseStyle="font-size:"+e[t].params.baseStyle.fontSize+";text-align:center;line-height:"+e[t].params.baseStyle.lineHeight+";",e[t].borderStyle="border-width: 1px;border-style: solid;border-color: #ccc;";break;case"title":e[t].params.baseStyle.backgroundColor=a.tradition.bgcolor,e[t].baseStyle="background-color:"+a.tradition.bgcolor+";";case"white":e[t].params.positionStyle.height=e[t].params.height;case"richText":case"adImg":case"cube":case"textNav":case"navImg":case"link":case"line":case"audio":case"notice":void 0!==a.positionStyle?e[t].params.positionStyle.left=a.positionStyle.marginleft||0:e[t].params.positionStyle.left=0,e[t].params.positionStyle.width=320}var i="";heightStyle="",e[t].params.positionStyle.width&&(i="width:"+e[t].params.positionStyle.width+"px;"),e[t].params.positionStyle.height&&(heightStyle="height:"+e[t].params.positionStyle.height+"px;"),e[t].positionStyle="position:relative;left:"+e[t].params.positionStyle.left+"px;"+i+heightStyle,void 0!==a.positionStyle?e[t].marginTop=a.positionStyle.margintop||0:e[t].marginTop=0}return e}};return a}]),angular.module("wapeditorApp").controller("AdImgCtrl",["$scope",function(n){n.addItem=function(){require(["fileUploader"],function(e){e.show(function(e){n.activeItem.params.items.push({id:e.id,imgurl:e.url,title:"",url:"",isactive:!1}),$.each(n.activeItem.params.items,function(e,t){n.activeItem.params.items[0].isactive=0==e}),n.$apply("activeItem"),n.changeInnerHeight()},{direct:!0,multiple:!1})})},n.removeItem=function(e){for(i in index=$.inArray(e,n.activeItem.params.items),items=_.clone(n.activeItem.params.items),n.activeItem.params.items=[],items)i!=index&&n.activeItem.params.items.push(items[i]);n.changeInnerHeight()},n.addEmpty=function(){n.activeItem.params.items.push({imgurl:"",title:"",url:""}),n.changeInnerHeight()},n.changeItem=function(a){require(["fileUploader"],function(e){e.init(function(e){var t=$.inArray(a,n.activeItem.params.items);-1<t&&(n.activeItem.params.items[t].id=e.id,n.activeItem.params.items[t].imgurl=e.url,n.$apply())},{direct:!0,multiple:!1})}),n.changeInnerHeight()}}]),angular.module("wapeditorApp").controller("AudioCtrl",["$scope",function(a){a.addAudioItem=function(){require(["fileUploader"],function(e){e.init(function(e){e&&(a.activeItem.params.audio.id=e.id,a.activeItem.params.audio.url=e.attachment,a.$apply(),$(".audio-player-play").click(function(){var e,t=a.activeItem.params.audio.url;t&&($("#player").remove(),e=$('<div id="player"></div>'),$(document.body).append(e),e.data("control",$(this)),e.jPlayer({playing:function(){$(this).data("control").find("i").removeClass("fa-play").addClass("fa-stop")},pause:function(e){$(this).data("control").find("i").removeClass("fa-stop").addClass("fa-play")},swfPath:"resource/components/jplayer",supplied:"mp3,wma,wav,amr",solution:"html, flash"}),e.jPlayer("setMedia",{mp3:t}).jPlayer("play"),$(this).find("i").hasClass("fa-stop")?e.jPlayer("stop"):e.jPlayer("setMedia",{mp3:t}).jPlayer("play"))}).show())},{direct:!0,multiple:!1,type:"audio"})})},a.addImgItem=function(){require(["fileUploader"],function(e){e.init(function(e){a.activeItem.params.headimg=e.url,a.$apply()},{direct:!0,multiple:!1})})},a.changeInnerHeight=function(){a.changeInnerHeight()}}]),angular.module("wapeditorApp").controller("CountDownCtrl",["$scope","$timeout",function(n,t){n.$watch("activeItem.params.deadtime",function(e,t){var a;n.activeItem.params.leftTimeText={day:0,hour:0,min:0,sec:0},d=(dtime=e&&void 0!==e&&0!=e?(a=e.replace(/:/g,"-").replace(/ /g,"-").split("-"),dtime=new Date(Date.UTC(a[0],a[1]-1,a[2],a[3]-8,a[4],a[5])),parseInt(dtime.getTime())):(a=Date.parse(new Date),parseInt(2592e6+a)),new Date(dtime)),n.activeItem.params.deadtime=d.getFullYear()+"-"+(d.getMonth()+1)+"-"+d.getDate()+" "+d.getHours()+":"+d.getMinutes()+":"+d.getSeconds(),n.activeItem.params.deadtimeToMin=d.getFullYear()+"-"+(d.getMonth()+1)+"-"+d.getDate()+" "+d.getHours()+":"+d.getMinutes(),i()});var i=function(){var e=Date.parse(new Date),e=0<dtime-e?dtime-e:0;n.activeItem.params.leftTimeText.day=parseInt(e/864e5),n.activeItem.params.leftTimeText.hour=parseInt(e/36e5%24),n.activeItem.params.leftTimeText.min=parseInt(e/6e4%60),n.activeItem.params.leftTimeText.sec=parseInt(e/1e3%60),t(i,1e3)}}]),angular.module("wapeditorApp").controller("CubeCtrl",["$scope",function(s){if(s.activeItem.params&&s.activeItem.params.layout&&_.isEmpty(s.activeItem.params.layout))for(row=0;row<4;row++)for(s.activeItem.params.layout[row]={},col=0;col<4;col++)s.activeItem.params.layout[row][col]={cols:1,rows:1,isempty:!0,imgurl:"",classname:""};$(".layout-table").bind("mouseover",function(e){var a,n;"LI"==e.target.tagName&&($(".layout-table li").removeClass("selected"),a=$(e.target).attr("data-rows"),n=$(e.target).attr("data-cols"),$(".layout-table li").filter(function(e,t){return $(t).attr("data-rows")<=a&&$(t).attr("data-cols")<=n}).addClass("selected"))}),s.activeItem.params.currentLayout={},s.showSelection=function(e,t){s.activeItem.params.currentPos={row:e,col:t},s.activeItem.params.selection={};var a=-1,n=1;for(i=e;i<4;i++){for(y=1,s.activeItem.params.selection[n]={},j=t;j<4;j++)0<=a&&a<j||(!_.isUndefined(s.activeItem.params.layout[i][j])&&s.activeItem.params.layout[i][j].isempty?(s.activeItem.params.selection[n][y]={rows:n,cols:y},y++):a=j-1);n++}return $(".layout-table li").removeClass("selected"),s.modalobj=$("#modal-cube-layout").modal({show:!0}),!0},s.selectLayout=function(e,t,a,n){for(_.isUndefined(a)&&(a=0),_.isUndefined(n)&&(n=0),s.activeItem.params.layout[e][t]={cols:n,rows:a,isempty:!1,imgurl:"",classname:"index-"+s.activeItem.params.showIndex},i=e;i<parseInt(e)+parseInt(a);i++)for(j=t;j<parseInt(t)+parseInt(n);j++)e==i&&t==j||delete s.activeItem.params.layout[i][j];return s.activeItem.params.showIndex++,s.modalobj.modal("hide"),s.changeItem(e,t),!0},s.addItem=function(e,t){require(["fileUploader"],function(e){e.show(function(e){s.activeItem.params.currentLayout.id=e.id,s.activeItem.params.currentLayout.imgurl=e.url,s.$apply(),s.changeInnerHeight()},{direct:!0,multiple:!1})})},s.changeItem=function(a,n){$("#cube-editor td").removeClass("current").filter(function(e,t){return $(t).attr("x")==a&&$(t).attr("y")==n}).addClass("current"),$("#thumb").attr("src",""),s.activeItem.params.currentLayout=s.activeItem.params.layout[a][n]},s.removeItem=function(){for(var e=0;e<4;e++)for(var t=0;t<4;t++)if(!_.isEmpty(s.activeItem.params.layout[e][t])&&s.activeItem.params.currentLayout.classname==s.activeItem.params.layout[e][t].classname){if(1<s.activeItem.params.currentLayout.rows)for(var a=0;a<s.activeItem.params.currentLayout.rows;a++){var n=e+a;if(s.activeItem.params.layout[n][t]={cols:1,rows:1,isempty:!0,imgurl:"",classname:""},1<s.activeItem.params.currentLayout.cols)for(var i=0;i<s.activeItem.params.currentLayout.cols;i++)s.activeItem.params.layout[n][t+i]={cols:1,rows:1,isempty:!0,imgurl:"",classname:""}}else if(s.activeItem.params.layout[e][t]={cols:1,rows:1,isempty:!0,imgurl:"",classname:""},1<s.activeItem.params.currentLayout.cols)for(i=0;i<s.activeItem.params.currentLayout.cols;i++)s.activeItem.params.layout[e][t+i]={cols:1,rows:1,isempty:!0,imgurl:"",classname:""};s.activeItem.params.currentLayout={}}}}]),angular.module("wapeditorApp").controller("DialCtrl",["$scope",function(t){t.changeItem=function(e){for(i in 5==e.id?(t.activeItem.paddingTop=angular.copy(t.activeItem.params.baseStyle.paddingTop),t.activeItem.params.baseStyle.paddingTop=0):t.activeItem.params.baseStyle.paddingTop=t.activeItem.params.baseStyle.paddingTop||t.activeItem.paddingTop,index=$.inArray(e,t.activeItem.params.items),t.activeItem.params.items)i==index?(t.activeItem.params.items[i].active=1,t.activeItem.params.baseStyle.color=t.activeItem.params.items[i].color,t.activeItem.params.baseStyle.backgroundColor=t.activeItem.params.items[i].discolor):t.activeItem.params.items[i].active=0},t.addImage=function(e){for(i in index=$.inArray(e,t.activeItem.params.items),t.activeItem.params.items)i==index&&require(["fileUploader"],function(e){e.show(function(e){t.saveModulePosition(),t.resetPosition(e),t.activeItem.params.items[i].imgurl=e.url,t.$apply()},{direct:!0,multiple:!1})})},t.resetPosition=function(e){e.width&&e.height&&(t.activeItem.params.positionStyle.width=e.width,t.activeItem.params.positionStyle.height=e.height,t.setModulePositionStyle(t.activeItem.params.positionStyle))}}]),angular.module("wapeditorApp").controller("GoodCtrl",["$scope",function(t){t.changeLayout=function(e){switch(e){case"lr":t.activeItem.params.layoutstyle=1;break;case"ud":t.activeItem.params.layoutstyle=2}}}]),angular.module("wapeditorApp").controller("HeaderCtrl",["$scope",function(a){a.addThumb=function(t){require(["fileUploader"],function(e){e.show(function(e){a.activeItem.params[t]=e.url,a.$apply("activeItem")},{direct:!0,multiple:!1})})},a.ifCheck=function(){a.activeItem.params.bottom_menu=!a.activeItem.params.bottom_menu}}]),angular.module("wapeditorApp").controller("ImageCtrl",["$scope",function(t){t.addItem=function(){require(["fileUploader"],function(e){e.show(function(e){t.saveModulePosition(),t.resetPosition(e),t.activeItem.params.items={id:e.id,imgurl:e.url},t.$apply()},{direct:!0,multiple:!1})})},t.changeItem=function(e){require(["fileUploader"],function(e){e.init(function(e){t.saveModulePosition(),t.resetPosition(e),t.activeItem.params.items.id=e.id,t.activeItem.params.items.imgurl=e.url,t.$apply()},{direct:!0,multiple:!1})})},t.resetPosition=function(e){e.width&&e.height&&(w=e.width,h=e.height,w>=h?(t.activeItem.params.positionStyle.width=100,t.activeItem.params.positionStyle.height=t.activeItem.params.positionStyle.width*h/w):(t.activeItem.params.positionStyle.height=100,t.activeItem.params.positionStyle.width=t.activeItem.params.positionStyle.height*w/h),t.setModulePositionStyle(t.activeItem.params.positionStyle))}}]),angular.module("wapeditorApp").controller("LineCtrl",["$scope",function(e){}]),angular.module("wapeditorApp").controller("LinkCtrl",["$scope","$http",function(o,t){o.pageSize=_.range(0,30),o.addItem=function(){o.activeItem.params.items.push({title:"",url:"",type:1,selectCate:{name:"",id:0},pageSize:3})},o.removeItem=function(e){for(i in index=$.inArray(e,o.activeItem.params.items),items=_.clone(o.activeItem.params.items),o.activeItem.params.items=[],items)i!=index&&o.activeItem.params.items.push(items[i]);o.changeInnerHeight()},o.showSearchCateList=function(e){o.currentItem=e;e=$(".js-search-cate-keyword").val();return t.get("./index.php?c=utility&a=link&do=catelist&keyword="+(e=void 0===e?"":e)).success(function(e,t,a,n){o.searchCateList=[];var s=e.message.message;for(i in s)o.searchCateList.push({id:s[i].id,name:s[i].name,children:s[i].children});o.modalobj=$("#modal-search-cate-link").modal({show:!0})}),!0},o.selectCateItem=function(e,t,a){return o.currentItem.selectCate={pid:e,cid:t,name:a},o.modalobj.modal("hide"),!0}}]),angular.module("wapeditorApp").controller("NavImgCtrl",["$scope",function(a){a.changeItem=function(t){require(["fileUploader"],function(e){e.show(function(e){t.id=e.id,t.imgurl=e.url,a.$apply()},{direct:!0,multiple:!1})})}}]),angular.module("wapeditorApp").controller("NoticeCtrl",["$scope",function(e){}]),angular.module("wapeditorApp").controller("OnlyTextCtrl",["$scope",function(e){}]),angular.module("wapeditorApp").controller("PureLinkCtrl",["$scope",function(t){t.changeItem=function(e){for(i in 5==e.id?(t.activeItem.paddingTop=angular.copy(t.activeItem.params.baseStyle.paddingTop),t.activeItem.params.baseStyle.paddingTop=0):t.activeItem.params.baseStyle.paddingTop=t.activeItem.params.baseStyle.paddingTop||t.activeItem.paddingTop,index=$.inArray(e,t.activeItem.params.items),t.activeItem.params.items)i==index?(t.activeItem.params.items[i].active=1,t.activeItem.params.baseStyle.color=t.activeItem.params.items[i].color,t.activeItem.params.baseStyle.backgroundColor=t.activeItem.params.items[i].discolor):t.activeItem.params.items[i].active=0},t.addImage=function(e){for(i in index=$.inArray(e,t.activeItem.params.items),t.activeItem.params.items)i==index&&require(["fileUploader"],function(e){e.show(function(e){t.saveModulePosition(),t.resetPosition(e),t.activeItem.params.items[i].imgurl=e.url,t.$apply()},{direct:!0,multiple:!1})})},t.resetPosition=function(e){e.width&&e.height&&(t.activeItem.params.positionStyle.width=e.width,t.activeItem.params.positionStyle.height=e.height,t.setModulePositionStyle(t.activeItem.params.positionStyle))}}]),angular.module("wapeditorApp").controller("RewardCtrl",["$scope",function(t){t.changeSize=function(e){switch(t.activeItem.params.fontactive=e,t.activeItem.params.fonttype=e){case"big":t.activeItem.params.baseStyle.fontSize="36px";break;case"middle":t.activeItem.params.baseStyle.fontSize="26px";break;case"small":t.activeItem.params.baseStyle.fontSize="16px"}}}]),angular.module("wapeditorApp").controller("RichTextCtrl",["$scope","$sce",function(e,a){e.trustAsHtml=function(e,t){return!e&&t&&(e=t.replace(/\#quot;/g,""")),a.trustAsHtml(e)}}]),angular.module("wapeditorApp").controller("ShapeCtrl",["$scope","$http",function(r,a){r.page={currentPage:1,numPages:1,toPage:"",totalItems:0,pageSize:18},r.addItem=function(){a({method:"GET",url:window.sysinfo.siteroot+"web/resource/images/app/shape/shape.json",cache:!0}).success(function(e){r.sysCategoryList=e.sysCategoryList,r.sysImageTag=e.sysImageTag,r.sysImageList=e.sysImageList,r.activeItem.params.catlistActive=1,r.activeItem.params.imgListActive=4,r.page.numPages=s(),r.pages=l(),o(1),r.currentImageList=c(r.activeItem.params.imgListActive,1),$("#shapeModal").modal("show")})},r.getSysCatAndList=function(e){var t,a=$.inArray(e,r.sysCategoryList);for(t in r.sysCategoryList)if(t==a){r.sysCategoryList[t].active=!0,r.activeItem.params.catlistActive=r.sysCategoryList[t].id;var n,i=1;for(n in r.sysImageTag)r.sysImageTag[n].parentid==r.sysCategoryList[t].id&&1==i?(r.activeItem.params.imgListActive=r.sysImageTag[n].id,r.sysImageTag[n].active=!0,r.page.numPages=s(),r.pages=l(),o(1),r.currentImageList=c(r.activeItem.params.imgListActive,1),i++):r.sysImageTag[n].active=!1}else r.sysCategoryList[t].active=!1},r.getSysImgByTag=function(e){var t,a=$.inArray(e,r.sysImageTag);for(t in r.sysImageTag)t==a?(r.sysImageTag[t].active=!0,r.activeItem.params.imgListActive=r.sysImageTag[t].id,r.page.numPages=s(),r.pages=l(),o(1),r.currentImageList=c(r.activeItem.params.imgListActive,1)):r.sysImageTag[t].active=!1},r.selectSvg=function(e,t){e=(e=e.target.dataset.url).split("../");a({method:"GET",url:window.sysinfo.siteroot+e[1]}).success(function(e){for(var t,a=$(e),n=a.length,i=0;i<n;i++)if("svg"==a[i].tagName){t=a[i];break}r.saveModulePosition();var s=parseFloat($(t).attr("width")),o=parseFloat($(t).attr("height"));o<=s?r.activeItem.params.positionStyle.height=r.activeItem.params.positionStyle.width*o/s:r.activeItem.params.positionStyle.width=r.activeItem.params.positionStyle.height*s/o,r.setModulePositionStyle(r.activeItem.params.positionStyle),r.activeItem.params.svgValue=e,$("#shapeModal").modal("hide")})},r.selectPage=function(e){0<(e=parseInt(e))&&e<=r.page.numPages&&(r.page.currentPage=e,r.pages=l(),o(e),r.currentImageList=c(r.activeItem.params.imgListActive,e))},r.getImgByPage=function(){var e=parseInt(r.page.toPage);0<e&&e<=r.page.numPages&&(r.page.currentPage=e,r.pages=l(),o(e),r.currentImageList=c(r.activeItem.params.imgListActive,e))};var s=function(){var e=t(r.activeItem.params.imgListActive);return Math.ceil(e/r.page.pageSize)},o=function(e){for(var t in r.pages)e==r.pages[t].number?r.pages[t].active=!0:r.pages[t].active=!1},l=function(){var e=[];if(r.page.numPages<=5)for(var t=1;t<=r.page.numPages;t++)r.page.currentPage==t?e.push({number:t,active:!0}):e.push({number:t,active:!1});else{var a=r.page.currentPage-2,n=r.page.currentPage+2;if(0<a)if(n<=r.page.numPages)e=[{number:a,active:!1},{number:r.page.currentPage-1,active:!1},{number:r.page.currentPage,active:!0},{number:r.page.currentPage+1,active:!1},{number:n,active:!1}];else for(t=r.page.numPages-4;t<=r.page.numPages;t++)t==r.page.currentPage?e.push({number:t,active:!0}):e.push({number:t,active:!1});else for(t=1;t<=5;t++)r.page.currentPage==t?e.push({number:t,active:!0}):e.push({number:t,active:!1})}return e},t=function(e){var t,a=0;for(t in r.sysImageList)e==r.sysImageList[t].parentid&&a++;return a},c=function(e,t){var a,n=[],i=0,s=((t=0<parseInt(t)?parseInt(t):1)-1)*r.page.pageSize,o=t*r.page.pageSize;for(a in r.sysImageList)e==r.sysImageList[a].parentid&&(s<=i&&i<o&&n.push(r.sysImageList[a]),i++);return n}}]),angular.module("wapeditorApp").controller("TextNavCtrl",["$scope",function(t){t.addItem=function(){t.activeItem.params.items.push({title:"",url:""}),t.changeInnerHeight()},t.removeItem=function(e){for(i in index=$.inArray(e,t.activeItem.params.items),items=_.clone(t.activeItem.params.items),t.activeItem.params.items=[],items)i!=index&&t.activeItem.params.items.push(items[i]);t.changeInnerHeight()}}]),angular.module("wapeditorApp").controller("TitleCtrl",["$scope",function(t){t.changeNavEnable=function(e){t.activeItem.params.tradition.nav.enable=e}}]),angular.module("wapeditorApp").controller("WhiteCtrl",["$scope",function(e){}]),angular.module("accountApp",["we7app","infinite-scroll"]),angular.module("accountApp").controller("SystemAccountDisplay",["$scope","$compile","$http","config",function(n,i,s,o){n.lists=[],n.links=o.links,n.showActionStatus=!1,n.checkAllStatus=!1,n.checkNum=0,n.checkItem=function(e){e?n.checkNum++:n.checkNum--,n.checkNum==n.lists.length?n.checkAllStatus=!0:n.checkAllStatus=!1},n.checkAll=function(){for(var e in n.lists)n.lists[e].checked=n.checkAllStatus;n.checkNum=n.checkAllStatus?n.lists.length:0},n.postAction=function(e){var t,a=[];for(t in n.lists)n.lists[t].checked&&a.push(n.lists[t].uniacid);"disabled"==e&&n.receiveAccount(o.links.del,a)},n.receiveAccount=function(e,t,a){util.confirm(function(){s.post(e,{uniacids:t}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,e.redirect,"error")})},function(){},"确认è¦åœç”¨å—?")};var r=o.searchParams;n.getAccountList=function(e,t,a){r.page=t,s.post(o.links.getAccountList,r).success(function(e){0==e.message.errno&&(e=e.message.message,n.lists=e.list,$("#pager").html(i(e.pager)(n)))})},n.getCreateInfo=function(){s.post(o.links.accountCreateInfo).success(function(e){0==e.message.errno&&(n.canCreate=!0,n.createInfo=e.message.message)})},n.getAccountList(),n.getCreateInfo()}]),angular.module("accountApp").controller("SystemAccountRecycle",["$scope","$http","config",function(n,t,a){n.del_accounts=a.del_accounts,n.links=a.links,n.account_types=a.account_types,n.checkAllStatus=!1,n.checkNum=0,n.checkItem=function(e){e?n.checkNum++:n.checkNum--,n.checkNum==n.del_accounts.length?n.checkAllStatus=!0:n.checkAllStatus=!1},n.checkAll=function(){for(var e in n.del_accounts)n.del_accounts[e].checked=n.checkAllStatus;n.checkNum=n.checkAllStatus?n.del_accounts.length:0},n.postAction=function(e){var t,a={uniacids:[]};for(t in n.del_accounts)n.del_accounts[t].checked&&a.uniacids.push(n.del_accounts[t].uniacid);"delete"==e?n.delete(a.uniacids):n.recover(a.uniacids)},n.recover=function(e){t.post(a.links.postRecover,{uniacids:e}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,e.redirect,"error")})},n.delete=function(e){util.confirm(function(){t.post(a.links.postDel,{uniacids:e}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,e.redirect,"error")})},function(){return!1},"æ¤ä¸ºæ°¸ä¹…åˆ é™¤ï¼Œç³»ç»Ÿå°†è‡ªåŠ¨åˆ é™¤è¯¥è´¦å·ä¸‹æ‰€æœ‰ç³»ç»Ÿç›¸å…³ä¿¡æ¯ï¼ˆåŒ…括但ä¸é™äºŽç²‰ä¸ä¿¡æ¯ï¼‰,<br>ç¡®è®¤çŽ°åœ¨åˆ é™¤å—?")}}]),angular.module("accountApp").controller("AccountPostStepOne",["$scope","$http","config",function(e,t,a){e.checkAccountLimit=function(){t.get(a.links.checkAccountLimitUrl).success(function(e){0==e.message.errno?window.location.href=e.message.message.url:util.message(e.message.message,"","error")})}}]),angular.module("accountApp").controller("AccountPostStepTwo",["$scope","config",function(a,e){a.account={},a.uploadMultiImage=function(t){require(["fileUploader"],function(e){e.init(function(e){a.account[t]=e.url,a.$apply(a.account)},{direct:!0,multiple:!1})})},a.delMultiImage=function(e){a.account[e]=""}}]),angular.module("accountApp").controller("AccountPostStepThree",["$scope","$http","config","AccountAppCommon",function(t,e,a,n){t.notify=a.notify,t.owner=a.owner||{},t.owner.groupid=t.owner.groupid||"0",$(".datetimepicker[name = 'endtime']").val(t.owner.endtime||0),t.owner.endtime=0!=t.owner.endtime&&t.owner.endtime?"1":"0",t.links=a.links,t.unigroups=a.unigroups,t.modulesAll={modules:a.modules||[],templates:a.templates||[]},t.groupAll={groups:a.unigroups||[]},t.loadChange=function(){$(".we7-group-show").each(function(){$(this).removeClass("low"),$(this).removeClass("closed"),70<$(this).find(".group-app-list").outerHeight()?($(this).addClass("closed"),$(this).find(".action").off("click").on("click",function(){$(this).parent().toggleClass("closed")})):$(this).addClass("low")})},t.selectOwner=function(e){n.selectOwner(function(e){$(".datetimepicker[name = 'endtime']").val(e.endtime),e.endtime=0==e.endtime?"0":"1",t.owner=Object.assign(t.owner,e),setTimeout(function(){t.$apply(),$("select").niceSelect&&$("select").niceSelect("update"),t.loadChange()})})},t.groupConfirm=function(){setTimeout(function(){t.loadChange()},20)},t.changeGroup=function(){t.owner.package=$("#groupid").find("option:selected").data("package"),n.update_package_list($("#groupid").find("option:selected").data("package")),setTimeout(function(){t.loadChange()})},t.addPermission=n.addPermission}]),angular.module("accountApp").controller("AccountPostStepFour",["$scope","config","AccountAppCommon",function(e,t,a){e.account=t.account,e.links=t.links,e.url=t.links.siteroot+"api.php?id="+e.account.acid,e.success=function(e){var e=parseInt(e),t=$('<span class="label label-success" style="position:absolute;z-index:10"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>');a.copySuccess(e,t)}}]),angular.module("accountApp").controller("AccountManageBase",["$scope","$http","config","AccountAppCommon",function(s,o,r,l){s.account=r.account,s.uniaccount=r.uniaccount,s.authstate=r.authstate,s.authurl=r.authurl,s.founder=r.founder,s.owner=r.owner,s.siteroot=r.links.siteroot.substring(0,r.links.siteroot.length-1),s.other={headimgsrc:r.account.logo,qrcodeimgsrc:r.account.qrcode,serviceUrl:r.links.siteroot+"api.php?id="+s.account.acid,siteurl:s.siteroot,socketurl:s.siteroot.replace(/(https|http)/,"wss"),udpurl:s.siteroot.replace(/(https|http)/,"udp")},s.changeImage=function(t,a){"headimgsrc"!=t&&"qrcodeimgsrc"!=t||require(["fileUploader"],function(e){e.init(function(e){s.other[t]=e.url,s.$apply(s.other),s.httpChange(t)},{direct:!0,multiple:!1,uniacid:a})})},s.success=function(e){var e=parseInt(e),t=$('<a href="javascript:;" class="btn btn-success btn-sm we7-margin-left-sm"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</a>');l.copySuccess(e,t)},s.editInfo=function(e,t){s.middleAccount={},s.middleAccount[e]=t,s.middleAccountCopy={},s.middleAccountCopy[e]=t},s.httpChange=function(t,e){switch(t){case"headimgsrc":case"qrcodeimgsrc":o.post(r.links.basePost,{type:t,request_data:s.other[t]}).success(function(e){0==e.message.errno?($(".wechat-img").attr("src",s.other[t]),util.message("修改æˆåŠŸï¼",e.redirect,"success")):(-1==e.message.errno&&util.message(e.message.message,e.redirect,"error"),1==e.message.errno&&util.message(e.message.message,"","error"),40035==e.message.errno&&util.message(e.message.message,"","error"))});break;case"name":case"account":case"original":case"level":case"appid":case"key":case"secret":case"attachment_limit":if($("#"+t).modal("hide"),0==s.middleAccount[t].length&&"attachment_limit"!=t)return util.message("ä¸å¯ä¸ºç©ºï¼","","error"),!1;o.post(r.links.basePost,{type:t,request_data:s.middleAccount[t]}).success(function(e){0==e.message.errno?(s.account[t]=s.middleAccount[t],util.message("修改æˆåŠŸï¼",e.redirect,"success")):(1==e.message.errno&&util.message(e.message.message,"","error"),40035==e.message.errno&&util.message(e.message.message,"","error"))});break;case"jointype":if($("#jointype").modal("hide"),1!=s.middleAccount.type&&4!=s.middleAccount.type||o.post(r.links.basePost,{type:"jointype",request_data:1}).success(function(e){0==e.message.errno?(s.account[t]=s.middleAccount[t],s.account.type=s.middleAccount.type,util.message("修改æˆåŠŸï¼",e.redirect,"success")):(1==e.message.errno&&util.message(e.message.message,"","error"),40035==e.message.errno&&util.message(e.message.message,"","error"))}),3==s.middleAccount.type||7==s.middleAccount.type)if(1==r.authurl.errno)util.message(r.authurl.url);else{if(!confirm("必须通过公众å·æŽˆæƒç™»å½•é¡µé¢è¿›è¡ŒæŽˆæƒæŽ¥å…¥ï¼Œæ˜¯å¦è·³è½¬è‡³æŽˆæƒé¡µé¢..."))return!1;location.href=r.authurl.url}break;case"token":if($("#token").modal("hide"),void 0===e){if(!confirm("确定è¦ç”Ÿæˆæ–°çš„å—?"))return!1;var a=l.tokenGen()}else{if(0==(a=$("#newtoken").val()).length)return util.message("ä¸å¯ä¸ºç©ºï¼"),!1;if(!new RegExp(/^[A-Za-z0-9]{3,32}$/).test(a))return util.message("必须为英文或者数å—,长度为3到32个å—符ï¼"),!1}o.post(r.links.basePost,{type:t,request_data:a}).success(function(e){0==e.message.errno?(s.account[t]=a,util.message("修改æˆåŠŸï¼",e.redirect,"success")):(-1==e.message.errno&&util.message(e.message.message,e.redirect,"error"),1==e.message.errno&&util.message(e.message.message,"","error"),40035==e.message.errno&&util.message(e.message.message,"","error"))});break;case"encodingaeskey":if($("#encodingaeskey").modal("hide"),void 0===e){if(!confirm("确定è¦ç”Ÿæˆæ–°çš„å—?"))return!1;var n=l.encodingAESKeyGen()}else{if(0==(n=$("#newencodingaeskey").val()).length)return util.message("ä¸å¯ä¸ºç©ºï¼"),!1;if(!new RegExp(/^[A-Za-z0-9]{43}$/).test(n))return util.message("必须为英文或者数å—,长度为43个å—符ï¼"),!1}o.post(r.links.basePost,{type:t,request_data:n}).success(function(e){0==e.message.errno?(s.account[t]=n,util.message("修改æˆåŠŸï¼",e.redirect,"success")):(-1==e.message.errno&&util.message(e.message.message,e.redirect,"error"),1==e.message.errno&&util.message(e.message.message,"","error"),40035==e.message.errno&&util.message(e.message.message,"","error"))});break;case"highest_visit":"number"==typeof s.middleAccount.highest_visit&&o.post(r.links.basePost,{type:t,request_data:s.middleAccount.highest_visit}).success(function(e){0==e.message.errno?(s.account[t]=s.middleAccount.highest_visit,util.message("修改æˆåŠŸï¼",e.redirect,"success")):util.message(e.message.message,"","error")});break;case"endtime":var i=$('[name="endtime"]').val();o.post(r.links.basePost,{type:"endtime",endtype:s.middleAccount.endtype,endtime:i}).success(function(e){1==e.message.errno?util.message(e.message.message,"","info"):(s.account.endtype=s.middleAccount.endtype,s.account.end=2==s.account.endtype?i:"永久",util.message("修改æˆåŠŸï¼",e.redirect,"success"))})}}}]),angular.module("accountApp").controller("AccountMangeModulesTpl",["$scope","$http","config","we7TypeDefault",function(n,i,s,e){for(var t in n.owner=s.owner,n.user_extend_modules=s.user_extend_modules,n.modules_tpl={},n.uni_groups=s.uni_groups,n.packagelist=s.packagelist,n.extend=s.extend,n.allmodule=!1,n.jurindex=0,n.account_type_sign=s.account_type_sign,n.we7TypeDefault=e,n.modules=s.modules,n.templates=s.templates,s.modules_tpl){t=s.modules_tpl[t];n.modules_tpl[t.id]&&"default"==n.modules_tpl[t.id].type||(n.modules_tpl[t.id]=t),"default"==t.type&&n.uni_groups&&n.uni_groups[t.id]&&delete n.uni_groups[t.id]}if(n.extend&&n.extend.groups)for(var a in n.extend.groups){var o=n.extend.groups[a].id;n.uni_groups&&n.uni_groups[o]&&(n.uni_groups[o].checked=1)}for(var a in n.groupList={groups:n.uni_groups||{}},n.modules)n.extend&&n.extend.modules&&n.extend.modules[a]&&(n.modules[a].checked=1),2!=n.modules[a][n.account_type_sign+"_support"]&&delete n.modules[a];if(n.moduleList={modules:n.modules},"account"==n.account_type_sign){if(n.extend&&n.extend.modules)for(var a in n.extend.templates){var r,o=n.extend.templates[a].id;for(r in n.templates)o==n.templates[r].id&&(n.templates[r].checked=1)}n.moduleList.templates=n.templates}n.changeGroup=function(){var e,t=[];for(e in n.groupList.groups)1==n.groupList.groups[e].checked&&t.push(n.groupList.groups[e].id);i.post(s.links.postModulesTpl,{type:"group",groupdata:t}).success(function(e){0==e.message.errno?location.reload():util.message(e.message.message)})},n.addExtend=function(){var e,t=[],a=[];for(e in n.moduleList.modules)1==n.moduleList.modules[e].checked&&t.push(n.moduleList.modules[e].name);for(e in n.moduleList.templates)1==n.moduleList.templates[e].checked&&a.push(n.moduleList.templates[e].id);i.post(s.links.postModulesTpl,{type:"extend",module:t,tpl:a}).success(function(e){0==e.message.errno?location.reload():util.message(e.message.message)})},n.editEndTime=function(e,t){n.middleTime=e,n.middleGoodsId=parseInt(t),$("#endtime").modal("show"),$('input[name="endtime"]').val(e)},n.httpChange=function(){var e=$('input[name="endtime"]').val();i.post(s.links.postModulesTpl,{type:"store_endtime",new_time:e,order_id:n.middleGoodsId}).success(function(e){0==e.message.errno&&util.message(e.message.message,e.redirect)})}}]),angular.module("accountApp").controller("AccountManageUsers",["$scope","$http","config",function(i,a,n){i.vice_founder=n.vice_founder,i.owner=n.owner,i.manager=n.manager,i.operator=n.operator,i.state=n.state,i.setPermission=function(e){e=parseInt(e);location.href=n.links.setPermission+"&uid="+e},i.delPermission=function(e){e=parseInt(e);a.post(n.links.delete,{uid:e}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})},i.addOwner=function(){$("#owner-modal").modal("hide");var e=$.trim($("#add-owner-username").val());i.requestPost(3,e)},i.changeOwner=function(e){$("#owner-modal").modal("show"),$("#add-owner-username").val(e)},i.changeVice=function(e){$("#user-modal").modal("show"),$("#addtype-4").prop("checked",!0),$("#add-username").val(e)},i.addUsername=function(){$("#user-modal").modal("hide");var a=$.trim($("#add-username").val()),n=$(".addtype");$.each(n,function(e,t){$(n[e]).is(":checked")&&i.requestPost($(n[e]).val(),a)})},i.requestPost=function(e,t){if(!t)return util.message("请输入用户å."),!1;e=parseInt(e);a.post(n.links.addUser,{username:t,addtype:e,account_type:n.accountType,token:n.token}).success(function(e){0==e.message.errno?location.reload():(-1==e.message.errno&&util.message(e.message.message),1==e.message.errno&&util.message("æ·»åŠ å¤±è´¥ï¼Œè¯·ç¨å€™é‡è¯•ï¼"),2==e.message.errno&&util.message(e.message.message),3==e.message.errno&&util.message("ç”¨æˆ·æœªé€šè¿‡å®¡æ ¸ï¼Œè¯·è”系网站管ç†å‘˜å®¡æ ¸é€šè¿‡åŽå†è¡Œæ·»åŠ ï¼"),4==e.message.errno&&util.message("管ç†å‘˜ä¸å¯æ“作其他管ç†å‘˜ï¼"),5!=e.message.errno&&6!=e.message.errno||util.message(e.message.message))})}}]),angular.module("accountApp").controller("SystemPlatform",["$scope","$http","config","AccountAppCommon",function(l,c,u,d){l.platform=u.platform,l.url=u.url,l.success=function(e){var e=parseInt(e),t=$('<span class="label label-success" style="btn btn-success we7-margin-left-sm"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>');d.copySuccess(e,t)},l.httpChange=function(e,t){switch(e){case"authstate":var a=1==l.platform.authstate?0:1;c.post(u.links.platformPost,{authstate:a}).success(function(e){0==e.message.errno?(l.platform.authstate=a,util.message("修改æˆåŠŸï¼","","success")):1==e.message.errno&&util.message("修改失败,请ç¨åŽé‡è¯•ï¼")});break;case"bindappid":$("#bindappid").modal("hide");var n=$("#newbindappid").val();c.post(u.links.platformPost,{bindappid:n}).success(function(e){0==e.message.errno?(l.platform.bindappid=n,util.message("修改æˆåŠŸï¼","","success")):1==e.message.errno&&util.message("修改失败,请ç¨åŽé‡è¯•ï¼","","error")});break;case"appid":$("#AppID").modal("hide");var i=$("#newappid").val();c.post(u.links.platformPost,{appid:i}).success(function(e){0==e.message.errno?(l.platform.appid=i,util.message("修改æˆåŠŸï¼","","success")):1==e.message.errno&&util.message("修改失败,请ç¨åŽé‡è¯•ï¼","","error")});break;case"appsecret":$("#AppSecret").modal("hide");var s=$("#newappsecret").val();c.post(u.links.platformPost,{appsecret:s}).success(function(e){0==e.message.errno?(l.platform.appsecret=s,util.message("修改æˆåŠŸï¼","","success")):1==e.message.errno&&util.message("修改失败,请ç¨åŽé‡è¯•ï¼","error")});break;case"token":if(void 0===t){if(!confirm("确定è¦ç”Ÿæˆæ–°çš„å—?"))return!1;var o=d.tokenGen()}else{if(0==(o=$("#newtoken").val()).length)return util.message("ä¸å¯ä¸ºç©ºï¼"),!1;if(!new RegExp(/^[A-Za-z0-9]{3,32}$/).test(o))return util.message("必须为英文或者数å—,长度为3到32个å—符ï¼"),!1}c.post(u.links.platformPost,{token:o}).success(function(e){0==e.message.errno?(l.platform.token=o,util.message("修改æˆåŠŸï¼","","success")):1==e.message.errno&&util.message("修改失败,请ç¨åŽé‡è¯•ï¼")});break;case"encodingaeskey":if(void 0===t){if(!confirm("确定è¦ç”Ÿæˆæ–°çš„å—?"))return!1;var r=d.encodingAESKeyGen()}else{if(0==(r=$("#newencodingaeskey").val()).length)return util.message("ä¸å¯ä¸ºç©ºï¼"),!1;if(!new RegExp(/^[A-Za-z0-9]{43}$/).test(r))return util.message("必须为英文或者数å—,长度为43个å—符ï¼"),!1}c.post(u.links.platformPost,{encodingaeskey:r}).success(function(e){0==e.message.errno?(l.platform.encodingaeskey=r,util.message("修改æˆåŠŸï¼","","success")):1==e.message.errno&&util.message("修改失败,请ç¨åŽé‡è¯•ï¼")})}}}]),angular.module("accountApp").controller("AccountManageWxappCtrl",["$scope","$http","config",function(a,e,t){a.wxapp_modules=t.wxapp_modules,a.current_module_info=t.current_module_info,a.showWxModules=function(){$("#module_wxapp").modal("show")},a.selectedWxModule=function(e,t){t=$(t.target).parents(".select-module-wxapp");t.find("span").removeClass("hide"),t.siblings().find("span").addClass("hide"),a.newWxModule=e},a.addWxModules=function(){e.post(t.links.editmodule,{module:a.newWxModule,account_type:4}).success(function(e){$("#module_wxapp").modal("hide"),0==e.message.errno?location.reload():util.message(e.message.message)})},a.delWxModule=function(){e.post(t.links.delmodule,{module:a.current_module_info,account_type:4}).success(function(e){0==e.message.errno?location.reload():util.message(e.message.message)})}}]),angular.module("accountApp").controller("SystemAccountExpiredMessageCtrl",["$scope","$http","config",function(e,n,i){e.account_types=i.account_types,e.saveSetting=function(e,t,a){status=null==a?0:a.status,n.post(i.links.saveSettingUrl,{account_type:t,message:e.value,status:status}).success(function(e){0==e.message.errno&&util.message("修改æˆåŠŸï¼",e.redirect,"success")})},e.saveSettingSwitch=function(e,t,a){if(null==a||null==a.message)return util.message("请先填写到期æ示内容!","","error"),!1;status=0==a.status||null==a.status?1:0,n.post(i.links.saveSettingUrl,{account_type:t,message:a.message,status:status}).success(function(e){0==e.message.errno&&util.message("修改æˆåŠŸï¼",e.redirect,"success")})}}]),angular.module("accountApp").controller("commonCreateAccountCtrl",["$scope","config","$http","AccountAppCommon",function(a,e,n,t){a.account={sign:e.sign},a.step="base_info",a.submitBaseinfo=function(){if(!a.account.name)return util.message(e.sign_title+"å称ä¸èƒ½ä¸ºç©º"),!1;e.isfounder?a.checkParamsGoToNext("account_modules"):-1!=["account","webapp"].indexOf(e.sign)?a.submitAndRedirect():a.checkParamsGoToNext("account_version")},a.submitAccountModules=function(){a.account.owner_uid=a.owner.uid||e.uid,a.account.endtime=$(".datetimepicker[name = 'endtime']").val(),a.account.groups=[],a.account.modules=[],a.account.templates=[],angular.forEach(a.groupAll.groups,function(e){e.checked&&a.account.groups.push(e.id)}),angular.forEach(a.modulesAll.modules,function(e){e.checked&&a.account.modules.push(e.name)}),angular.forEach(a.modulesAll.templates,function(e){e.checked&&a.account.templates.push(e.id)}),-1!=["account","webapp"].indexOf(e.sign)?a.submitAndRedirect():a.checkParamsGoToNext("account_version")},a.submitAccountVersion=function(){a.submitAndRedirect()},a.checkParamsGoToNext=function(t){a.account.step=a.step,n.post(e.links.check_params,a.account).success(function(e){return 0!=e.message.errno?(util.message(e.message.message,"","error"),!1):void(a.step=t)})},a.submitAndRedirect=function(){a.account.step="",a.account.owner_uid=a.owner.uid,n.post(e.links.save_account,a.account).success(function(e){return 0!=e.message.errno?(util.message(e.message.message,"","error"),!1):void(location.href=e.redirect)})},a.uploadMultiImage=function(t){require(["fileUploader"],function(e){e.init(function(e){a.account[t]=e.url,a.$apply(a.account)},{direct:!0,multiple:!1,uniacid:0})})},a.delMultiImage=function(e){a.account[e]=""},a.owner={},a.owner.groupid=0,a.owner.endtime="0",$(".datetimepicker[name = 'endtime']").val(0),a.modulesAll={modules:e.modules||[]},a.loadGroups=function(){n.post(e.links.load_groups).success(function(e){0==e.message.errno&&(a.groupAll={groups:e.message.message||[]})})},a.loadChange=function(){$(".we7-group-show").each(function(){$(this).removeClass("low"),$(this).removeClass("closed"),70<$(this).find(".group-app-list").outerHeight()?($(this).addClass("closed"),$(this).find(".action").off("click").on("click",function(){$(this).parent().toggleClass("closed")})):$(this).addClass("low")})},a.selectOwner=function(e){t.selectOwner(function(e){$(".datetimepicker[name = 'endtime']").val(e.endtime),e.endtime=0==e.endtime?"0":"1",a.owner=Object.assign(a.owner,e),setTimeout(function(){a.$apply(),$("select").niceSelect&&$("select").niceSelect("update"),a.loadChange()})})},a.groupConfirm=function(){setTimeout(function(){a.loadChange()},20)},a.changeGroup=function(){a.owner.package=$("#groupid").find("option:selected").data("package"),t.update_package_list($("#groupid").find("option:selected").data("package")),setTimeout(function(){a.loadChange()})},a.resourceModule=function(){require(["fileUploader"],function(e){e.show(function(e){a.version_module=e,a.account.version_module=e.name,a.$apply(a.version_module)},{direct:!0,multiple:a.isMuti,isWechat:!1,type:"module",others:{user_module:1,uid:a.account.owner_uid,module_uniacid:0,mtype:a.account.sign,cover:"account"==a.account.sign}})})}}]),angular.module("accountApp").service("AccountAppCommon",["$rootScope","$http","config",function(e,n,s){var o={addPermission:function(){var e="",t="";$("#jurisdiction-add #content-modules").find(".btn-primary").each(function(){e+='<span class="label label-info" style="margin-right:3px;">'+$(this).attr("data-title")+'</span><input type="hidden" name="extra[modules][]" value="'+$(this).attr("data-name")+'" />'}),$("#jurisdiction-add #content-templates").find(".btn-primary").each(function(){t+='<span class="label label-info" style="margin-right:3px;">'+$(this).attr("data-title")+'</span><input type="hidden" name="extra[templates][]" value="'+$(this).attr("data-name")+'" />'}),e||t?$(".account-package-extra").show():$(".account-package-extra").hide(),$(".account-package-extra .js-extra-modules").html(e),$(".account-package-extra .js-extra-templates").html(t),$("#jurisdiction-add").modal("hide")},update_package_list:function(e){for(i in $('input[name="package[]"]').prop("checked",!1),$('input[name="package[]"]').prop("disabled",!1),e)$('input[name="package[]"][value="'+e[i]+'"]').prop("checked",!0),$('input[name="package[]"][value="'+e[i]+'"]').prop("disabled",!0)},selectOwner:function(t){var a=[];require(["biz"],function(e){e.user.browser(a,function(e){n.post(s.links.userinfo,{uid:e}).success(function(e){e.message.errno&&util.message(e.message.message),setTimeout(function(){$("#manager").val(e.message.message.uid).trigger("change"),$("#showname").val(e.message.message.username).trigger("change"),$("#groupid").val(e.message.message.group.id||0).trigger("change"),$("#groupid").niceSelect&&$("#groupid").niceSelect("update")},1),$(".account-package-extra").show(),o.update_package_list(e.message.message.package),t&&"function"==typeof t&&t(e.message.message)})},{mode:"invisible",direct:!0})})},copySuccess:function(e,t){var e=parseInt(e),t=t,a=$("#copy-"+e).next().html();(!a||a.indexOf('<span class="label label-success" style="position:absolute;z-index:10"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>')<0)&&$("#copy-"+e).after(t),setTimeout(function(){t.remove()},2e3)},tokenGen:function(){for(var e="",t=0;t<32;t++)e+="abcdefghijklmnopqrstuvwxyz0123456789"[parseInt(32*Math.random())];return e},encodingAESKeyGen:function(){for(var e="",t=0;t<43;t++)e+="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"[parseInt(61*Math.random()+1)];return e}};return o}]),angular.module("we7codeAppjsonApp",["we7app"]),angular.module("we7codeAppjsonApp").controller("code_appjson_ctrl",["$scope","$q","config","$http",function(n,e,i,s){var t=i.default_appjson,a=i.save_url,o=i.default_url,r=i.convert_img_url,l=(t=(t=angular.isString(t)?JSON.parse(t):t)||{pages:{},windows:{}}).hasOwnProperty("tabBar")?t.tabBar:{list:[]};l&&!l.list&&(l.list=[]),l&&!l.isSystemTabBar&&(l.isSystemTabBar=1),t&&t.windows&&t.windows.navigationBarTitleText&&t.windows.navigationBarTitleText.indexOf("微擎")&&(t.windows.navigationBarTitleText="å°ç¨‹åº"),n.pages=t.pages,n.window=t.window,n.tabBar=l,$("body").on("click",".js-image",function(){var t=$(this).data("index"),a="0"==$(this).data("selected")?"iconPath":"selectedIconPath";util.image({},function(e){s.post(r,{version_id:i.version_id,att_id:e.id}).then(function(e){0==e.data.message.errno&&(n.tabBar.list[t][a]=e.data.message.message)})})}),n.toJson=function(){return{pages:n.pages,window:n.window,tabBar:n.tabBar}},n.iconPath=function(e){return e.iconPath},n.save=function(e){var t=n.toJson();s.post(a,{json:t,version_id:i.version_id}).then(function(e){0==e.data.message.errno?util.message(e.data.message.message,e.data.redirect,"success"):util.message(e.data.message.message,"","error")})},n.add=function(){n.tabBar.list.push({iconSelectedPath:"",iconPath:"",pagePath:n.pages[0],text:""})},n.del=function(e){n.tabBar.list.splice(e,1)},n.default=function(){s.post(o,{version_id:i.version_id}).then(function(e){0==e.data.message.errno?util.message(e.data.message.message,e.data.redirect,"success"):util.message(e.data.message.message,"","error")})},util.colorpicker(".js-color",function(){})}]),angular.module("articleApp",["we7app"]),angular.module("articleApp").controller("commentsCtr",["$scope","$compile","config","$http",function(a,n,e,i){a.do=e.do,a.changePage=function(e,t){i.get(e+"&page="+t).success(function(e){a.comment_list=e.message.message.list,a.pager=e.message.message.pager,(!a.comment_list||a.comment_list.length<1)&&$(".js-list").html("æš‚æ— è¯„è®º"),$(".js-pager").html(n(a.pager)(a))})},a.changePage(e.get_comments_url,1),a.likeComment=function(t){if("comments"==a.do)return!1;i.post(e.like_comment_url,t).success(function(e){return 0!=e.message.errno?(util.message(e.message.message),!1):void(t.like_num=+t.like_num+1)})},a.replyarticle=function(e){e.replying=!0},a.cancel=function(e){e.replying=!1},a.send=function(t){i.post(e.reply_url,t).success(function(e){return 0!=e.message.errno?(util.message(e.message.message),!1):(t.replys.push(e.message.message),t.replying=!1,void(t.replycontent=""))})}}]),angular.module("articleApp").controller("articleCategoryCtrl",["$scope","config","$http",function(t,a,e){t.categorys=a.categorys,t.current_category={},t.editCategory=function(e){t.current_category=e,$("#editCateform").modal("show")},t.saveCategory=function(){if(t.current_category.token=a.token,t.current_category.submit=1,!t.current_category.title)return util.message("分类å称ä¸èƒ½ä¸ºç©º","","error"),!1;e.post(a.edit_url,t.current_category).success(function(e){0==e.message.errno?($("#editCateform").modal("hide"),util.message(e.message.message,e.redirect,"success")):util.message(e.message.message,"","error")})},t.deleteCategory=function(e){util.confirm(function(){window.location.href=a.delete_url+"&id="+e},function(){return!1},"ç¡®è®¤åˆ é™¤å—?")}}]),angular.module("replyFormApp",["we7app"]),angular.module("replyFormApp").controller("KeywordReply",["$scope","$http","config",function(n,t,o){n.reply={advanceTrigger:!1,status:!0,showAdvance:!1,keyword:{exact:"",indistinct:"",contain:"",regexp:""},entry:o.replydata},n.reply.entry?(n.reply.entry.istop=255<=n.reply.entry.displayorder?1:0,n.reply.status=1==n.reply.entry.status,n.reply.entry.keywords||(n.reply.entry.keywords=[])):n.reply.entry={istop:0,displayorder:"",id:"",keywords:[],module:"",name:"",status:1,uniacid:o.uniacid},n.changeStatus=function(){n.reply.status=!n.reply.status},n.changeKeywordType=function(e){e=parseInt(e);n.newKeyword={type:e,content:""},$("#keyword-indistinct").next().text(""),$("#keyword-exact").next().text(""),$("#keyword-regexp").next().text("")},n.showAddkeywordModal=function(){$("#addkeywordModal").modal("show"),n.newKeyword={type:1,content:""}},n.addNewKeyword=function(){t.post("./index.php?c=platform&a=reply&do=post",{keyword:n.newKeyword.content}).success(function(e){if(-2==e.message.errno)return util.message(e.message.message),!1;if(0==e.message.errno){$("#addkeywordModal").modal("hide");var t=parseInt(n.newKeyword.type);switch(t){case 1:case 2:var a=n.newKeyword.content.replace(/,/g,",").split(",");angular.forEach(a,function(e){""!=e&&n.reply.entry.keywords.push({type:t,content:e})});break;case 3:n.reply.entry.keywords.push(n.newKeyword)}}})},n.delKeyword=function(e){e=_.findIndex(n.reply.entry.keywords,e);n.reply.entry.keywords=_.without(n.reply.entry.keywords,n.reply.entry.keywords[e])},n.changeTriggerType=function(){"exact"==n.reply.advanceTrigger&&(n.reply.advanceTrigger=!1),"indistinct"==n.reply.advanceTrigger&&(n.reply.advanceTrigger=!0)},n.changeShowAdvance=function(){n.reply.showAdvance=!n.reply.showAdvance},$.isFunction(window.initReplyController)&&window.initReplyController(n,t),n.submitForm=function(){var e=angular.toJson(n.reply.entry.keywords);if($(':hidden[name="keywords"]').val(e),$.isFunction(window.validateReplyForm)){if(!window.validateReplyForm($("#reply-form"),$,_,util,n,t))return!1;$(".reply-form-submit").click()}else $(".reply-form-submit").click()},n.initEmotion=function(e){util.emotion($("#emoji-exact"),$("#keyword-exact"),function(e,t,a){n.newKeyword.content+=e,n.$apply(n.newKeyword)}),util.emotion($("#emoji-indistinct"),$("#keyword-indistinct"),function(e,t,a){n.newKeyword.content+=e,n.$apply(n.newKeyword)})},n.checkKeyWord=function(e){var s=$(e.target),e=s.val().trim();if(""==e)return s.next().text(""),!1;t.post("./index.php?c=platform&a=reply&do=post",{keyword:e}).success(function(e){if(0!=e.message.errno){if(-2==e.message.errno)return s.next().html(e.message.message),!1;var t,a=$('input[name="rid"]').val(),n=e.message.message,i="";for(rule in n)a!=n[rule].id&&(t=n[rule].name||n[rule].id,i+="<a href='"+o.links.postUrl+"&rid="+n[rule].id+"' target='_blank'><strong class='text-danger'>"+t+"</strong></a> ");""!=i&&s.next().html("该关键å—å·²å˜åœ¨äºŽ "+i+" 规则ä¸.")}else s.next().text("")})}}]),angular.module("replyFormApp").controller("ApplyReply",["$scope",function(t){t.alphabet=["A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"],t.activeLetter="",t.searchModule=function(e){t.activeLetter=e}}]),angular.module("replyFormApp").controller("KeywordDisplay",["$scope","$http","config",function(e,n,t){e.keywordType="",e.keywordType=t.type,e.changeType=function(){window.location.href=t.replyUrl+"&type="+e.keywordType},e.changeStatus=function(t){var a=$("#key-"+t).attr("class");n.post("./index.php?c=platform&a=reply&do=change_keyword_status",{id:t}).success(function(e){0==e.message.errno?(a.match("switchOn")?$("#key-"+t).removeClass("switchOn"):$("#key-"+t).addClass("switchOn"),util.message("修改æˆåŠŸï¼","","success")):util.message("网络错误,请ç¨å€™é‡è¯•")}).error(function(e){util.message("网络错误,请ç¨å€™é‡è¯•")})}}]),angular.module("replyFormApp").controller("serviceDisplay",["$scope","config","$http",function(a,e,n){a.changeStatusUrl=e.url,a.service=e.service,a.changeStatus=function(t){t=file=t;n.post(a.changeStatusUrl,{rid:t,file:file,module_name:"service"}).success(function(e){0==e.message.errno?(a.service[t].switch=""==a.service[t].switch?"checked":"",location.reload()):util.message("网络错误,请ç¨å€™é‡è¯•")})}}]),angular.module("replyFormApp").controller("SpecialDisplay",["$scope","config","$http",function(a,e,n){a.config=e,a.url=e.url,a.msgtypes={image:a.config.image,voice:a.config.voice,video:a.config.video,shortvideo:a.config.shortvideo,location:a.config.location,trace:a.config.trace,link:a.config.link,merchant_order:a.config.merchant_order,ShakearoundUserShake:a.config.ShakearoundUserShake,ShakearoundLotteryBind:a.config.ShakearoundLotteryBind,WifiConnected:a.config.WifiConnected,qr:a.config.qr},a.switch_class=new Array,angular.forEach(a.msgtypes,function(e,t){a.switch_class[t]="module"==e||"keyword"==e?"switch switchOn special_switch":"switch special_switch"}),a.changestatus=function(t){n.post(a.url,{type:t}).success(function(e){0==e.message.errno?(a.switch_class[t]="switch switchOn special_switch"==a.switch_class[t]?"switch special_switch":"switch switchOn special_switch",location.reload()):util.message(e.message.message)})}}]),angular.module("replyFormApp").controller("PostCtrl",["$scope","config","$http",function(a,e,t){require(["underscore","util"],function(e,t){window.initReplyController(a)}),a.switch_class=e.class,a.status="module"==e.status||"keyword"==e.status?e.status:"",a.change=function(e,t){a.status=0==t?1:0,a.switch_class=1==a.status?"switch switchOn special_switch":"switch special_switch"}}]),angular.module("replyFormApp").controller("WelcomeDisplay",["$scope",function(e){$.isFunction(window.initReplyController)&&window.initReplyController(e)}]),angular.module("replyFormApp").controller("DefaultDisplay",["$scope",function(e){$.isFunction(window.initReplyController)&&window.initReplyController(e)}]),angular.module("replyFormApp").directive("ngInvoker",["$parse",function(e){return function(e,t,a){e.$eval(a.ngInvoker)}}]),angular.module("replyFormApp").directive("ngMyEditor",function(){var n={scope:{value:"=ngMyValue"},template:'<textarea id="editor" style="height:600px;width:100%;"></textarea>',link:function(e,t,a){t.data("editor")||(n=UE.getEditor("editor",{autoClearinitialContent:!1,toolbars:[["fullscreen","source","preview","|","bold","italic","underline","strikethrough","forecolor","backcolor","|","justifyleft","justifycenter","justifyright","|","insertorderedlist","insertunorderedlist","blockquote","emotion","link","removeformat","|","rowspacingtop","rowspacingbottom","lineheight","indent","paragraph","fontfamily","fontsize","|","inserttable","deletetable","insertparagraphbeforetable","insertrow","deleterow","insertcol","deletecol","mergecells","mergeright","mergedown","splittocells","splittorows","splittocols","|","horizontal","anchor","map","print","drafts"]],elementPathEnabled:!1,initialFrameHeight:200,focus:!1,maximumWords:9999999999999,autoFloatEnabled:!1}),t.data("editor",n),n.addListener("contentChange",function(){e.value=n.getContent().replace(/\"\;/g,'"'),e.$root.$$phase||e.$apply("value")}),$(t).parents("form").submit(function(){n.queryCommandState("source")&&n.execCommand("source")}),n.addListener("ready",function(){n&&n.getContent()!=e.value&&n.setContent(e.value),e.$watch("value",function(e){n&&n.getContent()!=e&&n.setContent(e||"")})}))}};return n}),angular.module("replyFormApp").filter("nl2br",["$sce",function(t){return function(e){return e?t.trustAsHtml(e.replace(/\n/g,"<br/>")):""}}]),angular.module("cloudApp",["we7app"]),angular.module("cloudApp").controller("CloudDiagnoseCtrl",["$scope","$http","config",function(e,t,a){$(".js-checkip p").each(function(){var t=$(this);$.getJSON("./index.php?c=cloud&a=diagnose&do=testapi&ip="+t.find("#serverdnsip").html(),function(e){t.find("#checkresult").html(e.message.message)})}),$.ajax({type:"get",url:a.apiurl+"&jsonpcallback=?",dataType:"jsonp",success:function(e){"0"==e.check_time.errno?$("#check-time").html('<i class="fa fa-check text-success"></i> æ£å¸¸'):$("#check-time").html('<i class="fa fa-remove text-warning"></i> 异常,当å‰æ—¶é—´ä¸ºï¼š'+e.check_time.message.localtime+"; æœåŠ¡å™¨æ—¶é—´ä¸ºï¼š"+e.check_time.message.servertime),"0"==e.check_touch.errno?$("#check-touch").html('<i class="fa fa-check text-success"></i> æ£å¸¸'):$("#check-touch").html('<i class="fa fa-remove text-warning"></i> 异常,'+e.check_touch.message)},error:function(){}})}]),angular.module("we7codeuploadApp",["we7app"]),angular.module("we7codeuploadApp").controller("code_upload_ctrl",["$scope","config","codeservice","$q","$http",function(a,t,n,i,s){a.qrcode_src="",a.preview_qrcode="",a.show_wait=!1,a.support_plugins=!0,a.plugins=[],a.step=1,a.show_step1=!0,a.show_step2=!1,a.show_step3=!1,a.wait_sec=15,a.user_desc="",a.user_version=t.user_version,a.uploadType="",a.uuid="",a.ticket="";var e=15,o=setInterval(function(){--e<=0&&(e=0,clearInterval(o)),a.$apply(function(){a.wait_sec=e})},1e3);a.beforeUpload=function(e,t){a.uploadType=t||"",e?$("#beforeUpload").modal():a.beginUpload(0)},a.beginUpload=function(e){return a.support_plugins=e,$("input:checkbox[name=plugins]:not(:checked)").each(function(e){a.plugins.push($(this).val())}),a.user_version&&/^[0-9]{1,2}\.[0-9]{1,2}(\.[0-9]{1,2})?$/.test(a.user_version)?a.user_desc&&0!=a.user_desc?void r(e):(util.message("版本æè¿°ä¸èƒ½ä¸ºç©º"),!1):(util.message("版本å·é”™è¯¯ï¼Œåªèƒ½æ˜¯æ•°å—ã€ç‚¹ï¼Œæ•°å—最多2ä½ï¼Œä¾‹å¦‚ 1.1.1 或1.2"),!1)};var r=function(e){n.codeuid(t.version_id,a.user_version,e).then(function(e){console.log(e),a.uuid=e.uuid,a.show_wait=!1,a.show_step1=!1,a.qrcode_src=e.qrcode_url;e=i.defer();return e.resolve(a.uuid),e.promise}).then(function(){return a.show_wait=!1,a.step=2,a.show_step2=!0,n.checkscan(a.uuid)}).then(function(e){console.log(e),a.ticket=e,a.commit()},function(e){console.log(e),util.message(e)})};a.preview=function(){n.publish(t.version_id,a.ticket,a.user_version,a.user_desc,a.plugins,1).then(function(e){a.preview_qrcode="data:image/jpg;base64,"+e,$("#qrCodeModal").modal("show")},function(e){util.message(e)})},a.commit=function(){if(!a.user_version||!/^[0-9]{1,2}\.[0-9]{1,2}(\.[0-9]{1,2})?$/.test(a.user_version))return util.message("版本å·é”™è¯¯ï¼Œåªèƒ½æ˜¯æ•°å—ã€ç‚¹ï¼Œæ•°å—最多2ä½ï¼Œä¾‹å¦‚ 1.1.1 或1.2"),!1;n.publish(t.version_id,a.ticket,a.user_version,a.user_desc,a.plugins,0).then(function(){s.post(t.upgrade_url,{version_id:t.version_id,version:a.user_version,description:a.user_desc}).success(function(e){return e.message&&0==e.message.errno?void(a.uploadType?s.post(t.VERSIONURL,{version_id:t.version_id,commit_type:a.uploadType}).success(function(e){0==e.message.errno?(a.step=3,a.show_step2=!1,a.show_step3=!0):util.message(e.message.message)}):(a.step=3,a.show_step2=!1,a.show_step3=!0)):(util.message(e.message.message),!1)})},function(e){util.message(e)})}}]),angular.module("we7codeuploadApp").service("codeservice",["$http","$q","config",function(n,r,l){return{ajax:function(e,t,a){return n({url:e,method:t||"get",data:a}).then(function(e){var t=e.data&&e.data.message?e.data.message:e.data,e=r.defer();return e.resolve(t),e.promise},function(){var e=r.defer();return e.reject(),e.promise})},codeuid:function(e,t,a){var n=r.defer(),a=l.UUIDURL+"version_id="+e+"&user_version="+t+"&support_live="+(a?1:0);return this.ajax(a,"get").then(function(e){var t;"0"!=e.errno?(t="å°ç¨‹åºåº”用数æ®å¼‚å¸¸ï¼Œæ— æ³•èŽ·å–,请è”系开å‘者",e.message&&(t=e.message),n.reject(t)):n.resolve(e.message)}),n.promise},checkscan:function(t,a){a=a||r.defer();var n=this,e=l.CHECKSANURL+"&uuid="+t;return this.ajax(e,"post",{uuid:t}).then(function(e){0==e.errno&&e.message&&e.message.ticket?a.resolve(e.message.ticket):n.checkscan(t,a)},function(e){a.reject(e.message?e.message.message:"出错了")}),a.promise},publish:function(e,t,a,n,i,s){var o=r.defer(),i=l.PUBLISHURL+"&version_id="+e+"&ticket="+t+"&user_version="+a+"&user_desc="+n+"&support_live="+i+"&commit_type="+s;return this.ajax(i,"post").then(function(e){var t;"0"==e.errno&&(t=e.message.qrcode_img||"",o.resolve(t));e=e.message;o.reject(e=""==e?(1==s?"预览失败":"ä¸Šä¼ ä»£ç 失败")+", ç¡®ä¿å½“å‰æ‰«ç ç”¨æˆ·æœ‰ä¸Šä¼ å°ç¨‹åºçš„æƒé™":e)}),o.promise}}}]),angular.module("fansApp",["we7app"]).value("config",{running:!1,syncState:"",downloadState:""}).controller("DisplayCtrl",["$scope","$http","config","$q",function(n,i,s,a){n.config=s,n.addTagUrl=s.addTagUrl,n.tag="",n.searchMod=s.searchMod,n.closeValue=0,n.registerUrl=s.registerUrl,n.register=[],n.sync_member=0,n.switchSearchMod=function(e){n.searchMod=e,n.$apply(n.searchMod)},n.addTag=function(){i.post(n.addTagUrl,{tag:n.tag}).success(function(e){})},n.registerMember=function(e){n.register.openid=e,n.register.password="",n.register.repassword=""},n.register=function(){return $(".modal").modal("hide"),""==n.register.password?(util.message("新密ç ä¸å¯ä¸ºç©ºï¼"),!1):""==n.register.repassword?(util.message("确认新密ç ä¸å¯ä¸ºç©ºï¼"),!1):n.register.password!=n.register.repassword?(util.message("两次密ç ä¸ä¸€è‡´ï¼"),!1):void i.post(n.registerUrl,{password:n.register.password,repassword:n.register.repassword,openid:n.register.openid}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"ajax"):util.message(e.message.message)})},n.syncMember=function(){i.get(s.syncMember+"&sync_member="+n.sync_member).success(function(e){0==e.message.errno?($("#sync-setting").modal("hide"),n.sync_member=1==e.message.message?1:0):(n.sync_member=0,util.message("设置失败, 请é‡è¯•!"))})},n.downloadFans=function(e,a){var t=new RegExp("(^| )we7:sync_fans_pindex:"+window.sysinfo.uniacid+"=([^;]*)(;|$)");if(t=document.cookie.match(t))return n.sync("all",{pageindex:unescape(t[2])}),!1;a=a||0,null==e&&(e="",util.message("æ£åœ¨ä¸‹è½½ç²‰ä¸æ•°æ®...")),i.post(s.syncAllUrl,{next_openid:e}).success(function(e){if(0!=e.message.errno){var t="";return"string"==typeof e.message?t=e.message:"string"==typeof e.message.message&&(t=e.message.message),util.message("粉ä¸ä¸‹è½½å¤±è´¥ã€‚å…·ä½“åŽŸå› ï¼š"+t),!1}if(a+=parseInt(e.message.message.count),e.message.message.total<=a||!e.message.message.count&&!e.message.message.next)return n.sync("all"),!1;n.downloadFans(e.message.message.next,a)})},n.sync=function(e,t){if("all"==e)t||(t={pageindex:0,total:0},util.message("粉ä¸æ•°æ®ä¸‹è½½å®Œæˆã€‚开始更新粉ä¸æ•°æ®...","","success")),t.type="all",t.sync_member=n.sync_member;else{if(t={type:"check",openids:[],sync_member:n.sync_member},$(".openid:checked").each(function(){t.openids.push(this.value)}),0==t.openids.length)return util.message("请选择粉ä¸","","info"),!1;util.message("æ£åœ¨åŒæ¥ç²‰ä¸æ•°æ®è¯·ä¸è¦å…³é—æµè§ˆå™¨...")}0<t.pageindex&&0==n.closeValue&&($("#modal-message").modal("hide"),util.dialog("更新进度",'<div class="progress"> <div class="progress-bar progress-bar-info" role="progressbar" aria-valuenow="'+t.pageindex/t.total*100+'" aria-valuemin="0" aria-valuemax="100" style="width: '+t.pageindex/t.total*100+'%"><span class="sr-only"></span></div></div>',"",{containerName:"link-container"}).modal("show")),$(".close").click(function(){n.closeValue=1});e=a.defer();e.promise.then(function(){i.post(n.config.syncUrl,t).success(function(e){if(null==e.message)return util.message("更新失败ï¼å¯èƒ½æ˜¯ç”±äºŽä½ 当å‰ç½‘络ä¸ç¨³å®šï¼Œè¯·ç¨åŽå†è¯•ã€‚","","info"),!1;if(0==e.message.errno){if("success"==e.message.message||e.message.message.total==e.message.message.pageindex)return util.message("åŒæ¥ç²‰ä¸æ•°æ®æˆåŠŸ",s.msgUrl,"success"),!1;n.sync("all",{pageindex:e.message.message.pageindex,total:e.message.message.total})}else{if(++t.pageindex>t)return util.message("åŒæ¥ç²‰ä¸æ•°æ®æˆåŠŸ",s.msgUrl,"success"),!1;n.sync("all",{pageindex:++t.pageindex,total:t.total})}})},function(e){}),1==n.closeValue?n.closeValue=0:e.resolve()}}]).controller("chatsCtrl",["$scope","$http","config",function(t,e,a){send=function(){for(type in types=[],types.text=$('[name="reply[reply_basic]"]').val(),types.news=$('[name="reply[reply_news]"]').val(),types.image=$('[name="reply[reply_image]"]').val(),types.music=$('[name="reply[reply_music]"]').val(),types.voice=$('[name="reply[reply_voice]"]').val(),types.video=$('[name="reply[reply_video]"]').val(),types.wxcard=$('[name="reply[reply_wxcard]"]').val(),types)if(msg_type=type,msg_content=types[type],""!=msg_content)break;if(!msg_content)return!1;$.post(a.sendurl,{type:msg_type,content:msg_content},function(e){-1==(e=$.parseJSON(e)).message.errno?util.message(e.message.message,"","info"):($(".keywords-list li").remove(),$('[name="reply[reply_basic]"]').val(""),$('[name="reply[reply_news]"]').val(""),$('[name="reply[reply_image]"]').val(""),$('[name="reply[reply_music]"]').val(""),$('[name="reply[reply_voice]"]').val(""),$('[name="reply[reply_video]"]').val(""),$('[name="reply[reply_wxcard]"]').val(""),t.chatLogs.unshift({flag:1,createtime:e.message.message.createtime,content:e.message.message.content,msgtype:e.message.message.msgtype}),t.$apply())})},t.chatLogs=a.chatLogs,window.onbeforeunload=function(){$.get(a.endurl,{},function(e){})}}]),angular.module("homeApp",["we7app"]),angular.module("homeApp").controller("WelcomeCtrl",["$scope","$http","config",function(n,e,t){n.notices=t.notices,n.loaderror=0,n.last_modules=null,n.fans_kpi=[],e({method:"POST",url:"./index.php?c=home&a=welcome&do=get_fans_kpi"}).success(function(e){0==e.message.errno&&(n.fans_kpi=e.message.message)}),n.buildAccountModules=function(){e.post("./index.php?c=home&a=welcome&do=build_account_modules")},n.buildAccountModules(),"v"==t.family&&(n.recommend={recommend:{name:"推è应用",list:[],ads:[],icon:"recommend"},"new-app":{name:"新应用",list:[],ads:[],icon:"new"},essential:{name:"下载排行",list:[],ads:[],icon:"down"},hot:{name:"çƒé—¨æŽ’è¡Œ",list:[],ads:[],icon:"hot"},large:{name:"大é¢åº”用排行",list:[],ads:[],icon:"big"}},require(),require(),require(),n.changeTab=function(a){a&&n.recommend[a].list.length<=0&&(n.showLoading=!0,require())})}]),angular.module("homeApp").controller("systemWelcomeCtrl",["$scope","$http","config","$compile",function(n,a,i,e){n.tuijianshow=!0,n.closeTuijian=function(){n.tuijianshow=!1},n.is_empty_accounts=i.is_empty_accounts,n.is_empty_modules=i.is_empty_modules,n.account_list=[],"v"==i.family&&(n.recommend={recommend:{name:"推è应用",list:[],ads:[],icon:"recommend"},"new-app":{name:"新应用",list:[],ads:[],icon:"new"},essential:{name:"下载排行",list:[],ads:[],icon:"down"},hot:{name:"çƒé—¨æŽ’è¡Œ",list:[],ads:[],icon:"hot"},large:{name:"大é¢åº”用排行",list:[],ads:[],icon:"big"}},require(),require(),require(),n.changeTab=function(a){a&&n.recommend[a].list.length<=0&&(n.showLoading=!0,require())}),n.loaderror=0,n.ads=null,n.account_num=i.account_num,n.last_accounts=i.last_accounts,n.last_modules=i.last_modules,n.message_list=i.message_list,n.links=i.links,n.user_info=i.user_info,n.account_types=i.account_types,n.system_notice_show=!0,n.module_show=!0,n.modules=i.user_modules,n.moduleList={modules:i.own_account_modules_all},n.account_list=[],n.getAccountList=function(){a.post(i.links.getAccountListUrl).success(function(e){angular.forEach(e.message.message,function(e){"owner"==e.user_role&&n.account_list.push(e)})})},n.getAccountList(),n.commonModuleSwitch=function(e){e.default_uniacid?window.location.href=e.module.switchurl+"&uniacid="+e.default_uniacid:window.location.href=e.module.switchurl+"&uniacid="+e.uniacid},n.showAccounts=function(e){a.post(i.links.moduleAccounts,{module_name:e}).success(function(e){n.module_accounts=e.message.message})},n.system_notice=function(){n.system_notice_show=!n.system_notice_show,n.we7_notice_show=!1},n.we7_notice=function(){n.we7_notice_show=!n.we7_notice_show,n.system_notice_show=!1},n.addCommonModule=function(){n.selected_modules=[],angular.forEach(n.moduleList.modules,function(e){1==e.checked&&n.selected_modules.push({module_name:e.module_name,uniacid:e.uniacid})}),a.post(i.links.addWelcomeShortcutUrl,{shortcuts:n.selected_modules}).success(function(e){location.reload()})},n.selectCommonAccount=function(){n.selected_accounts=[],angular.forEach(n.account_list,function(e){1==e.checked&&n.selected_accounts.push({uniacid:e.uniacid})}),a.post(i.links.addWelcomeShortcutUrl,{shortcuts:n.selected_accounts}).success(function(e){location.reload()})},n.remoteCommonModule=function(e,t){a.post(i.links.removeWelcomeShortcutUrl,{module_name:e,uniacid:t}).success(function(e){location.reload()})},n.removeCommonAccount=function(e){a.post(i.links.removeWelcomeShortcutUrl,{uniacid:e}).success(function(e){location.reload()})},n.setDefault=function(e,t){a.post(i.links.setDefaultUrl,{module_name:e,uniacid:t}).success(function(e){location.reload()})},n.setTop=function(e){a.post(n.links.setTop,{id:e}).success(function(e){0==e.message.errno&&location.reload()})},n.redirect_urls=i.redirect_urls,n.user_welcome_link={},angular.forEach(i.redirect_urls,function(e){e.id==i.user_info.welcome_link&&(n.user_welcome_link=e)}),n.saveSetting=function(e,t){n.user_info.welcome_link=e.value.id,n.user_welcome_link=e.value,a.post(i.links.userPost,{type:"welcome_link",welcome_link:n.user_info.welcome_link,uid:n.user_info.uid}).success(function(e){return 0!=e.message.errno?(util.message(e.message.message),!1):void util.toast("修改æˆåŠŸï¼","success")})}}]),angular.module("we7job",["we7app"]),angular.module("we7job").controller("we7job-base-controller",["$scope","$http","config",function(a,e,t){var n,i,s=t.list,t=t.jobid,o=new Worker("resource/js/app/job.js?"+Math.random());a.list=s,n=document.location.toString().split("//"),i=n[1].indexOf("/"),-1!=(i=n[1].substring(i)).indexOf("?")&&(i=i.split("?")[0]),a.relUrl=i,a.start=function(e){e.relUrl=a.relUrl,e.start=!e.start,o.postMessage(e)},o.onmessage=function(e){var t=e.data.id;a.list[t].progress=e.data.progress,a.$apply()},0<t&&((t=s[t])&&a.start(t))}]),angular.module("massApp",["we7app"]),angular.module(["massApp"]).controller("MassSend",["$scope","$http","config",function(e,a,n){e.showLog=function(e){var e=parseInt(e),t=$("#"+e);a.post(n.logUrl,{tid:e,type:"mass",module:"task"}).success(function(e){e=angular.toJson(e);var a="";e.message&&0!=e.message.items.length?$.each(e.message.items,function(e,t){a+="<tr><td>"+t.createtime+" "+t.note+"</td></tr>"}):a='<tr><td class="text-center"><i class="fa fa-info-circle"></i> æš‚æ— æ•°æ®</td></tr>',t.popover({html:!0,placement:"left",trigger:"manual",title:"触å‘日志",content:'<table class="table-cron table">'+a+"</table>"}),t.popover("toggle")})},e.hideLog=function(e){e=parseInt(e);$("#"+e).popover("toggle")}}]),angular.module("massApp").controller("MassPost",["$scope","config",function($scope,config){$scope.groups=config.groups,$scope.massdata=config.massdata||{groupname:"-1",type:"0"},setTimeout(function(){$("select").niceSelect&&$("select").niceSelect("update")}),$scope.clock=config.massdata?config.massdata.clock:"08:00",$.isFunction(window.initReplyController)&&window.initReplyController($scope),$scope.checkSubmit=function(e){var selectedGroup=$(".mass-group").val(),group_fans_all;if(""==selectedGroup)return e.preventDefault(),util.message("请选择群å‘对象"),!1;if(-1==selectedGroup?(group_fans_all={id:-1,name:"全部粉ä¸",count:0},$(':hidden[name="group"]').val(angular.toJson(group_fans_all))):angular.forEach($scope.groups,function(e,t){e.id==selectedGroup&&$(':hidden[name="group"]').val(angular.toJson(e))}),""==$scope.clock)return e.preventDefault(),util.message("请选择群å‘具体时间"),!1;if("0"==config.day){var selectedTime=$scope.clock.split(":"),d=new Date,hours=d.getHours(),minutes=d.getMinutes();if(selectedTime[0]<hours||selectedTime[0]==hours&&selectedTime[1]<minutes)return e.preventDefault(),util.message("å‘é€æ—¶é—´ä¸èƒ½å°äºŽå½“å‰æ—¶é—´"),!1}var reply_news=$(':hidden[name="reply[reply_news]"]').val(),reply_image=$(':hidden[name="reply[reply_image]"]').val(),reply_music=$(':hidden[name="reply[reply_music]"]').val(),reply_voice=$(':hidden[name="reply[reply_voice]"]').val(),reply_video=$(':hidden[name="reply[reply_video]"]').val(),reply_basic=$(':hidden[name="reply[reply_basic]"]').val();if(""==reply_news&&""==reply_image&&""==reply_music&&""==reply_voice&&""==reply_video&&""==reply_basic)return e.preventDefault(),util.message("请选择群å‘ç´ æ"),!1;if(""!=reply_news){if(reply_news=eval("("+reply_news+")"),"perm"!=reply_news.model)return e.preventDefault(),util.message("群å‘ä¸æ”¯æŒæœ¬åœ°/æœåŠ¡å™¨ç´ æï¼Œè¯·é€‰æ‹©å¾®ä¿¡ç´ æ"),!1;$(':hidden[name="reply[reply_news]"]').val(reply_news.mediaid)}""!=reply_image&&(reply_image=eval("("+reply_image+")"),$(':hidden[name="reply[reply_image]"]').val(reply_image)),""!=reply_music&&(reply_music=eval("("+reply_music+")"),$(':hidden[name="reply[reply_music]"]').val(reply_music)),""!=reply_voice&&(reply_voice=eval("("+reply_voice+")"),$(':hidden[name="reply[reply_voice]"]').val(reply_voice)),""!=reply_video&&(reply_video=eval("("+reply_video+")"),$(':hidden[name="reply[reply_video]"]').val(reply_video.mediaid))},$(".clockpicker").clockpicker({autoclose:!0})}]),angular.module("materialApp",["we7app"]),angular.module("materialApp").directive("ngMyEditor",function(){return{scope:{value:"=ngMyValue",imguploadurl:"@ngMyUpurl"},template:'<textarea id="editor" style="height:600px;width:100%;"></textarea>',link:function(a,n,e){n.data("editor")||util.editor("editor",{allow_upload_video:0,hideVideo:!0,hideVoice:!0,callback:function(e,t){n.data("editor",t),t.addListener("contentChange",function(){a.value=t.getContent(),a.$root.$$phase||a.$apply("value")}),t.addListener("ready",function(){t&&t.getContent()!=a.value&&t.setContent(a.value),a.$watch("value",function(e){t&&t.getContent()!=e&&t.setContent(e||"")})})}},!0)}}}).controller("materialDisplay",["$scope","$http","config",function(s,o,r){s.materialList=r.materialList,s.groups=r.group,s.config=r,s.group="",s.materialType="",s.materialId="",s.syncNews=r.syncNews,s.hidenbutton=0,s.typeName=r.typeName,s.sync=function(t,e,a,n,i){$(window).bind("beforeunload",function(){return"您输入的内容尚未ä¿å˜ï¼Œç¡®å®šç¦»å¼€æ¤é¡µé¢å—?"}),s.utilMessage?null==e?s.utilMessage.find(".content").text("æ£åœ¨åŒæ¥ç´ æ,请勿关é—æµè§ˆå™¨..."):s.utilMessage.find(".content").text("å·²åŒæ¥"+parseInt((e-1)/a*100)+"%,请勿关é—æµè§ˆå™¨..."):s.utilMessage=null==e?util.message("æ£åœ¨åŒæ¥ç´ æ,请勿关é—æµè§ˆå™¨..."):util.message("å·²åŒæ¥"+parseInt((e-1)/a*100)+"%,请勿关é—æµè§ˆå™¨..."),o.post(r.sync_url,{type:t,pageindex:e,total:a,wechat_existid:n,original_newsid:i}).success(function(e){0==e.message.errno?($(window).unbind("beforeunload"),s.utilMessage.find(".content").text("åŒæ¥ç´ ææˆåŠŸ, å³å°†åˆ·æ–°é¡µé¢"),window.location.href="./index.php?c=platform&a=material&type="+t):(sync_info=e.message.message,s.sync(sync_info.type,sync_info.pageindex,sync_info.total,sync_info.wechat_existid,sync_info.original_newsid))})},1==s.syncNews&&s.sync("news"),s.upload=function(t,a,n){require(["fileUploader"],function(e){e.init(function(){util.message("ä¸Šä¼ æˆåŠŸ",location.href,"success")},{type:t,direct:!0,multiple:a,isWechat:n,showType:n?1:2,needType:n?1:2,typeName:s.typeName})})},s.del_material=function(t,e,a){util.confirm(function(){o.post(r.del_url,{material_id:e,type:t,server:a}).success(function(e){0!=e.message.errno?util.message("åˆ é™¤å¤±è´¥,å…·ä½“åŽŸå› :"+e.message.message,"","info"):util.message("åˆ é™¤æˆåŠŸ","./index.php?c=platform&a=material&type="+t+("local"==a?"&islocal=true":""),"success")})},function(){return!1},"ç¡®è®¤åˆ é™¤å—?")},s.checkGroup=function(e,t){$("select").niceSelect&&$("select").niceSelect("update"),setTimeout(function(){$("#check-group").modal("show")}),s.materialType=e,s.materialId=t,s.group=""},s.transToWechat=function(t,e){util.message("ç´ æ转æ¢å°†åœ¨åŽå°è¿è¡Œï¼ŒæˆåŠŸåŽåŽè‡ªåŠ¨åˆ·æ–°é¡µé¢ï¼Œè¯·å‹¿å…³é—æµè§ˆå™¨..."),o.post(r.trans_url,{material_id:e}).success(function(e){0!=e.message.errno?util.message("转æ¢å¤±è´¥,å…·ä½“åŽŸå› :"+e.message.message,"","info"):s.sync(t)})},s.newsToWechat=function(e){util.message("ç´ æ转æ¢å°†åœ¨åŽå°è¿è¡Œï¼ŒæˆåŠŸåŽåŽè‡ªåŠ¨åˆ·æ–°é¡µé¢ï¼Œè¯·å‹¿å…³é—æµè§ˆå™¨..."),o.post(s.config.postwechat_url,{material_id:e}).success(function(e){0==e.message.errno?util.message("å·²ä¿å˜","./index.php?c=platform&a=material","success"):alert("创建图文失败"+e.message.message)})},s.sendMaterial=function(){o.post(s.config.send_url,{type:s.materialType,id:s.materialId,group:s.group}).success(function(e){1==e.message.errno?util.message(e.message.message,"","info"):util.message("群å‘æˆåŠŸ","./index.php?c=platform&a=material&type="+s.materialType,"success")})},s.createNew=function(e){e=s.config.create_new_url+"&new_type="+e;window.location=e},s.choiceSendType=function(e,t,a){$(".web-mobile-choice-type a[class = 'we7-margin-bottom']").attr("data-url",e),$(".web-mobile-choice-type a[class = 'we7-mobile-material-preview']").attr("data-type",t),$(".web-mobile-choice-type a[class = 'we7-mobile-material-preview']").attr("data-media-id",a),$(".material-wechat-view").removeClass("hidden"),$("#weixin-dialog").addClass("hidden"),"news"!=t&&($("#weixin-dialog").addClass("hidden"),s.mobilePreview())},s.wabPreview=function(){$("#modalWechatView").modal("hide"),window.open($(".web-mobile-choice-type a[class = 'we7-margin-bottom']").attr("data-url"),"_blank")},s.mobilePreview=function(){var t=$(".web-mobile-choice-type a[class = 'we7-mobile-material-preview']").attr("data-media-id"),a=$(".web-mobile-choice-type a[class = 'we7-mobile-material-preview']").attr("data-type");$(".material-wechat-view").addClass("hidden"),$("#weixin-dialog").removeClass("hidden"),$("#modalWechatView .btn-send").unbind().click(function(){var e=$.trim($("#modalWechatView #wxname").val());return e?($("#weixin-dialog").addClass("hidden"),$(".material-wechat-view").removeClass("hidden"),$("#modalWechatView #wxname").val(""),$("#modalWechatView").modal("hide"),o.post("./index.php?c=platform&a=mass&do=preview",{media_id:t,wxname:e,type:a}).success(function(e){0!=e.message.errno?util.message(e.message.message):util.message("å‘é€æˆåŠŸ","","success")})):util.message("微信å·ä¸èƒ½ä¸ºç©º","","error"),!1})},s.previewBack=function(){$("#weixin-dialog").addClass("hidden"),$(".material-wechat-view").removeClass("hidden")}}]).controller("materialAdd",["$scope","material","$http","$timeout",function(s,a,t,e){s.config=a,s.operate=a.operate,s.model=a.model,s.new_type=a.new_type,s.hidenbutton="reply"==a.new_type?0:1,s.typeName=a.typeName,s.changeClass=function(){angular.forEach(s.materialList,function(e,t){s.materialList[t].class="0"==t?s.activeIndex==t?"cover-appmsg-item active":"cover-appmsg-item":s.activeIndex==t?"appmsg-item active":"appmsg-item"})},s.tomedia=function(e){var t="";return $.ajax({url:a.url,async:!1,data:{url:e},success:function(e){e=$.parseJSON(e);t=e.message.message}}),t},s.changeOrder=function(e,t){a={},"down"==e?(a=s.materialList[t],s.materialList[t]=s.materialList[t+1],s.materialList[t+1]=a):(a=s.materialList[t],s.materialList[t]=s.materialList[t-1],s.materialList[t-1]=a)},s.deleteMaterial=function(e){confirm("确定è¦åˆ 除å—?")&&(s.materialList.splice(e,1),s.activeIndex=s.activeIndex-1)},s.changeIndex=function(e){s.activeIndex=e,s.changeClass()},s.addMaterial=function(){null==s.materialList?(s.materialList=[],s.activeIndex=0):s.activeIndex=s.materialList.length,s.materialList.push({id:"",title:"",author:"",thumb:"",media_id:"",displayorder:"0",digest:"",content:"",content_source_url:"",show_cover_pic:0,class:""}),s.changeClass()},"add"==s.operate&&"reply"!=s.config.type?s.addMaterial():(s.activeIndex=0,s.materialList=[],angular.forEach(a.materialList,function(e,t){e.thumb_url=s.tomedia(e.thumb_url),s.materialList[t]={id:e.id,title:e.title,author:e.author,thumb:e.thumb_url,media_id:e.thumb_media_id,displayorder:t,digest:e.digest,content:e.content,content_source_url:e.content_source_url,url:e.url,show_cover_pic:isNaN(Number(e.show_cover_pic))?0:Number(e.show_cover_pic),class:""}}),s.changeClass()),s.pickPicture=function(e){isWechat="wechat"==e,require(["fileUploader"],function(e){e.init(function(e){s.materialList[s.activeIndex].thumb=e.url,s.materialList[s.activeIndex].media_id=e.media_id,s.$apply()},{type:"image",direct:!0,multiple:!1,isWechat:isWechat,typeName:s.typeName,image_limit:s.config.image_limit,voice_limit:s.config.voice_limit,video_limit:s.config.video_limit})})},s.updateSelection=function(){s.materialList[s.activeIndex].show_cover_pic=isNaN(Number(!s.materialList[s.activeIndex].show_cover_pic))?0:Number(!s.materialList[s.activeIndex].show_cover_pic)},s.saveNews=function(a){news=[];var n="",i="";if(angular.forEach(s.materialList,function(e,t){""==e.title?(n=t,i="è¯·è¾“å…¥æ ‡é¢˜åŽ,å†ç‚¹å‡»ä¿å˜æŒ‰é’®"):""!=e.content||"wechat"!=a&&"reply"!=s.new_type?""==e.content&&"wechat"==a?(n=t,i="图文内容ä¸å›¾ç‰‡ä¸Šä¼ 失败,请é‡æ–°ä¸Šä¼ "):(e.displayorder=t+1,news[t]=e):(n=t,i="请输入一段æ£æ–‡,å†ç‚¹å‡»ä¿å˜æŒ‰é’®")}),""!==n)return s.activeIndex=n,s.changeClass(),alert(i),!1;util.message("æ£åœ¨ç”Ÿæˆå›¾æ–‡æ¶ˆæ¯ï¼Œè¯·å‹¿å…³é—æµè§ˆå™¨...");var e="add"==s.config.operate?"":s.config.materialList[0].attach_id;t.post(s.config.newsUpload_url,{news:news,operate:s.operate,attach_id:e,type:s.config.type,target:a,news_rid:s.config.news_rid}).success(function(e){0==e.message.errno?util.message("å·²ä¿å˜",s.config.msg_url,"success"):alert("创建图文失败"+e.message.message)})},s.exportFromCms=function(){s.searchCms()},s.searchCms=function(e){var i={header:'<ul role="tablist" class="nav nav-pills" style="font-size:14px; margin-top:-20px;">\t<li role="presentation" class="active" id="li_goodslist"><a data-toggle="tab" role="tab" aria-controls="articlelist" href="#articlelist">æ–‡ç« åˆ—è¡¨</a></li></ul>',content:'<div class="tab-content"><div id="articlelist" class="tab-pane active" role="tabpanel">\t<table class="table table-hover">\t\t<thead class="navbar-inner">\t\t\t<tr>\t\t\t\t<th style="width:40%;">æ ‡é¢˜</th>\t\t\t\t<th style="width:30%">创建时间</th>\t\t\t\t<th style="width:30%; text-align:right">\t\t\t\t\t<div class="input-group input-group-sm hide">\t\t\t\t\t\t<input type="text" class="form-control">\t\t\t\t\t\t<span class="input-group-btn">\t\t\t\t\t\t\t<button class="btn btn-default" type="button"><i class="fa fa-search"></i></button>\t\t\t\t\t\t</span>\t\t\t\t\t</div>\t\t\t\t</th>\t\t\t</tr>\t\t</thead>\t\t<tbody></tbody>\t</table>\t<div id="pager" style="text-align:center;"></div></div></div>',footer:"",articleitem:'<%_.each(list, function(item) {%> \n<tr>\n\t<td><a href="#" data-cover-attachment-url="<%=item.attachment%>" title="<%=item.title%>"><%=item.title%></a></td>\n\t<td><%=item.createtime%></td>\n\t<td class="text-right">\n\t\t<button class="btn btn-default js-btn-select" js-id="<%=item.id%>">选å–</button>\n\t</td>\n</tr>\n<%});%>\n'};$("#link-search-cms")[0]?s.modalobj=$("#link-search-cms").data("modal"):(s.modalobj=util.dialog(i.header,i.content,i.footer,{containerName:"link-search-cms"}),s.modalobj.find(".modal-body").css({height:"680px","overflow-y":"auto"}),s.modalobj.modal("show"),s.modalobj.on("hidden.bs.modal",function(){s.modalobj.remove()}),$("#link-search-cms").data("modal",s.modalobj)),t.get("./index.php?c=utility&a=link&do=articlelist&page="+(e=e||1)).success(function(e,t,a,n){e.message.message.list&&(s.modalobj.find("#articlelist").data("articles",e.message.message.list),s.modalobj.find("#articlelist tbody").html(_.template(i.articleitem)(e.message.message)),s.modalobj.find("#pager").html(e.message.message.pager),s.modalobj.find("#pager .pagination li[class!='active'] a").click(function(){return s.searchCms($(this).attr("page")),!1}),s.modalobj.find(".js-btn-select").click(function(){s.addCms($(this).attr("js-id")),s.$apply(),s.modalobj.modal("hide")}))})},s.addCms=function(e){e=s.modalobj.find("#articlelist").data("articles")[e];s.materialList[s.activeIndex].title=e.title,s.materialList[s.activeIndex].thumb=e.thumb_url,s.materialList[s.activeIndex].author=e.author,s.materialList[s.activeIndex].incontent=1==e.incontent,s.materialList[s.activeIndex].description=e.description,s.materialList[s.activeIndex].content=e.content,s.materialList[s.activeIndex].content_source_url=e.linkurl,s.materialList[s.activeIndex].detail=""!=e.content}}]),angular.module("memberAPP",["we7app"]),angular.module("memberAPP").controller("group",["$scope","$http","config",function(a,n,e){a.config=e,a.group_level=a.config.group_level,a.group_person_count=a.config.group_person_count,a.group_list=a.config.group_list,a.default_group=a.config.default_group,a.set_group_detail_info=function(e){a.group_detail={},n.post(a.config.get_group_url,{group_id:e}).success(function(e){1==e.message.errno?util.message(e.message.message,"","error"):a.group_detail=e.message.message}),$("#group_detail").modal("show")},a.change_group_level=function(){$("#modal-change-group").modal("hide"),n.post(a.config.change_group_level_url,{group_level:a.group_level}).success(function(e){0==e.message.errno?util.modal_message("","设置æˆåŠŸ","","success"):util.message("设置失败","","error")})},a.save_group=function(){if(""==a.group_detail.title)return util.message("请填写会员组å称","","error"),!1;n.post(a.config.save_group_url,{group:a.group_detail}).success(function(e){1==e.message.errno&&util.message(e.message.message,"","error"),2==e.message.errno&&($("#group_detail").modal("hide"),a.group_list[a.group_detail.groupid]=a.group_detail,util.message(e.message.message,"","success")),3==e.message.errno&&(groupid=e.message.message.groupid,a.group_list[groupid]=e.message.message,$("#group_detail").modal("hide"),util.message("æ·»åŠ æˆåŠŸ","","success"))})},a.set_default=function(t){n.post(a.config.set_default_url,{group_id:t}).success(function(e){0==e.message.errno?(a.group_list[t].isdefault=1,a.group_list[a.default_group.groupid].isdefault=0,a.default_group=a.group_list[t],a.apply(a),util.message("设置æˆåŠŸ","","success")):util.message("设置失败","","error")})},a.del_group=function(t){if(!confirm("确定è¦åˆ 除å—?"))return!1;n.post(a.config.del_group_url,{group_id:t}).success(function(e){0==e.message.errno?(delete a.group_list[t],util.message("åˆ é™¤æˆåŠŸ","","success")):util.message("åˆ é™¤å¤±è´¥","","error")})}}]),angular.module("memberAPP").controller("baseInformation",["$scope","$http","config",function(u,d,p){u.config=p,u.profile=u.config.profile,u.groups=u.config.groups,u.addresses=u.config.addresses,u.custom_fields=u.config.custom_fields,u.all_fields=u.config.all_fields,u.uniacid_fields=u.config.uniacid_fields,u.sexes=[{id:0,name:"ä¿å¯†"},{id:1,name:"ç”·"},{id:2,name:"女"}],u.educations=["åšå£«","硕士","本科","专科","ä¸å¦","å°å¦","其它"],u.constellations=["水瓶座","åŒé±¼åº§","白羊座","金牛座","åŒå座","巨蟹座","ç‹®å座","处女座","天秤座","天èŽåº§","射手座","摩羯座"],u.zodiacs=["é¼ ","牛","虎","å…”","é¾™","蛇","马","羊","猴","鸡","ç‹—","猪"],u.bloodtypes=["A","B","AB","O","其它"],u.profile.births=u.profile.birthyear+"-"+u.profile.birthmonth+"-"+u.profile.birthday,u.profile.resides=u.profile.resideprovince+u.profile.residecity+u.profile.residedist,u.other_field_name="",u.other_field_title="",u.addAddress={name:"",phone:"",code:"",province:"",city:"",district:"",detail:""},u.editAddress={},u.uid=u.config.uid,angular.forEach(u.addresses,function(e,t){e.pcda=e.province+"-"+e.city+"-"+e.district+"-"+e.address}),u.addAdd=function(){u.addAddress.province=$(".tpl-province").eq(2).val(),u.addAddress.city=$(".tpl-city").eq(2).val(),u.addAddress.district=$(".tpl-district").eq(2).val(),$("#address-add").modal("hide"),d.post(p.links.addAddressUrl,u.addAddress).success(function(e){var t;0==e.message.errno?((t=e.message.message).pcda=t.province+"-"+t.city+"-"+t.district+"-"+t.address,u.addresses.push(t),util.message("收货地å€æ·»åŠ æˆåŠŸ","","success")):1==e.message.errno&&util.message(e.message.message,"","error")})},u.choseEditAdd=function(a){angular.forEach(u.addresses,function(e,t){e.id==a&&(u.editAddress={id:a,name:e.username,phone:e.mobile,code:e.zipcode,province:e.province,city:e.city,district:e.district,detail:e.address,uniacid:e.uniacid},$(".tpl-province").eq(2).attr("data-value",u.editAddress.province),$(".tpl-city").eq(2).attr("data-value",u.editAddress.city),$(".tpl-district").eq(2).attr("data-value",u.editAddress.district),require(["district"],function(a){$(".tpl-district-container").each(function(){var e={};e.province=$(this).find(".tpl-province")[0],e.city=$(this).find(".tpl-city")[0],e.district=$(this).find(".tpl-district")[0];var t={};t.province=$(e.province).attr("data-value"),t.city=$(e.city).attr("data-value"),t.district=$(e.district).attr("data-value"),a.render(e,t,{withTitle:!0})})}))})},u.editAdd=function(e){u.editAddress.province=$(".tpl-province").eq(4).val(),u.editAddress.city=$(".tpl-city").eq(4).val(),u.editAddress.district=$(".tpl-district").eq(4).val(),$("#address-edit").modal("hide"),d.post(p.links.editAddressUrl,u.editAddress).success(function(e){var a;0==e.message.errno?((a=e.message.message).pcda=a.province+"-"+a.city+"-"+a.district+"-"+a.address,angular.forEach(u.addresses,function(e,t){a.id==e.id&&(e.pcda=a.pcda)}),util.message("收货地å€ä¿®æ”¹æˆåŠŸ","","success")):1==data.message.errno&&util.message(e.message.message,"","error")})},u.delAdd=function(a){d.post(p.links.delAddressUrl,{id:a}).success(function(e){0==e.message.errno?(angular.forEach(u.addresses,function(e,t){a==e.id&&u.addresses.splice(t,1)}),util.message("收货地å€åˆ 除æˆåŠŸ","","success")):1==data.message.errno&&util.message(e.message.message,"","error")})},u.setDefaultAdd=function(a){d.post(p.links.setDefaultAddressUrl,{id:a,uid:u.uid}).success(function(e){0==e.message.errno?(angular.forEach(u.addresses,function(e,t){a==e.id?e.isdefault=1:e.isdefault=0}),util.message("设置æˆåŠŸ","","success")):util.message("设置失败","","success")})},u.changeImage=function(t){"avatar"==t&&require(["fileUploader"],function(e){e.init(function(e){u.profile.avatar=e.attachment,u.profile.avatarUrl=e.url,u.$apply(u.profile),u.httpChange(t)},{direct:!0,multiple:!1})})},u.editInfo=function(e,t){u.userOriginal={},"other_field"==e?(u.userOriginal[t]=u.profile[t],u.other_field_name=u.all_fields[t],u.other_field_title=t):u.userOriginal[e]=t},u.httpChange=function(t,e){switch(t){case"avatar":d.post(p.links.basePost,{type:t,imgsrc:u.profile.avatar}).success(function(e){0==e.message.errno?util.message("修改æˆåŠŸï¼","","success"):(-1==e.message.errno&&util.message(e.message.message,e.redirect,"error"),1==e.message.errno&&util.message(e.message.message,"","error"))});break;case"groupid":case"gender":case"education":case"nickname":case"realname":case"address":case"mobile":case"qq":case"email":case"telephone":case"msn":case"taobao":case"alipay":case"graduateschool":case"grade":case"studentid":case"revenue":case"position":case"occupation":case"company":case"nationality":case"height":case"weight":case"idcard":case"zipcode":case"site":case"affectivestatus":case"lookingfor":case"bio":case"interest":case"constellation":case"zodiac":case"bloodtype":if($("#"+t).modal("hide"),""==u.userOriginal[t])return util.message("ä¸å¯ä¸ºç©ºï¼","","error"),!1;if("mobile"==t)if(!/^\d{11}$/.test(u.userOriginal[t]))return util.message("手机å·æ ¼å¼é”™è¯¯","","error"),!1;d.post(p.links.basePost,{type:t,request_data:u.userOriginal[t]}).success(function(e){0==e.message.errno?(u.profile[t]=u.userOriginal[t],util.message("修改æˆåŠŸï¼","","success")):(-1==e.message.errno&&util.message(e.message.message,e.redirect,"error"),1==e.message.errno&&util.message(e.message.message,"","error"))});break;case"other_field":if($("#"+t).modal("hide"),""==u.userOriginal[u.other_field_title])return util.message("ä¸å¯ä¸ºç©ºï¼","","error"),!1;d.post(p.links.basePost,{type:u.other_field_title,request_data:u.userOriginal[u.other_field_title]}).success(function(e){0==e.message.errno?(u.profile[u.other_field_title]=u.userOriginal[u.other_field_title],util.message("修改æˆåŠŸï¼","","success")):(-1==e.message.errno&&util.message(e.message.message,e.redirect,"error"),1==e.message.errno&&util.message(e.message.message,"","error"))});break;case"births":$(".modal").modal("hide");var a=$(".tpl-year").val(),n=$(".tpl-month").val(),i=$(".tpl-day").val();d.post(p.links.basePost,{type:t,birthyear:a,birthmonth:n,birthday:i}).success(function(e){0==e.message.errno?(u.profile.births=a+"-"+n+"-"+i,util.message("修改æˆåŠŸï¼","","success")):(-1==e.message.errno&&util.message(e.message.message,e.redirect,"error"),1==e.message.errno&&util.message(e.message.message,"","error"))});break;case"resides":$(".modal").modal("hide");var s=$(".tpl-province").eq(0).val(),o=$(".tpl-city").eq(0).val(),r=$(".tpl-district").eq(0).val();d.post(p.links.basePost,{type:t,resideprovince:s,residecity:o,residedist:r}).success(function(e){0==e.message.errno?(u.profile.resides=s+o+r,util.message("修改æˆåŠŸï¼","","success")):(-1==e.message.errno&&util.message(e.message.message,e.redirect,"error"),1==e.message.errno&&util.message(e.message.message,"","error"))});break;case"password":$(".modal").modal("hide");var l=$(".new-password").val(),c=$(".renew-password").val();if(""==l)return util.message("新密ç ä¸å¯ä¸ºç©ºï¼"),!1;if(""==c)return util.message("确认新密ç ä¸å¯ä¸ºç©ºï¼"),!1;if(l!=c)return util.message("两次密ç ä¸ä¸€è‡´ï¼"),!1;d.post(p.links.basePost,{type:t,password:l}).success(function(e){0==e.message.errno?util.message("密ç 修改æˆåŠŸï¼","","success"):(-1==e.message.errno&&util.message(e.message.message,e.redirect,"error"),1==e.message.errno&&util.message(e.message.message,"","error"))})}}}]),angular.module("menuApp",["we7app"]),angular.module("menuApp").controller("menuStatus",["$scope","config","$http",function(e,t,a){e.setMenu=function(e){a.post(t.set_menu_url,{status:e=1==e?0:1}).success(function(e){0==e.message.errno?util.message(e.message.message,window.location.href):util.message(e.message.message,window.location.href,"error")})}}]),angular.module("menuApp").controller("menuDisplay",["$scope","config","$http",function(e,n,i){e.changeStatus=function(e,t,a){t=1==t?2:1,3==a&&(1==t?$(".js-switch-"+e).addClass("switchOn"):2==t&&$(".js-switch-"+e).removeClass("switchOn")),i.post(n.push_url,{id:e}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect):3==a?util.message(e.message.message,"error"):util.message(e.message.message,e.redirect,"error")})}}]),angular.module("menuApp").controller("conditionMenuDesigner",["$scope","config","$http",function(s,a,n){current_menu_url=a.current_menu_url,require(["underscore","jquery.ui","jquery.caret","district-wechat"],function(e,a,a,n){a(".tpl-district-container").each(function(){var e={};e.province=a(this).find(".tpl-province")[0],e.city=a(this).find(".tpl-city")[0];var t={};t.province=a(e.province).data("value"),t.city=a(e.city).data("value"),n.render(e,t,{withTitle:!0,wechat:!0})}),a(".sub-designer-y").sortable({items:".sub-js-sortable",axis:"y",cancel:".sub-js-not-sortable"}),a(".designer-x").sortable({items:".js-sortable",axis:"x"})}),s.context={},s.context.group=a.group,0<a.id&&1!=a.type&&1==a.status&&(s.context.group.disabled=1),s.initGroup=function(){s.context.group={title:"",type:a.type,button:[{name:"èœå•å称",type:"click",url:"",key:"",media_id:"",appid:"",pagepath:"",sub_button:[]}],matchrule:{client_platform_type:0,group_id:-1}}},s.context.group&&s.context.group.button||s.initGroup(),s.$watch("context.group.matchrule.province",function(e,t){""==e?$(".tpl-city").hide():$(".tpl-city").show()}),s.context.activeIndex=0,s.context.activeBut=s.context.group.button[s.context.activeIndex],s.context.activeItem=s.context.activeBut,s.context.activeType=1,s.context.remove=function(){return confirm("åˆ é™¤é»˜è®¤èœå•ä¼šæ¸…空所有èœå•è®°å½•ï¼Œç¡®å®šå—?")&&(location.href=a.delete_url),!1},s.context.submit=function(e){var t=s.context.group;t.button=_.sortBy(t.button,function(e){return $(':hidden[data-role="parent"][data-hash="'+e.$$hashKey+'"]').parent().index()}),angular.forEach(t.button,function(e){e.sub_button=_.sortBy(e.sub_button,function(e){return $(':hidden[data-role="sub"][data-hash="'+e.$$hashKey+'"]').parent().index()})});$(':hidden[name="menu_media"]').val();if(!$.trim(t.title))return util.message("没有设置èœå•ç»„å称","","error"),!1;if(2==a.type&&!t.matchrule.client_platform_type&&-1==t.matchrule.group_id)return util.message("没有设置个性化èœå•çš„匹é…规则","","error"),!1;if(t.button.length<1)return util.message("没有设置èœå•","","error"),!1;var i={name:"",action:""};angular.forEach(t.button,function(a,n){""==$.trim(a.name)&&(this.name+="第"+(n+1)+"个一级èœå•æœªè®¾ç½®èœå•å称<br>"),0<a.sub_button.length?angular.forEach(a.sub_button,function(e,t){""==$.trim(e.name)&&(this.name+="第"+(n+1)+"个一级èœå•ä¸çš„第"+(t+1)+"个二级èœå•æœªè®¾ç½®èœå•å称<br>"),"view"==e.type&&e.url.indexOf("http")<0&&(this.action+="第"+(n+1)+"个一级èœå•ä¸çš„第"+(t+1)+"个二级èœå•è·³è½¬é“¾æŽ¥ç¼ºå°‘httpæ ‡è¯†<br>"),"miniprogram"==e.type&&(""==$.trim(e.appid)&&(this.action+="第"+(n+1)+"个一级èœå•ä¸çš„第"+(t+1)+"个二级èœå•éœ€è®¾ç½®APPID<br>"),""==$.trim(e.pagepath)&&(this.action+="第"+(n+1)+"个一级èœå•ä¸çš„第"+(t+1)+"个二级èœå•éœ€è®¾ç½®é¡µé¢è·³è½¬åœ°å€<br>"),""==$.trim(e.url)&&(this.action+="第"+(n+1)+"个一级èœå•ä¸çš„第"+(t+1)+"个二级èœå•éœ€è®¾ç½®å¤‡ç”¨é¡µè·³è½¬åœ°å€<br>")),("view"==e.type&&""==$.trim(e.url)||"click"==e.type&&""==e.media_id&&""==e.key||"view"!=e.type&&"click"!=e.type&&"miniprogram"!=e.type&&""==$.trim(e.key))&&(this.action+="èœå•ã€"+a.name+"】的åèœå•ã€"+e.name+"】未设置æ“作选项. <br />")},i):("view"==a.type&&a.url.indexOf("http")<0&&(this.action+="èœå•ã€"+a.name+"】跳转链接缺少httpæ ‡è¯†. <br />"),"miniprogram"==a.type&&(""==$.trim(a.appid)&&(this.action+="èœå•ã€"+a.name+"】需设置APPID. <br />"),""==$.trim(a.pagepath)&&(this.action+="èœå•ã€"+a.name+"】需设置页é¢è·³è½¬åœ°å€. <br />"),""==$.trim(a.url)&&(this.action+="èœå•ã€"+a.name+"】需设置备用页跳转地å€. <br />")),("view"==a.type&&""==$.trim(a.url)||"click"==a.type&&""==a.media_id&&""==a.key||"view"!=a.type&&"click"!=a.type&&"miniprogram"!=a.type&&""==$.trim(a.key))&&(this.action+="èœå•ã€"+a.name+"】ä¸å˜åœ¨åèœå•å¹¶ä¸”未设置æ“作选项. <br />"))},i),i.name?util.message(i.title,"","error"):i.action?util.message(i.action,"","error"):($("#btn-submit").attr("disabled",!0),n.post(location.href,{group:t,method:"post",submit_type:e}).success(function(e){0!=e.message.errno?($("#btn-submit").attr("disabled",!1),util.message(e.message.message,"","error")):util.message("创建èœå•æˆåŠŸ. ",e.redirect,"success")}))},s.context.triggerActiveBut=function(e){e=$.inArray(e,s.context.group.button);if(-1==e)return!1;s.context.activeIndex=e,s.context.activeBut=s.context.group.button[s.context.activeIndex],s.context.activeItem=s.context.activeBut,s.context.activeType=1,s.context.activeItem.forceHide=0},s.context.editBut=function(e,t,a){s.context.triggerActiveBut(t),e?(s.context.activeItem=e,s.context.activeType=2):(s.context.activeItem=t,s.context.activeType=1),1==s.context.activeType&&0<s.context.activeItem.sub_button.length?s.context.activeItem.forceHide=1:s.context.activeItem.forceHide=0,a&&(s.context.activeItem.material=[],"view"!=s.context.activeItem.type&&"click"!=s.context.activeItem.type&&(current_type=s.context.activeItem.key?s.context.activeItem.key.substr(0,6):"click","module"==current_type?s.context.activeItem.etype="module":s.context.activeItem.etype="click"),n.post(current_menu_url,{current_menu:s.context.activeItem}).success(function(e){0==e.message.errno&&s.context.activeItem.material.push(e.message.message)}))},s.context.addBut=function(){var e;3<=s.context.group.button.length||(s.context.group.button.push({name:"èœå•å称",type:"click",url:"",key:"",media_id:"",appid:"",pagepath:"",sub_button:[]}),e=s.context.group.button[s.context.group.button.length-1],s.context.triggerActiveBut(e),$(".designer-x").sortable({items:".js-sortable",axis:"x"}))},s.context.removeBut=function(e,t){1==t?util.confirm(function(){s.context.group.button=_.without(s.context.group.button,e),s.$apply(),s.context.triggerActiveBut(s.context.group.button[0])},function(){return!1},"ç¡®è®¤åˆ é™¤å—?"):(s.context.activeBut.sub_button=_.without(s.context.activeBut.sub_button,e),s.context.triggerActiveBut(s.context.activeBut)),0<s.context.activeItem.sub_button.length?s.context.activeItem.forceHide=1:s.context.activeItem.forceHide=0},s.context.addSubBut=function(e){if(1==s.context.group.disabled)return!1;s.context.triggerActiveBut(e),5<=s.context.activeBut.sub_button.length||(s.context.activeBut.sub_button.push({name:"åèœå•å称",type:"click",url:"",key:"",appid:"",pagepath:"",media_id:""}),$(".sub-designer-y").sortable({items:".sub-js-sortable",axis:"y",cancel:".sub-js-not-sortable"}),s.context.activeItem=s.context.activeBut.sub_button[s.context.activeBut.sub_button.length-1],s.context.activeType=2,s.context.activeItem.forceHide=0)},s.context.selectEmoji=function(){util.emojiBrowser(function(e){e="::"+e.find("span").text()+"::";$("#title").setCaret(),$("#title").insertAtCaret(e),s.context.activeItem.name=$("#title").val(),s.$digest()})},s.context.select_link=function(){$(this).parent().prev();util.linkBrowser(function(e){var t=a.site_url;"tel:"!=e.substring(0,4)?(-1==e.indexOf("http://")&&-1==e.indexOf("https://")&&(e=t+"app"+(e=e.replace("./index.php?","/index.php?"))),s.context.activeItem.url=e,s.$digest()):util.message("自定义èœå•ä¸èƒ½è®¾ç½®ä¸ºä¸€é”®æ‹¨å·")})},s.context.search=function(){var e=$("#ipt-forward").val();$.post(a.search_key_url,{key_word:e},function(e){var t=(e=$.parseJSON(e)).length,a="";if(0<t)for(var n=0;n<t;n++)a+='<li><a href="javascript:;">'+e[n]+"</a></li>";else a+='<li><a href="javascript:;" id="no-result">没有找到您输入的关键å—</a></li>';$("#key-result ul").html(a),$('#key-result ul li a[id!="no-result"]').click(function(){$("#ipt-forward").val($(this).html()),s.context.activeItem.key=$(this).html(),$("#key-result").hide()}),$("#key-result").show()})},s.context.select_mediaid=function(t,a){util.material(function(e){s.context.activeItem.key="",s.context.activeItem.media_id=e.media_id,s.context.activeItem.material=[],"keyword"==t?(s.context.activeItem.material.push(e),s.context.activeItem.material[0].type="keyword",s.context.activeItem.key="keyword:"+e.content,s.context.activeItem.media_id="","1"==a&&(s.context.activeItem.material[0].etype="click",s.context.activeItem.material[0].name=e.name,s.context.activeItem.material[0].content=e.content)):"image"==t||"news"==t||"voice"==t||"video"==t?s.context.activeItem.material.push(e):"module"==t&&(s.context.activeItem.key="module:"+e.name,s.context.activeItem.material.push(e),s.context.activeItem.material[0].module_type=s.context.activeItem.material[0].type,s.context.activeItem.material[0].type="module",s.context.activeItem.material[0].etype="module"),s.$digest()},{type:t,isWechat:!0,needType:3})},s.context.editBut("",s.context.group.button[0],s.context.group.id)}]),angular.module("messageApp",["we7app"]),angular.module("messageApp").controller("messageNoticeCtrl",["$scope","$http","config",function(t,n,a){t.type=a.type,t.lists=a.lists,t.is_read=a.is_read,t.all_read_url=a.all_read_url,t.allRead=function(){n.post(t.all_read_url,{type:t.type}).success(function(e){util.message(e.message.message,e.redirect,"ajax")})},t.changeStatus=function(e,t){var a=$("#key-"+t).attr("class");n.post("./index.php?c=message&a=notice&do=setting",{property:e,type:t}).success(function(e){0==e.message.errno?(a.match("switchOn")?$("#key-"+t).removeClass("switchOn"):$("#key-"+t).addClass("switchOn"),util.message("修改æˆåŠŸï¼","","success")):util.message(e.message.message)}).error(function(e){util.message("网络错误,请ç¨å€™é‡è¯•")})},t.getOfficialMsg=function(e,t){n.get(a.mark_read_url+"&id="+e),window.open(t)},t.accounts=a.accounts,t.searchInAccountData=function(e){if(t.accounts={},0<e.length)for(item in a.accounts)-1!=a.accounts[item].name.indexOf(e)&&(t.accounts[item]=a.accounts[item]);else t.accounts=angular.copy(a.accounts)},t.setUniacid=function(e){n.post(a.wechat_setting_url,{uniacid:e,token:a.token,submit:1}).success(function(e){0==e.message.errno?util.message(e.message.message,a.wechat_setting_url,"success"):util.message(e.message.message,"","error")})}}]);var letterindex=["按å—æ¯ç›é€‰(全部)","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"];function we7ResourceMusicFormController(e){var t=this;t.music={title:"",HQUrl:"",url:"",description:"",name:""},t.$onInit=function(){t.music.url=t.musicurl,t.music.name=t.musicname},t.$onChanges=function(e){t.music.url=e.musicurl.currentValue,t.music.name=e.musicname.currentValue},t.selectVoice=function(){t.doselect()},t.ok=function(){""!=t.music.title?""!=t.music.url?e.$emit("add_music",t.music):util.message("请选择媒体文件"):util.message("æ ‡é¢˜ä¸èƒ½ä¸ºç©º")}}function UploadController(a,e,n,i){var s=this;function o(e){i(function(){a.uploading=e})}function t(e){var t;s.uploading||(t=e[0],s.filename=t.name,s.filesize=parseInt(t.size/1024),s.files=e,o(!0),t=s.uploadUrl,s.onUploadStart({files:e}),n.upload(e,t,{onProgress:r,concurrency:1,onUploadError:function(e,t,a){t=JSON.parse(t);s.onUploadError({mes:t.message.message||"ä¸Šä¼ å¤±è´¥"})}}).then(function(e){o(!1),l(),s.onUploaded()},function(e){l(),o(!1),s.onUploadError("")}))}function r(e){var t=parseInt(e.loaded/e.total*100);e.filename=e.name,e.filesize=parseInt(e.size/1024),e.progress=t,s.onProgress({file:e,progress:t}),i(function(){a.progress=t})}function l(){var e=document.getElementById("we7resourceFile");e.value=null,e.addEventListener("change",function(e){t(e.target.files)})}s.currentFile=null,a.uploading=!0,s.uploadProgress=0,s.$onInit=function(){},document.addEventListener&&(document.addEventListener("dragenter",function(e){e.stopPropagation(),e.preventDefault()},!1),document.addEventListener("dragover",function(e){e.stopPropagation(),e.preventDefault()},!1),document.getElementById("material-Modal").addEventListener("drop",function(e){e.stopPropagation(),e.preventDefault(),t(e.dataTransfer.files)})),l()}function uiUploader(e,i){var u=this;function s(e){for(var t=0;t<e.length;t++)u.files.push(e[t])}function d(e){u.options=Object.assign(u.options,e),console.log(u.options,"start");for(var t=e.headers||{},a=e.options||{},n=0;n<u.files.length&&u.activeUploads!=u.options.concurrency;n++)u.files[n].active||function(a,e,t,n,i,s){var o,r,l;t=t||{},n=n||"file",u.activeUploads+=1,a.active=!0,a.status="loading",o=new window.XMLHttpRequest,!0===s.withCredentials&&(o.withCredentials=!0);if(r=new window.FormData,o.open("POST",e),i)for(var c in i)i.hasOwnProperty(c)&&o.setRequestHeader(c,i[c]);if(o.upload.onloadstart=function(){},o.upload.onprogress=function(e){var t;e.lengthComputable&&(a.loaded=e.loaded,a.total=e.total,a.humanSize=(t=e.loaded,e=0===t?0:+Math.floor(Math.log(t)/Math.log(1024)),(t/Math.pow(1024,e)).toFixed(e?1:0)+" "+["n/a","bytes","KiB","MiB","GiB","TB","PB","EiB","ZiB","YiB"][isNaN(t)?0:1+e]),angular.isFunction(u.options.onProgress)&&u.options.onProgress(a))},o.upload.onload=function(){angular.isFunction(u.options.onUploadSuccess)&&u.options.onUploadSuccess(a)},o.upload.onerror=function(e){angular.isFunction(u.options.onError)&&u.options.onError(e)},o.onload=function(){--u.activeUploads,u.uploadedFiles+=1,d(u.options);var e=JSON.parse(o.responseText);e.message&&0!=e.message.errno?(a.status="error",angular.isFunction(u.options.onUploadError)&&u.options.onUploadError(a,o.responseText,o.status)):(a.status="success",a.res=e,angular.isFunction(u.options.onCompleted)&&u.options.onCompleted(a,o.responseText,o.status)),0===u.activeUploads&&(u.uploadedFiles=0,angular.isFunction(u.options.onCompletedAll)&&u.options.onCompletedAll(u.files))},t)for(l in t)t.hasOwnProperty(l)&&r.append(l,t[l]);r.append(n,a,a.name),o.send(r)}(u.files[n],u.options.url,u.options.data,u.options.paramName,t,a)}return u.files=[],u.options={},u.activeUploads=0,u.uploadedFiles=0,{addFiles:s,getFiles:function(){return u.files},files:u.files,startUpload:d,removeFile:function(e){u.files.splice(u.files.indexOf(e),1)},removeAll:function(){u.files.splice(0,u.files.length)},upload:function(e,t,a){console.log(u.options,"upload");var n=i.defer();return s(e),d(Object.assign({url:t,concurrency:5,onProgress:function(e){a.onProgress&&a.onProgress(e)},onCompleted:function(e,t){},onCompletedAll:function(e){n.resolve(e)}},a)),n.promise}}}function VoiceController(a,n,t,i,e,s){n.resourceType="voice",e("we7resource-base-controller",{$scope:n}),n.uploadname="ä¸Šä¼ è¯éŸ³",n.accept="audio/amr,audio/mp3,audio/wma,audio/wmv,audio/amr",n.keyword="",n.order="desc",n.selectedAllStatus=!1,setTimeout(function(){$(".material-head select").niceSelect&&$(".material-head select").niceSelect()});var o=this;function r(){n.selectedAllStatus=!1,i.getResources("voice",n.currentPage,1==n.index,{uniacid:n.uniacid,global:n.global,keyword:n.keyword||"",order:n.order||""}).then(function(e){o.voices=e.items,o.pager=t.trustAsHtml(e.pager)})}function l(){n.uploadurl=0===n.index?"./index.php?c=utility&a=file&do=wechat_upload&upload_type=audio&mode=perm&uniacid="+n.uniacid:"./index.php?c=utility&a=file&do=upload&upload_type=audio&global="+n.global+"&dest_dir="+n.dest_dir+"&uniacid="+n.uniacid}o.voices=[],o.$onInit=function(){o.multiple=!1},o.itemClick=function(e){if(!o.multiple)if(n.needConvert())util.message("当å‰èµ„æºæ— 法选择");else if(e.selected)e.selected=!1;else{for(var t in o.voices)o.voices[t].selected=!1;e.selected=!0,n.$emit("selected_voice",e)}},n.canConvert=function(e){return!1},n.loadData=function(){r()},n.onIndexChange=function(e){n.keyword="",n.order="desc",setTimeout(function(){$("select").niceSelect&&$("select").niceSelect("update")}),r(),l()},n.search=function(){n.currentPage=1,r()},l(),n.$on("voice_page_change",function(e,t){n.setCurrentPage(t)}),o.timeToDate=function(e){return new Date(1e3*e)},o.getTitle=function(e){return o.isWechat?e.attachment:e.filename},$("body").on("click",function(e){$("[aria-describedby^=popover]").each(function(){$(this).is(e.target)||0!==$(this).has(e.target).length||0!==$(".popover").has(e.target).length||$(this).popover("destroy")})}),$("body").on("show.bs.popover",".js-show-del",function(){$(this).closest(".js-show-action").addClass("show")}),$("body").on("shown.bs.popover",".js-show-del",function(){$("select[ng-model^=move]").niceSelect&&$("select[ng-model^=move]").niceSelect()}),$("body").on("hide.bs.popover",".js-show-del",function(){$(this).closest(".js-show-action").removeClass("show")}),n.itemSelect=function(e,t){e.stopPropagation(),t.selected=!t.selected;t=n.getSelectedKeys().length==o.voices.length;n.selectedAllStatus=t},n.selectedAll=function(e){for(var t=0;t<o.voices.length;t++)o.voices[t].selected=e},n.getSelectedKeys=function(){for(var e=[],t=0;t<o.voices.length;t++){var a=o.voices[t];a.selected&&e.push(a.id)}return e},n.showAction=function(e,t){e.stopPropagation();e=$(e.target).closest(".js-show-action");$("[aria-describedby^=popover]").not(e).popover("destroy"),e.data("bs.popover")?e.popover("destroy"):e.popover({html:!0,placement:"auto bottom",title:"",template:'<div class="popover popover--material" role="tooltip"><div class="popover-content"></div></div>',trigger:"manual",container:"body",content:function(){var e='<div class="action-img-popover"><div class="action-img-popover__title">更多æ“作</div><div class="action-img-popover__content"><div class="action" ng-click="showRename($event)" data-name="'+o.getTitle(t)+'" data-name-id="'+t.id+'"><i class="wi wi-text color-default"></i>编辑å称</div><div class="action" ng-click="showDel($event)" data-del-id="'+t.id+'"><i class="wi wi-delete2 color-red"></i>åˆ é™¤éŸ³ä¹</div></div></div>';return a(e)(n)}}).popover("show")},n.rename="",n.showRename=function(t){t.stopPropagation(),n.rename="";var e=$(t.target);$(t.target).data("nameId")&&(e=$("[data-action-id="+$(t.target).data("nameId")+"]").find(".js-show-del"),n.rename=$(t.target).data("name")),console.log(e),$("[aria-describedby^=popover]").not(e).popover("destroy"),e.data("bs.popover")?e.popover("destroy"):e.popover({html:!0,placement:"auto bottom",title:"",template:'<div class="popover popover--material" role="tooltip"><div class="popover-content"></div></div>',trigger:"manual",container:"body",content:function(){var e='<div class="name-img-popover"><div class="name-img-popover__title">音ä¹ç®¡ç†</div><div class="name-img-popover__content we7-form"><div class="form-group"><label class="control-label col-sm-3">音ä¹å称</label><div class="col-sm-9"><div class="input-group"><input type="text" class="form-control" ng-model="rename"></div></div></div></div><div class="name-img-popover__footer"><button class="btn btn-primary" ng-disabled="!rename" ng-click="renameImg('+($(t.target).data("nameId")?$(t.target).data("nameId"):"")+')">确定</button><button class="btn btn-default js-hide-popover" onclick=\'$("[aria-describedby^=popover]").popover("destroy")\'>å–消</button></div></div>';return a(e)(n)}}).popover("show")},n.renameImg=function(e){if(1!=n.index)return util.message("ä¸æ”¯æŒä¿®æ”¹å¾®ä¿¡ç´ æå称"),!1;$("[aria-describedby^=popover]").popover("destroy"),i.changeName(e,n.rename,1==n.index,{uniacid:n.uniacid}).then(function(e){util.message("æ“作æˆåŠŸ","","success"),r()},function(e){util.message(e.message)})},n.showDel=function(t){t.stopPropagation();var e=$(t.target);$(t.target).data("delId")&&(e=$("[data-action-id="+$(t.target).data("delId")+"]").find(".js-show-del")),$("[aria-describedby^=popover]").not(e).popover("destroy"),e.data("bs.popover")?e.popover("destroy"):e.popover({html:!0,placement:"auto bottom",title:"",template:'<div class="popover popover--material" role="tooltip"><div class="popover-content"></div></div>',trigger:"manual",container:"body",content:function(){var e='<div class="delete-img-popover"><div class="delete-img-popover__title"><i class="wi wi-info"></i>åˆ é™¤è§†é¢‘</div><div class="delete-img-popover__content">åˆ é™¤ä¸å¯æ¢å¤ç¡®è®¤åˆ 除å—?</div><div class="delete-img-popover__footer"><button class="btn btn-primary" ng-click="delSel('+($(t.target).data("delId")?$(t.target).data("delId"):"")+')">åˆ é™¤</button><button class="btn btn-default js-hide-popover" onclick=\'$("[aria-describedby^=popover]").popover("destroy")\'>å–消</button></div></div>';return a(e)(n)}}).popover("show")},n.delSel=function(e){if($("[aria-describedby^=popover]").popover("destroy"),e)t=[e];else{var t=n.getSelectedKeys();if(0==t.length)return void util.message("请选择è¦åˆ 除的视频")}1==n.index?i.delMuti(t,"voice",1==n.index,{uniacid:n.uniacid}).then(function(e){util.message("åˆ é™¤æˆåŠŸ","","success"),n.currentPage=1,r()},function(e){util.message(e.message)}):i.delItem(t,"voice",1==n.index,n.uniacid).then(function(e){util.message("åˆ é™¤æˆåŠŸ","","success"),n.currentPage=1,r()},function(e){util.message(e.message)})},r(),s.bind("click","pagination li a",function(e){e=$(e.target).attr("page");e&&n.setCurrentPage(e)})}angular.module("moduleApp",["we7app","infinite-scroll"]),angular.module("moduleApp").controller("ModuleMoreCtrl",["$scope","config",function(e,t){e.activeLetter="",e.searchModule=function(e){location.href=t.searchurl+"&letter="+e}}]).controller("clerkPermission",["$scope","$http","config",function(e,a,n){e.deleteClerk=function(e,t){util.confirm(function(){a.post(n.links.deleteClerk,{uid:e,module_name:t}).success(function(e){"0"==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})},function(){return!1},"ç¡®è®¤åˆ é™¤?")}}]).controller("moduleGroupCtrl",["$scope","$http","config",function(e,t,a){e.changeText=function(e){$(e.currentTarget).parents("tr").find(".we7-group-app").toggleClass("hideall"),e.currentTarget.text="展开"==e.currentTarget.text?"收起":"展开"},e.delUniGroup=function(e){util.confirm(function(){t.post(a.links.groupDel,{id:e}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})},function(){},"ç¡®è®¤åˆ é™¤å—?")}}]).controller("moduleGroupPostCtrl",["$scope","$http","config",function(i,t,e){function a(t,e){if(i.selectedModules=[],!e)return i.selectedModules=[],void angular.forEach(t,function(e){e.selected=!1});angular.forEach(t,function(e){e.selected=!0,i.selectedModules.push(e),e.main_module&&""!=e.main_module&&null!=t[e.main_module]&&i.selectedModules.push(t[e.main_module])})}i.config=e,i.moduleGroup=null===e.moduleGroup?{title:""}:e.moduleGroup,i.groupHaveModuleApp=0==e.groupHaveModuleApp.length?{}:e.groupHaveModuleApp,i.groupHaveModuleWxapp=0==e.groupHaveModuleWxapp.length?{}:e.groupHaveModuleWxapp,i.groupHaveModuleWebapp=0==e.groupHaveModuleWebapp.length?{}:e.groupHaveModuleWebapp,i.groupHaveModulePhoneapp=0==e.groupHaveModulePhoneapp.length?{}:e.groupHaveModulePhoneapp,i.groupHaveModuleAliapp=0==e.groupHaveModuleAliapp.length?{}:e.groupHaveModuleAliapp,i.groupNotHaveModuleApp=e.groupNotHaveModuleApp,i.groupNotHaveModuleWxapp=e.groupNotHaveModuleWxapp,i.groupNotHaveModuleWebapp=e.groupNotHaveModuleWebapp,i.groupNotHaveModulePhoneapp=e.groupNotHaveModulePhoneapp,i.groupNotHaveModuleAliapp=e.groupNotHaveModuleAliapp,i.groupHaveTemplate=0==e.groupHaveTemplate.length?{}:e.groupHaveTemplate,i.groupNotHaveTemplate=e.groupNotHaveTemplate,i.selectedModules=[],i.allmodulesel=!1,i.allwxappsel=!1,i.alltemplatesel=!1,i.allwebsel=!1,i.keyword="",i.filterKeyword=function(t){angular.forEach(i.groupNotHaveModuleApp,function(e){e.hide=!1,""!=t&&-1==e.title.indexOf(t)&&(e.hide=!0)})},i.addModule=function(){$("#add_module").modal("show")},i.addModuleWxapp=function(){$("#add_module_wxapp").modal("show")},i.adTemplate=function(){$("#add_template").modal("show")},i.addModuleWebapp=function(){$("#add_module_webapp").modal("show")},i.addModulePhoneapp=function(){$("#add_module_phoneapp").modal("show")},i.addModuleAliapp=function(){$("#add_module_aliapp").modal("show")},i.selectOrCancelModule=function(e,t){e.selected=!e.selected,e.selected?i.selectModule(e,t):i.cancleModule(e,t)},i.selecteAllModule=function(e){a(i.groupNotHaveModuleApp,e)},i.selecteAllWxapp=function(e){a(i.groupNotHaveModuleWxapp,e)},i.selecteAllTemplate=function(e){a(i.groupNotHaveTemplate,e)},i.selecteAllWebapp=function(e){a(i.groupNotHaveModuleWebapp,e)},i.selecteAllAliapp=function(e){a(i.groupNotHaveModuleAliapp,e)},i.selecteAllPhoneapp=function(e){a(i.groupNotHaveModulePhoneapp,e)},i.selectModule=function(e,t){i.selectedModules.push(e),"module"==t&&""!=e.main_module&&null!=i.groupNotHaveModuleApp[e.main_module]&&i.selectedModules.push(i.groupNotHaveModuleApp[e.main_module]),"module"==t?i.selectedModules.length>=_.values(i.groupNotHaveModuleApp).length&&(i.allmodulesel=!0):"module_wxapp"==t?i.selectedModules.length==_.values(i.groupNotHaveModuleWxapp).length&&(i.allwxappsel=!0):"module_webapp"==t?i.selectedModules.length==_.values(i.groupNotHaveModuleWebapp).length&&(i.allwebappsel=!0):"module_phoneapp"==t?i.selectedModules.length==_.values(i.groupNotHaveModulePhoneapp).length&&(i.allphoneappsel=!0):i.selectedModules.length==_.values(i.groupNotHaveTemplate).length&&(i.alltemplatesel=!0)},i.cancleModule=function(t,e){if(have_plugin=!1,angular.forEach(i.selectedModules,function(e){e.main_module==t.name&&(have_plugin=!0)}),1==have_plugin)return!1;var a=_.indexOf(i.selectedModules,t);-1<a&&(i.selectedModules=_.without(i.selectedModules,i.selectedModules[a])),"module"==e?i.allmodulesel=!1:"module_wxapp"==e?i.allwxappsel=!1:"module_webapp"==e?i.allwebappsel=!1:"module_phoneapp"==e?i.allphoneappsel=!1:"module_aliapp"==e?i.allaliappsel=!1:i.alltemplatesel=!1},i.addHaveModule=function(){angular.forEach(i.selectedModules,function(e,t){delete i.groupNotHaveModuleApp[e.name],i.groupHaveModuleApp[e.name]=e}),i.selectedModules=[],$("#add_module").modal("hide"),i.allmodulesel=!1},i.addHaveModuleWxapp=function(){angular.forEach(i.selectedModules,function(e,t){delete i.groupNotHaveModuleWxapp[e.name],i.groupHaveModuleWxapp[e.name]=e}),i.selectedModules=[],$("#add_module_wxapp").modal("hide"),i.allwxappsel=!1},i.addHaveTemplate=function(){angular.forEach(i.selectedModules,function(e,t){delete i.groupNotHaveTemplate[e.name],i.groupHaveTemplate[e.name]=e}),i.selectedModules=[],$("#add_template").modal("hide")},i.addHaveModuleWebapp=function(){angular.forEach(i.selectedModules,function(e,t){delete i.groupNotHaveModuleWebapp[e.name],i.groupHaveModuleWebapp[e.name]=e}),i.selectedModules=[],$("#add_module_webapp").modal("hide")},i.addHaveModulePhoneapp=function(){angular.forEach(i.selectedModules,function(e,t){delete i.groupNotHaveModulePhoneapp[e.name],i.groupHaveModulePhoneapp[e.name]=e}),i.selectedModules=[],$("#add_module_phoneapp").modal("hide")},i.delHaveModule=function(t){t.selected=!1,delete i.groupHaveModuleApp[t.name],""!=(i.groupNotHaveModuleApp[t.name]=t).plugin&&angular.forEach(i.groupHaveModuleApp,function(e){e.main_module==t.name&&(delete i.groupHaveModuleApp[e.name],i.groupNotHaveModuleApp[e.name]=e)})},i.delHaveModuleWxapp=function(e){e.selected=!1,delete i.groupHaveModuleWxapp[e.name],i.groupNotHaveModuleWxapp[e.name]=e},i.delHaveModuleWebapp=function(e){e.selected=!1,delete i.groupHaveModuleWebapp[e.name],i.groupNotHaveModuleWebapp[e.name]=e},i.delHaveModulePhoneapp=function(e){e.selected=!1,delete i.groupHaveModulePhoneapp[e.name],i.groupNotHaveModulePhoneapp[e.name]=e},i.delHaveModuleAliapp=function(e){e.selected=!1,delete i.groupHaveModuleAliapp[e.name],i.groupNotHaveModuleAliapp[e.name]=e},i.delHaveTemplate=function(e){e.selected=!1,delete i.groupHaveTemplate[e.name],i.groupNotHaveTemplate[e.name]=e},i.cancel=function(e){angular.forEach(i.selectedModules,function(e){e.selected=!1}),i.selectedModules=[],i.allmodulesel=!1,i.allwxappsel=!1,i.alltemplatesel=!1,i.allwebappsel=!1,i.allphoneappsel=!1,i.allaliappsel=!1,$("#"+e).modal("hide")},i.saveGroup=function(){var a=[];angular.forEach(i.groupHaveModuleApp,function(e,t){a.push(e.name)});var n=[];angular.forEach(i.groupHaveModuleWxapp,function(e,t){n.push(e.name)});var e={id:i.moduleGroup.id,name:i.moduleGroup.name,modules:a,wxapp:n,templates:i.groupHaveTemplate,webapp:i.groupHaveModuleWebapp,phoneapp:i.groupHaveModulePhoneapp,aliapp:i.groupHaveModuleAliapp};if(""===e.name||void 0===e.name)return util.message("请输入套é¤å","","info"),!1;t({method:"POST",url:i.config.url,data:e,beforeSend:function(){$(".loader").show()},complete:function(){$(".loader").hide()}}).success(function(e){return 1==e.message.errno?(util.message(e.message.message),!1):void util.message("æ交æˆåŠŸ",e.redirect,"success")})}}]).controller("moduleGroupEditCtrl",["$scope","$http","config",function(s,i,o){s.module_name=o.module_name,s.module_list=o.module_list,s.type_list=["wxapp_support","webapp_support"],s.modulesCheck={},s.saveGroup=function(){var e,t={id:o.group_id,name:s.module_name,modules:{},templates:[]};for(e in s.module_list.modules){var a,n=s.module_list.modules[e];n.checked&&(a=n.support.replace("_support",""),t.modules[a]||(t.modules[a]=[]),-1==t.modules[a].indexOf(n.name)&&t.modules[a].push(n.name))}for(e in s.module_list.templates)s.module_list.templates[e].checked&&t.templates.push(s.module_list.templates[e].id);i.post(o.save_module_group_url,t).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,e.redirect,"error")})},s.deleteModuleSupport=function(e,t){for(var a in s.module_list.modules){var n=s.module_list.modules[a];if(n.name==t)for(var i in e)n.support==e[i]&&(n.checked=0)}setTimeout(function(){s.changeModule()},100)},s.deleteTemplate=function(e){e.checked=0,s.changeTemplate()},s.changeModule=function(){s.modulesCheck={};var e,t=s.module_list.modules;for(e in t){var a=t[e];1==a.checked&&(s.modulesCheck[a.name]||(s.modulesCheck[a.name]=JSON.parse(JSON.stringify(a)),s.modulesCheck[a.name].support={},s.modulesCheck[a.name].supportArray=[]),s.modulesCheck[a.name].support[a.support]=2,-1===s.modulesCheck[a.name].supportArray.indexOf(a.support)&&s.modulesCheck[a.name].supportArray.push(a.support))}setTimeout(function(){s.$apply("modulesCheck")},0,!1)},s.changeTemplate=function(){s.templatesCheck=[];var e,t=s.module_list.templates;for(e in t)1==t[e].checked&&s.templatesCheck.push(t[e]);setTimeout(function(){s.$apply("templatesCheck")},0,!1)},s.addModule=function(){s.changeModule(),s.changeTemplate()},s.changeModule(),s.changeTemplate()}]).controller("installedCtrl",["$scope","$http","$compile","config","$sce",function(l,e,c,a,t){l.config=a,l.isFounder=a.isFounder,l.letters=letterindex,l.moduleList={},l.moduleinfo={},l.upgradeInfo={},l.checkUpgradeSuccess=!1,l.search={moduleName:"",letter:"全部",newVersion:"",newBranch:"",serviceExpire:""};l.welcome_module=a.welcome_module,l.pagesize=15,l.pageindex=1,l.moduleListSource=angular.copy(a.moduleList),l.initModuleLogo=function(){e.get(a.initModuleLogoUrl).success(function(e){window.location.reload()})},l.loadMore=function(e,t,a){if(Math.ceil(l.moduleList.length/15)<t)return!1;var n=Math.ceil(l.moduleList.length/15);l.pageindex=t=+t;var i=Math.max(1,t-4),s=Math.min(n,t+4);s-i<9&&(s=Math.min(n,i+8),i=Math.max(1,s-8));for(var o="<li>"+$(".js-pager li:first").html()+"</li>",r=i;r<=s;r++)o+='<li><a href="javascript:;" page="'+r+'" ng-click="loadMore(\''+e+"',"+r+')">'+r+"</a></li>";t!=n&&(o+='<li><a href="javascript:;" page="'+n+'" ng-click="loadMore(\''+e+"',"+n+')">尾页</a></li>'),setTimeout(function(){$(".js-pager ul").html(c(o)(l)),$(".js-pager li").attr("class",""),$(".js-pager a[page='"+t+"']").parent().attr("class","active"),$(".js-pager .pager-nav").parent().attr("class",""),$('[data-toggle="popover"]').popover(),window.history.pushState({page:t},"",l.urlReplace("page",t))})},l.getUrlParameter=function(e){e=e.replace(/[\[]/,"\\[").replace(/[\]]/,"\\]");e=new RegExp("[\\?&]"+e+"=([^&#]*)").exec(location.search);return null===e?"":decodeURIComponent(e[1].replace(/\+/g," "))},l.urlReplace=function(e,t){url=window.location.href;var a=new RegExp("("+e+"=).*?(&|$)"),a=url.replace(a,"$1"+t+"$2");return a=-1==url.indexOf(e)?a+(0<a.indexOf("?")?"&":"?")+e+"="+t:a},l.addModuleList=function(){for(var e in l.moduleList=[],l.moduleListSource){var t=l.moduleListSource[e];if(("全部"==l.search.letter||l.moduleListSource[e].title_initial==l.search.letter)&&!(l.search.moduleName&&l.moduleListSource[e].title.indexOf(l.search.moduleName)<=-1)){if(l.search.newVersion||l.search.newBranch||l.search.serviceExpire||l.search.offSell){var a=!0;if(a=(a=(a=(a=a&&l.search.newVersion&&t.new_version&&(t.can_update||"local"==t.from)?!1:a)&&l.search.newBranch&&t.new_branch?!1:a)&&l.search.serviceExpire&&t.service_expire&&2!=t.system_shutdown&&3!=t.system_shutdown?!1:a)&&l.search.offSell&&t.offsell?!1:a)continue}l.moduleList.push(l.moduleListSource[e])}}l.loadMore(location.href,l.getUrlParameter("page")||1)},l.addModuleList(),l.searchLetter=function(e){l.search.letter=e,l.addModuleList(1)},l.searchModuleName=function(e){if(void 0!==e&&13!=(window.event?e.keyCode:e.which))return!1;l.addModuleList(1)},l.filter=function(e){"new_version"==e&&(l.search.newVersion=!0),l.addModuleList()},e.post(l.config.checkUpgradeUrl).success(function(e){if(0!=e.message.errno&&util.message(e.message.message),!e.message.message)return!1;var t=angular.copy(e.message.message);for(name_type in l.moduleListSource){var a=l.moduleListSource[name_type].name;t[a]&&(t[a].new_version&&(l.moduleListSource[name_type].new_version=!0),t[a].new_branch&&(l.moduleListSource[name_type].new_branch=!0),t[a].service_expire&&(l.moduleListSource[name_type].service_expire=!0),t[a].offsell&&(l.moduleListSource[name_type].offsell=!0),t[a].service_expiretime&&(l.moduleListSource[name_type].service_expiretime=t[a].service_expiretime),t[a].system_shutdown&&(l.moduleListSource[name_type].system_shutdown=t[a].system_shutdown,l.moduleListSource[name_type].system_shutdown_delay_time=t[a].system_shutdown_delay_time),l.moduleListSource[name_type].can_update=t[a].can_update)}l.checkUpgradeSuccess=!0}),l.change_welcome_module=function(t){t==l.welcome_module&&(t=""),e.post(a.set_site_welcome_url,{name:t}).success(function(e){return 0!=e.message.errno?(util.message(e.message.message,"","error"),!1):(l.welcome_module=t,void util.message("设置æˆåŠŸ","","success"))})},l.deleteUrl=a.deleteUrl,l.recycle=function(e,t){l.deleteData={module_name:e,support:t},$("#recycle").modal("show")}}]).controller("notInstalledCtrl",["$scope","$compile","config","we7TypeDefault",function(r,l,s,e){r.permission_check=s.permission_check,r.do=s.do,r.support=s.support,r.letters=letterindex,r.module_list=s.module_list,r.support=s.support,r.module_support_types=s.module_support_types,r.module_install_types="",angular.forEach(r.module_list,function(a){a.supportArray=[],angular.forEach(e,function(e,t){2==a[t+"_support"]&&a.supportArray.push(t+"_support")})});var c=0;for(i in s.module_list)c++;r.addModuleList=function(e){var t=-1,a=15*(e-1);for(modulename in s.module_list)if(!(++t<a)){if(15+a<=t)break;r.module_list[modulename]=s.module_list[modulename]}return!1},r.loadMore=function(e,t){if(Math.ceil(c/15)<t)return!1;r.module_list={},r.addModuleList(t);var a=Math.ceil(c/15);t=+t;var n=Math.max(1,t-4),i=Math.min(a,t+4);i-n<9&&(i=Math.min(a,n+8),n=Math.max(1,i-8));for(var s="<li>"+$(".js-pager li:first").html()+"</li>",o=n;o<=i;o++)s+='<li><a href="javascript:;" page="'+o+'" ng-click="loadMore(\''+e+"',"+o+')">'+o+"</a></li>";t!=a&&(s+='<li><a href="javascript:;" page="'+a+'" ng-click="loadMore(\''+e+"',"+a+')">尾页</a></li>'),$(".js-pager ul").html(l(s)(r)),$(".js-pager li").attr("class",""),$(".js-pager a[page='"+t+"']").parent().attr("class","active"),$(".js-pager .pager-nav").parent().attr("class","")},r.loadMore("",1),r.searchLetter=function(e){$(':hidden[name="letter"]').val(e),$("#search").click()},r.searchOrder=function(e){$(':hidden[name="order"]').val(e),$("#search").click()},r.modalConfirm=function(e,t,a){var n,i;return"delete"==a?(n="",angular.forEach(e,function(e,t){n+="&supports[]="+e}),i=s.delete_url+"&module_name="+t.name+n,util.confirm(function(){window.location.href=i},function(){},"ç¡®è®¤åˆ é™¤å—?")):(n=e.join(","),i=s.install_url+"&application_type="+t.application_type+"&module_name="+t.name+"&install_module_support="+n,util.confirm(function(){window.location.href=i},function(){},"确认安装å—?")),!1},r.uninstallModule=function(e,t,a){e+="&module_name="+t,e+="&support="+a,util.confirm(function(){window.location.href=e},function(){},"确认å¸è½½å—?")},r.testCodeInstall=function(){var e=$('input[name="code"]').val();if(!e)return util.message("测试ç ä¸èƒ½ä¸ºç©º"),!1;var t=s.install_url+"&code="+e;util.confirm(function(){window.location.href=t},function(){},"确认安装å—?")}}]).controller("detailCtrl",["$scope","$http","config","we7TypeDefault",function(a,n,i,e){a.config=i,a.isFounder=i.isFounder,a.receive_ban=i.receive_ban,a.moduleinfo=i.moduleInfo,a.localUpgradeInfo=!!Object.keys(i.localUpgradeInfo).length&&i.localUpgradeInfo,a.subscribe=2,a.checkupgrade=0,a.show=i.show,a.editType="",a.we7TypeDefault={},angular.forEach(e,function(e,t){a.we7TypeDefault[t+"_support"]=e}),n.post(a.config.checkReceiveUrl,{module_name:a.moduleinfo.name}).success(function(e){0==e.message.errno&&(a.subscribe=1)}),a.getUpgradeInfoButton="检测更新",a.getUpgradeInfo=function(t){a.getUpgradeInfoButton="检测ä¸...",n.post(a.config.getUpgradeInfoUrl,{name:a.moduleinfo.name}).success(function(e){return a.getUpgradeInfoButton="检测更新",a.moduleinfo.system_shutdown=e.message.message.system_shutdown,a.moduleinfo.system_shutdown_delay_time=e.message.message.system_shutdown_delay_time,a.moduleinfo.can_update=e.message.message.can_update,0!=e.message.errno?(util.message(e.message.message),!1):void(e.message.message.site_branch||2==a.moduleinfo.application_type?(a.checkupgrade=1,a.upgradeInfo=e.message.message,"cloud"==e.message.message.from&&(e=(e=(new Date).getTime()).toString().substr(0,10),0<a.upgradeInfo.service_expiretime&&e>a.upgradeInfo.service_expiretime?a.upgradeInfo.service_expire=!0:a.upgradeInfo.service_expire=!1)):(t&&util.message("未检测出新版本/新分支"),a.upgradeInfo=null))})},a.getUpgradeInfo(0),a.changeShow=function(e){a.show=e,"workorder"==a.show&&n.get(i.getWorkorderIframeUrl+"name="+a.moduleinfo.name).success(function(e){0==e.errno&&$("#workorderiframe").attr("src",e.data.url)})},a.changeSwitch=function(){n.post(a.config.receiveBanUrl,{name:a.moduleinfo.name}).success(function(e){0==e.message.errno&&util.message("æ›´æ–°æˆåŠŸï¼"),a.moduleinfo.is_receive_ban=!a.moduleinfo.is_receive_ban})},a.editModule=function(e,t){a.moduleOriginal={},a.moduleOriginal[e]=t,"preview"==(a.editType=e)||"logo"==e?a.changePicture(e):$("#module-info").modal("show")},a.changePicture=function(t){require(["fileUploader"],function(e){e.init(function(e){a.moduleOriginal[t]=e.url,a.moduleinfo[t]=e.url,a.$apply(a.moduleOriginal),a.save()},{type:"image",direct:!0,multiple:!1,uniacid:0})})},a.delPicture=function(e){a.moduleOriginal[e]=""},a.upgrade=function(e,t,a){window.open("http://s.w7.cc/module-"+a+".html")},a.notice=function(e,t,a){var n=e?'å‡çº§æœåŠ¡å·²åˆ°æœŸï¼Œè¯·åˆ°å•†åŸŽ<a class="color-default" target="_blank" href="http://s.w7.cc/module-'+t+'.html">ç»è´¹ã€‚':"确认å‡çº§åˆ°æœ¬åˆ†æ”¯çš„最高版本å—";return e?(util.message(n,"","info","去ç»è´¹","http://s.w7.cc/module-"+t+".html"),!1):!!confirm(n)&&void(location.href="./index.php?c=cloud&a=process&module_name="+a+"&is_upgrade=1")},a.downgrade=function(e){if(!confirm("确定è¦å°†è¯¥æ¨¡å—将以一个版本å—?"))return!1;n.post(a.config.downgradeUrl,{module_name:e}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,"","error")})},a.save=function(){n.post(a.config.saveModuleUrl,{moduleinfo:a.moduleOriginal,name:a.moduleinfo.name}).success(function(e){0==e.message.errno?(util.message("修改æˆåŠŸ","","success"),a.moduleinfo[a.editType]=a.moduleOriginal[a.editType],"logo"==a.editType&&(a.moduleinfo.logo=a.moduleOriginal.logo+"?v="+(new Date).getTime()),"preview"==a.editType&&(a.moduleinfo.preview=a.moduleOriginal.preview+"?v="+(new Date).getTime()),a.$apply(a.moduleinfo)):util.message("修改失败","","fail")})},a.testCodeUpgrade=function(){var e=$('input[name="code_upgrade"]').val();if(!e)return util.message("测试ç ä¸èƒ½ä¸ºç©º"),!1;var t=i.install_url+"&code="+e;util.confirm(function(){window.location.href=t},function(){},"确认å‡çº§å—?")},change=function(e){branch=e.data("id"),$("#version-detail-"+branch).toggle(),clas="wi wi-angle-down"==e.find("i").prop("class")?"wi wi-angle-up":"wi wi-angle-down",text="wi wi-angle-down"==clas?"查看详情":"收起",e.html(text+'<i class="'+clas+'"></i>')}}]).controller("templateCtrl",["$scope","$http","config",function(t,a,e){t.config=e,t.templateList=e.templateList,t.upgradeInfo={},t.checkUpgrade=function(){a.post(t.config.url,{template:t.templateList}).success(function(e){0==e.message.errno&&(t.templateList=e.message.message)})},t.checkUpgrade(),t.setUpgradeInfo=function(e){a.post(t.config.get_upgrade_info_url,{name:e}).success(function(e){0==e.message.errno?(t.upgradeInfo=e.message.message,$("#upgradeInfo").modal("show")):1==e.message.errno&&util.message(e.message.message)})},t.upgrade=function(e){return confirm("本次å‡çº§éœ€è¦èŠ±è´¹"+e+"个交易å¸ã€‚确认å‡çº§ï¼Ÿ")},t.deleteTemplate=function(e){util.confirm(function(){window.location.href=e},function(){return!1},"ç¡®è®¤åˆ é™¤å—?")}}]).controller("subscribeCtrl",["$scope","$http","config",function(a,n,e){a.subscribe_module=e.subscribe_module,a.types=e.types,a.change_ban_url=e.change_ban_url,a.check_receive_url=e.check_receive_url,a.change_ban=function(t){n.post(a.change_ban_url,{module_name:t}).success(function(e){0!=e.message.errno?util.message(e.message.message,"","error"):a.subscribe_module[t].receive_ban=1==a.subscribe_module[t].receive_ban?0:1})},angular.forEach(a.subscribe_module,function(e,t){n.post(a.check_receive_url,{module_name:t}).success(function(e){0==e.message.errno&&(a.subscribe_module[t].subscribe_success=1)})})}]).controller("createAccountCtrl",["$scope","$http","config",function(e,t,a){a.module.module=a.module.name,e.wxappinfo={submit:"yes",token:a.token,choose:{modules:[{module:a.module.name,newicon:"",defaultentry:""}]},quickmenu:{show:!0,bottom:{bgcolor:"#bebebe",boundary:"#fff",selectedColor:"#0f0",color:"#428bca"},menus:[{name:"首页",defaultImage:"./resource/images/bottom-default.png",selectedImage:"./resource/images/bottom-default.png",module:{}},{name:"首页",defaultImage:"./resource/images/bottom-default.png",selectedImage:"./resource/images/bottom-default.png",module:{}}]}},e.createWxappAccount=function(){t.post(a.createWxappUrl,e.wxappinfo).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,"","error")})},e.phoneappinfo={module:[a.module]},e.createPhoneappAccount=function(){t.post(a.createPhoneappUrl,e.phoneappinfo).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,"","error")})},e.miniapp={submit:"yes",token:a.token,choose_module:{name:a.module.name}},e.createMiniappAccount=function(){t.post(a.createMiniappUrl,e.miniapp).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,"","error")})}}]).controller("linkDisplayCtrl",["$scope","$http","config",function(a,t,n){for(var e in a.userModules=n.userModules,a.linkInfo={module_name:"",main_account:{uniacid:0},link_accounts:{}},a.accountData=[],a.selectAccountLinkType="main",n.userModules)n.userModules[e].main_module&&delete a.userModules[e];a.user_modules={modules:a.userModules},a.checkModule=function(){setTimeout(function(){for(var e in a.user_modules.modules){e=a.user_modules.modules[e];1==e.checked&&(a.module=e,a.linkInfo={module_name:e.name,main_account:{},link_accounts:{}},e.checked=0,a.$apply())}},200)},a.selectAccount=function(e){if("main"==e&&!a.linkInfo.module_name)return util.message("请先选择应用","","error"),!1;if("link"==e&&!a.linkInfo.main_account.uniacid)return util.message("请先选择主账å·","","error"),!1;a.selectAccountLinkType=e;e="";2!=a.module.account_support||"link"==a.selectAccountLinkType&&"account"==a.linkInfo.main_account.type_sign?2==a.module.wxapp_support?e="wxapp":2!=a.module.webapp_support||"link"==a.selectAccountLinkType&&"webapp"==a.linkInfo.main_account.type_sign?2!=a.module.phoneapp_support||"link"==a.selectAccountLinkType&&"phoneapp"==a.linkInfo.main_account.type_sign?2!=a.module.aliapp_support||"link"==a.selectAccountLinkType&&"aliapp"==a.linkInfo.main_account.type_sign||(e="aliapp"):e="phoneapp":e="webapp":e="account",a.setAccountInfo(e)},a.setAccountInfo=function(e){a.setAccountInfoType=e,e="main"==a.selectAccountLinkType?n.getMainAccountUrl+"type_sign="+e+"&module_name="+a.linkInfo.module_name:n.getLinkAccountUrl+"type_sign="+e+"&module_name="+a.linkInfo.module_name+"&main_uniacid="+a.linkInfo.main_account.uniacid,t.get(e).success(function(e){0==e.message.errno?(a.accountData=e.message.message,a.searchInAccountData(""),$("#add_account").modal("show")):util.message(e.message.message,"","error")}),a.keyword=""},a.searchInAccountData=function(e){for(item in a.searchedAccountData={},a.accountData)-1==a.accountData[item].name.indexOf(e)&&e||(a.linkInfo.link_accounts[a.accountData[item].uniacid]&&(a.accountData[item].checked=1),a.searchedAccountData[item]=a.accountData[item]);$("select").niceSelect&&$("select").niceSelect(),$("select").niceSelect&&$("select").niceSelect("update")},a.selectedAccount=function(e){"main"==a.selectAccountLinkType?(a.linkInfo.main_account=e,a.linkInfo.link_accounts={},$("#account-data .item").removeClass("active")):(e.checked=e.checked?0:1,1==e.checked?a.linkInfo.link_accounts[e.uniacid]=e:a.linkInfo.link_accounts[e.uniacid]&&delete a.linkInfo.link_accounts[e.uniacid]),$("#add_account").modal("hide")},a.deleteLink=function(e){for(var t in a.linkInfo.link_accounts)a.linkInfo.link_accounts[t].name==e&&delete a.linkInfo.link_accounts[t]},a.submitLinkInfo=function(){t.post(n.submitLinkInfoUrl,{link_info:a.linkInfo}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,"","error")})}}]).controller("userModuleShortcutCtrl",["$scope","$http","config",function(e,t,a){e.lists=a.lists,e.attachurl=a.attachurl,e.edit=function(e){window.location.href=a.links.post_url+"&id="+e},e.delete=function(e){util.confirm(function(){window.location.href=a.links.delete_url+"&id="+e},function(){return!1},"ç¡®è®¤åˆ é™¤å—?")}}]).controller("userModuleShortcutPostCtrl",["$scope","$http","config",function(t,e,a){t.info=a.info,t.shorcutImage={attachment:"",url:""},null==t.info&&null==t.info||(t.shorcutImage.attachment=t.info.icon,t.shorcutImage.url=a.attachurl+t.info.icon),t.delImage=function(){t.shorcutImage={attachment:"",url:""}},t.changeImage=function(){require(["fileUploader"],function(e){e.init(function(e){t.shorcutImage.attachment=e.attachment,t.shorcutImage.url=e.url,t.$apply(t.shorcutImage)},{direct:!0,multiple:!1})})}}]).controller("userModuleWelcomeCtrl",["$scope","$http","config",function(n,a,t){n.attachurl=t.attachurl,n.appurl=t.appurl,n.recommend_ads=[],n.uniacid=t.uniacid,n.module_name=t.module_name,n.account_info={},n.notices=t.notices,n.changeEntryType=function(e){n.entryType=e},"v"==t.family&&(n.recommend={recommend:{name:"推è应用",list:[],ads:[],icon:"recommend"},"new-app":{name:"新应用",list:[],ads:[],icon:"new"},essential:{name:"下载排行",list:[],ads:[],icon:"down"},hot:{name:"çƒé—¨æŽ’è¡Œ",list:[],ads:[],icon:"hot"},large:{name:"大é¢åº”用排行",list:[],ads:[],icon:"big"}},require(),require(),require(),n.changeTab=function(a){a&&n.recommend[a].list.length<=0&&(n.showLoading=!0,require())}),n.loadData=function(){a.post(t.links.get_module_info_url).success(function(e){0==e.message.errno&&(n.module_info=e.message.message.module_info,util.post_message_height())}),a.post(t.links.shortcut).success(function(e){0==e.message.errno&&(n.shortcuts=e.message.message.lists,util.post_message_height())}),a.post(t.links.get_module_replies_url).success(function(e){0==e.message.errno&&(n.replies=e.message.message,util.post_message_height(),0==n.replies.length&&(n.replies=null))}),a.post(t.links.get_module_covers_url).success(function(e){0==e.message.errno&&(n.covers=e.message.message.covers,n.cover_eid=e.message.message.cover_eid,n.entryType=n.covers?"cover":"reply",require(["jquery.qrcode"],function(){$(".js-url-qrcode").each(function(){url=$(this).data("url"),$(this).find(".qrcode-block").html("").qrcode({render:"canvas",width:$(this).data("size"),height:$(this).data("size"),text:url})})}),util.post_message_height())}),a.post(t.links.module_permission_url).success(function(e){0==e.message.errno&&(n.user_permissions=e.message.message,util.post_message_height())}),a.post(t.links.get_module_accounts_url).success(function(e){0==e.message.errno&&(n.account_info=e.message.message.account_info,n.link_accounts=e.message.message.link_accounts,util.post_message_height(),setTimeout(function(){n.$apply()},0))})},n.loadData(),n.account_switch=function(e){location.href=e},n.unbind_module=function(e,t){a.get(e).success(function(e){0==e.message.errno&&(location.href=t)})},n.pageTo=function(e){"cover"==e&&(url=t.links.cover_url),"reply"==e&&(url=t.links.reply_url),window.location.href=url+"&eid="+n.cover_eid},n.changeEnterStatus=function(){a.post(t.links.change_direct_enter_status).success(function(e){0==e.message.errno&&(n.module_info.direct_enter_status=!n.module_info.direct_enter_status,util.message("修改æˆåŠŸï¼","","success"))})}}]).controller("userModuleLinkAccountCtrl",["$scope","$http","config",function(e,t,a){e.passive_link_accounts=a.passive_link_accounts,e.account_info=a.account_info}]).controller("userModuleDisplayCtrl",["$scope","$http","$compile","$timeout","config",function(l,n,c,e,i){var t=i.own_account_modules.modules;l.own_account_modules=i.own_account_modules,l.type="module_title",l.module_keyword="",l.letters=letterindex,l.changaModule={name:"",default_name:""},l.initUniModules=function(e,t){0<e&&0!=t&&util.dialog("æ•°æ®åŠ è½½ä¸...",'<div class="progress"> <div class="progress-bar progress-bar-info" role="progressbar" aria-valuenow="'+e/t*100+'" aria-valuemin="0" aria-valuemax="100" style="width: '+e/t*100+'%"><span class="sr-only"></span></div></div>',"",{containerName:"link-container"}).modal("show"),n.post(i.links.init_uni_modules,{pageindex:e}).success(function(e){1==e.message.errno?location.href=i.links.module_display:l.initUniModules(e.message.message.pageindex,e.message.message.total)})},angular.equals(l.own_account_modules.modules,!angular.equals(l.own_account_modules.system_have_modules,[]))&&l.initUniModules(1,100),l.searchModule=function(){var a;l.modules=[],null!=l.keyword&&(a=new RegExp(l.keyword,"gi"),angular.forEach(t,function(e,t){a.test(e.title)&&l.modules.push(e)})),l.letter&&angular.forEach(t,function(e,t){e.title_initial==l.letter&&l.modules.push(e)}),l.own_account_modules.modules=l.modules},l.showAccounts=function(t,a){n.post(i.links.moduleAccounts,{module_name:t}).success(function(e){l.module_hava_accounts=e.message.message,l.loadMore(1),l.changaModule={name:t,default_name:a},$("#jurisdiction-add").modal("show")})},l.loadMore=function(e){if(!l.module_hava_accounts)return $(".js-pager ul").html(""),!1;for(var t in l.modulesByKeyword=[],l.module_hava_accounts){var a=l.module_hava_accounts[t];a.title=a.title||"",a.name=a.name||"",l.module_keyword&&-1===a.account_name.indexOf(l.module_keyword)||l.modulesByKeyword.push(a)}var n=Math.ceil(l.modulesByKeyword.length/10);if(n&&n<e)return!1;if(l.changePage(e,10),n<2)return $(".js-pager ul").html(""),!1;e=+e;var i=Math.max(1,e-4),s=Math.min(n,e+4);s-i<9&&(s=Math.min(n,i+8),i=Math.max(1,s-8));var o="";1!=e&&(o='<li><a href="javascript:;" page="1" ng-click="loadMore(1)">首页</a></li>');for(var r=i;r<=s;r++)o+='<li><a href="javascript:;" page="'+r+'" ng-click="loadMore(\''+r+"')\">"+r+"</a></li>";e!=n&&(o+='<li><a href="javascript:;" page="'+n+'" ng-click="loadMore(\''+n+"')\">尾页</a></li>"),$(".js-pager ul").html(c(o)(l)),$(".js-pager li").attr("class",""),$(".js-pager a[page='"+e+"']").parent().attr("class","active"),$(".js-pager .pager-nav").parent().attr("class","")},l.changePage=function(e,t){var a,n=-1,i=(e-1)*t;for(a in l.modules=[],l.modulesByKeyword){var s=l.modulesByKeyword[a];if(!(++n<i)){if(i+t<=n)break;l.modules.push(s)}}return!1},l.setDefaultAccount=function(e,t){n.post(i.links.setDefaultAccountUrl,{uniacid:e,module_name:t}).success(function(e){$("#jurisdiction-add").modal("hide"),0==e.message.errno?util.message("修改æˆåŠŸ",location.reload(),"success"):util.message("修改失败",location.reload(),"error")})},l.setTop=function(e,t){window.location.href=i.links.set_top_url+"module_name="+e+"&uniacid="+t},l.switchModule=function(e){var t;t=null==e.default_uniacid||""==e.default_uniacid||null==e.default_uniacid?e.uniacid:e.default_uniacid,window.location.href=i.links.module_switch_url+"module_name="+e.module_name+"&uniacid="+t}}]).controller("moduleAccountSetting",["$scope","config","$http",function(o,e,t){o.params=[],o.setting={},o.postSetting={},o.getSetting=function(){t.get(e.apiUrl).success(function(e){if(0!=(e=e.message).errno)return util.message(e.message,"","error"),!1;var t,a=e.message.setting&&Object.keys(e.message.setting).length?e.message.setting:{},n=e.message.params;for(t in n){if("checkbox"==n[t].type){var i=a[n[t].name];if(a[n[t].name]={},i&&"object"==typeof i&&i.length)for(var s in i)a[n[t].name][i[s]]=!0}"number"===n[t].type&&(a[n[t].name]=a[n[t].name]?Number(a[n[t].name]):""),n[t].error=!1,a[n[t].name]=a[n[t].name]||null}o.setting=a,o.params=n,setTimeout(function(){$("select").niceSelect&&$("select").niceSelect()&&$("select").niceSelect("update")},1)}).error(function(e){util.message(e.message.message,"","error")})},o.validate=function(){var e,t=o.params,a=JSON.parse(JSON.stringify(o.setting)),n=!0;for(e in t){if("checkbox"==t[e].type&&a[t[e].name]){var i,s=JSON.parse(JSON.stringify(a[t[e].name]));for(i in a[t[e].name]=[],s)s[i]&&a[t[e].name].push(i)}t[e].required&&(t[e].error=!1,(""===a[t[e].name]||null===a[t[e].name]||void 0===a[t[e].name]||"object"==typeof a[t[e].name]&&0===a[t[e].name].length)&&(n=!(t[e].error=!0)))}return o.postSetting=a,n},o.postData=function(){o.validate()&&t.post(e.apiUrl,{submit:1,token:e.token,params:o.params,setting:o.postSetting}).success(function(e){return 0!=(e=e.message).errno?(util.message(e.message,"","error"),!1):(util.toast("æ交æˆåŠŸ","success"),void o.getSetting())}).error(function(e){util.message(e.message.message,"","error")})},o.fileChange=function(e,t,a){if(a.multiple)for(var n in o.setting[o.params[a.key].name]=o.setting[o.params[a.key].name]||[],e)o.setting[o.params[a.key].name].push(e[n].url);else o.setting[o.params[a.key].name]=e.url},o.delImage=function(e,t){o.setting[o.params[e].name].splice(t,1)},o.getSetting()}]).controller("SystemAccountExpiredMessageCtrl",["$scope","config","$http",function(n,e,i){n.module_expire=e.module_expire,n.system_module_expire=e.system_module_expire,n.links=e.links,n.changeStatus=function(t){var a=1==n.module_expire[t].status?0:1;i.post(n.links.changeStatusUrl,{status:a,id:t}).success(function(e){return 0!=e.message.errno?(util.message(e.message.message),!1):(util.message(e.message.message,e.redirect,"success"),void(n.module_expire[t].status=a))})},n.deleteItem=function(e){util.confirm(function(){i.post(n.links.deleteSettingUrl,{id:e}).success(function(e){return 0!=e.message.errno?(util.message(e.message.message),!1):void util.message(e.message.message,e.redirect,"success")})},"","ç¡®è®¤åˆ é™¤ï¼Ÿ")}}]),angular.module("paycenterApp",["cfp.hotkeys"]).controller("microPay",["$scope","$timeout","config","$http","hotkeys","servicePaycenterBase",function(n,t,a,i,s,e){card=$.parseJSON(a.card_set_str),s.add({combo:"return+up",description:"Description goes here",allowIn:["INPUT"],callback:function(e,t){n.micro.submit()}}),s.add({combo:"esc",description:"Description goes here",allowIn:["INPUT"],callback:function(e,t){n.micro.reset()}}),s.add({combo:"backspace",description:"Description goes here",allowIn:["INPUT"],callback:function(e,t){n.micro.counter_handler("backspace"),e.preventDefault()}}),s.add({combo:"-",description:"Description goes here",allowIn:["INPUT"],callback:function(e,t){"0"!=n.micro.config.fee?n.micro.mcardPayManage():util.message("请输入金é¢","","error")}}),s.add({combo:"+",description:"Description goes here",allowIn:["INPUT"],callback:function(e,t){"0"!=n.micro.config.fee?n.micro.wechatPayManage():util.message("请输入金é¢","","error")}}),nums=["7","8","9","4","5","6","1","2","3","0","."],n.micro=e.paycenterBaseData(card),angular.forEach(nums,function(e,t){s.add({combo:e,description:"Description goes here",allowIn:["INPUT"],callback:function(e,t){n.micro.counter_handler(e.key)}})}),n.micro.mcardPayManage=function(){$("#mcard-pay").on("shown.bs.modal",function(){$(".js-input").focus();var a=2;s.add({combo:"return",description:"Description goes here",allowIn:["INPUT"],callback:function(e,t){input_count=n.micro.input_count(),a>input_count&&n.micro.submit(),$('input[tabindex="'+a+'"]').focus(),a++}}),s.del("backspace"),angular.forEach(nums,function(e,t){s.del(e)})}),$("#mcard-pay").on("hidden.bs.modal",function(){s.del("return"),angular.forEach(nums,function(e,t){s.add({combo:e,description:"Description goes here",allowIn:["INPUT"],callback:function(e,t){n.micro.counter_handler(e.key)}})})}),$("#mcard-pay").modal("show")},n.micro.wechatPayManage=function(){$("#wechat-pay").on("shown.bs.modal",function(){$(".js-input").focus(),s.add({combo:"return",description:"Description goes here",allowIn:["INPUT"],callback:function(e,t){n.micro.submit()}}),s.del("backspace"),angular.forEach(nums,function(e,t){s.del(e)})}),$("#wechat-pay").on("hidden.bs.modal",function(){s.del("return"),angular.forEach(nums,function(e,t){s.add({combo:e,description:"Description goes here",allowIn:["INPUT"],callback:function(e,t){n.micro.counter_handler(e.key)}})})}),$("#wechat-pay").modal("show")},n.micro.num=function(e){n.micro.counter_handler(e)},n.$watch("micro.config.code",function(e,t){e&&0<e.length&&$(".js-pay-warning").html("")}),n.micro.counter_handler=function(e){if("backspace"==(e+=""))return current_fee_length=n.micro.config.fee.length,void("1"==current_fee_length?n.micro.config.fee="0":n.micro.config.fee=n.micro.config.fee.substr(0,current_fee_length-1));"clear"!=e?"0"!=n.micro.config.fee||"1"!=n.micro.config.fee.length||"."==e?9<=n.micro.config.fee.length||8==n.micro.config.fee.length&&"."==e||-1<n.micro.config.fee.indexOf(".")&&(float=n.micro.config.fee.split("."),float[1]&&2<=float[1].length||"."==e)||(n.micro.config.fee+=e):n.micro.config.fee=e:n.micro.config.fee="0"},n.micro.reset=function(){n.micro.config.fee="0"},n.$watch("micro.config.offset_money",function(e,t){var a=Math.floor(n.micro.config.member.credit1/n.micro.config.card.offset_rate);n.micro.config.offset_money=parseInt(e),a<=e&&(n.micro.config.offset_money=a),e||(n.micro.config.offset_money=0),n.micro.config.credit1=n.micro.config.card.offset_rate*n.micro.config.offset_money,n.micro.checkLast_money()}),n.$watch("micro.config.credit2",function(e,t){reg=/^\d*\.{0,1}\d{0,1}\d{0,1}$/,reg.test(e)||(n.micro.config.credit2=t),e>n.micro.config.member.credit2&&(n.micro.config.credit2=n.micro.config.member.credit2),n.micro.checkLast_money()}),n.$watch("micro.config.last_money",function(e,t){e<0&&(n.config.last_money=0),n.micro.checkLast_money()}),n.micro.checkBasic=function(){if(!$.trim(n.micro.config.body))return util.message("商å“å称ä¸èƒ½ä¸ºç©º"),!1;var e=$.trim(n.micro.config.fee);return/^(([1-9]{1}\d*)|([0]{1}))(\.(\d){1,2})?$/.test(e)?void 0:(util.message("支付金é¢ä¸èƒ½å°‘于0.01å…ƒ"),!1)},n.micro.input_count=function(){return input_count=$("#mcard-pay input.js-input").length,input_count},n.$watch("micro.config.cardsn",function(e,t){11==e.length?n.micro.checkCard():(n.micro.config.member.uid=-1,n.micro.config.credit2=0,11<e.length&&(n.micro.config.card_error="会员å¡å¡å·é”™è¯¯"))}),n.micro.mcardPay=function(e){"0"==n.micro.config.fee?util.message("请输入金é¢","","error"):(n.micro.config.cardsn="",n.micro.config.member.uid=-1),"1"==e?n.micro.mcardPayManage():"2"==e&&n.micro.wechatPayManage()},n.micro.is_showCode=function(){Math.floor(n.micro.config.member.credit1/n.micro.config.card.offset_rate);n.micro.config.fact_fee<=n.micro.config.member.credit2?n.micro.config.is_showCode=0:0<n.micro.config.card.offset_rate?(max=n.micro.config.fact_fee-n.micro.config.member.credit2-Math.floor(n.micro.config.member.credit1/n.micro.config.card.offset_rate),reg=/^-?[1-9]\d*$/,!(0<max)&&(0==max||reg.test(max))?n.micro.config.is_showCode=0:n.micro.config.is_showCode=1):(max=n.micro.config.fact_fee-n.micro.config.member.credit2,0<max?n.micro.config.is_showCode=1:n.micro.config.is_showCode=0)},n.micro.checkCard=function(){n.micro.checkBasic();var e=$.trim(n.micro.config.cardsn);if(11!=e.length)return util.message("å¡å·ä¸è¶³11ä½","","error"),!1;n.micro.config.loading="åŠ è½½ä¸..",n.micro.config.card_error="",i.post(a.card_check_url,{cardsn:e}).success(function(e){if(n.micro.config.loading="",-1!=e.message.errno){n.micro.config.card_error="",n.micro.config.member=e.message.message,n.micro.config.fact_fee=n.micro.config.fee;var t=parseInt(n.micro.config.fee),a=parseInt(n.micro.config.member.discount.condition);return 0<n.micro.config.member.discount_type&&n.micro.config.member.discount&&a<=t&&(1==n.micro.config.member.discount_type?(n.micro.config.fact_fee=n.micro.config.fee-n.micro.config.member.discount.discount,n.micro.config.fact_fee=n.micro.config.fact_fee.toFixed(2)):n.micro.config.fact_fee=n.micro.config.fee*n.micro.config.member.discount.discount,n.micro.config.fact_fee<0&&(n.micro.config.fact_fee=0)),n.micro.last_money=n.micro.config.fact_fee,n.micro.checkCredit2(),n.micro.is_showCode(),!1}n.micro.config.card_error=e.message.message})},n.micro.checkCredit2=function(){n.micro.checkLast_money(),n.micro.config.credit2=Math.min.apply(null,[n.micro.config.member.credit2,n.micro.last_money]),n.micro.checkLast_money()},n.micro.checkLast_money=function(){var e=n.micro.config.fact_fee-n.micro.config.credit2-n.micro.config.offset_money;e<0&&(n.config.last_money=0),n.micro.last_money=e.toFixed(2)},n.micro.query=function(){if(!n.micro.uniontid)return util.message("系统错误","","error"),!1;i.post("{php echo url('paycenter/wxmicro/query');}",{uniontid:n.micro.uniontid}).success(function(e){0==e.message.errno?(util.message("支付æˆåŠŸ","","success"),location.reload()):util.message("支付失败:"+e.message.message,"","error")})},n.micro.checkpay=function(){i.post(a.checkpay_url,{uniontid:n.micro.uniontid}).success(function(e){console.dir(e),"SUCCESS"==e.message.trade_state?util.message("支付æˆåŠŸ",a.redirect_url,"error"):"NOTPAY"==e.message.trade_state?util.message("支付失败:用户å–消支付",a.redirect_url,"error"):"USERPAYING"==e.message.trade_state?t(function(){n.micro.checkpay()},5e3):util.message(e.message.trade_state_desc,a.redirect_url,"error")})},n.micro.submit=function(){return!!confirm("确认支付å—?")&&((1==n.micro.config.is_showCode||n.micro.config.member.uid<=0)&&!$.trim(n.micro.config.code)?($(".js-pay-warning").html("支付授æƒç ä¸èƒ½ä¸ºç©º"),!1):(1==n.micro.config.is_showCode?n.micro.config.cash=n.micro.last_money:n.micro.config.cash=0,0<n.micro.config.member.uid&&(n.micro.checkLast_money(),n.micro.last_money-n.micro.config.cash!=0)?(util.message("支付方å¼è®¾ç½®çš„支付金é¢ä¸ç‰äºŽå®žé™…支付金é¢","","error"),!1):void i.post(a.pay_url,n.micro.config).success(function(e){return 0==e.message.errno?util.message(e.message.message,e.redirect,"success"):-1==e.message.errno?(util.message("支付失败:"+e.message.message,"","error"),$('#form1 :text[name="code"]').val("")):-10==e.message.errno&&($(".js-userpaying").show(),n.micro.uniontid=e.message.uniontid,t(function(){n.micro.checkpay()},5e3)),!1})))}}]),angular.module("paycenterApp").filter("credit1_num",["$rootScope",function(e){return function(e){return e=Math.floor(e)}}]),angular.module("paycenterApp").service("servicePaycenterBase",["$rootScope",function(e){var t={},a={config:{body:"刷å¡æ”¯ä»˜æ”¶æ¬¾",fee:"0",cardsn:"",card:"",credit1:0,credit2:0,last_money:0,offset_money:0,is_showCode:0,loading:"",card_error:"",member:{uid:0,credit2:0},nums:[["7","7"],["8","8"],["9","9"],["4","4"],["5","5"],["6","6"],["1","1"],["2","2"],["3","3"],["0","0"],[".","."],["clear","清除"]]}};return t.paycenterBaseData=function(e){return a.config.card=e,a},t}]),angular.module("phoneApp",["we7app"]),angular.module("phoneApp").controller("phoneCreateCtrl",["$scope","$http","config",function(t,e,a){t.uniacid=a.uniacid,t.version_id=a.version_id,t.modules=a.modules,t.selectedModule=a.version_info.modules,t.phoneappinfo=a.version_info,t.selectOrCancelModule=function(e){e.selected=!e.selected,e.selected&&(t.selectedModule=[],t.selectedModule.push(e),$("#add_module").modal("hide"))},t.savePhoneApp=function(){return t.phoneappinfo.name||t.uniacid?t.phoneappinfo.description?t.phoneappinfo.version&&/^[0-9]{1,2}\.[0-9]{1,2}(\.[0-9]{1,2})?$/.test(t.phoneappinfo.version)?void e.post(a.links.create_phone_url,{uniacid:t.uniacid,version_id:t.version_id,module:t.selectedModule,name:t.phoneappinfo.name,description:t.phoneappinfo.description,version:t.phoneappinfo.version}).success(function(e){return 0!=e.message.errno?(util.message(e.message.message,"","error"),!1):void util.message(e.message.message,e.redirect,"success")}):(util.message("版本å·é”™è¯¯ï¼Œåªèƒ½æ˜¯æ•°å—ã€ç‚¹ï¼Œæ•°å—最多两ä½ï¼Œä¾‹å¦‚ 1.1.1"),!1):(util.message("请填写æè¿°"),!1):(util.message("APPå称ä¸å¯ä¸ºç©ºï¼"),!1)}}]),angular.module("phoneApp").controller("AccountManagePhoneappCtrl",["$scope","$http","config",function(e,t,a){e.phoneapp_version_lists=a.phoneapp_version_lists,e.phoneapp_modules=a.phoneapp_modules,e.version_exist=a.version_exist,e.delPhoneappVersion=function(e){e=parseInt(e);t.post(a.links.del_version,{version_id:e}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})}}]),angular.module("profileApp",["we7app"]),angular.module("profileApp").controller("remoteCtrl",["$scope","$http","config",function(a,n,i){a.remote=angular.copy(i.remote),a.setting_type=i.remote.type,angular.forEach(["qiniu","alioss","ftp","cos"],function(e){a.remote[e]||(a.remote[e]={})}),a.remote.qiniu.secretkey=util.encrypt(a.remote.qiniu.secretkey),a.remote.alioss.secret=util.encrypt(a.remote.alioss.secret),a.remote.cos.secretkey=util.encrypt(a.remote.cos.secretkey),a.remote.ftp.password=util.encrypt(a.remote.ftp.password),a.ossBuckets={},a.getOssBuckets=function(t){if(!a.remote.alioss.secret||!a.remote.alioss.key)return!1;var e="",e=(0<a.remote.alioss.secret.indexOf("*")?i:a).remote.alioss.secret;n.post(i.oss_buckets_url,{key:a.remote.alioss.key,secret:e}).success(function(e){e.message.errno<0?t||util.message("Access Key ID 或 Access Key Secret 有误,请é‡æ–°å¡«å†™ã€‚","","error"):(a.ossBuckets=e.message.message,setTimeout(function(){i.remote.alioss&&i.remote.alioss.bucket&&(a.remote.alioss.bucket=i.remote.alioss.bucket),a.$apply("remote"),$("select").niceSelect&&$("select").niceSelect("update")}))})},a.getOssBuckets(!0),a.saveSetting=function(e){0==a.remote.type&&e!=a.setting_type&&(a.remote.type=a.setting_type),a.remote.operate_type=e,n.post(i.save_url,a.remote).success(function(e){0==e.message.errno?util.message(e.message.message,"refresh","success"):util.message(e.message.message,"","error")})},a.testSetting=function(e){a.remote.operate_type=e,n.post(i.test_setting_url,a.remote).success(function(e){0==e.message.errno?util.message(e.message.message,"","success"):util.message(e.message.message,"","error")})},a.oneKeyUpload=function(){n.get(i.one_key_upload_url).success(function(e){3==e.message.errno?util.confirm(function(){window.location.href="{php echo url('system/attachment/remote')}"},function(){return!1},'未开å¯å…¨å±€çš„远程附件开关, 是å¦åŽ»<span class="color-red">站点-附件设置-远程附件</span> å¼€å¯?'):0==e.message.errno?util.message(e.message.message,"","success"):util.message(e.message.message,"","error")})}}]).controller("oauthCtrl",["$scope","$http","config",function(a,n,t){a.config=t,a.oauthHost=t.oauthHost,a.oauthAccount=t.oauthAccount,a.oauthtitle=t.oauthAccounts?t.oauthAccounts[t.oauthAccount]:"ä¸å€Ÿç”¨ä»»ä½•æƒé™",a.jsOauthAccount=t.jsOauth,a.jsOauthtitle=t.jsOauthAccounts?t.jsOauthAccounts[t.jsOauth]:"ä¸å€Ÿç”¨ä»»ä½•æƒé™",a.originalHost=a.oauthHost,a.accountList=[],a.keyword="",a.page={currentPage:1,totalItems:0,itemsPerPage:10,pagesLength:5,showGo:!0,onChange:function(){a.getList()}},a.changeType="",a.changeAccount="",a.accountNull=!1,$("body").on("show.bs.modal","#jsauth_acid",function(e){var t=a.changeType!=$(e.relatedTarget).data("type");a.changeType=$(e.relatedTarget).data("type"),a.changeAccount="oauth"==a.changeType?a.oauthAccount:a.jsOauthAccount,a.accountNull=""==a.changeAccount||0==a.changeAccount,a.$apply(),a.accountList&&a.accountList.length&&!t||a.getList()}),a.checkItem=function(e){a.changeAccount=e.uniacid,a.accountNull=!1},a.getList=function(e){e=e||a.page.currentPage||1;e=t.get_accounts_url+"&page="+e+"&keyword="+a.keyword+"&type="+a.changeType;n.get(e).success(function(e){e.message.errno?util.message(e.message.message,"","error"):(a.accountList=e.message.message.list,a.page.currentPage=e.message.message.page,a.page.itemsPerPage=e.message.message.page_size,a.page.totalItems=e.message.message.total)})},a.recover=function(){a.oauthHost=a.originalHost},a.saveOauth=function(e){var t=a.accountNull?"":a.changeAccount,t={type:e||a.changeType,account:e?a.oauthAccount:t};if("oauth"!=a.changeType&&!e||(t.host=a.oauthHost),a.oauthAccount&&!e&&!confirm("æ›´æ¢æœåŠ¡å·å€Ÿæƒä¼šå¯¼è‡´å½“å‰å…¬ä¼—å·å†…会员数æ®ä¸¢å¤±ï¼Œè¯·è°¨æ…Žæ“作ï¼"))return!1;n.post(a.config.oauth_url,t).success(function(e){0==e.message.errno?location.reload():util.message("域åä¸åˆæ³•","","error")})}}]).controller("tplCtrl",["$scope","$http","config",function(t,e,a){t.tplList=a.tplList,t.active="",t.activetpl="",t.changeActive=function(e){t.active=e,t.activetpl=t.tplList[e].tpl},t.saveTpl=function(){original_tpl=t.tplList[t.active].tpl,t.tplList[t.active].tpl=t.activetpl,e.post(a.url,{tpl:t.tplList}).success(function(e){1==e.message.errno?(t.tplList[t.active].tpl=original_tpl,util.message("请填写æ£ç¡®çš„"+e.message.message+"模æ¿id","","info")):$(".modal").modal("hide")})}}]).controller("emailCtrl",["$scope","$http","config",function(t,e,a){t.setting={},t.type="",t.setting_type=a.setting.smtp?a.setting.smtp.type:"",t.modalTitle="å‚数设置",t.changeType=function(e){t.type=e,t.modalTitle="163"==e?"网易邮箱æœåŠ¡å™¨":"qq"==e?"QQ邮箱æœåŠ¡å™¨":"自定义",e==t.setting_type?t.setting=a.setting:t.setting={},$("#setting-from").modal("show")}}]).controller("paymentCtrl",["$scope","$http","config",function(n,a,i){n.config=i,n.paysetting=i.paysetting,n.aliaccounthelp=!1,n.alipartnerhelp=!1,n.alisecrethelp=!1,n.saveEdit=function(e){if("wechat_facilitator"==e&&(!0===n.paysetting.wechat_facilitator.pay_switch||!0===n.paysetting.wechat_facilitator.recharge_switch)){if(""==n.paysetting.wechat_facilitator.mchid)return util.message("请填写æœåŠ¡å•†å•†æˆ·å·","","info"),!1;if(""==n.paysetting.wechat_facilitator.signkey)return util.message("请填写æœåŠ¡å•†å•†æˆ·æ”¯ä»˜å¯†é’¥","","info"),!1}if("alipay"==e&&(!0===n.paysetting.alipay.pay_switch||!0===n.paysetting.alipay.recharge_switch)){if(""==n.paysetting.alipay.partner)return util.message("请填写åˆä½œè€…身份","","info"),!1;if(""==n.paysetting.alipay.account)return util.message("请填写收款支付å®è´¦å·","","info"),!1;if(""==n.paysetting.alipay.secret)return util.message("è¯·å¡«å†™æ ¡éªŒå¯†é’¥","","info"),!1}if("wechat"==e){if(1==n.paysetting.wechat.switch)if(1==n.paysetting.wechat.version){if(""==n.paysetting.wechat.partner)return util.message("请填写商户身份","","info"),!1;if(""==n.paysetting.wechat.key)return util.message("请填写商户秘钥","","info"),!1;if(""==n.paysetting.wechat.signkey)return util.message("请填写通信秘钥","","info"),!1}else{if(""==n.paysetting.wechat.mchid)return util.message("请填写商户å·","","info"),!1;if(""==n.paysetting.wechat.apikey)return util.message("请填写支付秘钥","","info"),!1}if(3==n.paysetting.wechat.switch){if(""==n.paysetting.wechat.service)return util.message("请选择æœåŠ¡å•†å…¬ä¼—å·","","info"),!1;if(""==n.paysetting.wechat.sub_mch_id)return util.message("请填写å商户å·","","info"),!1}}if("unionpay"==e&&(1==n.paysetting.unionpay.pay_switch||1==n.paysetting.unionpay.recharge_switch)){if(""==n.paysetting.unionpay.merid)return util.message("请填写商户å·","","info"),!1;if(""==n.paysetting.unionpay.signcertpwd)return util.message("请填写商户ç§é’¥è¯ä¹¦å¯†ç ","","info"),!1}if("line"==e&&(!0===n.paysetting.line.pay_switch||!0===n.paysetting.line.recharge_switch)&&""==n.paysetting.line.message)return util.message("请填写账户信æ¯","","info"),!1;a.post(n.config.saveurl,{type:e,param:n.paysetting[e]}).success(function(e){0==e.message.errno&&util.message(e.message.message,e.redirect,"success")})},n.switchStatus=function(e,t){e&&t||util.message("å‚数错误","","error"),n.paysetting[e][t]=!n.paysetting[e][t],"delivery"!=e&&"credit"!=e&&"mix"!=e&&"line"!=e||(n.paysetting[e].recharge_switch=!1),a.post(i.change_status,{type:e,param:n.paysetting[e]}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})},n.check_wechat=function(){a.post(i.links.getAccountWechatProxy).success(function(e){return n.services=e.message.message.service,n.borrows=e.message.message.borrow,console.log(e),i.account_level<3||n.services&&n.borrows.length<1&&n.services.length<1&&4!=i.account_level||!n.services&&n.borrows.length<1&&4!=i.account_level?(util.message("您没有有效的微信支付方å¼","","error"),!1):($("#weixin").modal("show"),void setTimeout(function(){$("#weixin select").niceSelect&&$("#weixin select").niceSelect()}))})},$(".modal").on("hide.bs.modal",function(){a.post(n.config.get_setting_url,{}).success(function(e){n.paysetting=e.message.message})}),n.test_alipay=function(){a.post(n.config.text_alipay_url,{param:n.paysetting.alipay}).success(function(e){return null!==e.message.message?(location.href=e.message.message,!1):void util.message("é…置失败ï¼")})},n.changeSwitch=function(e,t){n.paysetting[e].switch=t},n.changeVersion=function(e){n.paysetting.wechat.version=e},n.tokenGen=function(e){if(confirm("确定è¦ä¿®æ”¹å¯†é’¥å—?")){for(var t="",a=0;a<32;a++)t+="abcdefghijklmnopqrstuvwxyz0123456789"[parseInt(32*Math.random())];"wechat_facilitator.signkey"==e&&(n.paysetting.wechat_facilitator.signkey=t),"wechat.apikey"==e&&(n.paysetting.wechat.apikey=t)}}}]).controller("paymentWebappCtrl",["$scope","$http","config",function(n,t,a){n.paysetting=a.paysetting,n.paysetting.alipay=n.paysetting.alipay||{},n.paysetting.wechat=n.paysetting.wechat||{},n.paysetting.alipay.has_config=a.paysetting.alipay.account?1:0,n.paysetting.wechat.has_config=a.paysetting.wechat.appid?1:0,n.paysetting.wechat.version=2,n.wechat_qrcode="",n.saveEdit=function(e){if("alipay"==e){if(!n.paysetting.alipay.account)return util.message("请填写收款支付å®è´¦å·","","error"),!1;if(!n.paysetting.alipay.partner)return util.message("请填写åˆä½œè€…身份","","error"),!1;if(!n.paysetting.alipay.secret)return util.message("è¯·å¡«å†™æ ¡éªŒå¯†é’¥","","error"),!1}else if("wechat"==e){if(!n.paysetting.wechat.appid)return util.message("请填写appid","","error"),!1;if(!n.paysetting.wechat.mchid)return util.message("请填写微信支付商户å·","","error"),!1;if(!n.paysetting.wechat.signkey)return util.message("请填写微信支付密钥","","error"),!1}t.post(a.saveurl,{type:e,param:n.paysetting[e]}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,"","error")})},n.test_wechat=function(){t.post(a.test_wechat_url,{param:n.paysetting.wechat}).success(function(e){e.message.errno?(n.wechat_qrcode="",$("#wechat_qrcode").hide(),util.message(e.message.message,"","error")):(n.wechat_qrcode=e.message.message+"?"+Math.random(),$("#wechat_qrcode").show())})},n.test_alipay=function(){t.post(a.test_alipay_url,{param:n.paysetting.alipay}).success(function(e){return null!==e.message.message?(location.href=e.message.message,!1):void util.message("é…置失败ï¼")})},n.tokenGen=function(e){if(confirm("确定è¦ä¿®æ”¹å¯†é’¥å—?")){for(var t="",a=0;a<32;a++)t+="abcdefghijklmnopqrstuvwxyz0123456789"[parseInt(32*Math.random())];"wechat_facilitator.signkey"==e&&(n.paysetting.wechat_facilitator.signkey=t),"wechat.apikey"==e&&(n.paysetting.wechat.apikey=t)}}}]).controller("creditCtrl",["$scope","$http","config",function(t,a,e){t.config=e,t.creditSetting=e.creditSetting,t.tactics={activity:e.activity,currency:e.currency},t.creditTitle="",t.activeCredit="",t.activeTacticsType="",t.enabledCredit=e.enabledCredit,t.activeTactics="",t.syncSetting=e.syncSetting,t.changeEnabled=function(e){t.creditSetting=null==t.creditSetting?{}:t.creditSetting,null==t.creditSetting[e]&&(t.creditSetting[e]={title:"",enabled:0}),t.creditSetting[e].enabled=1==t.creditSetting[e].enabled?0:1,a.post(t.config.saveCreditSetting,{credit_setting:t.creditSetting}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})},t.editCreditTactics=function(e){$("#tactics").modal("show"),t.activeTacticsType=e,t.activeTactics=t.tactics[e]},t.editCreditName=function(e){t.activeCredit=e,$("#credit-name").modal("show"),null==t.creditSetting[e]&&(t.creditSetting[e]={title:"",enabled:0}),t.creditTitle=t.creditSetting[e].title},t.setCreditName=function(){t.creditSetting[t.activeCredit].title=t.creditTitle,a.post(t.config.saveCreditSetting,{credit_setting:t.creditSetting}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})},t.setCreditTactics=function(){a.post(t.config.saveTacticsSetting,{setting:t.tactics}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})}}]).controller("syncCtrl",["$scope","$http","config",function(e,t,a){e.config=a,e.syncSetting=a.syncSetting,e.setSync=function(){e.syncSetting=1==e.syncSetting?0:1,t.post(e.config.saveSyncSetting,{setting:e.syncSetting}).success(function(e){})}}]).controller("ucCtrl",["$scope","$http","config",function(a,c,u){a.uc=u.uc,a.mysql_status="mysql"==a.uc.connect?1:0,a.http_status="http"==a.uc.connect?1:0,a.changeConnect=function(e){("mysql"==e?$("#mysqlconnect"):$("#httpconnect")).modal("show")},a.saveSetting=function(e,t){var a={token:u.token,submit:1};if("fastinput"==t){var n,i=e.value.split(";"),s=new Array;for(n in i){var o=i[n].indexOf("UC"),r=i[n].indexOf("', '"),l=i[n].indexOf("')"),t=i[n].substring(o,r),l=i[n].substring(r+4,l);s[t]=l}a.connect=s.UC_CONNECT,a.appid=s.UC_APPID,a.key=s.UC_KEY,a.charset=s.UC_CHARSET,a.dbhost=s.UC_DBHOST,a.dbuser=s.UC_DBUSER,a.dbname=s.UC_DBNAME,a.dbpw=s.UC_DBPW,a.dbcharset=s.UC_DBCHARSET,a.dbtablepre=s.UC_DBTABLEPRE,a.dbconnect=s.UC_DBCONNECT,a.api=s.UC_API,a.ip=s.UC_IP}else a[t]="status"==t?e:e.value;c.post(u.setting_url,a).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,"","error")})},a.saveConnect=function(e){var t={token:u.token,submit:1};if("mysql"==e){if(t.dbhost=a.uc.dbhost,t.dbuser=a.uc.dbuser,t.dbpw=a.uc.dbpw,t.dbname=a.uc.dbname,t.dbcharset=a.uc.dbcharset,t.dbtablepre=a.uc.dbtablepre,t.dbconnect=a.uc.dbconnect,1==a.mysql_status){if(!t.dbhost)return util.message("请填写UCenteræ•°æ®åº“主机地å€ï¼","","error"),!1;if(!t.dbuser)return util.message("请填写UCenteræ•°æ®åº“用户åï¼","","error"),!1;if(!t.dbpw)return util.message("请填写UCenteræ•°æ®åº“密ç ï¼","","error"),!1;if(!t.dbname)return util.message("请填写UCenteræ•°æ®åº“å称ï¼","","error"),!1;if(!t.dbcharset)return util.message("请填写UCenteræ•°æ®åº“å—符集ï¼","","error"),!1;if(!t.dbtablepre)return util.message("请填写UCenteræ•°æ®è¡¨å‰ç¼€ï¼","","error"),!1;t.connect="mysql"}}else if(t.api=a.uc.api,t.ip=a.uc.ip,1==a.http_status){if(!t.api)return util.message("请填写UCenter æœåŠ¡ç«¯çš„URL地å€ï¼","","error"),!1;if(!t.ip)return util.message("请填写UCenterçš„IPï¼","","error"),!1;t.connect="http"}c.post(u.setting_url,t).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,"","error")})}}]).controller("refundCtrl",["$scope","$http","config",function(a,e,t){a.setting=t.setting,a.wechat_refund=a.setting.wechat_refund,a.ali_refund=a.setting.ali_refund,a.change_switch=function(e,t){"wechat_refund"==e&&(a.wechat_refund.switch=t),"ali_refund"==e&&(a.ali_refund.switch=t)},$("#key").change(function(){a.wechat_refund.key=$("#key").val(),a.$apply()}),$("#cert").change(function(){a.wechat_refund.cert=$("#cert").val(),a.$apply()}),$("#form_wechat").submit(function(){if(1==a.wechat_refund.switch)return""==a.wechat_refund.cert?(util.message("è¯·ä¸Šä¼ apiclient_cert.pemè¯ä¹¦"),!1):""==a.wechat_refund.key?(util.message("è¯·ä¸Šä¼ apiclient_key.pemè¯ä¹¦"),!1):void 0}),$("#private_key").change(function(){a.ali_refund.private_key=$("#private_key").val(),a.$apply()}),$("#form_ali").submit(function(){if(1==a.ali_refund.switch)return""==a.ali_refund.app_id?(util.message("请填写app_id"),!1):""==a.ali_refund.private_key?(util.message("è¯·ä¸Šä¼ rsa_private_key.pemè¯ä¹¦"),!1):void 0})}]).controller("bindDomainCtrl",["$scope","$http","config",function(e,t,a){e.account=a.account,e.middleAccount={bind_domain:""},e.httpChange=function(){t.post(a.links.post,{bind_domain:e.middleAccount.bind_domain,submit:!0,token:a.token}).success(function(e){0==e.message.errno?util.message("修改æˆåŠŸï¼",e.redirect,"success"):util.message(e.message.message)})}}]).controller("appModuleLinkUniacidCtrl",["$scope","$http","config","we7TypeDefault",function(n,a,i,e){for(var t in n.modules=i.modules,n.module="",n.selectedAccount="",n.loadData=!1,n.linkAccounts="",n.searchKeyword="",n.typeSign=i.typeSign,delete e.welcome,delete e[i.typeSign],e){n.activeTypeSign=t;break}n.initModule=function(e){n.module=e,"account"==n.typeSign?n.changeType("wxapp"):n.changeType(n.typeSign)},n.changeType=function(e){n.loadData=!0,n.selectedAccount="",n.searchLinkAccount(n.module,e)},n.searchLinkAccount=function(e,t){n.activeTypeSign=t,setTimeout(function(){$("select").niceSelect&&$("select").niceSelect("update")},0),$("#show-account").modal("show"),a.post(i.links.search_link_account,{module_name:e,type_sign:t}).success(function(e){n.loadData=!1,0==e.message.errno?n.linkAccounts=e.message.message:util.message(e.message.message)})},n.selectLinkAccount=function(a){angular.forEach(n.linkAccounts,function(e,t){t==a.uniacid?n.linkAccounts[t].checked=1:n.linkAccounts[t].checked=0}),n.selectedAccount=a},n.module_unlink_uniacid=function(e){a.post(i.links.module_unlink_uniacid,{module_name:e}).success(function(e){e.message.errno,util.message(e.message.message,e.redirect)})},n.moduleLinkUniacid=function(){$("#show-account").modal("hide"),a.post(i.links.module_link_uniacid,{module_name:n.module,submit:"yes",token:i.token,uniacid:n.selectedAccount.uniacid}).success(function(e){0==e.message.errno?util.message("å…³è”æˆåŠŸ","refresh","success"):util.message(e.message.message)}),n.module=""}}]).controller("mcMessageListCtrl",["$scope","$http","config",function(e,a,n){e.lists=n.lists,e.getMessageInfo=function(e,t){window.location.href=n.getMessageInfoUrl+"&index="+e+"&msg_data_id="+t},e.switch=function(t){a.post(n.switchMessageUrl,{index:t.index,msg_data_id:t.msg_data_id,attach_id:t.attach_id,title:t.title,need_open_comment:t.need_open_comment}).success(function(e){0==e.message.errno?(t.need_open_comment=1==t.need_open_comment?0:1,util.message(e.message.message,"","success")):util.message(e.message.message,"","error")})}}]).controller("mcMessageInfoCtrl",["$scope","$http","config",function(e,a,n){e.comments=n.comments,e.selectedType=n.type,e.types=[{typeValue:0,typeName:"全部留言"},{typeValue:1,typeName:"普通留言"},{typeValue:2,typeName:"精选留言"}],e.searchComment=function(){$params="?index="+n.index+"&msg_data_id="+n.msg_data_id+"&type="+e.selectedType,window.location.href=n.getMessageInfoUrl+$params},e.replyarticle=function(e){e.replying=!e.replying},e.send=function(t){a.post(n.replyMessageUrl,{index:t.index,msg_data_id:t.msg_data_id,replycontent:t.replycontent,user_comment_id:t.user_comment_id}).success(function(e){0==e.message.errno?(t.replying=!1,util.message(e.message.message,"refresh","success")):util.message(e.message.message,"refresh","error")})},e.mark=function(t){a.post(n.markMessageUrl,{index:t.index,msg_data_id:t.msg_data_id,user_comment_id:t.user_comment_id,comment_type:t.comment_type}).success(function(e){0==e.message.errno?(t.comment_type=!t.comment_type,util.message(e.message.message,"","success")):util.message(e.message.message,"","error")})},e.del=function(t){a.post(n.delMessageUrl,{index:t.index,msg_data_id:t.msg_data_id,user_comment_id:t.user_comment_id}).success(function(e){0==e.message.errno?(t.reply="",util.message(e.message.message,"refresh","success")):util.message(e.message.message,"refresh","error")})},e.del_reply=function(t){a.post(n.delMessageReplyUrl,{index:t.index,msg_data_id:t.msg_data_id,user_comment_id:t.user_comment_id}).success(function(e){0==e.message.errno?(t.reply="",util.message(e.message.message,"refresh","success")):util.message(e.message.message,"refresh","error")})}}]).controller("fieldsListCtrl",["$scope","$http","config",function(e,n,i){e.account_member_fields=i.account_member_fields,e.changeAvailable=function(e,t,a){n.post(i.changeAvailableUrl,{id:e,available:t}).success(function(e){0==e.message.errno?util.message(e.message.message,"refresh","success"):util.message(e.message.message,"refresh","error")})},e.jumpTo=function(e){window.location.href=i.fieldPostUrl+"&id="+e}}]).controller("replySettingCtrl",["$scope","$http","config",function(e,t,a){e.times=a.times,e.saveSetting=function(){t.post(a.links.postUrl,{times:e.times}).success(function(e){0==e.message.errno?util.message("修改æˆåŠŸ!",e.redirect,"success"):util.message("修改失败!",e.redirect,"error")})}}]),angular.module("qrApp",["we7app"]),angular.module("qrApp").controller("QrDisplay",["$scope",function(e){}]),angular.module("qrApp").controller("QrPost",["$scope","$http","config",function(t,a,e){0<e.id?t.type=0:t.type=1,$(".we7-select").change(function(){var e=$(".we7-select").val();t.type=1==e?1:2,t.$apply(t.type)}),$.isFunction(window.initReplyController)&&window.initReplyController(t,a),$(".submit").on("click",function(){return!!t.checkSubmit()}),t.checkSubmit=function(){if(""==$(":text[name='scene-name']").val())return util.message("抱æ‰ï¼ŒäºŒç»´ç å称为必填项,请返回修改ï¼"),!1;if(1==t.type){if(""==$(":text[name='expire-seconds']").val())return util.message("抱æ‰ï¼Œä¸´æ—¶äºŒç»´ç 过期时间为必填项,请返回修改ï¼"),!1;if(!/^\+?[1-9][0-9]*$/.test($(":text[name='expire-seconds']").val()))return util.message("抱æ‰ï¼Œä¸´æ—¶äºŒç»´ç 过期时间必须为æ£æ•´æ•°ï¼Œè¯·è¿”回修改ï¼"),!1;if(parseInt($(":text[name='expire-seconds']").val())<30||2592e3<parseInt($(":text[name='expire-seconds']").val()))return util.message("抱æ‰ï¼Œä¸´æ—¶äºŒç»´ç 过期时间必须在30-2592000秒之间,请返回修改ï¼"),!1}if(2==t.type){var e=$.trim($("#scene_str").val());if(!e)return util.message("场景值ä¸èƒ½ä¸ºç©ºï¼"),!1;if(/^\d+$/g.test(e))return util.message("场景值ä¸èƒ½æ˜¯æ•°å—ï¼"),!1;a.post("{php echo url('platform/qr/check_scene_str')}",{scene_str:e}).success(function(e){if(1==e.message.errno&&"repeat"==e.message.message)return util.message("场景值和现有二维ç 场景值é‡å¤ï¼Œè¯·ä¿®æ”¹åœºæ™¯å€¼"),!1})}return""!=$(":hidden[name='reply[reply_keyword]']").val()||(util.message("抱æ‰ï¼Œè¯·é€‰æ‹©äºŒç»´ç è¦è§¦å‘的关键å—ï¼"),!1)}}]),angular.module("qrApp").controller("UrlToQr",["$scope","$http","config",function(e,t,n){e.copyLink="",e.selectUrl=function(){var a=$("#longurl");util.linkBrowser(function(e){var t=n.site_url;if("tel:"==e.substring(0,4))return util.message("长链接ä¸èƒ½è®¾ç½®ä¸ºä¸€é”®æ‹¨å·"),!1;-1==e.indexOf("http://")&&-1==e.indexOf("https://")&&(e=t+"app"+(e=e.replace("./index.php?","/index.php?"))),a.val(e)})},e.transformUrl=function(){var e=$("#longurl").val().trim();if(""==e)return util.message("请输入长链接"),!1;if(-1==e.indexOf("http://")&&-1==e.indexOf("https://")&&-1==e.indexOf("weixin://"))return util.message("请输入有效的长链接"),!1;var t=$("#change");t.html('<i class="fa fa-spinner"></i> 转æ¢ä¸'),$("#qrsrc").attr("src",n.img_url+"&url="+escape(e)),$("#shorturl").val(n.img_url+"&url="+escape(e)),$(".qr-img").next().removeClass("disabled"),$(".qr-img").next().attr("href",n.img_url+"&url="+escape(e)),t.html("ç«‹å³è½¬æ¢")},e.downQr=function(){var e=$("#shorturl").val(),t=n.down_url;window.location.href=t+"qrlink="+e},e.success=function(e){var e=parseInt(e),t=$('<span class="label label-success" style="position:absolute;height:33px;line-height:28px;"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>'),a=$("#copy-"+e).next().html();(!a||a.indexOf('<span class="label label-success" style="position:absolute;z-index:10"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>')<0)&&$("#copy-"+e).after(t),setTimeout(function(){t.remove()},2e3)}}]),angular.module("qrApp").controller("QrStatistics",["$scope","$http","config",function(e,t,a){e.link=a.link,e.changeStatus=function(){t.post(e.link.changeStatus,{}).success(function(e){0==e.message.errno?location.reload():util.message(e.message.message,e.redirect,"ajax")})}}]),angular.module("quickMenuApp",["wapeditorApp"]),angular.module("quickMenuApp").controller("MainCtrl",["$scope","config","serviceCommon","serviceQuickMenuBase","serviceQuickMenuSubmit",function(a,e,t,n,i){a.submit={},a.activeItem=e.activeItem||n.initActiveItem(),n.initActiveItem(a.activeItem),a.selectNavStyle=function(){var e=$('input[name="nav_style"]:checked').val();a.activeItem.navStyle=n.selectNavStyle(e)},a.addMenu=function(){a.activeItem.menus=n.addMenu()},a.addSubMenu=function(e){var t=_.findIndex(a.activeItem.menus,e);a.activeItem.menus[t].submenus=n.addSubMenu(e)},a.submit=function(e){a.submit=i.submit(),a.$apply("submit"),$(e.target).parents("form").submit()},a.removeMenu=function(e){a.activeItem.menus=n.removeMenu(e)},a.removeSubMenu=function(e,t){n.removeSubMenu(e,t),a.activeItem.menus[e].submenus=_.without(a.activeItem.menus[e].submenus,t)},a.showSearchModules=function(){a.moduleDialog=$("#shop-modules-modal").modal(),$("#shop-modules-modal .modal-body .btn-primary").html("å–消"),$("#shop-modules-modal").find(".modal-footer .btn-primary").unbind("click").click(function(){a.activeItem.ignoreModules={},$("#shop-modules-modal .modal-body .btn-primary").each(function(){a.hasIgnoreModules=!0,a.activeItem.ignoreModules[$(this).attr("js-name")]={name:$(this).attr("js-name"),title:$(this).attr("js-title")}}),a.$apply("activeItem"),a.$apply("hasIgnoreModules"),n.setQuickMenuData("ignoreModules",a.activeItem.ignoreModules)})},$(".js-editor-submit").click(function(e){a.submit(e)}),a.hasIgnoreModules=_.size(a.activeItem.ignoreModules),$(".nav-menu").show(),$(".app-shopNav-edit").show()}]),angular.module("quickMenuApp").service("serviceQuickMenuBase",["$rootScope",function(e){var t={},n={};return t.initActiveItem=function(e){return n=angular.isObject(e)?e:{navStyle:1,bgColor:"#2B2D30",menus:[],extend:[],position:{homepage:!0,usercenter:!0,page:!0,article:!0},ignoreModules:{}}},t.selectNavStyle=function(e){return n.navStyle=e,n.navStyle},t.addMenu=function(){return n.menus.push({title:"æ ‡é¢˜",url:"",submenus:[],icon:{name:"fa-home",color:"#00ffff"},image:"",hoverimage:"",hovericon:""}),n.menus},t.removeMenu=function(e){var t=$.inArray(e,n.menus),a=angular.copy(n.menus);for(i in n.menus=[],a)i!=t&&n.menus.push(a[i]);return n.menus},t.addSubMenu=function(e){e=_.findIndex(n.menus,e);return n.menus[e].submenus.push({title:"æ ‡é¢˜",url:""}),n.menus[e].submenus},t.removeSubMenu=function(e,t){return n.menus[e].submenus=_.without(n.menus[e].submenus,t),n.menus[e].submenus},t.getQuickMenuData=function(e){return angular.isString(e)?n[e]:n},t.setQuickMenuData=function(e,t){angular.isObject(e)?angular.forEach(e,function(e,t){n[t]=e}):n[e]=t},t}]),angular.module("quickMenuApp").service("serviceQuickMenuSubmit",["serviceCommon","serviceQuickMenuBase",function(a,n){var e={submit:function(){var e={params:{},html:""};e.params=n.getQuickMenuData(),a.stripHaskey(e.params);var t=$(".nav-menu").html();return t=(t=(t=(t=t.replace(/<\!\-\-([^-]*?)\-\->/g,"")).replace(/ng\-[a-zA-Z-]+=\"[^\"]*\"/g,"")).replace(/ng\-[a-zA-Z]+/g,"")).replace(/[\t\n\n\r]/g,""),e.html=t,e}};return e}]),angular.module("we7resource",["we7app"]),angular.module("we7resource").controller("we7resource-base-controller",["$scope","$sce","serviceResource","$http","config",function(a,e,n,t,i){function s(e){util.message(e)}function o(e){$(window).trigger("resource_selected",{type:a.resourceType,items:e})}a.currentPage=1,a.isWechat=i.isWechat,a.needType=i.needType,a.multiple=i.multiple,a.showType=i.showType,a.global=i.global?"global":"",a.dest_dir=i.dest_dir,a.uniacid=i.uniacid,a.netWorkVideo=i.netWorkVideo,i.others&&i.others[a.resourceType]&&(a.needType=i.others[a.resourceType].needType),a.selectedItems={},a.index=0,a.converting=!1,a.showWx=function(){return a.isWechat||1==a.showType||3==a.showType},a.showLocal=function(){return!a.isWechat||2==a.showType||3==a.showType},a.showNetWork=function(){return!0},a.loadData=function(){},a.onIndexChange=function(e){a.loadData()},a.setIndex=function(e){a.index!==e&&(a.index=e,a.selectedItems={},a.onIndexChange(e))},a.isWechat||a.setIndex(1),a.setCurrentPage=function(e){a.currentPage!=e&&(a.currentPage=e,a.loadData())},a.itemClick=function(e){if(!a.converting)if(e.selected)e.selected=!1;else{if(!a.multiple||a.needConvert())return e.selected=!0,void a.convert(e);e.selected=!e.selected,delete a.selectedItems[e.id],e.selected&&(a.selectedItems[e.id]=e)}},a.delItem=function(e,t){if(t.stopPropagation(),!confirm("åˆ é™¤ä¸å¯æ¢å¤ç¡®è®¤åˆ 除å—?"))return!1;n.delItem(e.id,a.resourceType,1==a.index,a.uniacid).then(function(){a.loadData()},function(e){util.message(e.message)})},a.canConvert=function(e){return!0},a.needConvert=function(){return 3!==a.needType&&a.index+1!==a.needType},a.convert=function(e){var t=0==a.index?"本地":"微信";if(a.needConvert()){if(!a.canConvert(e))return e.selected=!1,void s("当å‰èµ„æºæ— 法选择");confirm("当å‰èµ„æºè½¬æ¢ä¸º"+t+"ç´ ææ–¹å¯ä½¿ç”¨,是å¦è½¬æ¢")?(util.loading("æ£åœ¨è½¬æ¢ä¸º"+t+"资æº"),function(e){a.converting=!0;var t=2==a.needType;n.convert(e.id,a.resourceType,t).then(function(e){util.loaded(),a.converting=!1,e&&o([e]),e.selected=!1},function(){a.converting=!1,s("资æºè½¬æ¢å¤±è´¥"),e.selected=!1,util.loaded()})}(e)):e.selected=!1}else o([e])},a.ok=function(){var e,t=[];for(e in a.selectedItems)t.push(a.selectedItems[e]);0<t.length?o(t):$(window).trigger("resource_canceled")},a.uploaded=function(){a.loadData()},a.uploaderror=function(e){s(e=!e||""==e?"ä¸Šä¼ å¤±è´¥":e)},a.selectedItems=function(){return selectedItems}}]),angular.module("we7resource").directive("we7ResourceBasicDialog",["config",function(e){return{scope:{},restrict:"EA",templateUrl:"directive-basic-basic.html"}}]),angular.module("we7resource").controller("we7resource-basic-controller",["$scope","config",function(a,e){$("#basictext").val(e.otherVal),a.ok=function(){var e=$("#basictext").val();$(window).trigger("resource_selected",{type:"basic",items:[{content:e}]})},a.emotion=function(){t()},a.emoji=function(){n()},a.link={text:"",url:""},a.linkStatus=!1,a.showLink=function(){a.linkStatus=!a.linkStatus},a.changeLink=function(){var e,t;a.link.url&&(e=$("#basictext").val(),t='<a href="'+a.link.url+'">'+(a.link.text||a.link.url)+"</a>",$("#basictext").val(e+t),a.link={text:"",url:""},a.linkStatus=!1)};var t=function(){var o=$("#basictext")[0],r=$("#basictext").val();util.emotion($(".emotion-triggers"),$("#basictext"),function(e,t,a){var n,i,s;o.selectionStart&&"0"!=o.selectionStart?($("#basictext").val(r+e),$("#basictext").focus()):(n=o.selectionStart,i=o.selectionEnd,s=o.scrollTop,$("#basictext").val(o.value.substring(0,n)+e+o.value.substring(i,o.value.length)),$("#basictext").focus(),o.selectionStart=n+e.length,o.selectionEnd=n+e.length,o.scrollTop=s)})},n=function(){var t=$("#basictext").val();util.emojiBrowser(function(e){e="[U+"+e.find("span").text()+"]";$("#basictext").val(t+e)})}}]),angular.module("we7resource").directive("we7ResourceIconDialog",function(){return{scope:{},restrict:"EA",templateUrl:"directive-icon-icon.html"}}),angular.module("we7resource").controller("we7resource-icon-controller",["$scope","config",function(t,e){var a={c0:["fa-adjust","fa-anchor","fa-archive","fa-arrows","fa-arrows-h","fa-arrows-v","fa-asterisk","fa-automobile","fa-ban","fa-bank","fa-bar-chart-o","fa-barcode","fa-bars","fa-beer","fa-bell","fa-bell-o","fa-bolt","fa-bomb","fa-book","fa-bookmark","fa-bookmark-o","fa-briefcase","fa-bug","fa-building","fa-building-o","fa-bullhorn","fa-bullseye","fa-cab","fa-calendar","fa-calendar-o","fa-camera","fa-camera-retro","fa-car","fa-caret-square-o-down","fa-caret-square-o-left","fa-caret-square-o-right","fa-caret-square-o-up","fa-certificate","fa-check","fa-check-circle","fa-check-circle-o","fa-check-square","fa-check-square-o","fa-child","fa-circle","fa-circle-o","fa-circle-o-notch","fa-circle-thin","fa-clock-o","fa-cloud","fa-cloud-download","fa-cloud-upload","fa-code","fa-code-fork","fa-coffee","fa-cog","fa-cogs","fa-comment","fa-comment-o","fa-comments","fa-comments-o","fa-compass","fa-credit-card","fa-crop","fa-crosshairs","fa-cube","fa-cubes","fa-cutlery","fa-dashboard","fa-database","fa-desktop","fa-dot-circle-o","fa-download","fa-edit","fa-ellipsis-h","fa-ellipsis-v","fa-envelope","fa-envelope-o","fa-envelope-square","fa-eraser","fa-exchange","fa-exclamation","fa-exclamation-circle","fa-exclamation-triangle","fa-external-link","fa-external-link-square","fa-eye","fa-eye-slash","fa-fax","fa-female","fa-fighter-jet","fa-file-archive-o","fa-file-audio-o","fa-file-code-o","fa-file-excel-o","fa-file-image-o","fa-file-movie-o","fa-file-pdf-o","fa-file-photo-o","fa-file-picture-o","fa-file-powerpoint-o","fa-file-sound-o","fa-file-video-o","fa-file-word-o","fa-file-zip-o","fa-film","fa-filter","fa-fire","fa-fire-extinguisher","fa-flag","fa-flag-checkered","fa-flag-o","fa-flash","fa-flask","fa-folder","fa-folder-o","fa-folder-open","fa-folder-open-o","fa-frown-o","fa-gamepad","fa-gavel","fa-gear","fa-gears","fa-gift","fa-glass","fa-globe","fa-graduation-cap","fa-group","fa-hdd-o","fa-headphones","fa-heart","fa-heart-o","fa-history","fa-home","fa-image","fa-inbox","fa-info","fa-info-circle","fa-institution","fa-key","fa-keyboard-o","fa-language","fa-laptop","fa-leaf","fa-legal","fa-lemon-o","fa-level-down","fa-level-up","fa-life-bouy","fa-life-ring","fa-life-saver","fa-lightbulb-o","fa-location-arrow","fa-lock","fa-magic","fa-magnet","fa-mail-forward","fa-mail-reply","fa-mail-reply-all","fa-male","fa-map-marker","fa-meh-o","fa-microphone","fa-microphone-slash","fa-minus","fa-minus-circle","fa-minus-square","fa-minus-square-o","fa-mobile","fa-mobile-phone","fa-money","fa-moon-o","fa-mortar-board","fa-music","fa-navicon","fa-paper-plane","fa-paper-plane-o","fa-paw","fa-pencil","fa-pencil-square","fa-pencil-square-o","fa-phone","fa-phone-square","fa-photo","fa-picture-o","fa-plane","fa-plus","fa-plus-circle","fa-plus-square","fa-plus-square-o","fa-power-off","fa-print","fa-puzzle-piece","fa-qrcode","fa-question","fa-question-circle","fa-quote-left","fa-quote-right","fa-random","fa-recycle","fa-refresh","fa-reorder","fa-reply","fa-reply-all","fa-retweet","fa-road","fa-rocket","fa-rss","fa-rss-square","fa-search","fa-search-minus","fa-search-plus","fa-send","fa-send-o","fa-share","fa-share-alt","fa-share-alt-square","fa-share-square","fa-share-square-o","fa-shield","fa-shopping-cart","fa-sign-in","fa-sign-out","fa-signal","fa-sitemap","fa-sliders","fa-smile-o","fa-sort","fa-sort-alpha-asc","fa-sort-alpha-desc","fa-sort-amount-asc","fa-sort-amount-desc","fa-sort-asc","fa-sort-desc","fa-sort-down","fa-sort-numeric-asc","fa-sort-numeric-desc","fa-sort-up","fa-space-shuttle","fa-spinner","fa-spoon","fa-square","fa-square-o","fa-star","fa-star-half","fa-star-half-empty","fa-star-half-full","fa-star-half-o","fa-star-o","fa-suitcase","fa-sun-o","fa-support","fa-tablet","fa-tachometer","fa-tag","fa-tags","fa-tasks","fa-taxi","fa-terminal","fa-thumb-tack","fa-thumbs-down","fa-thumbs-o-down","fa-thumbs-o-up","fa-thumbs-up","fa-ticket","fa-times","fa-times-circle","fa-times-circle-o","fa-tint","fa-toggle-down","fa-toggle-left","fa-toggle-right","fa-toggle-up","fa-trash-o","fa-tree","fa-trophy","fa-truck","fa-umbrella","fa-university","fa-unlock","fa-unlock-alt","fa-unsorted","fa-upload","fa-user","fa-users","fa-video-camera","fa-volume-down","fa-volume-off","fa-volume-up","fa-warning","fa-wheelchair","fa-wrench"],c1:["fa-file","fa-file-archive-o","fa-file-audio-o","fa-file-code-o","fa-file-excel-o","fa-file-image-o","fa-file-movie-o","fa-file-o","fa-file-pdf-o","fa-file-photo-o","fa-file-picture-o","fa-file-powerpoint-o","fa-file-sound-o","fa-file-text","fa-file-text-o","fa-file-video-o","fa-file-word-o","fa-file-zip-o"],c2:["fa-circle-o-notch","fa-cog","fa-gear","fa-refresh","fa-spinner"],c3:["fa-check-square","fa-check-square-o","fa-circle","fa-circle-o","fa-dot-circle-o","fa-minus-square","fa-minus-square-o","fa-plus-square","fa-plus-square-o","fa-square","fa-square-o"],c4:["fa-bitcoin","fa-btc","fa-cny","fa-dollar","fa-eur","fa-euro","fa-gbp","fa-inr","fa-jpy","fa-krw","fa-money","fa-rmb","fa-rouble","fa-rub","fa-ruble","fa-rupee","fa-try","fa-turkish-lira","fa-usd","fa-won","fa-yen"],c5:["fa-align-center","fa-align-justify","fa-align-left","fa-align-right","fa-bold","fa-chain","fa-chain-broken","fa-clipboard","fa-columns","fa-copy","fa-cut","fa-dedent","fa-eraser","fa-file","fa-file-o","fa-file-text","fa-file-text-o","fa-files-o","fa-floppy-o","fa-font","fa-header","fa-indent","fa-italic","fa-link","fa-list","fa-list-alt","fa-list-ol","fa-list-ul","fa-outdent","fa-paperclip","fa-paragraph","fa-paste","fa-repeat","fa-rotate-left","fa-rotate-right","fa-save","fa-scissors","fa-strikethrough","fa-subscript","fa-superscript","fa-table","fa-text-height","fa-text-width","fa-th","fa-th-large","fa-th-list","fa-underline","fa-undo","fa-unlink"],c6:["fa-angle-double-down","fa-angle-double-left","fa-angle-double-right","fa-angle-double-up","fa-angle-down","fa-angle-left","fa-angle-right","fa-angle-up","fa-arrow-circle-down","fa-arrow-circle-left","fa-arrow-circle-o-down","fa-arrow-circle-o-left","fa-arrow-circle-o-right","fa-arrow-circle-o-up","fa-arrow-circle-right","fa-arrow-circle-up","fa-arrow-down","fa-arrow-left","fa-arrow-right","fa-arrow-up","fa-arrows","fa-arrows-alt","fa-arrows-h","fa-arrows-v","fa-caret-down","fa-caret-left","fa-caret-right","fa-caret-square-o-down","fa-caret-square-o-left","fa-caret-square-o-right","fa-caret-square-o-up","fa-caret-up","fa-chevron-circle-down","fa-chevron-circle-left","fa-chevron-circle-right","fa-chevron-circle-up","fa-chevron-down","fa-chevron-left","fa-chevron-right","fa-chevron-up","fa-hand-o-down","fa-hand-o-left","fa-hand-o-right","fa-hand-o-up","fa-long-arrow-down","fa-long-arrow-left","fa-long-arrow-right","fa-long-arrow-up","fa-toggle-down","fa-toggle-left","fa-toggle-right","fa-toggle-up"],c7:["fa-arrows-alt","fa-backward","fa-compress","fa-eject","fa-expand","fa-fast-backward","fa-fast-forward","fa-forward","fa-pause","fa-play","fa-play-circle","fa-play-circle-o","fa-step-backward","fa-step-forward","fa-stop","fa-youtube-play"],c8:["fa-adn","fa-android","fa-apple","fa-behance","fa-behance-square","fa-bitbucket","fa-bitbucket-square","fa-bitcoin","fa-btc","fa-codepen","fa-css3","fa-delicious","fa-deviantart","fa-digg","fa-dribbble","fa-dropbox","fa-drupal","fa-empire","fa-facebook","fa-facebook-square","fa-flickr","fa-foursquare","fa-ge","fa-git","fa-git-square","fa-github","fa-github-alt","fa-github-square","fa-gittip","fa-google","fa-google-plus","fa-google-plus-square","fa-hacker-news","fa-html5","fa-instagram","fa-joomla","fa-jsfiddle","fa-linkedin","fa-linkedin-square","fa-linux","fa-maxcdn","fa-openid","fa-pagelines","fa-pied-piper","fa-pied-piper-alt","fa-pinterest","fa-pinterest-square","fa-qq","fa-ra","fa-rebel","fa-reddit","fa-reddit-square","fa-renren","fa-share-alt","fa-share-alt-square","fa-skype","fa-slack","fa-soundcloud","fa-spotify","fa-stack-exchange","fa-stack-overflow","fa-steam","fa-steam-square","fa-stumbleupon","fa-stumbleupon-circle","fa-tencent-weibo","fa-trello","fa-tumblr","fa-tumblr-square","fa-twitter","fa-twitter-square","fa-vimeo-square","fa-vine","fa-vk","fa-wechat","fa-weibo","fa-weixin","fa-windows","fa-wordpress","fa-xing","fa-xing-square","fa-yahoo","fa-youtube","fa-youtube-play","fa-youtube-square"],c9:["fa-ambulance","fa-h-square","fa-hospital-o","fa-medkit","fa-plus-square","fa-stethoscope","fa-user-md","fa-wheelchair"]};t.index=0,t.color=e.otherVal||"#ddd",t.setIndex=function(e){t.index=e,t.selectIndex=-1},t.icons=function(){return a["c"+t.index]},util.colorpicker("#we7colorpicker",function(e){t.color=e.toString(),t.$apply("color")}),t.selectIndex=-1,t.itemClick=function(e){$(window).trigger("resource_selected",{type:"icon",items:[{name:e,color:t.color}]})}}]),angular.module("we7resource").directive("we7ResourceImageDialog",function(){return{scope:{},restrict:"EA",templateUrl:"directive-images-images.html",link:function(t,e,a,n,i){e.bind("click","pagination li a",function(e){e=$(e.target).attr("page");e&&t.$broadcast("image_page_change",e)})}}}),angular.module("we7resource").controller("we7resource-image-controller",["$compile","$scope","$sce","serviceResource","$http","$controller","config",function(n,s,a,o,e,t,r){s.resourceType="image",s.loading=!1,t("we7resource-base-controller",{$scope:s}),s.isWechat||(s.showType=2,s.needType=2,s.index=1),s.files=[],s.onprogress=function(e,t){},s.onUploadStart=function(e){s.loading=!0,s.files=e},s.uploaderror=function(e){s.loading=!1,i(e=!e||""==e?"ä¸Šä¼ å¤±è´¥":e)},s.accept="image/gif, image/jpg, image/jpeg, image/bmp, image/png, image/x-ico",s.uploadname="ä¸Šä¼ å›¾ç‰‡",s.multipleupload=!0,s.quality=0,s.netWorkurl="",s.groups=[],s.showSubGroups={};new Date;function i(e){util.message(e,"")}function l(e){$(window).trigger("resource_selected",{type:"image",items:e})}function c(){for(var e=[],t=u(),a=0;a<t.length;a++)e.push(t[a].id);return e}function u(){for(var e=[],t=0;t<s.images.length;t++){var a=s.images[t];a.selected&&e.push(a)}return e}function d(){var e=s.groupid;s.uploadurl=0==s.index?"./index.php?c=utility&a=file&do=wechat_upload&upload_type=image&mode=perm&uniacid="+s.uniacid+"&dest_dir="+s.dest_dir+"&quality="+s.quality+"&group_id="+e:"./index.php?c=utility&a=file&do=upload&upload_type=image&global="+s.global+"&dest_dir="+s.dest_dir+"&uniacid="+s.uniacid+"&quality="+s.quality+"&group_id="+e}function p(){m(s.groupid),g()}function m(e){s.selectedAllImage=!1,s.groupid=e,d();var t=1==s.index;o.getResources("image",s.currentPage,t,{year:s.year,month:s.month,uniacid:s.uniacid,dest_dir:s.dest_dir,global:s.global,group_id:e,keyword:s.keyword||"",order:s.order||""}).then(function(e){s.images=e.items,s.maxPage=Math.round(e.total/e.page_size),s.page.currentPage=e.page,s.page.totalItems=e.total,s.page.itemsPerPage=e.page_size,s.pager=a.trustAsHtml(e.pager),s.loading=!1})}function g(){var e=1==s.index,t={uniacid:r.uniacid||0};o.imageGroup(e,t).then(function(e){s.groups=e})}s.year="0",s.month="0",s.years=function(){for(var e=(new Date).getFullYear(),t=[],a=0;a<10;a++)t.push(e-a);return t}(),s.order="desc",s.months=function(){for(var e=[],t=1;t<=12;t++)e.push(t);return e}(),s.selectedAllImage=!1,s.groupid=-1,s.editable=!1,s.config=r,s.role=window.sysinfo.role,s.maxPage=1,s.images=[],s.page={currentPage:1,totalItems:0,itemsPerPage:10,pagesLength:10,onChange:function(){s.setCurrentPage(s.page.currentPage)}},""!=s.config.typeName&&null!=s.config.typeName&&null!=s.config.typeName||(s.config.typeName="å¹³å°"),setTimeout(function(){$(".material-head select").niceSelect&&$(".material-head select").niceSelect()}),s.getSelectedKeys=c,s.isLocal=function(){return 1==s.index},s.loadData=function(){p()},s.onIndexChange=function(e){2!=e&&(s.keyword="",s.order="desc",setTimeout(function(){$("select").niceSelect&&$("select").niceSelect("update")}),p(),d())},s.itemClick=function(e){s.converting||(e.selected=!e.selected,e=u().length==s.images.length,s.selectedAllImage=e)},s.ok=function(){var e=u();if(0<e.length)return!s.multiple||s.needConvert()?(e[0].selected=!0,void s.convert(e[0])):void l(e);$(window).trigger("resource_canceled")},d(),s.fetchNetwork=function(){var e=s.netWorkurl,t=2==s.needType;e=e,t=t,util.loading("网络图片转化ä¸..."),o.netWorkconvert(e,t,"image").then(function(e){util.loaded(),l([e])},function(e){i("网络图片转化失败"),util.loaded()})},s.$on("image_page_change",function(e,t){s.setCurrentPage(t)}),s.updateUploadUrl=function(){d()},s.timeToDate=function(e){return new Date(1e3*e)},s.getTitle=function(e){return s.isLocal?e.filename:e.attachment},s.getImage=function(e){return"url("+e.url+")"},s.search=function(){s.currentPage=1,p()},$("body").on("click",function(e){$("[aria-describedby^=popover]").each(function(){$(this).is(e.target)||0!==$(this).has(e.target).length||0!==$(".popover").has(e.target).length||$(this).popover("destroy")})}),$("body").on("show.bs.popover",".js-show-del",function(){$(this).closest(".js-show-action").addClass("show")}),$("body").on("shown.bs.popover",".js-show-del",function(){$("select[ng-model^=move]").niceSelect&&$("select[ng-model^=move]").niceSelect()}),$("body").on("hide.bs.popover",".js-show-del",function(){$(this).closest(".js-show-action").removeClass("show")}),s.showGroupAction=function(e,t){e.stopPropagation();e=$(e.target).closest(".js-show-action");$("[aria-describedby^=popover]").not(e).popover("destroy"),e.data("bs.popover")?e.popover("destroy"):e.popover({html:!0,placement:"auto bottom",title:"",template:'<div class="popover popover--material" role="tooltip"><div class="popover-content"></div></div>',trigger:"manual",container:"body",content:function(){var e='<div class="action-img-popover"><div class="action-img-popover__title">更多æ“作</div><div class="action-img-popover__content">',e=(e=!t.pid||0==t.pid?e+'<div class="action" ng-click="showRenameGroup($event, \'add\')" data-name="'+t.name+'" data-name-id="'+t.id+'"><i class="wi wi-copy color-default"></i>æ·»åŠ åˆ†ç»„</div>':e)+'<div class="action" ng-click="showRenameGroup($event)" data-name="'+t.name+'" data-name-id="'+t.id+'"><i class="wi wi-text color-default"></i>编辑分组</div><div class="action" ng-click="showDelGroup($event)" data-del-id="'+t.id+'"><i class="wi wi-delete2 color-red"></i>åˆ é™¤åˆ†ç»„</div></div></div>';return n(e)(s)}}).popover("show")},s.renameGroup="",s.showRenameGroup=function(t,a){t.stopPropagation(),s.renameGroup="";var e=$(t.target);$(t.target).data("nameId")&&(e=$(".group[data-action-id="+$(t.target).data("nameId")+"]").find(".js-show-del"),a||(s.renameGroup=$(t.target).data("name"))),$("[aria-describedby^=popover]").not(e).popover("destroy"),e.data("bs.popover")?e.popover("destroy"):e.popover({html:!0,placement:function(e,t){return $(t).position().top<280?"bottom":"top"},title:"",template:'<div class="popover popover--material" role="tooltip"><div class="popover-content"></div></div>',trigger:"manual",container:"body",content:function(){var e='<div class="name-img-popover"><div class="name-img-popover__title">分组管ç†</div><div class="name-img-popover__content we7-form"><div class="form-group"><label class="control-label col-sm-3">分组å称</label><div class="col-sm-9"><div class="input-group"><input type="text" class="form-control" ng-model="renameGroup"></div></div></div></div><div class="name-img-popover__footer"><button class="btn btn-primary" ng-disabled="!renameGroup" ng-click="editGroup(\''+(a||"")+"','"+($(t.target).data("nameId")?$(t.target).data("nameId"):"")+'\')">确定</button><button class="btn btn-default js-hide-popover" onclick=\'$("[aria-describedby^=popover]").popover("destroy")\'>å–消</button></div></div>';return n(e)(s)}}).popover("show")},s.editGroup=function(e,t){$("[aria-describedby^=popover]").popover("destroy");var a=1==s.index,n={uniacid:r.uniacid||0,pid:0};e&&(n.pid=t||0);var i={name:s.renameGroup};!e&&t?(i.id=t,o.changeGroup(i,a,n).then(function(e){g()})):o.addGroup(s.renameGroup,a,n).then(function(e){g()})},s.addGroup=function(e){$("[aria-describedby^=popover]").popover("destroy");var t=1==s.index,a={uniacid:r.uniacid||0};o.addGroup(e,t,a).then(function(e){g()})},s.showDelGroup=function(t){t.stopPropagation();var e=$(t.target);$(t.target).data("delId")&&(e=$(".group[data-action-id="+$(t.target).data("delId")+"]").find(".js-show-del")),$("[aria-describedby^=popover]").not(e).popover("destroy"),e.data("bs.popover")?e.popover("destroy"):e.popover({html:!0,placement:"auto bottom",title:"",template:'<div class="popover popover--material" role="tooltip"><div class="popover-content"></div></div>',trigger:"manual",container:"body",content:function(){var e='<div class="delete-img-popover"><div class="delete-img-popover__title"><i class="wi wi-info"></i>åˆ é™¤åˆ†ç»„</div><div class="delete-img-popover__content">ä»…åˆ é™¤åˆ†ç»„ï¼Œä¸åˆ 除图片,组内图片将自动归入未分组</div><div class="delete-img-popover__footer"><button class="btn btn-primary" ng-click="delGroup('+($(t.target).data("delId")?$(t.target).data("delId"):"")+')">åˆ é™¤</button><button class="btn btn-default js-hide-popover" onclick=\'$("[aria-describedby^=popover]").popover("destroy")\'>å–消</button></div></div>';return n(e)(s)}}).popover("show")},s.delGroup=function(e){if($("[aria-describedby^=popover]").popover("destroy"),!e)return!1;$("#categoryEditModal").hide(),e.deleted=!0;var t=1==s.index,a={uniacid:r.uniacid||0};o.delGroup(e,t,a).then(function(e){s.loadAll(),g()})},s.showAction=function(e,t){e.stopPropagation();e=$(e.target).closest(".js-show-action");$("[aria-describedby^=popover]").not(e).popover("destroy"),e.data("bs.popover")?e.popover("destroy"):e.popover({html:!0,placement:"auto bottom",title:"",template:'<div class="popover popover--material" role="tooltip"><div class="popover-content"></div></div>',trigger:"manual",container:"body",content:function(){var e='<div class="action-img-popover"><div class="action-img-popover__title">更多æ“作</div><div class="action-img-popover__content"><div class="action" ng-click="showRename($event)" data-name="'+t.filename+'" data-name-id="'+t.id+'"><i class="wi wi-text color-default"></i>编辑å称</div><div class="action" ng-click="showMove($event)" data-move-id="'+t.id+'"><i class="wi wi-insert color-default" ></i>移动分组</div><div class="action" ng-click="showDel($event)" data-del-id="'+t.id+'"><i class="wi wi-delete2 color-red"></i>åˆ é™¤å›¾ç‰‡</div></div></div>';return n(e)(s)}}).popover("show")},s.rename="",s.showRename=function(t){t.stopPropagation(),s.rename="";var e=$(t.target);$(t.target).data("nameId")&&(e=$("[data-action-id="+$(t.target).data("nameId")+"]").find(".js-show-del"),s.rename=$(t.target).data("name")),$("[aria-describedby^=popover]").not(e).popover("destroy"),e.data("bs.popover")?e.popover("destroy"):e.popover({html:!0,placement:"auto bottom",title:"",template:'<div class="popover popover--material" role="tooltip"><div class="popover-content"></div></div>',trigger:"manual",container:"body",content:function(){var e='<div class="name-img-popover"><div class="name-img-popover__title">图片管ç†</div><div class="name-img-popover__content we7-form"><div class="form-group"><label class="control-label col-sm-3">图片å称</label><div class="col-sm-9"><div class="input-group"><input type="text" class="form-control" ng-model="rename"></div></div></div></div><div class="name-img-popover__footer"><button class="btn btn-primary" ng-disabled="!rename" ng-click="renameImg('+($(t.target).data("nameId")?$(t.target).data("nameId"):"")+')">确定</button><button class="btn btn-default js-hide-popover" onclick=\'$("[aria-describedby^=popover]").popover("destroy")\'>å–消</button></div></div>';return n(e)(s)}}).popover("show")},s.renameImg=function(e){$("[aria-describedby^=popover]").popover("destroy"),o.changeName(e,s.rename,s.isLocal(),{uniacid:s.uniacid}).then(function(e){util.message("æ“作æˆåŠŸ","","success"),p()},function(e){util.message(e.message)})},s.showMove=function(t){t.stopPropagation();var e=$(t.target);$(t.target).data("moveId")&&(e=$("[data-action-id="+$(t.target).data("moveId")+"]").find(".js-show-del")),s.moveGroup="",s.moveGroupSub="",$("[aria-describedby^=popover]").not(e).popover("destroy"),e.data("bs.popover")?e.popover("destroy"):e.popover({html:!0,placement:function(e,t){return $(t).position().top<280?"bottom":"top"},title:"",template:'<div class="popover popover--material" role="tooltip"><div class="popover-content"></div></div>',trigger:"manual",container:"body",content:function(){var e='<div class="move-img-popover"><div class="move-img-popover__title">移动分组</div><div class="move-img-popover__content we7-form"><div class="form-group"><label class="control-label col-sm-3">一级分组</label><div class="col-sm-9"><select name="" class="" ng-model="moveGroup"><option value="">未分组</option><option value="{{value.id}}" ng-repeat="(key, value) in groups">{{value.name}}</option></select></div></div><div class="form-group"><label class="control-label col-sm-3">二级分组</label><div class="col-sm-9"><select name="" class="" ng-model="moveGroupSub"><option value="">放入一级</option><option value="{{sub_value.id}}" ng-repeat="(sub_key, sub_value) in groups[moveGroup].sub_group">{{sub_value.name}}</option></select></div></div></div><div class="move-img-popover__footer"><button class="btn btn-primary" ng-click="moveToGroup('+($(t.target).data("moveId")?$(t.target).data("moveId"):"")+')">确定</button><button class="btn btn-default js-hide-popover" onclick=\'$("[aria-describedby^=popover]").popover("destroy")\'>å–消</button></div></div>';return n(e)(s)}}).popover("show")},s.$watch("moveGroup",function(e){s.moveGroupSub="",setTimeout(function(){$("select").niceSelect&&$("select").niceSelect("update")})}),s.moveToGroup=function(e,t){$("[aria-describedby^=popover]").popover("destroy");var a=1==s.index,n=e?[e]:c();t=t||s.moveGroupSub||s.moveGroup,0!=n.length?(e={uniacid:r.uniacid||0},o.moveToGroup(n,t,a,e).then(function(e){util.message("移动æˆåŠŸ","","success"),m(t)})):util.message("请选择图片åŽç§»åŠ¨")},s.showDel=function(t){t.stopPropagation();var e=$(t.target);$(t.target).data("delId")&&(e=$("[data-action-id="+$(t.target).data("delId")+"]").find(".js-show-del")),$("[aria-describedby^=popover]").not(e).popover("destroy"),e.data("bs.popover")?e.popover("destroy"):e.popover({html:!0,placement:"auto bottom",title:"",template:'<div class="popover popover--material" role="tooltip"><div class="popover-content"></div></div>',trigger:"manual",container:"body",content:function(){var e='<div class="delete-img-popover"><div class="delete-img-popover__title"><i class="wi wi-info"></i>åˆ é™¤å›¾ç‰‡</div><div class="delete-img-popover__content">åˆ é™¤ä¸å¯æ¢å¤ç¡®è®¤åˆ 除å—?</div><div class="delete-img-popover__footer"><button class="btn btn-primary" ng-click="delSel('+($(t.target).data("delId")?$(t.target).data("delId"):"")+')">åˆ é™¤</button><button class="btn btn-default js-hide-popover" onclick=\'$("[aria-describedby^=popover]").popover("destroy")\'>å–消</button></div></div>';return n(e)(s)}}).popover("show")},s.delSel=function(e){if($("[aria-describedby^=popover]").popover("destroy"),e)t=[e];else{var t=c();if(0==t.length)return void util.message("请选择è¦åˆ 除的图片")}s.isLocal()?o.delMuti(t,"image",s.isLocal(),{uniacid:s.uniacid}).then(function(e){util.message("åˆ é™¤æˆåŠŸ","","success"),p()},function(e){util.message(e.message)}):o.delItem(t,"image",s.isLocal(),s.uniacid).then(function(e){util.message("åˆ é™¤æˆåŠŸ","","success"),p()},function(e){util.message(e.message)})},s.delItem=function(e,t){t.stopPropagation(),util.confirm(function(){s.isLocal()?o.delMuti(e.id,"image",s.isLocal(),{uniacid:s.uniacid}).then(function(e){util.message("åˆ é™¤æˆåŠŸ","","success"),p()},function(e){util.message(e.message)}):o.delItem(e.id,s.resourceType,1==s.index,s.uniacid).then(function(){s.loadData()},function(e){util.message(e.message)})},function(){return!1},"åˆ é™¤ä¸å¯æ¢å¤ç¡®è®¤åˆ 除å—?")},s.selectedAll=function(e){for(var t=0;t<s.images.length;t++)s.images[t].selected=e},s.loadAll=function(){s.setCurrentPage(1),m(-1)},s.loadNoGroup=function(){s.setCurrentPage(1),m(0)},s.loadImages=function(e){s.setCurrentPage(1),m(e.id)},s.doEditGroup=function(e){e.editable=!e.editable,s.loadImages(e)},s.editing=function(e){e.editing=!0},s.edited=function(e){e.editing=!1,e.editable=!1,s.editGroup(e)},s.cancelEditing=function(e){e.editing=!1,e.editable=!1},s.doAddGroup=function(){s.addGroup("未命å")},p()}]),angular.module("we7resource").directive("we7ResourceKeywordDialog",function(){return{scope:{},restrict:"EA",templateUrl:"directive-keyword-keyword.html",link:function(t,e,a,n,i){e.bind("click","pagination li a",function(e){e=$(e.target).attr("page");e&&t.$broadcast("keyword_page_change",e)})}}}),angular.module("we7resource").controller("we7resource-keyword-controller",["$scope","$sce","serviceResource",function(a,t,e){a.keyword="",a.currentId="",a.currentPage=1,a.itemClick=function(e){e.selected=!0,$(window).trigger("resource_selected",{type:"keyword",items:[e]})},a.$on("keyword_page_change",function(e,t){a.setCurrentPage(t)}),a.setCurrentPage=function(e){a.currentPage!==e&&(a.currentPage=e,n())},a.search=function(){a.currentPage=1,n()};var n=function(){e.getResources("keyword",a.currentPage,!0,{keyword:a.keyword}).then(function(e){a.keywords=e.items,a.pager=t.trustAsHtml(e.pager)})};n()}]),angular.module("we7resource").directive("we7ResourceModuleDialog",["$http",function(e){return{scope:{},restrict:"EA",templateUrl:"directive-module-module.html",link:function(t,e,a,n,i){e.bind("click","pagination li a",function(e){e=$(e.target).attr("page");e&&t.$broadcast("module_page_change",e)})}}}]),angular.module("we7resource").controller("we7resource-module-controller",["$scope","$sce","serviceResource","config",function(n,t,e,a){n.multiple=a.multiple,n.keyword="";var i=0,s=a.others,o="",r=!1;function l(){e.getResources("module",n.currentPage,!0,{keyword:n.keyword,user_module:i,uid:s.uid,module_uniacid:s.module_uniacid,mtype:o,cover:r}).then(function(e){n.modules=e.items,n.pager=t.trustAsHtml(e.pager)})}s&&s.user_module&&(i=1),s&&s.mtype&&(o=s.mtype),s&&s.cover&&(r=s.cover),n.itemClick=function(e){n.multiple?e.selected?e.selected=!1:e.selected=!0:(e.selected=!0,$(window).trigger("resource_selected",{type:"module",items:[e]}))},n.$on("module_page_change",function(e,t){n.setCurrentPage(t)}),n.setCurrentPage=function(e){n.currentPage!=e&&(n.currentPage=e,l())},n.search=function(){l()},n.ok=function(){var e,a=[];if(angular.forEach(n.modules,function(e,t){e.selected&&a.push(e)}),0<a.length)return e=a,void $(window).trigger("resource_selected",{type:"module",items:e});$(window).trigger("resource_canceled")},l()}]),angular.module("we7resource").directive("we7ResourceMusicDialog",function(){return{scope:{},restrict:"EA",replace:!1,templateUrl:"directive-music-music.html"}}),angular.module("we7resource").controller("we7resource-music-controller",["$scope","$sce","serviceResource","config",function(a,e,t,n){a.needType=n.needType,a.multiple=n.multiple,a.showMusicForm=!0,a.musicurl="",a.musicname="",a.selectVoice=function(){a.showMusicForm=!1};a.$on("selected_voice",function(e,t){a.musicurl=t.attachment,a.musicname=t.filename,a.showMusicForm=!0}),a.$on("add_music",function(e,t){$(window).trigger("resource_selected",{type:"music",items:[t]})})}]),angular.module("we7resource").directive("we7ResourceNewsDialog",function(){return{scope:{},restrict:"EA",templateUrl:"directive-news-news.html",link:function(t,e,a,n,i){e.bind("click","pagination li a",function(e){e=$(e.target).attr("page");e&&t.$broadcast("news_page_change",e)})}}}),angular.module("we7resource").controller("we7resource-news-controller",["$scope","$sce","serviceResource","$controller",function(a,t,e,n){function i(){e.getResources("news",a.currentPage,1==a.index,{keyword:a.keyword}).then(function(e){a.news=e.items,a.pager=t.trustAsHtml(e.pager)})}a.resourceType="news",n("we7resource-base-controller",{$scope:a}),a.keyword="",a.canConvert=function(e){return!e||!e.items||""!=e.items[0].author||""!=e.items[0].content},a.timeToDate=function(e){return new Date(1e3*e)},a.$on("news_page_change",function(e,t){a.setCurrentPage(t)}),a.loadData=function(){i()},a.search=function(){a.currentPage=1,i()},i()}]),angular.module("we7resource").directive("we7ResourceVideoDialog",function(){return{scope:{},restrict:"EA",templateUrl:"directive-video-video.html",link:function(t,e,a,n,i){e.bind("click","pagination li a",function(e){e=$(e.target).attr("page");e&&t.$broadcast("video_page_change",e)})}}}),angular.module("we7resource").controller("we7resource-video-controller",["$compile","$scope","$sce","serviceResource","config","$controller",function(a,n,t,i,e,s){function o(){n.selectedAllStatus=!1,i.getResources("video",n.currentPage,1==n.index,{uniacid:n.uniacid,global:n.global,keyword:n.keyword||"",order:n.order||""}).then(function(e){n.videos=e.items,n.pager=t.trustAsHtml(e.pager)})}n.resourceType="video",s("we7resource-base-controller",{$scope:n}),n.accept="video/rm, video/rmvb, video/wmv, video/avi, video/mpg, video/mpeg, video/mp4",n.uploadname="ä¸Šä¼ è§†é¢‘",n.multiupload=!1,n.keyword="",n.order="desc",n.selectedAllStatus=!1,n.videos=[],setTimeout(function(){$(".material-head select").niceSelect&&$(".material-head select").niceSelect()}),n.onIndexChange=function(e){n.keyword="",n.order="desc",setTimeout(function(){$("select").niceSelect&&$("select").niceSelect("update")}),o(),l()},n.search=function(){n.currentPage=1,o()},l(),n.showNetWork=function(){return n.netWorkVideo},n.loadData=function(){o()},n.sceurl=function(){return t.trustAsResourceUrl(n.netWorkurl)},n.canConvert=function(e){return!1},n.$on("video_page_change",function(e,t){n.setCurrentPage(t)}),n.getTitle=function(e){return e.tag&&e.tag.title||e.filename},n.fetchNetwork=function(){var e={url:function(e){{var t;/^<iframe/.test(e)&&(t="",/src=\"[^\s"]+/i.test(e)&&(t=e.match(/src=\"[^\s"]+/i)[0].substr(5)),e=/http:\/\/|https:\/\//gi.test(t)?t:"http://"+t)}return e}(n.netWorkurl),isRemote:!0};r("video",[e])},n.timeToDate=function(e){return new Date(1e3*e)},$("body").on("click",function(e){$("[aria-describedby^=popover]").each(function(){$(this).is(e.target)||0!==$(this).has(e.target).length||0!==$(".popover").has(e.target).length||$(this).popover("destroy")})}),$("body").on("show.bs.popover",".js-show-del",function(){$(this).closest(".js-show-action").addClass("show")}),$("body").on("shown.bs.popover",".js-show-del",function(){$("select[ng-model^=move]").niceSelect&&$("select[ng-model^=move]").niceSelect()}),$("body").on("hide.bs.popover",".js-show-del",function(){$(this).closest(".js-show-action").removeClass("show")}),n.itemSelect=function(e,t){e.stopPropagation(),t.selected=!t.selected;t=n.getSelectedKeys().length==n.videos.length;n.selectedAllStatus=t},n.selectedAll=function(e){for(var t=0;t<n.videos.length;t++)n.videos[t].selected=e},n.getSelectedKeys=function(){for(var e=[],t=0;t<n.videos.length;t++){var a=n.videos[t];a.selected&&e.push(a.id)}return e},n.showAction=function(e,t){e.stopPropagation();e=$(e.target).closest(".js-show-action");$("[aria-describedby^=popover]").not(e).popover("destroy"),e.data("bs.popover")?e.popover("destroy"):e.popover({html:!0,placement:"auto bottom",title:"",template:'<div class="popover popover--material" role="tooltip"><div class="popover-content"></div></div>',trigger:"manual",container:"body",content:function(){var e='<div class="action-img-popover"><div class="action-img-popover__title">更多æ“作</div><div class="action-img-popover__content"><div class="action" ng-click="showRename($event)" data-name="'+n.getTitle(t)+'" data-name-id="'+t.id+'"><i class="wi wi-text color-default"></i>编辑å称</div><div class="action" ng-click="showDel($event)" data-del-id="'+t.id+'"><i class="wi wi-delete2 color-red"></i>åˆ é™¤è§†é¢‘</div></div></div>';return a(e)(n)}}).popover("show")},n.rename="",n.showRename=function(t){t.stopPropagation(),n.rename="";var e=$(t.target);$(t.target).data("nameId")&&(e=$("[data-action-id="+$(t.target).data("nameId")+"]").find(".js-show-del"),n.rename=$(t.target).data("name")),console.log(e),$("[aria-describedby^=popover]").not(e).popover("destroy"),e.data("bs.popover")?e.popover("destroy"):e.popover({html:!0,placement:"auto bottom",title:"",template:'<div class="popover popover--material" role="tooltip"><div class="popover-content"></div></div>',trigger:"manual",container:"body",content:function(){var e='<div class="name-img-popover"><div class="name-img-popover__title">视频管ç†</div><div class="name-img-popover__content we7-form"><div class="form-group"><label class="control-label col-sm-3">视频å称</label><div class="col-sm-9"><div class="input-group"><input type="text" class="form-control" ng-model="rename"></div></div></div></div><div class="name-img-popover__footer"><button class="btn btn-primary" ng-disabled="!rename" ng-click="renameImg('+($(t.target).data("nameId")?$(t.target).data("nameId"):"")+')">确定</button><button class="btn btn-default js-hide-popover" onclick=\'$("[aria-describedby^=popover]").popover("destroy")\'>å–消</button></div></div>';return a(e)(n)}}).popover("show")},n.renameImg=function(e){if(1!=n.index)return util.message("ä¸æ”¯æŒä¿®æ”¹å¾®ä¿¡ç´ æå称"),!1;$("[aria-describedby^=popover]").popover("destroy"),i.changeName(e,n.rename,1==n.index,{uniacid:n.uniacid}).then(function(e){util.message("æ“作æˆåŠŸ","","success"),o()},function(e){util.message(e.message)})},n.showDel=function(t){t.stopPropagation();var e=$(t.target);$(t.target).data("delId")&&(e=$("[data-action-id="+$(t.target).data("delId")+"]").find(".js-show-del")),$("[aria-describedby^=popover]").not(e).popover("destroy"),e.data("bs.popover")?e.popover("destroy"):e.popover({html:!0,placement:"auto bottom",title:"",template:'<div class="popover popover--material" role="tooltip"><div class="popover-content"></div></div>',trigger:"manual",container:"body",content:function(){var e='<div class="delete-img-popover"><div class="delete-img-popover__title"><i class="wi wi-info"></i>åˆ é™¤è§†é¢‘</div><div class="delete-img-popover__content">åˆ é™¤ä¸å¯æ¢å¤ç¡®è®¤åˆ 除å—?</div><div class="delete-img-popover__footer"><button class="btn btn-primary" ng-click="delSel('+($(t.target).data("delId")?$(t.target).data("delId"):"")+')">åˆ é™¤</button><button class="btn btn-default js-hide-popover" onclick=\'$("[aria-describedby^=popover]").popover("destroy")\'>å–消</button></div></div>';return a(e)(n)}}).popover("show")},n.delSel=function(e){if($("[aria-describedby^=popover]").popover("destroy"),e)t=[e];else{var t=n.getSelectedKeys();if(0==t.length)return void util.message("请选择è¦åˆ 除的视频")}1==n.index?i.delMuti(t,"video",1==n.index,{uniacid:n.uniacid}).then(function(e){util.message("åˆ é™¤æˆåŠŸ","","success"),n.currentPage=1,o()},function(e){util.message(e.message)}):i.delItem(t,"video",1==n.index,n.uniacid).then(function(e){util.message("åˆ é™¤æˆåŠŸ","","success"),n.currentPage=1,o()},function(e){util.message(e.message)})};var r=function(e,t){$(window).trigger("resource_selected",{type:"video",items:t})};function l(){n.uploadurl=0===n.index?"./index.php?c=utility&a=file&do=wechat_upload&upload_type=video&mode=perm&uniacid="+n.uniacid:"./index.php?c=utility&a=file&do=upload&upload_type=video&global="+n.global+"&dest_dir="+n.dest_dir+"&uniacid="+n.uniacid}o()}]),angular.module("we7resource").directive("we7ResourceVoiceDialog",function(){return{scope:{},restrict:"EA",templateUrl:"directive-voice-voice.html",link:function(e,t,a,n,i){}}}),angular.module("we7resource").controller("we7resource-voice-controller",["$scope",function(e){e.$on("selected_voice",function(e,t){t&&!t.url&&(t.url=t.attachment),$(window).trigger("resource_selected",{type:"voice",items:[t]})})}]),angular.module("we7resource").directive("we7ResourceWxappDialog",function(){return{scope:{},restrict:"EA",replace:!1,templateUrl:"directive-wxapp-wxapp.html"}}),angular.module("we7resource").controller("we7resource-wxapp-controller",["$scope","$sce","config",function(e,t,a){e.wxapp={title:"",appid:"",pagepath:"",mediaid:"",mediaUrl:""},e.image={},e.showWxapp=!0,a.otherVal&&a.otherVal.image?(e.wxapp=$.extend({},e.wxapp,JSON.parse(window.sessionStorage.getItem("we7-platform-reply-wxapp-info"))),e.wxapp.mediaid=a.otherVal.image.media_id,e.wxapp.mediaUrl=a.otherVal.image.url):window.sessionStorage.setItem("we7-platform-reply-wxapp-info",JSON.stringify(e.wxapp)),e.showImage=function(){window.sessionStorage.setItem("we7-platform-reply-wxapp-info",JSON.stringify(e.wxapp)),e.showWxapp=!1},e.add_wxapp=function(){window.sessionStorage.setItem("we7-platform-reply-wxapp-info",""),$(window).trigger("resource_selected",{type:"wxapp",items:[e.wxapp]})}}]),angular.module("we7resource").service("serviceResource",["$rootScope","$http","$q",function(e,o,r){var t={};function s(e,t,a,n){var i=r.defer(),s=i.promise,n="./index.php?c=utility&a=file&do="+e+"&page="+t+"&local="+(a?"local":"wx")+l(n);return o.get(n).then(function(e){200!=e.status||"0"==(e=e.data.message).errno&&(e.message.items,i.resolve(e.message)),i.resolve([])},function(e){i.reject(e)}),s}function l(e){var a="";return angular.forEach(e,function(e,t){a+="&"+t+"="+e}),a}return t.getResources=function(e,t,a,n){var i=null;switch(e){case"keyword":i=s("keyword",t,!0,n);break;case"module":i=s("module",t,!0,n);break;case"video":i=s("video",t,a,n);break;case"news":i=s("news",t,a,n);break;case"voice":i=s("voice",t,a,n);break;case"image":i=s("image",t,a,n)}return i},t.imageGroup=function(e,t){var a=r.defer(),n=a.promise,t="./index.php?c=utility&a=file&do=group_list&local="+(e?"local":"wx")+l(t);return o.get(t).then(function(e){200==e.status&&("0"!=(e=e.data.message).errno?a.reject({state:!1,message:e.message}):a.resolve(e.message))}),n},t.addGroup=function(e,t,a){var n=r.defer(),i=n.promise,a="./index.php?c=utility&a=file&do=add_group&local="+(t?"local":"wx")+l(a);return o.post(a,{name:e}).then(function(e){if(200==e.status){e=e.data.message;if("0"==e.errno)return void n.resolve(e.message);n.reject({state:!1,message:e.message})}n.reject({state:!1,message:"æ·»åŠ å¤±è´¥"})},function(e){n.reject({state:!1,message:"æ·»åŠ å¤±è´¥"})}),i},t.changeGroup=function(e,t,a){var n=r.defer(),i=n.promise,a="./index.php?c=utility&a=file&do=change_group&local="+(t?"local":"wx")+l(a);return o.post(a,{name:e.name,id:e.id}).then(function(e){if(200==e.status){e=e.data.message;if("0"==e.errno)return void n.resolve(e.message);n.reject({state:!1,message:e.message})}n.reject({state:!1,message:"更新失败"})},function(e){n.reject({state:!1,message:"更新失败"})}),i},t.delGroup=function(e,t,a){var n=r.defer(),i=n.promise,a="./index.php?c=utility&a=file&do=del_group&local="+(t?"local":"wx")+l(a);return o.post(a,{group_id:e}).then(function(e){if(200==e.status){e=e.data.message;if("0"==e.errno)return void n.resolve(e.message);n.reject({state:!1,message:e.message})}n.reject({state:!1,message:"åˆ é™¤å¤±è´¥"})},function(e){n.reject({state:!1,message:"åˆ é™¤å¤±è´¥"})}),i},t.moveToGroup=function(e,t,a,n){var i=r.defer(),s=i.promise,n="./index.php?c=utility&a=file&do=move_to_group&local="+(a?"local":"wx")+l(n);return o.post(n,{group_id:t,id:e}).then(function(e){if(200==e.status){e=e.data.message;if("0"==e.errno)return void i.resolve(e.message);i.reject({state:!1,message:e.message})}i.reject({state:!1,message:"移动æˆåŠŸ"})},function(e){i.reject({state:!1,message:"移动失败"})}),s},t.delMuti=function(e,t,a,n){var i=r.defer(),s=i.promise,n="./index.php?c=utility&a=file&do=delete&local="+(a?"local":"wx")+l(n);return o.post(n,{id:e,type:t}).then(function(e){if(200==e.status){e=e.data.message;if("0"==e.errno)return void i.resolve(!0);i.reject({state:!1,message:e.message})}i.reject({state:!1,message:"åˆ é™¤å¤±è´¥"})},function(e){i.reject({state:!1,message:"åˆ é™¤å¤±è´¥"})}),s},t.changeName=function(e,t,a,n){var i=r.defer(),s=i.promise,n="./index.php?c=utility&a=file&do=change_name&local="+(a?"local":"wx")+l(n);return o.post(n,{id:e,new_filename:t}).then(function(e){if(200==e.status){e=e.data.message;if("0"==e.errno)return void i.resolve(!0);i.reject({state:!1,message:e.message})}i.reject({state:!1,message:"åˆ é™¤å¤±è´¥"})},function(e){i.reject({state:!1,message:"åˆ é™¤å¤±è´¥"})}),s},t.delItem=function(e,t,a,n){var i=r.defer(),s=i.promise;return o.post("./index.php?c=platform&a=material&do=delete&uniacid="+n,{material_id:e,type:t,server:a?"local":"wechat"}).then(function(e){if(200==e.status){e=e.data.message;if("0"==e.errno)return void i.resolve(!0);i.reject({state:!1,message:e.message||e})}i.reject({state:!1,message:"åˆ é™¤å¤±è´¥"})},function(e){i.reject({state:!1,message:"åˆ é™¤å¤±è´¥"})}),s},t.convert=function(e,t,a){var n=r.defer(),i=n.promise;return o.get("./index.php?c=utility&a=file&do="+(a?"tolocal":"towechat")+"&type="+t+"&resource_id="+e).then(function(e){var t;200==e.status&&(0==(t=e.data.message).errno&&(e=t.message,n.resolve(e)),1==t.errno&&n.reject(t.message)),n.resolve(null)},function(e){n.reject(e)}),i},t.netWorkconvert=function(e,t,a){var n=r.defer(),i=n.promise,a="./index.php?c=utility&a=file&do="+(t?"networktolocal":"networktowechat")+"&url="+encodeURIComponent(e)+"&type="+a;return o.get(a).then(function(e){var t;200==e.status&&(0==(t=e.data.message).errno&&(e=t.message,n.resolve(e)),1==t.errno&&n.reject(t.message)),n.resolve(null)},function(e){n.reject(e)}),i},t}]),we7ResourceMusicFormController.$inject=["$scope"],angular.module("we7resource").component("we7ResourceMusicform",{templateUrl:"widget-musicform-musicform.html",bindToController:!0,controller:we7ResourceMusicFormController,bindings:{doselect:"&",musicurl:"<",musicname:"<"}}),UploadController.$inject=["$scope","$sce","uiUploader","$timeout"],angular.module("we7resource").component("we7UploaderBtn",{templateUrl:"widget-upload-upload.html",controller:UploadController,transclude:!0,replace:!0,bindings:{name:"<",uploadUrl:"<",accept:"<",onUploadStart:"&",onUploading:"&",onUploaded:"&",onUploadError:"&",onProgress:"&",multiple:"<"}}),uiUploader.$inject=["$log","$q"],angular.module("we7resource").service("uiUploader",["$log","$q",uiUploader]),VoiceController.$inject=["$compile","$scope","$sce","serviceResource","$controller","$element"],angular.module("we7resource").component("we7ResourceVoice",{templateUrl:"widget-voice-voice.html",controller:VoiceController,transclude:!0,bindings:{isWechat:"<",showType:"<"}}),angular.module("wesiteApp",["we7app"]),angular.module("wesiteApp").controller("WesiteDisplay",["$scope","$http","serviceCommon","config",function(n,i,a,e){n.default_site=e.default_site,n.multis=e.multis,n.links=e.links,angular.forEach(n.multis,function(e,t){e.copyLink=n.links.appHome+"t="+e.id}),n.preview=function(e){var e=parseInt(e),t=util.dialog("预览模æ¿",'<iframe width="320px" scrolling="yes" height="480px" frameborder="0" src="about:blank"></iframe>','<button type="button" class="btn btn-default" data-dismiss="modal">å…³é—</button>'),e=n.links.appHome+"&t="+e;t.find("iframe").attr("src",e),t.find(".modal-dialog").css({width:"322px"}),t.find(".modal-body").css({padding:"0",height:"480px"}),t.modal("show")},n.switchOn=function(e,t){var a=_.indexOf(n.multis,e),t=parseInt(t);-1<a&&i.post(n.links.switch,{id:t}).success(function(e){0==e.message.errno&&(n.multis[a].status=1==n.multis[a].status?"0":"1",util.message("修改æˆåŠŸï¼","","success"))})},n.success=function(e){var e=parseInt(e),t=$('<span class="label label-success" style="position:absolute;z-index:10"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>');a.copySuccess(e,t)},n.deleteMulti=function(e,t){e=e+"&id="+t;util.confirm(function(){window.location.href=e},function(){return!1},"ç¡®è®¤åˆ é™¤å—?")}}]),angular.module("wesiteApp").controller("WesitePost",["$scope","config","$http","serviceCommon","serviceHomeMenuBase","serviceQuickMenuBase","serviceQuickMenuSubmit",function(i,e,s,a,t,n,o){i.links=e.links,i.attachurl=e.attachurl,i.default_site=e.default_site,i.temtypes=e.temtypes,i.temtype={name:"all",title:"全部"},i.searchedStyleName="",i.multi=e.multi,i.styles=e.styles,i.siteEntrance=i.links.murl+"t="+i.multi.id,i.slideLists=[],i.showSlideSubmit=!1,i.addHomemenuStatus=!1,i.homeMenu=[],i.sections=t.initSections(),i.menuInfo=t.initHomemenuInfo(),i.activeItem={},i.modules={},i.quickMenuStatus=!0,i.hasIgnoreModules=0,i.submit={},i.success=function(e){var e=parseInt(e),t=$('<span class="label label-success" style="position:absolute;z-index:10;width:90px;height:34px;line-height:28px;"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>');a.copySuccess(e,t)},i.selectStyle=function(e){i.multi.style=e},i.searchStyle=function(){s.post(i.links.searchStyleLink,{name:i.searchedStyleName}).success(function(e){0==e.message.errno&&(i.styles=e.message.message)})},i.changeMultiStatus=function(){i.multi.status=1==i.multi.status?0:1},i.uploadMultiImage=function(){require(["fileUploader"],function(e){e.init(function(e){i.multi.site_info.thumb=e.url,i.$apply(i.multi.site_info)},{direct:!0,multiple:!1})})},i.delMultiImage=function(){i.multi.site_info.thumb=""},i.loadSlideInfo=function(){s.post(i.links.slideDisplay,{multiid:e.multiid}).success(function(e){0==e.message.errno&&(i.slideLists=e.message.message,_.isEmpty(i.slideLists)||(i.showSlideSubmit=!0))})},i.addSlide=function(){i.slideLists.push({title:"",displayorder:0,thumb:"",url:""}),i.showSlideSubmit=!0},i.delSlide=function(e){e=_.indexOf(i.slideLists,e);-1<e&&(i.slideLists=_.without(i.slideLists,i.slideLists[e])),_.isEmpty(i.slideLists)&&(i.showSlideSubmit=!1)},i.uploadSlideImage=function(e){var t=_.indexOf(i.slideLists,e);-1<t?require(["fileUploader"],function(e){e.init(function(e){i.slideLists[t].thumb=e.url,i.$apply(i.slideLists)},{direct:!0,multiple:!1})}):util.message("å‚数错误,请刷新页é¢é‡è¯•ï¼")},i.delSlideImage=function(e){e=_.indexOf(i.slideLists,e);-1<e&&(i.slideLists[e].thumb="")},i.saveSlide=function(){s.post(i.links.slidePost,{slide:i.slideLists,multiid:e.multiid}).success(function(e){0==e.message.errno?util.message(e.message.message,"","success"):util.message(e.message.message)})},i.loadHomemenuInfo=function(){s.post(i.links.homeMenuDisplay,{multiid:e.multiid},{cache:!1}).success(function(e){0==e.message.errno&&(i.homeMenu=e.message.message,i.addHomemenuStatus=!1)})},i.changeHomemenuStatus=function(e){i.addHomemenuStatus=!i.addHomemenuStatus,_.isEmpty(e)?i.menuInfo=t.initHomemenuInfo():(i.menuInfo=e,e=parseInt(i.menuInfo.section),i.menuInfo.section=i.sections[e=e<=10&&0<=e?e:0],_.isEmpty(i.menuInfo.icon)?i.menuInfo.icontype=1:i.menuInfo.icontype=2)},i.updateMenu=function(t,e){var a=parseInt(t.id),n=_.indexOf(i.homeMenu,t);if(-1<n)switch(e){case"del":s.post(i.links.homeMenuDel,{id:a}).success(function(e){0==e.message.errno?(util.message("åˆ é™¤æˆåŠŸï¼","","success"),i.homeMenu=_.without(i.homeMenu,t)):(-1==e.message.errno&&util.message("本公众å·ä¸å˜åœ¨è¯¥å¯¼èˆªï¼"),1==e.message.errno&&util.message("åˆ é™¤å¤±è´¥ï¼Œè¯·ç¨å€™é‡è¯•ã€‚"))});break;case"switch":s.post(i.links.homeMenuSwith,{id:a}).success(function(e){0==e.message.errno?i.homeMenu[n].status=!i.homeMenu[n].status:(-1==e.message.errno&&util.message("本公众å·ä¸å˜åœ¨è¯¥å¯¼èˆªï¼"),1==e.message.errno&&util.message("更新失败,请ç¨å€™é‡è¯•ã€‚"))})}},i.uploadHomemenuImage=function(e){require(["fileUploader"],function(e){e.init(function(e){i.menuInfo.icon=e.attachment,i.$apply(i.menuInfo)},{direct:!0,multiple:!1})})},i.delHomemenuImage=function(e){i.menuInfo.icon=""},i.selectHomemenuIcon=function(){util.iconBrowser(function(e){i.menuInfo.css.icon.icon=e,i.$apply(i.menuInfo.css)})},i.saveMenu=function(){s.post(i.links.homeMenuPost,{menu_info:i.menuInfo,multiid:e.multiid}).success(function(e){0==e.message.errno?(util.message("导航èœå•ä¿å˜æˆåŠŸï¼","","success"),i.loadHomemenuInfo()):(1==e.message.errno&&util.message("ä¿å˜å¤±è´¥ï¼"),-1==e.message.errno&&util.message("抱æ‰ï¼Œè¯·è¾“入导航èœå•çš„å称ï¼"))})},i.successMenu=function(e){var e=parseInt(e),t=$('<span class="label label-success" style="position:absolute;z-index:10;width:80px;margin-left:10px"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>');a.copySuccess(e,t)},i.quickMenuSwitch=function(){i.quickMenuStatus=!i.quickMenuStatus},i.loadQuickmenuInfo=function(){s.post(i.links.quickMenuDisplay,{multiid:e.multiid}).success(function(e){0==e.message.errno?(i.activeItem=e.message.message.params,i.activeItem?i.activeItem.position?(i.activeItem.position.homepage=!!i.activeItem.position.homepage,i.activeItem.position.page=!!i.activeItem.position.page,i.activeItem.position.article=!!i.activeItem.position.article):i.activeItem.position={homepage:!1,page:!1,article:!1}:i.activeItem={position:{homepage:!1,page:!1,article:!1}},n.initActiveItem(i.activeItem),i.modules=e.message.message.modules,i.quickMenuStatus=e.message.message.status,i.hasIgnoreModules=_.size(i.activeItem.ignoreModules)):util.message("请求错误:微站ä¸å˜åœ¨ï¼Œè¯·æŒ‰â€œCtrl+F5â€åˆ·æ–°é‡è¯•ï¼")})},i.saveQucikMenu=function(){i.submit=o.submit(),s.post(i.links.quickMenuPost,{multiid:e.multiid,postdata:i.submit,status:i.quickMenuStatus?1:0}).success(function(e){0==e.message.errno?util.message("ä¿å˜æˆåŠŸã€‚您å¯ç‚¹å‡»â€œé¢„览刷新â€æŸ¥çœ‹æ•ˆæžœï¼","","success"):util.message(e.message.message)})},i.showSearchModules=function(){i.moduleDialog=$("#shop-modules-modal").modal(),$("#shop-modules-modal .modal-body .btn-primary").html("å–消"),$("#shop-modules-modal").find(".modal-footer .btn-primary").unbind("click").click(function(){i.activeItem.ignoreModules={},$("#shop-modules-modal .modal-body .btn-primary").each(function(){i.hasIgnoreModules=!0,i.activeItem.ignoreModules[$(this).attr("js-name")]={name:$(this).attr("js-name"),title:$(this).attr("js-title")}}),i.$apply("activeItem"),i.$apply("hasIgnoreModules"),n.setQuickMenuData("ignoreModules",i.activeItem.ignoreModules)})},i.selectNavStyle=function(){var e=$('#shop-nav-modal .alert input[type="radio"]:checked').val();i.activeItem.navStyle=n.selectNavStyle(e)},i.addMenu=function(){i.activeItem.menus=n.addMenu()},i.addSubMenu=function(e){var t=_.findIndex(i.activeItem.menus,e);i.activeItem.menus[t].submenus=n.addSubMenu(e)},i.removeMenu=function(e){i.activeItem.menus=n.removeMenu(e)},i.removeSubMenu=function(e,t){n.removeSubMenu(e,t),i.activeItem.menus[e].submenus=_.without(i.activeItem.menus[e].submenus,t)}}]),angular.module("wesiteApp").controller("WesiteTplDidplay",["$scope","config",function(n,e){n.stylesResult=e.stylesResult,n.temtypes=e.temtypes,n.type=e.type,n.setting=e.setting,n.links=e.links,n.preview=function(a){var a=parseInt(a),e='\t\t\t<a href="'+n.links.default+"&styleid="+a+'" class="btn btn-primary">设为默认模æ¿</a>\t\t\t<a href="'+n.links.designer+"&styleid="+a+'" class="btn btn-primary">è®¾è®¡é£Žæ ¼</a>\t\t\t<button type="button" class="btn btn-default" data-dismiss="modal">å…³é—</button>',t=util.dialog("预览模æ¿",'<iframe width="320" scrolling="yes" height="480" frameborder="0" src="about:blank"></iframe>',e);t.find("iframe").on("load",function(){$("a",this.contentWindow.document.body).each(function(){var e,t=$(this).attr("href");t&&"#"!=t[0]&&("&"!=(t=(e=t.split(/#/g))[0]).slice(-1)&&(t+="&"),-1!=t.indexOf("?")&&(t+="s="+a),e[1]&&(t+="#"+e[1]),"javascript"!=t.substr(0,10)&&-1!=t.indexOf("?")||(t=t.substr(0,t.lastIndexOf("&"))),$(this).attr("href",t))})});e=n.links.home+"&s="+a;t.find("iframe").attr("src",e),t.find(".modal-dialog").css({width:"322px"}),t.find(".modal-body").css({padding:"0",height:"480px"}),t.modal("show")},n.selectDefault=function(e){e=parseInt(e);location.href=n.links.default+"&styleid="+e},n.deleteStyle=function(e,t){util.confirm(function(){window.location.href=e+"&styleid="+t},function(){return!1},"ç¡®è®¤åˆ é™¤å—?")}}]),angular.module("wesiteApp").controller("WesiteTplPost",["$scope","config",function(a,e){a.style=e.style,a.styles=e.styles||{},a.template=e.template,a.systemtags=e.systemtags,a.customStyles=[],angular.forEach(a.styles,function(e,t){-1==_.indexOf(a.systemtags,e.variable)&&a.customStyles.push(e)}),a.addCustomAttribute=function(){$("#customForm").append($("#item-form-html").html())},a.delCustomArrtibute=function(e){$(e.target).parent().parent().remove()},a.uploadImage=function(){require(["fileUploader"],function(e){e.init(function(e){a.styles.indexbgimg={content:e.url},a.$apply(a.styles.indexbgimg.content)},{direct:!0,multiple:!1})})},a.delImage=function(){a.styles.indexbgimg=""},a.checkSubmit=function(e){for(var t=$(':text[name="custom[name][]"]'),a=$(':text[name="custom[desc][]"]'),n=$(':text[name="custom[value][]"]'),i=0;i<t.length;i++)if(_.isEmpty(t[i].value))return util.message("自定义属性å˜é‡åä¸å¯ä¸ºç©ºï¼"),!1;for(var s=0;s<a.length;s++)if(_.isEmpty(a[s].value))return util.message("自定义属性å˜é‡æè¿°ä¸å¯ä¸ºç©ºï¼"),!1;for(var o=0;o<n.length;o++)if(_.isEmpty(n[o].value))return util.message("自定义属性å˜é‡å€¼ä¸å¯ä¸ºç©ºï¼"),!1;$("#submit-post").click()}}]),angular.module("wesiteApp").controller("wesiteArticleDisplay",["$scope","config","serviceCommon","$http",function(i,s,a,e){i.category=s.category,i.articleList=s.articleList,i.commentListLink=s.commentListLink,i.articleComment=s.articleComment,i.setting=s.setting,i.commentLink=s.commentLink,angular.forEach(i.articleList,function(e,t){var a;0!=e.pcate?(a=parseInt(e.pcate),0!=e.ccate?(n=parseInt(e.ccate),angular.isDefined(i.category[a])&&angular.isDefined(i.category[n])&&(e.title="ã€"+i.category[a].name+"】-ã€"+i.category[n].name+"】"+e.title)):angular.isDefined(i.category[a])&&(e.title="ã€"+i.category[a].name+"】"+e.title)):0!=e.ccate&&(n=parseInt(e.ccate),angular.isDefined(i.category[n])&&(e.title="ã€"+i.category[n].name+"】"+e.title)),e.link=s.copyCommonLink+e.id;var n=i.articleComment;e.count=n&&n[e.id]?i.articleComment[e.id].count:0,i.articleList[t]=e}),i.success=function(e){var e=parseInt(e),t=$('<span class="label label-success" style="position:absolute;z-index:10"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>');a.copySuccess(e,t)},i.editArticle=function(e){e=parseInt(e);location.href="./index.php?c=site&a=article&do=post&id="+e},i.delArticle=function(e){e=parseInt(e);util.confirm(function(){window.location.href="./index.php?c=site&a=article&do=del&id="+e},function(){},"ç¡®è®¤åˆ é™¤å—?")},i.comment=function(){e.post(i.commentLink,{}).success(function(e){0==e.message.errno?(i.setting.comment_status=e.message.message,util.message("设置æˆåŠŸ","","success")):util.message(e.message.message,e.direct)})}}]),angular.module("wesiteApp").controller("WesiteArticlePost",["$scope","$http","config",function(t,a,o){t.item=o.item,t.keywords=o.keywords,t.id=o.id,t.template=o.template,t.uploadImage=function(){require(["fileUploader"],function(e){e.init(function(e){t.item.thumb=e.url,t.$apply(t.item)},{direct:!0,multiple:!1})})},t.delImage=function(){t.item.thumb=""},t.checkKeyWord=function(e){var s=$(e.target),e=s.val().trim();if(""==e)return s.next().next().text(""),!1;a.post("./index.php?c=platform&a=reply&do=post",{keyword:e}).success(function(e){if(0!=e.message.errno){if(-2==e.message.errno)return s.next().html(e.message.message),!1;var t,a=$('input[name="rid"]').val(),n=e.message.message,i="";for(rule in n)a!=n[rule].id&&(t=n[rule].name||n[rule].id,i+="<a href='"+o.links.postUrl+"&rid="+n[rule].id+"' target='_blank'><strong class='text-danger'>"+t+"</strong></a> ");""!=i&&s.next().next().html("该关键å—å·²å˜åœ¨äºŽ "+i+" 规则ä¸.")}else s.next().next().text("")})}}]),angular.module("wesiteApp").controller("WesiteCategoryPost",["$scope","config",function(n,e){n.id=e.id,n.category=e.category,n.parent=e.parent,n.parentid=e.parentid,n.multis=e.multis,n.site_template=e.site_template,n.styles=e.styles,angular.isUndefined(n.category.enabled)||n.id&&1==n.category.enabled?n.enabled=!0:n.enabled=!1,angular.isUndefined(n.category.icontype)||0==n.category.icontype||1==n.category.icontype?n.icontype=!0:n.icontype=!1,n.selectIcon=function(){util.iconBrowser(function(e){n.category.css.icon.icon=e,n.$apply(n.category.css)})},n.showWesite=function(){$(".js-site-selector").show()},n.hideWesite=function(){$(".js-site-selector").hide()},n.changeStyle=function(e){var t=parseInt(e),a=$(".title-"+t).text(),e=$(".preview-"+t).attr("src");$(".item-style").removeClass("active"),n.category.styleid=t,$("#current-title").text(a),$("#current-preview").attr("src",e),$(".title-"+t).parent().parent().addClass("active"),$("#ListStyle").modal("hide"),n.$apply(n.category.styleid)},n.uploadImage=function(){require(["fileUploader"],function(e){e.init(function(e){n.category.icon=e.url,n.$apply(n.category.icon)},{direct:!0,multiple:!1})})},n.delImage=function(){n.category.icon=""}}]),angular.module("wesiteApp").controller("articleComment",["$scope","config","$http",function(a,e,n){a.articleId=e.articleId,a.order_sort=e.order_sort,a.is_comment=e.is_comment,a.articleList=e.articleList,a.links=e.links,a.content="",a.replyarticle=function(e){e.replying=!0},a.cancel=function(e){e.replying=!1},a.send=function(t){var e=t.id;n.post(a.links.reply,{articleid:a.articleId,parentid:e,content:t.replycontent}).success(function(e){return 0!=e.message.errno?(util.message(e.message.message),!1):(t.son_comment.push(e.message.message),t.replying=!1,void(t.replycontent=""))})},a.changeSort=function(){n.post(a.links.display,{order:a.order_sort,id:a.articleId}).success(function(e){a.articleList=e.message.message})},a.changeComment=function(){n.post(a.links.display,{iscommend:a.is_comment,id:a.articleId}).success(function(e){a.articleList=e.message.message})}}]),angular.module("wesiteApp").service("serviceCommon",["$rootScope",function(e){var t={copySuccess:function(e,t){var e=parseInt(e),t=t,a=$("#copy-"+e).next().html();(!a||a.indexOf('<span class="label label-success" style="position:absolute;z-index:10"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>')<0)&&$("#copy-"+e).after(t),setTimeout(function(){t.remove()},2e3)}};return t}]),angular.module("wesiteApp").service("serviceHomeMenuBase",["$rootScope",function(e){var t={initHomemenuInfo:function(){return{css:{icon:{width:"",color:"",icon:""}},name:"",description:"",url:"",status:1,displayorder:0,icon:"",icontype:1,section:0}},initSections:function(){return[{num:0,val:"ä¸è®¾ç½®ä½ç½®"},{num:1,val:"ä½ç½®1"},{num:2,val:"ä½ç½®2"},{num:3,val:"ä½ç½®3"},{num:4,val:"ä½ç½®4"},{num:5,val:"ä½ç½®5"},{num:6,val:"ä½ç½®6"},{num:7,val:"ä½ç½®7"},{num:8,val:"ä½ç½®8"},{num:9,val:"ä½ç½®9"},{num:10,val:"ä½ç½®10"}]}};return t}]),angular.module("wesiteApp").service("serviceQuickMenuBase",["$rootScope",function(e){var t={},n={};return t.initActiveItem=function(e){return n=angular.isObject(e)?e:{navStyle:1,bgColor:"#2B2D30",menus:[],extend:[],position:{homepage:!0,usercenter:!0,page:!0,article:!0},ignoreModules:{}}},t.selectNavStyle=function(e){return n.navStyle=e,n.navStyle},t.addMenu=function(){return void 0===n.menus&&(n.menus=[]),n.menus.push({title:"æ ‡é¢˜",url:"",submenus:[],icon:{name:"fa-home",color:"#00ffff"},image:"",hoverimage:"",hovericon:""}),n.menus},t.removeMenu=function(e){var t=$.inArray(e,n.menus),a=angular.copy(n.menus);for(i in n.menus=[],a)i!=t&&n.menus.push(a[i]);return n.menus},t.addSubMenu=function(e){e=_.findIndex(n.menus,e);return void 0===n.menus[e].submenus?n.menus[e].submenus=[{title:"æ ‡é¢˜",url:""}]:n.menus[e].submenus.push({title:"æ ‡é¢˜",url:""}),n.menus[e].submenus},t.removeSubMenu=function(e,t){return n.menus[e].submenus=_.without(n.menus[e].submenus,t),n.menus[e].submenus},t.getQuickMenuData=function(e){return angular.isString(e)?n[e]:n},t.setQuickMenuData=function(e,t){angular.isObject(e)?angular.forEach(e,function(e,t){n[t]=e}):n[e]=t},t}]),angular.module("wesiteApp").service("serviceQuickMenuSubmit",["serviceQuickMenuBase",function(a){var n={stripHaskey:function(e){for(var t in e)"$$hashKey"==t?delete e[t]:"object"==typeof e[t]&&n.stripHaskey(e[t]);return e},submit:function(){var e={params:{},html:""};e.params=a.getQuickMenuData(),n.stripHaskey(e.params);var t=$(".nav-menu").html();return t=(t=(t=t.replace(/<\!\-\-([^-]*?)\-\->/g,"")).replace(/ng\-[a-zA-Z-]+=\"[^\"]*\"/g,"")).replace(/[\t\n\n\r]/g,""),e.html=t,e}};return n}]),angular.module("smsApp",["we7app"]).filter("showType",function(){return function(e,t){if(0==e.uniacid)return"系统";for(var a in t)if(-1!=t[a].contain_type.indexOf(Number(e.type)))return t[a].title}}),angular.module("smsApp").controller("smsIndex",["$scope","$http","config",function(a,n,i){a.settingSmsSign=i.settingSmsSign||{},a.currentType="",a.currentSign="",a.getSetting=function(){n.get(i.apiUrl+"system").success(function(e){e.message&&0==e.message.errno?(a.smsInfo=e.message.message.sms_info,a.systemSms=e.message.message.system_sms,(!a.smsInfo.sms_sign||a.smsInfo.sms_sign.length<1)&&(a.smsInfo.sms_sign=["微擎"]),delete e.message.message.sms_info,a.settingSmsSign=e.message.message):util.message(e.message.message,"","error")})},a.getSetting(),a.showModal=function(){a.currentSign=a.systemSms.system_sms_sign||"",setTimeout(function(){a.$apply("currentSign"),$("select").niceSelect&&$("select").niceSelect("update"),$("#editSign").modal("show")})},a.showBalance=function(){a.currentBalance=a.systemSms.system_sms_balance||0,$("#editBalance").modal("show")},a.showModalSetting=function(e,t){a.currentType=e,a.formData=a.settingSmsSign[e][t],a.formName=e,a.formKey=t,$("#editSetting").modal("show")},a.saveSetting=function(){n.post(i.smsSettingUrl+"setting_sign",{setting_sign:a.currentSign}).success(function(e){0==e.message.errno?(a.getSetting(),$("#editSign").modal("hide"),util.message("æ“作æˆåŠŸ!","","success")):($("#editSign").modal("hide"),util.message("æ“作失败!","","error"))})},a.changeBalance=function(){n.post(i.smsSettingUrl+"setting_balance",{balance:a.currentBalance}).success(function(e){0==e.message.errno?(a.getSetting(),$("#editBalance").modal("hide"),util.message("æ“作æˆåŠŸ!","","success")):($("#editBalance").modal("hide"),util.message("æ“作失败!","","error"))})},a.changeSetting=function(){var e={setting_name:a.formName,type:a.formKey};e[a.formKey]=a.formData||"",n.post(i.changeUrl,e).success(function(e){$("#editSign").modal("hide"),0==e.message.errno?(a.getSetting(),$("#editSetting").modal("hide"),util.message("æ“作æˆåŠŸ!","","success")):util.message("æ“作失败!","","error")})},a.changeStatus=function(e){var t=1==a.settingSmsSign[e].status?0:1;n.post(i.changeUrl,{setting_name:e,type:"status",status:t}).success(function(e){return 0!=e.message.errno?(util.message(e.message.message,"","error"),!1):(util.message(e.message.message,"","success"),void a.getSetting())})}}]).controller("smsSign",["$scope","$http","config",function(a,t,n){a.smsSigns=[],a.date={startDate:moment((new Date).getTime()-5184e5).format("YYYY-MM-DD"),endDate:moment().format("YYYY-MM-DD")},a.status_audit="",a.status_order="",a.statusText={2:"å®¡æ ¸ä¸",3:"å®¡æ ¸é€šè¿‡","-1":"å®¡æ ¸æ‹’ç»"},a.orderText={1:"待付款",2:"已付款",3:"已关é—",4:"已退款"},setTimeout(function(){$("select").niceSelect&&$("select").niceSelect("update")}),a.page2={currentPage:1,totalItems:0,itemsPerPage:10,pagesLength:10,onChange:function(){a.getSign()}};var l=function(e){var t,a,n,i,s,o,r="";for(t in e)if((a=e[t])instanceof Array)for(o=0;o<a.length;++o)i=a[o],(s={})[t+"["+o+"]"]=i,r+=l(s)+"&";else if(a instanceof Object)for(n in a)i=a[n],(s={})[t+"["+n+"]"]=i,r+=l(s)+"&";else null!=a&&(r+=encodeURIComponent(t)+"="+encodeURIComponent(a)+"&");return r.length?r.substr(0,r.length-1):r};a.getSign=function(e){e={page:e=e||a.page2.currentPage,status_audit:a.status_audit,status_order:a.status_order};a.date.startDate&&(e.start_time=Date.parse(moment(a.date.startDate).format("YYYY/MM/DD"))/1e3,e.end_time=Date.parse(moment(a.date.endDate).hours(23).minutes(59).seconds(59).format("YYYY/MM/DD HH:mm:ss"))/1e3),t.get(n.apiUrl+"sms_sign&"+l(e)).success(function(e){e.message.errno?util.message(e.message.message,"","error"):(a.smsSigns=e.message.message.data,a.page2.currentPage=e.message.message.page,a.page2.totalItems=e.message.message.total,setTimeout(function(){$('[data-toggle="tooltip"]').tooltip()}))})},a.getSign(),a.editSignModuleShow=function(e){$("#content").modal("show"),a.sign=e},a.editSign=function(){a.content&&a.sign.id||util.message("ç¾å内容ä¸èƒ½ä¸ºç©º","","info"),t.post(n.apiUrl+"sms_edit",{sign_id:a.sign.id,sign_content:a.content}).success(function(e){0!=e.message.errno?util.message("修改失败,å…·ä½“åŽŸå› :"+e.message.message,"","info"):(util.message("修改æˆåŠŸ",e.redirect,"success"),a.getSign())})},a.$watch("date",function(e,t){e&&e.startDate&&e!=t&&(a.date.startDate=moment(e.startDate).format("YYYY-MM-DD"),a.date.endDate=moment(e.endDate).format("YYYY-MM-DD"))},!0)}]).controller("smsLogs",["$scope","$http","config",function(a,t,n){a.mobile="",a.status="",a.date={startDate:moment((new Date).getTime()-5184e5).format("YYYY-MM-DD"),endDate:moment().format("YYYY-MM-DD")},a.page={currentPage:1,totalItems:0,itemsPerPage:10,pagesLength:5,onChange:function(){a.getList()}},a.smslogs=[];var l=function(e){var t,a,n,i,s,o,r="";for(t in e)if((a=e[t])instanceof Array)for(o=0;o<a.length;++o)i=a[o],(s={})[t+"["+o+"]"]=i,r+=l(s)+"&";else if(a instanceof Object)for(n in a)i=a[n],(s={})[t+"["+n+"]"]=i,r+=l(s)+"&";else null!=a&&(r+=encodeURIComponent(t)+"="+encodeURIComponent(a)+"&");return r.length?r.substr(0,r.length-1):r};a.changePage=function(e){a.page.currentPage=e||1},a.getList=function(e){e={page:e=e||a.page.currentPage||1};a.date.startDate&&(e.time=[Date.parse(moment(a.date.startDate).format("YYYY/MM/DD"))/1e3,Date.parse(moment(a.date.endDate).hours(23).minutes(59).seconds(59).format("YYYY/MM/DD HH:mm:ss"))/1e3]),a.mobile&&(e.mobile=a.mobile),""!=a.status&&(e.status=a.status),t.get(n.apiUrl+"smsLog&"+l({params:e})).success(function(e){e.message.errno?util.message(e.message.message,"","error"):(a.smslogs=e.message.message.list,a.page.currentPage=e.message.message.page,a.page.totalItems=e.message.message.total)})},a.$watch("date",function(e,t){e&&e.startDate&&e!=t&&(a.date.startDate=moment(e.startDate).format("YYYY-MM-DD"),a.date.endDate=moment(e.endDate).format("YYYY-MM-DD"))},!0),a.getList()}]).controller("smsTrade",["$scope","$http","config",function(a,t,n){a.smslogs=[],a.orderText={1:"待付款",2:"已付款",3:"已关é—",4:"已退款"},a.status_order="",setTimeout(function(){$("select").niceSelect&&$("select").niceSelect("update")}),a.date={startDate:moment((new Date).getTime()-5184e5).format("YYYY-MM-DD"),endDate:moment().format("YYYY-MM-DD")},a.smsInfo={},a.page1={currentPage:1,totalItems:0,itemsPerPage:10,pagesLength:5,onChange:function(){a.getTrade()}};var l=function(e){var t,a,n,i,s,o,r="";for(t in e)if((a=e[t])instanceof Array)for(o=0;o<a.length;++o)i=a[o],(s={})[t+"["+o+"]"]=i,r+=l(s)+"&";else if(a instanceof Object)for(n in a)i=a[n],(s={})[t+"["+n+"]"]=i,r+=l(s)+"&";else null!=a&&(r+=encodeURIComponent(t)+"="+encodeURIComponent(a)+"&");return r.length?r.substr(0,r.length-1):r};a.getTrade=function(e){e={page:e=e||a.page1.currentPage,status_order:a.status_order};a.date.startDate&&(e.start_time=Date.parse(moment(a.date.startDate).format("YYYY/MM/DD"))/1e3,e.end_time=Date.parse(moment(a.date.endDate).hours(23).minutes(59).seconds(59).format("YYYY/MM/DD HH:mm:ss"))/1e3),t({method:"GET",url:n.apiUrl+"smsTrade&"+l(e)}).success(function(e){a.smslogs=[],e.message.errno?util.message(e.message.message,"","error"):(a.smsInfo=e.message.message.sms_info,a.smslogs=e.message.message.list.data,a.page1.totalItems=e.message.message.list.total)})},a.$watch("date",function(e,t){e&&e.startDate&&e!=t&&(a.date.startDate=moment(e.startDate).format("YYYY-MM-DD"),a.date.endDate=moment(e.endDate).format("YYYY-MM-DD"))},!0),a.getTrade()}]).controller("smsShare",["$scope","$http","config",function(a,n,i){a.apiUrl=i.apiUrl,a.page={currentPage:1,totalItems:0,itemsPerPage:2,pagesLength:10,rememberPerPage:!1,onChange:function(){a.getList()}},a.keyword="",a.type="",a.getList=function(t){var e={page:t=t||a.page.currentPage,keyword:a.keyword,type:a.type};n.get(i.apiUrl+"list",{params:e}).success(function(e){0==e.message.errno?(a.list=e.message.message.list,a.typeList=e.message.message.account_types,a.page.itemsPerPage=e.message.message.page_size,a.page.totalItems=e.message.message.total,t&&(a.page.currentPage=t),setTimeout(function(){$("select").niceSelect&&$("select").niceSelect("update")})):util.message(e.message.message,"","error")})},a.getList(),a.deleteItem=function(e){util.confirm(function(){n.post(i.apiUrl+"delete",{uniacid:e}).success(function(e){0==e.message.errno?(a.getList(1),util.message("æ“作æˆåŠŸ!","","success")):util.message("æ“作失败!","","error")})},function(){return!1},"ç¡®è®¤åˆ é™¤å—?")}}]).controller("smsAdd",["$scope","$http","config",function(t,e,a){t.getSetting=function(){e.get(a.apiUrl+"&do=add").success(function(e){0==e.message.errno?(t.setting=e.message.message,setTimeout(function(){$("select").niceSelect&&$("select").niceSelect("update")})):util.message(e.message.message,"","error")})},t.getSetting(),t.postSetting=function(){e.post(a.apiUrl+"&do=add",t.postData).success(function(e){0==e.message.errno?util.message("æ“作æˆåŠŸ!",a.apiUrl,"success"):util.message(e.message.message,"","error")})}}]),angular.module("specialApp",["wapeditorApp"]),angular.module("specialApp").controller("MainCtrl",["$scope","$timeout","$uibModal","widget","config","serviceCommon","serviceSetStyle","serviceBase","serviceSpecialBase","serviceSubmit","serviceMultiSubmit","serviceMultiPage","serviceUpwardCompatible","$sanitize",function(s,e,t,a,n,i,o,r,l,c,u,d,p,m){s.modules=[],s.editors=[],s.allPages=n.allPages,s.multipage=n.multipage||[],s.submit={params:{},html:"",multipage:[]},s.isNew=!0,s.allPages&&-1==_.findIndex(s.allPages,{active:!0})&&(s.isNew=!1,s.allPages=[{property:s.allPages,active:!0}]),r.setBaseData("isNew",s.isNew),s.allPages=s.allPages||[{property:[],active:!0}];var g,n=_.findIndex(s.allPages,{active:!0});for(g in s.activeModules=-1<n?r.initActiveModules(s.allPages[n].property):[],s.activePageIndex=-1<n?n:0,l.setBaseData("activePageIndex",s.activePageIndex),s.activeItem={},s.activeIndex=0,s.index=s.activeModules.length?i.getMaxScopeIndex(s.allPages)+1:0,r.setBaseData("index",s.index),s.pageLength=!_.isEmpty(s.activeModules)&&s.activeModules[0].params.pageLength||1,s.isMultiPage=0==s.index||!(1<s.activeModules[i.getHeaderIndex(s.activeModules)].params.pageLength),s.isLongPage=0==s.index||(1<s.activeModules[i.getHeaderIndex(s.activeModules)].params.pageLength||1==s.activeModules[i.getHeaderIndex(s.activeModules)].params.pageLength&&1==s.allPages.length),s.pageLengths={1:1,2:2,3:3,4:4,5:5},s.lineHeights={1:1,1.25:1.25,1.5:1.5,2:2,2.5:2.5},s.fontSizes={12:12,14:14,16:16,18:18,20:20,22:22,24:24,26:26,28:28,30:30,32:32,34:34,36:36,38:38,40:40},l.setBaseData("allPages",s.allPages),l.setBaseData("multipage",s.multipage),r.setBaseData("pageLength",s.pageLength),s.isNew||(s.activeModules=p.compatibility(s.activeModules),void 0===s.activeModules[0].params.pageLength&&(s.activeModules[0].params.pageLength=Math.ceil($(".modules").height()/568)),1<s.activeModules[0].params.pageLength&&(s.pageLength=s.activeModules[0].params.pageLength,s.isMultiPage=!1,s.isLongPage=!0,r.setBaseData("pageLength",s.pageLength),e(function(){$(".app-content").css("height",568*s.pageLength+"px")},100)),e(function(){var a=0,n=height="";$(".modules>div").each(function(){var e=parseInt($(this).attr("index"));if(n=$(this).find("div.ng-scope[ng-controller$='Ctrl']").css("width"),height=$(this).find("div.ng-scope[ng-controller$='Ctrl']").css("height"),0<e){for(var t in s.activeModules)s.activeModules[t].index==e&&(a+=parseInt(s.activeModules[t].marginTop),s.activeModules[t].params.positionStyle.width=parseInt(n),s.activeModules[t].params.positionStyle.height=parseInt(height),s.activeModules[t].params.positionStyle.top=a,s.activeModules[t].positionStyle="position:absolute;width:"+n+";height:"+height+";left:"+s.activeModules[t].params.positionStyle.left+"px;top:"+a+"px;",$(this).find("div[ng-controller]").attr("style",s.activeModules[t].positionStyle));a+=parseInt(height)}t++}),r.setBaseData("activeModules",s.activeModules)},1e3)),s.activeModules)s.activeModules[g].originParams=angular.copy(s.activeModules[g].params);s.$on("serviceBase.editors.update",function(e,t){s.editors=t}),s.$on("serviceBase.activeItem.update",function(e,t){s.activeItem=t}),s.$on("serviceBase.activeModules.update",function(e,t){s.activeModules=t}),s.$on("serviceBase.activeItem.params.update",function(e,t){s.activeItem.params=t}),s.$on("serviceBase.activeItem.animationName.update",function(e,t){s.activeItem.params.animationStyle.animationName=t}),s.$on("serviceBase.activeItem.style.update",function(e,t,a,n,i){s.activeItem.params[t]=a,s.activeItem[t]=n,void 0!==i&&(s.activeItem.transform=i)}),s.$on("updateScope",function(e,t){angular.forEach(t,function(e,t){s[t]=e})}),s.addItem=function(e){r.addItem(e)},s.editItem=function(e){r.editItem(e)},s.deleteItem=function(e){r.deleteItem(e)},s.submit=function(e){s.submit=c.submit(),s.$apply("submit"),$(e.target).parents("form").submit()},s.multiSubmit=function(e){s.submit=u.submit(),s.$apply("submit"),$(e.target).parents("form").submit()},s.init=function(e,t){var a;s.modules=r.setModules(e,t),0<s.activeModules.length&&(a=[],angular.forEach(s.activeModules,function(e,t){e&&a.push(e.id)})),angular.forEach(s.modules,function(e,t){e.defaultshow&&-1==$.inArray(e.id,a)&&r.addItem(e.id)})},s.setModulePositionStyle=function(e){o.setModulePositionStyle(e)},s.eleAnimationIns=function(e){o.eleAnimationIns(e)},s.savePagePosition=function(){o.savePagePosition(s.activeModules)},s.saveModulePosition=function(){o.saveModulePosition(s.activeItem)},s.changeTextAlign=function(e){o.changeTextAlign(s.activeItem,e)},s.changeBorderWidth=function(){o.changeBorderWidth(s.activeItem)},s.changeInnerHeight=function(){o.changeInnerHeight(s.activeItem)},s.clearModuleStyle=function(){o.clearModuleStyle(s.activeItem)},s.changePageLength=function(e){if(angular.isString(e))if("minus"==e&&1<s.pageLength)e=s.pageLength-1;else{if(!("plus"==e&&s.pageLength<5))return!1;e=s.pageLength+1}var t=o.changePageLength(e,s.activeModules);r.setBaseData("pageLength",parseInt(e)),r.setBaseData("activeModules",t)},s.insertPage=function(){d.insertPage(),s.init(null,["header"])},s.navToPage=function(e){d.navToPage(e),s.activeHeader()},s.removePage=function(e){d.removePage(e),s.activeHeader()},s.copyPage=function(e,t){d.copyPage(e,t),s.activeHeader()},s.changeLock=function(){s.activeItem.params.baseStyle.lock=!s.activeItem.params.baseStyle.lock},s.activeHeader=function(){for(var e in s.activeModules)if("header"==s.activeModules[e].id){s.pageLength=s.activeModules[e].params.pageLength||1,o.changePageLength(s.pageLength,s.activeModules),r.setBaseData("activeItem",s.activeModules[0]),s.editItem(s.activeModules[e].index);break}},$(".multi-submit").on("click",function(e){s.multiSubmit(e)}),$(".single-submit").on("click",function(e){s.submit(e)}),s.init(null,["header"]),s.activeHeader(),s.$watch("activeItem.params.baseStyle",function(e){e&&o.setModuleBaseStyle(e)},!0),s.$watch("activeItem.params.borderStyle",function(e){e&&o.setModuleBorderStyle(e)},!0),s.$watch("activeItem.params.shadowStyle",function(e){e&&o.setModuleShadowStyle(e)},!0),s.$watch("activeItem.params.animationStyle",function(e){e&&o.setModuleAnimationStyle(e)},!0),s.$watch("activeItem.params.positionStyle",function(e){e&&o.setModulePositionStyle(e)},!0)}]),angular.module("specialApp").controller("SpecialDisplay",["$scope","serviceCopy","config",function(a,n,e){a.pages=e.pages,a.links=e.links,angular.forEach(a.pages,function(e,t){e.copyLink=a.links.appHome+"id="+e.id}),a.success=function(e){var e=parseInt(e),t=$('<span class="label label-success" style="position:absolute;z-index:10"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>');n.copySuccess(e,t)}}]),angular.module("specialApp").directive("we7Multipage",function(){return{replace:!0,templateUrl:"directive-multipage-multipage.html"}}),angular.module("specialApp").service("serviceSpecialBase",["$rootScope","serviceBase",function(e,t){var a={},n={activePageIndex:0,isMultiPage:!0,isLongPage:!0,allPages:[],multipage:[]};return a.getBaseData=function(e){return n[e]},a.setBaseData=function(e,t){angular.isObject(e)?angular.forEach(e,function(e,t){n[t]=e}):n[e]=t},a}]),angular.module("specialApp").service("serviceCopy",["$rootScope",function(e){var t={copySuccess:function(e,t){var e=parseInt(e),t=t,a=$("#copy-"+e).next().html();(!a||a.indexOf('<span class="label label-success" style="position:absolute;z-index:10"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>')<0)&&$("#copy-"+e).after(t),setTimeout(function(){t.remove()},2e3)}};return t}]),angular.module("specialApp").service("serviceMultiPage",["$rootScope","serviceCommon","serviceBase","serviceSpecialBase","$window",function(m,g,f,h,e){var u={insertPage:function(){u.saveCurPage();var e=h.getBaseData("allPages"),t=h.getBaseData("activePageIndex");e[t].active=!1,e.push({property:[],active:!0}),$(".app-content").css("height","568px"),t=_.findIndex(e,{active:!0}),f.setBaseData({activeModules:[],pageLength:1}),h.setBaseData({allPages:e,isMultiPage:!0,isLongPage:!1,activePageIndex:t}),m.$broadcast("updateScope",{allPages:e,isMultiPage:!0,isLongPage:!1,pageLength:1,activePageIndex:t,activeModules:[]})},navToPage:function(e){var t=h.getBaseData("activePageIndex");if(t==e)return!1;u.saveCurPage();var a=h.getBaseData("allPages"),n=a[e].property;a[t].active=!1,a[e].active=!0,t=e,f.setBaseData("activeModules",n),f.setBaseData("activeItem",n[0]),h.setBaseData({allPages:a,activePageIndex:t}),m.$broadcast("updateScope",{allPages:a,activePageIndex:t,activeModules:n})},removePage:function(e){var t=[],a=h.getBaseData("allPages"),n=h.getBaseData("multipage");if(1==a.length)return!1;u.saveCurPage(),n.splice(parseInt(e),1);var i,s=_.clone(a),o=a.length-1-e,a=[];for(i in s)i!=e&&(0==o?parseInt(i)+1==e?(a.push({property:s[i].property,active:!0}),t=s[i].property):a.push({property:s[i].property,active:!1}):i-1==e?(a.push({property:s[i].property,active:!0}),t=s[i].property):a.push({property:s[i].property,active:!1}));activePageIndex=_.findIndex(a,{active:!0}),1==a.length&&(h.setBaseData({isMultiPage:!0,isLongPage:!0}),m.$broadcast("updateScope",{isMultiPage:!0,isLongPage:!0})),f.setBaseData("activeModules",t),h.setBaseData({allPages:a,activePageIndex:activePageIndex}),m.$broadcast("updateScope",{allPages:a,activePageIndex:activePageIndex,activeModules:t})},copyPage:function(e,t){u.saveCurPage();var a=f.getBaseData("index"),n=h.getBaseData("allPages"),i=h.getBaseData("multipage");i.splice(parseInt(e),0,i[e]);var s,o=angular.copy(n),n=[];for(s in o)if(s==e){n.push({property:o[s].property,active:!1});var r,l=angular.copy(o[s].property);for(r in l)l[r].index=a++;n.push({property:l,active:!0});var c=l}else n.push({property:o[s].property,active:!1});activePageIndex=_.findIndex(n,{active:!0}),f.setBaseData("activeModules",c),f.setBaseData("index",a),h.setBaseData({allPages:n,multipage:i,isMultiPage:!0,isLongPage:!1,activePageIndex:activePageIndex}),t.stopPropagation(),m.$broadcast("updateScope",{allPages:n,isMultiPage:!0,isLongPage:!1,activePageIndex:activePageIndex,activeModules:c})},saveCurPage:function(){var u=f.getBaseData("activeModules"),d=f.getBaseData("pageLength"),e=h.getBaseData("allPages"),t=h.getBaseData("multipage"),a=_.findIndex(e,{active:!0}),p="";$($(".modules").html()).find("div.ng-scope[ng-controller$='Ctrl']").each(function(){var e,t=$(this).parent().parent(),a=_.findIndex(u,{index:parseInt(t.attr("index"))}),n=angular.copy(u[a].params);$(this).find(".js-default-content").remove(),$(this).find(".bar").remove();var i,s,o,r,l=t.attr("name").toLowerCase();switch("header"!=l?(r="position:absolute;top:"+(o=$(this).css("top"))+";left:"+(i=$(this).css("left"))+";width:"+(s=$(this).css("width"))+";height:"+(t=$(this).css("height"))+";",u[a].params.positionStyle.top=parseInt(o),u[a].params.positionStyle.left=parseInt(i),u[a].params.positionStyle.width=parseInt(s),u[a].params.positionStyle.height=parseInt(t),u[a].positionStyle=r):u[a].params.pageLength=d,l){case"link":var c=this;angular.forEach(n.items,function(e,t){(e.selectCate.pid||e.selectCate.cid)&&$(c).find(".list-group").children().eq(t).replaceWith("<div>"+g.buildDataTagBegin("link",e)+'<div class="list-group-item ng-scope"><a href="{$row[url]}" class="clearfix"><span class="app-nav-title"> {$row[title]}<i class="pull-right fa fa-angle-right"></i></span></a></div>'+g.buildDataTagEnd()+"</div>")});break;case"richtext":u[a]&&(u[a].params.content="")}e=$(this).html(),f.getBaseData("isNew")||(o=parseInt(o)-64,$(this).css("top",o+"px")),"header"!=l&&(r=$(this).attr("style"),p+='<div type="'+l+'" style="'+r+'">'+e+"</div>")}),p=(p=(p=p.replace(/<\!\-\-([^-]*?)\-\->/g,"")).replace(/ ng\-[a-zA-Z-]+=\"[^\"]*\"/g,"")).replace(/ ng\-[a-zA-Z]+/g,""),t[a]=p,e[a].property=u,f.setBaseData("activeModules",u),h.setBaseData({allPages:e,multipage:t}),m.$broadcast("updateScope",{activeModules:u,allPages:e,multipage:t})}};return u}]),angular.module("specialApp").service("serviceMultiSubmit",["serviceCommon","serviceMultiPage","serviceSpecialBase",function(c,u,d){var e={submit:function(e){u.saveCurPage();var t,a=d.getBaseData("multipage"),n=d.getBaseData("allPages"),i="",s='<section class="u-arrow-bottom" style="bottom: 15%;"><div class="pre-wrap"><div class="pre-box1"><div class="pre1"></div></div><div class="pre-box2"><div class="pre2"></div></div></div></section></div>';for(t in $.each(a,function(e,t){e+1==a.length?i+=1==n.length?'<div class="pane">'+t+"</div>":'<div class="pane overflowhidden">'+t+"</div>":i+=1==n.length?'<div class="pane">'+t+s:'<div class="pane overflowhidden">'+t+s}),n)for(var o in n[t].property)delete n[t].property[o].originParams,delete n[t].property[o].marginTop;var r={},l=$(".app-content").css("height");return i=(i=(i=(i='<div style="height:'+l+'"><div class="panes">'+i+"</div></div>").replace(/<\!\-\-([^-]*?)\-\->/g,"")).replace(/ ng\-[a-zA-Z-]+=\"[^\"]*\"/g,"")).replace(/ ng\-[a-zA-Z]+/g,""),r.html=i,r.params=angular.copy(n),r.multipage=a,c.stripHaskey(r.params),r}};return e}]),angular.module("statisticsApp",["we7app"]),angular.module("statisticsApp").controller("HorizontalBarCtrl",["$scope","$http","serviceCommon","config",function(r,l,a,c){r.needAccountApi="account"==c.frame||"wxapp"==c.frame,require(["echarts"],function(e){var s;r.needAccountApi&&(s=e.init(document.getElementById("chart-line"))),accountOption={tooltip:{trigger:"axis",axisPointer:{type:"line"}},grid:{left:"3%",right:"3%",bottom:"3%",containLabel:!0},xAxis:{data:[]},yAxis:{splitArea:{show:!0}},series:[{name:"æ•°é‡",type:"line",smooth:!0,data:[]}]},r.needAccountApi&&s.showLoading();var o=e.init(document.getElementById("chart-horizontal-bar"));moduleOption={tooltip:{trigger:"axis",axisPointer:{type:"shadow"}},grid:{left:"3%",right:"3%",bottom:"3%",containLabel:!0},xAxis:{},yAxis:{type:"category",data:[]},series:[{name:"æ•°é‡",type:"bar",barWidth:20,data:[]}]},o.showLoading(),r.active=!0,r.code="<script type=\"text/javascript\" src=\"{$_W['siteroot']}app/index.php?i={$_W['uniacid']}&c=utility&a=visit&do=showjs&m={$_W['current_module']['name']}\"><\/script>",r.show=!0,r.accountDateRange={startDate:moment().format("YYYY-MM-DD"),endDate:moment().format("YYYY-MM-DD")},r.moduleDateRange={startDate:moment().format("YYYY-MM-DD"),endDate:moment().format("YYYY-MM-DD")},r.changeDivideType=function(e,t){"account"==e&&(r.accountDivideType=t),"module"==e&&(r.moduleDivideType=t),r.getModuleApi(e,"week")},r.getModuleApi=function(a,e){var t="",n="",i="";"account"==a&&(r.accountTimeType=e,r.accountLabels=[],r.accountData=[],t=c.links.accountApi,n=r.accountDivideType,i=r.accountDateRange),"module"==a&&(r.moduleTimeType=e,r.moduleLabels=[],r.moduleData=[],t=c.links.moduleApi,n=r.moduleDivideType,i=r.moduleDateRange),l.post(t,{divide_type:n,time_type:e,daterange:i}).success(function(e){var t;r.needAccountApi&&s.hideLoading(),o.hideLoading(),r.needAccountApi&&"account"==a&&(accountOption.xAxis.data=e.message.message.data_x,accountOption.series[0].data=e.message.message.data_y,s.setOption(accountOption)),"module"==a&&(t=e.message.message.data_y.length,r.actualHight=15*parseInt(t)+"px",moduleOption.series[0].data=e.message.message.data_x,moduleOption.yAxis.data=e.message.message.data_y,o.setOption(moduleOption))})},r.accountDivideType="bysum",r.moduleDivideType="bysum",r.accountTimeType="week",r.moduleTimeType="week",r.needAccountApi&&r.getModuleApi("account",r.accountTimeType),r.getModuleApi("module",r.moduleTimeType),r.success=function(e){var e=parseInt(e),t=$('<span class="label label-success" style="position:absolute;z-index:10;width:90px;height:34px;line-height:28px;"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>');a.copySuccess(e,t)},r.changeStatus=function(){r.show=!r.show},r.$watch("moduleDateRange",function(e,t){e&&e!=t&&(r.moduleDateRange.startDate=moment(e.startDate).format("YYYY-MM-DD"),r.moduleDateRange.endDate=moment(e.endDate).format("YYYY-MM-DD"),r.getModuleApi("module","daterange"))},!0),r.$watch("accountDateRange",function(e,t){e&&e!=t&&(r.accountDateRange.startDate=moment(e.startDate).format("YYYY-MM-DD"),r.accountDateRange.endDate=moment(e.endDate).format("YYYY-MM-DD"),r.getModuleApi("account","daterange"))},!0)})}]),angular.module("statisticsApp").controller("statisticsSettingCtrl",["$scope","$http","config",function(a,t,n){a.setting=n.highest_visit,a.interval=n.interval,a.newVisitVal=0,a.newInterval=0,a.editInfo=function(e,t){switch(e){case"visit":a.newVisitVal=t||0;break;case"interval":a.newInterval=t||0}},a.saveSetting=function(e){switch(e){case"visit":t.post(n.links.editSetting,{highest_visit:a.newVisitVal,type:"highest_visit"}).success(function(e){0==e.message.errno&&(a.setting=a.newVisitVal),util.message(e.message.message,"","success")});break;case"interval":t.post(n.links.editSetting,{interval:a.newInterval,type:"interval"}).success(function(e){0==e.message.errno&&(a.interval=a.newInterval),util.message(e.message.message,"","success")})}}}]),angular.module("statisticsApp").controller("systemAccountAppAnalysisCtrl",["$scope","$http","config",function(a,n,i){require(["echarts"],function(e){var t=e.init(document.getElementById("chart-line"));option={tooltip:{trigger:"axis",axisPointer:{type:"line"}},xAxis:{data:[]},yAxis:{splitArea:{show:!0}},series:[{name:"æ•°é‡",type:"line",smooth:!0,data:[]}]},t.showLoading(),a.dateRange={startDate:moment().format("YYYY-MM-DD"),endDate:moment().format("YYYY-MM-DD")},a.changeDivideType=function(e){a.divideType=e,a.getAccountApi("week")},a.getAccountApi=function(e){a.timeType=e,n.post(i.links.accountApi,{divide_type:a.divideType,time_type:e,daterange:a.dateRange}).success(function(e){t.hideLoading(),option.xAxis.data=e.message.message.data_x,option.series[0].data=e.message.message.data_y,t.setOption(option)})},a.divideType="bysum",a.timeType="week",a.getAccountApi(a.timeType),a.$watch("dateRange",function(e,t){e&&e!=t&&(a.dateRange.startDate=moment(e.startDate).format("YYYY-MM-DD"),a.dateRange.endDate=moment(e.endDate).format("YYYY-MM-DD"),a.getAccountApi("daterange"))},!0)})}]),angular.module("statisticsApp").controller("systemAccountAnalysisCtrl",["$scope","$http","config",function(a,n,i){require(["echarts"],function(e){var t=e.init(document.getElementById("chart-line"));accountOption={tooltip:{trigger:"axis",axisPointer:{type:"line"}},grid:{left:"3%",right:"3%",bottom:"3%",containLabel:!0},xAxis:{data:[]},yAxis:{splitArea:{show:!0}},series:[{name:"æ•°é‡",type:"line",smooth:!0,data:[]}]},t.showLoading(),a.dateRange={startDate:moment().format("YYYY-MM-DD"),endDate:moment().format("YYYY-MM-DD")},a.getAccountApi=function(e){a.timeType=e,n.post(i.links.accountApi,{time_type:e,daterange:a.dateRange}).success(function(e){t.hideLoading(),accountOption.xAxis.data=e.message.message.data_x,accountOption.series[0].data=e.message.message.data_y,t.setOption(accountOption)})},a.timeType="week",a.getAccountApi(a.timeType),a.$watch("dateRange",function(e,t){e&&e!=t&&(a.dateRange.startDate=moment(e.startDate).format("YYYY-MM-DD"),a.dateRange.endDate=moment(e.endDate).format("YYYY-MM-DD"),a.getAccountApi("daterange"))},!0)})}]),angular.module("statisticsApp").controller("CurrentAccountCtrl",["$scope","$http","config",function(a,n,i){require(["echarts"],function(e){var t=e.init(document.getElementById("chart-line"));accountOption={tooltip:{trigger:"axis",axisPointer:{type:"line"}},grid:{left:"3%",right:"3%",bottom:"3%",containLabel:!0},xAxis:{data:[]},yAxis:{splitArea:{show:!0}},series:[{name:"æ•°é‡",type:"line",smooth:!0,data:[]}]},t.showLoading(),a.accountDateRange={startDate:moment().format("YYYY-MM-DD"),endDate:moment().format("YYYY-MM-DD")},a.getModuleApi=function(e){a.accountTimeType=e,n.post(i.links.accountApi,{time_type:e,daterange:a.accountDateRange}).success(function(e){t.hideLoading(),accountOption.xAxis.data=e.message.message.data_x,accountOption.series[0].data=e.message.message.data_y,t.setOption(accountOption)})},a.accountTimeType="week",a.getModuleApi(a.accountTimeType),a.$watch("accountDateRange",function(e,t){e&&e!=t&&(a.accountDateRange.startDate=moment(e.startDate).format("YYYY-MM-DD"),a.accountDateRange.endDate=moment(e.endDate).format("YYYY-MM-DD"),a.getModuleApi("daterange"))},!0)})}]),angular.module("statisticsApp").controller("FansStatisticeCtrl",["$scope","$http","serviceCommon","config",function(a,n,e,i){require(["echarts"],function(e){var t=e.init(document.getElementById("chart-line"));option={tooltip:{trigger:"axis",axisPointer:{type:"line"}},grid:{left:"3%",right:"3%",bottom:"3%",containLabel:!0},xAxis:{data:[]},yAxis:{splitArea:{show:!0}},series:[{name:"æ•°é‡",type:"line",smooth:!0,data:[]}]},t.showLoading(),a.dateRange={startDate:moment().format("YYYY-MM-DD"),endDate:moment().format("YYYY-MM-DD")},a.changeDivideType=function(e){a.fansDivideType=e,a.getFansApi("week")},a.getFansApi=function(e){a.timeType=e,n.post(i.links.fansApi,{divide_type:a.fansDivideType,time_type:e,daterange:a.dateRange}).success(function(e){t.hideLoading(),option.xAxis.data=e.message.message.data_x,option.series[0].data=e.message.message.data_y,t.setOption(option)})},a.fansDivideType="bynew",a.fansTimeType="week",a.getFansApi(a.fansTimeType),a.$watch("dateRange",function(e,t){e&&e!=t&&(a.dateRange.startDate=moment(e.startDate).format("YYYY-MM-DD"),a.dateRange.endDate=moment(e.endDate).format("YYYY-MM-DD"),a.getFansApi("daterange"))},!0)})}]),angular.module("statisticsApp").controller("systemAccountVisit",["$scope","$http","config",function(n,a,i){n.visitTimeType="today",n.visitDate={startDate:moment().format("YYYY-MM-DD"),endDate:moment().format("YYYY-MM-DD")},n.visitDateRange={startDate:moment().format("YYYY-MM-DD"),endDate:moment().format("YYYY-MM-DD")},n.page=1,n.size=10,n.visitList=[],n.visitTotal=0,n.visitTotalPage=1,n.range=function(e){return new Array(e)},n.getAccountVisit=function(e){var t=new Date;e&&(n.page=1,n.visitTimeType=e,"today"==n.visitTimeType&&(n.visitDate.startDate=moment().format("YYYY-MM-DD"),n.visitDate.endDate=moment().format("YYYY-MM-DD")),"week"==n.visitTimeType&&(n.visitDate.startDate=moment(t.setDate(t.getDate()-6)).format("YYYY-MM-DD"),n.visitDate.endDate=moment().format("YYYY-MM-DD")),"month"==n.visitTimeType&&(n.visitDate.startDate=moment(t.setDate(t.getDate()-29)).format("YYYY-MM-DD"),n.visitDate.endDate=moment().format("YYYY-MM-DD"))),a.get(i.links.accountVisit,{params:{page:n.page,size:n.size,start_time:n.visitDate.startDate,end_time:n.visitDate.endDate}}).success(function(e){e.message.errno||(n.visitList=e.message.message.list,n.visitTotal=e.message.message.total_visit,n.getPage(Math.ceil(e.message.message.total_account/n.size)))})},n.$watch("visitDateRange",function(e,t){e&&e.startDate!=n.visitDate.startDate&&(n.visitDate.startDate=moment(e.startDate).format("YYYY-MM-DD"),n.visitDate.endDate=moment(e.endDate).format("YYYY-MM-DD"),n.getAccountVisit("daterange"))},!0),n.changePage=function(e){if(e<1||e>n.visitTotalPage)return!1;n.page=e,n.getAccountVisit()},n.getPage=function(e){if(e==n.visitTotalPage)return!1;n.visitTotalPage=e;var t=Math.max(1,n.page-4),a=Math.min(n.visitTotalPage,n.page+4);for(a-t<9&&(a=Math.min(n.visitTotalPage,t+8),t=Math.max(1,a-8)),n.pageArray=[];t<=a;t++)n.pageArray.push(t)},n.changePage(1)}]),angular.module("statisticsApp").service("serviceCommon",["$rootScope",function(e){var t={copySuccess:function(e,t){var e=parseInt(e),t=t,a=$("#copy-"+e).next().html();(!a||a.indexOf('<span class="label label-success" style="position:absolute;z-index:10"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>')<0)&&$("#copy-"+e).after(t),setTimeout(function(){t.remove()},2e3)}};return t}]),angular.module("storeApp",["we7app"]),angular.module("storeApp").controller("goodsSellerCtrl",["$scope","$http","config",function(a,t,n){a.status=n.status,a.moduleList=[],a.keyword="",a.selectedModule="",a.visitTimes=0,a.visitPrice=0,a.moduleGoodsType=1,a.tabChange=function(e,t){for(key in a.moduleGoodsType=t,a.moduleList=[],n.moduleList)2==n.moduleList[key][e]&&a.moduleList.push(n.moduleList[key])},a.tabChange("account_support",1),a.showModule=function(){$("#add_module").modal("show")},a.selectModule=function(e,t){$(t.target).parents(".select-module").find(".item").addClass("active"),$(t.target).parents(".select-module").siblings().find(".item").removeClass("active"),a.selectedModule=e},a.editPrice=function(e){switch(e){case"add_module":t.post(n.links.add,{module:a.selectedModule,toedit:!0,type:a.moduleGoodsType}).success(function(e){0==e.message.errno?location.href=n.links.post+"&id="+e.message.message:util.message(e.message.message)});break;case"add_api":t.post(n.links.add,{title:"应用访问æµé‡(API)",visit_times:a.visitTimes,price:a.visitPrice,online:!0}).success(function(e){0==e.message.errno?location.href=n.links.online:util.message(e.message.message)})}},a.toOffline=function(e){switch(e){case"add_module":t.post(n.links.add,{module:a.selectedModule,type:a.moduleGoodsType}).success(function(e){0==e.message.errno?location.href=n.links.offline:util.message(e.message.message)});break;case"add_api":t.post(n.links.add,{title:"应用访问æµé‡(API)",visit_times:a.visitTimes,price:a.visitPrice}).success(function(e){0==e.message.errno?location.href=n.links.offline:util.message(e.message.message)})}}}]),angular.module("storeApp").controller("goodsPostCtrl",["$scope","$http","$compile","config","we7TypeDefault",function(l,e,i,t,a){if(l.slideLists=[],l.goodsInfo=t.goodsInfo,l.userGroups=t.userGroups,l.account_text=a,l.fileLogo=function(e,t,a){l.goodsInfo.logo=e.url},l.changeGroup=function(e,a){var n=!0;$('[name="user_group_id[]"]').each(function(e,t){a.currentTarget.dataset.id==$(t).val()&&(n=!1)}),n&&($(".user-group-price-content .form-group-"+e+" .group-title").text(a.currentTarget.dataset.title),$(".user-group-price-content .form-group-"+e+' [name="user_group_id[]"]').val(a.currentTarget.dataset.id),$(".user-group-price-content .form-group-"+e+' [name="user_group_name[]"]').val(a.currentTarget.dataset.title))},l.addGroupPrice=function(e,t,a){var n=$(".user-group-price-content .form-group").length+1,t='<div class="form-group form-group-'+n+'"><label class="control-label col-sm-2"></label><div class="col-sm-8 form-controls"><div class="input-group"><div class="input-group-btn"><button type="button" class="btn btn-info dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" style="min-width:120px;background-color: #f8f9f9;color: #666;"><span class="group-title">'+(a?t:"选择用户组")+'</span> <span class="caret" style="color: #3071a9"></span><input type="hidden" name="user_group_id[]" value="'+e+'"/><input type="hidden" name="user_group_name[]" value="'+t+'"/></button><ul class="dropdown-menu dropdown-menu-right">';t+=l.getuserGroupsLi(n),t+='</ul></div><input type="number" class="form-control" min="0" name="user_group_price[]" value="'+a+'" step="0.01"><span class="input-group-addon" >å…ƒ / <span ng-if="num > 0" ng-bind="num"></span><span ng-bind="unitTitle"></span></span><div class="input-group-btn" style="padding-left: 10px"><button type="button" class="btn btn-default" ng-click="deleteGroupPrice('+n+')">åˆ é™¤</button></div></div></div></div>',$(".user-group-price-content").append(i(t)(l))},l.getuserGroupsLi=function(e){var t="";for(key in l.userGroups)t+='<li><a href="" ng-click="changeGroup('+e+', $event)" data-title="'+l.userGroups[key].name+'" data-id="'+l.userGroups[key].id+'">'+l.userGroups[key].name+"</a></li>";return t},l.getUnitName=function(){switch(l.unit){case"day":return"æ—¥";case"month":return"月";case"year":return"å¹´"}},l.deleteGroupPrice=function(e){$(".user-group-price-content .form-group-"+e).remove()},l.changeUnit=function(e){l.unit=e,$('[name="unit"]').val(e),l.unitTitle=l.getUnitName()},l.addSlide=function(){require(["fileUploader"],function(e){e.init(function(e){l.slideLists.push(e.url),l.$apply(l.slideLists)},{direct:!0,multiple:!1,uniacid:0,global:"global"})})},l.delSlide=function(e){l.slideLists.splice(e,1)},l.goodsInfo){if(l.unit=l.goodsInfo.unit,7!=l.goodsInfo.type&&8!=l.goodsInfo.type&&29!=l.goodsInfo.type||(l.num=l.goodsInfo.account_num||l.goodsInfo.account_num),l.slideLists=l.goodsInfo.slide,$("#description").html(l.goodsInfo.description),l.goodsInfo.user_group_price)for(id in l.goodsInfo.user_group_price)l.addGroupPrice(id,l.goodsInfo.user_group_price[id].group_name,l.goodsInfo.user_group_price[id].price)}else l.unit="month";l.unitTitle=l.getUnitName(),l.user_group=l.goodsInfo?l.goodsInfo.user_group:l.userGroups&&l.userGroups.length?l.userGroups[0].id:"",l.userGroupInfo={},l.showGroupInfo=function(){l.user_group?l.userGroupInfo.id&&l.userGroupInfo.id==l.user_group||(l.userGroupInfo={},e.get(t.groupInfoUrl+"&user_group_id="+l.user_group).success(function(e){if(e.message&&!e.message.errno){var t=e.message.message,a=t.package_detail;if("all"!==t.modules||"all"!==t.templates)for(var n in t.group_module_all={},t.group_tempate_all={},a){var i,s,o=a[n].modules_all,r=a[n].templates;for(i in o)t.group_module_all[n]||(t.group_module_all[o[i].mid]=o[i]);for(s in r)t.group_tempate_all[r[s].id]||(t.group_tempate_all[r[s].id]=r[s])}l.userGroupInfo=t}})):l.userGroupInfo={}},l.showGroupInfo()}]),angular.module("storeApp").controller("storePaySettingCtrl",["$scope","$http","config",function(e,t,a){e.alipay=a.alipay,e.wechat_refund=a.wechat_refund,e.ali_refund=a.ali_refund,$("#key").change(function(){e.wechat_refund.key=$("#key").val(),e.$apply()}),$("#cert").change(function(){e.wechat_refund.cert=$("#cert").val(),e.$apply()}),$("#private_key").change(function(){e.ali_refund.private_key=$("#private_key").val(),e.$apply()})}]),angular.module("storeApp").controller("storeOrdersCtrl",["$scope","$http","config",function(t,e,a){t.orderList=a.orderList,t.role=a.role,t.links=a.links,t.order_types=a.order_types,t.goods_types=a.goods_types,t.newPrice=[],t.showChangePriceModal=function(e){$("#change-price").modal("show");e=parseInt(e);t.newPrice.orderid=e},t.changePrice=function(){e.post(a.links.changePrice,{id:t.newPrice.orderid,price:t.newPrice.price}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})},t.refund=function(e,t){var a="./index.php?c=site&a=entry&m=store&do=orders&operate=refund&orderid="+e.id+"&direct=1";refund_url=1===t?a+"&refund_type=founder":a+"&refund_id="+e.refund_id,util.confirm(function(){window.location.href=refund_url},function(){},"确认退款å—?")}}]),angular.module("storeApp").controller("goodsBuyerCtrl",["$scope","$http","config",function(a,n,i){a.duration=1,a.unit=i.unit,a.expiretime=i.expiretime,a.singlePrice=i.singlePrice,a.price=i.singlePrice,a.account_list=i.account_list,a.wxapp=i.wxapp,a.wxapp_account_list=i.wxapp_account_list,a.uniacid=i.first_uniacid,a.goods=i.goods,a.pay_way_list=i.pay_way,a.packages=i.packages,0==a.pay_way_list.length?a.pay_way="":a.pay_way=a.pay_way_list.alipay?"alipay":"wechat",a.changePayWay=function(e){a.pay_way=e},a.changeDuration=function(e){a.duration=e},a.submit_order=function(t){if(a.duration<=0)return util.message("è´ä¹°æ—¶é•¿ä¸åˆæ³•ï¼Œè¯·é‡æ–°å¡«å†™ï¼"),!1;var e={uniacid:a.uniacid,price:i.singlePrice,goodsid:a.goods.id,duration:a.duration,type:a.pay_way,wxapp:a.wxapp};n.post("./index.php?c=site&a=entry&module_name=store&do=goodsbuyer&operate=submit_order&direct=1",e).success(function(e){return 0!=e.message.errno?(util.message(e.message.message),!1):(location.href="./index.php?c=site&a=entry&module_name=store&do=goodsbuyer&operate=pay_order&direct=1&orderid="+e.message.message,void(location.href="order"==t?"./index.php?c=site&a=entry&module_name=store&do=orders&direct=1":"./index.php?c=site&a=entry&module_name=store&do=goodsbuyer&operate=pay_order&direct=1&orderid="+e.message.message))})},a.changeExpire=function(t,e){t=""==t||null==t?a.duration:t,e=""==e||null==e?a.uniacid:e,n.post("./index.php?c=site&a=entry&operate=change_order_expire&direct=1&do=changeorderexpire&module_name=store",{duration:t,unit:a.unit,uniacid:e,goodsid:a.goods.id}).success(function(e){0==e.message.errno&&(a.expiretime=e.message.message,a.price=100*a.singlePrice*t/100)})},a.$watch("duration",function(e,t,a){a.changeExpire(e,"")}),a.$watch("uniacid",function(e,t,a){a.changeExpire("",e)})}]),angular.module("storeApp").controller("storePermissionCtrl",["$scope","$http","config",function(t,a,n){t.blacklist=n.blacklist,t.whitelist=n.whitelist,t.permissionStatus=n.permissionStatus,t.addUsername="",t.changeType=function(e){"close"!=e||t.permissionStatus.close?t.type=e:confirm("确定è¦å…³é—æƒé™è®¾ç½®å—ï¼Ÿå¦‚è‹¥è¿™æ ·åšï¼Œæ‰€æœ‰ç³»ç»Ÿç”¨æˆ·éƒ½å¯è®¿é—®å•†åŸŽï¼")&&(t.type=e,t.changeStatus())},t.changeStatus=function(){a.post(n.links.changeStatus,{type:t.type}).success(function(e){0==e.message.errno?"close"==t.type?(t.permissionStatus.close=!0,util.message(e.message.message)):util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})},t.addUser=function(){a.post(n.links.addUser,{type:t.type,username:t.addUsername}).success(function(e){t.addUsername="",0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})},t.deleteUser=function(e){a.post(n.links.deleteUser,{type:t.type,username:e}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})},t.changeType(n.type)}]),angular.module("systemApp",["we7app"]),angular.module("systemApp").controller("MenuCtrl",["$scope","$http",function(a,n){a.subItemGroup={},a.displayStatus={},a.mainMenu={permission:"",displayorder:0},a.editItemPanel=function(e){e&&(a.activeItem={},a.activeItem=e,$(".js-edit-panel").modal())},a.editMainMenu=function(e,t){a.mainMenu.displayorder=e,a.mainMenu.permission=t,$("#editorder").modal("show")},a.saveorder=function(){n.post("./index.php?c=system&a=menu&do=change_displayorder",a.mainMenu).success(function(e){0==e.message.errno?($("#editorder").modal("hide"),util.message("æ“作æˆåŠŸ",e.redirect,"ajax")):util.message("æ“作失败","","info")})},a.editItem=function(){n.post("./index.php?c=system&a=menu&do=post",a.activeItem).success(function(e){e.message.errno?util.message(e.message.message):(a.activeItem.isNew&&a.subItemGroup[a.activeItem.group].push(a.activeItem),util.message(e.message.message,e.redirect,"ajax"),$(".js-edit-panel").modal("hide"))})},a.addSubItem=function(e,t){a.subItemGroup[e]||(a.subItemGroup[e]=[]);t={title:t.title,url:t.url,permissionName:t.permissionName,icon:t.icon,displayorder:t.displayorder,isDisplay:t.isDisplay,isSystem:!1,group:e,isNew:!0};a.editItemPanel(t)},a.selectMenuIcon=function(){util.iconBrowser(function(e){a.activeItem.icon=e,a.$apply("activeItem")})},a.removeSubItem=function(e,t){e&&confirm("ç¡®è®¤åˆ é™¤æ¤èœå•ï¼Ÿ")&&(void 0===t?n.post("./index.php?c=system&a=menu&do=delete",{permission_name:e}).success(function(e){e.message.errno?util.message(e.message.message):util.message(e.message.message,"refresh")}):a.subItemGroup[e].splice(t,1))},a.changeDisplay=function(t){status=1==a.displayStatus[t]?0:1,n.post("./index.php?c=system&a=menu&do=display_status",{status:status,permission_name:t}).success(function(e){a.displayStatus[t]=!!parseInt(status)})}}]),angular.module("systemApp").controller("WelcomeCtrl",["$scope","$http","config","$filter","we7TypeDefault",function(n,a,i,s,t){n.recommend={recommend:{name:"推è应用",list:[],ads:[],icon:"recommend"},"new-app":{name:"新应用",list:[],ads:[],icon:"new"},essential:{name:"下载排行",list:[],ads:[],icon:"down"},hot:{name:"çƒé—¨æŽ’è¡Œ",list:[],ads:[],icon:"hot"},large:{name:"大é¢åº”用排行",list:[],ads:[],icon:"big"}},require(),require(),require(),n.changeTab=function(a){a&&n.recommend[a].list.length<=0&&(n.showLoading=!0,require())},n.loaderror=0,n.ads=null,n.account_uninstall_modules_nums=0,n.wxapp_uninstall_modules_nums=0,n.account_modules_total=0,n.wxapp_modules_total=0,n.not_installed_module=[],n.not_installed_show=0,n.get_module_statistics=function(){a({url:i.moduleStatisticsUrl,method:"POST",data:{},beforeSend:function(){},complete:function(){}}).success(function(e){0==e.message.errno&&(n.module_statistics=e.message.message)})},n.upgrade_module_nums=[],n.upgrade_module_nums.account_upgrade_module_nums=0,n.upgrade_module_nums.wxapp_upgrade_module_nums=0,n.upgrade_module_list=[],n.upgrade_modules=[],n.get_upgrade_modules=function(){a({url:i.upgradeModulesUrl,method:"POST",data:{unstall:1},beforeSend:function(){},complete:function(){}}).success(function(e){0==e.message.errno&&(n.upgrade_module_list_show=!0,n.upgrade_module_list=e.message.message,n.count_ignore_modules=0,n.count_modules=0,n.count_modules_has_new_version=0,n.count_modules_has_new_branch=0,n.count_modules_uninstall=0,n.upgrade_module_list_all=[],n.ignore_modules=[],n.has_new_version_modules=[],n.has_new_branch_modules=[],n.uninstall_modules=[],angular.forEach(n.upgrade_module_list,function(e){n.count_modules+=1,n.upgrade_module_list_all.length<6&&1!=e.is_ignore&&n.upgrade_module_list_all.push(e),1==e.is_ignore&&(n.count_ignore_modules+=1,n.count_ignore_modules<=6&&n.ignore_modules.push(e)),1==e.has_new_version&&(n.count_modules_has_new_version+=1,n.has_new_version_modules.length<6&&1!=e.is_ignore&&n.has_new_version_modules.push(e)),1==e.has_new_branch&&(n.count_modules_has_new_branch+=1,n.has_new_branch_modules.length<6&&1!=e.is_ignore&&n.has_new_branch_modules.push(e)),1==e.unstall&&(n.count_modules_uninstall+=1,n.count_modules_uninstall<=6&&n.uninstall_modules.push(e))}),n.upgrade_modules=n.upgrade_module_list_all,n.count_ignore_modules==n.count_modules&&(n.upgrade_module_list_show=!1),angular.forEach(n.upgrade_modules,function(a){a.supportArray=[],angular.forEach(t,function(e,t){2==a[t+"_support"]&&a.supportArray.push(t+"_support")})}))})},n.searchType=function(e){n.upgrade_modules=[],"all"==e?(n.upgrade_modules=n.upgrade_module_list_all,n.search_type_name="all"):"has_new_version"==e?(n.upgrade_modules=n.has_new_version_modules,n.search_type_name="has_new_version"):"has_new_branch"==e?(n.upgrade_modules=n.has_new_branch_modules,n.search_type_name="has_new_branch"):"unstall"==e&&(n.upgrade_modules=n.uninstall_modules,n.search_type_name="unstall")},n.upgrade_show=0,n.get_system_upgrade=function(){a({url:i.systemUpgradeUrl,method:"POST",data:{},beforeSend:function(){},complete:function(){util.loaded()}}).success(function(e){0==e.message.errno&&!0===e.message.message&&(n.upgrade_show=1)})},n.get_ads=function(){require()},n.close_ads=function(){n.setCookie("closed_system_ads",angular.toJson(n.ads),365),n.ads=null},n.setCookie=function(e,t,a){var n=new Date;n.setTime(n.getTime()+24*a*60*60*1e3);n="expires="+n.toGMTString();document.cookie=e+"="+t+"; "+n},n.getCookie=function(e){for(var t=e+"=",a=document.cookie.split(";"),n=0;n<a.length;n++){var i=a[n].trim();if(0==i.indexOf(t))return i.substring(t.length,i.length)}return""},n.closeRecommend=function(){n.is_recommend_close=1,n.setCookie("closed_system_recommend",1,1)},n.getRecommendShow=function(){n.is_recommend_close=n.getCookie("closed_system_recommend")},n.getRecommendShow(),n.get_not_installed_module=function(){a.post("./index.php?c=home&a=welcome&do=get_not_installed_modules").success(function(e){0==e.message.errno&&(n.not_installed_module=e.message.message,n.not_installed_module&&(n.not_installed_show=1))})},n.ignoreUpdate=function(t){a.post(i.ignoreUpdateUrl,{name:t}).success(function(e){0==e.message.errno&&(n.upgrade_module_list[t].is_ignore=1)})},n.removeUnstallModule=function(e){var a="";angular.forEach(e.supportArray,function(e,t){a+="&supports[]="+e});e=i.links.removeUnstallModuleUrl+"&module_name="+e.name+a;window.location.href=e},n.get_module_statistics(),n.get_upgrade_modules(),n.get_system_upgrade(),n.get_not_installed_module(),n.get_ads(),n.moduleLink=function(e){1==e.has_new_branch||1==e.has_new_version?location.href=e.link:1==e.unstall&&(2==e.welcome_support?location.href=i.moduleNotInstalledUrl+"support=welcome_support":location.href=i.moduleNotInstalledUrl)},n.today=new Date,n.yestory=n.today-864e5,n.week_ago=n.today-5184e5,n.$watch("dayType",function(e){"today"==e?n.dateRange={startDate:s("date")(n.today,"yyyy-MM-dd"),endDate:s("date")(n.today,"yyyy-MM-dd")}:"yestoday"==e?n.dateRange={startDate:s("date")(n.yestory,"yyyy-MM-dd"),endDate:s("date")(n.yestory,"yyyy-MM-dd")}:"week"==e&&(n.dateRange={startDate:s("date")(n.week_ago,"yyyy-MM-dd"),endDate:s("date")(n.today,"yyyy-MM-dd")})},!0),require(["echarts"],function(e){var t=e.init(document.getElementById("chart-line"));t.showLoading("default",{color:"#3296fa"}),accountOption={tooltip:{trigger:"axis",axisPointer:{type:"line"}},legend:{data:["访问次数","访问人数"],right:"10px"},grid:{left:"20px",right:"40px",bottom:"30px",containLabel:!0},xAxis:{boundaryGap:!1,axisLine:{lineStyle:{color:"#999"},onZero:!0},data:[]},yAxis:{axisLine:{show:!1,lineStyle:{color:"#999"}}},series:[{name:"访问次数",type:"line",smooth:!0,data:[]},{name:"访问人数",type:"line",smooth:!0,data:[]}]},n.dateRange={startDate:s("date")(n.today-5184e5,"yyyy-MM-dd"),endDate:s("date")(n.today,"yyyy-MM-dd")},n.getAccountApi=function(e){n.timeType=e,a.post(i.links.accountApi,{type:"all",time_type:e,daterange:n.dateRange}).success(function(e){t.hideLoading(),accountOption.xAxis.data=e.message.message.data_x,accountOption.series[0].data=e.message.message.data_y,accountOption.series[1].data=e.message.message.data_y_ip,t.setOption(accountOption)})},n.timeType="week",n.getAccountApi(n.timeType),n.$watch("dateRange",function(e,t){e&&e!=t&&(n.dateRange.startDate=moment(e.startDate).format("YYYY-MM-DD"),n.dateRange.endDate=moment(e.endDate).format("YYYY-MM-DD"),n.getAccountApi("daterange"))},!0)}),require(["echarts"],function(e){$("#fangwen").addClass("in active");var t=e.init(document.getElementById("chart-line-fangwen"));t.showLoading("default",{color:"#3296fa"}),$("#fangwen").removeClass("in active"),webOption={tooltip:{trigger:"axis",axisPointer:{type:"line"}},legend:{data:["访问次数","访问人数"],right:"10px"},grid:{left:"20px",right:"40px",bottom:"30px",containLabel:!0},xAxis:{boundaryGap:!1,axisLine:{lineStyle:{color:"#999"},onZero:!0},data:[]},yAxis:{axisLine:{show:!1,lineStyle:{color:"#999"}}},series:[{name:"访问次数",type:"line",smooth:!0,data:[]},{name:"访问人数",type:"line",smooth:!0,data:[]}]},n.dateRange={startDate:s("date")(n.today-5184e5,"yyyy-MM-dd"),endDate:s("date")(n.today,"yyyy-MM-dd")},n.getWebApi=function(e){n.timeType=e,a.post(i.links.accountApi,{time_type:e,type:"web",daterange:n.dateRange}).success(function(e){t.hideLoading(),webOption.xAxis.data=e.message.message.data_x,webOption.series[0].data=e.message.message.data_y,webOption.series[1].data=e.message.message.data_y_ip,t.setOption(webOption)})},n.timeType="week",n.getWebApi(n.timeType),n.$watch("dateRange",function(e,t){e&&e!=t&&(n.dateRange.startDate=moment(e.startDate).format("YYYY-MM-DD"),n.dateRange.endDate=moment(e.endDate).format("YYYY-MM-DD"),n.getWebApi("daterange"))},!0)}),require(["echarts"],function(e){$("#app_count").addClass("in active");var t=e.init(document.getElementById("chart-line-app-count"));t.showLoading("default",{color:"#3296fa"}),$("#app_count").removeClass("in active"),appOption={tooltip:{trigger:"axis",axisPointer:{type:"line"}},legend:{data:["访问次数","访问人数"],right:"10px"},grid:{left:"20px",right:"40px",bottom:"30px",containLabel:!0},xAxis:{boundaryGap:!1,axisLine:{lineStyle:{color:"#999"},onZero:!0},data:[]},yAxis:{axisLine:{show:!1,lineStyle:{color:"#999"}}},series:[{name:"访问次数",type:"line",smooth:!0,data:[]},{name:"访问人数",type:"line",smooth:!0,data:[]}]},n.dateRange={startDate:s("date")(n.today-5184e5,"yyyy-MM-dd"),endDate:s("date")(n.today,"yyyy-MM-dd")},n.getAppApi=function(e){n.timeType=e,a.post(i.links.accountApi,{time_type:e,type:"app",daterange:n.dateRange}).success(function(e){t.hideLoading(),appOption.xAxis.data=e.message.message.data_x,appOption.series[0].data=e.message.message.data_y,appOption.series[1].data=e.message.message.data_y_ip,t.setOption(appOption)})},n.timeType="week",n.getAppApi(n.timeType),n.$watch("dateRange",function(e,t){e&&e!=t&&(n.dateRange.startDate=moment(e.startDate).format("YYYY-MM-DD"),n.dateRange.endDate=moment(e.endDate).format("YYYY-MM-DD"),n.getAppApi("daterange"))},!0)})}]),angular.module("systemApp").controller("ipWhiteListCtrl",["$scope","$http","config",function(t,a,e){t.lists=e.lists,t.links=e.links,t.ips="",t.changeStatus=function(e){a.post(t.links.change_status,{ip:e}).success(function(e){0==e.message.errno?location.reload():util.message(e.message.message,e.redirect,"ajax")})},t.saveIp=function(){$("#myModalIp").modal("hide"),a.post(t.links.add_link_ips,{ips:t.ips}).success(function(e){0!=e.message.errno?util.message(e.message.message):util.message("æ·»åŠ æˆåŠŸ",e.redirect,"ajax")})}}]),angular.module("systemApp").controller("sensitiveWord",["$scope","$http","config",function(t,a,e){t.lists=e.lists,t.links=e.links,t.word="",t.saveWords=function(){$("#myModalSensitive").modal("hide"),a.post(t.links.add_word_link,{word:t.word}).success(function(e){0!=e.message.errno?util.message(e.message.message):util.message("æ·»åŠ æˆåŠŸ",e.redirect,"ajax")})},t.del=function(e){a.post(t.links.del_word_link,{word:e}).success(function(e){0!=e.message.errno?util.message(e.message.message):util.message("åˆ é™¤æˆåŠŸ",e.redirect,"ajax")})}}]),angular.module("systemApp").controller("SystemThirdpartyLogin",["$scope","$http","serviceCommon","config",function(a,n,i,s){a.saveSettingUrl=s.saveSettingUrl,a.thirdlogin=s.thirdlogin,a.links=s.links,a.siteroot=s.siteroot,a.url=s.url,a.binds=s.binds,a.bind=s.bind,a.newappid="",a.newappsecret="",a.httpChange=function(e,t){switch(e){case"authstate":n.post(a.links.save_setting,{authstate:"authstate",type:t}).success(function(e){0==e.message.errno?util.message("修改æˆåŠŸ",e.redirect):util.message("修改失败,请ç¨åŽé‡è¯•ï¼")});break;case"appid":$("#AppID").modal("hide"),n.post(a.links.save_setting,{appid:a.newappid,type:t}).success(function(e){0==e.message.errno?util.message("修改æˆåŠŸ",e.redirect):util.message("修改失败,请ç¨åŽé‡è¯•ï¼")});break;case"appsecret":$("#AppSecret").modal("hide"),n.post(a.links.save_setting,{appsecret:a.newappsecret,type:t}).success(function(e){0==e.message.errno?util.message("修改æˆåŠŸ",e.redirect):util.message("修改失败,请ç¨åŽé‡è¯•ï¼")})}},a.success=function(e){var e=parseInt(e),t=$('<span class="label label-success" style="position:absolute;z-index:10;margin-top:10px"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>');i.copySuccess(e,t)},a.saveSettingSwitch=function(e,t){t=0==t||null==t?1:0,window.location.href=s.saveSettingUrl+"&key="+e+"&value="+t+"&submit=1"},a.saveSetting=function(e,t){e=e.value.id||e.value;window.location.href=s.saveSettingUrl+"&key="+t+"&value="+e+"&submit=1"}}]),angular.module("systemApp").controller("systemOauthCtrl",["$scope","$http","config",function(t,e,a){t.oauthHost=a.oauthHost,t.originalHost=a.oauthHost,t.oauthAccount=a.oauthAccount,t.oauthtitle=a.oauthAccounts[a.oauthAccount],t.links=a.links,t.saveOauth=function(){e.post(t.links.oauth_link,{account:t.oauthAccount,host:t.oauthHost}).success(function(e){0!=e.message.errno?util.message(e.message.message):(t.originalHost=t.oauthHost,util.message("æˆåŠŸ",e.redirect,"ajax"))})}}]),angular.module("systemApp").controller("SmsSignCtrl",["$scope","$http","config",function(t,a,e){t.all_signatures=e.all_signatures,t.site_sms_sign=e.site_sms_sign,t.links=e.links,t.saveSms=function(e){a.post(t.links.site_sms_sign_link,{register:t.site_sms_sign.register,find_password:t.site_sms_sign.find_password,user_expire:t.site_sms_sign.user_expire}).success(function(e){0!=e.message.errno?util.message(e.message.message,e.redirect,"error"):util.message("设置æˆåŠŸ",e.redirect,"success")})}}]),angular.module("systemApp").controller("systemInfoCtrl",["$scope","$http","config",function(t,e,a){t.content="查看",t.dbcontent="查看",t.attachSize=function(){-1!=t.content.indexOf("查看")&&(t.content="请ç¨å€™...",e.get(a.get_attach_size_url).success(function(e){e.message.message.attach_size?t.content=e.message.message.attach_size:t.content=0}))},t.databaseSize=function(){-1!=t.dbcontent.indexOf("查看")&&(t.dbcontent="请ç¨å€™...",e.get(a.get_database_size_url).success(function(e){e.message.message.database_size?t.dbcontent=e.message.message.database_size:t.dbcontent=0}))}}]),angular.module("systemApp").controller("systemCheckCtrl",["$scope","$http","config",function(a,e,n){a.system_check_items=n.system_check_items,a.account_post_url=n.links.account_post_url,a.check_num=n.check_num+3,a.check_wrong_num=n.check_wrong_num,a.checkMysqlTableStatus="",a.checkAccountStatus="",a.checkFpmStatus="",a.checkSystem=function(t){e.post(n.links.check_system,{type:t}).success(function(e){0==e.message.errno&&e.message.message&&(t?(a.system_check_items[t]=e.message.message.system_check_items,!1===e.message.message.system_check_items.check_result&&(a.check_wrong_num+=1)):(a.system_check_items=e.message.message.system_check_items,a.check_wrong_num+=e.message.message.check_wrong_num))})},a.checkMysqlTable=function(t){a.checkMysqlTableStatus=0,e.get(n.links.check_table_link).success(function(e){0==e.message.errno&&e.message.message&&-1==e.message.message.status?(a.wrong_tables=e.message.message.list,a.checkMysqlTableStatus=1):(a.checkMysqlTableStatus=1,a.wrong_tables=""),""!=a.wrong_tables&&(t&&(a.check_wrong_num+=1),a.checkMysqlTableStatus=3)})},a.checkFpm=function(t){a.checkFpmStatus=0,e.get(n.links.check_fpm_link).success(function(e){e?(a.checkFpmStatus=2,t&&(a.check_wrong_num+=1)):a.checkFpmStatus=1})},a.errorAccounts=[],a.checkAuthAccount=function(t){a.checkAccountStatus=0,a.errorAccounts=[],e.get(n.links.check_auth_accounts).success(function(e){0==e.message.errno&&e.message.message&&0==e.message.message.status?a.checkAccountStatus=1:(a.checkAccountStatus=2,t&&(a.check_wrong_num+=1),a.errorAccounts=e.message.message.list)})},a.checkAll=function(){a.checkSystem(""),a.checkFpm(!0),a.checkAuthAccount(!0),a.checkMysqlTable(!0)}}]),angular.module("systemApp").controller("systemSiteSettingCtrl",["$scope","$http","config",function(t,n,i){t.settings=i.settings,t.template_ch_name=i.template_ch_name,t.template=i.template,t.login_ch_name=i.login_ch_name,t.policeicp={value:{location:"",code:""}},t.icps=i.icps,t.saveSetting=function(e,t,a){n.post(i.links.saveSettingUrl,{key:t,value:e.value,is_int:"string"==a?0:1}).success(function(e){0==e.message.errno?util.message("æ“作æˆåŠŸ!",location.reload(),"success"):util.message("æ“作失败!",e.redirect,"error")})},t.saveSettingSwitch=function(e,t,a){if("login_verify_status"===e&&!a)return $("#login_verify").modal("show"),!1;n.post(i.links.saveSettingUrl,{key:e,value:t=0==t||null==t||""==t?1:0,is_int:1}).success(function(e){0==e.message.errno?util.message("æ“作æˆåŠŸ!",location.reload(),"success"):util.message("æ“作失败!",e.redirect,"error")})},t.changePicture=function(a,t){require(["fileUploader"],function(e){e.init(function(e){var t;value="slides"==a?(t=[],angular.forEach(e,function(e){t.push(e.attachment)}),t):e.attachment,n.post(i.links.saveSettingUrl,{key:a,value:value,is_int:0}).success(function(e){0==e.message.errno?util.message("æ·»åŠ æˆåŠŸ!",location.reload(),"success"):util.message("æ·»åŠ å¤±è´¥!",e.redirect,"error")})},{type:"image",direct:!0,multiple:t,uniacid:0,global:!0})})},t.changeDefault=function(e){n.post(i.links.saveSettingUrl,{key:e,value:"",is_int:0}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,e.redirect,"error")})},t.showCoordinate=function(){require(["util"],function(t){t.map({},function(e){key="baidumap",n.post(i.links.saveSettingUrl,{key:key,lng:e.lng,lat:e.lat}).success(function(e){0==e.message.errno?t.message("æ“作æˆåŠŸ!",location.reload(),"success"):t.message("æ“作失败!",e.redirect,"error")})})})},t.addIcps=function(){t.domains_data=[""],t.icps_data=[""],t.policeicp_location_data=[""],t.policeicp_code_data=[""],t.electronic_license_data=[""],$("#add-icps").modal("show")},t.pulsIcps=function(){t.domains_data.push(""),t.icps_data.push(""),t.policeicp_location_data.push(""),t.policeicp_code_data.push(""),t.electronic_license_data.push("")},t.delIcps=function(e){t.domains_data.splice(e,1),t.icps_data.splice(e,1),t.policeicp_location_data.splice(e,1),t.policeicp_code_data.splice(e,1),t.electronic_license_data.splice(e,1)},t.editIcp=function(e){t.key=e,t.currentIcp=angular.copy(t.icps[e]),$("#edit-icp").modal("show")},t.saveIcps=function(){t.icps_form.$valid&&n.post(i.links.editIcpUrl,t.currentIcp).success(function(e){0==e.message.errno?($("#add-icps").modal("hide"),util.message(e.message.message,"refresh","success")):util.message(e.message.message,"","info")})},t.updateIcp=function(){t.icps_edit.$valid&&n.post(i.links.editIcpUrl,t.currentIcp).success(function(e){0==e.message.errno?($("#edit-icp").modal("hide"),util.message(e.message.message,"refresh","success")):util.message(e.message.message,"","info")})},t.deleteIcp=function(e){n.post(i.links.delIcpUrl+"&id="+e).success(function(e){0==e.message.errno?($("#edit-icp").modal("hide"),util.message(e.message.message,"refresh","success")):util.message(e.message.message,"","info")})}}]),angular.module("systemApp").controller("globalAttachmentCtrl",["$scope","$http","config",function(e,a,n){e.upload=n.upload,e.saveSetting=function(e,t){e="image_thumb"==t||"attachment_by_uid"==t?e:e.value;e={token:n.token,submit:1,key:t,value:e};a.post(n.saveSettingUrl,e).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,"","error")})}}]),angular.module("systemApp").controller("databaseCtrl",["$scope","$http","config",function(n,e,i){n.moduleCloud=i.moduleCloud,n.links=i.links,n.all=!1,n.changeSelect=function(){for(var e in n.all=!0,n.moduleCloud)1!=n.moduleCloud[e].module_status||n.moduleCloud[e].selected||(n.all=!1)},n.selectAll=function(){for(var e in n.moduleCloud)1==n.moduleCloud[e].module_status&&(n.moduleCloud[e].selected=n.all)},n.loadAll=function(){for(var e in n.moduleCloud)1==n.moduleCloud[e].module_status&&n.moduleCloud[e].selected&&n.loadData(e)},n.loadData=function(a){n.moduleCloud[a].module_status=33,e.post(i.links.loadData,{module_name:a}).success(function(e){if(e.message&&0==e.message.errno)if(n.moduleCloud[a].scrap_table=e.message.message,e.message.message){for(var t in n.moduleCloud[a].num=0,e.message.message)n.moduleCloud[a].num++;n.moduleCloud[a].module_status=44}else n.moduleCloud[a].module_status=2,n.changeStatus(a,2);else util.message(e.message?e.message.message:n.moduleCloud[a].title+"检测出错"),n.moduleCloud[a].module_status=1})},n.changeStatus=function(t,a){a=a||(3!=n.moduleCloud[t].module_status?3:1),e.post(i.links.changeStatus,{module_name:t,module_status:a}).success(function(e){0==e.message.errno?n.moduleCloud[t].module_status=a:util.message(e.message.message)})},n.showDetail=function(e){$("#scrap_table_detail").modal("show"),n.activeModule=n.moduleCloud[e]},n.deleteScrapTable=function(t){e.post(i.links.deleteScrapTable,{module_name:t,tables:n.moduleCloud[t].scrap_table}).success(function(e){0==e.message.errno?(n.moduleCloud[t].scrap_table="",n.moduleCloud[t].module_status=55,util.message("åˆ é™¤æˆåŠŸï¼","","success")):util.message(e.message.message)})}}]),angular.module("systemApp").service("serviceCommon",["$rootScope",function(e){var t={copySuccess:function(e,t){var e=parseInt(e),t=t,a=$("#copy-"+e).next().html();(!a||a.indexOf('<span class="label label-success" style="position:absolute;z-index:10"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>')<0)&&$("#copy-"+e).after(t),setTimeout(function(){t.remove()},2e3)}};return t}]),angular.module("userCardApp",["wapeditorApp"]).controller("MainCtrl",["$scope","widget","config","serviceBase","serviceUserCardBase","serviceSubmit","serviceCommon","$sanitize",function(n,e,t,i,a,s,o,r){n.modules=[],n.editors=[],n.activeModules=i.initActiveModules(t.activeModules),n.activeItem={},n.activeIndex=0,n.index=t.activeModules?t.activeModules.length:0,n.submit={params:{},html:""},n.newcard=t.newcard,n.fansFields=t.fansFields,n.$on("serviceBase.editors.update",function(e,t){n.editors=t}),n.$on("serviceBase.activeItem.update",function(e,t){n.activeItem=t}),n.$on("serviceBase.activeModules.update",function(e,t){n.activeModules=t}),n.addItem=function(e){i.addItem(e)},n.editItem=function(e){a.editItem(e)},n.deleteItem=function(e){i.deleteItem(e)},n.init=function(e,t){var a;n.modules=i.setModules(e,t),0<n.activeModules.length&&(a=[],angular.forEach(n.activeModules,function(e,t){e&&a.push(e.id)})),angular.forEach(n.modules,function(e,t){e.defaultshow&&-1==$.inArray(e.id,a)&&i.addItem(e.id)})},n.url=function(e){return o.url(e)},n.tomedia=function(e){return o.tomedia(e)},n.submit=function(e){n.submit=s.submit(),n.$apply("submit"),$(e.target).parents("form").submit()},n.addFields=function(){a.addFields()},n.removeFields=function(e){a.removeFields(e)},n.addNums=function(){a.addNums()},n.removeNums=function(e){a.removeNums(e)},n.addRecharges=function(){a.addRecharges()},n.removeRecharges=function(e){a.removeRecharges(e)},n.addTimes=function(){a.addTimes()},n.removeTimes=function(e){a.removeTimes(e)},n.selectCoupon=function(){a.selectCoupon()},n.clearCoupon=function(){a.clearCoupon()},n.addThumb=function(e){a.addThumb(e)},n.addBgThumb=function(){a.addBgThumb()},$(".single-submit").on("click",function(e){n.submit(e)}),n.init(null,["cardBasic","cardActivity","cardNums","cardTimes","cardRecharge"]),n.activeModules[1].params.discounts=t.discounts,n.editItem(0)}]),angular.module("userCardApp").service("serviceUserCardBase",["$rootScope","serviceBase",function(n,i){var e={triggerActiveItem:function(e){$(".app-side .editor").css("marginTop","0"),i.triggerActiveItem(e)},editItem:function(t){var e=i.getBaseData("activeModules");"string"==typeof t&&angular.forEach(e,function(e){e.id==t&&(t=e.index)}),i.editItem(t)},addFields:function(){var e=i.getBaseData("activeItem");e.params.fields.push({title:"",require:1,bind:"",issystem:0}),i.setBaseData("activeItem",e),n.$broadcast("serviceBase.activeItem.update",e)},removeFields:function(e){if("mobile"==e.bind||"realname"==e.bind)return!1;var t=i.getBaseData("activeItem");t.params.fields=_.without(t.params.fields,e),i.setBaseData("activeItem",t),n.$broadcast("serviceBase.activeItem.update",t)},addNums:function(){i.getBaseData("activeItem").params.nums.push({recharge:"",num:""})},removeNums:function(e){var t=i.getBaseData("activeItem");t.params.nums=_.without(t.params.nums,e),i.setBaseData("activeItem",t),n.$broadcast("serviceBase.activeItem.update",t)},addRecharges:function(){var e=i.getBaseData("activeItem");e.params.recharges.push({condition:"",back:"",backtype:"0",backunit:"å…ƒ"}),i.setBaseData("activeItem",e),n.$broadcast("serviceBase.activeItem.update",e)},removeRecharges:function(e){var t=i.getBaseData("activeItem");t.params.recharges=_.without(t.params.recharges,e),i.setBaseData("activeItem",t),n.$broadcast("serviceBase.activeItem.update",t)},addTimes:function(){var e=i.getBaseData("activeItem");e.params.times.push({recharge:"",time:""}),i.setBaseData("activeItem",e),n.$broadcast("serviceBase.activeItem.update",e)},removeTimes:function(e){var t=i.getBaseData("activeItem");t.params.times=_.without(t.params.times,e),i.setBaseData("activeItem",t),n.$broadcast("serviceBase.activeItem.update",t)},selectCoupon:function(){var t=i.getBaseData("activeItem");util.coupon(function(e){t.params.grant.coupon=[],angular.forEach(e,function(e){t.params.grant.coupon.push({couponTitle:e.title,coupon:e.id})}),i.setBaseData("activeItem",t),n.$apply(),n.$broadcast("serviceBase.activeItem.update",t)},{multiple:!0})},clearCoupon:function(){var e=i.getBaseData("activeItem");e.params.grant.coupon=[],i.setBaseData("activeItem",e),n.$broadcast("serviceBase.activeItem.update",e)},addThumb:function(t){var a=i.getBaseData("activeItem");require(["fileUploader"],function(e){e.show(function(e){a.params[t]=e.url,i.setBaseData("activeItem",a),n.$apply(),n.$broadcast("serviceBase.activeItem.update",a)},{direct:!0,multiple:!1})})},addBgThumb:function(){var t=i.getBaseData("activeItem");require(["fileUploader"],function(e){e.show(function(e){t.params.background.image=e.url,i.setBaseData("activeItem",t),n.$apply(),n.$broadcast("serviceBase.activeItem.update",t)},{direct:!0,multiple:!1})})}};return e}]),angular.module("userCardApp").controller("CardActivityCtrl",["$scope",function(a){a.$watch("activeItem.params.grant_rate",function(e,t){(e+="").match(/^([1-9]\d*(\.(\d)?)?|0(\.(\d)?)?)?$/)?a.activeItem.params.grant_rate=e:a.activeItem.params.grant_rate=t})}]),angular.module("userCardApp").controller("CardBasicCtrl",["$scope","config",function(e,t){e.creditnames=t.creditnames,e.siteroot=t.siteroot,e.recharge_src=e.siteroot+"/app/resource/images/sum-recharge.png",e.scanpay_src=e.siteroot+"/app/resource/images/scan-pay.png"}]),angular.module("userCardApp").controller("CardNumsCtrl",["$scope",function(e){}]),angular.module("userCardApp").controller("CardRechargeCtrl",["$scope",function(e){require(["bootstrap"],function(e){e(".dropdown-toggle").dropdown()})}]),angular.module("userCardApp").controller("CardTimesCtrl",["$scope",function(e){}]),angular.module("userCenterApp",["wapeditorApp"]),angular.module("userCenterApp").controller("MainCtrl",["$scope","$timeout","widget","config","serviceCommon","serviceSetStyle","serviceBase","serviceUcSubmit","serviceUpwardCompatible",function(s,e,t,a,n,i,o,r,l){for(var c in s.modules=[],s.editors=[],s.activeModules=a.activeModules||[],s.activeMenus=a.activeMenus||[],s.submit={params:{},html:""},s.isNew=!0,s.siteroot=a.siteroot,s.logo_url=s.siteroot+"/app/resource/images/heading.jpg",_.isEmpty(s.activeModules)||1==s.activeModules[0].params.isnew||(s.isNew=!1),s.siteEntrance=a.links.murl,s.activeItem={},s.activeIndex=0,s.index=s.activeModules.length||0,o.setBaseData("index",s.index),o.setBaseData("activeModules",s.activeModules),s.pageLength=!_.isEmpty(s.activeModules)&&s.activeModules[0].params.pageLength?s.activeModules[0].params.pageLength:1,s.isLongPage=!0,s.pageLengths={1:1,2:2,3:3,4:4,5:5},s.lineHeights={1:1,1.25:1.25,1.5:1.5,2:2,2.5:2.5},s.fontSizes={12:12,14:14,16:16,18:18,20:20,22:22,24:24,26:26,28:28,30:30,32:32,34:34,36:36,38:38,40:40},s.isNew||(s.activeModules=l.compatibility(s.activeModules),s.activeModules[0].params.isnew=1,void 0===s.activeModules[0].params.pageLength&&(s.activeModules[0].params.pageLength=Math.ceil(($(".modules").height()+520)/568)),1<s.activeModules[0].params.pageLength&&(s.pageLength=s.activeModules[0].params.pageLength,o.setBaseData("pageLength",s.pageLength),e(function(){$(".app-content").css("height",568*s.pageLength+"px")},100)),e(function(){var a=0,n=height="";$(".modules>div").each(function(){var e=parseInt($(this).attr("index"));if(n=$(this).find("div.ng-scope[ng-controller$='Ctrl']").css("width"),height=$(this).find("div.ng-scope[ng-controller$='Ctrl']").css("height"),0<e){for(var t in s.activeModules)s.activeModules[t].index==e&&(a+=parseInt(s.activeModules[t].marginTop),s.activeModules[t].params.positionStyle.width=parseInt(n),s.activeModules[t].params.positionStyle.height=parseInt(height),s.activeModules[t].params.positionStyle.top=a,s.activeModules[t].positionStyle="position:absolute;width:"+n+";height:"+height+";left:"+s.activeModules[t].params.positionStyle.left+"px;top:"+a+"px;",$(this).find("div[ng-controller]").attr("style",s.activeModules[t].positionStyle));a+=parseInt(height)}t++}),o.setBaseData("activeModules",s.activeModules)},1e3)),s.activeModules)s.activeModules[c].originParams=angular.copy(s.activeModules[c].params);s.success=function(e){var e=parseInt(e),t=$('<span class="label label-success" style="position:absolute;z-index:10;width:90px;height:34px;line-height:28px;"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>');n.copySuccess(e,t)},s.$on("serviceBase.editors.update",function(e,t){s.editors=t}),s.$on("serviceBase.activeItem.update",function(e,t){s.activeItem=t}),s.$on("serviceBase.activeModules.update",function(e,t){s.activeModules=t}),s.$on("serviceBase.activeItem.params.update",function(e,t){s.activeItem.params=t}),s.$on("serviceBase.activeItem.animationName.update",function(e,t){s.activeItem.params.animationStyle.animationName=t}),s.$on("serviceBase.activeItem.style.update",function(e,t,a,n,i){s.activeItem.params[t]=a,s.activeItem[t]=n,void 0!==i&&(s.activeItem.transform=i)}),s.$on("updateScope",function(e,t){angular.forEach(t,function(e,t){s[t]=e})}),s.addItem=function(e){o.addItem(e,"uc")},s.editItem=function(e){o.editItem(e)},s.deleteItem=function(e){o.deleteItem(e)},s.submit=function(e){s.submit=r.submit(),s.$apply("submit"),$(e.target).parents("form").submit()},s.init=function(e,t){var a;s.modules=o.setModules(e,t),0<s.activeModules.length&&(a=[],angular.forEach(s.activeModules,function(e,t){e&&a.push(e.id)})),angular.forEach(s.modules,function(e,t){e.defaultshow&&-1==$.inArray(e.id,a)&&o.addItem(e.id)})},s.setModulePositionStyle=function(e){i.setModulePositionStyle(e)},s.eleAnimationIns=function(e){i.eleAnimationIns(e)},s.savePagePosition=function(){i.savePagePosition(s.activeModules)},s.saveModulePosition=function(){i.saveModulePosition(s.activeItem)},s.changeTextAlign=function(e){i.changeTextAlign(s.activeItem,e)},s.changeBorderWidth=function(){i.changeBorderWidth(s.activeItem)},s.changeInnerHeight=function(){i.changeInnerHeight(s.activeItem)},s.changePageLength=function(e){if(angular.isString(e))if("minus"==e&&1<s.pageLength)e=s.pageLength-1;else{if(!("plus"==e&&s.pageLength<5))return!1;e=s.pageLength+1}var t=i.changePageLength(e,s.activeModules);o.setBaseData({pageLength:parseInt(e),activeModules:t})},s.clearModuleStyle=function(){i.clearModuleStyle(s.activeItem)},s.addThumb=function(t){require(["fileUploader"],function(e){e.show(function(e){s.activeItem.params[t]=e.url,s.$apply("activeItem")},{direct:!0,multiple:!1})})},s.showIconBrowser=function(t){util.iconBrowser(function(e){t.css.icon.icon=e,s.$apply("activeMenus")})},s.addMenu=function(){s.activeMenus.push({icon:"",css:{icon:{icon:"fa fa-external-link"}},name:"",url:""})},s.removeMenu=function(e){s.activeMenus=_.without(s.activeMenus,e)},$(".single-submit").on("click",function(e){s.submit(e)}),s.init(null,["UCheader"]),s.changePageLength(s.pageLength),s.editItem(0),s.$watch("activeItem.params.baseStyle",function(e){e&&i.setModuleBaseStyle(e)},!0),s.$watch("activeItem.params.borderStyle",function(e){e&&i.setModuleBorderStyle(e)},!0),s.$watch("activeItem.params.shadowStyle",function(e){e&&i.setModuleShadowStyle(e)},!0),s.$watch("activeItem.params.animationStyle",function(e){e&&i.setModuleAnimationStyle(e)},!0),s.$watch("activeItem.params.positionStyle",function(e){e&&i.setModulePositionStyle(e)},!0)}]),angular.module("userCenterApp").service("serviceUcSubmit",["serviceBase","serviceCommon",function(n,p){var e={submit:function(){var u="",e={params:{},html:""},t=$($(".modules").html()),d=n.getBaseData("activeModules"),a=$(".app-usercenter").height(),a=$(".app-content").height()-a+"px";t.find("div.ng-scope[ng-controller$='Ctrl']").each(function(){var e,t=_.findIndex(d,{index:parseInt($(this).parent().parent().attr("index"))}),a=angular.copy(d[t].params);$(this).find(".js-default-content").remove();var n=$(this).parent().parent().attr("name").toLowerCase(),i=$(this).css("top"),s=$(this).css("left"),o=$(this).css("width"),r=$(this).css("height"),l="position:absolute;top:"+i+";left:"+s+";width:"+o+";height:"+r+";";switch(d[t].params.positionStyle.top=parseInt(i),d[t].params.positionStyle.left=parseInt(s),d[t].params.positionStyle.width=parseInt(o),d[t].params.positionStyle.height=parseInt(r),d[t].positionStyle=l,n){case"link":var c=this;angular.forEach(a.items,function(e,t){(e.selectCate.pid||e.selectCate.cid)&&$(c).find(".list-group").children().eq(t).replaceWith("<div>"+p.buildDataTagBegin("link",e)+'<div class="list-group-item ng-scope"><a href="{$row[url]}" class="clearfix"><span class="app-nav-title"> {$row[title]}<i class="pull-right fa fa-angle-right"></i></span></a></div>'+p.buildDataTagEnd()+"</div>")});break;case"richtext":d[t]&&(d[t].params.content="")}e=$(this).html(),"header"!=n&&(l=$(this).attr("style"),u+='<div type="'+n+'" style="'+l+'">'+e+"</div>"),t++});t=d[0].params.bgColor||"";return u=(u=(u=(u='<div class="js-design-page" style="background-color:'+t+";height:"+a+';position:absolute;">'+u+"</div>").replace(/<\!\-\-([^-]*?)\-\->/g,"")).replace(/ ng\-[a-zA-Z-]+=\"[^\"]*\"/g,"")).replace(/ ng\-[a-zA-Z]+/g,""),e.html=u,e.params=angular.copy(d),p.stripHaskey(e.params),e}};return e}]),angular.module("userCreateGroup",["we7app"]),angular.module("userCreateGroup").controller("userCreateGroupDisplay",["$scope","config","we7TypeDefault",function(e,t,a){e.lists=t.lists,e.we7TypeDefault=a,e.edit=function(e){window.location.href=t.links.groupPost+"&id="+e},e.delete=function(e){util.confirm(function(){window.location.href=t.links.groupDel+"&id="+e},function(){return!1},"ç¡®è®¤åˆ é™¤å—?")}}]),angular.module("userCreateGroup").controller("userCreateGroupPost",["$scope","config","we7TypeDefault",function(a,e,t){a.groupInfo=e.groupInfo,a.groupInfo||(a.groupInfo={},angular.forEach(t,function(e,t){a.groupInfo["max"+t]=0}))}]),angular.module("userGroup",["we7app"]),angular.module("userGroup").controller("UserGroupDisplay",["$scope","$http","config","we7TypeDefault",function(t,a,e,n){t.lists=e.lists,t.links=e.links,t.we7TypeDefault=n,t.editGroup=function(e){e=parseInt(e);location.href=t.links.groupPost+"id="+e},t.delGroup=function(e){e=parseInt(e);util.confirm(function(){a.post(t.links.groupDel,{id:e}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})},function(){return!1},"ç¡®è®¤åˆ é™¤å—?")}}]),angular.module("userGroup").controller("UserGroupPost",["$scope","$http","$compile","config","we7TypeDefault",function(r,e,l,i,t){r.groupInfo=i.groupInfo,r.packages=i.packages,r.changeText=function(e){var t=$(e)[0].target.text;$(e)[0].target.text="展开"==t?"收起":"展开"},r.groupInfo||(r.groupInfo={},angular.forEach(t,function(e,t){r.groupInfo["max"+t]=0})),null==r.groupInfo&&(r.groupInfo={check_all:!1}),r.hideCheckAll=!1,r.searchKeywords="";var c,s=i.pagesize;null==i.packages||Math.ceil(i.packages.length/s);if(r.checkedGroup=[],r.groupInfo.check_all)r.checkedGroup=angular.copy(i.packages),r.checkedGroup.unshift({id:"-1",name:"所有æœåŠ¡"});else if(0<i.checkedGroup.length)for(var a in i.checkedGroup)r.checkedGroup.push(i.checkedGroup[a]);r.user_modules={groups:i.packages},r.selectUniGroup=function(){},r.setChecked=function(){var a=[];angular.forEach(r.checkedGroup,function(e){a.push(e.id)}),-1!=$.inArray("-1",a)?angular.forEach(r.packages,function(e,t){r.packages[t].checked=!0}):angular.forEach(r.packages,function(e,t){-1==$.inArray(e.id,a)?r.packages[t].checked=!1:r.packages[t].checked=!0})},r.removeCheckedGroupItem=function(a){angular.forEach(r.checkedGroup,function(e,t){e.id==a&&r.checkedGroup.splice(t,1),-1==+a&&(r.groupInfo.check_all=!1,r.checkedGroup=[])}),r.setChecked()},r.loadChange=function(){$(".we7-group-show").each(function(){$(this).removeClass("low"),$(this).removeClass("closed"),70<$(this).find(".group-app-list").outerHeight()?($(this).addClass("closed"),$(this).find(".action").off("click").on("click",function(){$(this).parent().toggleClass("closed")})):$(this).addClass("low")})},r.pushCheckedGroupItem=function(a,e){var n;e.target.checked?(n=!1,angular.forEach(r.checkedGroup,function(e,t){e.id==a.id&&(n=!0)}),n||(r.checkedGroup.push(a),r.setChecked())):-1==+r.checkedGroup[0].id?(r.checkedGroup=[],r.groupInfo.check_all=!1,r.setChecked()):r.removeCheckedGroupItem(a.id)},r.checkAllGroup=function(e){e.target.checked?(r.checkedGroup=angular.copy(i.packages),r.checkedGroup.unshift({id:"-1",name:"所有æœåŠ¡"}),r.groupInfo.check_all=!0):(r.checkedGroup=[],r.groupInfo.check_all=!1),r.setChecked()},r.setPackagesData=function(e){var t=-1,a=(e-1)*s;r.packages=[];var n=0;for(id in i.packages)r.searchKeywords&&i.packages[id].name.indexOf(r.searchKeywords)<=-1||(n+=1);for(id in i.packages)if(!(r.searchKeywords&&i.packages[id].name.indexOf(r.searchKeywords)<=-1||++t<a)){if(a+s<=t)break;r.packages.push(i.packages[id])}return r.setChecked(),Math.ceil(n/s)},r.loadMore=function(e,t,a){if(1==(t=+t)&&""==r.searchKeywords?r.hideCheckAll=!1:r.hideCheckAll=!0,(c=r.setPackagesData(t))<t)return!1;var n=Math.max(1,t-4),i=Math.min(c,t+4);i-n<9&&(i=Math.min(c,n+8),n=Math.max(1,i-8));for(var s="<li>"+$(".js-pager li:first").html()+"</li>",o=n;o<=i;o++)s+='<li><a href="javascript:;" page="'+o+'" ng-click="loadMore(\''+e+"',"+o+')">'+o+"</a></li>";t!=c&&(s+='<li><a href="javascript:;" page="'+c+'" ng-click="loadMore(\''+e+"',"+c+')">尾页</a></li>'),$(".js-pager ul").html(l(s)(r)),$(".js-pager li").attr("class",""),$(".js-pager a[page='"+t+"']").parent().attr("class","active"),$(".js-pager .pager-nav").parent().attr("class","")},r.loadMore("",1)}]),angular.module("userGroup").controller("ViceGroupDisplay",["$scope","config","we7TypeDefault",function(t,e,a){t.lists=e.lists,t.links=e.links,t.we7TypeDefault=a,t.editGroup=function(e){e=parseInt(e);location.href=t.links.groupPost+"id="+e},t.delGroup=function(e){e=parseInt(e);util.confirm(function(){location.href=t.links.groupDel+"id="+e},function(){return!1},"确认è¦åˆ 除å—?")}}]),angular.module("userManageApp",["we7app"]),angular.module("userManageApp").directive("checkUsername",["$http",function(i){return{require:"ngModel",link:function(t,e,a,n){t.$watch(a.ngModel,function(e){return null!=e&&e?void i.post(t.config.check_user_info_url,{user:t.user}).success(function(e){-1==e.message.errno||-2==e.message.errno?(-1==e.message.errno&&n.$setValidity("format",!1),-2==e.message.errno&&(n.$setValidity("unique",!1),n.$setValidity("format",!0))):(n.$setValidity("unique",!0),n.$setValidity("format",!0))}):(n.$setValidity("required",!1),n.$setValidity("format",!0),!1)})}}}]),angular.module("userManageApp").controller("UserEditModules",["$scope","$http","$compile","config",function(i,t,e,s){i.user=s.user,i.uid=s.uid,i.profile=s.profile,i.group_info=s.group_info,i.groups=s.groups,i.links=s.links,i.extend=s.extend,i.changeGroup=i.user.groupid||"",i.jurindex="account",i.allmodule=!1,i.user_modules=s.user_modules,i.source_templates=s.source_templates,i.templates=s.source_templates,i.uni_groups=s.uni_groups,i.user_extra_groups=s.user_extra_groups,i.groupList={groups:s.uni_groups},i.moduleList={templates:s.source_templates,modules:i.user_modules.modules},s.uni_groups&&(i.user_modules.groups=s.uni_groups),s.source_templates&&(i.user_modules.templates=s.source_templates),i.recycleUser=function(){t.post(s.links.recycleUser,{uid:i.user.uid}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,e.redirect)})},i.editUserGroup=function(){t.post(i.links.editUserGroup+"uid="+i.user.uid,{groupid:i.changeGroup}).success(function(e){0==e.message.errno?(i.group_info=e.message.message,s.user.groupid=i.changeGroup,util.message("修改æˆåŠŸï¼","","success")):util.message(e.message.message)})},i.changeText=function(e){var t=$(e)[0].target.text;$(e)[0].target.text="展开"==t?"收起":"展开"},i.addExtend=function(){var a=[];angular.forEach(i.source_templates,function(e,t){1!=e.checked&&1!=e.checked||a.push(e.id)});var n=[];angular.forEach(i.user_modules,function(e,t){0<e.length&&("account"==t&&(t="modules"),angular.forEach(e,function(e,t){!e.name||1!=e.checked&&1!=e.checked||n.push(e.name)}))}),$("#jurisdiction-add").modal("hide"),t.post(s.links.editUsersPermission,{type:"extend",modules:n,templates:a,uid:i.user.uid}).success(function(e){0==e.message.errno?location.reload(!0):util.message("å‚数错误ï¼")})},i.selectUniGroup=function(){i.selected_uni_groups=[],angular.forEach(i.groupList.groups,function(e,t,a){1==e.checked&&i.selected_uni_groups.push(e.id)}),t.post(s.links.editUniGroupsUrl,{uni_groups:i.selected_uni_groups,uid:i.uid}).success(function(e){0==e.message.errno?location.reload(!0):util.message(e.message.message)})},i.selectExtraModules=function(){i.selected_extra_modules=[],angular.forEach(i.moduleList.modules,function(e,t,a){1==e.checked&&i.selected_extra_modules.push({name:e.name,support:e.support})}),i.selected_extra_templates=[],angular.forEach(i.moduleList.templates,function(e){1==e.checked&&i.selected_extra_templates.push({id:e.id})}),t.post(s.links.editExtraModulesUrl,{extra_modules:i.selected_extra_modules,extra_templates:i.selected_extra_templates,uid:i.uid}).success(function(e){0==e.message.errno?location.reload(!0):util.message(e.message.message)})},i.delUserGroup=function(e){util.confirm(function(){t.post(s.links.deleteUserGroupUrl,{uid:i.uid,groupid:e}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):uitl.message(e.message.message)})},"ç¡®è®¤åˆ é™¤å—?")}}]),angular.module("userManageApp").controller("UserEditModulesTpl",["$scope","$http","config",function(i,s,o){i.user=o.user,i.profile=o.profile,i.group_info=o.group_info,i.groups=o.groups,i.links=o.links,i.extend=o.extend,i.changeGroup=i.user.groupid,i.jurindex=0,i.allmodule=!1,i.httpChange=function(e){s.post(i.links.editGroup+"uid="+i.user.uid,{type:e,groupid:i.changeGroup,founder_groupid:i.user.founder_groupid}).success(function(e){0==e.message.errno?(i.group_info=e.message.message,util.message("修改æˆåŠŸï¼","","success")):util.message(e.message.message)})},i.changeText=function(e){var t=$(e)[0].target.text;$(e)[0].target.text="展开"==t?"收起":"展开"},i.tabChange=function(e){i.jurindex=e,function(){var e="#content-templates";0==i.jurindex&&(e="#content-modules");$("#jurisdiction-add "+e+" .item").size()!=$("#jurisdiction-add "+e+" .item.active").size()?i.allmodule=!1:i.allmodule=!0}()},i.allmodulechange=function(e){var t="#content-templates";0==i.jurindex&&(t="#content-modules"),e?$("#jurisdiction-add "+t+" .item").addClass("active"):$("#jurisdiction-add "+t+" .item").removeClass("active")},i.addExtend=function(){var e="",t="",a=[],n=[];$("#jurisdiction-add #content-modules").find(".active").each(function(){e+='<div class="col-sm-3 text-left we7-margin-bottom"><a href="javascript:;" class="label label-info">'+$(this).attr("data-title")+"</a></div>",a.push($(this).attr("data-name"))}),$("#jurisdiction-add #content-templates").find(".active").each(function(){t+='<div class="col-sm-3 text-left we7-margin-bottom"><a href="javascript:;" class="label label-info">'+$(this).attr("data-title")+"</a></div>",n.push($(this).attr("data-id"))}),e||t?$(".account-package-extra").show():$(".account-package-extra").hide(),$(".account-package-extra .js-extra-modules").append(e),$(".account-package-extra .js-extra-templates").append(t),$("#jurisdiction-add").modal("hide"),s.post(o.links.editUsersPermission,{type:"extend",module:a,tpl:n,uid:i.user.uid}).success(function(e){0==e.message.errno?location.reload():util.message("å‚数错误ï¼")})}}]),angular.module("userManageApp").controller("UserEditAccount",["$scope","$http","config","we7TypeDefault",function(n,i,s,e){n.user=s.user,n.uid=s.uid,n.account_list=s.account_list,n.profile=s.profile,n.groups=s.groups,n.group_info=s.group_info,n.extra_limit_info=s.extra_limit_info||{timelimit:0},n.total_timelimit=s.total_timelimit,n.we7TypeDefault=e,n.links=s.links,n.user_groups=s.user_groups,n.changeGroup=0,n.create_account_info=s.create_account_info,n.user.starttime=0<n.user.starttime?n.user.starttime:n.user.joindate,n.group_info&&0<n.group_info.timelimit?n.startDate=moment(1e3*n.user.starttime).add(Number(n.group_info.timelimit)+Number(n.extra_limit_info.timelimit),"days").format("YYYY-MM-DD"):n.startDate=(0<n.extra_limit_info.timelimit?moment(1e3*n.user.starttime).add(Number(n.extra_limit_info.timelimit),"days"):moment(1e3*n.user.starttime)).format("YYYY-MM-DD"),n.dateRange={startDate:n.startDate,endDate:n.startDate},n.datePickerConfig={minDate:(n.group_info&&0<n.group_info.timelimit?moment(1e3*n.user.starttime).add(Number(n.group_info.timelimit),"days"):moment(1e3*n.user.starttime)).format("YYYY-MM-DD"),startDate:n.startDate,endDate:n.startDate,timePicker:!1,singleDatePicker:!0},setTimeout(function(){$("select").niceSelect&&$("select").niceSelect("update")},1),n.extraCreateGroup=function(e){var a={},t="&operate=";if("group"==e?(a.group_ids=[],a.del_ids=[],t+="extend_group",angular.forEach(n.create_account_info.create_groups,function(e,t){(1==e.checked?a.group_ids:a.del_ids).push(e.id)})):"numbers"==e&&(a.numbers=n.create_account_info.create_numbers,t+="extend_numbers"),!a)return!1;i.post(s.links.extra_create_account_url+t,a).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,e.redirect)})},n.deleteCreateGroup=function(e){i.post(s.links.extra_create_account_url+"&operate=delete",{group_ids:[e]}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,e.redirect)})},n.httpChange=function(e){i.post(n.links.editGroup+"uid="+n.user.uid,{type:e,groupid:n.changeGroup,founder_groupid:n.user.founder_groupid}).success(function(e){0==e.message.errno?(n.group_info=e.message.message,util.message("修改æˆåŠŸï¼",s.links.editCreateAccountList,"success")):util.message(e.message.message)})},n.recycleUser=function(){i.post(s.links.recycleUser,{uid:n.user.uid}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,e.redirect)})},n.changeGroupId=function(e){n.groupid=e},n.changeGroup=function(){i.post(s.links.editUserGroup,{groupid:n.groupid}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,e.redirect)})},n.chageExtraTimelimit=function(){i.post(s.links.chageExtraTimelimit,{timelimit:n.extra_limit_info.timelimit}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})},n.changeTime=function(e){var t=moment(n.datePickerConfig.minDate).add(Number(n.extra_limit_info.timelimit),"d").format("YYYY-MM-DD");n.dateRange.startDate=t,n.dateRange.endDate=t,$("[we7-date-range-picker]").data("daterangepicker").setStartDate(t),$("[we7-date-range-picker]").data("daterangepicker").setEndDate(t)},n.$watch("dateRange",function(e,t){e&&e.startDate&&(n.dateRange.startDate=moment(e.startDate).format("YYYY-MM-DD"),n.dateRange.endDate=moment(e.endDate).format("YYYY-MM-DD"),n.extra_limit_info.timelimit=moment(e.startDate).diff(moment(n.datePickerConfig.minDate),"days"))},!0),n.delUserGroup=function(e){util.confirm(function(){i.post(s.links.deleteUserGroupUrl,{uid:n.uid,groupid:e}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):uitl.message(e.message.message)})},"ç¡®è®¤åˆ é™¤å—?")}}]),angular.module("userManageApp").controller("UsersDisplay",["$scope","$http","config",function(n,a,e){n.type=e.type,n.users=e.users,n.usergroups=e.usergroups,n.links=e.links,n.checkAllStatus=!1,n.checkNum=0,n.checkItem=function(e){e?n.checkNum++:n.checkNum--,n.checkNum==n.users.length?n.checkAllStatus=!0:n.checkAllStatus=!1},n.checkAll=function(){for(var e in n.users)n.users[e].checked=n.checkAllStatus;n.checkNum=n.checkAllStatus?n.users.length:0},n.postAction=function(e){var t,a=[];for(t in n.users)n.users[t].checked&&a.push(n.users[t].uid);"recycle_delete"==e||""==e?n.deleteUser(a,e):util.confirm(function(){n.operate(a,e)},function(){},"recycle_restore"==e?"确认è¦å¯ç”¨ç”¨æˆ·å—?":"确认è¦ç¦ç”¨ç”¨æˆ·å—?")},n.operate=function(e,t){t={type:t};"object"==typeof e?t.uids=e:t.uid=e,a.post(n.links.link,t).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,e.redirect)})},n.deleteUser=function(e,t){util.confirm(function(){n.operate(e,t)},function(){return fasle},"确认è¦åˆ 除å—?")}}]),angular.module("userManageApp").controller("FieldsDisplay",["$scope","$http","config",function(t,n,i){t.fields=i.fields,t.links=i.links,t.changeStatus=function(e,t,a){n.post(i.links.fieldDisplay,{id:e,key:t,val:a=0==a?1:0}).success(function(e){0==e.message.errno?util.message("修改æˆåŠŸ!",e.redirect,"success"):util.message("修改失败!",e.redirect,"info")})},t.editInfo=function(e){t.field=e},t.saveInfo=function(e){n.post(i.links.fieldPost,{field:e}).success(function(e){0==e.message.errno?util.message("修改æˆåŠŸ!",e.redirect,"success"):util.message("修改失败!",e.redirect,"info")})}}]),angular.module("userManageApp").controller("FieldsPost",["$scope","$http","config",function(e,t,a){null==e.item?(e.available=!0,e.required=!0,e.unchangeable=!0,e.showinregister=!0):(1==e.item.available?e.available=!0:e.available=!1,1==e.item.required?e.required=!0:e.required=!1,1==e.item.unchangeable?e.unchangeable=!0:e.unchangeable=!1,1==e.item.showinregister?e.showinregister=!0:e.showinregister=!1),e.verifyField=function(){var e=$('input[name="field"]');field_value=e.val(),reg=/^[A-Za-z0-9_]*$/,reg.test(field_value)||(util.message("请使用å—æ¯æˆ–æ•°å—或下划线组åˆå—段åï¼"),e.val(""))},e.saveInfo=function(e){t.post(a.links.fieldPost,{field:e}).success(function(e){0==e.message.errno?util.message("修改æˆåŠŸ!",e.redirect,"success"):util.message("修改失败!",e.redirect,"info")})}}]),angular.module("userManageApp").controller("RegistersetCtrl",["$scope","$http","config",function(e,a,n){e.settings=n.settings,e.copyright=n.copyright,e.groups=n.groups,e.group=n.group,e.welcomeLinks=n.welcomeLinks,e.welcome=n.welcome,e.binds=n.binds,e.bind=n.bind,e.saveSettingSwitch=function(e,t){a.post(n.saveSettingUrl,{submit:1,token:n.token,key:e,value:t=0==t||null==t?1:0}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,"","error")})},e.saveSetting=function(e,t){e=e.value.id||e.value;a.post(n.saveSettingUrl,{submit:1,token:n.token,key:t,value:e}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,"","error")})}}]),angular.module("userManageApp").controller("UserAssignPermissionsCtrl",["$scope","config",function(e,t){e.user=t.user,e.profile=t.profile}]),angular.module("userManageApp").controller("UsersFindMobilePwd",["$scope","$http","config","$interval",function(a,t,e,n){a.links=e.links,a.code="",a.password="",a.repassword="",a.mobile="",a.find_password_sign=e.find_password_sign,a.image=e.image,a.expire=120,a.text="å…费获å–验è¯ç ",a.isDisable=!1,a.sendMessage=function(){return a.isDisable=!0,""==a.mobile?(util.message("手机å·ä¸èƒ½ä¸ºç©º"),!1):""==a.imagecode||null==a.imagecode?(a.imagecodeErr=!0,a.imagecodeMsg="请输入验è¯ç ",a.isDisable=!1):void t.post(e.links.check_code_link,{code:a.imagecode}).success(function(e){return 0!=e.message.errno?(a.imagecodeErr=!0,a.imagecodeMsg="请输入æ£ç¡®çš„验è¯ç ",a.isDisable=!1,a.changeVerify(),!1):(a.imagecodeErr=!1,a.imageInvalid=!1,void t.post(a.links.valid_mobile_link,{receiver:a.mobile}).success(function(e){0!=e.message.errno?(a.isDisable=!1,a.changeVerify(),util.message(e.message.message)):t.post(a.links.send_code_link,{receiver:a.mobile,custom_sign:a.find_password_sign}).success(function(e){var t;0==e.message.errno?(util.message("å‘é€éªŒè¯ç æˆåŠŸ","","success"),t=n(function(){a.isDisable=!0,a.expire--,a.text=a.expire+"秒åŽé‡æ–°èŽ·å–",a.expire<=0&&(n.cancel(t),a.isDisable=!1,a.text="é‡æ–°ç‚¹å‡»èŽ·å–验è¯ç ",a.expire=120)},1e3)):(a.isDisable=!1,util.message(e.message.message,"","error"))})}))})},a.nextStep=function(){return""==a.mobile?(util.message("手机å·ä¸èƒ½ä¸ºç©º"),!1):""==a.imagecode?(util.message("验è¯ç ä¸èƒ½ä¸ºç©º"),!1):""==a.code?(util.message("çŸä¿¡éªŒè¯ç ä¸èƒ½ä¸ºç©º"),!1):($(".step-2").removeClass("hide"),$(".step-2").show(),$(".step-1").hide(),void $(".step-set-pwd").addClass("steps-status-finish"))},a.prevStep=function(){a.isDisable=!1,$(".step-2").hide(),$(".step-1").removeClass("hide"),$(".step-1").show(),$(".step-set-pwd").removeClass("steps-status-finish")},a.changePassword=function(){return""==a.password?($(".password").html("密ç ä¸èƒ½ä¸ºç©º"),!1):""==a.repassword?($(".repassword").html("密ç ä¸èƒ½ä¸ºç©º"),!1):a.password!=a.repassword?($(".repassword").html("两次输入的密ç ä¸ä¸€è‡´"),!1):void t.post(a.links.set_password_link,{password:a.password,repassword:a.repassword,receiver:a.mobile,code:a.code}).success(function(e){if(0==e.message.errno)$(".step-3").removeClass("hide"),$(".step-2").hide(),$(".step-pwd-success").addClass("steps-status-finish");else{if(-2==e.message.errno)return $(".password").html(e.message.message),!1;util.message(e.message.message)}})},a.changeVerify=function(){return a.image=a.links.img_verify_link+"r="+Math.round((new Date).getTime()),!1}}]),angular.module("userManageApp").controller("UserExpireCtrl",["$scope","$http","config",function(a,n,e){a.user_expire=e.user_expire,a.links=e.links,a.saveExpire=function(e){var t;"day"==e&&(t={day:a.user_expire.day}),"notice"==e&&(t={notice:a.user_expire.notice}),n.post(a.links.user_expire_link+"&type="+e,t).success(function(e){0!=e.message.errno?util.message(e.message.message,e.redirect,"error"):util.message("设置æˆåŠŸ",e.redirect,"success")})},a.changeStatus=function(e){n.post(a.links.user_expire_status_link+"&type="+e,{}).success(function(e){0==e.message.errno?util.message("修改æˆåŠŸ",e.redirect,"success"):util.message("修改失败,请ç¨åŽé‡è¯•ï¼")})}}]),angular.module("userManageApp").controller("UsersRegisterMobile",["$scope","$http","config","$interval",function(a,n,e,i){a.showImageCode=!1,a.links=e.links,a.smscode="",a.password="",a.repassword="",a.image=e.image,a.verify="",a.mobile="",a.owner_uid=e.owner_uid,a.register_type=e.register_type,a.register_sign=e.register_sign,a.expire=120,a.text="å‘é€éªŒè¯ç ",a.isDisable=!1,a.mobleInvalid=!0,a.smscodeInvalid=!0,a.imageInvalid=!0,a.passwordInvalid=!0,a.repasswordInvalid=!0,a.sendMessage=function(){n.post(a.links.valid_mobile_link,{mobile:a.mobile}).success(function(e){0!=e.message.errno?util.message(e.message.message):n.post(a.links.send_code_link,{receiver:a.mobile,custom_sign:a.register_sign,imagecode:a.imagecode}).success(function(e){if(0==e.message.errno){util.message("å‘é€éªŒè¯ç æˆåŠŸ","","success");var t=i(function(){a.isDisable=!0,a.expire--,a.text=a.expire+"秒åŽé‡æ–°èŽ·å–",a.expire<=0&&(i.cancel(t),a.isDisable=!1,a.text="é‡æ–°ç‚¹å‡»èŽ·å–验è¯ç ",a.expire=120)},1e3)}else{if(-3==e.message.errno)return a.imagecodeErr=!0,$("#imageCode").modal(),!1;a.changeVerify(),util.message(e.message.message,"","error")}})})},a.changeVerify=function(){return a.image=a.links.img_verify_link+"r="+Math.round((new Date).getTime()),!1},a.checkMobile=function(){var e=a.mobile;n.post(a.links.valid_mobile_link,{mobile:e}).success(function(e){0!=e.message.errno?(a.mobileErr=!0,a.mobileMsg=e.message.message):(a.mobileErr=!1,a.mobleInvalid=!1)})},a.checkImagecode=function(){""==a.imagecode||null==a.imagecode?(a.imagecodeErr=!0,a.imagecodeMsg="请输入验è¯ç "):n.post(e.links.check_code_link,{code:a.imagecode}).success(function(e){0!=e.message.errno?(a.imagecodeErr=!0,a.imagecodeMsg="请输入æ£ç¡®çš„验è¯ç ",a.changeVerify()):(a.imagecodeErr=!1,a.imageInvalid=!1)})},a.checkPassword=function(){var t;""==a.password||null==a.password?(a.passwordErr=!0,a.passwordMsg="请输入密ç "):a.password.length<8?(a.passwordErr=!0,a.passwordMsg="密ç 长度ä¸èƒ½å°‘于8"):1==e.password_safe?(t=/(?=.*[a-z])(?=.*[A-Z])(?=.*\d).{8,30}/,n.post(e.links.check_password_link,{password:a.password}).success(function(e){0==t.test(a.password)?(a.passwordErr=!0,a.passwordMsg="至少8-16个å—符,必须包å«å¤§å†™å—æ¯ï¼Œå°å†™å—æ¯ï¼Œæ•°å—。"):(a.passwordErr=!1,a.passwordInvalid=!1)})):(a.passwordErr=!1,a.passwordInvalid=!1)},a.checkRepassword=function(){""==a.repassword||null==a.repassword?(a.repasswordErr=!0,a.repasswordMsg="确认密ç ä¸èƒ½ä¸ºç©º"):a.repassword!=a.password?(a.repasswordErr=!0,a.repasswordMsg="两次密ç 输入ä¸ä¸€è‡´"):(a.repasswordErr=!1,a.repasswordInvalid=!1)},a.register=function(){n.post(a.links.register_link,{password:a.password,mobile:a.mobile,register_type:a.register_type,code:a.imagecode,smscode:a.smscode,owner_uid:e.owner_uid}).success(function(e){a.imagecode="",0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})}}]),angular.module("userManageApp").controller("UserRegisterSystem",["$scope","$http","config",function(s,e,t){function a(e,t,a,n,i){return""==e||null==e?(s.extendfields[t].fieldErr=!0,s.extendfields[t].fieldMsg=a):i.test(e)?s.extendfields[t].fieldErr=!1:(s.extendfields[t].fieldErr=!0,s.extendfields[t].fieldMsg=n),s.extendfields[t].fieldErr}s.image=t.image,s.usernameInvalid=!0,s.passwordInvalid=!0,s.repasswordInvalid=!0,s.codeInvalid=!0,s.checkUsername=function(){""==s.username||null==s.username?(s.usernameErr=!0,s.usernameMsg="请输入用户å"):e.post(t.links.check_username_link,{username:s.username,owner_uid:s.owner_uid,password:s.password}).success(function(e){0!=e.message.errno?(s.usernameErr=!0,s.usernameMsg="éžå¸¸æŠ±æ‰ï¼Œæ¤ç”¨æˆ·åå·²ç»è¢«æ³¨å†Œï¼Œä½ 需è¦æ›´æ¢æ³¨å†Œå称ï¼"):(s.usernameErr=!1,s.usernameInvalid=!1)})},s.checkPassword=function(){""==s.password||null==s.password?(s.passwordErr=!0,s.passwordMsg="请输入密ç "):s.password.length<8?(s.passwordErr=!0,s.passwordMsg="密ç 长度ä¸èƒ½å°‘于8"):1==t.password_safe?/(?=.*[a-z])(?=.*[A-Z])(?=.*\d).{8,30}/.test(s.password)?(s.passwordErr=!1,s.passwordInvalid=!1):(s.passwordErr=!0,s.passwordMsg="至少8-16个å—符,必须包å«å¤§å†™å—æ¯ï¼Œå°å†™å—æ¯ï¼Œæ•°å—。"):(s.passwordErr=!1,s.passwordInvalid=!1)},s.checkRepassword=function(){s.repassword!=s.password?(s.repasswordErr=!0,s.repasswordMsg="两次密ç 输入ä¸ä¸€è‡´"):(s.repasswordErr=!1,s.repasswordInvalid=!1)},s.changeVerify=function(){return s.image=t.links.img_verify_link+"r="+Math.round((new Date).getTime()),!1},s.checkCode=function(){""==s.code||null==s.code?(s.codeErr=!0,s.codeMsg="请输入验è¯ç "):e.post(t.links.check_code_link,{code:s.code}).success(function(e){0!=e.message.errno?(s.codeErr=!0,s.codeMsg="请输入æ£ç¡®çš„验è¯ç ",s.changeVerify()):(s.codeErr=!1,s.codeInvalid=!1)})},s.checkExtendfield=function(e){var t=document.getElementsByName(e)[0].value;switch(e){case"realname":checkRes=a(t,e,"请输入用户å","请输入您的真实姓å",/^.{2,5}$/);break;case"nickname":checkRes=a(t,e,"请输入昵称","æ˜µç§°æ ¼å¼ä¸º 3-30 ä½å—符",/^.{3,30}$/);break;case"qq":""==t||null==t?(s.extendfields[e].fieldErr=!0,s.extendfields[e].fieldMsg="请输入QQ"):checkRes=a(t,e,"请输入QQå·ç ","请输入æ£ç¡®çš„QQå·ç ",/^[1-9][0-9]{4,9}$/)}}}]),angular.module("userManageApp").controller("UserCreateCtrl",["$scope","$http","$compile","$filter","config","UserManageCommon","we7TypeDefault",function(l,a,e,t,n,i,s){l.user={username:"",password:"",repassword:"",remark:""},l.submitDisabled=!1,l.is_used=n.is_used,l.user_type=n.user_type,l.config=n,l.groups=n.groups,l.jurindex="modules_group",l.allmodule=!1,l.user_modules=n.user_modules,l.modules_group_list=n.modules_group_list,l.modules=[],l.account=n.create_account,l.selectedAccount=[],l.selectedDate=0,l.expiration=0,l.selectedGroupInfo=null,l.account_text=s,l.module_keyword="",l.showModules=!1,l.showAccount=!1,l.group={},l.moduleGroupList={groups:n.modules_group_list},l.permissionType="1",l.loadChange=function(){$(".we7-group-show").each(function(){$(this).removeClass("low"),$(this).removeClass("closed"),70<$(this).find(".group-app-list").outerHeight()?($(this).addClass("closed"),$(this).find(".action").off("click").on("click",function(){$(this).parent().toggleClass("closed")})):$(this).addClass("low")})},l.create_step=1,l.step=function(t){2==t&&"vice_founder"!=l.user_type?a.post(n.check_user_info_url,{user:l.user}).success(function(e){return 0!=e.message.errno?(util.message(e.message.message),!1):void(l.create_step=t)}):l.create_step=t},l.groupConfirm=function(){setTimeout(function(){l.loadChange()},20)},l.changeGroup=function(){l.selectedGroupInfo={},l.group&&l.group.id&&a.get(n.get_user_group_detail_url+"&user_group_id="+l.group.id).success(function(e){if(e.message&&!e.message.errno){var t=e.message.message,a=t.package_detail;if("all"!==t.modules||"all"!==t.templates)for(var n in t.group_module_all={},t.group_tempate_all={},a){var i,s,o=a[n].modules_all,r=a[n].templates;for(i in o)t.group_module_all[n]||(t.group_module_all[o[i].mid]=o[i]);for(s in r)t.group_tempate_all[r[s].id]||(t.group_tempate_all[r[s].id]=r[s])}l.selectedGroupInfo=t}})},l.submit=function(){l.submitDisabled=!0;var t={username:l.user.username,password:l.user.password,repassword:l.user.repassword,remark:l.user.remark,addtype:l.permissionType,is_used:l.is_used};1==l.permissionType&&(""!=l.vice_founder_name&&null!=l.vice_founder_name&&a.post(n.check_vice_founder_exists_url,{vice_founder_name:l.vice_founder_name}).success(function(e){if(0!=e.message.errno)return util.message(e.message.message),!1}),l.uni_groups=[],angular.forEach(l.moduleGroupList.groups,function(e,t,a){1==e.checked&&l.uni_groups.push(e.id)}),l.modules=[],angular.forEach(l.user_modules.modules,function(e,t,a){1==e.checked&&l.modules.push(e)}),l.templates=[],angular.forEach(l.user_modules.templates,function(e,t,a){1==e.checked&&l.templates.push(e.id)}),l.create_account_groups=[],angular.forEach(l.account.create_groups,function(e,t,a){1==e.checked&&l.create_account_groups.push(e.id)}),t.uni_groups=l.uni_groups,t.modules=l.modules,t.templates=l.templates,t.create_account_groups=l.create_account_groups,t.create_account_nums=l.account.create_numbers,t.timelimit=l.selectedDate,t.vice_founder_name=l.vice_founder_name),2==l.permissionType&&(t.groupid=l.group.id),"vice_founder"!=l.user_type?a.post(n.check_vice_founder_permission_limit_url,t).success(function(e){return 0!=e.message.errno?(util.message(e.message.message),!1):void a.post(n.user_save_url,t).success(function(e){util.message(e.message.message,e.redirect,"ajax")})}):a.post(n.user_save_url,t).success(function(e){0==e.message.errno?util.message("æ·»åŠ æˆåŠŸ!",e.redirect,"ajax"):util.message(e.message.message)})},l.addPermission=i.addPermission}]),angular.module("userManageApp").service("UserManageCommon",["$rootScope","$http","config",function(e,t,a){var n={addPermission:function(){var e="",t="";$("#jurisdiction-add #content-modules").find(".btn-primary").each(function(){e+='<span class="label label-info" style="margin-right:3px;">'+$(this).attr("data-title")+'</span><input type="hidden" name="extra[modules][]" value="'+$(this).attr("data-name")+'" />'}),$("#jurisdiction-add #content-templates").find(".btn-primary").each(function(){t+='<span class="label label-info" style="margin-right:3px;">'+$(this).attr("data-title")+'</span><input type="hidden" name="extra[templates][]" value="'+$(this).attr("data-name")+'" />'}),e||t?$(".account-package-extra").show():$(".account-package-extra").hide(),$(".account-package-extra .js-extra-modules").html(e),$(".account-package-extra .js-extra-templates").html(t),$("#jurisdiction-add").modal("hide")}};return n}]),angular.module("userProfile",["we7app"]),angular.module("userProfile").controller("UserProfileDisplay",["$scope","$window","$http","config",function(p,m,g,t){p.user_extra_groups=t.user_extra_groups,p.extend=t.extend,p.account_num=t.account_num,p.user=t.user,p.profile=t.profile||{},p.extra_fields=t.extra_fields,null==p.profile&&(p.profile={avatar:"",realname:"",births:"",address:"",resides:""}),p.links=t.links,p.group_info=t.group_info,p.groups=t.groups,p.changeGroup=p.user.groupid,p.wechats=t.wechats,p.wxapps=t.wxapps,p.redirect_urls=t.redirect_urls,p.user_welcome_link={},angular.forEach(t.redirect_urls,function(e){e.id==t.user.welcome_link&&(p.user_welcome_link=e)}),p.saveSetting=function(e,t){p.user.welcome_link=e.value.id,p.user_welcome_link=e.value,p.httpChange(t)},p.recycleUser=function(){g.post(t.links.recycleUser,{uid:p.user.uid}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,e.redirect)})},p.changeAvatar=function(){require(["fileUploader"],function(e){e.init(function(e){p.profile.avatar=e.url,p.$apply(p.profile),p.httpChange("avatar")},{direct:!0,multiple:!1,uniacid:0})})},p.editInfo=function(e,t){p.userOriginal={},p.userOriginal[e]=t},p.httpChange=function(t){switch(t){case"avatar":g.post(p.links.userPost,{type:t,avatar:p.profile.avatar,uid:p.user.uid}).success(function(e){0==e.message.errno?util.toast("修改æˆåŠŸï¼","success"):util.message(e.message.message)});break;case"username":$(".modal").modal("hide"),g.post(p.links.userPost,{type:t,username:p.userOriginal[t],uid:p.user.uid}).success(function(e){0==e.message.errno?(p.user[t]=p.userOriginal[t],util.toast("修改æˆåŠŸï¼","success")):util.message(e.message.message)});break;case"vice_founder_name":$(".modal").modal("hide"),g.post(p.links.userPost,{type:t,vice_founder_name:p.userOriginal[t],uid:p.user.uid}).success(function(e){return 0!=e.message.errno?(util.message(e.message.message),!1):(p.user[t]=p.userOriginal[t],void util.toast("修改æˆåŠŸï¼","success"))});break;case"qq":$(".modal").modal("hide"),g.post(p.links.userPost,{type:t,qq:p.userOriginal[t],uid:p.user.uid}).success(function(e){return 0!=e.message.errno?(util.message(e.message.message),!1):(p.profile[t]=p.userOriginal[t],void util.toast("修改æˆåŠŸï¼","success"))});break;case"remark":$(".modal").modal("hide"),g.post(p.links.userPost,{type:t,remark:p.userOriginal[t],uid:p.user.uid}).success(function(e){return 0!=e.message.errno?(util.message(e.message.message),!1):(p.user[t]=p.userOriginal[t],void util.toast("修改æˆåŠŸï¼","success"))});break;case"welcome_link":$(".modal").modal("hide"),g.post(p.links.userPost,{type:t,welcome_link:p.user.welcome_link,uid:p.user.uid}).success(function(e){return 0!=e.message.errno?(util.message(e.message.message),!1):void util.toast("修改æˆåŠŸï¼","success")});break;case"mobile":$(".modal").modal("hide"),g.post(p.links.userPost,{type:t,mobile:p.userOriginal[t],uid:p.user.uid}).success(function(e){return 0!=e.message.errno?(util.message(e.message.message),!1):(p.profile[t]=p.userOriginal[t],void util.toast("修改æˆåŠŸï¼","success"))});break;case"password":if($(".modal").modal("hide"),0==m.sysinfo.isfounder&&0==p.user.register_type){var e=$(".old-password").val();if(_.isEmpty(e))return util.message("原密ç ä¸å¯ä¸ºç©ºï¼"),!1}var a=$(".new-password").val(),n=$(".renew-password").val();if(_.isEmpty(a))return util.message("新密ç ä¸å¯ä¸ºç©ºï¼"),!1;if(_.isEmpty(n))return util.message("确认新密ç ä¸å¯ä¸ºç©ºï¼"),!1;if(a!=n)return util.message("两次密ç ä¸ä¸€è‡´ï¼"),!1;g.post(p.links.userPost,{type:t,oldpwd:e,newpwd:a,renewpwd:n,uid:p.user.uid}).success(function(e){0==e.message.errno?util.message("修改æˆåŠŸ,请é‡æ–°ç™»å½•ï¼",e.redirect,"success"):util.message(e.message.message)});break;case"endtime":$(".modal").modal("hide");var i=p.user.endtype,s=$(':text[name="endtime"]').val();g.post(p.links.userPost,{type:t,endtype:i,endtime:s,uid:p.user.uid}).success(function(e){0==e.message.errno?(p.user.endtype=i,p.user.end=1==i?"永久":s,util.toast("修改æˆåŠŸï¼","success")):util.message(e.message.message)});break;case"realname":if($(".modal").modal("hide"),_.isEmpty(p.userOriginal.realname))return util.message("真实姓åä¸å¯ä¸ºç©ºï¼"),!1;g.post(p.links.userPost,{type:t,realname:p.userOriginal.realname,uid:p.user.uid}).success(function(e){0==e.message.errno?(p.profile.realname=p.userOriginal.realname,util.toast("修改æˆåŠŸï¼","success")):util.message(e.message.message)});break;case"birth":$(".modal").modal("hide");var o=$(".tpl-year").val(),r=$(".tpl-month").val(),l=$(".tpl-day").val();g.post(p.links.userPost,{type:t,year:o,month:r,day:l,uid:p.user.uid}).success(function(e){0==e.message.errno?(p.profile.births=o+"å¹´"+r+"月"+l+"æ—¥",util.toast("修改æˆåŠŸï¼","success")):util.message(e.message.message)});break;case"address":if($(".modal").modal("hide"),_.isEmpty(p.userOriginal.address))return util.message("邮寄地å€ä¸å¯ä¸ºç©ºï¼"),!1;g.post(p.links.userPost,{type:t,address:p.userOriginal.address,uid:p.user.uid}).success(function(e){0==e.message.errno?(p.profile.address=p.userOriginal.address,util.toast("修改æˆåŠŸï¼","success")):util.message(e.message.message)});break;case"reside":$(".modal").modal("hide");var c=$(".tpl-province").val(),u=$(".tpl-city").val(),d=$(".tpl-district").val();g.post(p.links.userPost,{type:t,province:c,city:u,district:d,uid:p.user.uid}).success(function(e){0==e.message.errno?(p.profile.resides=c+" "+u+" "+d,util.toast("修改æˆåŠŸï¼","success")):util.message(e.message.message)});break;default:$(".modal").modal("hide"),g.post(p.links.userPost,{type:p.edit_extra_filed.field,extra_field_key:p.edit_extra_filed.field,extra_field_val:p.edit_extra_filed[p.edit_extra_filed.field],uid:p.user.uid}).success(function(e){0==e.message.errno?util.message("修改æˆåŠŸï¼",location.reload(),"success"):util.message(e.message.message)})}},p.changeText=function(e){var t=$(e)[0].target.text;$(e)[0].target.text="展开"==t?"收起":"展开"},p.editExtra=function(e,t){p.edit_extra_filed=e,p.edit_extra_filed[e.field]=t[e.field]}}]),angular.module("userProfile").controller("userBindCtrl",["$scope","$http","config","$interval",function(a,n,e,i){a.bindqq=e.bindqq,a.bindwechat=e.bindwechat,a.bindmobile=e.bindmobile,a.bindconsole=e.bindconsole,a.login_urls=e.login_urls,a.thirdlogin=e.thirdlogin,a.bind_sign=e.bind_sign,a.image=e.image,a.mobile=null==e.bindmobile?"":e.bindmobile.bind_sign,a.password="",a.repassword="",a.links=e.links,a.imagecode="",a.smscode="",a.expire=120,a.text="å‘é€éªŒè¯ç ",a.isDisable=!1,a.showCaptcha=function(e){if(""==a.mobile)return util.message("手机å·ä¸èƒ½ä¸ºç©º"),!1;n.post(a.links.valid_mobile_link,{mobile:a.mobile,type:e}).success(function(e){0!=e.message.errno?util.message(e.message.message):$("#checkcaptcha").modal("show")})},a.checkCaptcha=function(e,t){if(""==e)return util.message("验è¯ç ä¸èƒ½ä¸ºç©º"),!1;n.post(a.links.checkcaptcha_link,{imagecode:e}).success(function(e){0==e.message.errno?($("#checkcaptcha").modal("hide"),a.sendMessage(t)):util.message(e.message.message)})},a.sendMessage=function(e){n.post(a.links.send_code_link,{receiver:a.mobile,custom_sign:a.bind_sign,need_checkcaptcha:""}).success(function(e){var t;"success"==e||0==e.message.errno?(util.message("å‘é€éªŒè¯ç æˆåŠŸ","","success"),t=i(function(){a.isDisable=!0,a.expire--,a.text=a.expire+"秒åŽé‡æ–°èŽ·å–",a.expire<=0&&(i.cancel(t),a.isDisable=!1,a.text="é‡æ–°ç‚¹å‡»èŽ·å–验è¯ç ",a.expire=120)},1e3)):util.message(e.message.message,"","error")})},a.changeVerify=function(){return a.image=a.links.img_verify_link+"r="+Math.round((new Date).getTime()),!1},a.mobileBind=function(e,t){return""==a.mobile?(util.message("手机å·ä¸èƒ½ä¸ºç©º"),!1):""==a.imagecode?(util.message("图形验è¯ç ä¸èƒ½ä¸ºç©º"),!1):""==a.smscode?(util.message("手机å·éªŒè¯ç ä¸èƒ½ä¸ºç©º"),!1):void(null==a.bindmobile?n.post(a.links.bind_mobile_link,{mobile:a.mobile,password:a.password,repassword:a.repassword,imagecode:a.imagecode,smscode:a.smscode,type:e,need_checkcaptcha:0}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)}):n.post(a.links.unbind_third_link,{mobile:a.mobile,password:a.password,repassword:a.repassword,imagecode:a.imagecode,smscode:a.smscode,type:e,bind_type:t,need_checkcaptcha:0}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)}))},a.unbind=function(e){n.post(a.links.unbind_third_link,{bind_type:e}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})}}]),angular.module("userProfile").controller("changeMobileCtrl",["$scope","$http","config","$interval",function(n,i,e,s){n.bindmobile=e.bindmobile,n.bind_sign=e.bind_sign,n.image=e.image,n.mobile=null==e.bindmobile?"":e.bindmobile.bind_sign,n.newMobile="",n.links=e.links,n.imagecode="",n.smscode="",n.newSmscode="",n.expire=120,n.text="å‘é€éªŒè¯ç ",n.isDisable=!1,n.step=e.step,n.checkAuthcode="",n.showCaptcha=function(e){return 1==e?(n.changeVerify(),void $("#checkcaptcha").modal("show")):""==n.newMobile?(util.message("手机å·ä¸èƒ½ä¸ºç©º"),!1):void i.post(n.links.valid_mobile_link,{mobile:n.newMobile}).success(function(e){0!=e.message.errno?util.message(e.message.message):(n.changeVerify(),$("#checkcaptcha").modal("show"))})},n.checkCaptcha=function(e,t,a){if(""==e)return util.message("验è¯ç ä¸èƒ½ä¸ºç©º"),!1;i.post(n.links.checkcaptcha_link,{imagecode:e}).success(function(e){0==e.message.errno?($("#checkcaptcha").modal("hide"),n.sendMessage(t,a)):util.message(e.message.message)})},n.sendMessage=function(e,t){var a=n.mobile;2==t&&(a=n.newMobile),i.post(n.links.send_code_link,{receiver:a,custom_sign:n.bind_sign,need_checkcaptcha:""}).success(function(e){var t;"success"==e||0==e.message.errno?(util.message("å‘é€éªŒè¯ç æˆåŠŸ","","success"),n.isDisable=!0,t=s(function(){1==n.isDisable&&(n.expire--,n.text=n.expire+"秒åŽé‡æ–°èŽ·å–",n.expire<=0&&(s.cancel(t),n.isDisable=!1,n.text="é‡æ–°ç‚¹å‡»èŽ·å–验è¯ç ",n.expire=120))},1e3)):util.message(e.message.message,"","error")})},n.nextStep=function(){return console.log(n.smscode),""==n.mobile?(util.message("手机å·ä¸èƒ½ä¸ºç©º"),!1):""==n.smscode?(util.message("手机å·éªŒè¯ç ä¸èƒ½ä¸ºç©º"),!1):void i.post(n.links.check_mobile_sms_code_link,{mobile:n.mobile,smscode:n.smscode,need_checkcaptcha:0}).success(function(e){0==e.message.errno?(n.step=2,n.isDisable=!1,n.text="å‘é€éªŒè¯ç ",n.expire=120,n.checkAuthcode=e.message.message.check_authcode):util.message(e.message.message)})},n.changeVerify=function(){return n.image=n.links.img_verify_link+"r="+Math.round((new Date).getTime()),!1},n.mobileBind=function(){return""==n.newMobile?(util.message("手机å·ä¸èƒ½ä¸ºç©º"),!1):""==n.newSmscode?(util.message("手机å·éªŒè¯ç ä¸èƒ½ä¸ºç©º"),!1):void i.post(n.links.bind_mobile_link,{mobile:n.newMobile,smscode:n.newSmscode,need_checkcaptcha:0,check_authcode:n.checkAuthcode}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})}}]),angular.module("userProfile").controller("UserEditOperatoers",["$scope","$http","config",function(e,n,i){e.user=i.user,e.profile=i.profile||{},e.list=i.list,e.deleteClerk=function(e,t,a){util.confirm(function(){n.post(i.links.deleteClerk,{uid:e,module_name:t,uniacid:a}).success(function(e){"0"==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})},function(){return!1},"ç¡®è®¤åˆ é™¤?")}}]),angular.module("webApp",["we7app"]),angular.module("webApp").controller("bindDomainCtrl",["$scope","$http","config",function(n,e,t){n.account=t.account,n.moduleList=t.modulelist,n.middleAccount={bind_domain:""},n.httpChange=function(){e.post(t.links.postDomain,{bind_domain:n.middleAccount.bind_domain,submit:!0,token:t.token}).success(function(e){0==e.message.errno?util.message("修改æˆåŠŸï¼",e.redirect,"success"):util.message(e.message.message)})},n.changeModule=function(){e.post(t.links.postModule,{module_name:n.selectedModule,token:t.token}).success(function(e){0==e.message.errno?util.message("修改æˆåŠŸï¼",e.redirect,"success"):util.message(e.message.message)}),$("#add_module").modal("hide")},n.cancelModule=function(){$("#add_module").modal("hide")},n.selectModule=function(a){angular.forEach(n.moduleList,function(e,t){n.moduleList[t].selected=a==t}),n.selectedModule=a}}]),angular.module("we7wish",["we7app"]).constant("params",function(e){var l=function(e){var t,a,n,i,s,o,r="";for(t in e)if((a=e[t])instanceof Array)for(o=0;o<a.length;++o)i=a[o],(s={})[t+"["+o+"]"]=i,r+=l(s)+"&";else if(a instanceof Object)for(n in a)i=a[n],(s={})[t+"["+n+"]"]=i,r+=l(s)+"&";else null!=a&&(r+=encodeURIComponent(t)+"="+encodeURIComponent(a)+"&");return r.length?r.substr(0,r.length-1):r};return l(e)}),angular.module("we7wish").controller("wishList",["$scope","$http","config","params",function(t,a,n,i){t.page={currentPage:1,totalItems:1,itemsPerPage:10,pagesLength:9,onChange:function(){t.getList()}},t.goods_type="",t.we7TypeDefault={wxapp_support:"微信å°ç¨‹åº",app_support:"微信公众å·",android_support:"APP-android",ios_support:"APP-ios",aliapp_support:"支付å®å°ç¨‹åº",webapp_support:"PC",system_welcome_support:"微擎首页",theme_support:"微擎微站",baiduapp_support:"百度å°ç¨‹åº"},t.unitInfo={year:"å¹´",month:"月",day:"æ—¥"},t.op=n.op,t.status=n.status,t.editUrl="wishgoods"==n.op?n.editGoodsUrl:n.editCloudGoodsUrl,t.list=[],t.goods_type="",t.goods_name="",t.getList=function(e){e=e||t.page.currentPage,a.get(n.apiUrl+"&"+i({op:n.op||"wishgoods",status:n.status||1,page:e||1,goods_name:t.goods_name||"",goods_type:t.goods_type||""})).success(function(e){e.message.errno||(t.list=e.message.message.data,t.page.totalItems=e.message.message.total)})},t.getList(),t.changeStatus=function(e){a.get(n.changeStatusUrl+"&"+i({id:e})).success(function(e){"success"==e.type?util.message("æ“作æˆåŠŸ","refresh","success"):util.message("æ“作失败, 请é‡è¯•","","error")})},t.deleteGoods=function(e){util.confirm(function(){a.get(n.deleteGoodsUrl+"&"+i({id:e})).success(function(e){"success"==e.type?util.message("æ“作æˆåŠŸ","refresh","success"):util.message("æ“作失败, 请é‡è¯•","","error")})},function(){return!1},"åˆ é™¤ä¸å¯æ¢å¤, 是å¦ç¡®è®¤åˆ 除?")},t.deleteCloudGoods=function(e){util.confirm(function(){a.get(n.deleteCloudGoods+"&"+i({id:e})).success(function(e){e.message.errno?util.message("æ“作失败, 请é‡è¯•","","error"):util.message("æ“作æˆåŠŸ","refresh","success")})},function(){return!1},"ç¡®è®¤åˆ é™¤?")}}]),angular.module("we7wish").controller("wishEdit",["$scope","$http","config",function(n,i,s){if(n.cloudGoods=s.cloudGoods,n.content="",n.branch=0,n.support=[],n.we7TypeDefault={wxapp_support:"微信å°ç¨‹åº",account_support:"微信公众å·",phoneapp_support:"APP",aliapp_support:"支付å®å°ç¨‹åº",webapp_support:"PC",system_welcome_support:"微擎首页",theme_support:"微擎微站",baiduapp_support:"百度å°ç¨‹åº"},n.slideLists=[],n.prices={},n.content="",n.fileLogo=function(e,t,a){n.cloudGoods.logo=e.url},n.changeBranch=function(e){for(var t in n.branch=e,n.prices={},n.cloudGoods.branchs[e].supports){t=n.cloudGoods.branchs[e].supports[t];"android_support"===t||"ios_support"===t?t="phoneapp_support":"app_support"===t&&(t="account_support"),n.prices[t]={checked:-1!==n.cloudGoods.goods_support.indexOf(t),disabled:-1!==n.cloudGoods.goods_support.indexOf(t),price:"",unit:"month"}}setTimeout(function(){n.$apply("prices")})},n.changeSupport=function(e){e.checked=!e.checked},n.delSlide=function(e){n.slideLists.splice(e,1)},n.fileChange=function(e,t,a){n.slideLists.push(e.url)},n.submit=function(e){var t,a=!0;for(t in n.prices)n.prices[t].checked&&(a=!1,n.prices[t].price||(a=!0));if(a)return util.message("è¯·é€‰æ‹©ç±»åž‹å¹¶å¡«å†™ä»·æ ¼","","error"),!1;i.post(s.saveWishGoodsUrl,{title:n.cloudGoods.title,logo:n.cloudGoods.logo,name:n.cloudGoods.name,status:e,prices:n.prices,slide:n.slideLists,description:n.content,goods_cloud_id:n.cloudGoods.id,branch_id:n.cloudGoods.branchs[n.branch].id}).success(function(e){e.message.errno||util.message("æ·»åŠ æˆåŠŸ",e.redirect,"success")})},n.cloudGoods&&n.cloudGoods.wish_goods){for(var e in n.cloudGoods.branchs)if(n.cloudGoods.branchs[e].id==n.cloudGoods.wish_goods){n.changeBranch(e);break}}else n.changeBranch(0);n.changeUnit=function(e,t){e.unit=t}}]),angular.module("we7wish").controller("wishPost",["$scope","$http","config","params",function(t,a,n,i){t.we7TypeDefault={wxapp:"微信å°ç¨‹åº",app:"微信公众å·",phoneapp:"APP",aliapp:"支付å®å°ç¨‹åº",webapp:"PC",baiduapp:"百度å°ç¨‹åº"},t.loading=!1,t.page={currentPage:1,totalItems:1,itemsPerPage:20,pagesLength:9,onChange:function(){t.getList()}},t.list=[],t.support_type="",t.keyword="",t.getList=function(e){e=e||t.page.currentPage,t.loading=!0,a.get(n.apiUrl+"&"+i({op:"get_cloud_goods",page:e||1,keyword:t.keyword||"",support_type:t.support_type||""})).success(function(e){t.loading=!1,e.message.errno||(t.list=e.message.message.data,t.page.totalItems=e.message.message.total)}).error(function(){t.loading=!1})},t.addedGoodsId=0,t.addItem=function(e){(e=angular.copy(e)).op="add_cloud_goods",a.post(n.apiUrl,e).success(function(e){e.message.errno?util.message(e.message.message,"","error"):(t.addedGoodsId=e.message.message.goods_id,e.message.message.cloud_goods?$("#modalmessage").text("该应用已在待编辑列表,您å¯ç›´æŽ¥ç¼–辑"):$("#modalmessage").text("å·²æˆåŠŸæ·»åŠ 至待编辑列表,编辑完æˆåŽå¯æ·»åŠ 至星愿应用列表"),$("#modal-message").modal("show"))})},t.gotoEdit=function(){return location.href=n.editUrl+"&id="+t.addedGoodsId,!1},t.getList()}]),angular.module("wxApp",["we7app"]),angular.module("wxApp").controller("MainCtrl",["$scope","$http","config",function(n,a,t){n.module_bindings=[],n.create_type=t.create_type,n.wxappinfo={name:t.wxappinfo.name,version:"",choose:{modules:[],template:1},quickmenu:{show:!0,bottom:{bgcolor:"#bebebe",boundary:"#fff",selectedColor:"#0f0",color:"#428bca"},menus:[{name:"首页",defaultImage:"./resource/images/bottom-default.png",selectedImage:"./resource/images/bottom-default.png",module:{}},{name:"首页",defaultImage:"./resource/images/bottom-default.png",selectedImage:"./resource/images/bottom-default.png",module:{}}]},submit:"yes",token:t.token,uniacid:t.uniacid,modules:[]},n.apps=[],n.createStep=1,n.version=t.version,n.isMuti=2==t.create_type,t.mtype?n.mtype=t.mtype:n.mtype=0==t.create_type?"wxapp":"account",n.designMethod=t.designMethod,n.submitDisabled=!1,t.isedit&&(n.wxappinfo.choose.modules=t.wxappinfo.modules,n.wxappinfo.quickmenu=t.wxappinfo.quickmenu,n.wxappinfo.version=t.wxappinfo.version,n.wxappinfo.description=t.wxappinfo.description),n.uploadMultiImage=function(t){require(["fileUploader"],function(e){e.init(function(e){n.wxappinfo[t]=e.url,n.$apply(n.wxappinfo)},{direct:!0,multiple:!1})})},n.delMultiImage=function(e){n.wxappinfo[e]=""};var e=t.bindingsUrl;n.moduleEntries=[],n.prevStep=function(){n.createStep<=1?n.createStep=1:--n.createStep,3==n.createStep&&3==n.designMethod&&(n.isMuti||(n.createStep=1))},n.nextStep=function(){var t;4<n.createStep?n.createStep=4:n.checkComplete()&&(n.createStep+=1),2==n.createStep&&3==n.designMethod&&(n.isMuti?(t=[],angular.forEach(n.wxappinfo.choose.modules,function(e){t.push(e.name)}),t=t.join(","),a.post(e,{modules:t}).then(function(e){var a;"0"==e.data.message.errno&&(e=e.data.message.message,a=[],angular.forEach(e,function(e){e.module=e.name;for(var t=0;t<e.bindings.length;t++)e.bindings[t].modulename=e.title,a.push(e.bindings[t])}),n.module_bindings=a,n.wxappinfo.choose.modules=e)}),n.createStep=3):n.createStep=4)},n.backToStep=function(e){e=parseInt(e);e<n.createStep&&(e<=2&&(n.type=0),n.createStep=e)},n.selectType=function(e){n.type=parseInt(e),$(':hidden[name="type"]').val(e)},n.changeType=function(e){n.type=parseInt(e),$(':hidden[name="type"]').val(e)},n.searchTpl=function(){var e=$(':text[id="searchtpl"]').val();"默认模版".match(e)?($(':hidden[name="template"]').val(1),$(".select-tem-list > ul").show()):($(':hidden[name="template"]').val(""),$(".select-tem-list > ul").hide())},n.selectTpl=function(e){n.wxappinfo.choose.template=e},n.getModuleEntries=function(){if(0==n.moduleEntries.length&&n.wxappinfo.choose.modules)for(i in n.wxappinfo.choose.modules)if(n.wxappinfo.choose.modules[i].bindings)for(j in n.wxappinfo.choose.modules[i].bindings)n.moduleEntries.push({title:n.wxappinfo.choose.modules[i].bindings[j].title,url:n.wxappinfo.choose.modules[i].bindings[j].do,module:n.wxappinfo.choose.modules[i].title})},n.showMenu=function(){n.wxappinfo.quickmenu.show=!n.wxappinfo.quickmenu.show},n.addMenu=function(){if(5<=n.wxappinfo.quickmenu.menus.length)return!1;n.wxappinfo.quickmenu.menus.push({name:"首页",defaultImage:"./resource/images/bottom-default.png",selectedImage:"./resource/images/bottom-default.png",module:{}})},n.delMenu=function(e){n.wxappinfo.quickmenu.menus=_.without(n.wxappinfo.quickmenu.menus,n.wxappinfo.quickmenu.menus[e])},n.addDefaultImg=function(t){require(["fileUploader"],function(e){e.show(function(e){n.wxappinfo.quickmenu.menus[t].defaultImage=e.url,n.$apply(n.wxappinfo)},{direct:!0,multiple:!1})})},n.addSelectedImg=function(t){require(["fileUploader"],function(e){e.show(function(e){n.wxappinfo.quickmenu.menus[t].selectedImage=e.url,n.$apply(n.wxappinfo)},{direct:!0,multiple:!1})})},n.addModuleImage=function(t){require(["fileUploader"],function(e){e.show(function(e){t.newicon=e.url,n.$apply(n.wxappinfo)},{direct:!0,multiple:!1})})},n.checkComplete=function(){n.createStep;if(!n.wxappinfo.uniacid){if(!n.wxappinfo.name)return util.message("å°ç¨‹åºå称ä¸å¯ä¸ºç©ºï¼"),!1;if(!n.wxappinfo.account)return util.message("å°ç¨‹åºè´¦å·ä¸å¯ä¸ºç©ºï¼"),!1;if(!n.wxappinfo.original)return util.message("原始IDä¸å¯ä¸ºç©ºï¼"),!1;if(!n.wxappinfo.appid)return util.message("AppIdä¸å¯ä¸ºç©ºï¼"),!1;if(!n.wxappinfo.appsecret)return util.message("AppSecretä¸å¯ä¸ºç©ºï¼"),!1}return n.wxappinfo.description?!(!n.wxappinfo.version||!/^[0-9]{1,2}\.[0-9]{1,2}(\.[0-9]{1,2})?$/.test(n.wxappinfo.version))||(util.message("版本å·é”™è¯¯ï¼Œåªèƒ½æ˜¯æ•°å—ã€ç‚¹ï¼Œæ•°å—最多2ä½ï¼Œä¾‹å¦‚ 1.1.1 或1.2"),!1):(util.message("请填写æè¿°"),!1)},n.wxapp_module_select=function(e,t){angular.isArray(t)||(t=[t]),n.wxappinfo.choose.modules=t,angular.forEach(n.wxappinfo.choose.modules,function(e,t,a){e.module=e.name}),n.$apply()},n.package=function(e){return(0!=n.wxappinfo.choose.modules.length||confirm("æ·»åŠ æ¨¡å—应用åŽæ‰å¯è¿›è¡Œæ‰“包æ“作,是å¦ç»§ç»ä»…ä¿å˜ï¼Ÿ"))&&(n.submitDisabled=!0,a.post(t.wxappPostUrl,n.wxappinfo).success(function(e){e.message.errno?util.message(e.message.message,"","error"):util.message(e.message.message,e.redirect,"success"),n.submitDisabled=!1})),!1},$("#resource_module").unbind("click").click(function(){require(["fileUploader"],function(e){e.show(function(e){n.wxapp_module_select("module",e)},{direct:!0,multiple:n.isMuti,isWechat:!1,type:"module",others:{user_module:2,mtype:n.mtype,cover:"account"==n.mtype}})})})}]),angular.module("wxApp").controller("WxappEditCtrl",["$scope","$http","config",function(a,n,i){a.uniacid=i.uniacid,a.multiid=i.multiid,a.success_url=i.success_url,a.account_list=[],a.current_module="",a.category={id:"",name:"",displayorder:"",linkurl:""},a.wxapp=i.wxapp,a.slideedit=function(e){a.wxapp="slideedit",a.slideid=e},a.navedit=function(e){a.wxapp="navedit",a.navid=e},a.recommendedit=function(e,t){a.wxapp="recommendedit",a.recommendid=e,a.recommendpid=t},a.showAccount=function(t){a.account_list="",n.post(i.links.accountList,{module:t}).success(function(e){a.account_list=e.message.message,a.current_module=t,console.dir(e)}),$("#show_account").modal("show")},a.selectAccount=function(t,e){var a=window.location.href;n.post(i.links.saveConnection,{module:t,uniacid:e}).success(function(e){0==e.message.errno?($(".js-connection-img-"+t).attr("src",e.message.message.thumb),$(".js-connection-name-"+t).text(e.message.message.name),util.message("修改æˆåŠŸ",a,"success")):util.message(e.message.message,"","error"),$("#show_account").modal("hide")})},a.categoryedit=function(e,t){a.wxapp="categoryedit",a.categoryeditid=e,a.categoryparentid=t},a.get_categorys=function(){n.post(i.links.getCategorys,{uniacid:a.uniacid,multiid:a.multiid}).success(function(e){a.categorys=e.message.message})},a.get_categorys(),a.edit_category=function(){a.categorys.push({name:"",displayorder:"",linkurl:""})},a.del_category=function(e){null!=a.categorys[e].id?(n.post(i.links.delCategory,{id:a.categorys[e].id}).success(function(){}),a.get_categorys()):a.categorys.splice(e,1)},a.save_category=function(){if(a.name_exist=!1,angular.forEach(a.categorys,function(e){""==e.name&&(util.message("请填写类å"),a.name_exist=!0)}),1==a.name_exist)return!1;n.post(i.links.saveCategory,{post:a.categorys,uniacid:uniacid,multiid:i.multiid}).success(function(e){}),a.get_categorys(),$("#myModal").modal("hide")}}]),angular.module("wxApp").controller("AccountManageWxappCtrl",["$scope","$http","config",function(a,t,n){a.wxapp_version_lists=n.wxapp_version_lists,a.wxapp_modules=n.wxapp_modules,a.version_exist=n.version_exist,a.activeVersion={},a.modules=n.wxapp_modules,a.search={},a.searchModuleName=function(){if(a.search.moduleName)for(key in a.modules={},a.wxapp_modules)-1!=a.wxapp_modules[key].title.indexOf(a.search.moduleName)&&(a.modules[key]=a.wxapp_modules[key])},a.showEditVersionInfoModal=function(e){$("#modal_edit_versioninfo").modal("show"),a.activeVersion=e?angular.copy(e):{},a.middleVersion=angular.copy(a.activeVersion),!_.isEmpty(a.activeVersion)&&_.isEmpty(a.activeVersion.modules)&&$(".wxapp-module-list .add").css("display","")},a.showEditModuleModal=function(){$("#modal_edit_module").modal("show"),a.newWxModule={}},a.selectedWxModule=function(e,t){t=$(t.target).parents(".select-module-wxapp");t.find("span").removeClass("hide"),t.siblings().find("span").addClass("hide"),a.newWxModule=e},a.changeWxModules=function(){a.newWxModule||util.message("请选择一个应用模å—ï¼"),a.activeVersion.modules&&3!=a.activeVersion.design_method?-1<_.indexOf(a.activeVersion.modules,a.newWxModule)?util.message("该应用模å—å·²å˜åœ¨ï¼"):a.activeVersion.modules.push(a.newWxModule):(a.activeVersion.modules=[a.newWxModule],$(".wxapp-module-list .add").css("display","none")),$("#modal_edit_module").modal("hide")},a.editVersionInfo=function(){if(_.isEmpty(a.activeVersion.modules))return util.message("应用模å—ä¸å¯ä¸ºç©ºï¼"),!1;t.post(n.links.edit_version,{version_info:a.activeVersion}).success(function(e){$("#modal_edit_versioninfo").modal("hide"),0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})},a.cancelVersionInfo=function(){a.middleVersion.modules?a.activeVersion.modules=a.middleVersion.modules:a.activeVersion.modules=[]},a.delWxappVersion=function(e){e=parseInt(e);t.post(n.links.del_version,{version_id:e}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})},a.delModule=function(e){a.modules_values=[],angular.forEach(a.activeVersion.modules,function(e){a.modules_values.push(e)}),a.activeVersion.modules=a.modules_values;e=_.indexOf(a.activeVersion.modules,e);-1<e&&(a.activeVersion.modules=_.without(a.activeVersion.modules,a.activeVersion.modules[e])),_.isEmpty(a.activeVersion.modules)&&$(".wxapp-module-list .add").css("display","")}}]),angular.module("wxApp").controller("PaymentCtrl",["$scope","$http","config",function(n,t,e){(n.config=e).paysetting&&e.paysetting.wechat_facilitator&&e.paysetting.wechat_facilitator.service&&(e.paysetting.wechat_facilitator.service=String(e.paysetting.wechat_facilitator.service)),n.paysetting=e.paysetting,n.saveEdit=function(e){if("wechat"==e){if(""==n.paysetting.wechat.mchid)return util.message("请填写商户å·","","info"),!1;if(""==n.paysetting.wechat.signkey)return util.message("请填写支付秘钥","","info"),!1}t.post(n.config.saveurl,{type:e,version_id:n.config.version_id,param:n.paysetting[e]}).success(function(e){return 0!=e.message.errno?(util.message(e.message.message,"","info"),!1):($(".modal").modal("hide"),void util.message(e.message.message,e.redirect,"success"))})},$(".modal").on("hide.bs.modal",function(){t.post(n.config.get_setting_url,{}).success(function(e){n.paysetting=e.message.message})}),n.tokenGen=function(e){if(confirm("确定è¦ä¿®æ”¹å¯†é’¥å—?")){for(var t="",a=0;a<32;a++)t+="abcdefghijklmnopqrstuvwxyz0123456789"[parseInt(32*Math.random())];"wechat.signkey"==e&&(n.paysetting.wechat.signkey=t)}}}]),angular.module("wxApp").controller("WxappWelcomeCtrl",["$scope","$http","config",function(n,e,t){n.notices=t.notices,n.loaderror=0,n.last_modules=null,n.buildAccountModules=function(){e.post("./index.php?c=home&a=welcome&do=build_account_modules")},n.buildAccountModules(),"v"==t.family&&(n.recommend={recommend:{name:"推è应用",list:[],ads:[],icon:"recommend"},"new-app":{name:"新应用",list:[],ads:[],icon:"new"},essential:{name:"下载排行",list:[],ads:[],icon:"down"},hot:{name:"çƒé—¨æŽ’è¡Œ",list:[],ads:[],icon:"hot"},large:{name:"大é¢åº”用排行",list:[],ads:[],icon:"big"}},require(),require(),require(),n.changeTab=function(a){a&&n.recommend[a].list.length<=0&&(n.showLoading=!0,require())})}]),angular.module("wxApp").controller("moduleLinkUniacidCtrl",["$scope","$http","config","we7TypeDefault",function(n,a,i,e){for(var t in n.versionInfo=i.version_info,n.module="",n.selectedAccount="",n.loadData=!1,n.linkAccounts="",n.searchKeyword="",n.typeSign=i.typeSign,delete e.welcome,"wxapp"!=n.typeSign&&delete e[i.typeSign],e){n.activeTypeSign=t;break}n.initModule=function(e){n.module=e,n.changeType("wxapp")},n.changeType=function(e){n.loadData=!0,n.selectedAccount="",n.searchLinkAccount(n.module,e)},n.searchLinkAccount=function(e,t){n.activeTypeSign=t,setTimeout(function(){$("select").niceSelect&&$("select").niceSelect("update")},0),$("#show-account").modal("show"),a.post(i.links.search_link_account,{module_name:e,type_sign:t}).success(function(e){n.loadData=!1,0==e.message.errno?n.linkAccounts=e.message.message:util.message(e.message.message)})},n.selectLinkAccount=function(a){angular.forEach(n.linkAccounts,function(e,t){t==a.uniacid?n.linkAccounts[t].checked=1:n.linkAccounts[t].checked=0}),n.selectedAccount=a},n.module_unlink_uniacid=function(e){a.post(i.links.module_unlink_uniacid,{version_id:n.versionInfo.id,module_name:e}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,e.redirect)})},n.moduleLinkUniacid=function(){$("#show-account").modal("hide"),a.post(i.links.module_link_uniacid,{module_name:n.module,submit:"yes",token:i.token,uniacid:n.selectedAccount.uniacid,version_id:n.versionInfo.id}).success(function(e){0==e.message.errno?util.message("å…³è”æˆåŠŸ","refresh","success"):util.message(e.message.message)}),n.module=""}}]),angular.module("wxApp").controller("WxappEntranceCtrl",["$scope","$http","serviceCommon","config",function(e,t,a,n){e.moduleList=n.moduleList,e.success=function(e){var e=parseInt(e),t=$('<span class="label label-success" style="z-index:10;width:90px;height:34px;line-height:28px;"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>');a.copySuccess(e,t)}}]),angular.module("wxApp").controller("StatisticeCtrl",["$scope","$http","serviceCommon","config",function(n,a,e,i){require(["echarts"],function(e){var t=e.init(document.getElementById("chart-line"));option={tooltip:{trigger:"axis",axisPointer:{type:"line"}},grid:{left:"3%",right:"3%",bottom:"3%",containLabel:!0},xAxis:{data:[]},yAxis:{splitArea:{show:!0}},series:[{name:"æ•°é‡",type:"line",smooth:!0,data:[]}]},t.showLoading(),n.dateRange={startDate:moment().subtract(1,"days").format("YYYY-MM-DD"),endDate:moment().subtract(1,"days").format("YYYY-MM-DD")},n.changeDivideType=function(e){n.visitDivideType=e,n.getVisitApi("week")},n.getVisitApi=function(e){n.timeType=e,a.post(i.links.visitApi,{divide_type:n.visitDivideType,time_type:e,daterange:n.dateRange}).success(function(e){0!=e.message.errno&&util.message(e.message.message,"","error"),t.hideLoading(),option.xAxis.data=e.message.message.data_x,option.series[0].data=e.message.message.data_y,t.setOption(option)})},n.visitDivideType="session_cnt",n.visitTimeType="week",n.getVisitApi(n.visitTimeType),n.$watch("dateRange",function(e,t){var a={startDate:moment(e.startDate).format("YYYY-MM-DD"),endDate:moment(e.endDate).format("YYYY-MM-DD")},e=moment(t.startDate).format("YYYY-MM-DD"),t=moment(t.endDate).format("YYYY-MM-DD");a.startDate==e&&a.endDate==t||(n.dateRange.startDate=a.startDate,n.dateRange.endDate=a.endDate,n.getVisitApi("daterange"))},!0)})}]),angular.module("wxApp").controller("MiniappManageCtrl",["$scope","$http","config",function(a,t,n){a.version_lists=n.version_lists,a.miniapp_modules=n.miniapp_modules,a.version_exist=n.version_exist,a.activeVersion={},a.modules=n.miniapp_modules,a.search={},a.searchModuleName=function(){if(a.search.moduleName)for(key in a.modules={},a.miniapp_modules)-1!=a.miniapp_modules[key].title.indexOf(a.search.moduleName)&&(a.modules[key]=a.miniapp_modules[key])},a.showEditVersionInfoModal=function(e){$("#modal_edit_versioninfo").modal("show"),a.showadd=!1,a.activeVersion=e||{},a.middleVersion=angular.copy(a.activeVersion),!_.isEmpty(a.activeVersion)&&_.isEmpty(a.activeVersion.modules)&&(a.showadd=!0)},a.showEditModuleModal=function(){$("#modal_edit_module").modal("show"),a.newWxModule={}},a.selectedWxModule=function(e,t){t=$(t.target).parents(".select-module-wxapp");t.find("span").removeClass("hide"),t.siblings().find("span").addClass("hide"),a.newWxModule=e},a.changeWxModules=function(){a.newWxModule||util.message("请选择一个应用模å—ï¼"),a.activeVersion.module={name:a.newWxModule.name,version:a.newWxModule.version,module_info:a.newWxModule},a.showadd=!1,$("#modal_edit_module").modal("hide")},a.editVersionInfo=function(){if(_.isEmpty(a.activeVersion.module))return util.message("应用模å—ä¸å¯ä¸ºç©ºï¼"),!1;t.post(n.links.edit_version,{version_id:a.activeVersion.id,name:a.activeVersion.module.name}).success(function(e){$("#modal_edit_versioninfo").modal("hide"),0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})},a.cancelVersionInfo=function(){a.middleVersion.modules?a.activeVersion.modules=a.middleVersion.modules:a.activeVersion.modules=[]},a.delWxappVersion=function(e){e=parseInt(e);t.post(n.links.del_version,{version_id:e}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message)})},a.delModule=function(e){a.activeVersion.modules=[],a.showadd=!0}}]),angular.module("wxApp").controller("CreateMiniappCtrl",["$scope","$http","config",function(a,t,n){a.presetTypeInfo=n.preset_type_info,a.miniapp={name:n.miniapp.name,version:"",choose_module:[],submit:"yes",token:n.token,uniacid:n.uniacid,modules:[],type:n.type},a.apps=[],a.createStep=1,a.version=n.version,a.newversion=0<n.uniacid,a.designMethod=n.designMethod,a.submitDisabled=!1;n.bindingsUrl;a.moduleEntries=[],a.uploadMultiImage=function(t){require(["fileUploader"],function(e){e.init(function(e){a.miniapp[t]=e.url,a.$apply(a.miniapp)},{direct:!0,multiple:!1})})},a.delMultiImage=function(e){a.miniapp[e]=""},a.prevStep=function(){a.createStep=1},a.nextStep=function(){a.checkComplete()&&(a.createStep=2)},a.checkComplete=function(){if(0==a.miniapp.uniacid){if(!a.miniapp.name)return util.message("å称ä¸å¯ä¸ºç©ºï¼"),!1;if(!a.miniapp.appid)return util.message("AppIdä¸å¯ä¸ºç©ºï¼"),!1}return a.miniapp.description?!(!a.miniapp.version||!/^[0-9]{1,2}\.[0-9]{1,2}(\.[0-9]{1,2})?$/.test(a.miniapp.version))||(util.message("版本å·é”™è¯¯ï¼Œåªèƒ½æ˜¯æ•°å—ã€ç‚¹ï¼Œæ•°å—最多2ä½ï¼Œä¾‹å¦‚ 1.1.1 或1.2"),!1):(util.message("请填写æè¿°"),!1)},a.package=function(e){return(a.miniapp.choose_module||confirm("æ·»åŠ æ¨¡å—应用åŽæ‰å¯è¿›è¡Œæ‰“包æ“作,是å¦ç»§ç»ä»…ä¿å˜ï¼Ÿ"))&&(a.submitDisabled=!0,t.post(n.postUrl,{version:a.miniapp.version,description:a.miniapp.description,token:a.miniapp.token,module_name:a.miniapp.choose_module.name,uniacid:a.miniapp.uniacid,submit:"yes",type:a.miniapp.type}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,"","error"),a.submitDisabled=!1})),!1},a.resourceModule=function(){require(["fileUploader"],function(e){e.show(function(e){a.miniapp.choose_module=e,a.$apply(a.miniapp.choose_module)},{direct:!0,multiple:a.isMuti,isWechat:!1,type:"module",others:{user_module:!n.uniacid||n.mtype?1:0,uid:n.uid||0,module_uniacid:n.uniacid||0,mtype:n.mtype||a.presetTypeInfo.type_sign,cover:"account"==n.mtype||"account"==a.presetTypeInfo.type_sign}})})}}]),angular.module("wxApp").controller("tominiprogram",["$scope","config","$http",function(n,i){for(var e in n.tomini_lists=[],n.edit_list=[],n.max_count=i.max_count,n.is_add=1,i.tomini_lists)n.tomini_lists.push(i.tomini_lists[e]);n.showForm=function(e){if(n.is_add=e,n.edit_list=[],n.is_add)for(var t=i.tomini_lists.length;t<i.max_count;t++)n.edit_list[t]||n.edit_list.push({appid:"",app_name:""});else for(var a in i.tomini_lists)n.edit_list.push(i.tomini_lists[a]);$("#addminiprogram").modal("show")}}]),angular.module("wxApp").controller("wxappVersion",["$scope","config","$http",function(t,a,n){t.platform_version_info=a.platform_version_info,t.preview_qrcode="",t.reason=[],t.postSuccess=function(e){console.log(e),e.message&&0==e.message.errno?(util.message(e.message.message,"","success"),location.reload()):util.message(e.message?e.message.message:"出错了","","error")},t.showQr=function(e){t.preview_qrcode=a.qrcodeUrl+"&version_id="+e.version_id,$("#qrCodeModal").modal("show")},t.showReason=function(e){t.reason=e.reason||[],$("#reasonModal").modal("show")},t.submitAudit=function(e){n.post(a.submitAuditUrl,{version_id:e.version_id}).success(function(e){t.postSuccess(e)})},t.release=function(e){n.post(a.releaseUrl,{version_id:e.version_id}).success(function(e){t.postSuccess(e)})},t.undo=function(e){0==e.day_num||0==e.month_num?util.message("æ’¤å›žå®¡æ ¸æ¬¡æ•°å·²ç”¨å®Œ!","","error"):n.post(a.undoUrl,{version_id:e.version_id}).success(function(e){t.postSuccess(e)})},t.delete=function(e){n.post(a.deleteUrl,{version_id:e.version_id}).success(function(e){t.postSuccess(e)})},t.revert=function(e){n.post(a.revertUrl,{version_id:e.version_id}).success(function(e){t.postSuccess(e)})}}]),angular.module("wxApp").controller("domainSetCtrl",["$scope","$http","serviceCommon","config",function(a,n,e,i){a.newDomain="",a.domainEdit=function(e,t){if("add"==e&&!a.newDomain||"delete"==e&&!t)return!1;"delete"==e?util.confirm(function(){a.domainPost(e,t)},function(){},"确认è¦åœç”¨å—?"):a.domainPost(e,a.newDomain)},a.domainPost=function(e,t){n.post(i.domainEditURl,{action:e,webviewdomain:t}).success(function(e){0==e.message.errno?util.message(e.message.message,e.redirect,"success"):util.message(e.message.message,e.redirect,"error")})}}]),angular.module("wxApp").directive("we7ChooseMore",["$http",function(e){return{restrict:"EA",templateUrl:"directive-selectmore-module-item.html",scope:{selectModules:"=we7Modules",selectSingle:"=we7ChooseSingle"},link:function(a){a.selectMore=function(){a.wxappModuleList&&0!=a.wxappModuleList.length?$("#modules-Modal").modal("show"):e({method:"POST",url:"./index.php?c=wxapp&a=post&do=get_wxapp_modules",cache:!0}).success(function(e,t){a.wxappModuleList=e.message.message,$("#modules-Modal").modal("show")})},a.selectModule=function(e){if(a.selectSingle)return a.selectModules=[],a.selectModules.push({title:e.title,module:e.name,icon:e.logo,version:e.version,bindings:e.bindings}),$("#modules-Modal").modal("hide"),$(".app-list .select-more").css("display","none"),!1;a.selectModules.push({title:e.title,module:e.name,icon:e.logo,version:e.version,bindings:e.bindings}),$("#modules-Modal").modal("hide")},a.delModule=function(e){-1<_.indexOf(a.selectModules,e)&&(a.selectModules=_.without(a.selectModules,e)),_.isEmpty(a.selectModules)&&$(".app-list .select-more").css("display","")}}}}]),angular.module("wxApp").service("serviceCommon",["$rootScope",function(e){var t={copySuccess:function(e,t){var e=parseInt(e),t=t,a=$("#copy-"+e).next().html();(!a||a.indexOf('<span class="label label-success" style="position:absolute;z-index:10"><i class="fa fa-check-circle"></i> å¤åˆ¶æˆåŠŸ</span>')<0)&&$("#copy-"+e).after(t),setTimeout(function(){t.remove()},2e3)}};return t}]);