(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["common/vendor"],{"0676":function(e,t){e.exports=function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports["default"]=e.exports},"092b":function(e,t,n){"use strict";var r=n("4ea4");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=r(n("9523")),i=r(n("970b")),a=r(n("5bc3")),s=r(n("febd")),u=r(n("7a28")),c=r(n("69d7")),f=r(n("a294")),l=n("6e37"),d=r(n("3832"));function h(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function p(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:{};(0,i.default)(this,e),(0,l.isPlainObject)(t)||(t={},console.warn("设置全局参数必须接收一个Object")),this.config=(0,d.default)(p(p({},f.default),t)),this.interceptors={request:new u.default,response:new u.default}}return(0,a.default)(e,[{key:"setConfig",value:function(e){this.config=e(this.config)}},{key:"middleware",value:function(e){e=(0,c.default)(this.config,e);var t=[s.default,void 0],n=Promise.resolve(e);this.interceptors.request.forEach((function(e){t.unshift(e.fulfilled,e.rejected)})),this.interceptors.response.forEach((function(e){t.push(e.fulfilled,e.rejected)}));while(t.length)n=n.then(t.shift(),t.shift());return n}},{key:"request",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return this.middleware(e)}},{key:"get",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this.middleware(p({url:e,method:"GET"},t))}},{key:"post",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.middleware(p({url:e,data:t,method:"POST"},n))}},{key:"put",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.middleware(p({url:e,data:t,method:"PUT"},n))}},{key:"delete",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.middleware(p({url:e,data:t,method:"DELETE"},n))}},{key:"connect",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.middleware(p({url:e,data:t,method:"CONNECT"},n))}},{key:"head",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.middleware(p({url:e,data:t,method:"HEAD"},n))}},{key:"options",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.middleware(p({url:e,data:t,method:"OPTIONS"},n))}},{key:"trace",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.middleware(p({url:e,data:t,method:"TRACE"},n))}},{key:"upload",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t.url=e,t.method="UPLOAD",this.middleware(t)}},{key:"download",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t.url=e,t.method="DOWNLOAD",this.middleware(t)}}]),e}();t.default=v},"0c57":function(e,t,n){"use strict";(function(e){var r=n("4ea4");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=r(n("2eee")),i=r(n("c973")),a=n("e0eb"),s=r(n("de98")),u=r(n("12eb")),c=s.default.state.apiUrl,f=new u.default,l=function(){var t=(0,i.default)(o.default.mark((function t(n,r){var i,s,u,l,d=arguments;return o.default.wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(i=d.length>2&&void 0!==d[2]?d[2]:{},s=!(d.length>3&&void 0!==d[3])||d[3],u=(0,a.getStorageSync)("u"),l=f.generateId(r,n,i),l||console.log("重复请求"),l){t.next=7;break}return t.abrupt("return",!1);case 7:return t.abrupt("return",new Promise((function(t,o){s&&e.showLoading({title:"加载中..."}),e.request({url:c+n,method:r||"GET",header:{token:u.token||"","content-type":"application/json"},timeout:1e4,data:i||{},complete:function(){e.hideLoading(),f.deleteById(l)},success:function(e){var n=e.data;200==e.statusCode?t(n):((0,a.toast)("网络连接失败,请稍后重试"),o(n))},fail:function(e){(0,a.toast)("网络连接失败,请稍后重试"),o(e)}})})));case 8:case"end":return t.stop()}}),t)})));return function(e,n){return t.apply(this,arguments)}}(),d={};["options","get","post","put","head","delete","trace","connect"].forEach((function(e){d[e]=function(t,n,r){return l(t,e,n,r)}}));var h=d;t.default=h}).call(this,n("543d")["default"])},"0c91":function(e,t,n){"use strict";var r=n("4ea4");Object.defineProperty(t,"__esModule",{value:!0}),t.positionList=t.newsList=t.newsInfo=t.newsGoryList=t.newIndustryIndex=t.messageAdd=t.loginDo=t.loginAdd=t.getUserIndex=t.eventInfo=t.associationInfo=t.associationIndex=t.architectureList=t.applicationAdd=t.addressList=t.activityList=t.activityIndex=t.UserApplication=t.IndustryList=void 0;var o=r(n("0c57"));t.newsGoryList=function(e){return o.default.post("/move/news/gory",e,!1)};t.newsList=function(e){return o.default.post("/move/news/index",e,!1)};t.activityList=function(e){return o.default.post("/move/activity/list",e,!1)};t.activityIndex=function(e){return o.default.post("/move/activity/index",e,!1)};t.associationIndex=function(e){return o.default.post("/move/association/index",e,!1)};t.newsInfo=function(e){return o.default.post("/move/news/find",e,!1)};t.eventInfo=function(e){return o.default.post("/move/activity/find",e,!1)};t.associationInfo=function(e){return o.default.post("/move/association/find",e,!1)};t.architectureList=function(e){return o.default.post("/move/address/architecture",e,!1)};t.positionList=function(e){return o.default.post("/position",e,!1)};t.IndustryList=function(e){return o.default.post("/industry",e,!1)};t.loginAdd=function(e){return o.default.post("/move/login/add",e,!1)};t.loginDo=function(e){return o.default.post("/move/login/login",e,!1)};t.addressList=function(e){return o.default.post("/move/address",e,!1)};t.newIndustryIndex=function(e){return o.default.post("/move/industry/index",e,!1)};t.getUserIndex=function(e){return o.default.post("/move/member/find",e,!1)};t.UserApplication=function(e){return o.default.post("/move/application",e,!1)};t.applicationAdd=function(e){return o.default.post("/move/application/add",e,!1)};t.messageAdd=function(e){return o.default.post("/move/message/add",e,!1)}},"11b0":function(e,t){e.exports=function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)},e.exports.__esModule=!0,e.exports["default"]=e.exports},"12eb":function(e,t,n){"use strict";var r=n("4ea4");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=r(n("7037")),i=r(n("970b")),a=r(n("5bc3"));function s(e,t){var n="undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"===typeof e)return u(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return u(e,t)}(e))||t&&e&&"number"===typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){s=!0,i=e},f:function(){try{a||null==n.return||n.return()}finally{if(s)throw i}}}}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n8;t>>=1)n+=this.lunarInfo[e-1900]&t?1:0;return n+this.leapDays(e)},leapMonth:function(e){return 15&this.lunarInfo[e-1900]},leapDays:function(e){return this.leapMonth(e)?65536&this.lunarInfo[e-1900]?30:29:0},monthDays:function(e,t){return t>12||t<1?-1:this.lunarInfo[e-1900]&65536>>t?30:29},solarDays:function(e,t){if(t>12||t<1)return-1;var n=t-1;return 1==n?e%4==0&&e%100!=0||e%400==0?29:28:this.solarMonth[n]},toGanZhiYear:function(e){var t=(e-3)%10,n=(e-3)%12;return 0==t&&(t=10),0==n&&(n=12),this.Gan[t-1]+this.Zhi[n-1]},toAstro:function(e,t){return"魔羯水瓶双鱼白羊金牛双子巨蟹狮子处女天秤天蝎射手魔羯".substr(2*e-(t<[20,19,21,21,21,22,23,23,23,23,22,22][e-1]?2:0),2)+"座"},toGanZhi:function(e){return this.Gan[e%10]+this.Zhi[e%12]},getTerm:function(e,t){if(e<1900||e>2100)return-1;if(t<1||t>24)return-1;var n=this.sTermInfo[e-1900],r=[parseInt("0x"+n.substr(0,5)).toString(),parseInt("0x"+n.substr(5,5)).toString(),parseInt("0x"+n.substr(10,5)).toString(),parseInt("0x"+n.substr(15,5)).toString(),parseInt("0x"+n.substr(20,5)).toString(),parseInt("0x"+n.substr(25,5)).toString()],o=[r[0].substr(0,1),r[0].substr(1,2),r[0].substr(3,1),r[0].substr(4,2),r[1].substr(0,1),r[1].substr(1,2),r[1].substr(3,1),r[1].substr(4,2),r[2].substr(0,1),r[2].substr(1,2),r[2].substr(3,1),r[2].substr(4,2),r[3].substr(0,1),r[3].substr(1,2),r[3].substr(3,1),r[3].substr(4,2),r[4].substr(0,1),r[4].substr(1,2),r[4].substr(3,1),r[4].substr(4,2),r[5].substr(0,1),r[5].substr(1,2),r[5].substr(3,1),r[5].substr(4,2)];return parseInt(o[t-1])},toChinaMonth:function(e){if(e>12||e<1)return-1;var t=this.nStr3[e-1];return t+="月",t},toChinaDay:function(e){var t;switch(e){case 10:t="初十";break;case 20:t="二十";break;case 30:t="三十";break;default:t=this.nStr2[Math.floor(e/10)],t+=this.nStr1[e%10]}return t},getAnimal:function(e){return this.Animals[(e-4)%12]},solar2lunar:function(e,t,n){if(e<1900||e>2100)return-1;if(1900==e&&1==t&&n<31)return-1;if(e)r=new Date(e,parseInt(t)-1,n);else var r=new Date;var o,i=0,a=(e=r.getFullYear(),t=r.getMonth()+1,n=r.getDate(),(Date.UTC(r.getFullYear(),r.getMonth(),r.getDate())-Date.UTC(1900,0,31))/864e5);for(o=1900;o<2101&&a>0;o++)i=this.lYearDays(o),a-=i;a<0&&(a+=i,o--);var s=new Date,u=!1;s.getFullYear()==e&&s.getMonth()+1==t&&s.getDate()==n&&(u=!0);var c=r.getDay(),f=this.nStr1[c];0==c&&(c=7);var l=o,d=this.leapMonth(o),h=!1;for(o=1;o<13&&a>0;o++)d>0&&o==d+1&&0==h?(--o,h=!0,i=this.leapDays(l)):i=this.monthDays(l,o),1==h&&o==d+1&&(h=!1),a-=i;0==a&&d>0&&o==d+1&&(h?h=!1:(h=!0,--o)),a<0&&(a+=i,--o);var p=o,v=a+1,g=t-1,y=this.toGanZhiYear(l),b=this.getTerm(e,2*t-1),m=this.getTerm(e,2*t),_=this.toGanZhi(12*(e-1900)+t+11);n>=b&&(_=this.toGanZhi(12*(e-1900)+t+12));var w=!1,x=null;b==n&&(w=!0,x=this.solarTerm[2*t-2]),m==n&&(w=!0,x=this.solarTerm[2*t-1]);var k=Date.UTC(e,g,1,0,0,0,0)/864e5+25567+10,O=this.toGanZhi(k+n-1),A=this.toAstro(t,n);return{lYear:l,lMonth:p,lDay:v,Animal:this.getAnimal(l),IMonthCn:(h?"闰":"")+this.toChinaMonth(p),IDayCn:this.toChinaDay(v),cYear:e,cMonth:t,cDay:n,gzYear:y,gzMonth:_,gzDay:O,isToday:u,isLeap:h,nWeek:c,ncWeek:"星期"+f,isTerm:w,Term:x,astro:A}},lunar2solar:function(e,t,n,r){r=!!r;var o=this.leapMonth(e);this.leapDays(e);if(r&&o!=t)return-1;if(2100==e&&12==t&&n>1||1900==e&&1==t&&n<31)return-1;var i=this.monthDays(e,t),a=i;if(r&&(a=this.leapDays(e,t)),e<1900||e>2100||n>a)return-1;for(var s=0,u=1900;u0&&(s+=this.leapDays(e),f=!0),s+=this.monthDays(e,u);r&&(s+=i);var l=Date.UTC(1900,1,30,0,0,0),d=new Date(864e5*(s+n-31)+l),h=d.getUTCFullYear(),p=d.getUTCMonth()+1,v=d.getUTCDate();return this.solar2lunar(h,p,v)}},o=r;t.default=o},"1b30":function(e,t,n){"use strict";var r=n("4ea4");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=r(n("7037"));var i=function e(t){if([null,void 0,NaN,!1].includes(t))return t;if("object"!==(0,o.default)(t)&&"function"!==typeof t)return t;var n=function(e){return"[object Array]"===Object.prototype.toString.call(e)}(t)?[]:{};for(var r in t)t.hasOwnProperty(r)&&(n[r]="object"===(0,o.default)(t[r])?e(t[r]):t[r]);return n};t.default=i},"1fb5":function(e,t,n){"use strict";t.byteLength=function(e){var t=c(e),n=t[0],r=t[1];return 3*(n+r)/4-r},t.toByteArray=function(e){var t,n,r=c(e),a=r[0],s=r[1],u=new i(function(e,t,n){return 3*(t+n)/4-n}(0,a,s)),f=0,l=s>0?a-4:a;for(n=0;n>16&255,u[f++]=t>>8&255,u[f++]=255&t;2===s&&(t=o[e.charCodeAt(n)]<<2|o[e.charCodeAt(n+1)]>>4,u[f++]=255&t);1===s&&(t=o[e.charCodeAt(n)]<<10|o[e.charCodeAt(n+1)]<<4|o[e.charCodeAt(n+2)]>>2,u[f++]=t>>8&255,u[f++]=255&t);return u},t.fromByteArray=function(e){for(var t,n=e.length,o=n%3,i=[],a=0,s=n-o;as?s:a+16383));1===o?(t=e[n-1],i.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],i.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"="));return i.join("")};for(var r=[],o=[],i="undefined"!==typeof Uint8Array?Uint8Array:Array,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,u=a.length;s0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");-1===n&&(n=t);var r=n===t?0:4-n%4;return[n,r]}function f(e){return r[e>>18&63]+r[e>>12&63]+r[e>>6&63]+r[63&e]}function l(e,t,n){for(var r,o=[],i=t;i-1&&t.splice(n,1)}}function p(e,t){e._actions=Object.create(null),e._mutations=Object.create(null),e._wrappedGetters=Object.create(null),e._modulesNamespaceMap=Object.create(null);var n=e.state;g(e,n,[],e._modules.root,!0),v(e,n,t)}function v(e,t,n){var r=e._vm;e.getters={},e._makeLocalGettersCache=Object.create(null);var o=e._wrappedGetters,a={};i(o,(function(t,n){a[n]=function(e,t){return function(){return e(t)}}(t,e),Object.defineProperty(e.getters,n,{get:function(){return e._vm[n]},enumerable:!0})}));var s=f.config.silent;f.config.silent=!0,e._vm=new f({data:{$$state:t},computed:a}),f.config.silent=s,e.strict&&function(e){e._vm.$watch((function(){return this._data.$$state}),(function(){0}),{deep:!0,sync:!0})}(e),r&&(n&&e._withCommit((function(){r._data.$$state=null})),f.nextTick((function(){return r.$destroy()})))}function g(e,t,n,r,o){var i=!n.length,a=e._modules.getNamespace(n);if(r.namespaced&&(e._modulesNamespaceMap[a],e._modulesNamespaceMap[a]=r),!i&&!o){var s=y(t,n.slice(0,-1)),u=n[n.length-1];e._withCommit((function(){f.set(s,u,r.state)}))}var c=r.context=function(e,t,n){var r=""===t,o={dispatch:r?e.dispatch:function(n,r,o){var i=b(n,r,o),a=i.payload,s=i.options,u=i.type;return s&&s.root||(u=t+u),e.dispatch(u,a)},commit:r?e.commit:function(n,r,o){var i=b(n,r,o),a=i.payload,s=i.options,u=i.type;s&&s.root||(u=t+u),e.commit(u,a,s)}};return Object.defineProperties(o,{getters:{get:r?function(){return e.getters}:function(){return function(e,t){if(!e._makeLocalGettersCache[t]){var n={},r=t.length;Object.keys(e.getters).forEach((function(o){if(o.slice(0,r)===t){var i=o.slice(r);Object.defineProperty(n,i,{get:function(){return e.getters[o]},enumerable:!0})}})),e._makeLocalGettersCache[t]=n}return e._makeLocalGettersCache[t]}(e,t)}},state:{get:function(){return y(e.state,n)}}}),o}(e,a,n);r.forEachMutation((function(t,n){var r=a+n;(function(e,t,n,r){var o=e._mutations[t]||(e._mutations[t]=[]);o.push((function(t){n.call(e,r.state,t)}))})(e,r,t,c)})),r.forEachAction((function(t,n){var r=t.root?n:a+n,o=t.handler||t;(function(e,t,n,r){var o=e._actions[t]||(e._actions[t]=[]);o.push((function(t){var o=n.call(e,{dispatch:r.dispatch,commit:r.commit,getters:r.getters,state:r.state,rootGetters:e.getters,rootState:e.state},t);return function(e){return e&&"function"===typeof e.then}(o)||(o=Promise.resolve(o)),e._devtoolHook?o.catch((function(t){throw e._devtoolHook.emit("vuex:error",t),t})):o}))})(e,r,o,c)})),r.forEachGetter((function(t,n){var r=a+n;(function(e,t,n,r){if(e._wrappedGetters[t])return void 0;e._wrappedGetters[t]=function(e){return n(r.state,r.getters,e.state,e.getters)}})(e,r,t,c)})),r.forEachChild((function(r,i){g(e,t,n.concat(i),r,o)}))}function y(e,t){return t.reduce((function(e,t){return e[t]}),e)}function b(e,t,n){return a(e)&&e.type&&(n=t,t=e,e=e.type),{type:e,payload:t,options:n}}function m(e){f&&e===f||(f=e, /*! * vuex v3.6.2 * (c) 2021 Evan You * @license MIT */ function(e){var t=Number(e.version.split(".")[0]);if(t>=2)e.mixin({beforeCreate:r});else{var n=e.prototype._init;e.prototype._init=function(e){void 0===e&&(e={}),e.init=e.init?[r].concat(e.init):r,n.call(this,e)}}function r(){var e=this.$options;e.store?this.$store="function"===typeof e.store?e.store():e.store:e.parent&&e.parent.$store&&(this.$store=e.parent.$store)}}(f))}d.state.get=function(){return this._vm._data.$$state},d.state.set=function(e){0},l.prototype.commit=function(e,t,n){var r=this,o=b(e,t,n),i=o.type,a=o.payload,s=(o.options,{type:i,payload:a}),u=this._mutations[i];u&&(this._withCommit((function(){u.forEach((function(e){e(a)}))})),this._subscribers.slice().forEach((function(e){return e(s,r.state)})))},l.prototype.dispatch=function(e,t){var n=this,r=b(e,t),o=r.type,i=r.payload,a={type:o,payload:i},s=this._actions[o];if(s){try{this._actionSubscribers.slice().filter((function(e){return e.before})).forEach((function(e){return e.before(a,n.state)}))}catch(c){0}var u=s.length>1?Promise.all(s.map((function(e){return e(i)}))):s[0](i);return new Promise((function(e,t){u.then((function(t){try{n._actionSubscribers.filter((function(e){return e.after})).forEach((function(e){return e.after(a,n.state)}))}catch(c){0}e(t)}),(function(e){try{n._actionSubscribers.filter((function(e){return e.error})).forEach((function(t){return t.error(a,n.state,e)}))}catch(c){0}t(e)}))}))}},l.prototype.subscribe=function(e,t){return h(e,this._subscribers,t)},l.prototype.subscribeAction=function(e,t){var n="function"===typeof e?{before:e}:e;return h(n,this._actionSubscribers,t)},l.prototype.watch=function(e,t,n){var r=this;return this._watcherVM.$watch((function(){return e(r.state,r.getters)}),t,n)},l.prototype.replaceState=function(e){var t=this;this._withCommit((function(){t._vm._data.$$state=e}))},l.prototype.registerModule=function(e,t,n){void 0===n&&(n={}),"string"===typeof e&&(e=[e]),this._modules.register(e,t),g(this,this.state,e,this._modules.get(e),n.preserveState),v(this,this.state)},l.prototype.unregisterModule=function(e){var t=this;"string"===typeof e&&(e=[e]),this._modules.unregister(e),this._withCommit((function(){var n=y(t.state,e.slice(0,-1));f.delete(n,e[e.length-1])})),p(this)},l.prototype.hasModule=function(e){return"string"===typeof e&&(e=[e]),this._modules.isRegistered(e)},l.prototype[[104,111,116,85,112,100,97,116,101].map((function(e){return String.fromCharCode(e)})).join("")]=function(e){this._modules.update(e),p(this,!0)},l.prototype._withCommit=function(e){var t=this._committing;this._committing=!0,e(),this._committing=t},Object.defineProperties(l.prototype,d);var _=A((function(e,t){var n={};return O(t).forEach((function(t){var r=t.key,o=t.val;n[r]=function(){var t=this.$store.state,n=this.$store.getters;if(e){var r=S(this.$store,"mapState",e);if(!r)return;t=r.context.state,n=r.context.getters}return"function"===typeof o?o.call(this,t,n):t[o]},n[r].vuex=!0})),n})),w=A((function(e,t){var n={};return O(t).forEach((function(t){var r=t.key,o=t.val;n[r]=function(){var t=[],n=arguments.length;while(n--)t[n]=arguments[n];var r=this.$store.commit;if(e){var i=S(this.$store,"mapMutations",e);if(!i)return;r=i.context.commit}return"function"===typeof o?o.apply(this,[r].concat(t)):r.apply(this.$store,[o].concat(t))}})),n})),x=A((function(e,t){var n={};return O(t).forEach((function(t){var r=t.key,o=t.val;o=e+o,n[r]=function(){if(!e||S(this.$store,"mapGetters",e))return this.$store.getters[o]},n[r].vuex=!0})),n})),k=A((function(e,t){var n={};return O(t).forEach((function(t){var r=t.key,o=t.val;n[r]=function(){var t=[],n=arguments.length;while(n--)t[n]=arguments[n];var r=this.$store.dispatch;if(e){var i=S(this.$store,"mapActions",e);if(!i)return;r=i.context.dispatch}return"function"===typeof o?o.apply(this,[r].concat(t)):r.apply(this.$store,[o].concat(t))}})),n}));function O(e){return function(e){return Array.isArray(e)||a(e)}(e)?Array.isArray(e)?e.map((function(e){return{key:e,val:e}})):Object.keys(e).map((function(t){return{key:t,val:e[t]}})):[]}function A(e){return function(t,n){return"string"!==typeof t?(n=t,t=""):"/"!==t.charAt(t.length-1)&&(t+="/"),e(t,n)}}function S(e,t,n){var r=e._modulesNamespaceMap[n];return r}function P(e,t,n){var r=n?e.groupCollapsed:e.group;try{r.call(e,t)}catch(o){e.log(t)}}function T(e){try{e.groupEnd()}catch(t){e.log("—— log end ——")}}function E(){var e=new Date;return" @ "+I(e.getHours(),2)+":"+I(e.getMinutes(),2)+":"+I(e.getSeconds(),2)+"."+I(e.getMilliseconds(),3)}function I(e,t){return function(e,t){return new Array(t+1).join(e)}("0",t-e.toString().length)+e}var j={Store:l,install:m,version:"3.6.2",mapState:_,mapMutations:w,mapGetters:x,mapActions:k,createNamespacedHelpers:function(e){return{mapState:_.bind(null,e),mapGetters:x.bind(null,e),mapMutations:w.bind(null,e),mapActions:k.bind(null,e)}},createLogger:function(e){void 0===e&&(e={});var t=e.collapsed;void 0===t&&(t=!0);var n=e.filter;void 0===n&&(n=function(e,t,n){return!0});var r=e.transformer;void 0===r&&(r=function(e){return e});var i=e.mutationTransformer;void 0===i&&(i=function(e){return e});var a=e.actionFilter;void 0===a&&(a=function(e,t){return!0});var s=e.actionTransformer;void 0===s&&(s=function(e){return e});var u=e.logMutations;void 0===u&&(u=!0);var c=e.logActions;void 0===c&&(c=!0);var f=e.logger;return void 0===f&&(f=console),function(e){var l=o(e.state);"undefined"!==typeof f&&(u&&e.subscribe((function(e,a){var s=o(a);if(n(e,l,s)){var u=E(),c=i(e),d="mutation "+e.type+u;P(f,d,t),f.log("%c prev state","color: #9E9E9E; font-weight: bold",r(l)),f.log("%c mutation","color: #03A9F4; font-weight: bold",c),f.log("%c next state","color: #4CAF50; font-weight: bold",r(s)),T(f)}l=s})),c&&e.subscribeAction((function(e,n){if(a(e,n)){var r=E(),o=s(e),i="action "+e.type+r;P(f,i,t),f.log("%c action","color: #03A9F4; font-weight: bold",o),T(f)}})))}}};e.exports=j}).call(this,n("c8ba"))},"278c":function(e,t,n){var r=n("c135"),o=n("9b42"),i=n("6613"),a=n("c240");e.exports=function(e,t){return r(e)||o(e,t)||i(e,t)||a()},e.exports.__esModule=!0,e.exports["default"]=e.exports},"27c3":function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={formatNumberString:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,n=0;if("string"===typeof e?n=Number(e):"number"===typeof e&&(n=e),isNaN(n)||0===n)return 0;var r=Math.pow(10,t)-1;return n>r?"".concat(r,"+"):n},formatNumberAddZero:function(e){var t=0;return"string"===typeof e?t=Number(e):"number"===typeof e&&(t=e),isNaN(t)||+t<10?"0"+t:String(t)},formatNumberAddPriceUnit:function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,r=[{value:1,symbol:""},{value:1e3,symbol:"K"},{value:1e4,symbol:"W"}],o=/\.0+$|(\.[0=9]*[1-9])0+$/,i=0;for("string"===typeof e?i=Number(e):"number"===typeof e&&(i=e),t=r.length-1;t>0;t--)if(i>=r[t].value)break;return(i/r[t].value).toFixed(n).replace(o,"$1")+r[t].symbol},random:function(e,t){if(e>=0&&t>0&&t>=e){var n=t-e;return Math.random()*n+e}return 0},randomInt:function(e,t){if(e>=0&&t>0&&t>=e){var n=t-e+1;return Math.floor(Math.random()*n+e)}return 0}};t.default=r},"29a0":function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}},"2ede":function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={random:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return e.sort((function(){return Math.random()-.5}))},isArray:function(e){return"[object Array]"===Object.prototype.toString.call(e)}};t.default=r},"2eee":function(e,t,n){var r=n("7ec2")();e.exports=r},"34f1":function(e,t){},"36c6":function(e,t){function n(t){return e.exports=n=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},e.exports.__esModule=!0,e.exports["default"]=e.exports,n(t)}e.exports=n,e.exports.__esModule=!0,e.exports["default"]=e.exports},"37dc":function(e,t,n){"use strict";(function(e,r){var o=n("4ea4");Object.defineProperty(t,"__esModule",{value:!0}),t.LOCALE_ZH_HANT=t.LOCALE_ZH_HANS=t.LOCALE_FR=t.LOCALE_ES=t.LOCALE_EN=t.I18n=t.Formatter=void 0,t.compileI18nJsonStr=function(e,t){var n=t.locale,r=t.locales,o=t.delimiters;if(!A(e,o))return e;k||(k=new l);var i=[];Object.keys(r).forEach((function(e){e!==n&&i.push({locale:e,values:r[e]})})),i.unshift({locale:n,values:r[n]});try{return JSON.stringify(P(JSON.parse(e),i,o),null,2)}catch(a){}return e},t.hasI18nJson=function e(t,n){k||(k=new l);return T(t,(function(t,r){var o=t[r];return O(o)?!!A(o,n)||void 0:e(o,n)}))},t.initVueI18n=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0;if("string"!==typeof e){var o=[t,e];e=o[0],t=o[1]}"string"!==typeof e&&(e=x());"string"!==typeof n&&(n="undefined"!==typeof __uniConfig&&__uniConfig.fallbackLocale||"en");var i=new _({locale:e,fallbackLocale:n,messages:t,watcher:r}),a=function(e,t){if("function"!==typeof getApp)a=function(e,t){return i.t(e,t)};else{var n=!1;a=function(e,t){var r=getApp().$vm;return r&&(r.$locale,n||(n=!0,w(r,i))),i.t(e,t)}}return a(e,t)};return{i18n:i,f:function(e,t,n){return i.f(e,t,n)},t:function(e,t){return a(e,t)},add:function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return i.add(e,t,n)},watch:function(e){return i.watchLocale(e)},getLocale:function(){return i.getLocale()},setLocale:function(e){return i.setLocale(e)}}},t.isI18nStr=A,t.isString=void 0,t.normalizeLocale=m,t.parseI18nJson=function e(t,n,r){k||(k=new l);return T(t,(function(t,o){var i=t[o];O(i)?A(i,r)&&(t[o]=S(i,n,r)):e(i,n,r)})),t},t.resolveLocale=function(e){return function(t){return t?(t=m(t)||t,function(e){var t=[],n=e.split("-");while(n.length)t.push(n.join("-")),n.pop();return t}(t).find((function(t){return e.indexOf(t)>-1}))):t}};var i=o(n("278c")),a=o(n("970b")),s=o(n("5bc3")),u=o(n("7037")),c=function(e){return null!==e&&"object"===(0,u.default)(e)},f=["{","}"],l=function(){function e(){(0,a.default)(this,e),this._caches=Object.create(null)}return(0,s.default)(e,[{key:"interpolate",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:f;if(!t)return[e];var r=this._caches[e];return r||(r=p(e,n),this._caches[e]=r),v(r,t)}}]),e}();t.Formatter=l;var d=/^(?:\d)+/,h=/^(?:\w)+/;function p(e,t){var n=(0,i.default)(t,2),r=n[0],o=n[1],a=[],s=0,u="";while(s-1?"zh-Hans":e.indexOf("-hant")>-1||function(e,t){return!!t.find((function(t){return-1!==e.indexOf(t)}))}(e,["-tw","-hk","-mo","-cht"])?"zh-Hant":"zh-Hans";var n=["en","fr","es"];t&&Object.keys(t).length>0&&(n=Object.keys(t));var r=function(e,t){return t.find((function(t){return 0===e.indexOf(t)}))}(e,n);return r||void 0}}var _=function(){function e(t){var n=t.locale,r=t.fallbackLocale,o=t.messages,i=t.watcher,s=t.formater;(0,a.default)(this,e),this.locale="en",this.fallbackLocale="en",this.message={},this.messages={},this.watchers=[],r&&(this.fallbackLocale=r),this.formater=s||b,this.messages=o||{},this.setLocale(n||"en"),i&&this.watchLocale(i)}return(0,s.default)(e,[{key:"setLocale",value:function(e){var t=this,n=this.locale;this.locale=m(e,this.messages)||this.fallbackLocale,this.messages[this.locale]||(this.messages[this.locale]={}),this.message=this.messages[this.locale],n!==this.locale&&this.watchers.forEach((function(e){e(t.locale,n)}))}},{key:"getLocale",value:function(){return this.locale}},{key:"watchLocale",value:function(e){var t=this,n=this.watchers.push(e)-1;return function(){t.watchers.splice(n,1)}}},{key:"add",value:function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],r=this.messages[e];r?n?Object.assign(r,t):Object.keys(t).forEach((function(e){y(r,e)||(r[e]=t[e])})):this.messages[e]=t}},{key:"f",value:function(e,t,n){return this.formater.interpolate(e,t,n).join("")}},{key:"t",value:function(e,t,n){var r=this.message;return"string"===typeof t?(t=m(t,this.messages),t&&(r=this.messages[t])):n=t,y(r,e)?this.formater.interpolate(r[e],n).join(""):(console.warn("Cannot translate the value of keypath ".concat(e,". Use the value of keypath as default.")),e)}}]),e}();function w(e,t){e.$watchLocale?e.$watchLocale((function(e){t.setLocale(e)})):e.$watch((function(){return e.$locale}),(function(e){t.setLocale(e)}))}function x(){return"undefined"!==typeof e&&e.getLocale?e.getLocale():"undefined"!==typeof r&&r.getLocale?r.getLocale():"en"}t.I18n=_;var k,O=function(e){return"string"===typeof e};function A(e,t){return e.indexOf(t[0])>-1}function S(e,t,n){return k.interpolate(e,t,n).join("")}function P(e,t,n){return T(e,(function(e,r){(function(e,t,n,r){var o=e[t];if(O(o)){if(A(o,r)&&(e[t]=S(o,n[0].values,r),n.length>1)){var i=e[t+"Locales"]={};n.forEach((function(e){i[e.locale]=S(o,e.values,r)}))}}else P(o,n,r)})(e,r,t,n)})),e}function T(e,t){if(Array.isArray(e)){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:void 0,t=this.$parent;while(t){if(!t.$options||t.$options.name===e)return t;t=t.$parent}return!1}},"543d":function(e,t,n){"use strict";(function(e,r){var o=n("4ea4");Object.defineProperty(t,"__esModule",{value:!0}),t.createApp=jt,t.createComponent=Bt,t.createPage=Ft,t.createPlugin=Vt,t.createSubpackageApp=qt,t.default=void 0;var i,a=o(n("278c")),s=o(n("9523")),u=o(n("b17c")),c=o(n("448a")),f=o(n("7037")),l=n("37dc"),d=o(n("66fd"));function h(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function p(e){for(var t=1;t>16&255):64===r?String.fromCharCode(t>>16&255,t>>8&255):String.fromCharCode(t>>16&255,t>>8&255,255&t);return o}:atob;var b=Object.prototype.toString,m=Object.prototype.hasOwnProperty;function _(e){return"function"===typeof e}function w(e){return"string"===typeof e}function x(e){return"[object Object]"===b.call(e)}function k(e,t){return m.call(e,t)}function O(){}function A(e){var t=Object.create(null);return function(n){var r=t[n];return r||(t[n]=e(n))}}var S=/-(\w)/g,P=A((function(e){return e.replace(S,(function(e,t){return t?t.toUpperCase():""}))}));function T(e){var t={};return x(e)&&Object.keys(e).sort().forEach((function(n){t[n]=e[n]})),Object.keys(t)?t:e}var E=["invoke","success","fail","complete","returnValue"],I={},j={};function C(e,t){Object.keys(t).forEach((function(n){-1!==E.indexOf(n)&&_(t[n])&&(e[n]=function(e,t){var n=t?e?e.concat(t):Array.isArray(t)?t:[t]:e;return n?function(e){for(var t=[],n=0;n1&&void 0!==arguments[1]?arguments[1]:{};return["success","fail","complete"].forEach((function(n){if(Array.isArray(e[n])){var r=t[n];t[n]=function(o){M(e[n],o,t).then((function(e){return _(r)&&r(e)||e}))}}})),t}function U(e,t){var n=[];Array.isArray(I.returnValue)&&n.push.apply(n,(0,c.default)(I.returnValue));var r=j[e];return r&&Array.isArray(r.returnValue)&&n.push.apply(n,(0,c.default)(r.returnValue)),n.forEach((function(e){t=e(t)||t})),t}function N(e){var t=Object.create(null);Object.keys(I).forEach((function(e){"returnValue"!==e&&(t[e]=I[e].slice())}));var n=j[e];return n&&Object.keys(n).forEach((function(e){"returnValue"!==e&&(t[e]=(t[e]||[]).concat(n[e]))})),t}function F(e,t,n){for(var r=arguments.length,o=new Array(r>3?r-3:0),i=3;i0&&void 0!==arguments[0]?arguments[0]:{},r=arguments.length,o=new Array(r>1?r-1:0),i=1;i-1?"zh-Hans":e.indexOf("-hant")>-1||function(e,t){return!!t.find((function(t){return-1!==e.indexOf(t)}))}(e,["-tw","-hk","-mo","-cht"])?"zh-Hant":"zh-Hans";var n=function(e,t){return t.find((function(t){return 0===e.indexOf(t)}))}(e,["en","fr","es"]);return n||void 0}}function ae(){if(_(getApp)){var t=getApp({allowDefault:!0});if(t&&t.$vm)return t.$vm.$locale}return ie(e.getSystemInfoSync().language)||"en"}var se=[];"undefined"!==typeof r&&(r.getLocale=ae);var ue={promiseInterceptor:B},ce=Object.freeze({__proto__:null,upx2px:function(t,n){if(0===X&&function(){var t=e.getSystemInfoSync(),n=t.platform,r=t.pixelRatio,o=t.windowWidth;X=o,ee=r,Q="ios"===n}(),t=Number(t),0===t)return 0;var r=t/750*(n||X);return r<0&&(r=-r),r=Math.floor(r+1e-4),0===r&&(r=1!==ee&&Q?.5:1),t<0?-r:r},getLocale:ae,setLocale:function(e){var t=!!_(getApp)&&getApp();if(!t)return!1;var n=t.$vm.$locale;return n!==e&&(t.$vm.$locale=e,se.forEach((function(t){return t({locale:e})})),!0)},onLocaleChange:function(e){-1===se.indexOf(e)&&se.push(e)},addInterceptor:function(e,t){"string"===typeof e&&x(t)?C(j[e]||(j[e]={}),t):x(e)&&C(I,e)},removeInterceptor:function(e,t){"string"===typeof e?x(t)?$(j[e],t):delete j[e]:x(e)&&$(I,e)},interceptors:ue});var fe,le={name:function(e){return"back"===e.exists&&e.delta?"navigateBack":"redirectTo"},args:function(e){if("back"===e.exists&&e.url){var t=function(e){var t=getCurrentPages(),n=t.length;while(n--){var r=t[n];if(r.$page&&r.$page.fullPath===e)return n}return-1}(e.url);if(-1!==t){var n=getCurrentPages().length-1-t;n>0&&(e.delta=n)}}}},de={args:function(e){var t=parseInt(e.current);if(!isNaN(t)){var n=e.urls;if(Array.isArray(n)){var r=n.length;if(r)return t<0?t=0:t>=r&&(t=r-1),t>0?(e.current=n[t],e.urls=n.filter((function(e,r){return!(r2&&void 0!==arguments[2]?arguments[2]:{},r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},o=arguments.length>4&&void 0!==arguments[4]&&arguments[4];if(x(t)){var i=!0===o?t:{};for(var a in _(n)&&(n=n(t,i)||{}),t)if(k(n,a)){var s=n[a];_(s)&&(s=s(t[a],t,i)),s?w(s)?i[s]=t[a]:x(s)&&(i[s.name?s.name:a]=s.value):console.warn("The '".concat(e,"' method of platform '微信小程序' does not support option '").concat(a,"'"))}else-1!==Ae.indexOf(a)?_(t[a])&&(i[a]=Se(e,t[a],r)):o||(i[a]=t[a]);return i}return _(t)&&(t=Se(e,t,r)),t}function Te(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]&&arguments[3];return _(Oe.returnValue)&&(t=Oe.returnValue(e,t)),Pe(e,t,n,{},r)}function Ee(t,n){if(k(Oe,t)){var r=Oe[t];return r?function(n,o){var i=r;_(r)&&(i=r(n)),n=Pe(t,n,i.args,i.returnValue);var a=[n];"undefined"!==typeof o&&a.push(o),_(i.name)?t=i.name(n):w(i.name)&&(t=i.name);var s=e[t].apply(e,a);return J(t)?Te(t,s,i.returnValue,W(t)):s}:function(){console.error("Platform '微信小程序' does not support '".concat(t,"'."))}}return n}var Ie=Object.create(null);["onTabBarMidButtonTap","subscribePush","unsubscribePush","onPush","offPush","share"].forEach((function(e){Ie[e]=function(e){return function(t){var n=t.fail,r=t.complete,o={errMsg:"".concat(e,":fail method '").concat(e,"' not supported")};_(n)&&n(o),_(r)&&r(o)}}(e)}));var je={oauth:["weixin"],share:["weixin"],payment:["wxpay"],push:["weixin"]};var Ce=Object.freeze({__proto__:null,getProvider:function(e){var t=e.service,n=e.success,r=e.fail,o=e.complete,i=!1;je[t]?(i={errMsg:"getProvider:ok",service:t,provider:je[t]},_(n)&&n(i)):(i={errMsg:"getProvider:fail service not found"},_(r)&&r(i)),_(o)&&o(i)}}),$e=function(){var e;return function(){return e||(e=new d.default),e}}();function Le(e,t,n){return e[t].apply(e,n)}var De,Me,Re,Ue=Object.freeze({__proto__:null,$on:function(){return Le($e(),"$on",Array.prototype.slice.call(arguments))},$off:function(){return Le($e(),"$off",Array.prototype.slice.call(arguments))},$once:function(){return Le($e(),"$once",Array.prototype.slice.call(arguments))},$emit:function(){return Le($e(),"$emit",Array.prototype.slice.call(arguments))}});function Ne(e){return function(){try{return e.apply(e,arguments)}catch(t){console.error(t)}}}function Fe(e){try{return JSON.parse(e)}catch(t){}return e}var Be=[];function qe(e,t){Be.forEach((function(n){n(e,t)})),Be.length=0}var Ve=[],He=e.getAppBaseInfo&&e.getAppBaseInfo();He||(He=e.getSystemInfoSync());var ze=He?He.host:null,Ke=ze&&"SAAASDK"===ze.env?e.miniapp.shareVideoMessage:e.shareVideoMessage,We=Object.freeze({__proto__:null,shareVideoMessage:Ke,getPushClientId:function(e){x(e)||(e={});var t=function(e){var t={};for(var n in e){var r=e[n];_(r)&&(t[n]=Ne(r),delete e[n])}return t}(e),n=t.success,r=t.fail,o=t.complete,i=_(n),a=_(r),s=_(o);Promise.resolve().then((function(){"undefined"===typeof Re&&(Re=!1,De="",Me="uniPush is not enabled"),Be.push((function(e,t){var u;e?(u={errMsg:"getPushClientId:ok",cid:e},i&&n(u)):(u={errMsg:"getPushClientId:fail"+(t?" "+t:"")},a&&r(u)),s&&o(u)})),"undefined"!==typeof De&&qe(De,Me)}))},onPushMessage:function(e){-1===Ve.indexOf(e)&&Ve.push(e)},offPushMessage:function(e){if(e){var t=Ve.indexOf(e);t>-1&&Ve.splice(t,1)}else Ve.length=0},invokePushCallback:function(e){if("enabled"===e.type)Re=!0;else if("clientId"===e.type)De=e.cid,Me=e.errMsg,qe(De,e.errMsg);else if("pushMsg"===e.type)for(var t={type:"receive",data:Fe(e.message)},n=0;n=0;i--){var a=o[i];if(a.$scope._$vueId===n)return a}for(var s=o.length-1;s>=0;s--)if(r=e(o[s],n),r)return r}(this.$vm,r)),t||(t=this.$vm),o.parent=t}function et(e){return Object.defineProperty(e,"__v_isMPComponent",{configurable:!0,enumerable:!1,value:!0}),e}function tt(e){return function(e){return null!==e&&"object"===(0,f.default)(e)}(e)&&Object.isExtensible(e)&&Object.defineProperty(e,"__ob__",{configurable:!0,enumerable:!1,value:(0,s.default)({},"__v_skip",!0)}),e}var nt=/_(.*)_worklet_factory_/;var rt=Page,ot=Component,it=/:/g,at=A((function(e){return P(e.replace(it,"-"))}));function st(e){var t=e.triggerEvent,n=function(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o0&&void 0!==arguments[0]?arguments[0]:{};return ut("onLoad",e),rt(e)},Page.after=rt.after,Component=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return ut("created",e),ot(e)});function ct(e,t,n){t.forEach((function(t){(function e(t,n){if(!n)return!0;if(d.default.options&&Array.isArray(d.default.options[t]))return!0;if(n=n.default||n,_(n))return!!_(n.extendOptions[t])||!!(n.super&&n.super.options&&Array.isArray(n.super.options[t]));if(_(n[t])||Array.isArray(n[t]))return!0;var r=n.mixins;return Array.isArray(r)?!!r.find((function(n){return e(t,n)})):void 0})(t,n)&&(e[t]=function(e){return this.$vm&&this.$vm.__call_hook(t,e)})}))}function ft(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[];lt(t).forEach((function(t){return dt(e,t,n)}))}function lt(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return e&&Object.keys(e).forEach((function(n){0===n.indexOf("on")&&_(e[n])&&t.push(n)})),t}function dt(e,t,n){-1!==n.indexOf(t)||k(e,t)||(e[t]=function(e){return this.$vm&&this.$vm.__call_hook(t,e)})}function ht(e,t){var n;return t=t.default||t,n=_(t)?t:e.extend(t),t=n.options,[n,t]}function pt(e,t){if(Array.isArray(t)&&t.length){var n=Object.create(null);t.forEach((function(e){n[e]=!0})),e.$scopedSlots=e.$slots=n}}function vt(e,t){e=(e||"").split(",");var n=e.length;1===n?t._$vueId=e[0]:2===n&&(t._$vueId=e[0],t._$vuePid=e[1])}function gt(e,t){var n=e.data||{},r=e.methods||{};if("function"===typeof n)try{n=n.call(t)}catch(o){Object({VUE_APP_DARK_MODE:"false",VUE_APP_NAME:"智慧云商协",VUE_APP_PLATFORM:"mp-weixin",NODE_ENV:"production",BASE_URL:"/"}).VUE_APP_DEBUG&&console.warn("根据 Vue 的 data 函数初始化小程序 data 失败,请尽量确保 data 函数中不访问 vm 对象,否则可能影响首次数据渲染速度。",n)}else try{n=JSON.parse(JSON.stringify(n))}catch(o){}return x(n)||(n={}),Object.keys(r).forEach((function(e){-1!==t.__lifecycle_hooks__.indexOf(e)||k(n,e)||(n[e]=r[e])})),n}var yt=[String,Number,Boolean,Object,Array,null];function bt(e){return function(t,n){this.$vm&&(this.$vm[e]=t)}}function mt(e,t){var n=e.behaviors,r=e.extends,o=e.mixins,i=e.props;i||(e.props=i=[]);var a=[];return Array.isArray(n)&&n.forEach((function(e){a.push(e.replace("uni://","wx".concat("://"))),"uni://form-field"===e&&(Array.isArray(i)?(i.push("name"),i.push("value")):(i.name={type:String,default:""},i.value={type:[String,Number,Boolean,Array,Object,Date],default:""}))})),x(r)&&r.props&&a.push(t({properties:wt(r.props,!0)})),Array.isArray(o)&&o.forEach((function(e){x(e)&&e.props&&a.push(t({properties:wt(e.props,!0)}))})),a}function _t(e,t,n,r){return Array.isArray(t)&&1===t.length?t[0]:t}function wt(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=arguments.length>3?arguments[3]:void 0,r={};return t||(r.vueId={type:String,value:""},n.virtualHost&&(r.virtualHostStyle={type:null,value:""},r.virtualHostClass={type:null,value:""}),r.scopedSlotsCompiler={type:String,value:""},r.vueSlots={type:null,value:[],observer:function(e,t){var n=Object.create(null);e.forEach((function(e){n[e]=!0})),this.setData({$slots:n})}}),Array.isArray(e)?e.forEach((function(e){r[e]={type:null,observer:bt(e)}})):x(e)&&Object.keys(e).forEach((function(t){var n=e[t];if(x(n)){var o=n.default;_(o)&&(o=o()),n.type=_t(0,n.type),r[t]={type:-1!==yt.indexOf(n.type)?n.type:null,value:o,observer:bt(t)}}else{var i=_t(0,n);r[t]={type:-1!==yt.indexOf(i)?i:null,observer:bt(t)}}})),r}function xt(e,t,n,r){var o={};return Array.isArray(t)&&t.length&&t.forEach((function(t,i){"string"===typeof t?t?"$event"===t?o["$"+i]=n:"arguments"===t?o["$"+i]=n.detail&&n.detail.__args__||r:0===t.indexOf("$event.")?o["$"+i]=e.__get_value(t.replace("$event.",""),n):o["$"+i]=e.__get_value(t):o["$"+i]=e:o["$"+i]=function(e,t){var n=e;return t.forEach((function(t){var r=t[0],o=t[2];if(r||"undefined"!==typeof o){var i,a=t[1],s=t[3];Number.isInteger(r)?i=r:r?"string"===typeof r&&r&&(i=0===r.indexOf("#s#")?r.substr(3):e.__get_value(r,n)):i=n,Number.isInteger(i)?n=o:a?Array.isArray(i)?n=i.find((function(t){return e.__get_value(a,t)===o})):x(i)?n=Object.keys(i).find((function(t){return e.__get_value(a,i[t])===o})):console.error("v-for 暂不支持循环数据:",i):n=i[o],s&&(n=e.__get_value(s,n))}})),n}(e,t)})),o}function kt(e){for(var t={},n=1;n2&&void 0!==arguments[2]?arguments[2]:[],r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:[],o=arguments.length>4?arguments[4]:void 0,i=arguments.length>5?arguments[5]:void 0,a=!1,s=x(t.detail)&&t.detail.__args__||[t.detail];if(o&&(a=t.currentTarget&&t.currentTarget.dataset&&"wx"===t.currentTarget.dataset.comType,!n.length))return a?[t]:s;var u=xt(e,r,t,s),c=[];return n.forEach((function(e){"$event"===e?"__set_model"!==i||o?o&&!a?c.push(s[0]):c.push(t):c.push(t.target.value):Array.isArray(e)&&"o"===e[0]?c.push(kt(e)):"string"===typeof e&&k(u,e)?c.push(u[e]):c.push(e)})),c}function At(e){var t=this;e=function(e){try{e.mp=JSON.parse(JSON.stringify(e))}catch(t){}return e.stopPropagation=O,e.preventDefault=O,e.target=e.target||{},k(e,"detail")||(e.detail={}),k(e,"markerId")&&(e.detail="object"===(0,f.default)(e.detail)?e.detail:{},e.detail.markerId=e.markerId),x(e.detail)&&(e.target=Object.assign({},e.target,e.detail)),e}(e);var n=(e.currentTarget||e.target).dataset;if(!n)return console.warn("事件信息不存在");var r=n.eventOpts||n["event-opts"];if(!r)return console.warn("事件信息不存在");var o=e.type,i=[];return r.forEach((function(n){var r=n[0],a=n[1],s="^"===r.charAt(0);r=s?r.slice(1):r;var u="~"===r.charAt(0);r=u?r.slice(1):r,a&&function(e,t){return e===t||"regionchange"===t&&("begin"===e||"end"===e)}(o,r)&&a.forEach((function(n){var r=n[0];if(r){var o=t.$vm;if(o.$options.generic&&(o=function(e){var t=e.$parent;while(t&&t.$parent&&(t.$options.generic||t.$parent.$options.generic||t.$scope._$vuePid))t=t.$parent;return t&&t.$parent}(o)||o),"$emit"===r)return void o.$emit.apply(o,Ot(t.$vm,e,n[1],n[2],s,r));var a=o[r];if(!_(a)){var c="page"===t.$vm.mpType?"Page":"Component",f=t.route||t.is;throw new Error("".concat(c,' "').concat(f,'" does not have a method "').concat(r,'"'))}if(u){if(a.once)return;a.once=!0}var l=Ot(t.$vm,e,n[1],n[2],s,r);l=Array.isArray(l)?l:[],/=\s*\S+\.eventParams\s*\|\|\s*\S+\[['"]event-params['"]\]/.test(a.toString())&&(l=l.concat([,,,,,,,,,,e])),i.push(a.apply(o,l))}}))})),"input"===o&&1===i.length&&"undefined"!==typeof i[0]?i[0]:void 0}var St={};var Pt=["onShow","onHide","onError","onPageNotFound","onThemeChange","onUnhandledRejection"];function Tt(){d.default.prototype.getOpenerEventChannel=function(){return this.$scope.getOpenerEventChannel()};var e=d.default.prototype.__call_hook;d.default.prototype.__call_hook=function(t,n){return"onLoad"===t&&n&&n.__id__&&(this.__eventChannel__=function(e){var t=St[e];return delete St[e],t}(n.__id__),delete n.__id__),e.call(this,t,n)}}function Et(t,n){var r=n.mocks,o=n.initRefs;Tt(),function(){var e={},t={};function n(e){var t=this.$options.propsData.vueId;if(t){var n=t.split(",")[0];e(n)}}d.default.prototype.$hasSSP=function(n){var r=e[n];return r||(t[n]=this,this.$on("hook:destroyed",(function(){delete t[n]}))),r},d.default.prototype.$getSSP=function(t,n,r){var o=e[t];if(o){var i=o[n]||[];return r?i:i[0]}},d.default.prototype.$setSSP=function(t,r){var o=0;return n.call(this,(function(n){var i=e[n],a=i[t]=i[t]||[];a.push(r),o=a.length-1})),o},d.default.prototype.$initSSP=function(){n.call(this,(function(t){e[t]={}}))},d.default.prototype.$callSSP=function(){n.call(this,(function(e){t[e]&&t[e].$forceUpdate()}))},d.default.mixin({destroyed:function(){var n=this.$options.propsData,r=n&&n.vueId;r&&(delete e[r],delete t[r])}})}(),t.$options.store&&(d.default.prototype.$store=t.$options.store),function(e){e.prototype.uniIDHasRole=function(e){var t=y(),n=t.role;return n.indexOf(e)>-1},e.prototype.uniIDHasPermission=function(e){var t=y(),n=t.permission;return this.uniIDHasRole("admin")||n.indexOf(e)>-1},e.prototype.uniIDTokenValid=function(){var e=y(),t=e.tokenExpired;return t>Date.now()}}(d.default),d.default.prototype.mpHost="mp-weixin",d.default.mixin({beforeCreate:function(){if(this.$options.mpType){if(this.mpType=this.$options.mpType,this.$mp=(0,s.default)({data:{}},this.mpType,this.$options.mpInstance),this.$scope=this.$options.mpInstance,delete this.$options.mpType,delete this.$options.mpInstance,"page"===this.mpType&&"function"===typeof getApp){var e=getApp();e.$vm&&e.$vm.$i18n&&(this._i18n=e.$vm.$i18n)}"app"!==this.mpType&&(o(this),function(e,t){var n=e.$mp[e.mpType];t.forEach((function(t){k(n,t)&&(e[t]=n[t])}))}(this,r))}}});var i={onLaunch:function(n){this.$vm||(e.canIUse&&!e.canIUse("nextTick")&&console.error("当前微信基础库版本过低,请将 微信开发者工具-详情-项目设置-调试基础库版本 更换为`2.3.0`以上"),this.$vm=t,this.$vm.$mp={app:this},this.$vm.$scope=this,this.$vm.globalData=this.globalData,this.$vm._isMounted=!0,this.$vm.__call_hook("mounted",n),this.$vm.__call_hook("onLaunch",n))}};i.globalData=t.$options.globalData||{};var a=t.$options.methods;return a&&Object.keys(a).forEach((function(e){i[e]=a[e]})),function(e,t,n){var r=e.observable({locale:n||re.getLocale()}),o=[];t.$watchLocale=function(e){o.push(e)},Object.defineProperty(t,"$locale",{get:function(){return r.locale},set:function(e){r.locale=e,o.forEach((function(t){return t(e)}))}})}(d.default,t,ie(e.getSystemInfoSync().language)||"en"),ct(i,Pt),ft(i,t.$options),i}function It(e){return Et(e,{mocks:Je,initRefs:Qe})}function jt(e){return App(It(e)),e}var Ct=/[!'()*]/g,$t=function(e){return"%"+e.charCodeAt(0).toString(16)},Lt=/%2C/g,Dt=function(e){return encodeURIComponent(e).replace(Ct,$t).replace(Lt,",")};function Mt(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Dt,n=e?Object.keys(e).map((function(n){var r=e[n];if(void 0===r)return"";if(null===r)return t(n);if(Array.isArray(r)){var o=[];return r.forEach((function(e){void 0!==e&&(null===e?o.push(t(n)):o.push(t(n)+"="+t(e)))})),o.join("&")}return t(n)+"="+t(r)})).filter((function(e){return e.length>0})).join("&"):null;return n?"?".concat(n):""}function Rt(e,t){return function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.isPage,r=t.initRelation,o=arguments.length>2?arguments[2]:void 0,i=ht(d.default,e),s=(0,a.default)(i,2),u=s[0],c=s[1],f=p({multipleSlots:!0,addGlobalClass:!0},c.options||{});c["mp-weixin"]&&c["mp-weixin"].options&&Object.assign(f,c["mp-weixin"].options);var l={options:f,data:gt(c,d.default.prototype),behaviors:mt(c,Ge),properties:wt(c.props,!1,c.__file,f),lifetimes:{attached:function(){var e=this.properties,t={mpType:n.call(this)?"page":"component",mpInstance:this,propsData:e};vt(e.vueId,this),r.call(this,{vuePid:this._$vuePid,vueOptions:t}),this.$vm=new u(t),pt(this.$vm,e.vueSlots),this.$vm.$mount()},ready:function(){this.$vm&&(this.$vm._isMounted=!0,this.$vm.__call_hook("mounted"),this.$vm.__call_hook("onReady"))},detached:function(){this.$vm&&this.$vm.$destroy()}},pageLifetimes:{show:function(e){this.$vm&&this.$vm.__call_hook("onPageShow",e)},hide:function(){this.$vm&&this.$vm.__call_hook("onPageHide")},resize:function(e){this.$vm&&this.$vm.__call_hook("onPageResize",e)}},methods:{__l:Xe,__e:At}};return c.externalClasses&&(l.externalClasses=c.externalClasses),Array.isArray(c.wxsCallMethods)&&c.wxsCallMethods.forEach((function(e){l.methods[e]=function(t){return this.$vm[e](t)}})),o?[l,c,u]:n?l:[l,u]}(e,{isPage:Ye,initRelation:Ze},t)}var Ut=["onShow","onHide","onUnload"];function Nt(e){var t=Rt(e,!0),n=(0,a.default)(t,2),r=n[0],o=n[1];return ct(r.methods,Ut,o),r.methods.onLoad=function(e){this.options=e;var t=Object.assign({},e);delete t.__id__,this.$page={fullPath:"/"+(this.route||this.is)+Mt(t)},this.$vm.$mp.query=e,this.$vm.__call_hook("onLoad",e)},ft(r.methods,e,["onReady"]),function(e,t){t&&Object.keys(t).forEach((function(n){var r=n.match(nt);if(r){var o=r[1];e[n]=t[n],e[o]=t[o]}}))}(r.methods,o.methods),r}function Ft(e){return Component(function(e){return Nt(e)}(e))}function Bt(e){return Component(Rt(e))}function qt(t){var n=It(t),r=getApp({allowDefault:!0});t.$scope=r;var o=r.globalData;if(o&&Object.keys(n.globalData).forEach((function(e){k(o,e)||(o[e]=n.globalData[e])})),Object.keys(n).forEach((function(e){k(r,e)||(r[e]=n[e])})),_(n.onShow)&&e.onAppShow&&e.onAppShow((function(){for(var e=arguments.length,n=new Array(e),r=0;re.length)&&(t=e.length);for(var n=0,r=new Array(t);n0&&void 0!==arguments[0]?arguments[0]:32,t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz".split(""),o=[];if(n=n||r.length,e)for(var i=0;i=0&&Math.floor(t)===t&&isFinite(e)}function l(e){return o(e)&&"function"===typeof e.then&&"function"===typeof e.catch}function d(e){return null==e?"":Array.isArray(e)||c(e)&&e.toString===u?JSON.stringify(e,null,2):String(e)}function h(e){var t=parseFloat(e);return isNaN(t)?e:t}function p(e,t){for(var n=Object.create(null),r=e.split(","),o=0;o-1)return e.splice(n,1)}}var y=Object.prototype.hasOwnProperty;function b(e,t){return y.call(e,t)}function m(e){var t=Object.create(null);return function(n){var r=t[n];return r||(t[n]=e(n))}}var _=/-(\w)/g,w=m((function(e){return e.replace(_,(function(e,t){return t?t.toUpperCase():""}))})),x=m((function(e){return e.charAt(0).toUpperCase()+e.slice(1)})),k=/\B([A-Z])/g,O=m((function(e){return e.replace(k,"-$1").toLowerCase()}));var A=Function.prototype.bind?function(e,t){return e.bind(t)}:function(e,t){function n(n){var r=arguments.length;return r?r>1?e.apply(t,arguments):e.call(t,n):e.call(t)}return n._length=e.length,n};function S(e,t){t=t||0;var n=e.length-t,r=new Array(n);while(n--)r[n]=e[n+t];return r}function P(e,t){for(var n in t)e[n]=t[n];return e}function T(e){for(var t={},n=0;n0),Y=(W&&W.indexOf("android"),W&&/iphone|ipad|ipod|ios/.test(W)||"ios"===K),Z=(W&&/chrome\/\d+/.test(W),W&&/phantomjs/.test(W),W&&W.match(/firefox\/(\d+)/),{}.watch);if(H)try{var Q={};Object.defineProperty(Q,"passive",{get:function(){}}),window.addEventListener("test-passive",null,Q)}catch(Rn){}var X=function(){return void 0===q&&(q=!H&&!z&&"undefined"!==typeof e&&(e["process"]&&"server"===e["process"].env.VUE_ENV)),q},ee=H&&window.__VUE_DEVTOOLS_GLOBAL_HOOK__;function te(e){return"function"===typeof e&&/native code/.test(e.toString())}var ne,re="undefined"!==typeof Symbol&&te(Symbol)&&"undefined"!==typeof Reflect&&te(Reflect.ownKeys);ne="undefined"!==typeof Set&&te(Set)?Set:function(){function e(){this.set=Object.create(null)}return e.prototype.has=function(e){return!0===this.set[e]},e.prototype.add=function(e){this.set[e]=!0},e.prototype.clear=function(){this.set=Object.create(null)},e}();var oe=E,ie=0,ae=function(){this.id=ie++,this.subs=[]};function se(e){ae.SharedObject.targetStack.push(e),ae.SharedObject.target=e,ae.target=e}function ue(){ae.SharedObject.targetStack.pop(),ae.SharedObject.target=ae.SharedObject.targetStack[ae.SharedObject.targetStack.length-1],ae.target=ae.SharedObject.target}ae.prototype.addSub=function(e){this.subs.push(e)},ae.prototype.removeSub=function(e){g(this.subs,e)},ae.prototype.depend=function(){ae.SharedObject.target&&ae.SharedObject.target.addDep(this)},ae.prototype.notify=function(){var e=this.subs.slice();for(var t=0,n=e.length;t-1)if(i&&!b(o,"default"))a=!1;else if(""===a||a===O(e)){var u=Me(String,o.type);(u<0||s0&&(u=e(u,(n||"")+"_"+s),rt(u[0])&&rt(f)&&(l[c]=de(f.text+u[0].text),u.shift()),l.push.apply(l,u)):a(u)?rt(f)?l[c]=de(f.text+u):""!==u&&l.push(de(u)):rt(u)&&rt(f)?l[c]=de(f.text+u.text):(i(t._isVList)&&o(u.tag)&&r(u.key)&&o(n)&&(u.key="__vlist"+n+"_"+s+"__"),l.push(u)));return l}(e):void 0}function rt(e){return o(e)&&o(e.text)&&function(e){return!1===e}(e.isComment)}function ot(e){var t=e.$options.provide;t&&(e._provided="function"===typeof t?t.call(e):t)}function it(e){var t=at(e.$options.inject,e);t&&(ye(!1),Object.keys(t).forEach((function(n){we(e,n,t[n])})),ye(!0))}function at(e,t){if(e){for(var n=Object.create(null),r=re?Reflect.ownKeys(e):Object.keys(e),o=0;o0,a=e?!!e.$stable:!i,s=e&&e.$key;if(e){if(e._normalized)return e._normalized;if(a&&r&&r!==n&&s===r.$key&&!i&&!r.$hasNormal)return r;for(var u in o={},e)e[u]&&"$"!==u[0]&&(o[u]=ft(t,u,e[u]))}else o={};for(var c in t)c in o||(o[c]=lt(t,c));return e&&Object.isExtensible(e)&&(e._normalized=o),F(o,"$stable",a),F(o,"$key",s),F(o,"$hasNormal",i),o}function ft(e,t,n){var r=function(){var e=arguments.length?n.apply(null,arguments):n({});return e=e&&"object"===typeof e&&!Array.isArray(e)?[e]:nt(e),e&&(0===e.length||1===e.length&&e[0].isComment)?void 0:e};return n.proxy&&Object.defineProperty(e,t,{get:r,enumerable:!0,configurable:!0}),r}function lt(e,t){return function(){return e[t]}}function dt(e,t){var n,r,i,a,u;if(Array.isArray(e)||"string"===typeof e)for(n=new Array(e.length),r=0,i=e.length;rdocument.createEvent("Event").timeStamp&&(Xt=function(){return en.now()})}function tn(){var e,t;for(Xt(),Zt=!0,Wt.sort((function(e,t){return e.id-t.id})),Qt=0;QtQt&&Wt[n].id>e.id)n--;Wt.splice(n+1,0,e)}else Wt.push(e);Yt||(Yt=!0,Ge(tn))}}(this)},rn.prototype.run=function(){if(this.active){var e=this.get();if(e!==this.value||s(e)||this.deep){var t=this.value;if(this.value=e,this.user)try{this.cb.call(this.vm,e,t)}catch(Rn){Re(Rn,this.vm,'callback for watcher "'+this.expression+'"')}else this.cb.call(this.vm,e,t)}}},rn.prototype.evaluate=function(){this.value=this.get(),this.dirty=!1},rn.prototype.depend=function(){var e=this.deps.length;while(e--)this.deps[e].depend()},rn.prototype.teardown=function(){if(this.active){this.vm._isBeingDestroyed||g(this.vm._watchers,this);var e=this.deps.length;while(e--)this.deps[e].removeSub(this);this.active=!1}};var on={enumerable:!0,configurable:!0,get:E,set:E};function an(e,t,n){on.get=function(){return this[t][n]},on.set=function(e){this[t][n]=e},Object.defineProperty(e,n,on)}function sn(e){e._watchers=[];var t=e.$options;t.props&&function(e,t){var n=e.$options.propsData||{},r=e._props={},o=e.$options._propKeys=[],i=!e.$parent;i||ye(!1);var a=function(i){o.push(i);var a=$e(i,t,n,e);we(r,i,a),i in e||an(e,"_props",i)};for(var s in t)a(s);ye(!0)}(e,t.props),t.methods&&function(e,t){e.$options.props;for(var n in t)e[n]="function"!==typeof t[n]?E:A(t[n],e)}(e,t.methods),t.data?function(e){var t=e.$options.data;t=e._data="function"===typeof t?function(e,t){se();try{return e.call(t,t)}catch(Rn){return Re(Rn,t,"data()"),{}}finally{ue()}}(t,e):t||{},c(t)||(t={});var n=Object.keys(t),r=e.$options.props,o=(e.$options.methods,n.length);while(o--){var i=n[o];0,r&&b(r,i)||N(i)||an(e,"_data",i)}_e(t,!0)}(e):_e(e._data={},!0),t.computed&&function(e,t){var n=e._computedWatchers=Object.create(null),r=X();for(var o in t){var i=t[o],a="function"===typeof i?i:i.get;0,r||(n[o]=new rn(e,a||E,E,un)),o in e||cn(e,o,i)}}(e,t.computed),t.watch&&t.watch!==Z&&function(e,t){for(var n in t){var r=t[n];if(Array.isArray(r))for(var o=0;o-1:"string"===typeof e?e.split(",").indexOf(t)>-1:!!function(e){return"[object RegExp]"===u.call(e)}(e)&&e.test(t)}function mn(e,t){var n=e.cache,r=e.keys,o=e._vnode;for(var i in n){var a=n[i];if(a){var s=yn(a.componentOptions);s&&!t(s)&&_n(n,i,r,o)}}}function _n(e,t,n,r){var o=e[t];!o||r&&o.tag===r.tag||o.componentInstance.$destroy(),e[t]=null,g(n,t)}(function(e){e.prototype._init=function(e){var t=this;t._uid=hn++,t._isVue=!0,e&&e._isComponent?function(e,t){var n=e.$options=Object.create(e.constructor.options),r=t._parentVnode;n.parent=t.parent,n._parentVnode=r;var o=r.componentOptions;n.propsData=o.propsData,n._parentListeners=o.listeners,n._renderChildren=o.children,n._componentTag=o.tag,t.render&&(n.render=t.render,n.staticRenderFns=t.staticRenderFns)}(t,e):t.$options=je(pn(t.constructor),e||{},t),t._renderProxy=t,t._self=t,function(e){var t=e.$options,n=t.parent;if(n&&!t.abstract){while(n.$options.abstract&&n.$parent)n=n.$parent;n.$children.push(e)}e.$parent=n,e.$root=n?n.$root:e,e.$children=[],e.$refs={},e._watcher=null,e._inactive=null,e._directInactive=!1,e._isMounted=!1,e._isDestroyed=!1,e._isBeingDestroyed=!1}(t),function(e){e._events=Object.create(null),e._hasHookEvent=!1;var t=e.$options._parentListeners;t&&qt(e,t)}(t),function(e){e._vnode=null,e._staticTrees=null;var t=e.$options,r=e.$vnode=t._parentVnode,o=r&&r.context;e.$slots=st(t._renderChildren,o),e.$scopedSlots=n,e._c=function(t,n,r,o){return Lt(e,t,n,r,o,!1)},e.$createElement=function(t,n,r,o){return Lt(e,t,n,r,o,!0)};var i=r&&r.data;we(e,"$attrs",i&&i.attrs||n,null,!0),we(e,"$listeners",t._parentListeners||n,null,!0)}(t),Kt(t,"beforeCreate"),!t._$fallback&&it(t),sn(t),!t._$fallback&&ot(t),!t._$fallback&&Kt(t,"created"),t.$options.el&&t.$mount(t.$options.el)}})(vn),function(e){var t={get:function(){return this._data}},n={get:function(){return this._props}};Object.defineProperty(e.prototype,"$data",t),Object.defineProperty(e.prototype,"$props",n),e.prototype.$set=xe,e.prototype.$delete=ke,e.prototype.$watch=function(e,t,n){if(c(t))return dn(this,e,t,n);n=n||{},n.user=!0;var r=new rn(this,e,t,n);if(n.immediate)try{t.call(this,r.value)}catch(o){Re(o,this,'callback for immediate watcher "'+r.expression+'"')}return function(){r.teardown()}}}(vn),function(e){var t=/^hook:/;e.prototype.$on=function(e,n){var r=this;if(Array.isArray(e))for(var o=0,i=e.length;o1?S(n):n;for(var r=S(arguments,1),o='event handler for "'+e+'"',i=0,a=n.length;iparseInt(this.max)&&_n(s,u[0],u,this._vnode)),t.data.keepAlive=!0}return t||e&&e[0]}},kn={KeepAlive:xn};(function(e){var t={get:function(){return R}};Object.defineProperty(e,"config",t),e.util={warn:oe,extend:P,mergeOptions:je,defineReactive:we},e.set=xe,e.delete=ke,e.nextTick=Ge,e.observable=function(e){return _e(e),e},e.options=Object.create(null),D.forEach((function(t){e.options[t+"s"]=Object.create(null)})),e.options._base=e,P(e.options.components,kn),function(e){e.use=function(e){var t=this._installedPlugins||(this._installedPlugins=[]);if(t.indexOf(e)>-1)return this;var n=S(arguments,1);return n.unshift(this),"function"===typeof e.install?e.install.apply(e,n):"function"===typeof e&&e.apply(null,n),t.push(e),this}}(e),function(e){e.mixin=function(e){return this.options=je(this.options,e),this}}(e),gn(e),function(e){D.forEach((function(t){e[t]=function(e,n){return n?("component"===t&&c(n)&&(n.name=n.name||e,n=this.options._base.extend(n)),"directive"===t&&"function"===typeof n&&(n={bind:n,update:n}),this.options[t+"s"][e]=n,n):this.options[t+"s"][e]}}))}(e)})(vn),Object.defineProperty(vn.prototype,"$isServer",{get:X}),Object.defineProperty(vn.prototype,"$ssrContext",{get:function(){return this.$vnode&&this.$vnode.ssrContext}}),Object.defineProperty(vn,"FunctionalRenderContext",{value:Pt}),vn.version="2.6.11";var On="[object Array]",An="[object Object]";function Sn(e,t){var n={};return function e(t,n){if(t===n)return;var r=Tn(t),o=Tn(n);if(r==An&&o==An){if(Object.keys(t).length>=Object.keys(n).length)for(var i in n){var a=t[i];void 0===a?t[i]=null:e(a,n[i])}}else r==On&&o==On&&t.length>=n.length&&n.forEach((function(n,r){e(t[r],n)}))}(e,t),function e(t,n,r,o){if(t===n)return;var i=Tn(t),a=Tn(n);if(i==An)if(a!=An||Object.keys(t).length1&&(t[r[0].trim()]=r[1].trim())}})),t}));var Dn=["createSelectorQuery","createIntersectionObserver","selectAllComponents","selectComponent"];var Mn=["onLaunch","onShow","onHide","onUniNViewMessage","onPageNotFound","onThemeChange","onError","onUnhandledRejection","onInit","onLoad","onReady","onUnload","onPullDownRefresh","onReachBottom","onTabItemTap","onAddToFavorites","onShareTimeline","onShareAppMessage","onResize","onPageScroll","onNavigationBarButtonTap","onBackPress","onNavigationBarSearchInputChanged","onNavigationBarSearchInputConfirmed","onNavigationBarSearchInputClicked","onUploadDouyinVideo","onNFCReadMessage","onPageShow","onPageHide","onPageResize"];vn.prototype.__patch__=function(e,t){var n=this;if(null!==t&&("page"===this.mpType||"component"===this.mpType)){var r=this.$scope,o=Object.create(null);try{o=function(e){var t=Object.create(null),n=[].concat(Object.keys(e._data||{}),Object.keys(e._computedWatchers||{}));n.reduce((function(t,n){return t[n]=e[n],t}),t);var r=e.__composition_api_state__||e.__secret_vfa_state__,o=r&&r.rawBindings;return o&&Object.keys(o).forEach((function(n){t[n]=e[n]})),Object.assign(t,e.$mp.data||{}),Array.isArray(e.$options.behaviors)&&-1!==e.$options.behaviors.indexOf("uni://form-field")&&(t["name"]=e.name,t["value"]=e.value),JSON.parse(JSON.stringify(t,jn))}(this)}catch(s){console.error(s)}o.__webviewId__=r.data.__webviewId__;var i=Object.create(null);Object.keys(o).forEach((function(e){i[e]=r.data[e]}));var a=!1===this.$shouldDiffData?o:Sn(o,i);Object.keys(a).length?(Object({VUE_APP_DARK_MODE:"false",VUE_APP_NAME:"智慧云商协",VUE_APP_PLATFORM:"mp-weixin",NODE_ENV:"production",BASE_URL:"/"}).VUE_APP_DEBUG&&console.log("["+ +new Date+"]["+(r.is||r.route)+"]["+this._uid+"]差量更新",JSON.stringify(a)),this.__next_tick_pending=!0,r.setData(a,(function(){n.__next_tick_pending=!1,En(n)}))):En(this)}},vn.prototype.$mount=function(e,t){return function(e,t,n){return e.mpType?("app"===e.mpType&&(e.$options.render=Cn),e.$options.render||(e.$options.render=Cn),!e._$fallback&&Kt(e,"beforeMount"),new rn(e,(function(){e._update(e._render(),n)}),E,{before:function(){e._isMounted&&!e._isDestroyed&&Kt(e,"beforeUpdate")}},!0),n=!1,e):e}(this,0,t)},function(e){var t=e.extend;e.extend=function(e){e=e||{};var n=e.methods;return n&&Object.keys(n).forEach((function(t){-1!==Mn.indexOf(t)&&(e[t]=n[t],delete n[t])})),t.call(this,e)};var n=e.config.optionMergeStrategies,r=n.created;Mn.forEach((function(e){n[e]=r})),e.prototype.__lifecycle_hooks__=Mn}(vn),function(e){e.config.errorHandler=function(t,n,r){e.util.warn("Error in "+r+': "'+t.toString()+'"',n),console.error(t);var o="function"===typeof getApp&&getApp();o&&o.onError&&o.onError(t)};var t=e.prototype.$emit;e.prototype.$emit=function(e){if(this.$scope&&e){var n=this.$scope["_triggerEvent"]||this.$scope["triggerEvent"];if(n)try{n.call(this.$scope,e,{__args__:S(arguments,1)})}catch(r){}}return t.apply(this,arguments)},e.prototype.$nextTick=function(e){return In(this,e)},Dn.forEach((function(t){e.prototype[t]=function(e){return this.$scope&&this.$scope[t]?this.$scope[t](e):"undefined"!==typeof my?"createSelectorQuery"===t?my.createSelectorQuery(e):"createIntersectionObserver"===t?my.createIntersectionObserver(e):void 0:void 0}})),e.prototype.__init_provide=ot,e.prototype.__init_injections=it,e.prototype.__call_hook=function(e,t){var n=this;se();var r,o=n.$options[e],i=e+" hook";if(o)for(var a=0,s=o.length;a1&&void 0!==arguments[1]?arguments[1]:{},n=t.method||e.method||"GET",r={baseURL:e.baseURL||"",method:n,url:t.url||"",params:t.params||{},custom:s(s({},e.custom||{}),t.custom||{}),header:(0,i.deepMerge)(e.header||{},t.header||{})},o=["getTask","validateStatus"];if(r=s(s({},r),u(o,e,t)),"DOWNLOAD"===n);else if("UPLOAD"===n){delete r.header["content-type"],delete r.header["Content-Type"];var a=["filePath","name","formData"];a.forEach((function(e){(0,i.isUndefined)(t[e])||(r[e]=t[e])}))}else{var c=["data","timeout","dataType","responseType"];r=s(s({},r),u(c,e,t))}return r}},"6b58":function(e,t,n){var r=n("7037")["default"],o=n("3c96");e.exports=function(e,t){if(t&&("object"===r(t)||"function"===typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return o(e)},e.exports.__esModule=!0,e.exports["default"]=e.exports},"6e37":function(e,t,n){"use strict";var r=n("4ea4");Object.defineProperty(t,"__esModule",{value:!0}),t.deepMerge=function e(){var t={};function n(n,r){"object"===(0,o.default)(t[r])&&"object"===(0,o.default)(n)?t[r]=e(t[r],n):"object"===(0,o.default)(n)?t[r]=e({},n):t[r]=n}for(var r=0,i=arguments.length;r=0;--o){var i=this.tryEntries[o],s=i.completion;if("root"===i.tryLoc)return r("end");if(i.tryLoc<=this.prev){var u=a.call(i,"catchLoc"),c=a.call(i,"finallyLoc");if(u&&c){if(this.prev=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&a.call(r,"finallyLoc")&&this.prev=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),j(n),b}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;j(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,n,r){return this.delegate={iterator:$(e),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=t),b}},n}e.exports=o,e.exports.__esModule=!0,e.exports["default"]=e.exports},"8ab9":function(e,t,n){"use strict";var r=n("4ea4");r(n("de98"))},9152:function(e,t){ /*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh */ t.read=function(e,t,n,r,o){var i,a,s=8*o-r-1,u=(1<>1,f=-7,l=n?o-1:0,d=n?-1:1,h=e[t+l];for(l+=d,i=h&(1<<-f)-1,h>>=-f,f+=s;f>0;i=256*i+e[t+l],l+=d,f-=8);for(a=i&(1<<-f)-1,i>>=-f,f+=r;f>0;a=256*a+e[t+l],l+=d,f-=8);if(0===i)i=1-c;else{if(i===u)return a?NaN:1/0*(h?-1:1);a+=Math.pow(2,r),i-=c}return(h?-1:1)*a*Math.pow(2,i-r)},t.write=function(e,t,n,r,o,i){var a,s,u,c=8*i-o-1,f=(1<>1,d=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,h=r?0:i-1,p=r?1:-1,v=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=f):(a=Math.floor(Math.log(t)/Math.LN2),t*(u=Math.pow(2,-a))<1&&(a--,u*=2),t+=a+l>=1?d/u:d*Math.pow(2,1-l),t*u>=2&&(a++,u/=2),a+l>=f?(s=0,a=f):a+l>=1?(s=(t*u-1)*Math.pow(2,o),a+=l):(s=t*Math.pow(2,l-1)*Math.pow(2,o),a=0));o>=8;e[n+h]=255&s,h+=p,s/=256,o-=8);for(a=a<0;e[n+h]=255&a,h+=p,a/=256,c-=8);e[n+h-p]|=128*v}},9480:function(e,t,n){"use strict";function r(e,t,n){this.$children.map((function(o){e===o.$options.name?o.$emit.apply(o,[t].concat(n)):r.apply(o,[e,t].concat(n))}))}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o={methods:{dispatch:function(e,t,n){var r=this.$parent||this.$root,o=r.$options.name;while(r&&(!o||o!==e))r=r.$parent,r&&(o=r.$options.name);r&&r.$emit.apply(r,[t].concat(n))},broadcast:function(e,t,n){r.call(this,e,t,n)}}};t.default=o},9523:function(e,t,n){var r=n("a395");e.exports=function(e,t,n){return t=r(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e},e.exports.__esModule=!0,e.exports["default"]=e.exports},"970b":function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},e.exports.__esModule=!0,e.exports["default"]=e.exports},9892:function(e,t,n){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n={toast:function(t){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"none",i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:1500;e.showToast({title:t,icon:o,mask:n,duration:i,success:function(){setTimeout((function(){r&&r()}),i)}})},loading:function(t){e.showLoading({title:t,mask:!0})},modal:function(t,n,r){var o=arguments.length>3&&void 0!==arguments[3]&&arguments[3],i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null,a=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"确定",s=arguments.length>6&&void 0!==arguments[6]?arguments[6]:"取消";e.showModal({title:t,content:n,showCancel:o,cancelText:s,confirmText:a,success:function(e){e.cancel?i&&i():e.confirm&&r&&r()}})},closeToast:function(){e.hideToast()},closeLoading:function(){e.hideLoading()}};t.default=n}).call(this,n("543d")["default"])},"9b42":function(e,t){e.exports=function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,s=[],u=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);u=!0);}catch(e){c=!0,o=e}finally{try{if(!u&&null!=n["return"]&&(a=n["return"](),Object(a)!==a))return}finally{if(c)throw o}}return s}},e.exports.__esModule=!0,e.exports["default"]=e.exports},"9c66":function(e,t,n){"use strict";(function(e){var r=n("4ea4");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=r(n("7037"));function i(){return i=Object.assign||function(e){for(var t=1;t=i)return e;switch(e){case"%s":return String(t[r++]);case"%d":return Number(t[r++]);case"%j":try{return JSON.stringify(t[r++])}catch(n){return"[Circular]"}break;default:return e}})),u=t[r];r()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/,url:new RegExp("^(?!mailto:)(?:(?:http|https|ftp)://|//)(?:\\S+(?::\\S*)?@)?(?:(?:(?:[1-9]\\d?|1\\d\\d|2[01]\\d|22[0-3])(?:\\.(?:1?\\d{1,2}|2[0-4]\\d|25[0-5])){2}(?:\\.(?:[0-9]\\d?|1\\d\\d|2[0-4]\\d|25[0-4]))|(?:(?:[a-z\\u00a1-\\uffff0-9]+-*)*[a-z\\u00a1-\\uffff0-9]+)(?:\\.(?:[a-z\\u00a1-\\uffff0-9]+-*)*[a-z\\u00a1-\\uffff0-9]+)*(?:\\.(?:[a-z\\u00a1-\\uffff]{2,})))|localhost)(?::\\d{2,5})?(?:(/|\\?|#)[^\\s]*)?$","i"),hex:/^#?([a-f0-9]{6}|[a-f0-9]{3})$/i},y={integer:function(e){return y.number(e)&&parseInt(e,10)===e},float:function(e){return y.number(e)&&!y.integer(e)},array:function(e){return Array.isArray(e)},regexp:function(e){if(e instanceof RegExp)return!0;try{return!!new RegExp(e)}catch(t){return!1}},date:function(e){return"function"===typeof e.getTime&&"function"===typeof e.getMonth&&"function"===typeof e.getYear},number:function(e){return!isNaN(e)&&"number"===typeof+e},object:function(e){return"object"===(0,o.default)(e)&&!y.array(e)},method:function(e){return"function"===typeof e},email:function(e){return"string"===typeof e&&!!e.match(g.email)&&e.length<255},url:function(e){return"string"===typeof e&&!!e.match(g.url)},hex:function(e){return"string"===typeof e&&!!e.match(g.hex)}};var b={required:v,whitespace:function(e,t,n,r,o){(/^\s+$/.test(t)||""===t)&&r.push(c(o.messages.whitespace,e.fullField))},type:function(e,t,n,r,i){if(e.required&&void 0===t)v(e,t,n,r,i);else{var a=e.type;["integer","float","array","regexp","object","method","email","number","date","url","hex"].indexOf(a)>-1?y[a](t)||r.push(c(i.messages.types[a],e.fullField,e.type)):a&&(0,o.default)(t)!==e.type&&r.push(c(i.messages.types[a],e.fullField,e.type))}},range:function(e,t,n,r,o){var i="number"===typeof e.len,a="number"===typeof e.min,s="number"===typeof e.max,u=t,f=null,l="number"===typeof t,d="string"===typeof t,h=Array.isArray(t);if(l?f="number":d?f="string":h&&(f="array"),!f)return!1;h&&(u=t.length),d&&(u=t.replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,"_").length),i?u!==e.len&&r.push(c(o.messages[f].len,e.fullField,e.len)):a&&!s&&ue.max?r.push(c(o.messages[f].max,e.fullField,e.max)):a&&s&&(ue.max)&&r.push(c(o.messages[f].range,e.fullField,e.min,e.max))},enum:function(e,t,n,r,o){e["enum"]=Array.isArray(e["enum"])?e["enum"]:[],-1===e["enum"].indexOf(t)&&r.push(c(o.messages["enum"],e.fullField,e["enum"].join(", ")))},pattern:function(e,t,n,r,o){if(e.pattern)if(e.pattern instanceof RegExp)e.pattern.lastIndex=0,e.pattern.test(t)||r.push(c(o.messages.pattern.mismatch,e.fullField,t,e.pattern));else if("string"===typeof e.pattern){var i=new RegExp(e.pattern);i.test(t)||r.push(c(o.messages.pattern.mismatch,e.fullField,t,e.pattern))}}};function m(e,t,n,r,o){var i=e.type,a=[],s=e.required||!e.required&&r.hasOwnProperty(e.field);if(s){if(f(t,i)&&!e.required)return n();b.required(e,t,r,a,o,i),f(t,i)||b.type(e,t,r,a,o)}n(a)}var _={string:function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(f(t,"string")&&!e.required)return n();b.required(e,t,r,i,o,"string"),f(t,"string")||(b.type(e,t,r,i,o),b.range(e,t,r,i,o),b.pattern(e,t,r,i,o),!0===e.whitespace&&b.whitespace(e,t,r,i,o))}n(i)},method:function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(f(t)&&!e.required)return n();b.required(e,t,r,i,o),void 0!==t&&b.type(e,t,r,i,o)}n(i)},number:function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(""===t&&(t=void 0),f(t)&&!e.required)return n();b.required(e,t,r,i,o),void 0!==t&&(b.type(e,t,r,i,o),b.range(e,t,r,i,o))}n(i)},boolean:function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(f(t)&&!e.required)return n();b.required(e,t,r,i,o),void 0!==t&&b.type(e,t,r,i,o)}n(i)},regexp:function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(f(t)&&!e.required)return n();b.required(e,t,r,i,o),f(t)||b.type(e,t,r,i,o)}n(i)},integer:function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(f(t)&&!e.required)return n();b.required(e,t,r,i,o),void 0!==t&&(b.type(e,t,r,i,o),b.range(e,t,r,i,o))}n(i)},float:function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(f(t)&&!e.required)return n();b.required(e,t,r,i,o),void 0!==t&&(b.type(e,t,r,i,o),b.range(e,t,r,i,o))}n(i)},array:function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(f(t,"array")&&!e.required)return n();b.required(e,t,r,i,o,"array"),f(t,"array")||(b.type(e,t,r,i,o),b.range(e,t,r,i,o))}n(i)},object:function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(f(t)&&!e.required)return n();b.required(e,t,r,i,o),void 0!==t&&b.type(e,t,r,i,o)}n(i)},enum:function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(f(t)&&!e.required)return n();b.required(e,t,r,i,o),void 0!==t&&b["enum"](e,t,r,i,o)}n(i)},pattern:function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(f(t,"string")&&!e.required)return n();b.required(e,t,r,i,o),f(t,"string")||b.pattern(e,t,r,i,o)}n(i)},date:function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(f(t)&&!e.required)return n();var s;if(b.required(e,t,r,i,o),!f(t))s="number"===typeof t?new Date(t):t,b.type(e,s,r,i,o),s&&b.range(e,s.getTime(),r,i,o)}n(i)},url:m,hex:m,email:m,required:function(e,t,n,r,i){var a=[],s=Array.isArray(t)?"array":(0,o.default)(t);b.required(e,t,r,a,i,s),n(a)},any:function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(f(t)&&!e.required)return n();b.required(e,t,r,i,o)}n(i)}};function w(){return{default:"Validation error on field %s",required:"%s is required",enum:"%s must be one of %s",whitespace:"%s cannot be empty",date:{format:"%s date %s is invalid for format %s",parse:"%s date could not be parsed, %s is invalid ",invalid:"%s date %s is invalid"},types:{string:"%s is not a %s",method:"%s is not a %s (function)",array:"%s is not an %s",object:"%s is not an %s",number:"%s is not a %s",date:"%s is not a %s",boolean:"%s is not a %s",integer:"%s is not an %s",float:"%s is not a %s",regexp:"%s is not a valid %s",email:"%s is not a valid %s",url:"%s is not a valid %s",hex:"%s is not a valid %s"},string:{len:"%s must be exactly %s characters",min:"%s must be at least %s characters",max:"%s cannot be longer than %s characters",range:"%s must be between %s and %s characters"},number:{len:"%s must equal %s",min:"%s cannot be less than %s",max:"%s cannot be greater than %s",range:"%s must be between %s and %s"},array:{len:"%s must be exactly %s in length",min:"%s cannot be less than %s in length",max:"%s cannot be greater than %s in length",range:"%s must be between %s and %s in length"},pattern:{mismatch:"%s value %s does not match pattern %s"},clone:function(){var e=JSON.parse(JSON.stringify(this));return e.clone=this.clone,e}}}var x=w();function k(e){this.rules=null,this._messages=x,this.define(e)}k.prototype={messages:function(e){return e&&(this._messages=p(w(),e)),this._messages},define:function(e){if(!e)throw new Error("Cannot configure a schema with no rules");if("object"!==(0,o.default)(e)||Array.isArray(e))throw new Error("Rules must be an object");var t,n;for(t in this.rules={},e)e.hasOwnProperty(t)&&(n=e[t],this.rules[t]=Array.isArray(n)?n:[n])},validate:function(e,t,n){var r=this;void 0===t&&(t={}),void 0===n&&(n=function(){});var a,s,f=e,l=t,v=n;if("function"===typeof l&&(v=l,l={}),!this.rules||0===Object.keys(this.rules).length)return v&&v(),Promise.resolve();if(l.messages){var g=this.messages();g===x&&(g=w()),p(g,l.messages),l.messages=g}else l.messages=this.messages();var y={},b=l.keys||Object.keys(this.rules);b.forEach((function(t){a=r.rules[t],s=f[t],a.forEach((function(n){var o=n;"function"===typeof o.transform&&(f===e&&(f=i({},f)),s=f[t]=o.transform(s)),o="function"===typeof o?{validator:o}:i({},o),o.validator=r.getValidationMethod(o),o.field=t,o.fullField=o.fullField||t,o.type=r.getType(o),o.validator&&(y[t]=y[t]||[],y[t].push({rule:o,value:s,source:f,field:t}))}))}));var m={};return d(y,l,(function(e,t){var n,r=e.rule,a=("object"===r.type||"array"===r.type)&&("object"===(0,o.default)(r.fields)||"object"===(0,o.default)(r.defaultField));function s(e,t){return i({},t,{fullField:r.fullField+"."+e})}function u(n){void 0===n&&(n=[]);var o=n;if(Array.isArray(o)||(o=[o]),!l.suppressWarning&&o.length&&k.warning("async-validator:",o),o.length&&r.message&&(o=[].concat(r.message)),o=o.map(h(r)),l.first&&o.length)return m[r.field]=1,t(o);if(a){if(r.required&&!e.value)return o=r.message?[].concat(r.message).map(h(r)):l.error?[l.error(r,c(l.messages.required,r.field))]:[],t(o);var u={};if(r.defaultField)for(var f in e.value)e.value.hasOwnProperty(f)&&(u[f]=r.defaultField);for(var d in u=i({},u,{},e.rule.fields),u)if(u.hasOwnProperty(d)){var p=Array.isArray(u[d])?u[d]:[u[d]];u[d]=p.map(s.bind(null,d))}var v=new k(u);v.messages(l.messages),e.rule.options&&(e.rule.options.messages=l.messages,e.rule.options.error=l.error),v.validate(e.value,e.rule.options||l,(function(e){var n=[];o&&o.length&&n.push.apply(n,o),e&&e.length&&n.push.apply(n,e),t(n.length?n:null)}))}else t(o)}a=a&&(r.required||!r.required&&e.value),r.field=e.field,r.asyncValidator?n=r.asyncValidator(r,e.value,u,e.source,l):r.validator&&(n=r.validator(r,e.value,u,e.source,l),!0===n?u():!1===n?u(r.message||r.field+" fails"):n instanceof Array?u(n):n instanceof Error&&u(n.message)),n&&n.then&&n.then((function(){return u()}),(function(e){return u(e)}))}),(function(e){(function(e){var t,n=[],r={};function o(e){var t;Array.isArray(e)?n=(t=n).concat.apply(t,e):n.push(e)}for(t=0;t=0},range:function(e,t){return e>=t[0]&&e<=t[1]},rangeLength:function(e,t){return e.length>=t[0]&&e.length<=t[1]},empty:i,isEmpty:i,jsonString:function(e){if("string"==typeof e)try{var t=JSON.parse(e);return!("object"!=(0,o.default)(t)||!t)}catch(n){return!1}return!1},landline:function(e){return/^\d{3,4}-\d{7,8}(-\d{3,4})?$/.test(e)},object:function(e){return"[object Object]"===Object.prototype.toString.call(e)},array:function(e){return"function"===typeof Array.isArray?Array.isArray(e):"[object Array]"===Object.prototype.toString.call(e)},code:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:6;return new RegExp("^\\d{".concat(t,"}$")).test(e)}};t.default=a},a128:function(e,t,n){var r=n("36c6"),o=n("4a4b"),i=n("c5f7"),a=n("b17c");function s(t){var n="function"===typeof Map?new Map:void 0;return e.exports=s=function(e){if(null===e||!i(e))return e;if("function"!==typeof e)throw new TypeError("Super expression must either be null or a function");if("undefined"!==typeof n){if(n.has(e))return n.get(e);n.set(e,t)}function t(){return a(e,arguments,r(this).constructor)}return t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),o(t,e)},e.exports.__esModule=!0,e.exports["default"]=e.exports,s(t)}e.exports=s,e.exports.__esModule=!0,e.exports["default"]=e.exports},a230:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=["red","purplered","purple","bluepurple","aquablue","blue","indigo","cyan","teal","green","yellowgreen","lime","yellow","orangeyellow","orange","orangered","brown","grey","gray"];function o(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=/^#([0-9a-fA-F]{3}|[0-9a-fA-F]{6})$/;if(e=e.toLowerCase(),e&&n.test(e)){if(4===e.length){for(var r="#",o=1;o<4;o++)r+=e.slice(o,o+1).concat(e.slice(o,o+1));e=r}for(var i=[],a=1;a<7;a+=2)i.push(parseInt("0x"+e.slice(a,a+2)));return t?"rgb(".concat(i[0],", ").concat(i[1],", ").concat(i[2],")"):i}if(/^(rgb|RGB)/.test(e)){var s=e.replace(/(?:\(|\)|rgb|RGB)*/g,"").split(",");return s.map((function(e){return Number(e)}))}return e}function i(e){if(/^(rgb|RGB)/.test(e)){for(var t=e.replace(/(?:\(|\)|rgb|GRB)*/g,"").split(","),n="#",r=0;r0&&void 0!==arguments[0]?arguments[0]:"bg",t=Math.floor(Math.random()*r.length),n=r[t];return"tn-"+e+"-"+n},getRandomCoolBgClass:function(){var e=16*Math.random()+1;return"tn-cool-bg-color-"+Math.floor(e)},getBackgroundColorInternalClass:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return e&&["tn-bg","tn-dynamic-bg","tn-main-gradient","tn-cool-bg"].some((function(t){return e.includes(t)}))?e:""},getBackgroundColorStyle:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return e&&(!e.startsWith("tn-")||["#","rgb","rgba"].some((function(t){return e.includes(t)})))?e:""},getFontColorInternalClass:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return e&&["tn-color"].some((function(t){return e.includes(t)}))?e:""},getFontColorStyle:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return e&&(!e.startsWith("tn-")||["#","rgb","rgba"].some((function(t){return e.includes(t)})))?e:""},colorGradient:function(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"rgb(0, 0, 0)",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"rgb(255, 255, 255)",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:10,r=o(e,!1),a=r[0],s=r[1],u=r[2],c=o(t,!1),f=c[0],l=c[1],d=c[2],h=(f-a)/n,p=(l-s)/n,v=(d-u)/n,g=[],y=0;y1&&void 0!==arguments[1]?arguments[1]:.3;e=i(e);var n=/^#([0-9a-fA-F]{3}|[0-9a-fA-F]{6})$/;if(e=e.toLowerCase(),e&&n.test(e)){if(4===e.length){for(var r="#",o=1;o<4;o++)r+=e.slice(o,o+1).concat(e.slice(o,o+1));e=r}for(var a=[],s=1;s<7;s+=2)a.push(parseInt("0x"+e.slice(s,s+2)));return"rgba(".concat(a[0],", ").concat(a[1],", ").concat(a[2],", ").concat(t,")")}return e}};t.default=a},a294:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default={baseURL:"",header:{},method:"GET",dataType:"json",responseType:"text",custom:{},timeout:6e4,validateStatus:function(e){return e>=200&&e<300}}},a395:function(e,t,n){var r=n("7037")["default"],o=n("e50d");e.exports=function(e){var t=o(e,"string");return"symbol"==r(t)?t:String(t)},e.exports.__esModule=!0,e.exports["default"]=e.exports},a3f2:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default={appid:"__UNI__F702B81"}},a9ff:function(e,t,n){"use strict";(function(e,r,o){var i=n("4ea4");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var a=i(n("2eee")),s=i(n("3c96")),u=i(n("278c")),c=i(n("7037")),f=i(n("448a")),l=i(n("c973")),d=i(n("9523")),h=i(n("ed6d")),p=i(n("6b58")),v=i(n("36c6")),g=i(n("a128")),y=i(n("970b")),b=i(n("5bc3")),m=i(n("6602"));function _(e,t){var n="undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"===typeof e)return w(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return w(e,t)}(e))||t&&e&&"number"===typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){s=!0,i=e},f:function(){try{a||null==n.return||n.return()}finally{if(s)throw i}}}}function w(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n>>2]>>>24-i%4*8&255;t[r+i>>>2]|=a<<24-(r+i)%4*8}else for(i=0;i>>2]=n[i>>>2];return this.sigBytes+=o,this},clamp:function(){var t=this.words,n=this.sigBytes;t[n>>>2]&=4294967295<<32-n%4*8,t.length=e.ceil(n/4)},clone:function(){var e=i.clone.call(this);return e.words=this.words.slice(0),e},random:function(t){for(var n,r=[],o=function(t){t=t;var n=987654321,r=4294967295;return function(){var o=((n=36969*(65535&n)+(n>>16)&r)<<16)+(t=18e3*(65535&t)+(t>>16)&r)&r;return o/=4294967296,(o+=.5)*(e.random()>.5?1:-1)}},i=0;i>>2]>>>24-o%4*8&255;r.push((i>>>4).toString(16)),r.push((15&i).toString(16))}return r.join("")},parse:function(e){for(var t=e.length,n=[],r=0;r>>3]|=parseInt(e.substr(r,2),16)<<24-r%8*4;return new a.init(n,t/2)}},c=s.Latin1={stringify:function(e){for(var t=e.words,n=e.sigBytes,r=[],o=0;o>>2]>>>24-o%4*8&255;r.push(String.fromCharCode(i))}return r.join("")},parse:function(e){for(var t=e.length,n=[],r=0;r>>2]|=(255&e.charCodeAt(r))<<24-r%4*8;return new a.init(n,t)}},f=s.Utf8={stringify:function(e){try{return decodeURIComponent(escape(c.stringify(e)))}catch(e){throw new Error("Malformed UTF-8 data")}},parse:function(e){return c.parse(unescape(encodeURIComponent(e)))}},l=o.BufferedBlockAlgorithm=i.extend({reset:function(){this._data=new a.init,this._nDataBytes=0},_append:function(e){"string"==typeof e&&(e=f.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes},_process:function(t){var n=this._data,r=n.words,o=n.sigBytes,i=this.blockSize,s=o/(4*i),u=(s=t?e.ceil(s):e.max((0|s)-this._minBufferSize,0))*i,c=e.min(4*u,o);if(u){for(var f=0;f>>24)|4278255360&(o<<24|o>>>8)}var i=this._hash.words,a=e[t+0],u=e[t+1],h=e[t+2],p=e[t+3],v=e[t+4],g=e[t+5],y=e[t+6],b=e[t+7],m=e[t+8],_=e[t+9],w=e[t+10],x=e[t+11],k=e[t+12],O=e[t+13],A=e[t+14],S=e[t+15],P=i[0],T=i[1],E=i[2],I=i[3];P=c(P,T,E,I,a,7,s[0]),I=c(I,P,T,E,u,12,s[1]),E=c(E,I,P,T,h,17,s[2]),T=c(T,E,I,P,p,22,s[3]),P=c(P,T,E,I,v,7,s[4]),I=c(I,P,T,E,g,12,s[5]),E=c(E,I,P,T,y,17,s[6]),T=c(T,E,I,P,b,22,s[7]),P=c(P,T,E,I,m,7,s[8]),I=c(I,P,T,E,_,12,s[9]),E=c(E,I,P,T,w,17,s[10]),T=c(T,E,I,P,x,22,s[11]),P=c(P,T,E,I,k,7,s[12]),I=c(I,P,T,E,O,12,s[13]),E=c(E,I,P,T,A,17,s[14]),P=f(P,T=c(T,E,I,P,S,22,s[15]),E,I,u,5,s[16]),I=f(I,P,T,E,y,9,s[17]),E=f(E,I,P,T,x,14,s[18]),T=f(T,E,I,P,a,20,s[19]),P=f(P,T,E,I,g,5,s[20]),I=f(I,P,T,E,w,9,s[21]),E=f(E,I,P,T,S,14,s[22]),T=f(T,E,I,P,v,20,s[23]),P=f(P,T,E,I,_,5,s[24]),I=f(I,P,T,E,A,9,s[25]),E=f(E,I,P,T,p,14,s[26]),T=f(T,E,I,P,m,20,s[27]),P=f(P,T,E,I,O,5,s[28]),I=f(I,P,T,E,h,9,s[29]),E=f(E,I,P,T,b,14,s[30]),P=l(P,T=f(T,E,I,P,k,20,s[31]),E,I,g,4,s[32]),I=l(I,P,T,E,m,11,s[33]),E=l(E,I,P,T,x,16,s[34]),T=l(T,E,I,P,A,23,s[35]),P=l(P,T,E,I,u,4,s[36]),I=l(I,P,T,E,v,11,s[37]),E=l(E,I,P,T,b,16,s[38]),T=l(T,E,I,P,w,23,s[39]),P=l(P,T,E,I,O,4,s[40]),I=l(I,P,T,E,a,11,s[41]),E=l(E,I,P,T,p,16,s[42]),T=l(T,E,I,P,y,23,s[43]),P=l(P,T,E,I,_,4,s[44]),I=l(I,P,T,E,k,11,s[45]),E=l(E,I,P,T,S,16,s[46]),P=d(P,T=l(T,E,I,P,h,23,s[47]),E,I,a,6,s[48]),I=d(I,P,T,E,b,10,s[49]),E=d(E,I,P,T,A,15,s[50]),T=d(T,E,I,P,g,21,s[51]),P=d(P,T,E,I,k,6,s[52]),I=d(I,P,T,E,p,10,s[53]),E=d(E,I,P,T,w,15,s[54]),T=d(T,E,I,P,u,21,s[55]),P=d(P,T,E,I,m,6,s[56]),I=d(I,P,T,E,S,10,s[57]),E=d(E,I,P,T,y,15,s[58]),T=d(T,E,I,P,O,21,s[59]),P=d(P,T,E,I,v,6,s[60]),I=d(I,P,T,E,x,10,s[61]),E=d(E,I,P,T,h,15,s[62]),T=d(T,E,I,P,_,21,s[63]),i[0]=i[0]+P|0,i[1]=i[1]+T|0,i[2]=i[2]+E|0,i[3]=i[3]+I|0},_doFinalize:function(){var t=this._data,n=t.words,r=8*this._nDataBytes,o=8*t.sigBytes;n[o>>>5]|=128<<24-o%32;var i=e.floor(r/4294967296),a=r;n[15+(o+64>>>9<<4)]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8),n[14+(o+64>>>9<<4)]=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8),t.sigBytes=4*(n.length+1),this._process();for(var s=this._hash,u=s.words,c=0;c<4;c++){var f=u[c];u[c]=16711935&(f<<8|f>>>24)|4278255360&(f<<24|f>>>8)}return s},clone:function(){var e=i.clone.call(this);return e._hash=this._hash.clone(),e}});function c(e,t,n,r,o,i,a){var s=e+(t&n|~t&r)+o+a;return(s<>>32-i)+t}function f(e,t,n,r,o,i,a){var s=e+(t&r|n&~r)+o+a;return(s<>>32-i)+t}function l(e,t,n,r,o,i,a){var s=e+(t^n^r)+o+a;return(s<>>32-i)+t}function d(e,t,n,r,o,i,a){var s=e+(n^(t|~r))+o+a;return(s<>>32-i)+t}t.MD5=i._createHelper(u),t.HmacMD5=i._createHmacHelper(u)}(Math),n.MD5)})),A((function(e,t){var n;e.exports=(n=P,void function(){var e=n,t=e.lib.Base,r=e.enc.Utf8;e.algo.HMAC=t.extend({init:function(e,t){e=this._hasher=new e.init,"string"==typeof t&&(t=r.parse(t));var n=e.blockSize,o=4*n;t.sigBytes>o&&(t=e.finalize(t)),t.clamp();for(var i=this._oKey=t.clone(),a=this._iKey=t.clone(),s=i.words,u=a.words,c=0;c>>6-a%4*2;o[i>>>2]|=(s|u)<<24-i%4*8,i++}return t.create(o,i)}e.enc.Base64={stringify:function(e){var t=e.words,n=e.sigBytes,r=this._map;e.clamp();for(var o=[],i=0;i>>2]>>>24-i%4*8&255)<<16|(t[i+1>>>2]>>>24-(i+1)%4*8&255)<<8|t[i+2>>>2]>>>24-(i+2)%4*8&255,s=0;s<4&&i+.75*s>>6*(3-s)&63));var u=r.charAt(64);if(u)for(;o.length%4;)o.push(u);return o.join("")},parse:function(e){var t=e.length,n=this._map,o=this._reverseMap;if(!o){o=this._reverseMap=[];for(var i=0;i0&&void 0!==arguments[0]?arguments[0]:{},n=t.createPromise,r=t.retryRule,o=void 0===r?F:r;(0,y.default)(this,e),this.createPromise=n,this.status=null,this.promise=null,this.retryRule=o}return(0,b.default)(e,[{key:"needRetry",get:function(){if(!this.status)return!0;switch(this.retryRule){case F:return this.status===D;case B:return this.status!==$}}},{key:"exec",value:function(){var e=this;return this.needRetry?(this.status=$,this.promise=this.createPromise().then((function(t){return e.status=L,Promise.resolve(t)}),(function(t){return e.status=D,Promise.reject(t)})),this.promise):this.promise}}]),e}();function V(e){return e&&"string"==typeof e?JSON.parse(e):e}var H="mp-weixin",z=V([]),K=H,W=(V(void 0),V([])||[]);try{(n("a3f2").default||n("a3f2")).appid}catch(lr){}var J={};function G(e){var t,n,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t=J,n=e,Object.prototype.hasOwnProperty.call(t,n)||(J[e]=r),J[e]}"app"===K&&(J=r._globalUniCloudObj?r._globalUniCloudObj:r._globalUniCloudObj={});var Y=["invoke","success","fail","complete"],Z=G("_globalUniCloudInterceptor");function Q(e,t){Z[e]||(Z[e]={}),R(t)&&Object.keys(t).forEach((function(n){Y.indexOf(n)>-1&&function(e,t,n){var r=Z[e][t];r||(r=Z[e][t]=[]),-1===r.indexOf(n)&&U(n)&&r.push(n)}(e,n,t[n])}))}function X(e,t){Z[e]||(Z[e]={}),R(t)?Object.keys(t).forEach((function(n){Y.indexOf(n)>-1&&function(e,t,n){var r=Z[e][t];if(r){var o=r.indexOf(n);o>-1&&r.splice(o,1)}}(e,n,t[n])})):delete Z[e]}function ee(e,t){return e&&0!==e.length?e.reduce((function(e,n){return e.then((function(){return n(t)}))}),Promise.resolve()):Promise.resolve()}function te(e,t){return Z[e]&&Z[e][t]||[]}function ne(e){Q("callObject",e)}var re=G("_globalUniCloudListener"),oe="response",ie="needLogin",ae="refreshToken",se="clientdb",ue="cloudfunction",ce="cloudobject";function fe(e){return re[e]||(re[e]=[]),re[e]}function le(e,t){var n=fe(e);n.includes(t)||n.push(t)}function de(e,t){var n=fe(e),r=n.indexOf(t);-1!==r&&n.splice(r,1)}function he(e,t){for(var n=fe(e),r=0;r0&&void 0!==arguments[0]?arguments[0]:0;if(!(e>=10))return e++,{errCode:this.errCode,errMsg:this.errMsg,errSubject:this.errSubject,cause:this.cause&&this.cause.toJson?this.cause.toJson(e):this.cause}}}]),n}((0,g.default)(Error)),we={request:function(e){return r.request(e)},uploadFile:function(e){return r.uploadFile(e)},setStorageSync:function(e,t){return r.setStorageSync(e,t)},getStorageSync:function(e){return r.getStorageSync(e)},removeStorageSync:function(e){return r.removeStorageSync(e)},clearStorageSync:function(){return r.clearStorageSync()}};function xe(){return{token:we.getStorageSync("uni_id_token")||we.getStorageSync("uniIdToken"),tokenExpired:we.getStorageSync("uni_id_token_expired")}}function ke(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.token,n=e.tokenExpired;t&&we.setStorageSync("uni_id_token",t),n&&we.setStorageSync("uni_id_token_expired",n)}function Oe(){return be||(be=r.getSystemInfoSync()),be}function Ae(){var e=r.getLocale&&r.getLocale()||"en";if(me)return k(k({},me),{},{locale:e,LOCALE:e});for(var t=Oe(),n=t.deviceId,o=t.osName,i=t.uniPlatform,a=t.appId,s=["pixelRatio","brand","model","system","language","version","platform","host","SDKVersion","swanNativeVersion","app","AppPlatform","fontSizeSetting"],u=0;u-1)return;var n=r.getLaunchOptionsSync(),o=n.scene,i=n.channel;e=i,t=o}}catch(e){}return{channel:e,scene:t}}()),t),k(k({},me),{},{locale:e,LOCALE:e})}var Se,Pe={sign:function(e,t){var n="";return Object.keys(e).sort().forEach((function(t){e[t]&&(n=n+"&"+t+"="+e[t])})),n=n.slice(1),T(n,t).toString()},wrappedRequest:function(e,t){return new Promise((function(n,r){t(Object.assign(e,{complete:function(e){e||(e={});var t=e.data&&e.data.header&&e.data.header["x-serverless-request-id"]||e.header&&e.header["request-id"];if(!e.statusCode||e.statusCode>=400)return r(new _e({code:"SYS_ERR",message:e.errMsg||"request:fail",requestId:t}));var o=e.data;if(o.error)return r(new _e({code:o.error.code,message:o.error.message,requestId:t}));o.result=o.data,o.requestId=t,delete o.data,n(o)}}))}))},toBase64:function(e){return I.stringify(E.parse(e))}},Te=function(){function e(t){var n=this;(0,y.default)(this,e),["spaceId","clientSecret"].forEach((function(e){if(!Object.prototype.hasOwnProperty.call(t,e))throw new Error("".concat(e," required"))})),this.config=Object.assign({},{endpoint:0===t.spaceId.indexOf("mp-")?"https://api.next.bspapp.com":"https://api.bspapp.com"},t),this.config.provider="aliyun",this.config.requestUrl=this.config.endpoint+"/client",this.config.envType=this.config.envType||"public",this.config.accessTokenKey="access_token_"+this.config.spaceId,this.adapter=we,this._getAccessTokenPromiseHub=new q({createPromise:function(){return n.requestAuth(n.setupRequest({method:"serverless.auth.user.anonymousAuthorize",params:"{}"},"auth")).then((function(e){if(!e.result||!e.result.accessToken)throw new _e({code:"AUTH_FAILED",message:"获取accessToken失败"});n.setAccessToken(e.result.accessToken)}))},retryRule:B})}return(0,b.default)(e,[{key:"hasAccessToken",get:function(){return!!this.accessToken}},{key:"setAccessToken",value:function(e){this.accessToken=e}},{key:"requestWrapped",value:function(e){return Pe.wrappedRequest(e,this.adapter.request)}},{key:"requestAuth",value:function(e){return this.requestWrapped(e)}},{key:"request",value:function(e,t){var n=this;return Promise.resolve().then((function(){return n.hasAccessToken?t?n.requestWrapped(e):n.requestWrapped(e).catch((function(t){return new Promise((function(e,n){!t||"GATEWAY_INVALID_TOKEN"!==t.code&&"InvalidParameter.InvalidToken"!==t.code?n(t):e()})).then((function(){return n.getAccessToken()})).then((function(){var t=n.rebuildRequest(e);return n.request(t,!0)}))})):n.getAccessToken().then((function(){var t=n.rebuildRequest(e);return n.request(t,!0)}))}))}},{key:"rebuildRequest",value:function(e){var t=Object.assign({},e);return t.data.token=this.accessToken,t.header["x-basement-token"]=this.accessToken,t.header["x-serverless-sign"]=Pe.sign(t.data,this.config.clientSecret),t}},{key:"setupRequest",value:function(e,t){var n=Object.assign({},e,{spaceId:this.config.spaceId,timestamp:Date.now()}),r={"Content-Type":"application/json"};return"auth"!==t&&(n.token=this.accessToken,r["x-basement-token"]=this.accessToken),r["x-serverless-sign"]=Pe.sign(n,this.config.clientSecret),{url:this.config.requestUrl,method:"POST",data:n,dataType:"json",header:r}}},{key:"getAccessToken",value:function(){return this._getAccessTokenPromiseHub.exec()}},{key:"authorize",value:function(){var e=(0,l.default)(a.default.mark((function e(){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this.getAccessToken();case 2:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"callFunction",value:function(e){var t={method:"serverless.function.runtime.invoke",params:JSON.stringify({functionTarget:e.name,functionArgs:e.data||{}})};return this.request(this.setupRequest(t))}},{key:"getOSSUploadOptionsFromPath",value:function(e){var t={method:"serverless.file.resource.generateProximalSign",params:JSON.stringify(e)};return this.request(this.setupRequest(t))}},{key:"uploadFileToOSS",value:function(e){var t=this,n=e.url,r=e.formData,o=e.name,i=e.filePath,a=e.fileType,s=e.onUploadProgress;return new Promise((function(e,u){var c=t.adapter.uploadFile({url:n,formData:r,name:o,filePath:i,fileType:a,header:{"X-OSS-server-side-encrpytion":"AES256"},success:function(t){t&&t.statusCode<400?e(t):u(new _e({code:"UPLOAD_FAILED",message:"文件上传失败"}))},fail:function(e){u(new _e({code:e.code||"UPLOAD_FAILED",message:e.message||e.errMsg||"文件上传失败"}))}});"function"==typeof s&&c&&"function"==typeof c.onProgressUpdate&&c.onProgressUpdate((function(e){s({loaded:e.totalBytesSent,total:e.totalBytesExpectedToSend})}))}))}},{key:"reportOSSUpload",value:function(e){var t={method:"serverless.file.resource.report",params:JSON.stringify(e)};return this.request(this.setupRequest(t))}},{key:"uploadFile",value:function(){var e=(0,l.default)(a.default.mark((function e(t){var n,r,o,i,s,u,c,f,l,d,h,p,v,g,y,b,m,_,w,x,k,O;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=t.filePath,r=t.cloudPath,o=t.fileType,i=void 0===o?"image":o,s=t.cloudPathAsRealPath,u=void 0!==s&&s,c=t.onUploadProgress,f=t.config,"string"===M(r)){e.next=3;break}throw new _e({code:"INVALID_PARAM",message:"cloudPath必须为字符串类型"});case 3:if(r=r.trim()){e.next=5;break}throw new _e({code:"INVALID_PARAM",message:"cloudPath不可为空"});case 5:if(!/:\/\//.test(r)){e.next=7;break}throw new _e({code:"INVALID_PARAM",message:"cloudPath不合法"});case 7:if(l=f&&f.envType||this.config.envType,!(u&&("/"!==r[0]&&(r="/"+r),r.indexOf("\\")>-1))){e.next=10;break}throw new _e({code:"INVALID_PARAM",message:"使用cloudPath作为路径时,cloudPath不可包含“\\”"});case 10:return e.next=12,this.getOSSUploadOptionsFromPath({env:l,filename:u?r.split("/").pop():r,fileId:u?r:void 0});case 12:return d=e.sent.result,h="https://"+d.cdnDomain+"/"+d.ossPath,p=d.securityToken,v=d.accessKeyId,g=d.signature,y=d.host,b=d.ossPath,m=d.id,_=d.policy,w=d.ossCallbackUrl,x={"Cache-Control":"max-age=2592000","Content-Disposition":"attachment",OSSAccessKeyId:v,Signature:g,host:y,id:m,key:b,policy:_,success_action_status:200},p&&(x["x-oss-security-token"]=p),w&&(k=JSON.stringify({callbackUrl:w,callbackBody:JSON.stringify({fileId:m,spaceId:this.config.spaceId}),callbackBodyType:"application/json"}),x.callback=Pe.toBase64(k)),O={url:"https://"+d.host,formData:x,fileName:"file",name:"file",filePath:n,fileType:i},e.next=27,this.uploadFileToOSS(Object.assign({},O,{onUploadProgress:c}));case 27:if(!w){e.next=29;break}return e.abrupt("return",{success:!0,filePath:n,fileID:h});case 29:return e.next=31,this.reportOSSUpload({id:m});case 31:if(!e.sent.success){e.next=33;break}return e.abrupt("return",{success:!0,filePath:n,fileID:h});case 33:throw new _e({code:"UPLOAD_FAILED",message:"文件上传失败"});case 34:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getTempFileURL",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.fileList;return new Promise((function(e,n){Array.isArray(t)&&0!==t.length||n(new _e({code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"})),e({fileList:t.map((function(e){return{fileID:e,tempFileURL:e}}))})}))}},{key:"getFileInfo",value:function(){var e=(0,l.default)(a.default.mark((function e(){var t,n,r,o=arguments;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t=o.length>0&&void 0!==o[0]?o[0]:{},n=t.fileList,Array.isArray(n)&&0!==n.length){e.next=3;break}throw new _e({code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"});case 3:return r={method:"serverless.file.resource.info",params:JSON.stringify({id:n.map((function(e){return e.split("?")[0]})).join(",")})},e.next=6,this.request(this.setupRequest(r));case 6:return e.t0=e.sent.result,e.abrupt("return",{fileList:e.t0});case 8:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()}]),e}(),Ee={init:function(e){var t=new Te(e),n={signInAnonymously:function(){return t.authorize()},getLoginState:function(){return Promise.resolve(!1)}};return t.auth=function(){return n},t.customAuth=t.auth,t}},Ie="undefined"!=typeof location&&"http:"===location.protocol?"http:":"https:";!function(e){e.local="local",e.none="none",e.session="session"}(Se||(Se={}));var je,Ce=function(){},$e=A((function(e,t){var n;e.exports=(n=P,function(e){var t=n,r=t.lib,o=r.WordArray,i=r.Hasher,a=t.algo,s=[],u=[];!function(){function t(t){for(var n=e.sqrt(t),r=2;r<=n;r++)if(!(t%r))return!1;return!0}function n(e){return 4294967296*(e-(0|e))|0}for(var r=2,o=0;o<64;)t(r)&&(o<8&&(s[o]=n(e.pow(r,.5))),u[o]=n(e.pow(r,1/3)),o++),r++}();var c=[],f=a.SHA256=i.extend({_doReset:function(){this._hash=new o.init(s.slice(0))},_doProcessBlock:function(e,t){for(var n=this._hash.words,r=n[0],o=n[1],i=n[2],a=n[3],s=n[4],f=n[5],l=n[6],d=n[7],h=0;h<64;h++){if(h<16)c[h]=0|e[t+h];else{var p=c[h-15],v=(p<<25|p>>>7)^(p<<14|p>>>18)^p>>>3,g=c[h-2],y=(g<<15|g>>>17)^(g<<13|g>>>19)^g>>>10;c[h]=v+c[h-7]+y+c[h-16]}var b=r&o^r&i^o&i,m=(r<<30|r>>>2)^(r<<19|r>>>13)^(r<<10|r>>>22),_=d+((s<<26|s>>>6)^(s<<21|s>>>11)^(s<<7|s>>>25))+(s&f^~s&l)+u[h]+c[h];d=l,l=f,f=s,s=a+_|0,a=i,i=o,o=r,r=_+(m+b)|0}n[0]=n[0]+r|0,n[1]=n[1]+o|0,n[2]=n[2]+i|0,n[3]=n[3]+a|0,n[4]=n[4]+s|0,n[5]=n[5]+f|0,n[6]=n[6]+l|0,n[7]=n[7]+d|0},_doFinalize:function(){var t=this._data,n=t.words,r=8*this._nDataBytes,o=8*t.sigBytes;return n[o>>>5]|=128<<24-o%32,n[14+(o+64>>>9<<4)]=e.floor(r/4294967296),n[15+(o+64>>>9<<4)]=r,t.sigBytes=4*n.length,this._process(),this._hash},clone:function(){var e=i.clone.call(this);return e._hash=this._hash.clone(),e}});t.SHA256=i._createHelper(f),t.HmacSHA256=i._createHmacHelper(f)}(Math),n.SHA256)})),Le=$e,De=A((function(e,t){e.exports=P.HmacSHA256})),Me=function(){var e;if(!Promise){e=function(){},e.promise={};var t=function(){throw new _e({message:'Your Node runtime does support ES6 Promises. Set "global.Promise" to your preferred implementation of promises.'})};return Object.defineProperty(e.promise,"then",{get:t}),Object.defineProperty(e.promise,"catch",{get:t}),e}var n=new Promise((function(t,n){e=function(e,r){return e?n(e):t(r)}}));return e.promise=n,e};function Re(e){return void 0===e}function Ue(e){return"[object Null]"===Object.prototype.toString.call(e)}!function(e){e.WEB="web",e.WX_MP="wx_mp"}(je||(je={}));var Ne={adapter:null,runtime:void 0},Fe=["anonymousUuidKey"],Be=function(e){(0,h.default)(n,e);var t=O(n);function n(){var e;return(0,y.default)(this,n),e=t.call(this),Ne.adapter.root.tcbObject||(Ne.adapter.root.tcbObject={}),e}return(0,b.default)(n,[{key:"setItem",value:function(e,t){Ne.adapter.root.tcbObject[e]=t}},{key:"getItem",value:function(e){return Ne.adapter.root.tcbObject[e]}},{key:"removeItem",value:function(e){delete Ne.adapter.root.tcbObject[e]}},{key:"clear",value:function(){delete Ne.adapter.root.tcbObject}}]),n}(Ce);function qe(e,t){switch(e){case"local":return t.localStorage||new Be;case"none":return new Be;default:return t.sessionStorage||new Be}}var Ve=function(){function e(t){if((0,y.default)(this,e),!this._storage){this._persistence=Ne.adapter.primaryStorage||t.persistence,this._storage=qe(this._persistence,Ne.adapter);var n="access_token_".concat(t.env),r="access_token_expire_".concat(t.env),o="refresh_token_".concat(t.env),i="anonymous_uuid_".concat(t.env),a="login_type_".concat(t.env),s="user_info_".concat(t.env);this.keys={accessTokenKey:n,accessTokenExpireKey:r,refreshTokenKey:o,anonymousUuidKey:i,loginTypeKey:a,userInfoKey:s}}}return(0,b.default)(e,[{key:"updatePersistence",value:function(e){if(e!==this._persistence){var t="local"===this._persistence;this._persistence=e;var n=qe(e,Ne.adapter);for(var r in this.keys){var o=this.keys[r];if(!t||!Fe.includes(r)){var i=this._storage.getItem(o);Re(i)||Ue(i)||(n.setItem(o,i),this._storage.removeItem(o))}}this._storage=n}}},{key:"setStore",value:function(e,t,n){if(this._storage){var r={version:n||"localCachev1",content:t},o=JSON.stringify(r);try{this._storage.setItem(e,o)}catch(e){throw e}}}},{key:"getStore",value:function(e,t){try{if(!this._storage)return}catch(e){return""}t=t||"localCachev1";var n=this._storage.getItem(e);return n&&n.indexOf(t)>=0?JSON.parse(n).content:""}},{key:"removeStore",value:function(e){this._storage.removeItem(e)}}]),e}(),He={},ze={};function Ke(e){return He[e]}var We=(0,b.default)((function e(t,n){(0,y.default)(this,e),this.data=n||null,this.name=t})),Je=function(e){(0,h.default)(n,e);var t=O(n);function n(e,r){var o;return(0,y.default)(this,n),o=t.call(this,"error",{error:e,data:r}),o.error=e,o}return(0,b.default)(n)}(We),Ge=new(function(){function e(){(0,y.default)(this,e),this._listeners={}}return(0,b.default)(e,[{key:"on",value:function(e,t){return function(e,t,n){n[e]=n[e]||[],n[e].push(t)}(e,t,this._listeners),this}},{key:"off",value:function(e,t){return function(e,t,n){if(n&&n[e]){var r=n[e].indexOf(t);-1!==r&&n[e].splice(r,1)}}(e,t,this._listeners),this}},{key:"fire",value:function(e,t){if(e instanceof Je)return console.error(e.error),this;var n="string"==typeof e?new We(e,t||{}):e,r=n.name;if(this._listens(r)){n.target=this;var o,i=this._listeners[r]?(0,f.default)(this._listeners[r]):[],a=_(i);try{for(a.s();!(o=a.n()).done;){var s=o.value;s.call(this,n)}}catch(u){a.e(u)}finally{a.f()}}return this}},{key:"_listens",value:function(e){return this._listeners[e]&&this._listeners[e].length>0}}]),e}());function Ye(e,t){Ge.on(e,t)}function Ze(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Ge.fire(e,t)}function Qe(e,t){Ge.off(e,t)}var Xe,et="loginStateChanged",tt="loginStateExpire",nt="loginTypeChanged",rt="anonymousConverted",ot="refreshAccessToken";!function(e){e.ANONYMOUS="ANONYMOUS",e.WECHAT="WECHAT",e.WECHAT_PUBLIC="WECHAT-PUBLIC",e.WECHAT_OPEN="WECHAT-OPEN",e.CUSTOM="CUSTOM",e.EMAIL="EMAIL",e.USERNAME="USERNAME",e.NULL="NULL"}(Xe||(Xe={}));var it=["auth.getJwt","auth.logout","auth.signInWithTicket","auth.signInAnonymously","auth.signIn","auth.fetchAccessTokenWithRefreshToken","auth.signUpWithEmailAndPassword","auth.activateEndUserMail","auth.sendPasswordResetEmail","auth.resetPasswordWithToken","auth.isUsernameRegistered"],at={"X-SDK-Version":"1.3.5"};function st(e,t,n){var r=e[t];e[t]=function(t){var o={},i={};n.forEach((function(n){var r=n.call(e,t),a=r.data,s=r.headers;Object.assign(o,a),Object.assign(i,s)}));var a=t.data;return a&&function(){var e;if(e=a,"[object FormData]"!==Object.prototype.toString.call(e))t.data=k(k({},a),o);else for(var n in o)a.append(n,o[n])}(),t.headers=k(k({},t.headers||{}),i),r.call(e,t)}}function ut(){var e=Math.random().toString(16).slice(2);return{data:{seqId:e},headers:k(k({},at),{},{"x-seqid":e})}}var ct=function(){function e(){var t,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};(0,y.default)(this,e),this.config=n,this._reqClass=new Ne.adapter.reqClass({timeout:this.config.timeout,timeoutMsg:"请求在".concat(this.config.timeout/1e3,"s内未完成,已中断"),restrictedMethods:["post"]}),this._cache=Ke(this.config.env),this._localCache=(t=this.config.env,ze[t]),st(this._reqClass,"post",[ut]),st(this._reqClass,"upload",[ut]),st(this._reqClass,"download",[ut])}return(0,b.default)(e,[{key:"post",value:function(){var e=(0,l.default)(a.default.mark((function e(t){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this._reqClass.post(t);case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"upload",value:function(){var e=(0,l.default)(a.default.mark((function e(t){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this._reqClass.upload(t);case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"download",value:function(){var e=(0,l.default)(a.default.mark((function e(t){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this._reqClass.download(t);case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"refreshAccessToken",value:function(){var e=(0,l.default)(a.default.mark((function e(){var t,n;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this._refreshAccessTokenPromise||(this._refreshAccessTokenPromise=this._refreshAccessToken()),e.prev=1,e.next=4,this._refreshAccessTokenPromise;case 4:t=e.sent,e.next=10;break;case 7:e.prev=7,e.t0=e["catch"](1),n=e.t0;case 10:if(this._refreshAccessTokenPromise=null,this._shouldRefreshAccessTokenHook=null,!n){e.next=12;break}throw n;case 12:return e.abrupt("return",t);case 13:case"end":return e.stop()}}),e,this,[[1,7]])})));return function(){return e.apply(this,arguments)}}()},{key:"_refreshAccessToken",value:function(){var e=(0,l.default)(a.default.mark((function e(){var t,n,r,o,i,s,u,c,f,l,d,h,p;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t=this._cache.keys,n=t.accessTokenKey,r=t.accessTokenExpireKey,o=t.refreshTokenKey,i=t.loginTypeKey,s=t.anonymousUuidKey,this._cache.removeStore(n),this._cache.removeStore(r),u=this._cache.getStore(o),u){e.next=5;break}throw new _e({message:"未登录CloudBase"});case 5:return c={refresh_token:u},e.next=8,this.request("auth.fetchAccessTokenWithRefreshToken",c);case 8:if(f=e.sent,!f.data.code){e.next=21;break}if(l=f.data.code,"SIGN_PARAM_INVALID"!==l&&"REFRESH_TOKEN_EXPIRED"!==l&&"INVALID_REFRESH_TOKEN"!==l){e.next=20;break}if(this._cache.getStore(i)!==Xe.ANONYMOUS||"INVALID_REFRESH_TOKEN"!==l){e.next=19;break}return d=this._cache.getStore(s),h=this._cache.getStore(o),e.next=17,this.send("auth.signInAnonymously",{anonymous_uuid:d,refresh_token:h});case 17:return p=e.sent,e.abrupt("return",(this.setRefreshToken(p.refresh_token),this._refreshAccessToken()));case 19:Ze(tt),this._cache.removeStore(o);case 20:throw new _e({code:f.data.code,message:"刷新access token失败:".concat(f.data.code)});case 21:if(!f.data.access_token){e.next=23;break}return e.abrupt("return",(Ze(ot),this._cache.setStore(n,f.data.access_token),this._cache.setStore(r,f.data.access_token_expire+Date.now()),{accessToken:f.data.access_token,accessTokenExpire:f.data.access_token_expire}));case 23:f.data.refresh_token&&(this._cache.removeStore(o),this._cache.setStore(o,f.data.refresh_token),this._refreshAccessToken());case 24:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"getAccessToken",value:function(){var e=(0,l.default)(a.default.mark((function e(){var t,n,r,o,i,s,u;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t=this._cache.keys,n=t.accessTokenKey,r=t.accessTokenExpireKey,o=t.refreshTokenKey,this._cache.getStore(o)){e.next=3;break}throw new _e({message:"refresh token不存在,登录状态异常"});case 3:if(i=this._cache.getStore(n),s=this._cache.getStore(r),u=!0,e.t0=this._shouldRefreshAccessTokenHook,!e.t0){e.next=9;break}return e.next=8,this._shouldRefreshAccessTokenHook(i,s);case 8:e.t0=!e.sent;case 9:if(e.t1=e.t0,!e.t1){e.next=12;break}u=!1;case 12:return e.abrupt("return",(!i||!s||s2&&void 0!==arguments[2]?arguments[2]:{},r=/\?/.test(t),o="";for(var i in n)""===o?!r&&(t+="?"):o+="&",o+="".concat(i,"=").concat(encodeURIComponent(n[i]));return/^http(s)?\:\/\//.test(t+=o)?t:"".concat(e).concat(t)}(Ie,"//tcb-api.tencentcloudapi.com/web",y),g&&(b+=g),e.next=22,this.post(k({url:b,data:c},d));case 22:if(m=e.sent,_=m.header&&m.header["x-tcb-trace"],_&&this._localCache.setStore(o,_),(200===Number(m.status)||200===Number(m.statusCode))&&m.data){e.next=26;break}throw new _e({code:"NETWORK_ERROR",message:"network request error"});case 26:return e.abrupt("return",m);case 27:case"end":return e.stop()}}),e,this)})));return function(t,n,r){return e.apply(this,arguments)}}()},{key:"send",value:function(){var e=(0,l.default)(a.default.mark((function e(t){var n,r,o,i=arguments;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=i.length>1&&void 0!==i[1]?i[1]:{},e.next=3,this.request(t,n,{onUploadProgress:n.onUploadProgress});case 3:if(r=e.sent,"ACCESS_TOKEN_EXPIRED"!==r.data.code||-1!==it.indexOf(t)){e.next=13;break}return e.next=7,this.refreshAccessToken();case 7:return e.next=9,this.request(t,n,{onUploadProgress:n.onUploadProgress});case 9:if(o=e.sent,!o.data.code){e.next=12;break}throw new _e({code:o.data.code,message:o.data.message});case 12:return e.abrupt("return",o.data);case 13:if(!r.data.code){e.next=15;break}throw new _e({code:r.data.code,message:r.data.message});case 15:return e.abrupt("return",r.data);case 16:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"setRefreshToken",value:function(e){var t=this._cache.keys,n=t.accessTokenKey,r=t.accessTokenExpireKey,o=t.refreshTokenKey;this._cache.removeStore(n),this._cache.removeStore(r),this._cache.setStore(o,e)}}]),e}(),ft={};function lt(e){return ft[e]}var dt=function(){function e(t){(0,y.default)(this,e),this.config=t,this._cache=Ke(t.env),this._request=lt(t.env)}return(0,b.default)(e,[{key:"setRefreshToken",value:function(e){var t=this._cache.keys,n=t.accessTokenKey,r=t.accessTokenExpireKey,o=t.refreshTokenKey;this._cache.removeStore(n),this._cache.removeStore(r),this._cache.setStore(o,e)}},{key:"setAccessToken",value:function(e,t){var n=this._cache.keys,r=n.accessTokenKey,o=n.accessTokenExpireKey;this._cache.setStore(r,e),this._cache.setStore(o,t)}},{key:"refreshUserInfo",value:function(){var e=(0,l.default)(a.default.mark((function e(){var t,n;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this._request.send("auth.getUserInfo",{});case 2:return t=e.sent,n=t.data,e.abrupt("return",(this.setLocalUserInfo(n),n));case 5:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"setLocalUserInfo",value:function(e){var t=this._cache.keys.userInfoKey;this._cache.setStore(t,e)}}]),e}(),ht=function(){function e(t){if((0,y.default)(this,e),!t)throw new _e({code:"PARAM_ERROR",message:"envId is not defined"});this._envId=t,this._cache=Ke(this._envId),this._request=lt(this._envId),this.setUserInfo()}return(0,b.default)(e,[{key:"linkWithTicket",value:function(e){if("string"!=typeof e)throw new _e({code:"PARAM_ERROR",message:"ticket must be string"});return this._request.send("auth.linkWithTicket",{ticket:e})}},{key:"linkWithRedirect",value:function(e){e.signInWithRedirect()}},{key:"updatePassword",value:function(e,t){return this._request.send("auth.updatePassword",{oldPassword:t,newPassword:e})}},{key:"updateEmail",value:function(e){return this._request.send("auth.updateEmail",{newEmail:e})}},{key:"updateUsername",value:function(e){if("string"!=typeof e)throw new _e({code:"PARAM_ERROR",message:"username must be a string"});return this._request.send("auth.updateUsername",{username:e})}},{key:"getLinkedUidList",value:function(){var e=(0,l.default)(a.default.mark((function e(){var t,n,r,o;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this._request.send("auth.getLinkedUidList",{});case 2:return t=e.sent,n=t.data,r=!1,o=n.users,e.abrupt("return",(o.forEach((function(e){e.wxOpenId&&e.wxPublicId&&(r=!0)})),{users:o,hasPrimaryUid:r}));case 7:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"setPrimaryUid",value:function(e){return this._request.send("auth.setPrimaryUid",{uid:e})}},{key:"unlink",value:function(e){return this._request.send("auth.unlink",{platform:e})}},{key:"update",value:function(){var e=(0,l.default)(a.default.mark((function e(t){var n,r,o,i,s,u,c,f;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.nickName,r=t.gender,o=t.avatarUrl,i=t.province,s=t.country,u=t.city,e.next=8,this._request.send("auth.updateUserInfo",{nickName:n,gender:r,avatarUrl:o,province:i,country:s,city:u});case 8:c=e.sent,f=c.data,this.setLocalUserInfo(f);case 11:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"refresh",value:function(){var e=(0,l.default)(a.default.mark((function e(){var t,n;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this._request.send("auth.getUserInfo",{});case 2:return t=e.sent,n=t.data,e.abrupt("return",(this.setLocalUserInfo(n),n));case 5:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"setUserInfo",value:function(){var e=this,t=this._cache.keys.userInfoKey,n=this._cache.getStore(t);["uid","loginType","openid","wxOpenId","wxPublicId","unionId","qqMiniOpenId","email","hasPassword","customUserId","nickName","gender","avatarUrl"].forEach((function(t){e[t]=n[t]})),this.location={country:n.country,province:n.province,city:n.city}}},{key:"setLocalUserInfo",value:function(e){var t=this._cache.keys.userInfoKey;this._cache.setStore(t,e),this.setUserInfo()}}]),e}(),pt=function(){function e(t){if((0,y.default)(this,e),!t)throw new _e({code:"PARAM_ERROR",message:"envId is not defined"});this._cache=Ke(t);var n=this._cache.keys,r=n.refreshTokenKey,o=n.accessTokenKey,i=n.accessTokenExpireKey,a=this._cache.getStore(r),s=this._cache.getStore(o),u=this._cache.getStore(i);this.credential={refreshToken:a,accessToken:s,accessTokenExpire:u},this.user=new ht(t)}return(0,b.default)(e,[{key:"isAnonymousAuth",get:function(){return this.loginType===Xe.ANONYMOUS}},{key:"isCustomAuth",get:function(){return this.loginType===Xe.CUSTOM}},{key:"isWeixinAuth",get:function(){return this.loginType===Xe.WECHAT||this.loginType===Xe.WECHAT_OPEN||this.loginType===Xe.WECHAT_PUBLIC}},{key:"loginType",get:function(){return this._cache.getStore(this._cache.keys.loginTypeKey)}}]),e}(),vt=function(e){(0,h.default)(n,e);var t=O(n);function n(){return(0,y.default)(this,n),t.apply(this,arguments)}return(0,b.default)(n,[{key:"signIn",value:function(){var e=(0,l.default)(a.default.mark((function e(){var t,n,r,o,i,s,u;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this._cache.updatePersistence("local"),t=this._cache.keys,n=t.anonymousUuidKey,r=t.refreshTokenKey,o=this._cache.getStore(n)||void 0,i=this._cache.getStore(r)||void 0,e.next=8,this._request.send("auth.signInAnonymously",{anonymous_uuid:o,refresh_token:i});case 8:if(s=e.sent,!s.uuid||!s.refresh_token){e.next=20;break}return this._setAnonymousUUID(s.uuid),this.setRefreshToken(s.refresh_token),e.next=14,this._request.refreshAccessToken();case 14:return Ze(et),Ze(nt,{env:this.config.env,loginType:Xe.ANONYMOUS,persistence:"local"}),u=new pt(this.config.env),e.next=19,u.user.refresh();case 19:return e.abrupt("return",u);case 20:throw new _e({message:"匿名登录失败"});case 21:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"linkAndRetrieveDataWithTicket",value:function(){var e=(0,l.default)(a.default.mark((function e(t){var n,r,o,i,s,u;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=this._cache.keys,r=n.anonymousUuidKey,o=n.refreshTokenKey,i=this._cache.getStore(r),s=this._cache.getStore(o),e.next=7,this._request.send("auth.linkAndRetrieveDataWithTicket",{anonymous_uuid:i,refresh_token:s,ticket:t});case 7:if(u=e.sent,!u.refresh_token){e.next=16;break}return this._clearAnonymousUUID(),this.setRefreshToken(u.refresh_token),e.next=13,this._request.refreshAccessToken();case 13:return Ze(rt,{env:this.config.env}),Ze(nt,{loginType:Xe.CUSTOM,persistence:"local"}),e.abrupt("return",{credential:{refreshToken:u.refresh_token}});case 16:throw new _e({message:"匿名转化失败"});case 17:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"_setAnonymousUUID",value:function(e){var t=this._cache.keys,n=t.anonymousUuidKey,r=t.loginTypeKey;this._cache.removeStore(n),this._cache.setStore(n,e),this._cache.setStore(r,Xe.ANONYMOUS)}},{key:"_clearAnonymousUUID",value:function(){this._cache.removeStore(this._cache.keys.anonymousUuidKey)}}]),n}(dt),gt=function(e){(0,h.default)(n,e);var t=O(n);function n(){return(0,y.default)(this,n),t.apply(this,arguments)}return(0,b.default)(n,[{key:"signIn",value:function(){var e=(0,l.default)(a.default.mark((function e(t){var n,r;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if("string"==typeof t){e.next=2;break}throw new _e({code:"PARAM_ERROR",message:"ticket must be a string"});case 2:return n=this._cache.keys.refreshTokenKey,e.next=5,this._request.send("auth.signInWithTicket",{ticket:t,refresh_token:this._cache.getStore(n)||""});case 5:if(r=e.sent,!r.refresh_token){e.next=15;break}return this.setRefreshToken(r.refresh_token),e.next=10,this._request.refreshAccessToken();case 10:return Ze(et),Ze(nt,{env:this.config.env,loginType:Xe.CUSTOM,persistence:this.config.persistence}),e.next=14,this.refreshUserInfo();case 14:return e.abrupt("return",new pt(this.config.env));case 15:throw new _e({message:"自定义登录失败"});case 16:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()}]),n}(dt),yt=function(e){(0,h.default)(n,e);var t=O(n);function n(){return(0,y.default)(this,n),t.apply(this,arguments)}return(0,b.default)(n,[{key:"signIn",value:function(){var e=(0,l.default)(a.default.mark((function e(t,n){var r,o,i,s,u;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if("string"==typeof t){e.next=2;break}throw new _e({code:"PARAM_ERROR",message:"email must be a string"});case 2:return r=this._cache.keys.refreshTokenKey,e.next=5,this._request.send("auth.signIn",{loginType:"EMAIL",email:t,password:n,refresh_token:this._cache.getStore(r)||""});case 5:if(o=e.sent,i=o.refresh_token,s=o.access_token,u=o.access_token_expire,!i){e.next=22;break}if(this.setRefreshToken(i),!s||!u){e.next=15;break}this.setAccessToken(s,u),e.next=17;break;case 15:return e.next=17,this._request.refreshAccessToken();case 17:return e.next=19,this.refreshUserInfo();case 19:return Ze(et),Ze(nt,{env:this.config.env,loginType:Xe.EMAIL,persistence:this.config.persistence}),e.abrupt("return",new pt(this.config.env));case 22:throw o.code?new _e({code:o.code,message:"邮箱登录失败: ".concat(o.message)}):new _e({message:"邮箱登录失败"});case 23:case"end":return e.stop()}}),e,this)})));return function(t,n){return e.apply(this,arguments)}}()},{key:"activate",value:function(){var e=(0,l.default)(a.default.mark((function e(t){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",this._request.send("auth.activateEndUserMail",{token:t}));case 1:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"resetPasswordWithToken",value:function(){var e=(0,l.default)(a.default.mark((function e(t,n){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",this._request.send("auth.resetPasswordWithToken",{token:t,newPassword:n}));case 1:case"end":return e.stop()}}),e,this)})));return function(t,n){return e.apply(this,arguments)}}()}]),n}(dt),bt=function(e){(0,h.default)(n,e);var t=O(n);function n(){return(0,y.default)(this,n),t.apply(this,arguments)}return(0,b.default)(n,[{key:"signIn",value:function(){var e=(0,l.default)(a.default.mark((function e(t,n){var r,o,i,s,u;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if("string"==typeof t){e.next=2;break}throw new _e({code:"PARAM_ERROR",message:"username must be a string"});case 2:return"string"!=typeof n&&(n="",console.warn("password is empty")),r=this._cache.keys.refreshTokenKey,e.next=6,this._request.send("auth.signIn",{loginType:Xe.USERNAME,username:t,password:n,refresh_token:this._cache.getStore(r)||""});case 6:if(o=e.sent,i=o.refresh_token,s=o.access_token_expire,u=o.access_token,!i){e.next=23;break}if(this.setRefreshToken(i),!u||!s){e.next=16;break}this.setAccessToken(u,s),e.next=18;break;case 16:return e.next=18,this._request.refreshAccessToken();case 18:return e.next=20,this.refreshUserInfo();case 20:return Ze(et),Ze(nt,{env:this.config.env,loginType:Xe.USERNAME,persistence:this.config.persistence}),e.abrupt("return",new pt(this.config.env));case 23:throw o.code?new _e({code:o.code,message:"用户名密码登录失败: ".concat(o.message)}):new _e({message:"用户名密码登录失败"});case 24:case"end":return e.stop()}}),e,this)})));return function(t,n){return e.apply(this,arguments)}}()}]),n}(dt),mt=function(){function e(t){(0,y.default)(this,e),this.config=t,this._cache=Ke(t.env),this._request=lt(t.env),this._onAnonymousConverted=this._onAnonymousConverted.bind(this),this._onLoginTypeChanged=this._onLoginTypeChanged.bind(this),Ye(nt,this._onLoginTypeChanged)}return(0,b.default)(e,[{key:"currentUser",get:function(){var e=this.hasLoginState();return e&&e.user||null}},{key:"loginType",get:function(){return this._cache.getStore(this._cache.keys.loginTypeKey)}},{key:"anonymousAuthProvider",value:function(){return new vt(this.config)}},{key:"customAuthProvider",value:function(){return new gt(this.config)}},{key:"emailAuthProvider",value:function(){return new yt(this.config)}},{key:"usernameAuthProvider",value:function(){return new bt(this.config)}},{key:"signInAnonymously",value:function(){var e=(0,l.default)(a.default.mark((function e(){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",new vt(this.config).signIn());case 1:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"signInWithEmailAndPassword",value:function(){var e=(0,l.default)(a.default.mark((function e(t,n){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",new yt(this.config).signIn(t,n));case 1:case"end":return e.stop()}}),e,this)})));return function(t,n){return e.apply(this,arguments)}}()},{key:"signInWithUsernameAndPassword",value:function(e,t){return new bt(this.config).signIn(e,t)}},{key:"linkAndRetrieveDataWithTicket",value:function(){var e=(0,l.default)(a.default.mark((function e(t){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this._anonymousAuthProvider||(this._anonymousAuthProvider=new vt(this.config)),Ye(rt,this._onAnonymousConverted),e.next=3,this._anonymousAuthProvider.linkAndRetrieveDataWithTicket(t);case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"signOut",value:function(){var e=(0,l.default)(a.default.mark((function e(){var t,n,r,o,i,s;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(this.loginType!==Xe.ANONYMOUS){e.next=2;break}throw new _e({message:"匿名用户不支持登出操作"});case 2:if(t=this._cache.keys,n=t.refreshTokenKey,r=t.accessTokenKey,o=t.accessTokenExpireKey,i=this._cache.getStore(n),i){e.next=5;break}return e.abrupt("return");case 5:return e.next=7,this._request.send("auth.logout",{refresh_token:i});case 7:return s=e.sent,e.abrupt("return",(this._cache.removeStore(n),this._cache.removeStore(r),this._cache.removeStore(o),Ze(et),Ze(nt,{env:this.config.env,loginType:Xe.NULL,persistence:this.config.persistence}),s));case 9:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"signUpWithEmailAndPassword",value:function(){var e=(0,l.default)(a.default.mark((function e(t,n){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",this._request.send("auth.signUpWithEmailAndPassword",{email:t,password:n}));case 1:case"end":return e.stop()}}),e,this)})));return function(t,n){return e.apply(this,arguments)}}()},{key:"sendPasswordResetEmail",value:function(){var e=(0,l.default)(a.default.mark((function e(t){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",this._request.send("auth.sendPasswordResetEmail",{email:t}));case 1:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"onLoginStateChanged",value:function(e){var t=this;Ye(et,(function(){var n=t.hasLoginState();e.call(t,n)}));var n=this.hasLoginState();e.call(this,n)}},{key:"onLoginStateExpired",value:function(e){Ye(tt,e.bind(this))}},{key:"onAccessTokenRefreshed",value:function(e){Ye(ot,e.bind(this))}},{key:"onAnonymousConverted",value:function(e){Ye(rt,e.bind(this))}},{key:"onLoginTypeChanged",value:function(e){var t=this;Ye(nt,(function(){var n=t.hasLoginState();e.call(t,n)}))}},{key:"getAccessToken",value:function(){var e=(0,l.default)(a.default.mark((function e(){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,this._request.getAccessToken();case 2:return e.t0=e.sent.accessToken,e.t1=this.config.env,e.abrupt("return",{accessToken:e.t0,env:e.t1});case 5:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"hasLoginState",value:function(){var e=this._cache.keys.refreshTokenKey;return this._cache.getStore(e)?new pt(this.config.env):null}},{key:"isUsernameRegistered",value:function(){var e=(0,l.default)(a.default.mark((function e(t){var n,r;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if("string"==typeof t){e.next=2;break}throw new _e({code:"PARAM_ERROR",message:"username must be a string"});case 2:return e.next=4,this._request.send("auth.isUsernameRegistered",{username:t});case 4:return n=e.sent,r=n.data,e.abrupt("return",r&&r.isRegistered);case 7:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getLoginState",value:function(){return Promise.resolve(this.hasLoginState())}},{key:"signInWithTicket",value:function(){var e=(0,l.default)(a.default.mark((function e(t){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",new gt(this.config).signIn(t));case 1:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"shouldRefreshAccessToken",value:function(e){this._request._shouldRefreshAccessTokenHook=e.bind(this)}},{key:"getUserInfo",value:function(){return this._request.send("auth.getUserInfo",{}).then((function(e){return e.code?e:k(k({},e.data),{},{requestId:e.seqId})}))}},{key:"getAuthHeader",value:function(){var e=this._cache.keys,t=e.refreshTokenKey,n=e.accessTokenKey,r=this._cache.getStore(t);return{"x-cloudbase-credentials":this._cache.getStore(n)+"/@@/"+r}}},{key:"_onAnonymousConverted",value:function(e){var t=e.data.env;t===this.config.env&&this._cache.updatePersistence(this.config.persistence)}},{key:"_onLoginTypeChanged",value:function(e){var t=e.data,n=t.loginType,r=t.persistence,o=t.env;o===this.config.env&&(this._cache.updatePersistence(r),this._cache.setStore(this._cache.keys.loginTypeKey,n))}}]),e}(),_t=function(e,t){t=t||Me();var n=lt(this.config.env),r=e.cloudPath,o=e.filePath,i=e.onUploadProgress,a=e.fileType,s=void 0===a?"image":a;return n.send("storage.getUploadMetadata",{path:r}).then((function(e){var a=e.data,u=a.url,c=a.authorization,f=a.token,l=a.fileId,d=a.cosFileId,h=e.requestId,p={key:r,signature:c,"x-cos-meta-fileid":d,success_action_status:"201","x-cos-security-token":f};n.upload({url:u,data:p,file:o,name:r,fileType:s,onUploadProgress:i}).then((function(e){201===e.statusCode?t(null,{fileID:l,requestId:h}):t(new _e({code:"STORAGE_REQUEST_FAIL",message:"STORAGE_REQUEST_FAIL: ".concat(e.data)}))})).catch((function(e){t(e)}))})).catch((function(e){t(e)})),t.promise},wt=function(e,t){t=t||Me();var n=lt(this.config.env),r=e.cloudPath;return n.send("storage.getUploadMetadata",{path:r}).then((function(e){t(null,e)})).catch((function(e){t(e)})),t.promise},xt=function(e,t){var n=e.fileList;if(t=t||Me(),!n||!Array.isArray(n))return{code:"INVALID_PARAM",message:"fileList必须是非空的数组"};var r,o=_(n);try{for(o.s();!(r=o.n()).done;){var i=r.value;if(!i||"string"!=typeof i)return{code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"}}}catch(s){o.e(s)}finally{o.f()}var a={fileid_list:n};return lt(this.config.env).send("storage.batchDeleteFile",a).then((function(e){e.code?t(null,e):t(null,{fileList:e.data.delete_list,requestId:e.requestId})})).catch((function(e){t(e)})),t.promise},kt=function(e,t){var n=e.fileList;t=t||Me(),n&&Array.isArray(n)||t(null,{code:"INVALID_PARAM",message:"fileList必须是非空的数组"});var r,o=[],i=_(n);try{for(i.s();!(r=i.n()).done;){var a=r.value;"object"==(0,c.default)(a)?(a.hasOwnProperty("fileID")&&a.hasOwnProperty("maxAge")||t(null,{code:"INVALID_PARAM",message:"fileList的元素必须是包含fileID和maxAge的对象"}),o.push({fileid:a.fileID,max_age:a.maxAge})):"string"==typeof a?o.push({fileid:a}):t(null,{code:"INVALID_PARAM",message:"fileList的元素必须是字符串"})}}catch(u){i.e(u)}finally{i.f()}var s={file_list:o};return lt(this.config.env).send("storage.batchGetDownloadUrl",s).then((function(e){e.code?t(null,e):t(null,{fileList:e.data.download_list,requestId:e.requestId})})).catch((function(e){t(e)})),t.promise},Ot=function(){var e=(0,l.default)(a.default.mark((function e(t,n){var r,o,i,s;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=t.fileID,e.next=3,kt.call(this,{fileList:[{fileID:r,maxAge:600}]});case 3:if(o=e.sent.fileList[0],"SUCCESS"===o.code){e.next=6;break}return e.abrupt("return",n?n(o):new Promise((function(e){e(o)})));case 6:if(i=lt(this.config.env),s=o.download_url,s=encodeURI(s),n){e.next=10;break}return e.abrupt("return",i.download({url:s}));case 10:return e.t0=n,e.next=13,i.download({url:s});case 13:e.t1=e.sent,(0,e.t0)(e.t1);case 15:case"end":return e.stop()}}),e,this)})));return function(t,n){return e.apply(this,arguments)}}(),At=function(e,t){var n,r=e.name,o=e.data,i=e.query,a=e.parse,s=e.search,u=t||Me();try{n=o?JSON.stringify(o):""}catch(r){return Promise.reject(r)}if(!r)return Promise.reject(new _e({code:"PARAM_ERROR",message:"函数名不能为空"}));var c={inQuery:i,parse:a,search:s,function_name:r,request_data:n};return lt(this.config.env).send("functions.invokeFunction",c).then((function(e){if(e.code)u(null,e);else{var t=e.data.response_data;if(a)u(null,{result:t,requestId:e.requestId});else try{t=JSON.parse(e.data.response_data),u(null,{result:t,requestId:e.requestId})}catch(e){u(new _e({message:"response data must be json"}))}}return u.promise})).catch((function(e){u(e)})),u.promise},St={timeout:15e3,persistence:"session"},Pt={},Tt=function(){function e(t){(0,y.default)(this,e),this.config=t||this.config,this.authObj=void 0}return(0,b.default)(e,[{key:"init",value:function(t){switch(Ne.adapter||(this.requestClient=new Ne.adapter.reqClass({timeout:t.timeout||5e3,timeoutMsg:"请求在".concat((t.timeout||5e3)/1e3,"s内未完成,已中断")})),this.config=k(k({},St),t),!0){case this.config.timeout>6e5:console.warn("timeout大于可配置上限[10分钟],已重置为上限数值"),this.config.timeout=6e5;break;case this.config.timeout<100:console.warn("timeout小于可配置下限[100ms],已重置为下限数值"),this.config.timeout=100}return new e(this.config)}},{key:"auth",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.persistence;if(this.authObj)return this.authObj;var n,r=t||Ne.adapter.primaryStorage||St.persistence;return r!==this.config.persistence&&(this.config.persistence=r),function(e){var t=e.env;He[t]=new Ve(e),ze[t]=new Ve(k(k({},e),{},{persistence:"local"}))}(this.config),n=this.config,ft[n.env]=new ct(n),this.authObj=new mt(this.config),this.authObj}},{key:"on",value:function(e,t){return Ye.apply(this,[e,t])}},{key:"off",value:function(e,t){return Qe.apply(this,[e,t])}},{key:"callFunction",value:function(e,t){return At.apply(this,[e,t])}},{key:"deleteFile",value:function(e,t){return xt.apply(this,[e,t])}},{key:"getTempFileURL",value:function(e,t){return kt.apply(this,[e,t])}},{key:"downloadFile",value:function(e,t){return Ot.apply(this,[e,t])}},{key:"uploadFile",value:function(e,t){return _t.apply(this,[e,t])}},{key:"getUploadMetadata",value:function(e,t){return wt.apply(this,[e,t])}},{key:"registerExtension",value:function(e){Pt[e.name]=e}},{key:"invokeExtension",value:function(){var e=(0,l.default)(a.default.mark((function e(t,n){var r;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(r=Pt[t],r){e.next=3;break}throw new _e({message:"扩展".concat(t," 必须先注册")});case 3:return e.next=5,r.invoke(n,this);case 5:return e.abrupt("return",e.sent);case 6:case"end":return e.stop()}}),e,this)})));return function(t,n){return e.apply(this,arguments)}}()},{key:"useAdapters",value:function(e){var t=function(e){var t,n,r=(t=e,"[object Array]"===Object.prototype.toString.call(t)?e:[e]),o=_(r);try{for(o.s();!(n=o.n()).done;){var i=n.value,a=i.isMatch,s=i.genAdapter,u=i.runtime;if(a())return{adapter:s(),runtime:u}}}catch(c){o.e(c)}finally{o.f()}}(e)||{},n=t.adapter,r=t.runtime;n&&(Ne.adapter=n),r&&(Ne.runtime=r)}}]),e}(),Et=new Tt;function It(e,t,n){void 0===n&&(n={});var r=/\?/.test(t),o="";for(var i in n)""===o?!r&&(t+="?"):o+="&",o+=i+"="+encodeURIComponent(n[i]);return/^http(s)?:\/\//.test(t+=o)?t:""+e+t}var jt=function(){function e(){(0,y.default)(this,e)}return(0,b.default)(e,[{key:"post",value:function(e){var t=e.url,n=e.data,r=e.headers;return new Promise((function(e,o){we.request({url:It("https:",t),data:n,method:"POST",header:r,success:function(t){e(t)},fail:function(e){o(e)}})}))}},{key:"upload",value:function(e){return new Promise((function(t,n){var r=e.url,o=e.file,i=e.data,a=e.headers,s=e.fileType,u=we.uploadFile({url:It("https:",r),name:"file",formData:Object.assign({},i),filePath:o,fileType:s,header:a,success:function(e){var n={statusCode:e.statusCode,data:e.data||{}};200===e.statusCode&&i.success_action_status&&(n.statusCode=parseInt(i.success_action_status,10)),t(n)},fail:function(e){n(new Error(e.errMsg||"uploadFile:fail"))}});"function"==typeof e.onUploadProgress&&u&&"function"==typeof u.onProgressUpdate&&u.onProgressUpdate((function(t){e.onUploadProgress({loaded:t.totalBytesSent,total:t.totalBytesExpectedToSend})}))}))}}]),e}(),Ct={setItem:function(e,t){we.setStorageSync(e,t)},getItem:function(e){return we.getStorageSync(e)},removeItem:function(e){we.removeStorageSync(e)},clear:function(){we.clearStorageSync()}},$t={genAdapter:function(){return{root:{},reqClass:jt,localStorage:Ct,primaryStorage:"local"}},isMatch:function(){return!0},runtime:"uni_app"};Et.useAdapters($t);var Lt=Et,Dt=Lt.init;Lt.init=function(e){e.env=e.spaceId;var t=Dt.call(this,e);t.config.provider="tencent",t.config.spaceId=e.spaceId;var n=t.auth;return t.auth=function(e){var t=n.call(this,e);return["linkAndRetrieveDataWithTicket","signInAnonymously","signOut","getAccessToken","getLoginState","signInWithTicket","getUserInfo"].forEach((function(e){var n;t[e]=(n=t[e],function(e){e=e||{};var t=ye(e),r=t.success,o=t.fail,i=t.complete;if(!(r||o||i))return n.call(this,e);n.call(this,e).then((function(e){r&&r(e),i&&i(e)}),(function(e){o&&o(e),i&&i(e)}))}).bind(t)})),t},t.customAuth=t.auth,t};var Mt=Lt,Rt=function(e){(0,h.default)(n,e);var t=O(n);function n(){return(0,y.default)(this,n),t.apply(this,arguments)}return(0,b.default)(n,[{key:"getAccessToken",value:function(){var e=this;return new Promise((function(t,n){var r="Anonymous_Access_token";e.setAccessToken(r),t(r)}))}},{key:"setupRequest",value:function(e,t){var n=Object.assign({},e,{spaceId:this.config.spaceId,timestamp:Date.now()}),r={"Content-Type":"application/json"};"auth"!==t&&(n.token=this.accessToken,r["x-basement-token"]=this.accessToken),r["x-serverless-sign"]=Pe.sign(n,this.config.clientSecret);var o=Ae();r["x-client-info"]=encodeURIComponent(JSON.stringify(o));var i=xe(),a=i.token;return r["x-client-token"]=a,{url:this.config.requestUrl,method:"POST",data:n,dataType:"json",header:JSON.parse(JSON.stringify(r))}}},{key:"uploadFileToOSS",value:function(e){var t=this,n=e.url,r=e.formData,o=e.name,i=e.filePath,a=e.fileType,s=e.onUploadProgress;return new Promise((function(e,u){var c=t.adapter.uploadFile({url:n,formData:r,name:o,filePath:i,fileType:a,success:function(t){t&&t.statusCode<400?e(t):u(new _e({code:"UPLOAD_FAILED",message:"文件上传失败"}))},fail:function(e){u(new _e({code:e.code||"UPLOAD_FAILED",message:e.message||e.errMsg||"文件上传失败"}))}});"function"==typeof s&&c&&"function"==typeof c.onProgressUpdate&&c.onProgressUpdate((function(e){s({loaded:e.totalBytesSent,total:e.totalBytesExpectedToSend})}))}))}},{key:"uploadFile",value:function(e){var t,n=this,r=e.filePath,o=e.cloudPath,i=e.fileType,a=void 0===i?"image":i,s=e.onUploadProgress;if(!o)throw new _e({code:"CLOUDPATH_REQUIRED",message:"cloudPath不可为空"});return this.getOSSUploadOptionsFromPath({cloudPath:o}).then((function(e){var o=e.result,i=o.url,u=o.formData,c=o.name;t=e.result.fileUrl;var f={url:i,formData:u,name:c,filePath:r,fileType:a};return n.uploadFileToOSS(Object.assign({},f,{onUploadProgress:s}))})).then((function(){return n.reportOSSUpload({cloudPath:o})})).then((function(e){return new Promise((function(n,o){e.success?n({success:!0,filePath:r,fileID:t}):o(new _e({code:"UPLOAD_FAILED",message:"文件上传失败"}))}))}))}},{key:"deleteFile",value:function(e){var t=e.fileList,n={method:"serverless.file.resource.delete",params:JSON.stringify({fileList:t})};return this.request(this.setupRequest(n)).then((function(e){if(e.success)return e.result;throw new _e({code:"DELETE_FILE_FAILED",message:"删除文件失败"})}))}},{key:"getTempFileURL",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.fileList,n=e.maxAge;if(!Array.isArray(t)||0===t.length)throw new _e({code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"});var r={method:"serverless.file.resource.getTempFileURL",params:JSON.stringify({fileList:t,maxAge:n})};return this.request(this.setupRequest(r)).then((function(e){if(e.success)return{fileList:e.result.fileList.map((function(e){return{fileID:e.fileID,tempFileURL:e.tempFileURL}}))};throw new _e({code:"GET_TEMP_FILE_URL_FAILED",message:"获取临时文件链接失败"})}))}}]),n}(Te),Ut={init:function(e){var t=new Rt(e),n={signInAnonymously:function(){return t.authorize()},getLoginState:function(){return Promise.resolve(!1)}};return t.auth=function(){return n},t.customAuth=t.auth,t}},Nt=A((function(e,t){e.exports=P.enc.Hex}));function Ft(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.data,r=t.functionName,o=t.method,i=t.headers,a=t.signHeaderKeys,s=void 0===a?[]:a,c=t.config,f=Date.now(),l="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)})),d=Object.assign({},i,{"x-from-app-id":c.spaceAppId,"x-from-env-id":c.spaceId,"x-to-env-id":c.spaceId,"x-from-instance-id":f,"x-from-function-name":r,"x-client-timestamp":f,"x-alipay-source":"client","x-request-id":l,"x-alipay-callid":l,"x-trace-id":l}),h=["x-from-app-id","x-from-env-id","x-to-env-id","x-from-instance-id","x-from-function-name","x-client-timestamp"].concat(s),p=e.split("?")||[],v=(0,u.default)(p,2),g=v[0],y=void 0===g?"":g,b=v[1],m=void 0===b?"":b,_=function(e){var t=e.signedHeaders.join(";"),n=e.signedHeaders.map((function(t){return"".concat(t.toLowerCase(),":").concat(e.headers[t],"\n")})).join(""),r=Le(e.body).toString(Nt),o="".concat(e.method.toUpperCase(),"\n").concat(e.path,"\n").concat(e.query,"\n").concat(n,"\n").concat(t,"\n").concat(r,"\n"),i=Le(o).toString(Nt),a="HMAC-SHA256\n".concat(e.timestamp,"\n").concat(i,"\n"),s=De(a,e.secretKey).toString(Nt);return"HMAC-SHA256 Credential=".concat(e.secretId,", SignedHeaders=").concat(t,", Signature=").concat(s)}({path:y,query:m,method:o,headers:d,timestamp:f,body:JSON.stringify(n),secretId:c.accessKey,secretKey:c.secretKey,signedHeaders:h.sort()});return{url:"".concat(c.endpoint).concat(e),headers:Object.assign({},d,{Authorization:_})}}function Bt(e){var t=e.url,n=e.data,r=e.method,o=void 0===r?"POST":r,i=e.headers,a=void 0===i?{}:i;return new Promise((function(e,r){we.request({url:t,method:o,data:n,header:a,dataType:"json",complete:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=a["x-trace-id"]||"";if(!t.statusCode||t.statusCode>=400){var o=t.data||{},i=o.message,s=o.errMsg,u=o.trace_id;return r(new _e({code:"SYS_ERR",message:i||s||"request:fail",requestId:u||n}))}e({status:t.statusCode,data:t.data,headers:t.header,requestId:n})}})}))}function qt(e,t){var n=e.path,r=e.data,o=e.method,i=void 0===o?"GET":o,a=Ft(n,{functionName:"",data:r,method:i,headers:{"x-alipay-cloud-mode":"oss","x-data-api-type":"oss","x-expire-timestamp":Date.now()+6e4},signHeaderKeys:["x-data-api-type","x-expire-timestamp"],config:t}),s=a.url,u=a.headers;return Bt({url:s,data:r,method:i,headers:u}).then((function(e){var t=e.data||{};if(!t.success)throw new _e({code:e.errCode,message:e.errMsg,requestId:e.requestId});return t.data||{}})).catch((function(e){throw new _e({code:e.errCode,message:e.errMsg,requestId:e.requestId})}))}function Vt(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=e.trim().replace(/^cloud:\/\//,""),n=t.indexOf("/");if(n<=0)throw new _e({code:"INVALID_PARAM",message:"fileID不合法"});var r=t.substring(0,n),o=t.substring(n+1);return r!==this.config.spaceId&&console.warn("file ".concat(e," does not belong to env ").concat(this.config.spaceId)),o}function Ht(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return"cloud://".concat(this.config.spaceId,"/").concat(e.replace(/^\/+/,""))}var zt=function(){function e(t){if((0,y.default)(this,e),["spaceId","spaceAppId","accessKey","secretKey"].forEach((function(e){if(!Object.prototype.hasOwnProperty.call(t,e))throw new Error("".concat(e," required"))})),t.endpoint){if("string"!=typeof t.endpoint)throw new Error("endpoint must be string");if(!/^https:\/\//.test(t.endpoint))throw new Error("endpoint must start with https://");t.endpoint=t.endpoint.replace(/\/$/,"")}this.config=Object.assign({},t,{endpoint:t.endpoint||"https://".concat(t.spaceId,".api-hz.cloudbasefunction.cn")})}return(0,b.default)(e,[{key:"callFunction",value:function(e){return function(e,t){var n=e.name,r=e.data,o="POST",i=Ft("/functions/invokeFunction",{functionName:n,data:r,method:o,headers:{"x-to-function-name":n},signHeaderKeys:["x-to-function-name"],config:t}),a=i.url,s=i.headers;return Bt({url:a,data:r,method:o,headers:s}).then((function(e){return{errCode:0,success:!0,requestId:e.requestId,result:e.data}})).catch((function(e){throw new _e({code:e.errCode,message:e.errMsg,requestId:e.requestId})}))}(e,this.config)}},{key:"uploadFileToOSS",value:function(e){var t=e.url,n=e.filePath,r=e.fileType,o=e.formData,i=e.onUploadProgress;return new Promise((function(e,a){var s=we.uploadFile({url:t,filePath:n,fileType:r,formData:o,name:"file",success:function(t){t&&t.statusCode<400?e(t):a(new _e({code:"UPLOAD_FAILED",message:"文件上传失败"}))},fail:function(e){a(new _e({code:e.code||"UPLOAD_FAILED",message:e.message||e.errMsg||"文件上传失败"}))}});"function"==typeof i&&s&&"function"==typeof s.onProgressUpdate&&s.onProgressUpdate((function(e){i({loaded:e.totalBytesSent,total:e.totalBytesExpectedToSend})}))}))}},{key:"uploadFile",value:function(){var e=(0,l.default)(a.default.mark((function e(t){var n,r,o,i,s,u,c,f,l,d,h;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=t.filePath,r=t.cloudPath,o=void 0===r?"":r,i=t.fileType,s=void 0===i?"image":i,u=t.onUploadProgress,"string"===M(o)){e.next=3;break}throw new _e({code:"INVALID_PARAM",message:"cloudPath必须为字符串类型"});case 3:if(o=o.trim()){e.next=5;break}throw new _e({code:"INVALID_PARAM",message:"cloudPath不可为空"});case 5:if(!/:\/\//.test(o)){e.next=7;break}throw new _e({code:"INVALID_PARAM",message:"cloudPath不合法"});case 7:return e.next=9,qt({path:"/".concat(o.replace(/^\//,""),"?post_url")},this.config);case 9:return c=e.sent,f=c.file_id,l=c.upload_url,d=c.form_data,h=d&&d.reduce((function(e,t){return e[t.key]=t.value,e}),{}),e.abrupt("return",this.uploadFileToOSS({url:l,filePath:n,fileType:s,formData:h,onUploadProgress:u}).then((function(){return{fileID:f}})));case 15:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getTempFileURL",value:function(){var e=(0,l.default)(a.default.mark((function e(t){var n,r=this;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.fileList,e.abrupt("return",new Promise((function(e,t){(!n||n.length<0)&&t(new _e({errCode:"INVALID_PARAM",errMsg:"fileList不能为空数组"})),n.length>50&&t(new _e({errCode:"INVALID_PARAM",errMsg:"fileList数组长度不能超过50"}));var o,i=[],a=_(n);try{for(a.s();!(o=a.n()).done;){var s=o.value;"string"!==M(s)&&t(new _e({errCode:"INVALID_PARAM",errMsg:"fileList的元素必须是非空的字符串"}));var u=Vt.call(r,s);i.push({file_id:u,expire:600})}}catch(c){a.e(c)}finally{a.f()}qt({path:"/?download_url",data:{file_list:i},method:"POST"},r.config).then((function(t){var n=t.file_list,o=void 0===n?[]:n;e({fileList:o.map((function(e){return{fileID:Ht.call(r,e.file_id),tempFileURL:e.download_url}}))})})).catch((function(e){return t(e)}))})));case 2:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()}]),e}(),Kt={init:function(e){e.provider="alipay";var t=new zt(e);return t.auth=function(){return{signInAnonymously:function(){return Promise.resolve()},getLoginState:function(){return Promise.resolve(!0)}}},t}};function Wt(e){var t,n=e.data;t=Ae();var r=JSON.parse(JSON.stringify(n||{}));if(Object.assign(r,{clientInfo:t}),!r.uniIdToken){var o=xe(),i=o.token;i&&(r.uniIdToken=i)}return r}var Jt=[{rule:/fc_function_not_found|FUNCTION_NOT_FOUND/,content:",云函数[{functionName}]在云端不存在,请检查此云函数名称是否正确以及该云函数是否已上传到服务空间",mode:"append"}],Gt=/[\\^$.*+?()[\]{}|]/g,Yt=RegExp(Gt.source);function Zt(e,t,n){return e.replace(new RegExp((r=t)&&Yt.test(r)?r.replace(Gt,"\\$&"):r,"g"),n);var r}var Qt="request",Xt="response";var en;en="0123456789abcdef";var tn={code:2e4,message:"System error"},nn={code:20101,message:"Invalid client"};function rn(e){var t=e||{},n=t.errSubject,r=t.subject,o=t.errCode,i=t.errMsg,a=t.code,s=t.message,u=t.cause;return new _e({subject:n||r||"uni-secure-network",code:o||a||tn.code,message:i||s,cause:u})}var on;function an(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.secretType;return t===Qt||t===Xt||"both"===t}function sn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.name,n=e.data,r=void 0===n?{}:n;return"app"===K&&"DCloud-clientDB"===t&&"encryption"===r.redirectTo&&"getAppClientKey"===r.action}function un(e){e.functionName,e.result,e.logPvd}function cn(e){var t=e.callFunction,n=function(n){var r=this,o=n.name;n.data=Wt.call(e,{data:n.data});var i={aliyun:"aliyun",tencent:"tcb",tcb:"tcb",alipay:"alipay"}[this.config.provider],a=an(n),s=sn(n),u=a||s;return t.call(this,n).then((function(e){return e.errCode=0,!u&&un.call(r,{functionName:o,result:e,logPvd:i}),Promise.resolve(e)}),(function(e){return!u&&un.call(r,{functionName:o,result:e,logPvd:i}),e&&e.message&&(e.message=function(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.message,n=void 0===t?"":t,r=e.extraInfo,o=void 0===r?{}:r,i=e.formatter,a=void 0===i?[]:i,s=0;s0&&void 0!==arguments[0]?arguments[0]:{},t=e.provider,n=e.spaceId,r=e.functionName,o=Oe(),i=o.appId,a=o.uniPlatform,s=o.osName,u=a;"app"===a&&(u=s);var c=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.provider,n=e.spaceId,r=z;if(!r)return{};t=function(e){return"tencent"===e?"tcb":e}(t);var o=r.find((function(e){return e.provider===t&&e.spaceId===n}));return o&&o.config}({provider:t,spaceId:n});if(!c||!c.accessControl||!c.accessControl.enable)return!1;var f=c.accessControl.function||{},l=Object.keys(f);if(0===l.length)return!0;var d=function(e,t){for(var n,r,o,i=0;i-1&&(r=a):o=a:n=a}return n||r||o}(l,r);if(!d)return!1;if((f[d]||[]).find((function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return e.appId===i&&(e.platform||"").toLowerCase()===u.toLowerCase()})))return!0;throw console.error("此应用[appId: ".concat(i,", platform: ").concat(u,"]不在云端配置的允许访问的应用列表内,参考:https://uniapp.dcloud.net.cn/uniCloud/secure-network.html#verify-client")),rn(nn)}({provider:a,spaceId:s,functionName:u})?new on({secretType:t.secretType,uniCloudIns:e}).wrapVerifyClientCallFunction(n.bind(e))(t):r(t),Object.defineProperty(o,"result",{get:function(){return console.warn("当前返回结果为Promise类型,不可直接访问其result属性,详情请参考:https://uniapp.dcloud.net.cn/uniCloud/faq?id=promise"),{}}}),o.then((function(e){return"undefined"!=typeof UTSJSONObject&&(e.result=new UTSJSONObject(e.result)),e}))}}on="mp-weixin"!==K&&"app"!==K?function(){return(0,b.default)((function e(){throw(0,y.default)(this,e),rn({message:"Platform ".concat(K," is not supported by secure network")})}))}():function(){return(0,b.default)((function e(){throw(0,y.default)(this,e),rn({message:"Platform ".concat(K," is not enabled, please check whether secure network module is enabled in your manifest.json")})}))}();var fn=Symbol("CLIENT_DB_INTERNAL");function ln(e,t){return e.then="DoNotReturnProxyWithAFunctionNamedThen",e._internalType=fn,e.inspect=null,e.__ob__=void 0,new Proxy(e,{get:function(e,n,r){if("_uniClient"===n)return null;if("symbol"==(0,c.default)(n))return e[n];if(n in e||"string"!=typeof n){var o=e[n];return"function"==typeof o?o.bind(e):o}return t.get(e,n,r)}})}function dn(e){return{on:function(t,n){e[t]=e[t]||[],e[t].indexOf(n)>-1||e[t].push(n)},off:function(t,n){e[t]=e[t]||[];var r=e[t].indexOf(n);-1!==r&&e[t].splice(r,1)}}}var hn=["db.Geo","db.command","command.aggregate"];function pn(e,t){return hn.indexOf("".concat(e,".").concat(t))>-1}function vn(e){switch(M(e)){case"array":return e.map((function(e){return vn(e)}));case"object":return e._internalType===fn||Object.keys(e).forEach((function(t){e[t]=vn(e[t])})),e;case"regexp":return{$regexp:{source:e.source,flags:e.flags}};case"date":return{$date:e.toISOString()};default:return e}}function gn(e){return e&&e.content&&e.content.$method}var yn=function(){function e(t,n,r){(0,y.default)(this,e),this.content=t,this.prevStage=n||null,this.udb=null,this._database=r}return(0,b.default)(e,[{key:"toJSON",value:function(){for(var e=this,t=[e.content];e.prevStage;)e=e.prevStage,t.push(e.content);return{$db:t.reverse().map((function(e){return{$method:e.$method,$param:vn(e.$param)}}))}}},{key:"toString",value:function(){return JSON.stringify(this.toJSON())}},{key:"getAction",value:function(){var e=this.toJSON().$db.find((function(e){return"action"===e.$method}));return e&&e.$param&&e.$param[0]}},{key:"getCommand",value:function(){return{$db:this.toJSON().$db.filter((function(e){return"action"!==e.$method}))}}},{key:"isAggregate",get:function(){for(var e=this;e;){var t=gn(e),n=gn(e.prevStage);if("aggregate"===t&&"collection"===n||"pipeline"===t)return!0;e=e.prevStage}return!1}},{key:"isCommand",get:function(){for(var e=this;e;){if("command"===gn(e))return!0;e=e.prevStage}return!1}},{key:"isAggregateCommand",get:function(){for(var e=this;e;){var t=gn(e),n=gn(e.prevStage);if("aggregate"===t&&"command"===n)return!0;e=e.prevStage}return!1}},{key:"getNextStageFn",value:function(e){var t=this;return function(){return bn({$method:e,$param:vn(Array.from(arguments))},t,t._database)}}},{key:"count",get:function(){return this.isAggregate?this.getNextStageFn("count"):function(){return this._send("count",Array.from(arguments))}}},{key:"remove",get:function(){return this.isCommand?this.getNextStageFn("remove"):function(){return this._send("remove",Array.from(arguments))}}},{key:"get",value:function(){return this._send("get",Array.from(arguments))}},{key:"add",get:function(){return this.isCommand?this.getNextStageFn("add"):function(){return this._send("add",Array.from(arguments))}}},{key:"update",value:function(){return this._send("update",Array.from(arguments))}},{key:"end",value:function(){return this._send("end",Array.from(arguments))}},{key:"set",get:function(){return this.isCommand?this.getNextStageFn("set"):function(){throw new Error("JQL禁止使用set方法")}}},{key:"_send",value:function(e,t){var n=this.getAction(),r=this.getCommand();return r.$db.push({$method:e,$param:vn(t)}),this._database._callCloudFunction({action:n,command:r})}}]),e}();function bn(e,t,n){return ln(new yn(e,t,n),{get:function(e,t){var r="db";return e&&e.content&&(r=e.content.$method),pn(r,t)?bn({$method:t},e,n):function(){return bn({$method:t,$param:vn(Array.from(arguments))},e,n)}}})}function mn(e){var t=e.path,n=e.method;return function(){function e(){(0,y.default)(this,e),this.param=Array.from(arguments)}return(0,b.default)(e,[{key:"toJSON",value:function(){return{$newDb:[].concat((0,f.default)(t.map((function(e){return{$method:e}}))),[{$method:n,$param:this.param}])}}},{key:"toString",value:function(){return JSON.stringify(this.toJSON())}}]),e}()}function _n(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return ln(new e(t),{get:function(e,t){return pn("db",t)?bn({$method:t},null,e):function(){return bn({$method:t,$param:vn(Array.from(arguments))},null,e)}}})}var wn=function(e){(0,h.default)(n,e);var t=O(n);function n(){return(0,y.default)(this,n),t.apply(this,arguments)}return(0,b.default)(n,[{key:"_parseResult",value:function(e){return this._isJQL?e.result:e}},{key:"_callCloudFunction",value:function(e){var t=this,n=e.action,r=e.command,o=e.multiCommand,i=e.queryList;function a(e,t){if(o&&i)for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{},n=t.uniClient,r=void 0===n?{}:n,o=t.isJQL,i=void 0!==o&&o;(0,y.default)(this,e),this._uniClient=r,this._authCallBacks={},this._dbCallBacks={},r._isDefault&&(this._dbCallBacks=G("_globalUniCloudDatabaseCallback")),i||(this.auth=dn(this._authCallBacks)),this._isJQL=i,Object.assign(this,dn(this._dbCallBacks)),this.env=ln({},{get:function(e,t){return{$env:t}}}),this.Geo=ln({},{get:function(e,t){return mn({path:["Geo"],method:t})}}),this.serverDate=mn({path:[],method:"serverDate"}),this.RegExp=mn({path:[],method:"RegExp"})}return(0,b.default)(e,[{key:"getCloudEnv",value:function(e){if("string"!=typeof e||!e.trim())throw new Error("getCloudEnv参数错误");return{$env:e.replace("$cloudEnv_","")}}},{key:"_callback",value:function(e,t){var n=this._dbCallBacks;n[e]&&n[e].forEach((function(e){e.apply(void 0,(0,f.default)(t))}))}},{key:"_callbackAuth",value:function(e,t){var n=this._authCallBacks;n[e]&&n[e].forEach((function(e){e.apply(void 0,(0,f.default)(t))}))}},{key:"multiSend",value:function(){var e=Array.from(arguments),t=e.map((function(e){var t=e.getAction(),n=e.getCommand();if("getTemp"!==n.$db[n.$db.length-1].$method)throw new Error("multiSend只支持子命令内使用getTemp");return{action:t,command:n}}));return this._callCloudFunction({multiCommand:t,queryList:e})}}]),e}()),xn="token无效,跳转登录页面",kn="token过期,跳转登录页面",On={TOKEN_INVALID_TOKEN_EXPIRED:kn,TOKEN_INVALID_INVALID_CLIENTID:xn,TOKEN_INVALID:xn,TOKEN_INVALID_WRONG_TOKEN:xn,TOKEN_INVALID_ANONYMOUS_USER:xn},An={"uni-id-token-expired":kn,"uni-id-check-token-failed":xn,"uni-id-token-not-exist":xn,"uni-id-check-device-feature-failed":xn};function Sn(e,t){var n="";return n=e?"".concat(e,"/").concat(t):t,n.replace(/^\//,"")}function Pn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=[],r=[];return e.forEach((function(e){!0===e.needLogin?n.push(Sn(t,e.path)):!1===e.needLogin&&r.push(Sn(t,e.path))})),{needLoginPage:n,notNeedLoginPage:r}}function Tn(e){return e.split("?")[0].replace(/^\//,"")}function En(){return function(e){var t=e&&e.$page&&e.$page.fullPath||"";return t?("/"!==t.charAt(0)&&(t="/"+t),t):t}(function(){var e=getCurrentPages();return e[e.length-1]}())}function In(){return Tn(En())}function jn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!e)return!1;if(!(t&&t.list&&t.list.length))return!1;var n=t.list,r=Tn(e);return n.some((function(e){return e.pagePath===r}))}var Cn,$n=!!m.default.uniIdRouter,Ln=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.default,t=e.pages,n=void 0===t?[]:t,r=e.subPackages,o=void 0===r?[]:r,i=e.uniIdRouter,a=void 0===i?{}:i,s=e.tabBar,u=void 0===s?{}:s,c=a.loginPage,l=a.needLogin,d=void 0===l?[]:l,h=a.resToLogin,p=void 0===h||h,v=Pn(n),g=v.needLoginPage,y=v.notNeedLoginPage,b=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=[],n=[];return e.forEach((function(e){var r=e.root,o=e.pages,i=void 0===o?[]:o,a=Pn(i,r),s=a.needLoginPage,u=a.notNeedLoginPage;t.push.apply(t,(0,f.default)(s)),n.push.apply(n,(0,f.default)(u))})),{needLoginPage:t,notNeedLoginPage:n}}(o),_=b.needLoginPage,w=b.notNeedLoginPage;return{loginPage:c,routerNeedLogin:d,resToLogin:p,needLoginPage:[].concat((0,f.default)(g),(0,f.default)(_)),notNeedLoginPage:[].concat((0,f.default)(y),(0,f.default)(w)),loginPageInTabBar:jn(c,u)}}(),Dn=Ln.loginPage,Mn=Ln.routerNeedLogin,Rn=Ln.resToLogin,Un=Ln.needLoginPage,Nn=Ln.notNeedLoginPage,Fn=Ln.loginPageInTabBar;if(Un.indexOf(Dn)>-1)throw new Error("Login page [".concat(Dn,'] should not be "needLogin", please check your pages.json'));function Bn(e){var t=In();if("/"===e.charAt(0))return e;var n=e.split("?"),r=(0,u.default)(n,2),o=r[0],i=r[1],a=o.replace(/^\//,"").split("/"),s=t.split("/");s.pop();for(var c=0;c-1)&&(Un.indexOf(t)>-1||Mn.some((function(t){return function(e,t){return new RegExp(t).test(e)}(e,t)})))}function Vn(e){var t=e.redirect,n=Tn(t),r=Tn(Dn);return In()!==r&&n!==r}function Hn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.api,n=e.redirect;if(n&&Vn({redirect:n})){var o=function(e,t){return"/"!==e.charAt(0)&&(e="/"+e),t?e.indexOf("?")>-1?e+"&uniIdRedirectUrl=".concat(encodeURIComponent(t)):e+"?uniIdRedirectUrl=".concat(encodeURIComponent(t)):e}(Dn,n);Fn?"navigateTo"!==t&&"redirectTo"!==t||(t="switchTab"):"switchTab"===t&&(t="navigateTo");var i={navigateTo:r.navigateTo,redirectTo:r.redirectTo,switchTab:r.switchTab,reLaunch:r.reLaunch};setTimeout((function(){i[t]({url:o})}))}}function zn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.url,n={abortLoginPageJump:!1,autoToLoginPage:!1},r=function(){var e,t=xe(),n=t.token,r=t.tokenExpired;if(n){if(r0)return setTimeout((function(){he(ie,r)}),0),n.abortLoginPageJump=!0,n;n.autoToLoginPage=!0}return n}function Kn(){!function(){var e=En(),t=zn({url:e}),n=t.abortLoginPageJump,r=t.autoToLoginPage;n||r&&Hn({api:"redirectTo",redirect:e})}();for(var e=["navigateTo","redirectTo","reLaunch","switchTab"],t=function(t){var n=e[t];r.addInterceptor(n,{invoke:function(e){var t=zn({url:e.url}),r=t.abortLoginPageJump,o=t.autoToLoginPage;return r?e:o?(Hn({api:n,redirect:Bn(e.url)}),!1):e}})},n=0;n0&&void 0!==arguments[0]?arguments[0]:{},t=fe(ie);ge().then((function(){var n=En();if(n&&Vn({redirect:n}))return t.length>0?he(ie,Object.assign({uniIdRedirectUrl:n},e)):void(Dn&&Hn({api:"navigateTo",redirect:n}))}))}(n)}))}function Jn(e){!function(e){e.onResponse=function(e){le(oe,e)},e.offResponse=function(e){de(oe,e)}}(e),function(e){e.onNeedLogin=function(e){le(ie,e)},e.offNeedLogin=function(e){de(ie,e)},$n&&(G("_globalUniCloudStatus").needLoginInit||(G("_globalUniCloudStatus").needLoginInit=!0,ge().then((function(){Kn.call(e)})),Rn&&Wn.call(e)))}(e),function(e){e.onRefreshToken=function(e){le(ae,e)},e.offRefreshToken=function(e){de(ae,e)}}(e)}var Gn="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",Yn=/^(?:[A-Za-z\d+/]{4})*?(?:[A-Za-z\d+/]{2}(?:==)?|[A-Za-z\d+/]{3}=?)?$/;function Zn(){var e,t,n=xe().token||"",r=n.split(".");if(!n||3!==r.length)return{uid:null,role:[],permission:[],tokenExpired:0};try{e=JSON.parse((t=r[1],decodeURIComponent(Cn(t).split("").map((function(e){return"%"+("00"+e.charCodeAt(0).toString(16)).slice(-2)})).join(""))))}catch(n){throw new Error("获取当前用户信息出错,详细错误信息为:"+n.message)}return e.tokenExpired=1e3*e.exp,delete e.exp,delete e.iat,e}Cn="function"!=typeof atob?function(e){if(e=String(e).replace(/[\t\n\f\r ]+/g,""),!Yn.test(e))throw new Error("Failed to execute 'atob' on 'Window': The string to be decoded is not correctly encoded.");var t;e+="==".slice(2-(3&e.length));for(var n,r,o="",i=0;i>16&255):64===r?String.fromCharCode(t>>16&255,t>>8&255):String.fromCharCode(t>>16&255,t>>8&255,255&t);return o}:atob;var Qn=A((function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n="chooseAndUploadFile:ok",i="chooseAndUploadFile:fail";function a(e,t){return e.tempFiles.forEach((function(e,n){e.name||(e.name=e.path.substring(e.path.lastIndexOf("/")+1)),t&&(e.fileType=t),e.cloudPath=Date.now()+"_"+n+e.name.substring(e.name.lastIndexOf("."))})),e.tempFilePaths||(e.tempFilePaths=e.tempFiles.map((function(e){return e.path}))),e}function s(e,t,r){var o=r.onChooseFile,i=r.onUploadProgress;return t.then((function(e){if(o){var t=o(e);if(void 0!==t)return Promise.resolve(t).then((function(t){return void 0===t?e:t}))}return e})).then((function(t){return!1===t?{errMsg:n,tempFilePaths:[],tempFiles:[]}:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:5,o=arguments.length>3?arguments[3]:void 0;(t=Object.assign({},t)).errMsg=n;var i=t.tempFiles,a=i.length,s=0;return new Promise((function(n){for(;s=a)!i.find((function(e){return!e.url&&!e.errMsg}))&&n(t);else{var c=i[r];e.uploadFile({provider:c.provider,filePath:c.path,cloudPath:c.cloudPath,fileType:c.fileType,cloudPathAsRealPath:c.cloudPathAsRealPath,onUploadProgress:function(e){e.index=r,e.tempFile=c,e.tempFilePath=c.path,o&&o(e)}}).then((function(e){c.url=e.fileID,r0&&void 0!==arguments[0]?arguments[0]:{type:"all"};return"image"===t.type?s(e,function(e){var t=e.count,n=e.sizeType,o=e.sourceType,s=void 0===o?["album","camera"]:o,u=e.extension;return new Promise((function(e,o){r.chooseImage({count:t,sizeType:n,sourceType:s,extension:u,success:function(t){e(a(t,"image"))},fail:function(e){o({errMsg:e.errMsg.replace("chooseImage:fail",i)})}})}))}(t),t):"video"===t.type?s(e,function(e){var t=e.camera,n=e.compressed,o=e.maxDuration,s=e.sourceType,u=void 0===s?["album","camera"]:s,c=e.extension;return new Promise((function(e,s){r.chooseVideo({camera:t,compressed:n,maxDuration:o,sourceType:u,extension:c,success:function(t){var n=t.tempFilePath,r=t.duration,o=t.size,i=t.height,s=t.width;e(a({errMsg:"chooseVideo:ok",tempFilePaths:[n],tempFiles:[{name:t.tempFile&&t.tempFile.name||"",path:n,size:o,type:t.tempFile&&t.tempFile.type||"",width:s,height:i,duration:r,fileType:"video",cloudPath:""}]},"video"))},fail:function(e){s({errMsg:e.errMsg.replace("chooseVideo:fail",i)})}})}))}(t),t):s(e,function(e){var t=e.count,n=e.extension;return new Promise((function(e,s){var u=r.chooseFile;if("undefined"!=typeof o&&"function"==typeof o.chooseMessageFile&&(u=o.chooseMessageFile),"function"!=typeof u)return s({errMsg:i+" 请指定 type 类型,该平台仅支持选择 image 或 video。"});u({type:"all",count:t,extension:n,success:function(t){e(a(t))},fail:function(e){s({errMsg:e.errMsg.replace("chooseFile:fail",i)})}})}))}(t),t)}}})),Xn=function(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}(Qn);function er(e){return{props:{localdata:{type:Array,default:function(){return[]}},options:{type:[Object,Array],default:function(){return{}}},spaceInfo:{type:Object,default:function(){return{}}},collection:{type:[String,Array],default:""},action:{type:String,default:""},field:{type:String,default:""},orderby:{type:String,default:""},where:{type:[String,Object],default:""},pageData:{type:String,default:"add"},pageCurrent:{type:Number,default:1},pageSize:{type:Number,default:20},getcount:{type:[Boolean,String],default:!1},gettree:{type:[Boolean,String],default:!1},gettreepath:{type:[Boolean,String],default:!1},startwith:{type:String,default:""},limitlevel:{type:Number,default:10},groupby:{type:String,default:""},groupField:{type:String,default:""},distinct:{type:[Boolean,String],default:!1},foreignKey:{type:String,default:""},loadtime:{type:String,default:"auto"},manual:{type:Boolean,default:!1}},data:function(){return{mixinDatacomLoading:!1,mixinDatacomHasMore:!1,mixinDatacomResData:[],mixinDatacomErrorMessage:"",mixinDatacomPage:{},mixinDatacomError:null}},created:function(){var e=this;this.mixinDatacomPage={current:this.pageCurrent,size:this.pageSize,count:0},this.$watch((function(){var t=[];return["pageCurrent","pageSize","localdata","collection","action","field","orderby","where","getont","getcount","gettree","groupby","groupField","distinct"].forEach((function(n){t.push(e[n])})),t}),(function(t,n){if("manual"!==e.loadtime){for(var r=!1,o=[],i=2;i0&&void 0!==arguments[0]?arguments[0]:{},n=t.getone,r=void 0!==n&&n,o=t.success,i=t.fail;this.mixinDatacomLoading||(this.mixinDatacomLoading=!0,this.mixinDatacomErrorMessage="",this.mixinDatacomError=null,this.mixinDatacomGet().then((function(t){e.mixinDatacomLoading=!1;var n=t.result,i=n.data,a=n.count;e.getcount&&(e.mixinDatacomPage.count=a),e.mixinDatacomHasMore=i.length0&&void 0!==arguments[0]?arguments[0]:{};r=r||{},n="undefined"!=typeof __uniX&&__uniX?e.databaseForJQL(this.spaceInfo):e.database(this.spaceInfo);var o=r.action||this.action;o&&(n=n.action(o));var i=r.collection||this.collection;n=Array.isArray(i)?(t=n).collection.apply(t,(0,f.default)(i)):n.collection(i);var a=r.where||this.where;a&&Object.keys(a).length&&(n=n.where(a));var s=r.field||this.field;s&&(n=n.field(s));var u=r.foreignKey||this.foreignKey;u&&(n=n.foreignKey(u));var c=r.groupby||this.groupby;c&&(n=n.groupBy(c));var l=r.groupField||this.groupField;l&&(n=n.groupField(l)),!0===(void 0!==r.distinct?r.distinct:this.distinct)&&(n=n.distinct());var d=r.orderby||this.orderby;d&&(n=n.orderBy(d));var h=void 0!==r.pageCurrent?r.pageCurrent:this.mixinDatacomPage.current,p=void 0!==r.pageSize?r.pageSize:this.mixinDatacomPage.size,v=void 0!==r.getcount?r.getcount:this.getcount,g=void 0!==r.gettree?r.gettree:this.gettree,y=void 0!==r.gettreepath?r.gettreepath:this.gettreepath,b={getCount:v},m={limitLevel:void 0!==r.limitlevel?r.limitlevel:this.limitlevel,startWith:void 0!==r.startwith?r.startwith:this.startwith};return g&&(b.getTree=m),y&&(b.getTreePath=m),n=n.skip(p*(h-1)).limit(p).get(b),n}}}}function tr(e){return G("_globalUniCloudSecureNetworkCache__{spaceId}".replace("{spaceId}",e.config.spaceId))}function nr(){return rr.apply(this,arguments)}function rr(){return rr=(0,l.default)(a.default.mark((function e(){var t,n,o,i,s,u,c,f=arguments;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t=f.length>0&&void 0!==f[0]?f[0]:{},n=t.openid,o=t.callLoginByWeixin,i=void 0!==o&&o,s=tr(this),"mp-weixin"===K){e.next=4;break}throw new Error("[SecureNetwork] API `initSecureNetworkByWeixin` is not supported on platform `".concat(K,"`"));case 4:if(!n||!i){e.next=6;break}throw new Error("[SecureNetwork] openid and callLoginByWeixin cannot be passed at the same time");case 6:if(!n){e.next=8;break}return e.abrupt("return",(s.mpWeixinOpenid=n,{}));case 8:return e.next=10,new Promise((function(e,t){r.login({success:function(t){e(t.code)},fail:function(e){t(new Error(e.errMsg))}})}));case 10:return u=e.sent,c=this.importObject("uni-id-co",{customUI:!0}),e.next=14,c.secureNetworkHandshakeByWeixin({code:u,callLoginByWeixin:i});case 14:return s.mpWeixinCode=u,e.abrupt("return",{code:u});case 16:case"end":return e.stop()}}),e,this)}))),rr.apply(this,arguments)}function or(e){return ir.apply(this,arguments)}function ir(){return ir=(0,l.default)(a.default.mark((function e(t){var n;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=tr(this),e.abrupt("return",(n.initPromise||(n.initPromise=nr.call(this,t).then((function(e){return e})).catch((function(e){throw delete n.initPromise,e}))),n.initPromise));case 2:case"end":return e.stop()}}),e,this)}))),ir.apply(this,arguments)}function ar(e){var t={getSystemInfo:r.getSystemInfo,getPushClientId:r.getPushClientId};return function(n){return new Promise((function(r,o){t[e](k(k({},n),{},{success:function(e){r(e)},fail:function(e){o(e)}}))}))}}var sr=function(e){(0,h.default)(n,e);var t=O(n);function n(){var e;return(0,y.default)(this,n),e=t.call(this),e._uniPushMessageCallback=e._receivePushMessage.bind((0,s.default)(e)),e._currentMessageId=-1,e._payloadQueue=[],e}return(0,b.default)(n,[{key:"init",value:function(){var e=this;return Promise.all([ar("getSystemInfo")(),ar("getPushClientId")()]).then((function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=(0,u.default)(t,2),r=n[0];r=void 0===r?{}:r;var o=r.appId,i=n[1];i=void 0===i?{}:i;var a=i.cid;if(!o)throw new Error("Invalid appId, please check the manifest.json file");if(!a)throw new Error("Invalid push client id");e._appId=o,e._pushClientId=a,e._seqId=Date.now()+"-"+Math.floor(9e5*Math.random()+1e5),e.emit("open"),e._initMessageListener()}),(function(t){throw e.emit("error",t),e.close(),t}))}},{key:"open",value:function(){var e=(0,l.default)(a.default.mark((function e(){return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",this.init());case 1:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"_isUniCloudSSE",value:function(e){if("receive"!==e.type)return!1;var t=e&&e.data&&e.data.payload;return!(!t||"UNI_CLOUD_SSE"!==t.channel||t.seqId!==this._seqId)}},{key:"_receivePushMessage",value:function(e){if(this._isUniCloudSSE(e)){var t=e&&e.data&&e.data.payload,n=t.action,r=t.messageId,o=t.message;this._payloadQueue.push({action:n,messageId:r,message:o}),this._consumMessage()}}},{key:"_consumMessage",value:function(){for(var e=this;;){var t=this._payloadQueue.find((function(t){return t.messageId===e._currentMessageId+1}));if(!t)break;this._currentMessageId++,this._parseMessagePayload(t)}}},{key:"_parseMessagePayload",value:function(e){var t=e.action,n=e.messageId,r=e.message;"end"===t?this._end({messageId:n,message:r}):"message"===t&&this._appendMessage({messageId:n,message:r})}},{key:"_appendMessage",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=(e.messageId,e.message);this.emit("message",t)}},{key:"_end",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=(e.messageId,e.message);this.emit("end",t),this.close()}},{key:"_initMessageListener",value:function(){r.onPushMessage(this._uniPushMessageCallback)}},{key:"_destroy",value:function(){r.offPushMessage(this._uniPushMessageCallback)}},{key:"toJSON",value:function(){return{appId:this._appId,pushClientId:this._pushClientId,seqId:this._seqId}}},{key:"close",value:function(){this._destroy(),this.emit("close")}}]),n}(function(){function e(){(0,y.default)(this,e),this._callback={}}return(0,b.default)(e,[{key:"addListener",value:function(e,t){this._callback[e]||(this._callback[e]=[]),this._callback[e].push(t)}},{key:"on",value:function(e,t){return this.addListener(e,t)}},{key:"removeListener",value:function(e,t){if(!t)throw new Error('The "listener" argument must be of type function. Received undefined');var n=this._callback[e];if(n){var r=function(e,t){for(var n=e.length-1;n>=0;n--)if(e[n]===t)return n;return-1}(n,t);n.splice(r,1)}}},{key:"off",value:function(e,t){return this.removeListener(e,t)}},{key:"removeAllListener",value:function(e){delete this._callback[e]}},{key:"emit",value:function(e){for(var t=this._callback[e],n=arguments.length,r=new Array(n>1?n-1:0),o=1;o0)return e.init(t).database();if(this._database)return this._database;var n=_n(wn,{uniClient:e});return this._database=n,n},e.databaseForJQL=function(t){if(t&&Object.keys(t).length>0)return e.init(t).databaseForJQL();if(this._databaseForJQL)return this._databaseForJQL;var n=_n(wn,{uniClient:e,isJQL:!0});return this._databaseForJQL=n,n}}(t),function(e){e.getCurrentUserInfo=Zn,e.chooseAndUploadFile=Xn.initChooseAndUploadFile(e),Object.assign(e,{get mixinDatacom(){return er(e)}}),e.SSEChannel=sr,e.initSecureNetworkByWeixin=function(e){return function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=t.openid,r=t.callLoginByWeixin,o=void 0!==r&&r;return or.call(e,{openid:n,callLoginByWeixin:o})}}(e),e.importObject=function(e){return function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};n=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e.customUI=t.customUI||e.customUI,e.parseSystemError=t.parseSystemError||e.parseSystemError,Object.assign(e.loadingOptions,t.loadingOptions),Object.assign(e.errorOptions,t.errorOptions),"object"==(0,c.default)(t.secretMethods)&&(e.secretMethods=t.secretMethods),e}({customUI:!1,loadingOptions:{title:"加载中...",mask:!0},errorOptions:{type:"modal",retry:!1}},n);var o=n,i=o.customUI,s=o.loadingOptions,u=o.errorOptions,f=o.parseSystemError,d=!i;return new Proxy({},{get:function(o,i){switch(i){case"toString":return"[object UniCloudObject]";case"toJSON":return{}}return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.fn,n=e.interceptorName,r=e.getCallbackArgs;return(0,l.default)(a.default.mark((function e(){var o,i,s,u,c,f,l=arguments;return a.default.wrap((function(e){while(1)switch(e.prev=e.next){case 0:for(o=l.length,i=new Array(o),s=0;s0&&void 0!==c[0]?c[0]:{},n=t.title,o=t.content,i=t.showCancel,s=t.cancelText,u=t.confirmText,e.abrupt("return",new Promise((function(e,t){r.showModal({title:n,content:o,showCancel:i,cancelText:s,confirmText:u,success:function(t){e(t)},fail:function(){e({confirm:!1,cancel:!0})}})})));case 2:case"end":return e.stop()}}),e)})))({title:"提示",content:S,showCancel:u.retry,cancelText:"取消",confirmText:u.retry?"重试":"确定"});case 33:if(P=o.sent,T=P.confirm,!u.retry||!T){o.next=37;break}return o.abrupt("return",h.apply(void 0,g));case 37:throw E=new _e({subject:w,code:x,message:O,requestId:p.requestId}),E.detail=p.result,he(oe,{type:ce,content:E}),E;case 39:return o.abrupt("return",(he(oe,{type:ce,content:p.result}),p.result));case 40:case"end":return o.stop()}}),o,null,[[5,11]])})));function h(){return o.apply(this,arguments)}return h}(),interceptorName:"callObject",getCallbackArgs:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.params;return{objectName:t,methodName:i,params:n}}})}})}}(e)}(t),["callFunction","uploadFile","deleteFile","getTempFileURL","downloadFile","chooseAndUploadFile"].forEach((function(e){if(t[e]){var n=t[e];t[e]=function(){return n.apply(t,Array.from(arguments))},t[e]=function(e,t){return function(n){var r=this,o=!1;if("callFunction"===t){var i=n&&n.type||j;o=i!==j}var a="callFunction"===t&&!o,s=this._initPromiseHub.exec();n=n||{};var u=ye(n),c=u.success,f=u.fail,l=u.complete,d=s.then((function(){return o?Promise.resolve():ee(te(t,"invoke"),n)})).then((function(){return e.call(r,n)})).then((function(e){return o?Promise.resolve(e):ee(te(t,"success"),e).then((function(){return ee(te(t,"complete"),e)})).then((function(){return a&&he(oe,{type:ue,content:e}),Promise.resolve(e)}))}),(function(e){return o?Promise.reject(e):ee(te(t,"fail"),e).then((function(){return ee(te(t,"complete"),e)})).then((function(){return he(oe,{type:ue,content:e}),Promise.reject(e)}))}));if(!(c||f||l))return d;d.then((function(e){c&&c(e),l&&l(e),a&&he(oe,{type:ue,content:e})}),(function(e){f&&f(e),l&&l(e),a&&he(oe,{type:ue,content:e})}))}}(t[e],e).bind(t)}})),t.init=this.init,t}}]),e}());(function(){var e=W,t={};if(e&&1===e.length)t=e[0],cr=cr.init(t),cr._isDefault=!0;else{var n;n=e&&e.length>0?"应用有多个服务空间,请通过uniCloud.init方法指定要使用的服务空间":"应用未关联服务空间,请在uniCloud目录右键关联服务空间",["auth","callFunction","uploadFile","deleteFile","getTempFileURL","downloadFile","database","getCurrentUSerInfo","importObject"].forEach((function(e){cr[e]=function(){return console.error(n),Promise.reject(new _e({code:"SYS_ERR",message:n}))}}))}Object.assign(cr,{get mixinDatacom(){return er(cr)}}),Jn(cr),cr.addInterceptor=Q,cr.removeInterceptor=X,cr.interceptObject=ne})();var fr=cr;t.default=fr}).call(this,n("c8ba"),n("543d")["default"],n("bc2e")["default"])},aee8:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default={landsacpe:29100,navbar:29090,toast:20090,goodsNav:20089,alert:20085,modal:20080,popup:20075,tips:19080,sticky:19075,indexListSticky:19070,fab:19060,mask:9999,tableTr:1001,tableTd:1e3}},b17c:function(e,t,n){var r=n("4a4b"),o=n("6f8f");e.exports=function(e,t,n){if(o())return Reflect.construct.apply(null,arguments);var i=[null];i.push.apply(i,t);var a=new(e.bind.apply(e,i));return n&&r(a,n.prototype),a},e.exports.__esModule=!0,e.exports["default"]=e.exports},b1dd:function(e,t,n){"use strict";var r=n("4ea4");Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if(e&&!(0,o.default)(t))return(0,i.default)(e,t);return t};var o=r(n("29a0")),i=r(n("63f8"))},b639:function(e,t,n){"use strict";(function(e){ /*! * The buffer module from node.js, for the browser. * * @author Feross Aboukhadijeh * @license MIT */ var r=n("1fb5"),o=n("9152"),i=n("e3db");function a(){return u.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function s(e,t){if(a()=a())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a().toString(16)+" bytes");return 0|e}function p(e,t){if(u.isBuffer(e))return e.length;if("undefined"!==typeof ArrayBuffer&&"function"===typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!==typeof e&&(e=""+e);var n=e.length;if(0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return F(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return B(e).length;default:if(r)return F(e).length;t=(""+t).toLowerCase(),r=!0}}function v(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if(n>>>=0,t>>>=0,n<=t)return"";e||(e="utf8");while(1)switch(e){case"hex":return E(this,t,n);case"utf8":case"utf-8":return S(this,t,n);case"ascii":return P(this,t,n);case"latin1":case"binary":return T(this,t,n);case"base64":return A(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return I(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function g(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function y(e,t,n,r,o){if(0===e.length)return-1;if("string"===typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=o?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(o)return-1;n=e.length-1}else if(n<0){if(!o)return-1;n=0}if("string"===typeof t&&(t=u.from(t,r)),u.isBuffer(t))return 0===t.length?-1:b(e,t,n,r,o);if("number"===typeof t)return t&=255,u.TYPED_ARRAY_SUPPORT&&"function"===typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):b(e,[t],n,r,o);throw new TypeError("val must be string, number or Buffer")}function b(e,t,n,r,o){var i,a=1,s=e.length,u=t.length;if(void 0!==r&&(r=String(r).toLowerCase(),"ucs2"===r||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;a=2,s/=2,u/=2,n/=2}function c(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(o){var f=-1;for(i=n;is&&(n=s-u),i=n;i>=0;i--){for(var l=!0,d=0;do&&(r=o)):r=o;var i=t.length;if(i%2!==0)throw new TypeError("Invalid hex string");r>i/2&&(r=i/2);for(var a=0;a>8,o=n%256,i.push(o),i.push(r)}return i}(t,e.length-n),e,n,r)}function A(e,t,n){return 0===t&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function S(e,t,n){n=Math.min(e.length,n);var r=[],o=t;while(o239?4:c>223?3:c>191?2:1;if(o+l<=n)switch(l){case 1:c<128&&(f=c);break;case 2:i=e[o+1],128===(192&i)&&(u=(31&c)<<6|63&i,u>127&&(f=u));break;case 3:i=e[o+1],a=e[o+2],128===(192&i)&&128===(192&a)&&(u=(15&c)<<12|(63&i)<<6|63&a,u>2047&&(u<55296||u>57343)&&(f=u));break;case 4:i=e[o+1],a=e[o+2],s=e[o+3],128===(192&i)&&128===(192&a)&&128===(192&s)&&(u=(15&c)<<18|(63&i)<<12|(63&a)<<6|63&s,u>65535&&u<1114112&&(f=u))}null===f?(f=65533,l=1):f>65535&&(f-=65536,r.push(f>>>10&1023|55296),f=56320|1023&f),r.push(f),o+=l}return function(e){var t=e.length;if(t<=4096)return String.fromCharCode.apply(String,e);var n="",r=0;while(r0&&(e=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(e+=" ... ")),""},u.prototype.compare=function(e,t,n,r,o){if(!u.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===o&&(o=this.length),t<0||n>e.length||r<0||o>this.length)throw new RangeError("out of range index");if(r>=o&&t>=n)return 0;if(r>=o)return-1;if(t>=n)return 1;if(t>>>=0,n>>>=0,r>>>=0,o>>>=0,this===e)return 0;for(var i=o-r,a=n-t,s=Math.min(i,a),c=this.slice(r,o),f=e.slice(t,n),l=0;lo)&&(n=o),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var i=!1;;)switch(r){case"hex":return m(this,e,t,n);case"utf8":case"utf-8":return _(this,e,t,n);case"ascii":return w(this,e,t,n);case"latin1":case"binary":return x(this,e,t,n);case"base64":return k(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return O(this,e,t,n);default:if(i)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),i=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function P(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;or)&&(n=r);for(var o="",i=t;in)throw new RangeError("Trying to access beyond buffer length")}function C(e,t,n,r,o,i){if(!u.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||te.length)throw new RangeError("Index out of range")}function $(e,t,n,r){t<0&&(t=65535+t+1);for(var o=0,i=Math.min(e.length-n,2);o>>8*(r?o:1-o)}function L(e,t,n,r){t<0&&(t=4294967295+t+1);for(var o=0,i=Math.min(e.length-n,4);o>>8*(r?o:3-o)&255}function D(e,t,n,r,o,i){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function M(e,t,n,r,i){return i||D(e,0,n,4),o.write(e,t,n,r,23,4),n+4}function R(e,t,n,r,i){return i||D(e,0,n,8),o.write(e,t,n,r,52,8),n+8}u.prototype.slice=function(e,t){var n,r=this.length;if(e=~~e,t=void 0===t?r:~~t,e<0?(e+=r,e<0&&(e=0)):e>r&&(e=r),t<0?(t+=r,t<0&&(t=0)):t>r&&(t=r),t0&&(o*=256))r+=this[e+--t]*o;return r},u.prototype.readUInt8=function(e,t){return t||j(e,1,this.length),this[e]},u.prototype.readUInt16LE=function(e,t){return t||j(e,2,this.length),this[e]|this[e+1]<<8},u.prototype.readUInt16BE=function(e,t){return t||j(e,2,this.length),this[e]<<8|this[e+1]},u.prototype.readUInt32LE=function(e,t){return t||j(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},u.prototype.readUInt32BE=function(e,t){return t||j(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},u.prototype.readIntLE=function(e,t,n){e|=0,t|=0,n||j(e,t,this.length);var r=this[e],o=1,i=0;while(++i=o&&(r-=Math.pow(2,8*t)),r},u.prototype.readIntBE=function(e,t,n){e|=0,t|=0,n||j(e,t,this.length);var r=t,o=1,i=this[e+--r];while(r>0&&(o*=256))i+=this[e+--r]*o;return o*=128,i>=o&&(i-=Math.pow(2,8*t)),i},u.prototype.readInt8=function(e,t){return t||j(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},u.prototype.readInt16LE=function(e,t){t||j(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},u.prototype.readInt16BE=function(e,t){t||j(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},u.prototype.readInt32LE=function(e,t){return t||j(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},u.prototype.readInt32BE=function(e,t){return t||j(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},u.prototype.readFloatLE=function(e,t){return t||j(e,4,this.length),o.read(this,e,!0,23,4)},u.prototype.readFloatBE=function(e,t){return t||j(e,4,this.length),o.read(this,e,!1,23,4)},u.prototype.readDoubleLE=function(e,t){return t||j(e,8,this.length),o.read(this,e,!0,52,8)},u.prototype.readDoubleBE=function(e,t){return t||j(e,8,this.length),o.read(this,e,!1,52,8)},u.prototype.writeUIntLE=function(e,t,n,r){if(e=+e,t|=0,n|=0,!r){var o=Math.pow(2,8*n)-1;C(this,e,t,n,o,0)}var i=1,a=0;this[t]=255&e;while(++a=0&&(a*=256))this[t+i]=e/a&255;return t+n},u.prototype.writeUInt8=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,1,255,0),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},u.prototype.writeUInt16LE=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):$(this,e,t,!0),t+2},u.prototype.writeUInt16BE=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):$(this,e,t,!1),t+2},u.prototype.writeUInt32LE=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):L(this,e,t,!0),t+4},u.prototype.writeUInt32BE=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):L(this,e,t,!1),t+4},u.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);C(this,e,t,n,o-1,-o)}var i=0,a=1,s=0;this[t]=255&e;while(++i>0)-s&255;return t+n},u.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);C(this,e,t,n,o-1,-o)}var i=n-1,a=1,s=0;this[t+i]=255&e;while(--i>=0&&(a*=256))e<0&&0===s&&0!==this[t+i+1]&&(s=1),this[t+i]=(e/a>>0)-s&255;return t+n},u.prototype.writeInt8=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,1,127,-128),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},u.prototype.writeInt16LE=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):$(this,e,t,!0),t+2},u.prototype.writeInt16BE=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):$(this,e,t,!1),t+2},u.prototype.writeInt32LE=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,4,2147483647,-2147483648),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):L(this,e,t,!0),t+4},u.prototype.writeInt32BE=function(e,t,n){return e=+e,t|=0,n||C(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):L(this,e,t,!1),t+4},u.prototype.writeFloatLE=function(e,t,n){return M(this,e,t,!0,n)},u.prototype.writeFloatBE=function(e,t,n){return M(this,e,t,!1,n)},u.prototype.writeDoubleLE=function(e,t,n){return R(this,e,t,!0,n)},u.prototype.writeDoubleBE=function(e,t,n){return R(this,e,t,!1,n)},u.prototype.copy=function(e,t,n,r){if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t=0;--o)e[o+t]=this[o+n];else if(i<1e3||!u.TYPED_ARRAY_SUPPORT)for(o=0;o>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"===typeof e)for(i=t;i55295&&n<57344){if(!o){if(n>56319){(t-=3)>-1&&i.push(239,191,189);continue}if(a+1===r){(t-=3)>-1&&i.push(239,191,189);continue}o=n;continue}if(n<56320){(t-=3)>-1&&i.push(239,191,189),o=n;continue}n=65536+(o-55296<<10|n-56320)}else o&&(t-=3)>-1&&i.push(239,191,189);if(o=null,n<128){if((t-=1)<0)break;i.push(n)}else if(n<2048){if((t-=2)<0)break;i.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;i.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return i}function B(e){return r.toByteArray(function(e){if(e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(U,""),e.length<2)return"";while(e.length%4!==0)e+="=";return e}(e))}function q(e,t,n,r){for(var o=0;o=t.length||o>=e.length)break;t[o+n]=e[o]}return o}}).call(this,n("c8ba"))},b761:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,n){var r=n.config.validateStatus,o=n.statusCode;!o||r&&!r(o)?t(n):e(n)}},bc2e:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=["qy","env","error","version","lanDebug","cloud","serviceMarket","router","worklet","__webpack_require_UNI_MP_PLUGIN__"],o=["lanDebug","router","worklet"],i="undefined"!==typeof globalThis?globalThis:function(){return this}(),a=["w","x"].join(""),s=i[a],u=s.getLaunchOptionsSync?s.getLaunchOptionsSync():null;function c(e){return(!u||1154!==u.scene||!o.includes(e))&&(r.indexOf(e)>-1||"function"===typeof s[e])}i[a]=function(){var e={};for(var t in s)c(t)&&(e[t]=s[t]);return e}();var f=i[a];t.default=f},bd69:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default={mainColor:"#01BEFF",reverseMainColor:"#FFF00D",femaleColor:"#FF71D2",maleColor:"#82B2FF",mainOrange:"#FBBD12",bgColor:"#FFFFFF",spaceColor:"#F8F7F8",fontColor:"#080808",fontSubColor:"#AAAAAA",contentColor:"#838383",fontHolderColor:"#E6E6E6",maskBgColor:"rgba(0, 0, 0, 0.4)"}},c135:function(e,t){e.exports=function(e){if(Array.isArray(e))return e},e.exports.__esModule=!0,e.exports["default"]=e.exports},c240:function(e,t){e.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports["default"]=e.exports},c5f7:function(e,t){e.exports=function(e){try{return-1!==Function.toString.call(e).indexOf("[native code]")}catch(t){return"function"===typeof e}},e.exports.__esModule=!0,e.exports["default"]=e.exports},c8ba:function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(r){"object"===typeof window&&(n=window)}e.exports=n},c973:function(e,t){function n(e,t,n,r,o,i,a){try{var s=e[i](a),u=s.value}catch(c){return void n(c)}s.done?t(u):Promise.resolve(u).then(r,o)}e.exports=function(e){return function(){var t=this,r=arguments;return new Promise((function(o,i){var a=e.apply(t,r);function s(e){n(a,o,i,s,u,"next",e)}function u(e){n(a,o,i,s,u,"throw",e)}s(void 0)}))}},e.exports.__esModule=!0,e.exports["default"]=e.exports},d2b3:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={trim:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"both";return"both"===t?e.replace(/^\s+|\s+$/g,""):"left"===t?e.replace(/^\s*/g,""):"right"===t?e.replace(/(\s*$)/g,""):"all"===t?e.replace(/\s+/g,""):e},getLengthUnitValue:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"rpx";return e?/(%|px|rpx|auto)$/.test(e)?e:e+t:""},humpConvertChar:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"_";return e&&t?e.replace(/([A-Z])/g,"".concat(t,"$1")).toLowerCase():""},charConvertHump:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"_";if(!e||!t)return"";var n=RegExp(t+"(\\w)","g");return e.replace(n,(function(e,t){return t.toUpperCase()}))}};t.default=r},de98:function(e,t,n){"use strict";(function(e){var r=n("4ea4");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=r(n("66fd")),i=r(n("26cb"));o.default.use(i.default);var a={};try{a=e.getStorageSync("lifeData")}catch(f){}var s=["vuex_user"],u=new i.default.Store({state:{vuex_user:a.vuex_user?a.vuex_user:{name:"灵睿"},vuex_version:"1.0.0",vuex_custom_nav_bar:!0,vuex_status_bar_height:0,vuex_custom_bar_height:0,Gid:1,imgUrl:"https://ysx.0rui.cn",apiUrl:"https://ysx.0rui.cn/api"},mutations:{$tStore:function(t,n){var r=n.name.split("."),o="",i=r.length;if(i>=2){for(var a=t[r[0]],u=1;u=0;r--){var o=e[r];"."===o?e.splice(r,1):".."===o?(e.splice(r,1),n++):n&&(e.splice(r,1),n--)}if(t)for(;n--;n)e.unshift("..");return e}function r(e,t){if(e.filter)return e.filter(t);for(var n=[],r=0;r=-1&&!o;i--){var a=i>=0?arguments[i]:e.cwd();if("string"!==typeof a)throw new TypeError("Arguments to path.resolve must be strings");a&&(t=a+"/"+t,o="/"===a.charAt(0))}return t=n(r(t.split("/"),(function(e){return!!e})),!o).join("/"),(o?"/":"")+t||"."},t.normalize=function(e){var i=t.isAbsolute(e),a="/"===o(e,-1);return e=n(r(e.split("/"),(function(e){return!!e})),!i).join("/"),e||i||(e="."),e&&a&&(e+="/"),(i?"/":"")+e},t.isAbsolute=function(e){return"/"===e.charAt(0)},t.join=function(){var e=Array.prototype.slice.call(arguments,0);return t.normalize(r(e,(function(e,t){if("string"!==typeof e)throw new TypeError("Arguments to path.join must be strings");return e})).join("/"))},t.relative=function(e,n){function r(e){for(var t=0;t=0;n--)if(""!==e[n])break;return t>n?[]:e.slice(t,n-t+1)}e=t.resolve(e).substr(1),n=t.resolve(n).substr(1);for(var o=r(e.split("/")),i=r(n.split("/")),a=Math.min(o.length,i.length),s=a,u=0;u=1;--i)if(t=e.charCodeAt(i),47===t){if(!o){r=i;break}}else o=!1;return-1===r?n?"/":".":n&&1===r?"/":e.slice(0,r)},t.basename=function(e,t){var n=function(e){"string"!==typeof e&&(e+="");var t,n=0,r=-1,o=!0;for(t=e.length-1;t>=0;--t)if(47===e.charCodeAt(t)){if(!o){n=t+1;break}}else-1===r&&(o=!1,r=t+1);return-1===r?"":e.slice(n,r)}(e);return t&&n.substr(-1*t.length)===t&&(n=n.substr(0,n.length-t.length)),n},t.extname=function(e){"string"!==typeof e&&(e+="");for(var t=-1,n=0,r=-1,o=!0,i=0,a=e.length-1;a>=0;--a){var s=e.charCodeAt(a);if(47!==s)-1===r&&(o=!1,r=a+1),46===s?-1===t?t=a:1!==i&&(i=1):-1!==t&&(i=-1);else if(!o){n=a+1;break}}return-1===t||-1===r||0===i||1===i&&t===r-1&&t===n+1?"":e.slice(t,r)};var o="b"==="ab".substr(-1)?function(e,t,n){return e.substr(t,n)}:function(e,t,n){return t<0&&(t=e.length+t),e.substr(t,n)}}).call(this,n("4362"))},e0eb:function(e,t,n){"use strict";(function(e){function n(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"none",r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1500;t&&e.showToast({title:t,icon:n,duration:r})}Object.defineProperty(t,"__esModule",{value:!0}),t.clearStorageSync=function(){return e.clearStorageSync()},t.clone=void 0,t.getStorageSync=function(t){return e.getStorageSync(t)},t.previewImage=function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["发送给朋友","保存图片","收藏"];e.previewImage({urls:t,longPressActions:{itemList:n,fail:function(e){console.error(e,"===previewImage")}}})},t.removeStorageSync=function(t){return e.removeStorageSync(t)},t.saveImage=function(t){if(!t)return!1;e.saveImageToPhotosAlbum({filePath:t,success:function(e){n("图片保存成功","success")},fail:function(t){"saveImageToPhotosAlbum:fail:auth denied"!==t.errMsg&&"saveImageToPhotosAlbum:fail auth deny"!==t.errMsg||e.showModal({title:"提示",content:"需要您授权保存相册",showCancel:!1,success:function(t){e.openSetting({success:function(t){t.authSetting["scope.writePhotosAlbum"]?e.showModal({title:"提示",content:"获取权限成功,再次点击图片即可保存",showCancel:!1}):e.showModal({title:"提示",content:"获取权限失败,将无法保存到相册哦~",showCancel:!1})},fail:function(e){console.log("failData",e)}})}})}})},t.setStorageSync=function(t,n){e.setStorageSync(t,n)},t.toast=n,t.useRouter=function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"navigateTo";try{Object.keys(n).length&&(t="".concat(t,"?data=").concat(encodeURIComponent(JSON.stringify(n)))),"navigateBack"===r?e[r]({delta:t}):e[r]({url:t})}catch(o){console.error(o)}};t.clone=function(e){return JSON.parse(JSON.stringify(e))}}).call(this,n("543d")["default"])},e3db:function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},e50d:function(e,t,n){var r=n("7037")["default"];e.exports=function(e,t){if("object"!=r(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,t||"default");if("object"!=r(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)},e.exports.__esModule=!0,e.exports["default"]=e.exports},e725:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.debounceFun=function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:500;return function(){for(var r=this,o=arguments.length,i=new Array(o),a=0;a1&&void 0!==arguments[1]?arguments[1]:500,n=null;return function(){for(var r=this,o=arguments.length,i=new Array(o),a=0;a0&&void 0!==arguments[0]?arguments[0]:"";this.parent||(this.parent=!1),this.parent=this.$tn.$parent.call(this,t),this.parent&&Object.keys(this.parentData).map((function(t){e.parentData[t]=e.parent[t]}))},preventEvent:function(e){e&&e.stopPropagation&&e.stopPropagation()}}}}).call(this,n("543d")["default"])},fafd:function(e,t,n){"use strict";(function(e){var r=n("4ea4");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=r(n("f3b2")),i=r(n("6ef8")),a=r(n("62e5")),s=r(n("a230")),u=r(n("9892")),c=r(n("6262")),f=r(n("2ede")),l=r(n("9e45")),d=r(n("4f40")),h=r(n("d2b3")),p=r(n("27c3")),v=r(n("1b30")),g=r(n("aee8")),y=r(n("bd69"));var b={http:new i.default,updateCustomBar:a.default,color:s.default,message:u.default,uuid:c.default,array:f.default,test:l.default,$parent:d.default,string:h.default,number:p.default,deepClone:v.default,zIndex:g.default,colorInfo:y.default};e.$tn=b;var m={install:function(e){e.mixin(o.default),e.prototype.$tn=b}};t.default=m}).call(this,n("543d")["default"])},febd:function(e,t,n){"use strict";var r=n("4ea4");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=r(n("4bea"));t.default=function(e){return(0,o.default)(e)}}}]);