1 |
- !function(){function e(e,n,t,r,o,i,a){try{var u=e[i](a),c=u.value}catch(l){return void t(l)}u.done?n(c):Promise.resolve(c).then(r,o)}function n(n){return function(){var t=this,r=arguments;return new Promise((function(o,i){var a=n.apply(t,r);function u(n){e(a,o,i,u,c,"next",n)}function c(n){e(a,o,i,u,c,"throw",n)}u(void 0)}))}}function t(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function r(e,n){return function(e){if(Array.isArray(e))return e}(e)||function(e,n){var t=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null==t)return;var r,o,i=[],a=!0,u=!1;try{for(t=t.call(e);!(a=(r=t.next()).done)&&(i.push(r.value),!n||i.length!==n);a=!0);}catch(c){u=!0,o=c}finally{try{a||null==t.return||t.return()}finally{if(u)throw o}}return i}(e,n)||function(e,n){if(!e)return;if("string"==typeof e)return o(e,n);var t=Object.prototype.toString.call(e).slice(8,-1);"Object"===t&&e.constructor&&(t=e.constructor.name);if("Map"===t||"Set"===t)return Array.from(e);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return o(e,n)}(e,n)||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.")}()}function o(e,n){(null==n||n>e.length)&&(n=e.length);for(var t=0,r=new Array(n);t<n;t++)r[t]=e[t];return r}var i=document.createElement("style");i.innerHTML="._imgCode_mywmt_1{padding:.42667rem}._imgCode_mywmt_1 ._codeTitle_mywmt_4{text-align:center;font-size:.42667rem;color:#4f4f4f;margin:0;padding-bottom:.42667rem}._imgCode_mywmt_1 ._img_mywmt_1{display:flex;align-items:center;justify-content:center}._imgCode_mywmt_1 ._imgChange_mywmt_16{display:block;color:#aaa;font-size:.32rem;text-align:center;padding-top:.13333rem}._imgCode_mywmt_1 ._field_mywmt_23{background:#F4F4F4;padding:.26667rem .32rem!important}._imgCodePopup_mywmt_27{width:90%;border-radius:.13333rem;overflow:inherit}._imgCodePopup_mywmt_27 .van-popup__close-icon{top:-.98667rem!important;right:0!important;font-size:.66667rem;color:#fff}\n",document.head.appendChild(i),System.register(["./index-legacy.59567947.js","./index-legacy.f752ca55.js","./index-legacy.c36100f7.js"],(function(e){"use strict";var o,i,a,u,c,l,s,f,d,m,p,g,h,y,v,_,w,C,S,b,x,I,k;return{setters:[function(e){o=e.m,i=e.n,a=e.t,u=e.q,c=e.d,l=e.u,s=e.v,f=e.k,d=e.w,m=e.x,p=e.y,g=e.z,h=e.A,y=e.C,v=e.D,_=e.s,w=e.g,C=e.j,S=e.P,b=e.l,x=e.L},function(e){I=e.F},function(e){k=e.I}],execute:function(){e("c",(function(e){return/^1[3456789]\d{9}$/.test(e)}));var j=r(o("row"),2),T=j[0],A=j[1],R=Symbol(T),F={tag:i("div"),wrap:a,align:String,gutter:u(0),justify:String},H=c({name:T,props:F,setup:function(e,n){var r=n.slots,o=l(R),i=o.children,a=o.linkChildren,u=s((function(){var e=[[]],n=0;return i.forEach((function(t,r){(n+=Number(t.span))>24?(e.push([r]),n-=24):e[e.length-1].push(r)})),e}));return a({spaces:s((function(){var n=Number(e.gutter),t=[];return n?(u.value.forEach((function(e){var r=n*(e.length-1)/e.length;e.forEach((function(e,o){if(0===o)t.push({right:r});else{var i=n-t[e-1].right,a=r-i;t.push({left:i,right:a})}}))})),t):t}))}),function(){var n,o=e.tag,i=e.wrap,a=e.align,u=e.justify;return f(o,{class:A((n={},t(n,"align-".concat(a),a),t(n,"justify-".concat(u),u),t(n,"nowrap",!i),n))},{default:function(){var e;return[null==(e=r.default)?void 0:e.call(r)]}})}}}),L=r(o("col"),2),P=L[0],O=L[1],z={tag:i("div"),span:u(0),offset:d},D=c({name:P,props:z,setup:function(e,n){var r=n.slots,o=m(R),i=o.parent,a=o.index,u=s((function(){if(i){var e=i.spaces;if(e&&e.value&&e.value[a.value]){var n=e.value[a.value],t=n.left,r=n.right;return{paddingLeft:t?"".concat(t,"px"):null,paddingRight:r?"".concat(r,"px"):null}}}}));return function(){var n,o=e.tag,i=e.span,a=e.offset;return f(o,{style:u.value,class:O((n={},t(n,i,i),t(n,"offset-".concat(a),a),n))},{default:function(){var e;return[null==(e=r.default)?void 0:e.call(r)]}})}}}),E=e("C",p(D));var q=r(o("count-down"),2),N=q[0],V=q[1],B={time:u(0),format:i("HH:mm:ss"),autoStart:a,millisecond:Boolean},M=c({name:N,props:B,emits:["change","finish"],setup:function(e,n){var t=n.emit,r=n.slots,o=h({time:+e.time,millisecond:e.millisecond,onChange:function(e){return t("change",e)},onFinish:function(){return t("finish")}}),i=o.start,a=o.pause,u=o.reset,c=o.current,l=s((function(){return function(e,n){var t=n.days,r=n.hours,o=n.minutes,i=n.seconds,a=n.milliseconds;if(e.includes("DD")?e=e.replace("DD",g(t)):r+=24*t,e.includes("HH")?e=e.replace("HH",g(r)):o+=60*r,e.includes("mm")?e=e.replace("mm",g(o)):i+=60*o,e.includes("ss")?e=e.replace("ss",g(i)):a+=1e3*i,e.includes("S")){var u=g(a,3);e=e.includes("SSS")?e.replace("SSS",u):e.includes("SS")?e.replace("SS",u.slice(0,2)):e.replace("S",u.charAt(0))}return e}(e.format,c.value)})),d=function(){u(+e.time),e.autoStart&&i()};return y((function(){return e.time}),d,{immediate:!0}),v({start:i,pause:a,reset:d}),function(){return f("div",{role:"timer",class:V()},[r.default?r.default(c.value):l.value])}}}),U=(e("a",p(M)),e("R",p(H))),$="_imgCode_mywmt_1",G="_codeTitle_mywmt_4",J="_img_mywmt_1",K="_imgChange_mywmt_16",Q="_field_mywmt_23",W="_imgCodePopup_mywmt_27";e("I",c({name:"o-img-code",props:{value:Boolean,phone:[String,Number],onClose:{type:Function,default:function(){}},onSendCode:{type:Function,default:function(){}}},data:function(){return{isSuffix:_.platformApi,showStatus:!1,identifyingCode:null,code:null}},mounted:function(){this.showStatus=this.value,this.sendImgCode()},watch:{value:function(e){this.showStatus=e},code:function(e){e.length>=4&&this.checkVerifyLoginImage()}},methods:{sendImgCode:function(){var e=this;return n(regeneratorRuntime.mark((function n(){var t,r;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,w.get(e.isSuffix+"/open/sendImgCode",{requestType:"form",hideLoading:!0,params:{phone:e.phone}});case 2:t=n.sent,r=t.data,e.identifyingCode=r;case 5:case"end":return n.stop()}}),n)})))()},updateIdentifyingCode:function(){var e=this;return n(regeneratorRuntime.mark((function n(){return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:e.sendImgCode();case 1:case"end":return n.stop()}}),n)})))()},checkVerifyLoginImage:function(){var e=this;return n(regeneratorRuntime.mark((function n(){return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(n.prev=0,!(e.code.length<4)){n.next=3;break}return n.abrupt("return");case 3:return n.next=5,w.post("".concat(e.isSuffix,"/open/verifyImgCode"),{requestType:"form",data:{phone:e.phone,code:e.code}});case 5:return console.log(_.clientId,_.platformType),n.next=8,w.post("".concat(e.isSuffix,"/open/sendSms"),{requestType:"form",data:{mobile:e.phone,type:"LOGIN",clientId:_.clientId[_.platformType]}});case 8:setTimeout((function(){C("验证码已发送")}),100),e.onClose(),e.onSendCode(),n.next=16;break;case 13:n.prev=13,n.t0=n.catch(0),e.updateIdentifyingCode();case 16:case"end":return n.stop()}}),n,null,[[0,13]])})))()}},render:function(){var e=this;return f(S,{show:this.showStatus,class:W,closeOnClickOverlay:!1,onClose:function(){e.onClose()},closeable:!0,closeIcon:"close"},{default:function(){return[f("div",{class:$},[f("p",{class:G},[b("输入图形验证码")]),f(U,null,{default:function(){return[f(E,{span:"14"},{default:function(){return[f(I,{placeholder:"请输入验证码",modelValue:e.code,"onUpdate:modelValue":function(n){return e.code=n},class:Q},null)]}}),f(E,{span:"10",class:J},{default:function(){return[f(k,{src:e.identifyingCode,onClick:function(){return e.updateIdentifyingCode()}},{loading:function(){return f(x,{type:"spinner",size:"20"},null)}})]}})]}}),f(U,{style:{display:"flex",justifyContent:"end"}},{default:function(){return[f(E,{span:"10"},{default:function(){return[f("span",{class:K,onClick:function(){return e.updateIdentifyingCode()}},[b("看不清?换一换")])]}})]}})])]}})}}))}}}))}();
|