You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
NewEduCoderBuild/layouts__index.8d342fd9.asy...

2 lines
65 KiB

(window.webpackJsonp=window.webpackJsonp||[]).push([[30,14],{"+ego":function(J,re,_){"use strict";_.r(re);var mt=_("GNNt"),Te=_("wEI+"),gt=_("T2oS"),Ce=_("W9HT"),vt=_("2qtc"),he=_("kLXV"),Ne=_("PpiC"),z=_("q1tI"),l=_.n(z),Se=_("+Gva"),K=_("9kvl"),Et=_("14J3"),Fe=_("BMrR"),_t=_("jCWc"),pe=_("kPKH"),yt=_("miYZ"),me=_("tsqr"),q=_("k1fw"),W=_("9og8"),Y=_("tJVT"),wt=_("Znn+"),Le=_("ZTPi"),bt=_("+L6B"),ae=_("2/Rp"),Pt=_("sRBo"),je=_("kaz8"),Lt=_("5NDa"),Q=_("5rEg"),Rt=_("y8nQ"),X=_("Vl3Y"),Z=_("jb+D"),Ae=_("4i/N"),ue=_("m3rI"),Be=_("Ty5D"),Ot=_("0zpY"),se=_("J66h");function ge(){"use strict";/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ge=function(){return f};var f={},g=Object.prototype,E=g.hasOwnProperty,b=typeof Symbol=="function"?Symbol:{},C=b.iterator||"@@iterator",O=b.asyncIterator||"@@asyncIterator",D=b.toStringTag||"@@toStringTag";function h(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{h({},"")}catch(t){h=function(r,n,a){return r[n]=a}}function I(t,e,r,n){var a=e&&e.prototype instanceof U?e:U,o=Object.create(a.prototype),u=new k(n||[]);return o._invoke=function(c,d,i){var s="suspendedStart";return function(p,V){if(s==="executing")throw new Error("Generator is already running");if(s==="completed"){if(p==="throw")throw V;return B()}for(i.method=p,i.arg=V;;){var P=i.delegate;if(P){var L=x(P,i);if(L){if(L===v)continue;return L}}if(i.method==="next")i.sent=i._sent=i.arg;else if(i.method==="throw"){if(s==="suspendedStart")throw s="completed",i.arg;i.dispatchException(i.arg)}else i.method==="return"&&i.abrupt("return",i.arg);s="executing";var M=j(c,d,i);if(M.type==="normal"){if(s=i.done?"completed":"suspendedYield",M.arg===v)continue;return{value:M.arg,done:i.done}}M.type==="throw"&&(s="completed",i.method="throw",i.arg=M.arg)}}}(t,r,u),o}function j(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(n){return{type:"throw",arg:n}}}f.wrap=I;var v={};function U(){}function y(){}function m(){}var A={};h(A,C,function(){return this});var S=Object.getPrototypeOf,T=S&&S(S(F([])));T&&T!==g&&E.call(T,C)&&(A=T);var w=m.prototype=U.prototype=Object.create(A);function G(t){["next","throw","return"].forEach(function(e){h(t,e,function(r){return this._invoke(e,r)})})}function N(t,e){function r(a,o,u,c){var d=j(t[a],t,o);if(d.type!=="throw"){var i=d.arg,s=i.value;return s&&typeof s=="object"&&E.call(s,"__await")?e.resolve(s.__await).then(function(p){r("next",p,u,c)},function(p){r("throw",p,u,c)}):e.resolve(s).then(function(p){i.value=p,u(i)},function(p){return r("throw",p,u,c)})}c(d.arg)}var n;this._invoke=function(a,o){function u(){return new e(function(c,d){r(a,o,c,d)})}return n=n?n.then(u,u):u()}}function x(t,e){var r=t.iterator[e.method];if(r===void 0){if(e.delegate=null,e.method==="throw"){if(t.iterator.return&&(e.method="return",e.arg=void 0,x(t,e),e.method==="throw"))return v;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return v}var n=j(r,t.iterator,e.arg);if(n.type==="throw")return e.method="throw",e.arg=n.arg,e.delegate=null,v;var a=n.arg;return a?a.done?(e[t.resultName]=a.value,e.next=t.nextLoc,e.method!=="return"&&(e.method="next",e.arg=void 0),e.delegate=null,v):a:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,v)}function $(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function R(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function k(t){this.tryEntries=[{tryLoc:"root"}],t.forEach($,this),this.reset(!0)}function F(t){if(t){var e=t[C];if(e)return e.call(t);if(typeof t.next=="function")return t;if(!isNaN(t.length)){var r=-1,n=function a(){for(;++r<t.length;)if(E.call(t,r))return a.value=t[r],a.done=!1,a;return a.value=void 0,a.done=!0,a};return n.next=n}}return{next:B}}function B(){return{value:void 0,done:!0}}return y.prototype=m,h(w,"constructor",m),h(m,"constructor",y),y.displayName=h(m,D,"GeneratorFunction"),f.isGeneratorFunction=function(t){var e=typeof t=="function"&&t.constructor;return!!e&&(e===y||(e.displayName||e.name)==="GeneratorFunction")},f.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,m):(t.__proto__=m,h(t,D,"GeneratorFunction")),t.prototype=Object.create(w),t},f.awrap=function(t){return{__await:t}},G(N.prototype),h(N.prototype,O,function(){return this}),f.AsyncIterator=N,f.async=function(t,e,r,n,a){a===void 0&&(a=Promise);var o=new N(I(t,e,r,n),a);return f.isGeneratorFunction(e)?o:o.next().then(function(u){return u.done?u.value:o.next()})},G(w),h(w,D,"Generator"),h(w,C,function(){return this}),h(w,"toString",function(){return"[object Generator]"}),f.keys=function(t){var e=[];for(var r in t)e.push(r);return e.reverse(),function n(){for(;e.length;){var a=e.pop();if(a in t)return n.value=a,n.done=!1,n}return n.done=!0,n}},f.values=F,k.prototype={constructor:k,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(R),!e)for(var r in this)r.charAt(0)==="t"&&E.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if(e.type==="throw")throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function n(i,s){return u.type="throw",u.arg=e,r.next=i,s&&(r.method="next",r.arg=void 0),!!s}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],u=o.completion;if(o.tryLoc==="root")return n("end");if(o.tryLoc<=this.prev){var c=E.call(o,"catchLoc"),d=E.call(o,"finallyLoc");if(c&&d){if(this.prev<o.catchLoc)return n(o.catchLoc,!0);if(this.prev<o.finallyLoc)return n(o.finallyLoc)}else if(c){if(this.prev<o.catchLoc)return n(o.catchLoc,!0)}else{if(!d)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return n(o.finallyLoc)}}}},abrupt:function(e,r){for(var n=this.tryEntries.length-1;n>=0;--n){var a=this.tryEntries[n];if(a.tryLoc<=this.prev&&E.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&(e==="break"||e==="continue")&&o.tryLoc<=r&&r<=o.finallyLoc&&(o=null);var u=o?o.completion:{};return u.type=e,u.arg=r,o?(this.method="next",this.next=o.finallyLoc,v):this.complete(u)},complete:function(e,r){if(e.type==="throw")throw e.arg;return e.type==="break"||e.type==="continue"?this.next=e.arg:e.type==="return"?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):e.type==="normal"&&r&&(this.next=r),v},finish:function(e){for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),R(n),v}},catch:function(e){for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r];if(n.tryLoc===e){var a=n.completion;if(a.type==="throw"){var o=a.arg;R(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:F(e),resultName:r,nextLoc:n},this.method==="next"&&(this.arg=void 0),v}},f}var le={height:48,borderRadius:4},De=function(g){var E=g.dispatch,b=g.setType,C=g.user,O=g.setusername,D=X.a.useForm(),h=Object(Y.a)(D,1),I=h[0],j=Object(Be.l)(),v=Object(z.useState)(""),U=Object(Y.a)(v,2),y=U[0],m=U[1],A=/^(?![\d]+$)(?![a-zA-Z]+$)(?![^\da-zA-Z]+$).{8,16}$/,S=Object(z.useState)(0),T=Object(Y.a)(S,2),w=T[0],G=T[1];Object(z.useEffect)(function(){I.resetFields()},[C.showPopLogin]);var N=Object(z.useMemo)(function(){return"/rucaptcha?t="+new Date().getTime()},[w]),x=function(){var R=Object(W.a)(ge().mark(function k(F){var B,t,e,r;return ge().wrap(function(a){for(;;)switch(a.prev=a.next){case 0:return A.test(F.password)||(O(F.login),m("\u7CFB\u7EDF\u68C0\u6D4B\u60A8\u7684\u5BC6\u7801\u5F3A\u5EA6\u8FC7\u4F4E\uFF0C\u8BF7\u53CA\u65F6\u4FEE\u6539")),F.password=se.Base64.encode(F.password),a.next=4,Object(Z.b)(F);case 4:if(B=a.sent,!B.status){a.next=9;break}return m(B==null?void 0:B.message),G(w+1),a.abrupt("return");case 9:(B==null?void 0:B.show)?(localStorage.setItem("extension-modal","exist"),localStorage.setItem("extension-date",B==null?void 0:B.start_date)):localStorage.removeItem("extension-modal"),console.log(K.c,"history"),j.pathname==="/user/login"||j.pathname==="/login"?(r=((t=j.query)===null||t===void 0?void 0:t.from)||((e=j.query)===null||e===void 0?void 0:e.back_url),r?window.location.href=decodeURIComponent(r):K.c.replace("/")):window.location.reload(),I.resetFields();case 13:case"end":return a.stop()}},k)}));return function(F){return R.apply(this,arguments)}}(),$=function(){E({type:"user/showPopLogin",payload:{showPopLogin:!1}})};return l.a.createElement(X.a,{layout:"vertical",form:I,initialValues:{autologin:!0,login:C.actionTabs.phone},onFinish:x,onValuesChange:function(){return m("")}},!!y&&l.a.createElement("div",{className:"res-error-values"},l.a.createElement("span",null,y),l.a.createElement(Ae.a,{onClick:function(){return m("")}})),l.a.createElement(X.a.Item,{name:"login",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u7528\u6237\u540D\u3001\u624B\u673A\u53F7\u6216\u90AE\u7BB1"}]},l.a.createElement(Q.a,{style:le,size:"large",placeholder:"\u8BF7\u8F93\u5165\u6709\u6548\u7684\u624B\u673A\u53F7/\u90AE\u7BB1\u53F7/\u8D26\u53F7",onBlur:function(){E({type:"user/setActionTabs",payload:{phone:I.getFieldValue("login")}})}})),l.a.createElement(X.a.Item,{name:"password",rules:[{required:!0,message:"\u8BF7\u8F93\u51658-16\u4F4D\u5BC6\u7801\uFF0C\u533A\u5206\u5927\u5C0F\u5199\u3001\u4E0D\u80FD\u4F7F\u7528\u7A7A\u683C"}]},l.a.createElement(Q.a.Password,{style:le,size:"large",placeholder:"\u5BC6\u7801"})),l.a.createElement(X.a.Item,null,l.a.createElement("div",{className:"flex-container",style:{justifyContent:"space-between"}},l.a.createElement(X.a.Item,{name:"autologin",noStyle:!0,valuePropName:"checked"},l.a.createElement(je.a,null,"\u4E0B\u6B21\u81EA\u52A8\u767B\u5F55")),l.a.createElement("div",null))),l.a.createElement(X.a.Item,{name:"code",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u9A8C\u8BC1\u7801"}]},l.a.createElement("div",{style:{display:"flex"}},l.a.createElement(Q.a,{style:le,size:"large",placeholder:"\u9A8C\u8BC1\u7801"}),l.a.createElement("img",{src:(ue.a===null||ue.a===void 0?void 0:ue.a.API_SERVER)+N,style:{height:"32px",marginLeft:"10px"},onClick:function(){G(w+1)}}))),l.a.createElement(X.a.Item,null,l.a.createElement(ae.a,{size:"large",type:"primary",htmlType:"submit",block:!0,className:"font16",style:le},"\u767B\u5F55")),l.a.createElement("div",{className:"tc",style:{paddingTop:0,paddingBottom:20}},"\u767B\u5F55\u5373\u4EE3\u8868\u60A8\u5DF2\u9605\u8BFB\u5E76\u540C\u610F",l.a.createElement("a",{href:"https://engineer.educoder.net/help?index=4",target:"_blank"},"\u300A\u670D\u52A1\u534F\u8BAE\u6761\u6B3E\u300B")))},ke=Object(K.a)(function(f){var g=f.user,E=f.loading,b=f.globalSetting;return{user:g,globalSetting:b,loading:E.models.index}})(De),Ut=_("5Dmo"),ce=_("3S7+"),H=_("1vsH");function ne(){"use strict";/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ne=function(){return f};var f={},g=Object.prototype,E=g.hasOwnProperty,b=typeof Symbol=="function"?Symbol:{},C=b.iterator||"@@iterator",O=b.asyncIterator||"@@asyncIterator",D=b.toStringTag||"@@toStringTag";function h(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{h({},"")}catch(t){h=function(r,n,a){return r[n]=a}}function I(t,e,r,n){var a=e&&e.prototype instanceof U?e:U,o=Object.create(a.prototype),u=new k(n||[]);return o._invoke=function(c,d,i){var s="suspendedStart";return function(p,V){if(s==="executing")throw new Error("Generator is already running");if(s==="completed"){if(p==="throw")throw V;return B()}for(i.method=p,i.arg=V;;){var P=i.delegate;if(P){var L=x(P,i);if(L){if(L===v)continue;return L}}if(i.method==="next")i.sent=i._sent=i.arg;else if(i.method==="throw"){if(s==="suspendedStart")throw s="completed",i.arg;i.dispatchException(i.arg)}else i.method==="return"&&i.abrupt("return",i.arg);s="executing";var M=j(c,d,i);if(M.type==="normal"){if(s=i.done?"completed":"suspendedYield",M.arg===v)continue;return{value:M.arg,done:i.done}}M.type==="throw"&&(s="completed",i.method="throw",i.arg=M.arg)}}}(t,r,u),o}function j(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(n){return{type:"throw",arg:n}}}f.wrap=I;var v={};function U(){}function y(){}function m(){}var A={};h(A,C,function(){return this});var S=Object.getPrototypeOf,T=S&&S(S(F([])));T&&T!==g&&E.call(T,C)&&(A=T);var w=m.prototype=U.prototype=Object.create(A);function G(t){["next","throw","return"].forEach(function(e){h(t,e,function(r){return this._invoke(e,r)})})}function N(t,e){function r(a,o,u,c){var d=j(t[a],t,o);if(d.type!=="throw"){var i=d.arg,s=i.value;return s&&typeof s=="object"&&E.call(s,"__await")?e.resolve(s.__await).then(function(p){r("next",p,u,c)},function(p){r("throw",p,u,c)}):e.resolve(s).then(function(p){i.value=p,u(i)},function(p){return r("throw",p,u,c)})}c(d.arg)}var n;this._invoke=function(a,o){function u(){return new e(function(c,d){r(a,o,c,d)})}return n=n?n.then(u,u):u()}}function x(t,e){var r=t.iterator[e.method];if(r===void 0){if(e.delegate=null,e.method==="throw"){if(t.iterator.return&&(e.method="return",e.arg=void 0,x(t,e),e.method==="throw"))return v;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return v}var n=j(r,t.iterator,e.arg);if(n.type==="throw")return e.method="throw",e.arg=n.arg,e.delegate=null,v;var a=n.arg;return a?a.done?(e[t.resultName]=a.value,e.next=t.nextLoc,e.method!=="return"&&(e.method="next",e.arg=void 0),e.delegate=null,v):a:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,v)}function $(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function R(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function k(t){this.tryEntries=[{tryLoc:"root"}],t.forEach($,this),this.reset(!0)}function F(t){if(t){var e=t[C];if(e)return e.call(t);if(typeof t.next=="function")return t;if(!isNaN(t.length)){var r=-1,n=function a(){for(;++r<t.length;)if(E.call(t,r))return a.value=t[r],a.done=!1,a;return a.value=void 0,a.done=!0,a};return n.next=n}}return{next:B}}function B(){return{value:void 0,done:!0}}return y.prototype=m,h(w,"constructor",m),h(m,"constructor",y),y.displayName=h(m,D,"GeneratorFunction"),f.isGeneratorFunction=function(t){var e=typeof t=="function"&&t.constructor;return!!e&&(e===y||(e.displayName||e.name)==="GeneratorFunction")},f.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,m):(t.__proto__=m,h(t,D,"GeneratorFunction")),t.prototype=Object.create(w),t},f.awrap=function(t){return{__await:t}},G(N.prototype),h(N.prototype,O,function(){return this}),f.AsyncIterator=N,f.async=function(t,e,r,n,a){a===void 0&&(a=Promise);var o=new N(I(t,e,r,n),a);return f.isGeneratorFunction(e)?o:o.next().then(function(u){return u.done?u.value:o.next()})},G(w),h(w,D,"Generator"),h(w,C,function(){return this}),h(w,"toString",function(){return"[object Generator]"}),f.keys=function(t){var e=[];for(var r in t)e.push(r);return e.reverse(),function n(){for(;e.length;){var a=e.pop();if(a in t)return n.value=a,n.done=!1,n}return n.done=!0,n}},f.values=F,k.prototype={constructor:k,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(R),!e)for(var r in this)r.charAt(0)==="t"&&E.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if(e.type==="throw")throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function n(i,s){return u.type="throw",u.arg=e,r.next=i,s&&(r.method="next",r.arg=void 0),!!s}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],u=o.completion;if(o.tryLoc==="root")return n("end");if(o.tryLoc<=this.prev){var c=E.call(o,"catchLoc"),d=E.call(o,"finallyLoc");if(c&&d){if(this.prev<o.catchLoc)return n(o.catchLoc,!0);if(this.prev<o.finallyLoc)return n(o.finallyLoc)}else if(c){if(this.prev<o.catchLoc)return n(o.catchLoc,!0)}else{if(!d)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return n(o.finallyLoc)}}}},abrupt:function(e,r){for(var n=this.tryEntries.length-1;n>=0;--n){var a=this.tryEntries[n];if(a.tryLoc<=this.prev&&E.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&(e==="break"||e==="continue")&&o.tryLoc<=r&&r<=o.finallyLoc&&(o=null);var u=o?o.completion:{};return u.type=e,u.arg=r,o?(this.method="next",this.next=o.finallyLoc,v):this.complete(u)},complete:function(e,r){if(e.type==="throw")throw e.arg;return e.type==="break"||e.type==="continue"?this.next=e.arg:e.type==="return"?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):e.type==="normal"&&r&&(this.next=r),v},finish:function(e){for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),R(n),v}},catch:function(e){for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r];if(n.tryLoc===e){var a=n.completion;if(a.type==="throw"){var o=a.arg;R(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:F(e),resultName:r,nextLoc:n},this.method==="next"&&(this.arg=void 0),v}},f}var ve={height:48},Re=/(\b[\w\.-]+@[\w\.-]+\.\w{2,4}\b)|(^(13[0-9]|14[01456879]|15[0-35-9]|16[2567]|17[0-8]|18[0-9]|19[0-35-9])\d{8}$)/i,Ie=/^(?![\d]+$)(?![a-zA-Z]+$)(?![^\da-zA-Z]+$).{8,16}$/,Ge={timer:0},oe;(function(f){f[f.setTimer=0]="setTimer"})(oe||(oe={}));function Me(f,g){switch(g.type){case oe.setTimer:return Object(q.a)(Object(q.a)({},f),{},{timer:g.payload});default:throw new Error}}var xe=function(g){var E,b=g.validateName,C=g.getCode,O=g.register,D=g.style,h=D===void 0?{}:D,I=g.buttonText,j=I===void 0?"\u6CE8\u518C":I,v=g.globalSetting,U=X.a.useForm(),y=Object(Y.a)(U,1),m=y[0],A=Object(z.useReducer)(Me,Ge),S=Object(Y.a)(A,2),T=S[0],w=S[1],G=Object(z.useState)(!1),N=Object(Y.a)(G,2),x=N[0],$=N[1],R=T.timer;function k(o){return F.apply(this,arguments)}function F(){return F=Object(W.a)(ne().mark(function o(u){var c,d,i,s,p,V;return ne().wrap(function(L){for(;;)switch(L.prev=L.next){case 0:return c=u.login,d=u.password,i=u.code,L.next=3,O({login:c,password:d,code:i});case 3:s=L.sent,p=s.message,V=s.status;debugger;if(!(V<0)){L.next=10;break}return m.setFields([{name:"code",errors:[p]}]),L.abrupt("return");case 10:window.location.reload();case 11:case"end":return L.stop()}},o)})),F.apply(this,arguments)}function B(){return t.apply(this,arguments)}function t(){return t=Object(W.a)(ne().mark(function o(){var u,c,d,i,s,p;return ne().wrap(function(P){for(;;)switch(P.prev=P.next){case 0:if(u=m.getFieldValue("login"),c=0,!(!Re.test(u)||u.indexOf(" ")>-1)){P.next=6;break}return m.setFields([{name:"login",errors:["\u8BF7\u8F93\u5165\u6B63\u786E\u7684\u624B\u673A\u53F7\u6216\u90AE\u7BB1"]}]),c=1,P.abrupt("return",c);case 6:return P.next=8,b({login:u,type:1});case 8:return d=P.sent,i=d.status,s=d.message,p=i>0,p?c=2:(m.setFields([{name:"login",errors:[s]}]),c=1),P.abrupt("return",c);case 14:case"end":return P.stop()}},o)})),t.apply(this,arguments)}var e=function(){var o=Object(W.a)(ne().mark(function u(){var c,d,i,s,p;return ne().wrap(function(P){for(;;)switch(P.prev=P.next){case 0:if(c=m.getFieldValue("verify"),d=m.getFieldValue("login"),d){P.next=6;break}m.validateFields(["login"]),P.next=15;break;case 6:return $(!0),P.next=9,C({login:d,type:1,smscode:Object(H.L)(d)});case 9:i=P.sent,s=i.status,p=i.message,s<0&&m.setFields([{name:"code",errors:[p]}]),w({type:oe.setTimer,payload:60}),$(!1);case 15:case"end":return P.stop()}},u)}));return function(){return o.apply(this,arguments)}}();function r(o,u){if(!u)return Promise.resolve();if(!Ie.test(u))return Promise.reject("\u8BF7\u8F93\u51658~16\u4F4D\u5B57\u7B26\uFF0C\u5B57\u6BCD\u3001\u6570\u5B57\u548C\u7279\u6B8A\u7B26\u53F7\u81F3\u5C11\u5305\u542B2\u79CD");if(u.indexOf(" ")>-1)return Promise.reject("\u8BF7\u8F93\u51658-16\u4F4D\u5BC6\u7801\uFF0C\u533A\u5206\u5927\u5C0F\u5199\u3001\u4E0D\u80FD\u4F7F\u7528\u7A7A\u683C");var c=u.length;return c>=8&&c<=16?Promise.resolve():Promise.reject("\u8BF7\u8F93\u51658-16\u4F4D\u5BC6\u7801\uFF0C\u533A\u5206\u5927\u5C0F\u5199\u3001\u4E0D\u80FD\u4F7F\u7528\u7A7A\u683C")}var n=function(u,c){return c?Promise.resolve():Promise.reject("\u8BF7\u62D6\u52A8\u6ED1\u5757\u9A8C\u8BC1")};Object(z.useEffect)(function(){R>0&&setTimeout(function(){w({type:oe.setTimer,payload:R-1})},1e3)},[R]);var a=function(u,c){return c?c.indexOf(" ")>-1?Promise.reject("\u8BF7\u8F93\u5165\u6B63\u786E\u7684\u624B\u673A\u53F7\u6216\u90AE\u7BB1"):Re.test(c)?Promise.resolve():Promise.reject("\u8BF7\u8F93\u5165\u6B63\u786E\u7684\u624B\u673A\u53F7\u6216\u90AE\u7BB1"):Promise.resolve()};return l.a.createElement(X.a,{layout:"vertical",form:m,style:h,initialValues:{autologin:!0,protool:!1},onFinish:k},l.a.createElement(X.a.Item,{name:"login",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u6B63\u786E\u7684\u624B\u673A\u53F7\u6216\u90AE\u7BB1"},{validator:a}]},l.a.createElement(Q.a,{style:ve,autoComplete:"new-login",size:"large",placeholder:"\u8BF7\u8F93\u5165\u6709\u6548\u7684\u624B\u673A\u53F7/\u90AE\u7BB1\u53F7",onBlur:function(){return B},onChange:function(){return m.setFieldsValue({verify:0})}})),!(v==null||((E=v.setting)===null||E===void 0)?void 0:E.is_local)&&l.a.createElement(X.a.Item,{name:"code",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u9A8C\u8BC1\u7801"}]},l.a.createElement(Q.a,{suffix:l.a.createElement(ae.a,{loading:x,type:"link",onClick:e,disabled:R>0}," ",R===0?"\u83B7\u53D6\u9A8C\u8BC1\u7801":"".concat(R,"\u79D2\u53EF\u91CD\u65B0\u83B7\u53D6")),style:{paddingRight:2,height:48},placeholder:"\u8BF7\u8F93\u5165\u9A8C\u8BC1\u7801",size:"large"})),l.a.createElement(ce.a,{title:l.a.createElement("div",null,l.a.createElement("span",null,"\u957F\u5EA6\u4E3A8-16\u4F4D\u5B57\u7B26"),l.a.createElement("br",null),l.a.createElement("span",null,"\u5B57\u6BCD/\u6570\u5B57\u4EE5\u53CA\u6807\u70B9\u7B26\u53F7\u81F3\u5C11\u5305\u542B2\u79CD"),l.a.createElement("br",null),l.a.createElement("span",null,"\u4E0D\u5141\u8BB8\u6709\u7A7A\u683C\u3001\u4E2D\u6587")),placement:"topRight"},l.a.createElement(X.a.Item,{name:"password",rules:[{required:!0,message:"\u8BF7\u8F93\u51658-16\u4F4D\u5BC6\u7801\uFF0C\u533A\u5206\u5927\u5C0F\u5199\u3001\u4E0D\u80FD\u4F7F\u7528\u7A7A\u683C"},{validator:r}]},l.a.createElement(Q.a.Password,{autoComplete:"new-password",style:ve,size:"large",placeholder:"\u8BF7\u8F93\u51658~16\u4F4D\u5B57\u7B26\uFF0C\u5B57\u6BCD\u3001\u6570\u5B57\u548C\u7279\u6B8A\u7B26\u53F7\u81F3\u5C11\u5305\u542B2\u79CD"}))),l.a.createElement(X.a.Item,null,l.a.createElement(ae.a,{size:"large",type:"primary",htmlType:"submit",block:!0,style:ve,className:"font16"}," ",j," ")),l.a.createElement("div",{className:"tc",style:{paddingTop:0,paddingBottom:35}},"\u6CE8\u518C\u5E76\u767B\u5F55\u5373\u4EE3\u8868\u60A8\u5DF2\u9605\u8BFB\u5E76\u540C\u610F",l.a.createElement("a",{href:"https://engineer.educoder.net/help?index=4",target:"_blank"},"\u300A\u670D\u52A1\u534F\u8BAE\u6761\u6B3E\u300B")))},Ve=Object(K.a)(function(f){var g=f.globalSetting;return{globalSetting:g}})(xe);function ee(){"use strict";/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ee=function(){return f};var f={},g=Object.prototype,E=g.hasOwnProperty,b=typeof Symbol=="function"?Symbol:{},C=b.iterator||"@@iterator",O=b.asyncIterator||"@@asyncIterator",D=b.toStringTag||"@@toStringTag";function h(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{h({},"")}catch(t){h=function(r,n,a){return r[n]=a}}function I(t,e,r,n){var a=e&&e.prototype instanceof U?e:U,o=Object.create(a.prototype),u=new k(n||[]);return o._invoke=function(c,d,i){var s="suspendedStart";return function(p,V){if(s==="executing")throw new Error("Generator is already running");if(s==="completed"){if(p==="throw")throw V;return B()}for(i.method=p,i.arg=V;;){var P=i.delegate;if(P){var L=x(P,i);if(L){if(L===v)continue;return L}}if(i.method==="next")i.sent=i._sent=i.arg;else if(i.method==="throw"){if(s==="suspendedStart")throw s="completed",i.arg;i.dispatchException(i.arg)}else i.method==="return"&&i.abrupt("return",i.arg);s="executing";var M=j(c,d,i);if(M.type==="normal"){if(s=i.done?"completed":"suspendedYield",M.arg===v)continue;return{value:M.arg,done:i.done}}M.type==="throw"&&(s="completed",i.method="throw",i.arg=M.arg)}}}(t,r,u),o}function j(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(n){return{type:"throw",arg:n}}}f.wrap=I;var v={};function U(){}function y(){}function m(){}var A={};h(A,C,function(){return this});var S=Object.getPrototypeOf,T=S&&S(S(F([])));T&&T!==g&&E.call(T,C)&&(A=T);var w=m.prototype=U.prototype=Object.create(A);function G(t){["next","throw","return"].forEach(function(e){h(t,e,function(r){return this._invoke(e,r)})})}function N(t,e){function r(a,o,u,c){var d=j(t[a],t,o);if(d.type!=="throw"){var i=d.arg,s=i.value;return s&&typeof s=="object"&&E.call(s,"__await")?e.resolve(s.__await).then(function(p){r("next",p,u,c)},function(p){r("throw",p,u,c)}):e.resolve(s).then(function(p){i.value=p,u(i)},function(p){return r("throw",p,u,c)})}c(d.arg)}var n;this._invoke=function(a,o){function u(){return new e(function(c,d){r(a,o,c,d)})}return n=n?n.then(u,u):u()}}function x(t,e){var r=t.iterator[e.method];if(r===void 0){if(e.delegate=null,e.method==="throw"){if(t.iterator.return&&(e.method="return",e.arg=void 0,x(t,e),e.method==="throw"))return v;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return v}var n=j(r,t.iterator,e.arg);if(n.type==="throw")return e.method="throw",e.arg=n.arg,e.delegate=null,v;var a=n.arg;return a?a.done?(e[t.resultName]=a.value,e.next=t.nextLoc,e.method!=="return"&&(e.method="next",e.arg=void 0),e.delegate=null,v):a:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,v)}function $(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function R(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function k(t){this.tryEntries=[{tryLoc:"root"}],t.forEach($,this),this.reset(!0)}function F(t){if(t){var e=t[C];if(e)return e.call(t);if(typeof t.next=="function")return t;if(!isNaN(t.length)){var r=-1,n=function a(){for(;++r<t.length;)if(E.call(t,r))return a.value=t[r],a.done=!1,a;return a.value=void 0,a.done=!0,a};return n.next=n}}return{next:B}}function B(){return{value:void 0,done:!0}}return y.prototype=m,h(w,"constructor",m),h(m,"constructor",y),y.displayName=h(m,D,"GeneratorFunction"),f.isGeneratorFunction=function(t){var e=typeof t=="function"&&t.constructor;return!!e&&(e===y||(e.displayName||e.name)==="GeneratorFunction")},f.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,m):(t.__proto__=m,h(t,D,"GeneratorFunction")),t.prototype=Object.create(w),t},f.awrap=function(t){return{__await:t}},G(N.prototype),h(N.prototype,O,function(){return this}),f.AsyncIterator=N,f.async=function(t,e,r,n,a){a===void 0&&(a=Promise);var o=new N(I(t,e,r,n),a);return f.isGeneratorFunction(e)?o:o.next().then(function(u){return u.done?u.value:o.next()})},G(w),h(w,D,"Generator"),h(w,C,function(){return this}),h(w,"toString",function(){return"[object Generator]"}),f.keys=function(t){var e=[];for(var r in t)e.push(r);return e.reverse(),function n(){for(;e.length;){var a=e.pop();if(a in t)return n.value=a,n.done=!1,n}return n.done=!0,n}},f.values=F,k.prototype={constructor:k,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(R),!e)for(var r in this)r.charAt(0)==="t"&&E.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if(e.type==="throw")throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function n(i,s){return u.type="throw",u.arg=e,r.next=i,s&&(r.method="next",r.arg=void 0),!!s}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],u=o.completion;if(o.tryLoc==="root")return n("end");if(o.tryLoc<=this.prev){var c=E.call(o,"catchLoc"),d=E.call(o,"finallyLoc");if(c&&d){if(this.prev<o.catchLoc)return n(o.catchLoc,!0);if(this.prev<o.finallyLoc)return n(o.finallyLoc)}else if(c){if(this.prev<o.catchLoc)return n(o.catchLoc,!0)}else{if(!d)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return n(o.finallyLoc)}}}},abrupt:function(e,r){for(var n=this.tryEntries.length-1;n>=0;--n){var a=this.tryEntries[n];if(a.tryLoc<=this.prev&&E.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&(e==="break"||e==="continue")&&o.tryLoc<=r&&r<=o.finallyLoc&&(o=null);var u=o?o.completion:{};return u.type=e,u.arg=r,o?(this.method="next",this.next=o.finallyLoc,v):this.complete(u)},complete:function(e,r){if(e.type==="throw")throw e.arg;return e.type==="break"||e.type==="continue"?this.next=e.arg:e.type==="return"?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):e.type==="normal"&&r&&(this.next=r),v},finish:function(e){for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),R(n),v}},catch:function(e){for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r];if(n.tryLoc===e){var a=n.completion;if(a.type==="throw"){var o=a.arg;R(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:F(e),resultName:r,nextLoc:n},this.method==="next"&&(this.arg=void 0),v}},f}var Ee={height:48},Oe=/(\b[\w\.-]+@[\w\.-]+\.\w{2,4}\b)|(^(13[0-9]|14[01456879]|15[0-35-9]|16[2567]|17[0-8]|18[0-9]|19[0-35-9])\d{8}$)/i,Xe=/^(?![\d]+$)(?![a-zA-Z]+$)(?![^\da-zA-Z]+$).{8,16}$/,$e={timer:0},ie;(function(f){f[f.setTimer=0]="setTimer"})(ie||(ie={}));function ze(f,g){switch(g.type){case ie.setTimer:return Object(q.a)(Object(q.a)({},f),{},{timer:g.payload});default:throw new Error}}var Ye=function(g){var E,b=g.validateName,C=g.getCode,O=g.register,D=g.style,h=D===void 0?{}:D,I=g.buttonText,j=I===void 0?"\u6CE8\u518C":I,v=g.globalSetting,U=X.a.useForm(),y=Object(Y.a)(U,1),m=y[0],A=Object(z.useReducer)(ze,$e),S=Object(Y.a)(A,2),T=S[0],w=S[1],G=Object(z.useState)(!1),N=Object(Y.a)(G,2),x=N[0],$=N[1],R=T.timer;function k(o){return F.apply(this,arguments)}function F(){return F=Object(W.a)(ee().mark(function o(u){var c,d,i,s,p,V;return ee().wrap(function(L){for(;;)switch(L.prev=L.next){case 0:return c=u.login,d=u.new_password,i=u.code,u.new_password=se.Base64.encode(u.new_password),L.next=4,O({login:c,new_password:d,code:i});case 4:if(s=L.sent,p=s.message,V=s.status,!(V<0)){L.next=10;break}return m.setFields([{name:"code",errors:[p]}]),L.abrupt("return");case 10:location.reload();case 11:case"end":return L.stop()}},o)})),F.apply(this,arguments)}function B(){return t.apply(this,arguments)}function t(){return t=Object(W.a)(ee().mark(function o(){var u,c,d,i,s,p;return ee().wrap(function(P){for(;;)switch(P.prev=P.next){case 0:if(u=m.getFieldValue("login"),c=0,!(!Oe.test(u)||u.indexOf(" ")>-1)){P.next=6;break}return m.setFields([{name:"login",errors:["\u8BF7\u8F93\u5165\u6B63\u786E\u7684\u624B\u673A\u53F7\u6216\u90AE\u7BB1"]}]),c=1,P.abrupt("return",c);case 6:return P.next=8,b({login:u,type:2});case 8:return d=P.sent,i=d.status,s=d.message,p=i>0,p?c=2:(m.setFields([{name:"login",errors:[s]}]),c=1),P.abrupt("return",c);case 14:case"end":return P.stop()}},o)})),t.apply(this,arguments)}var e=function(){var o=Object(W.a)(ee().mark(function u(){var c,d,i,s,p;return ee().wrap(function(P){for(;;)switch(P.prev=P.next){case 0:return c=m.getFieldValue("verify"),d=m.getFieldValue("login"),P.next=4,m.validateFields(["login"]);case 4:if(d){P.next=8;break}m.validateFields(["login"]),P.next=17;break;case 8:return $(!0),P.next=11,C({login:d,type:2,smscode:Object(H.L)(d)});case 11:i=P.sent,s=i.status,p=i.message,s<0&&m.setFields([{name:"code",errors:[p]}]),w({type:ie.setTimer,payload:60}),$(!1);case 17:case"end":return P.stop()}},u)}));return function(){return o.apply(this,arguments)}}();function r(o,u){if(!u)return Promise.resolve();if(!Xe.test(u))return Promise.reject("\u8BF7\u8F93\u51658~16\u4F4D\u5B57\u7B26\uFF0C\u5B57\u6BCD\u3001\u6570\u5B57\u548C\u7279\u6B8A\u7B26\u53F7\u81F3\u5C11\u5305\u542B2\u79CD");if(u.indexOf(" ")>-1)return Promise.reject("\u8BF7\u8F93\u51658-16\u4F4D\u65B0\u5BC6\u7801\uFF0C\u533A\u5206\u5927\u5C0F\u5199\u3001\u4E0D\u80FD\u4F7F\u7528\u7A7A\u683C");var c=u.length;return c>=8&&c<=16?Promise.resolve():Promise.reject("\u8BF7\u8F93\u51658-16\u4F4D\u65B0\u5BC6\u7801\uFF0C\u533A\u5206\u5927\u5C0F\u5199\u3001\u4E0D\u80FD\u4F7F\u7528\u7A7A\u683C")}var n=function(u,c){return c?Promise.resolve():Promise.reject("\u8BF7\u62D6\u52A8\u6ED1\u5757\u9A8C\u8BC1")};Object(z.useEffect)(function(){R>0&&setTimeout(function(){w({type:ie.setTimer,payload:R-1})},1e3)},[R]);var a=function(){var o=Object(W.a)(ee().mark(function u(c,d){var i,s,p,V;return ee().wrap(function(L){for(;;)switch(L.prev=L.next){case 0:if(d){L.next=2;break}return L.abrupt("return",Promise.resolve());case 2:if(!(d.indexOf(" ")>-1)){L.next=4;break}return L.abrupt("return",Promise.reject("\u8BF7\u8F93\u5165\u6B63\u786E\u7684\u624B\u673A\u53F7\u6216\u90AE\u7BB1"));case 4:if(!Oe.test(d)){L.next=18;break}return L.next=7,b({login:d,type:2});case 7:if(i=L.sent,s=i.status,p=i.message,V=s>0,!V){L.next=15;break}return L.abrupt("return",Promise.resolve());case 15:return L.abrupt("return",Promise.reject(p));case 16:L.next=19;break;case 18:return L.abrupt("return",Promise.reject("\u8BF7\u8F93\u5165\u6B63\u786E\u7684\u624B\u673A\u53F7\u6216\u90AE\u7BB1"));case 19:case"end":return L.stop()}},u)}));return function(c,d){return o.apply(this,arguments)}}();return l.a.createElement(X.a,{layout:"vertical",form:m,style:h,initialValues:{autologin:!0,protool:!1},onFinish:k},l.a.createElement(X.a.Item,{name:"login",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u6B63\u786E\u7684\u624B\u673A\u53F7\u6216\u90AE\u7BB1"},{validator:a}]},l.a.createElement(Q.a,{style:Ee,autoComplete:"new-login",size:"large",placeholder:"\u8BF7\u8F93\u5165\u6709\u6548\u7684\u624B\u673A\u53F7/\u90AE\u7BB1\u53F7",onChange:function(){return m.setFieldsValue({verify:0})}})),l.a.createElement(ce.a,{title:l.a.createElement("div",null,l.a.createElement("span",null,"\u957F\u5EA6\u4E3A8-16\u4F4D\u5B57\u7B26"),l.a.createElement("br",null),l.a.createElement("span",null,"\u5B57\u6BCD/\u6570\u5B57\u4EE5\u53CA\u6807\u70B9\u7B26\u53F7\u81F3\u5C11\u5305\u542B2\u79CD"),l.a.createElement("br",null),l.a.createElement("span",null,"\u4E0D\u5141\u8BB8\u6709\u7A7A\u683C\u3001\u4E2D\u6587")),placement:"topRight"},l.a.createElement(X.a.Item,{name:"new_password",rules:[{required:!0,message:"\u8BF7\u8F93\u51658-16\u4F4D\u65B0\u5BC6\u7801\uFF0C\u533A\u5206\u5927\u5C0F\u5199\u3001\u4E0D\u80FD\u4F7F\u7528\u7A7A\u683C"},{validator:r}]},l.a.createElement(Q.a.Password,{autoComplete:"new-password",style:Ee,size:"large",placeholder:"\u8F93\u51658\uFF5E16\u4F4D\u65B0\u5BC6\u7801\uFF0C\u533A\u5206\u5927\u5C0F\u5199"}))),!(v==null||((E=v.setting)===null||E===void 0)?void 0:E.is_local)&&l.a.createElement(X.a.Item,{name:"code",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u9A8C\u8BC1\u7801"}]},l.a.createElement(Q.a,{suffix:l.a.createElement(ae.a,{loading:x,type:"link",onClick:e,disabled:R>0}," ",R===0?"\u83B7\u53D6\u9A8C\u8BC1\u7801":"".concat(R,"\u79D2\u53EF\u91CD\u65B0\u83B7\u53D6")),style:{paddingRight:2,height:48},placeholder:"\u8BF7\u8F93\u5165\u9A8C\u8BC1\u7801",size:"large"})),l.a.createElement(X.a.Item,null,l.a.createElement(ae.a,{size:"large",type:"primary",htmlType:"submit",block:!0,style:Ee,className:"font16"}," ",j," ")),l.a.createElement("div",{className:"tc",style:{paddingTop:0,paddingBottom:20}},"\u4FEE\u6539\u5E76\u767B\u5F55\u5373\u4EE3\u8868\u60A8\u5DF2\u9605\u8BFB\u5E76\u540C\u610F",l.a.createElement("a",{href:"https://engineer.educoder.net/help?index=4",target:"_blank"},"\u300A\u670D\u52A1\u534F\u8BAE\u6761\u6B3E\u300B")))},We=Object(K.a)(function(f){var g=f.globalSetting;return{globalSetting:g}})(Ye),Ze=_("h0ge"),Qe=_.n(Ze),Je=_("/nL+"),He=_.n(Je),Ke=_("IxGP"),_e=_.n(Ke),ye=window.location.host,we=ue.a.QQLoginCB,qe=function(f){var g=f.onWechatLogin,E=f.setType,b=f.loginType;function C(){Object(H.E)()?window.location.href="https://graph.qq.com/oauth2.0/show?which=Login&display=pc&client_id=101508858&redirect_uri=".concat(we,"%2fotherloginqq&state=null,").concat(ye,"&response_type=code"):Object(H.I)("https://xui.ptlogin2.qq.com/cgi-bin/xlogin?appid=716027609&pt_3rd_aid=101508858&daid=383&pt_skey_valid=0&style=35&s_url=http%3A%2F%2Fconnect.qq.com&refer_cgi=authorize&which=&client_id=101508858&response_type=code&scope=get_user_info&redirect_uri=".concat(we,"%2fotherloginqq&state=null,").concat(ye,"&response_type=code"))}return l.a.createElement(l.a.Fragment,null,(b===1||b===2)&&l.a.createElement("div",{style:{marginTop:b===4?20:92,marginBottom:60},className:"font16 tc"},"\u6CA1\u6709\u8D26\u53F7\uFF1F",l.a.createElement("span",{onClick:function(){return E(3)},className:"c-blue current"},"\u514D\u8D39\u6CE8\u518C")),(b===3||b===4||b===5)&&l.a.createElement("div",{style:{marginTop:92,marginBottom:60},className:"font16 tc"},"\u5DF2\u6709\u8D26\u53F7\uFF1F",l.a.createElement("span",{onClick:function(){return E(1)},className:"c-blue current"},"\u7ACB\u5373\u767B\u5F55")),l.a.createElement("p",{className:_e.a.driver},l.a.createElement("span",{style:{color:"#444444"}},"\u5FEB\u901F\u767B\u5F55")),l.a.createElement("div",{className:_e.a["other-login"]},l.a.createElement("a",{title:"\u5FAE\u4FE1\u767B\u5F55",onClick:g},l.a.createElement("img",{src:Qe.a,alt:"\u5FAE\u4FE1",width:66})),l.a.createElement("a",{title:"qq\u767B\u5F55",onClick:C},l.a.createElement("img",{src:He.a,alt:"QQ",width:66}))))};function et(f){var g=f.onBack,E=f.setType;return l.a.createElement(l.a.Fragment,null,l.a.createElement("div",{style:{overflow:"hidden",width:300,height:300,margin:"20px auto 0 auto"}},l.a.createElement("iframe",{className:_e.a["wechat-qrcode"],frameBorder:"0",sandbox:"allow-scripts allow-same-origin allow-top-navigation",scrolling:"no",src:"https://open.weixin.qq.com/connect/qrconnect?appid=wx6b119e2d829c13fa&redirect_uri=".concat(we,"%2fotherloginstart&response_type=code&scope=snsapi_login&state=null,").concat(ye,"#wechat_redirect")})),l.a.createElement("div",{style:{marginTop:17,marginBottom:10},className:"font16 bold tc c-blue current"},l.a.createElement("span",{onClick:function(){return E(1)},style:{borderBottom:"2px solid #1890FF"}},"\u8FD4\u56DE\u8D26\u53F7\u767B\u5F55")),l.a.createElement("div",{className:"tc",style:{paddingTop:14,paddingBottom:40}},"\u767B\u5F55\u5373\u4EE3\u8868\u60A8\u5DF2\u9605\u8BFB\u5E76\u540C\u610F",l.a.createElement("a",{href:"https://engineer.educoder.net/help?index=4",target:"_blank"},"\u300A\u670D\u52A1\u534F\u8BAE\u6761\u6B3E\u300B")))}function be(){"use strict";/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */be=function(){return f};var f={},g=Object.prototype,E=g.hasOwnProperty,b=typeof Symbol=="function"?Symbol:{},C=b.iterator||"@@iterator",O=b.asyncIterator||"@@asyncIterator",D=b.toStringTag||"@@toStringTag";function h(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{h({},"")}catch(t){h=function(r,n,a){return r[n]=a}}function I(t,e,r,n){var a=e&&e.prototype instanceof U?e:U,o=Object.create(a.prototype),u=new k(n||[]);return o._invoke=function(c,d,i){var s="suspendedStart";return function(p,V){if(s==="executing")throw new Error("Generator is already running");if(s==="completed"){if(p==="throw")throw V;return B()}for(i.method=p,i.arg=V;;){var P=i.delegate;if(P){var L=x(P,i);if(L){if(L===v)continue;return L}}if(i.method==="next")i.sent=i._sent=i.arg;else if(i.method==="throw"){if(s==="suspendedStart")throw s="completed",i.arg;i.dispatchException(i.arg)}else i.method==="return"&&i.abrupt("return",i.arg);s="executing";var M=j(c,d,i);if(M.type==="normal"){if(s=i.done?"completed":"suspendedYield",M.arg===v)continue;return{value:M.arg,done:i.done}}M.type==="throw"&&(s="completed",i.method="throw",i.arg=M.arg)}}}(t,r,u),o}function j(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(n){return{type:"throw",arg:n}}}f.wrap=I;var v={};function U(){}function y(){}function m(){}var A={};h(A,C,function(){return this});var S=Object.getPrototypeOf,T=S&&S(S(F([])));T&&T!==g&&E.call(T,C)&&(A=T);var w=m.prototype=U.prototype=Object.create(A);function G(t){["next","throw","return"].forEach(function(e){h(t,e,function(r){return this._invoke(e,r)})})}function N(t,e){function r(a,o,u,c){var d=j(t[a],t,o);if(d.type!=="throw"){var i=d.arg,s=i.value;return s&&typeof s=="object"&&E.call(s,"__await")?e.resolve(s.__await).then(function(p){r("next",p,u,c)},function(p){r("throw",p,u,c)}):e.resolve(s).then(function(p){i.value=p,u(i)},function(p){return r("throw",p,u,c)})}c(d.arg)}var n;this._invoke=function(a,o){function u(){return new e(function(c,d){r(a,o,c,d)})}return n=n?n.then(u,u):u()}}function x(t,e){var r=t.iterator[e.method];if(r===void 0){if(e.delegate=null,e.method==="throw"){if(t.iterator.return&&(e.method="return",e.arg=void 0,x(t,e),e.method==="throw"))return v;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return v}var n=j(r,t.iterator,e.arg);if(n.type==="throw")return e.method="throw",e.arg=n.arg,e.delegate=null,v;var a=n.arg;return a?a.done?(e[t.resultName]=a.value,e.next=t.nextLoc,e.method!=="return"&&(e.method="next",e.arg=void 0),e.delegate=null,v):a:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,v)}function $(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function R(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function k(t){this.tryEntries=[{tryLoc:"root"}],t.forEach($,this),this.reset(!0)}function F(t){if(t){var e=t[C];if(e)return e.call(t);if(typeof t.next=="function")return t;if(!isNaN(t.length)){var r=-1,n=function a(){for(;++r<t.length;)if(E.call(t,r))return a.value=t[r],a.done=!1,a;return a.value=void 0,a.done=!0,a};return n.next=n}}return{next:B}}function B(){return{value:void 0,done:!0}}return y.prototype=m,h(w,"constructor",m),h(m,"constructor",y),y.displayName=h(m,D,"GeneratorFunction"),f.isGeneratorFunction=function(t){var e=typeof t=="function"&&t.constructor;return!!e&&(e===y||(e.displayName||e.name)==="GeneratorFunction")},f.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,m):(t.__proto__=m,h(t,D,"GeneratorFunction")),t.prototype=Object.create(w),t},f.awrap=function(t){return{__await:t}},G(N.prototype),h(N.prototype,O,function(){return this}),f.AsyncIterator=N,f.async=function(t,e,r,n,a){a===void 0&&(a=Promise);var o=new N(I(t,e,r,n),a);return f.isGeneratorFunction(e)?o:o.next().then(function(u){return u.done?u.value:o.next()})},G(w),h(w,D,"Generator"),h(w,C,function(){return this}),h(w,"toString",function(){return"[object Generator]"}),f.keys=function(t){var e=[];for(var r in t)e.push(r);return e.reverse(),function n(){for(;e.length;){var a=e.pop();if(a in t)return n.value=a,n.done=!1,n}return n.done=!0,n}},f.values=F,k.prototype={constructor:k,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(R),!e)for(var r in this)r.charAt(0)==="t"&&E.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if(e.type==="throw")throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function n(i,s){return u.type="throw",u.arg=e,r.next=i,s&&(r.method="next",r.arg=void 0),!!s}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],u=o.completion;if(o.tryLoc==="root")return n("end");if(o.tryLoc<=this.prev){var c=E.call(o,"catchLoc"),d=E.call(o,"finallyLoc");if(c&&d){if(this.prev<o.catchLoc)return n(o.catchLoc,!0);if(this.prev<o.finallyLoc)return n(o.finallyLoc)}else if(c){if(this.prev<o.catchLoc)return n(o.catchLoc,!0)}else{if(!d)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return n(o.finallyLoc)}}}},abrupt:function(e,r){for(var n=this.tryEntries.length-1;n>=0;--n){var a=this.tryEntries[n];if(a.tryLoc<=this.prev&&E.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&(e==="break"||e==="continue")&&o.tryLoc<=r&&r<=o.finallyLoc&&(o=null);var u=o?o.completion:{};return u.type=e,u.arg=r,o?(this.method="next",this.next=o.finallyLoc,v):this.complete(u)},complete:function(e,r){if(e.type==="throw")throw e.arg;return e.type==="break"||e.type==="continue"?this.next=e.arg:e.type==="return"?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):e.type==="normal"&&r&&(this.next=r),v},finish:function(e){for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),R(n),v}},catch:function(e){for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r];if(n.tryLoc===e){var a=n.completion;if(a.type==="throw"){var o=a.arg;R(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:F(e),resultName:r,nextLoc:n},this.method==="next"&&(this.arg=void 0),v}},f}var de={height:48},Tt=/(\b[\w\.-]+@[\w\.-]+\.\w{2,4}\b)|(^(13[0-9]|14[01456879]|15[0-35-9]|16[2567]|17[0-8]|18[0-9]|19[0-35-9])\d{8}$)/i,tt=/^(?![\d]+$)(?![a-zA-Z]+$)(?![^\da-zA-Z]+$).{8,16}$/,rt={timer:0},fe;(function(f){f[f.setTimer=0]="setTimer"})(fe||(fe={}));function nt(f,g){switch(g.type){case fe.setTimer:return Object(q.a)(Object(q.a)({},f),{},{timer:g.payload});default:throw new Error}}var at=function(g){var E=g.validateName,b=g.getCode,C=g.register,O=g.style,D=O===void 0?{}:O,h=g.buttonText,I=h===void 0?"\u6CE8\u518C":h,j=g.globalSetting,v=X.a.useForm(),U=Object(Y.a)(v,1),y=U[0],m=Object(z.useReducer)(nt,rt),A=Object(Y.a)(m,2),S=A[0],T=A[1],w=Object(z.useState)(!1),G=Object(Y.a)(w,2),N=G[0],x=G[1],$=S.timer;function R(B){return k.apply(this,arguments)}function k(){return k=Object(W.a)(be().mark(function B(t){var e,r,n,a,o;return be().wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return e=t.old_password,r=t.newPassword,c.next=3,C({old_password:e,newPassword:r});case 3:if(n=c.sent,a=n.message,o=n.status,!(o<0)){c.next=9;break}return y.setFields([{name:"code",errors:[a]}]),c.abrupt("return");case 9:case"end":return c.stop()}},B)})),k.apply(this,arguments)}var F=function(t,e,r){e?e.indexOf(" ")>-1?r("\u8BF7\u8F93\u51658-16\u4F4D\u5BC6\u7801\uFF0C\u533A\u5206\u5927\u5C0F\u5199\u3001\u4E0D\u80FD\u4F7F\u7528\u7A7A\u683C"):e.length<8||e.length>16?r("\u8BF7\u8F93\u51658-16\u4F4D\u5B57\u7B26\u7684\u65B0\u5BC6\u7801\uFF0C\u533A\u5206\u5927\u5C0F\u5199\uFF01"):tt.test(e)?r():r("\u8BF7\u8F93\u51658~16\u4F4D\u5B57\u7B26\uFF0C\u5B57\u6BCD\u3001\u6570\u5B57\u548C\u7279\u6B8A\u7B26\u53F7\u81F3\u5C11\u5305\u542B2\u79CD"):r("\u8BF7\u8F93\u51658-16\u4F4D\u5B57\u7B26\u7684\u65B0\u5BC6\u7801\uFF0C\u533A\u5206\u5927\u5C0F\u5199\uFF01")};return Object(z.useEffect)(function(){$>0&&setTimeout(function(){T({type:fe.setTimer,payload:$-1})},1e3)},[$]),l.a.createElement(X.a,{layout:"vertical",form:y,style:D,initialValues:{autologin:!0,protool:!1},onFinish:R},l.a.createElement(X.a.Item,{name:"old_password",rules:[{required:!0,message:"\u8BF7\u8F93\u51658\uFF5E16\u4F4D\u5BC6\u7801\uFF0C\u533A\u5206\u5927\u5C0F\u5199"}]},l.a.createElement(Q.a,{style:de,autoComplete:"new-login",size:"large",type:"password",placeholder:"\u8BF7\u8F93\u5165\u65E7\u5BC6\u7801",onChange:function(){return y.setFieldsValue({verify:0})}})),l.a.createElement(ce.a,{title:l.a.createElement("div",null,l.a.createElement("span",null,"\u957F\u5EA6\u4E3A8-16\u4F4D\u5B57\u7B26"),l.a.createElement("br",null),l.a.createElement("span",null,"\u5B57\u6BCD/\u6570\u5B57\u4EE5\u53CA\u6807\u70B9\u7B26\u53F7\u81F3\u5C11\u5305\u542B2\u79CD"),l.a.createElement("br",null),l.a.createElement("span",null,"\u4E0D\u5141\u8BB8\u6709\u7A7A\u683C\u3001\u4E2D\u6587")),placement:"topRight"},l.a.createElement(X.a.Item,{name:"newPassword",rules:[{required:!0,message:"\u8BF7\u8F93\u51658-16\u4F4D\u65B0\u5BC6\u7801\uFF0C\u533A\u5206\u5927\u5C0F\u5199\u3001\u4E0D\u80FD\u4F7F\u7528\u7A7A\u683C"},{validator:F}]},l.a.createElement(Q.a.Password,{autoComplete:"new-password",style:de,size:"large",placeholder:"\u8F93\u51658\uFF5E16\u4F4D\u65B0\u5BC6\u7801\uFF0C\u533A\u5206\u5927\u5C0F\u5199"}))),l.a.createElement(ce.a,{title:l.a.createElement("div",null,l.a.createElement("span",null,"\u957F\u5EA6\u4E3A8-16\u4F4D\u5B57\u7B26"),l.a.createElement("br",null),l.a.createElement("span",null,"\u5B57\u6BCD/\u6570\u5B57\u4EE5\u53CA\u6807\u70B9\u7B26\u53F7\u81F3\u5C11\u5305\u542B2\u79CD"),l.a.createElement("br",null),l.a.createElement("span",null,"\u4E0D\u5141\u8BB8\u6709\u7A7A\u683C\u3001\u4E2D\u6587")),placement:"topRight"},l.a.createElement(X.a.Item,{name:"againPassword",rules:[{required:!0,message:"\u8BF7\u518D\u6B21\u8F93\u5165\u65B0\u5BC6\u7801"},{validator:function(t,e,r){e!=y.getFieldsValue().newPassword?r("\u4E24\u6B21\u8F93\u5165\u7684\u65B0\u5BC6\u7801\u5FC5\u987B\u4E00\u81F4\uFF01"):r()}}]},l.a.createElement(Q.a.Password,{autoComplete:"new-password",style:de,size:"large",placeholder:"\u8BF7\u518D\u6B21\u8F93\u5165\u65B0\u5BC6\u7801"}))),l.a.createElement(X.a.Item,null,l.a.createElement(ae.a,{size:"large",type:"primary",htmlType:"submit",block:!0,style:de,className:"font16"}," ",I," ")),l.a.createElement("div",{className:"tc",style:{paddingTop:0,paddingBottom:20}},"\u4FEE\u6539\u5E76\u767B\u5F55\u5373\u4EE3\u8868\u60A8\u5DF2\u9605\u8BFB\u5E76\u540C\u610F",l.a.createElement("a",{href:"https://engineer.educoder.net/help?index=4",target:"_blank"},"\u300A\u670D\u52A1\u534F\u8BAE\u6761\u6B3E\u300B")))},ot=Object(K.a)(function(f){var g=f.globalSetting;return{globalSetting:g}})(at),it=_("4R62"),Pe=_.n(it);function te(){"use strict";/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */te=function(){return f};var f={},g=Object.prototype,E=g.hasOwnProperty,b=typeof Symbol=="function"?Symbol:{},C=b.iterator||"@@iterator",O=b.asyncIterator||"@@asyncIterator",D=b.toStringTag||"@@toStringTag";function h(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{h({},"")}catch(t){h=function(r,n,a){return r[n]=a}}function I(t,e,r,n){var a=e&&e.prototype instanceof U?e:U,o=Object.create(a.prototype),u=new k(n||[]);return o._invoke=function(c,d,i){var s="suspendedStart";return function(p,V){if(s==="executing")throw new Error("Generator is already running");if(s==="completed"){if(p==="throw")throw V;return B()}for(i.method=p,i.arg=V;;){var P=i.delegate;if(P){var L=x(P,i);if(L){if(L===v)continue;return L}}if(i.method==="next")i.sent=i._sent=i.arg;else if(i.method==="throw"){if(s==="suspendedStart")throw s="completed",i.arg;i.dispatchException(i.arg)}else i.method==="return"&&i.abrupt("return",i.arg);s="executing";var M=j(c,d,i);if(M.type==="normal"){if(s=i.done?"completed":"suspendedYield",M.arg===v)continue;return{value:M.arg,done:i.done}}M.type==="throw"&&(s="completed",i.method="throw",i.arg=M.arg)}}}(t,r,u),o}function j(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(n){return{type:"throw",arg:n}}}f.wrap=I;var v={};function U(){}function y(){}function m(){}var A={};h(A,C,function(){return this});var S=Object.getPrototypeOf,T=S&&S(S(F([])));T&&T!==g&&E.call(T,C)&&(A=T);var w=m.prototype=U.prototype=Object.create(A);function G(t){["next","throw","return"].forEach(function(e){h(t,e,function(r){return this._invoke(e,r)})})}function N(t,e){function r(a,o,u,c){var d=j(t[a],t,o);if(d.type!=="throw"){var i=d.arg,s=i.value;return s&&typeof s=="object"&&E.call(s,"__await")?e.resolve(s.__await).then(function(p){r("next",p,u,c)},function(p){r("throw",p,u,c)}):e.resolve(s).then(function(p){i.value=p,u(i)},function(p){return r("throw",p,u,c)})}c(d.arg)}var n;this._invoke=function(a,o){function u(){return new e(function(c,d){r(a,o,c,d)})}return n=n?n.then(u,u):u()}}function x(t,e){var r=t.iterator[e.method];if(r===void 0){if(e.delegate=null,e.method==="throw"){if(t.iterator.return&&(e.method="return",e.arg=void 0,x(t,e),e.method==="throw"))return v;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return v}var n=j(r,t.iterator,e.arg);if(n.type==="throw")return e.method="throw",e.arg=n.arg,e.delegate=null,v;var a=n.arg;return a?a.done?(e[t.resultName]=a.value,e.next=t.nextLoc,e.method!=="return"&&(e.method="next",e.arg=void 0),e.delegate=null,v):a:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,v)}function $(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function R(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function k(t){this.tryEntries=[{tryLoc:"root"}],t.forEach($,this),this.reset(!0)}function F(t){if(t){var e=t[C];if(e)return e.call(t);if(typeof t.next=="function")return t;if(!isNaN(t.length)){var r=-1,n=function a(){for(;++r<t.length;)if(E.call(t,r))return a.value=t[r],a.done=!1,a;return a.value=void 0,a.done=!0,a};return n.next=n}}return{next:B}}function B(){return{value:void 0,done:!0}}return y.prototype=m,h(w,"constructor",m),h(m,"constructor",y),y.displayName=h(m,D,"GeneratorFunction"),f.isGeneratorFunction=function(t){var e=typeof t=="function"&&t.constructor;return!!e&&(e===y||(e.displayName||e.name)==="GeneratorFunction")},f.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,m):(t.__proto__=m,h(t,D,"GeneratorFunction")),t.prototype=Object.create(w),t},f.awrap=function(t){return{__await:t}},G(N.prototype),h(N.prototype,O,function(){return this}),f.AsyncIterator=N,f.async=function(t,e,r,n,a){a===void 0&&(a=Promise);var o=new N(I(t,e,r,n),a);return f.isGeneratorFunction(e)?o:o.next().then(function(u){return u.done?u.value:o.next()})},G(w),h(w,D,"Generator"),h(w,C,function(){return this}),h(w,"toString",function(){return"[object Generator]"}),f.keys=function(t){var e=[];for(var r in t)e.push(r);return e.reverse(),function n(){for(;e.length;){var a=e.pop();if(a in t)return n.value=a,n.done=!1,n}return n.done=!0,n}},f.values=F,k.prototype={constructor:k,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(R),!e)for(var r in this)r.charAt(0)==="t"&&E.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if(e.type==="throw")throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function n(i,s){return u.type="throw",u.arg=e,r.next=i,s&&(r.method="next",r.arg=void 0),!!s}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],u=o.completion;if(o.tryLoc==="root")return n("end");if(o.tryLoc<=this.prev){var c=E.call(o,"catchLoc"),d=E.call(o,"finallyLoc");if(c&&d){if(this.prev<o.catchLoc)return n(o.catchLoc,!0);if(this.prev<o.finallyLoc)return n(o.finallyLoc)}else if(c){if(this.prev<o.catchLoc)return n(o.catchLoc,!0)}else{if(!d)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return n(o.finallyLoc)}}}},abrupt:function(e,r){for(var n=this.tryEntries.length-1;n>=0;--n){var a=this.tryEntries[n];if(a.tryLoc<=this.prev&&E.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var o=a;break}}o&&(e==="break"||e==="continue")&&o.tryLoc<=r&&r<=o.finallyLoc&&(o=null);var u=o?o.completion:{};return u.type=e,u.arg=r,o?(this.method="next",this.next=o.finallyLoc,v):this.complete(u)},complete:function(e,r){if(e.type==="throw")throw e.arg;return e.type==="break"||e.type==="continue"?this.next=e.arg:e.type==="return"?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):e.type==="normal"&&r&&(this.next=r),v},finish:function(e){for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),R(n),v}},catch:function(e){for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r];if(n.tryLoc===e){var a=n.completion;if(a.type==="throw"){var o=a.arg;R(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:F(e),resultName:r,nextLoc:n},this.method==="next"&&(this.arg=void 0),v}},f}var ut=Le.a.TabPane,st=function(f){var g=f.dispatch,E=f.is_main_site,b=f.is_local,C=f.style,O=C===void 0?{}:C,D=Object(z.useState)(!1),h=Object(Y.a)(D,2),I=h[0],j=h[1],v=Object(z.useState)("1"),U=Object(Y.a)(v,2),y=U[0],m=U[1],A=Object(z.useState)(1),S=Object(Y.a)(A,2),T=S[0],w=S[1],G=Object(z.useState)(),N=Object(Y.a)(G,2),x=N[0],$=N[1];function R(){w(1),j(!1)}function k(){w(2),j(!0)}function F(a){console.log(a),m(a)}var B={buttonText:"\u767B \u5F55",validateName:Z.G,getCode:Z.w,register:function(){var a=Object(W.a)(te().mark(function u(c){var d;return te().wrap(function(s){for(;;)switch(s.prev=s.next){case 0:return s.next=2,Object(Z.a)({phone:c.login,code:c.code});case 2:if(d=s.sent,!(d.status===0)){s.next=6;break}return(d==null?void 0:d.show)?(localStorage.setItem("extension-modal","exist"),localStorage.setItem("extension-date",d==null?void 0:d.start_date)):localStorage.removeItem("extension-modal"),s.abrupt("return","/");case 6:return s.abrupt("return",d);case 7:case"end":return s.stop()}},u)}));function o(u){return a.apply(this,arguments)}return o}()},t={buttonText:"\u6CE8\u518C\u5E76\u767B\u5F55",validateName:Z.G,getCode:Z.w,register:function(){var a=Object(W.a)(te().mark(function u(c){var d,i;return te().wrap(function(p){for(;;)switch(p.prev=p.next){case 0:return p.next=2,Object(Z.z)(Object(q.a)({},c));case 2:if(d=p.sent,!(d.status===0)){p.next=9;break}return i=localStorage.getItem("addinfo"),i==="1"?localStorage.setItem("addinfo","2"):localStorage.setItem("registeruser","1"),localStorage.removeItem("extension-modal"),me.b.info("\u6CE8\u518C\u5E76\u767B\u9646\u6210\u529F"),p.abrupt("return","/");case 9:return p.abrupt("return",d);case 10:case"end":return p.stop()}},u)}));function o(u){return a.apply(this,arguments)}return o}()},e={buttonText:"\u4FEE\u6539\u5BC6\u7801",validateName:Z.G,getCode:Z.w,register:function(){var a=Object(W.a)(te().mark(function u(c){var d;return te().wrap(function(s){for(;;)switch(s.prev=s.next){case 0:return s.next=2,Object(Z.f)(Object(q.a)({login:x},c));case 2:return d=s.sent,me.b.info("\u4FEE\u6539\u5BC6\u7801\u6210\u529F"),s.abrupt("return",d);case 5:case"end":return s.stop()}},u)}));function o(u){return a.apply(this,arguments)}return o}()},r={buttonText:"\u4FEE\u6539\u5E76\u767B\u5F55",validateName:Z.G,getCode:Z.w,register:function(){var a=Object(W.a)(te().mark(function u(c){var d;return te().wrap(function(s){for(;;)switch(s.prev=s.next){case 0:return c.new_password_confirmation=se.Base64.encode(c.new_password),c.new_password=se.Base64.encode(c.new_password),s.next=4,Object(Z.A)(Object(q.a)({},c));case 4:if(d=s.sent,!(d.status===0)){s.next=9;break}return(d==null?void 0:d.show)?(localStorage.setItem("extension-modal","exist"),localStorage.setItem("extension-date",d==null?void 0:d.start_date)):localStorage.removeItem("extension-modal"),me.b.info("\u4FEE\u6539\u6210\u529F"),s.abrupt("return","/");case 9:return s.abrupt("return",d);case 10:case"end":return s.stop()}},u)}));function o(u){return a.apply(this,arguments)}return o}()},n=Object(z.useCallback)(function(){switch(T){case 1:return l.a.createElement(Le.a,{defaultActiveKey:y,onChange:F,className:Pe.a.tabs},l.a.createElement(ut,{tab:"\u8D26\u53F7\u767B\u5F55",key:"1"},l.a.createElement("div",{className:"mt20"},y==="1"&&l.a.createElement(ke,{setusername:$,setType:w}))));case 2:return l.a.createElement(et,{setType:w,onBack:R});case 3:return l.a.createElement("div",{className:"ml40"},l.a.createElement("h1",{className:"font18 mb20 mt35"},"\u65B0\u7528\u6237\u6CE8\u518C"),l.a.createElement(Ve,t));case 4:return l.a.createElement("div",{className:"ml40"},l.a.createElement("h1",{className:"font18 mb20 mt35"},"\u627E\u56DE\u5BC6\u7801"),l.a.createElement(We,r));case 5:return l.a.createElement("div",{className:"ml40"},l.a.createElement("h1",{className:"font18 mb20 mt35"},"\u4FEE\u6539\u5BC6\u7801"),l.a.createElement(ot,e))}},[T,y]);return l.a.createElement("div",{className:Pe.a["login-panel-wrapper2"],style:O},l.a.createElement(Fe.a,null,l.a.createElement(pe.a,{flex:"1"},n()),b&&l.a.createElement(pe.a,{flex:"40px"}),l.a.createElement(pe.a,{flex:"295px",className:Pe.a["login-panel-right-wrp"]},!b&&l.a.createElement(qe,{loginType:T,setType:w,onWechatLogin:k}))))},lt=_("1TMG"),ct=_.n(lt),dt=function(g){var E,b,C=g.user,O=g.globalSetting,D=g.loading,h=g.dispatch,I=function(){h({type:"user/showPopLogin",payload:{showPopLogin:!1,showClosable:!1}})},j=(E=O.setting)===null||E===void 0?void 0:E.main_site,v=(b=O.setting)===null||b===void 0?void 0:b.is_local;return l.a.createElement(he.a,{centered:!0,visible:C.showPopLogin,footer:null,width:v?420:765,keyboard:!1,maskClosable:!1,wrapClassName:ct.a.popLogin,closable:C.showClosable,onCancel:I},C.showPopLogin&&l.a.createElement(st,{is_main_site:j,is_local:v}))},ft=Object(K.a)(function(f){var g=f.user,E=f.loading,b=f.globalSetting;return{user:g,globalSetting:b,loading:E.models.index}})(dt),ht=_("wd/R"),Ue=_.n(ht),pt=function(g){var E=g.loading,b=g.globalSetting,C=g.children,O=g.user,D=g.dispatch,h=g.location,I=Object(Ne.a)(g,["loading","globalSetting","children","user","dispatch","location"]),j=b.globalLoading;Object(z.useEffect)(function(){},[]),Object(z.useEffect)(function(){if(document.body.scrollIntoView(),D({type:"globalSetting/query",payload:{}}),D({type:"globalSetting/setGlobalLoading",payload:{show:!1,text:""}}),h.pathname==="/admins"||h.pathname==="/sidekiq"){var U=document.domain;if(U.indexOf("educoder.net")>-1)switch(U){case"www.educoder.net":case"educoder.net":window.location.href="https://data.educoder.net".concat(h.pathname);break;default:var y=document.domain.split(".");y[0]=y[0]+"-data",window.location.href="https://".concat(y.join(".")).concat(h.pathname);break}}he.a.destroyAll(),Object(K.e)("zh-CN",!1)},[h.pathname]),Object(z.useEffect)(function(){b.updateData.system_update?localStorage.updateEndTime||new Date().getTime()<new Date(b.updateData.end_time).getTime()&&he.a.info({title:b.updateData.subject,content:b.updateData.system_score,onOk:function(){localStorage.updateEndTime=b.updateData.end_time}}):localStorage.removeItem("updateEndTime")},[b.updateData.system_update]),Object(z.useEffect)(function(){var U;if((U=O.userInfo)===null||U===void 0?void 0:U.login){var y,m;window.gtag("config","UA-198293321-1",{user_id:(y=O.userInfo)===null||y===void 0?void 0:y.login,custom_map:{dimension1:"user_id"}}),window.gtag("set",{user_id:(m=O.userInfo)===null||m===void 0?void 0:m.login})}},[O.userInfo]),Object(z.useEffect)(function(){var U,y;if(((U=O.userInfo)===null||U===void 0?void 0:U.login)&&v(),(y=O.userInfo)===null||y===void 0?void 0:y.user_school){var m,A,S,T;Object(H.Q)([(m=O.userInfo)===null||m===void 0?void 0:m.user_school,(A=O.userInfo)===null||A===void 0?void 0:A.login,3]),Object(H.P)(["\u7528\u6237\u8BBF\u95EE\u660E\u7EC6",(S=O.userInfo)===null||S===void 0?void 0:S.login,(T=O.userInfo)===null||T===void 0?void 0:T.user_school])}},[O.userInfo,h.pathname]);var v=function(){var y,m=localStorage.trackUserTime,A=localStorage.trackUser;if(!(m&&Ue()(m).isSame(Ue()().startOf("day"),"d")&&A==((y=O.userInfo)===null||y===void 0?void 0:y.login))){var S,T,w,G;localStorage.trackUserTime=new Date,localStorage.trackUser=(S=O.userInfo)===null||S===void 0?void 0:S.login;var N="";switch(O.userInfo.role){case 1:N="\u8D85\u7BA1";break;case 2:N="\u8FD0\u8425";break;case 5:N="\u8BA4\u8BC1\u6559\u5E08";break;case 12:N="\u672A\u8BA4\u8BC1\u6559\u5E08";break;case 15:N="\u5B66\u751F";break}if(((T=O.userInfo)===null||T===void 0?void 0:T.identity)!=="student"&&((w=O.userInfo)===null||w===void 0?void 0:w.identity)!=="teacher"&&(N="\u4E13\u4E1A\u4EBA\u58EB"),(G=O.userInfo)===null||G===void 0?void 0:G.user_school){var x,$,R;Object(H.P)(["\u5B66\u6821\u6D3B\u8DC3\u7528\u6237",(x=O.userInfo)===null||x===void 0?void 0:x.user_school]),Object(H.P)(["\u7528\u6237\u8BBF\u95EE\u660E\u7EC6",($=O.userInfo)===null||$===void 0?void 0:$.login,(R=O.userInfo)===null||R===void 0?void 0:R.user_school])}Object(H.P)(["\u5E73\u53F0PC\u7AEF","\u603B\u6D3B\u8DC3\u7528\u6237\u6570"]),Object(H.P)(["\u5E73\u53F0PC\u7AEF",N])}};return l.a.createElement(Te.a,{locale:Se.default},l.a.createElement(ft,null),l.a.createElement(Ce.a,{size:"large",spinning:j.show,tip:j.text,className:"ant-spin-nested-loading-black"},C))},Ct=re.default=Object(K.a)(function(f){var g=f.loading,E=f.globalSetting,b=f.user;return{loading:g,globalSetting:E,user:b}})(pt)},"/nL+":function(J,re,_){J.exports=_.p+"static/qq.3cfa477b.svg"},"0zpY":function(J,re,_){},"1TMG":function(J,re,_){J.exports={popLogin:"popLogin___3dT1f"}},"4R62":function(J,re,_){J.exports={"login-panel-wrapper2":"login-panel-wrapper2___togLZ","ant-form-item-explain":"ant-form-item-explain___ThRBE","ant-form-item":"ant-form-item___3IV6B","ant-form-item-with-help":"ant-form-item-with-help___tz-ky","login-panel-right-wrp":"login-panel-right-wrp___2GQ8_","res-error-values":"res-error-values___2aGnb",tabs:"tabs___2wmM-"}},IxGP:function(J,re,_){J.exports={"other-login":"other-login___re0Nc","btn-link":"btn-link___1uZTy","wechat-qrcode":"wechat-qrcode___14L6l",driver:"driver___1fhl_"}},h0ge:function(J,re,_){J.exports=_.p+"static/wechat.044c9ad6.svg"}}]);