|
|
"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[92821],{16135:function(e,n,l){var i=l(39647),o=l.n(i),a=(l(59301),l(11403)),t=l(43418),r=l(37712),s=["shixunsDetail","globalSetting","loading","dispatch"];n.Z=(0,a.connect)((function(e){var n=e.shixunsDetail,l=e.loading;return{shixunsDetail:n,globalSetting:e.globalSetting,loading:l.models.index}}))((function(e){var n=e.shixunsDetail,l=(e.globalSetting,e.loading,e.dispatch);o()(e,s);return(0,r.jsx)(t.Z,{centered:!0,keyboard:!1,closable:!1,zIndex:6666,title:"提示",open:"Banner-Auth"===n.actionTabs.key,okText:"确定",cancelText:"取消",onOk:function(){l({type:"shixunsDetail/setActionTabs",payload:{}}),window.location.href="/account/certification"},onCancel:function(){l({type:"shixunsDetail/setActionTabs",payload:{}})},children:(0,r.jsxs)("p",{className:"tc font16",children:["当前竞赛需要实名认证,请先完成实名认证后再报名参赛",(0,r.jsx)("br",{}),"请问是否前往进行认证?"]})})}))},43727:function(e,n,l){var i=l(82242),o=l.n(i),a=l(7557),t=l.n(a),r=l(41498),s=l.n(r),d=l(79800),u=l.n(d),c=l(57809),p=l(78241),_=l(43418),h=l(8591),v=l(98135),f=l(5112),x=l(88522),m=l(14834),y=l(89392),g=l(59301),j=l(37712),Z=c.default.Option;n.Z=function(e){var n,l,i,a,r,d,b,w,I,k,C,P,S,A,q,z,O,L,T,D,R,E,F,N,B,Y,G=e.isAddmodle,M=e.setIsAdd,V=e.createTeam,J=e.Data,H=e.user,K=void 0===H?{}:H,Q=e.dispatch,$=p.Z.useForm(),U=u()($,1)[0];console.log("---",K);var W,X=(0,g.useState)([]),ee=u()(X,2),ne=ee[0],le=ee[1],ie=(0,g.useRef)((0,y.throttle)((function(e){return se(e)}),1200,{leading:!0,trailing:!0})).current,oe=(0,g.useState)([]),ae=u()(oe,2),te=ae[0],re=ae[1],se=function(){var e=s()(t()().mark((function e(n){var l,i;return t()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Q({type:"account/getSchoolOption",payload:{keyword:n,limit:10,competition_id:null==J?void 0:J.identifier}});case 2:l=e.sent,le(null==l?void 0:l.schools),n&&""!=n&&re(null==l||null===(i=l.schools)||void 0===i?void 0:i.filter((function(e){return e.name.includes(n)})));case 5:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}();return(0,g.useEffect)((function(){var e;se(null==K||null===(e=K.userInfo)||void 0===e?void 0:e.school_name)}),[(null==J||null===(n=J.need_apply_info)||void 0===n?void 0:n.need_apply_name)||(null==J||null===(l=J.need_apply_info)||void 0===l?void 0:l.need_apply_student_id)||(null==J||null===(i=J.need_apply_info)||void 0===i?void 0:i.need_apply_sex)||(null==J||null===(a=J.need_apply_info)||void 0===a?void 0:a.need_apply_phone)||(null==J||null===(r=J.need_apply_info)||void 0===r?void 0:r.need_apply_grade)||(null==J||null===(d=J.need_apply_info)||void 0===d?void 0:d.need_apply_teacher_name)||(null==J||null===(b=J.need_apply_info)||void 0===b?void 0:b.need_apply_school)]),(0,j.jsx)(_.Z,{className:"modal_styles",centered:!0,title:(0,j.jsxs)("div",{style:{alignItems:"center",display:"flex"},children:[(0,j.jsx)("div",{style:{textAlign:"left",flex:"1"},children:"创建战队"}),(0,j.jsx)(m.Z,{onClick:function(){return M(!1)},style:{cursor:"porint"}})]}),open:G,closable:!1,width:700,destroyOnClose:!0,onOk:function(){U.submit()},onCancel:function(){return M(!1)},children:(0,j.jsxs)(p.Z,{form:U,initialValues:o()(o()({},K.userInfo),{},{sex:null==K||null===(w=K.userInfo)||void 0===w?void 0:w.gender,grade:null==K||null===(I=K.userInfo)||void 0===I?void 0:I.edu_entry_year,school:null==K||null===(k=K.userInfo)||void 0===k?void 0:k.school_name}),labelCol:{span:5},size:"large",onFinish:function(){var e=s()(t()().mark((function e(n){var l,i,a;return t()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if((a=null===(l=ne.find((function(e){return e.name===(null==n?void 0:n.school)})))||void 0===l?void 0:l.id)||null==J||null===(i=J.need_apply_info)||void 0===i||!i.need_apply_school){e.next=4;break}return h.ZP.info("请选择正确的学校"),e.abrupt("return");case 4:V(o()(o()({},n),{},{school_id:a}));case 5:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}(),children:[((null==J||null===(C=J.need_apply_info)||void 0===C?void 0:C.need_apply_name)||(null==J||null===(P=J.need_apply_info)||void 0===P?void 0:P.need_apply_teacher_phone)||(null==J||null===(S=J.need_apply_info)||void 0===S?void 0:S.need_apply_student_id)||(null==J||null===(A=J.need_apply_info)||void 0===A?void 0:A.need_apply_sex)||(null==J||null===(q=J.need_apply_info)||void 0===q?void 0:q.need_apply_phone)||(null==J||null===(z=J.need_apply_info)||void 0===z?void 0:z.need_apply_grade)||(null==J||null===(O=J.need_apply_info)||void 0===O?void 0:O.need_apply_teacher_name)||(null==J||null===(L=J.need_apply_info)||void 0===L?void 0:L.need_apply_school))&&(0,j.jsx)("div",{className:"mb20",children:"根据竞赛官方的规定,参赛人员需填写必填信息才可完成报名,请确保填写的信息准确完整。"}),(0,j.jsx)(p.Z.Item,{label:"队伍名称",name:"name",rules:[{required:!0,validator:function(e,n){var l;return(null==n||null===(l=n.replaceAll(" ",""))||void 0===l?void 0:l.length)>0?Promise.resolve():Promise.reject("请填写队伍名称")}}],children:(0,j.jsx)(v.Z,{maxLength:60,showCount:!0,placeholder:"请输入队伍名称"})}),(null==J||null===(T=J.need_apply_info)||void 0===T?void 0:T.need_apply_name)&&(0,j.jsx)(p.Z.Item,{label:"参赛人员姓名",name:"real_name",rules:[{required:!0,message:"请输入参赛人员姓名"},{whitespace:!0,message:"姓名不能为空"}],children:(0,j.jsx)(v.Z,{placeholder:"请输入参赛人员姓名",showCount:!0,maxLength:60})}),(null==J||null===(D=J.need_apply_info)||void 0===D?void 0:D.need_apply_sex)&&(0,j.jsx)(p.Z.Item,{label:"性别",name:"sex",rules:[{required:!0,message:"请选择参赛人员性别"}],children:(0,j.jsxs)(f.ZP.Group,{children:[(0,j.jsx)(f.ZP,{value:0,children:"男"}),(0,j.jsx)(f.ZP,{value:1,children:"女"})]})}),(null==J||null===(R=J.need_apply_info)||void 0===R?void 0:R.need_apply_student_id)&&(0,j.jsx)(p.Z.Item,{label:"学号",name:"student_id",rules:[{required:!0,message:"请输入参赛人员学号"},{whitespace:!0,message:"学号不能为空"}],children:(0,j.jsx)(v.Z,{placeholder:"请输入参赛人员学号",showCount:!0,maxLength:60})}),(null==J||null===(E=J.need_apply_info)||void 0===E?void 0:E.need_apply_phone)&&(0,j.jsx)(p.Z.Item,{label:"电话",name:"phone",rules:[{required:!0,message:"请输入参赛人员电话"},{whitespace:!0,message:"电话不能为空"}],children:(0,j.jsx)(v.Z,{placeholder:"请输入参赛人员电话",showCount:!0,maxLength:60})}),(null==J||null===(F=J.need_apply_info)||void 0===F?void 0:F.need_apply_grade)&&(0,j.jsx)(p.Z.Item,{label:"年级",name:"grade",rules:[{required:!0,message:"请选择参赛人员年级"}],children:(0,j.jsx)(c.default,{placeholder:"请选择参赛人员年级",size:"large",children:(W=(new Date).getFullYear(),Array(31).fill({}).map((function(e,n){return(0,j.jsx)(Z,{value:W-n,children:(0,j.jsx)("span",{children:W-n})},n)})))})}),(null==J||null===(N=J.need_apply_info)||void 0===N?void 0:N.need_apply_teacher_name)&&(0,j.jsx)(p.Z.Item,{label:"指导老师姓名",name:"teacher_name",rules:[{required:!0,message:"请输入指导老师姓名"},{whitespace:!0,message:"指导老师姓名不能为空"}],children:(0,j.jsx)(v.Z,{placeholder:"请输入指导老师姓名",showCount:!0,maxLength:60})}),(null==J||null===(B=J.need_apply_info)||void 0===B?void 0:B.need_apply_teacher_phone)&&(0,j.jsx)(p.Z.Item,{label:"指导老师联系方式",name:"teacher_phone",rules:[{required:!0,message:"请输入指导老师联系方式"},{whitespace:!0,message:"指导老师联系方式不能为空"}],children:(0,j.jsx)(v.Z,{placeholder:"请输入指导老师联系方式",showCount:!0,maxLength:60})}),(null==J||null===(Y=J.need_apply_info)||void 0===Y?void 0:Y.need_apply_school)&&(0,j.jsx)(p.Z.Item,{label:"学校",name:"school",rules:[{required:!0,message:"请选择学校"}],children:(0,j.jsx)(x.Z,{size:"large",showSearch:!0,onChange:ie,children:te.map((function(e,n){return(0,j.jsx)(Z,{value:e.name,children:e.name},n)}))})})]})})}},74986:function(e,n,l){var i=l(82242),o=l.n(i),a=l(7557),t=l.n(a),r=l(41498),s=l.n(r),d=l(79800),u=l.n(d),c=l(59301),p=l(57809),_=l(78241),h=l(43418),v=l(8591),f=l(98135),x=l(5112),m=l(88522),y=l(14834),g=l(89392),j=l(37712),Z=p.default.Option;n.Z=function(e){var n,l,i,a,r,d,b,w,I,k,C,P,S,A,q,z,O,L,T,D,R,E,F,N,B,Y,G=e.isjoin,M=e.setJoin,V=e.JoinTeams,J=e.user,H=void 0===J?{}:J,K=e.dispatch,Q=e.Data,$=void 0===Q?{}:Q,U=(0,c.useState)(""),W=u()(U,2),X=(W[0],W[1],(0,c.useState)([])),ee=u()(X,2),ne=ee[0],le=ee[1],ie=_.Z.useForm(),oe=u()(ie,1)[0],ae=(0,c.useRef)((0,g.throttle)((function(e){return ce(e)}),1200,{leading:!0,trailing:!0})).current,te=(0,c.useState)([]),re=u()(te,2),se=re[0],de=re[1];(0,c.useEffect)((function(){var e;ce(null==H||null===(e=H.userInfo)||void 0===e?void 0:e.school_name)}),[(null==$||null===(n=$.need_apply_info)||void 0===n?void 0:n.need_apply_name)||(null==$||null===(l=$.need_apply_info)||void 0===l?void 0:l.need_apply_student_id)||(null==$||null===(i=$.need_apply_info)||void 0===i?void 0:i.need_apply_sex)||(null==$||null===(a=$.need_apply_info)||void 0===a?void 0:a.need_apply_phone)||(null==$||null===(r=$.need_apply_info)||void 0===r?void 0:r.need_apply_grade)||(null==$||null===(d=$.need_apply_info)||void 0===d?void 0:d.need_apply_teacher_name)||(null==$||null===(b=$.need_apply_info)||void 0===b?void 0:b.need_apply_school)]);var ue,ce=function(){var e=s()(t()().mark((function e(n){var l,i;return t()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,K({type:"account/getSchoolOption",payload:{keyword:n,limit:10,competition_id:null==$?void 0:$.identifier}});case 2:l=e.sent,le(null==l?void 0:l.schools),n&&""!=n&&de(null==l||null===(i=l.schools)||void 0===i?void 0:i.filter((function(e){return e.name.includes(n)})));case 5:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}();return(0,j.jsx)(h.Z,{className:"modal_styles",centered:!0,title:(0,j.jsxs)("div",{style:{alignItems:"center",display:"flex"},children:[(0,j.jsx)("div",{style:{textAlign:"left",flex:"1"},children:"加入战队"}),(0,j.jsx)(y.Z,{onClick:function(){return M(!1)},style:{cursor:"porint"}})]}),open:G,width:700,closable:!1,destroyOnClose:!0,onOk:function(){oe.submit()},onCancel:function(){return M(!1)},children:(0,j.jsxs)(_.Z,{form:oe,size:"large",labelCol:{span:4},initialValues:o()(o()({},H.userInfo),{},{sex:null==H||null===(w=H.userInfo)||void 0===w?void 0:w.gender,grade:null==H||null===(I=H.userInfo)||void 0===I?void 0:I.edu_entry_year,school:null==H||null===(k=H.userInfo)||void 0===k?void 0:k.school_name}),onFinish:function(){var e=s()(t()().mark((function e(n){var l,i,a;return t()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if((a=null===(l=ne.find((function(e){return e.name===(null==n?void 0:n.school)})))||void 0===l?void 0:l.id)||null==$||null===(i=$.need_apply_info)||void 0===i||!i.need_apply_school){e.next=4;break}return v.ZP.info("请选择正确的学校"),e.abrupt("return");case 4:V(o()(o()({},n),{},{school_id:a}));case 5:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}(),children:[((null==$||null===(C=$.need_apply_info)||void 0===C?void 0:C.need_apply_name)||(null==$||null===(P=$.need_apply_info)||void 0===P?void 0:P.need_apply_teacher_phone)||(null==$||null===(S=$.need_apply_info)||void 0===S?void 0:S.need_apply_student_id)||(null==$||null===(A=$.need_apply_info)||void 0===A?void 0:A.need_apply_sex)||(null==$||null===(q=$.need_apply_info)||void 0===q?void 0:q.need_apply_phone)||(null==$||null===(z=$.need_apply_info)||void 0===z?void 0:z.need_apply_grade)||(null==$||null===(O=$.need_apply_info)||void 0===O?void 0:O.need_apply_teacher_name)||(null==$||null===(L=$.need_apply_info)||void 0===L?void 0:L.need_apply_school))&&(0,j.jsx)("div",{className:"mb20",children:"根据竞赛官方的规定,参赛人员需填写必填信息才可完成报名,请确保填写的信息准确完整。"}),(0,j.jsx)(_.Z.Item,{label:"邀请码",name:"invite_code",rules:[{required:!0,validator:function(e,n){var l;return(null==n||null===(l=n.replaceAll(" ",""))||void 0===l?void 0:l.length)>0?Promise.resolve():Promise.reject("请输入邀请码")}}],children:(0,j.jsx)(f.Z,{maxLength:60,showCount:!0,placeholder:"请输入邀请码"})}),(null==$||null===(T=$.need_apply_info)||void 0===T?void 0:T.need_apply_name)&&(0,j.jsx)(_.Z.Item,{label:"参赛人员姓名",name:"real_name",rules:[{required:!0,message:"请输入参赛人员姓名"},{whitespace:!0,message:"姓名不能为空"}],children:(0,j.jsx)(f.Z,{placeholder:"请输入参赛人员姓名",showCount:!0,maxLength:60})}),(null==$||null===(D=$.need_apply_info)||void 0===D?void 0:D.need_apply_sex)&&(0,j.jsx)(_.Z.Item,{label:"性别",name:"sex",rules:[{required:!0,message:"请选择参赛人员性别"}],children:(0,j.jsxs)(x.ZP.Group,{children:[(0,j.jsx)(x.ZP,{value:0,children:"男"}),(0,j.jsx)(x.ZP,{value:1,children:"女"})]})}),(null==$||null===(R=$.need_apply_info)||void 0===R?void 0:R.need_apply_student_id)&&(0,j.jsx)(_.Z.Item,{label:"学号",name:"student_id",rules:[{required:!0,message:"请输入参赛人员学号"},{whitespace:!0,message:"学号不能为空"}],children:(0,j.jsx)(f.Z,{placeholder:"请输入参赛人员学号",showCount:!0,maxLength:60})}),(null==$||null===(E=$.need_apply_info)||void 0===E?void 0:E.need_apply_phone)&&(0,j.jsx)(_.Z.Item,{label:"电话",name:"phone",rules:[{required:!0,message:"请输入参赛人员电话"},{whitespace:!0,message:"电话不能为空"}],children:(0,j.jsx)(f.Z,{placeholder:"请输入参赛人员电话",showCount:!0,maxLength:60})}),(null==$||null===(F=$.need_apply_info)||void 0===F?void 0:F.need_apply_grade)&&(0,j.jsx)(_.Z.Item,{label:"年级",name:"grade",rules:[{required:!0,message:"请选择参赛人员年级"}],children:(0,j.jsx)(p.default,{placeholder:"请选择参赛人员年级",size:"large",children:(ue=(new Date).getFullYear(),Array(31).fill({}).map((function(e,n){return(0,j.jsx)(Z,{value:ue-n,children:(0,j.jsx)("span",{children:ue-n})},n)})))})}),(null==$||null===(N=$.need_apply_info)||void 0===N?void 0:N.need_apply_teacher_name)&&(0,j.jsx)(_.Z.Item,{label:"指导老师姓名",name:"teacher_name",rules:[{required:!0,message:"请输入指导老师姓名"},{whitespace:!0,message:"指导老师姓名不能为空"}],children:(0,j.jsx)(f.Z,{placeholder:"请输入指导老师姓名",showCount:!0,maxLength:60})}),(null==$||null===(B=$.need_apply_info)||void 0===B?void 0:B.need_apply_teacher_phone)&&(0,j.jsx)(_.Z.Item,{label:"指导老师联系方式",name:"teacher_phone",rules:[{required:!0,message:"请输入指导老师联系方式"},{whitespace:!0,message:"指导老师联系方式不能为空"}],children:(0,j.jsx)(f.Z,{placeholder:"请输入指导老师联系方式",showCount:!0,maxLength:60})}),(null==$||null===(Y=$.need_apply_info)||void 0===Y?void 0:Y.need_apply_school)&&(0,j.jsx)(_.Z.Item,{label:"学校",name:"school",rules:[{required:!0,message:"请选择学校"}],children:(0,j.jsx)(m.Z,{size:"large",showSearch:!0,onChange:ae,children:se.map((function(e,n){return(0,j.jsx)(Z,{value:e.name,children:e.name},n)}))})})]})})}},55701:function(e,n,l){var i=l(7557),o=l.n(i),a=l(41498),t=l.n(a),r=l(79800),s=l.n(r),d=l(59301),u=l(8591),c=l(43418),p=l(98135),_=l(3113),h=l(18327),v=l(42124),f=l(61435),x=l(54335),m=l(37712),y=/^1\d{10}$/;n.Z=function(e){var n=e.isShowPhone,l=e.setIsShowPhone,i=e.user,a=e.dispatch,r=e.onOK,g=e.isopen,j=e.setisopen,Z=e.datas,b=e.Header,w=(0,d.useState)(""),I=s()(w,2),k=I[0],C=I[1],P=(0,d.useState)(""),S=s()(P,2),A=S[0],q=S[1],z=(0,d.useState)(60),O=s()(z,2),L=O[0],T=O[1],D=(0,d.useState)(),R=s()(D,2),E=R[0],F=R[1],N=(0,d.useState)(!1),B=s()(N,2),Y=B[0],G=B[1],M=(0,d.useState)(!1),V=s()(M,2),J=V[0],H=V[1],K=(0,d.useState)(""),Q=s()(K,2),$=Q[0],U=Q[1],W=(0,d.useRef)();(0,d.useEffect)((function(){return function(){W.current&&clearInterval(W.current)}}),[]),(0,v.Y)((function(){E&&(T(60),L>0?T(L-1):(T(60),F(!1),W.current&&clearInterval(W.current)))}),1e3);var X=function(){var e=t()(o()().mark((function e(){var n,l,t;return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,h.ZP)("/api/users/accounts/".concat(null===(n=i.userInfo)||void 0===n?void 0:n.login,"/valid_phone.json"),{method:"get",params:{phone:k}});case 2:if(-1!==(null==(l=e.sent)?void 0:l.status)){e.next=5;break}return e.abrupt("return");case 5:if(null==l||!l.is_exists){e.next=8;break}return G(!0),e.abrupt("return");case 8:return t=(0,f.M)(k),e.next=11,a({type:"account/getCode",payload:{login:k,type:3,smscode:t}});case 11:1===e.sent.status&&(u.ZP.info("验证码已发送,请注意查收"),F(!0));case 13:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();return(0,m.jsxs)("div",{children:[(0,m.jsx)(c.Z,{title:"强制解绑",open:J,onCancel:function(){return H(!1)},onOk:t()(o()().mark((function e(){var n,a;return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if($){e.next=3;break}return u.ZP.info("验证码不能为空"),e.abrupt("return");case 3:return e.next=5,(0,h.ZP)("/api/users/accounts/".concat(null==i||null===(n=i.userInfo)||void 0===n?void 0:n.login,"/phone_force_unbind.json"),{method:"POST",body:{code:$,phone:k}});case 5:0===(null==(a=e.sent)?void 0:a.status)&&(u.ZP.info("解绑成功"),F(!1),H(!1),r(),l(!1),U(""));case 7:case"end":return e.stop()}}),e)}))),children:(0,m.jsxs)("div",{style:{padding:"8px 24px"},children:[(0,m.jsx)("p",{children:"若原账号只有绑定了手机号一种登录方式,强制解绑后会导致原账号无法登录,请确定是否强制解绑"}),(0,m.jsxs)("p",{children:["你的手机号:",k]}),(0,m.jsxs)("p",{children:["手机验证码:",(0,m.jsx)(p.Z,{value:$,size:"middle",onChange:function(e){return U(e.target.value)},style:{width:"240px"}})," ",(0,m.jsx)(_.ZP,{disabled:E,type:"primary",size:"middle",onClick:t()(o()().mark((function e(){var n;return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=(0,f.M)(k),e.next=3,a({type:"account/getCode",payload:{login:k,type:10,smscode:n}});case 3:1===e.sent.status&&(u.ZP.info("验证码已发送,请注意查收"),F(!0));case 5:case"end":return e.stop()}}),e)}))),children:E?"重新发送".concat(L,"s"):"获取验证码"})]})]})}),(0,m.jsx)(c.Z,{title:"提示",open:Y,onCancel:function(){G(!1)},okText:"进行强制解绑",okButtonProps:{type:"primary",ghost:!0,style:{width:"124px"}},onOk:function(){H(!0),G(!1)},children:(0,m.jsxs)("div",{style:{padding:"7px 24px"},children:[(0,m.jsx)("span",{children:"该手机号已经被绑定账号,如果需要将该手机号绑定在当前账号上,你可以进行下方任意一种解绑操作:"}),(0,m.jsx)("br",{}),(0,m.jsx)("p",{style:{marginTop:"1em",display:"flex"},children:(0,m.jsx)("span",{style:{flex:"1"},children:"1、使用该手机号登录平台进行解绑,再将手机号绑定当前账号上。"})}),(0,m.jsx)("p",{style:{marginTop:"1em",display:"flex"},children:(0,m.jsx)("span",{style:{flex:"1"},children:"2、强制解绑(强制解绑可能会导致解绑账号无法登录)"})})]})}),(0,m.jsx)(c.Z,{title:"绑定手机号",open:n,onCancel:function(){return l(!1)},onOk:t()(o()().mark((function e(){var n,t,s;return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(y.test(k)){e.next=3;break}return u.ZP.info("请输入有效的11位手机号码"),e.abrupt("return");case 3:if(A){e.next=6;break}return u.ZP.info("请输入验证码"),e.abrupt("return");case 6:return n=i.userInfo||{},t=n.login,e.next=9,a({type:"account/bindPhone",payload:{login:t,phone:k,code:A}});case 9:0===(null==(s=e.sent)?void 0:s.status)&&(l(!1),r());case 11:case"end":return e.stop()}}),e)}))),children:(0,m.jsxs)("div",{style:{padding:"8px 24px"},children:[(0,m.jsx)("p",{children:"平台已检测到您未绑定手机号,为了不影响使用报名功能,请先绑定手机号码"}),(0,m.jsxs)("p",{children:["你的手机号:",(0,m.jsx)(p.Z,{size:"middle",value:k,onChange:function(e){return C(e.target.value)},style:{width:"240px"}})]}),(0,m.jsxs)("p",{children:["手机验证码:",(0,m.jsx)(p.Z,{size:"middle",value:A,onChange:function(e){return q(e.target.value)},style:{width:"240px"}})," ",(0,m.jsx)(_.ZP,{disabled:E,type:"primary",size:"middle",onClick:t()(o()().mark((function e(){return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(y.test(k)){e.next=3;break}return u.ZP.info("请输入有效的11位手机号码"),e.abrupt("return");case 3:X();case 4:case"end":return e.stop()}}),e)}))),children:E?"重新发送".concat(L,"s"):"获取验证码"})]})]})}),(0,m.jsx)(c.Z,{open:g,footer:!1,onCancel:function(){return j(!1)},centered:!0,width:460,children:(0,m.jsxs)("div",{children:[(0,m.jsxs)("div",{style:{marginTop:50,fontSize:26,color:"#3d3d3d",textAlign:"center",marginBottom:20},children:[(0,m.jsx)("i",{style:{fontSize:26,color:"#52C41A"},className:"iconfont icon-tongguo"})," 报名成功"]}),(0,m.jsxs)("div",{style:{alignItems:"center",textAlign:"center"},children:[(null==b?void 0:b.is_show_picture)&&(0,m.jsx)("img",{style:{width:180,border:"1px solid #eeeeef",padding:10,marginBottom:20},src:x.Z.IMG_SERVER+(null==Z?void 0:Z.QR_code)}),(0,m.jsx)("p",{style:{color:"#AAAAAA"},children:(null==b?void 0:b.apply_success_tips)||"参赛者可扫码加入大赛官方交流群,获取最新竞赛通知"})]})]})})]})}},42124:function(e,n,l){l.d(n,{Y:function(){return o}});var i=l(59301);function o(e,n){var l=(0,i.useRef)(),o=(0,i.useRef)();(0,i.useEffect)((function(){l.current=e})),(0,i.useEffect)((function(){if(null!==n){var e=setInterval((function(){l.current()}),n);return o.current=e,function(){return clearInterval(e)}}}),[n])}}}]); |