index-legacy.a65a38da.js 6.4 KB

1
  1. !function(){function e(e,n,t,o,r,i,a){try{var c=e[i](a),u=c.value}catch(s){return void t(s)}c.done?n(u):Promise.resolve(u).then(o,r)}function n(n){return function(){var t=this,o=arguments;return new Promise((function(r,i){var a=n.apply(t,o);function c(n){e(a,r,i,c,u,"next",n)}function u(n){e(a,r,i,c,u,"throw",n)}c(void 0)}))}}function t(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 o,r,i=[],a=!0,c=!1;try{for(t=t.call(e);!(a=(o=t.next()).done)&&(i.push(o.value),!n||i.length!==n);a=!0);}catch(u){c=!0,r=u}finally{try{a||null==t.return||t.return()}finally{if(c)throw r}}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,o=new Array(n);t<n;t++)o[t]=e[t];return o}var r=document.createElement("style");r.innerHTML=":root{--van-count-down-text-color: var(--van-text-color);--van-count-down-font-size: var(--van-font-size-md);--van-count-down-line-height: var(--van-line-height-md)}.van-count-down{color:var(--van-count-down-text-color);font-size:var(--van-count-down-font-size);line-height:var(--van-count-down-line-height)}._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(r),System.register(["./index-legacy.b2528a15.js","./index-legacy.d3645f16.js","./index-legacy.ca42ae97.js","./index-legacy.207dc8c2.js","./index-legacy.ab501af1.js"],(function(e){"use strict";var o,r,i,a,c,u,s,l,d,m,f,p,g,h,y,v,_,w,C,S,x,b;return{setters:[function(e){o=e.aQ,r=e.E,i=e.ab,a=e.a0,c=e.H,u=e.d,s=e.aR,l=e.W,d=e.a3,m=e.ak,f=e.i,p=e.O,g=e.s,h=e.e,y=e.T,v=e.A,_=e.aS,w=e.aT},function(e){C=e.R,S=e.C},function(e){x=e.I},function(){},function(e){b=e.F}],execute:function(){var I=t(r("count-down"),2),k=I[0],T=I[1],j={time:i(0),format:a("HH:mm:ss"),autoStart:c,millisecond:Boolean},z=u({name:k,props:j,emits:["change","finish"],setup:function(e,n){var t=n.emit,r=n.slots,i=s({time:+e.time,millisecond:e.millisecond,onChange:function(e){return t("change",e)},onFinish:function(){return t("finish")}}),a=i.start,c=i.pause,u=i.reset,p=i.current,g=l((function(){return function(e,n){var t=n.days,r=n.hours,i=n.minutes,a=n.seconds,c=n.milliseconds;if(e.includes("DD")?e=e.replace("DD",o(t)):r+=24*t,e.includes("HH")?e=e.replace("HH",o(r)):i+=60*r,e.includes("mm")?e=e.replace("mm",o(i)):a+=60*i,e.includes("ss")?e=e.replace("ss",o(a)):c+=1e3*a,e.includes("S")){var u=o(c,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,p.value)})),h=function(){u(+e.time),e.autoStart&&a()};return d((function(){return e.time}),h,{immediate:!0}),m({start:a,pause:c,reset:h}),function(){return f("div",{role:"timer",class:T()},[r.default?r.default(p.value):g.value])}}}),A=(e("C",p(z)),"_imgCode_mywmt_1"),H="_codeTitle_mywmt_4",F="_img_mywmt_1",O="_imgChange_mywmt_16",R="_field_mywmt_23",D="_imgCodePopup_mywmt_27";e("I",u({name:"imgCode",props:{value:Boolean,phone:[String,Number],onClose:{type:Function,default:function(){}},onSendCode:{type:Function,default:function(){}}},data:function(){var e=window.location.origin,n="STUDENT"===g.platformType?"/api-student":"/api-teacher";return{isSuffix:n,showStatus:!1,identifyingCode:e+n+"/code/getImageCode?phone="+this.phone,code:null}},mounted:function(){this.showStatus=this.value},watch:{value:function(e){this.showStatus=e},code:function(e){e.length>=4&&this.checkVerifyLoginImage()}},methods:{updateIdentifyingCode:function(){var e=this;return n(regeneratorRuntime.mark((function n(){var t;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:t=window.location.origin,e.identifyingCode="".concat(t).concat(e.isSuffix,"/code/getImageCode?phone=").concat(e.phone,"&token=").concat(Math.random());case 2: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,h.post("".concat(e.isSuffix,"/code/verifyImageCode"),{requestType:"form",data:{phone:e.phone,code:e.code}});case 5:return n.next=7,h.post("".concat(e.isSuffix,"/code/sendSmsCode"),{requestType:"form",data:{mobile:e.phone,type:"LOGIN"}});case 7:y("验证码已发送"),e.onClose(),e.onSendCode(),n.next=15;break;case 12:n.prev=12,n.t0=n.catch(0),e.updateIdentifyingCode();case 15:case"end":return n.stop()}}),n,null,[[0,12]])})))()}},render:function(){var e=this;return f(w,{show:this.showStatus,class:D,closeOnClickOverlay:!1,onClose:function(){e.onClose()},closeable:!0,closeIcon:"close"},{default:function(){return[f("div",{class:A},[f("p",{class:H},[v("输入图形验证码")]),f(C,null,{default:function(){return[f(S,{span:"14"},{default:function(){return[f(b,{placeholder:"请输入验证码",modelValue:e.code,"onUpdate:modelValue":function(n){return e.code=n},class:R},null)]}}),f(S,{span:"10",class:F},{default:function(){return[f(x,{src:e.identifyingCode,onClick:function(){return e.updateIdentifyingCode()}},{loading:function(){return f(_,{type:"spinner",size:"20"},null)}})]}})]}}),f(C,{style:{display:"flex",justifyContent:"end"}},{default:function(){return[f(S,{span:"10"},{default:function(){return[f("span",{class:O,onClick:function(){return e.updateIdentifyingCode()}},[v("看不清?换一换")])]}})]}})])]}})}}))}}}))}();