1import{_ as R,r as f,d as i,o as h,c as w,f as e,h as t,x as o,a as I,j as U,l as y,m as z,e as d,n as B,q as K,p as N,s as S,t as T,y as M,E as $,v as j}from"./index-uGWb9Yh4.js";const x=c=>(S("data-v-aaa460ed"),c=c(),T(),c),A={class:"register"},F=x(()=>d("h3",{class:"title"},"è¥ä¾åå°ç®¡çç³»ç»",-1)),H={class:"register-code"},L=["src"],D={key:0},G={key:1},J={style:{float:"right"}},O=x(()=>d("div",{class:"el-register-footer"},[d("span",null,"Copyright © 2018-2024 ruoyi.vip All Rights Reserved.")],-1)),Q={__name:"register",setup(c){const b=I(),{proxy:k}=j(),s=f({username:"",password:"",confirmPassword:"",code:"",uuid:""}),C={username:[{required:!0,trigger:"blur",message:"请è¾å
¥æ¨çè´¦å·"},{min:2,max:20,message:"ç¨æ·è´¦å·é¿åº¦å¿
é¡»ä»äº 2 å 20 ä¹é´",trigger:"blur"}],password:[{required:!0,trigger:"blur",message:"请è¾å
¥æ¨çå¯ç "},{min:5,max:20,message:"ç¨æ·å¯ç é¿åº¦å¿
é¡»ä»äº 5 å 20 ä¹é´",trigger:"blur"},{pattern:/^[^<>"'|\\]+$/,message:`ä¸è½å
å«éæ³å符ï¼< > " ' \\ |`,trigger:"blur"}],confirmPassword:[{required:!0,trigger:"blur",message:"è¯·åæ¬¡è¾å
¥æ¨çå¯ç "},{required:!0,validator:(l,r,a)=>{s.value.password!==r?a(new Error("两次è¾å
¥çå¯ç ä¸ä¸è´")):a()},trigger:"blur"}],code:[{required:!0,trigger:"change",message:"请è¾å
¥éªè¯ç "}]},V=f(""),p=f(!1),m=f(!0);function g(){k.$refs.registerRef.validate(l=>{l&&(p.value=!0,M(s.value).then(r=>{const a=s.value.username;$.alert("<font color='red'>æåä½ ï¼æ¨çè´¦å· "+a+" 注åæåï¼</font>","ç³»ç»æç¤º",{dangerouslyUseHTMLString:!0,type:"success"}).then(()=>{b.push("/login")}).catch(()=>{})}).catch(()=>{p.value=!1,m&&v()}))})}function v(){U().then(l=>{m.value=l.captchaEnabled===void 0?!0:l.captchaEnabled,m.value&&(V.value="data:image/gif;base64,"+l.img,s.value.uuid=l.uuid)})}return v(),(l,r)=>{const a=i("svg-icon"),_=i("el-input"),u=i("el-form-item"),q=i("el-button"),E=i("router-link"),P=i("el-form");return h(),w("div",A,[e(P,{ref:"registerRef",model:o(s),rules:C,class:"register-form"},{default:t(()=>[F,e(u,{prop:"username"},{default:t(()=>[e(_,{modelValue:o(s).username,"onUpdate:modelValue":r[0]||(r[0]=n=>o(s).username=n),type:"text",size:"large","auto-complete":"off",placeholder:"è´¦å·"},{prefix:t(()=>[e(a,{"icon-class":"user",class:"el-input__icon input-icon"})]),_:1},8,["modelValue"])]),_:1}),e(u,{prop:"password"},{default:t(()=>[e(_,{modelValue:o(s).password,"onUpdate:modelValue":r[1]||(r[1]=n=>o(s).password=n),type:"password",size:"large","auto-complete":"off",placeholder:"å¯ç ",onKeyup:y(g,["enter"])},{prefix:t(()=>[e(a,{"icon-class":"password",class:"el-input__icon input-icon"})]),_:1},8,["modelValue"])]),_:1}),e(u,{prop:"confirmPassword"},{default:t(()=>[e(_,{modelValue:o(s).confirmPassword,"onUpdate:modelValue":r[2]||(r[2]=n=>o(s).confirmPassword=n),type:"password",size:"large","auto-complete":"off",placeholder:"确认å¯ç ",onKeyup:y(g,["enter"])},{prefix:t(()=>[e(a,{"icon-class":"password",class:"el-input__icon input-icon"})]),_:1},8,["modelValue"])]),_:1}),o(m)?(h(),z(u,{key:0,prop:"code"},{default:t(()=>[e(_,{size:"large",modelValue:o(s).code,"onUpdate:modelValue":r[3]||(r[3]=n=>o(s).code=n),"auto-complete":"off",placeholder:"éªè¯ç ",style:{width:"63%"},onKeyup:y(g,["enter"])},{prefix:t(()=>[e(a,{"icon-class":"validCode",class:"el-input__icon input-icon"})]),_:1},8,["modelValue"]),d("div",H,[d("img",{src:o(V),onClick:v,class:"register-code-img"},null,8,L)])]),_:1})):B("",!0),e(u,{style:{width:"100%"}},{default:t(()=>[e(q,{loading:o(p),size:"large",type:"primary",style:{width:"100%"},onClick:K(g,["prevent"])},{default:t(()=>[o(p)?(h(),w("span",G,"注 å ä¸...")):(h(),w("span",D,"注 å"))]),_:1},8,["loading"]),d("div",J,[e(E,{class:"link-type",to:"/login"},{default:t(()=>[N("使ç¨å·²æè´¦æ·ç»å½")]),_:1})])]),_:1})]),_:1},8,["model"]),O])}}},Y=R(Q,[["__scopeId","data-v-aaa460ed"]]);export{Y as default};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.