import{B as T,C as j,D as z,F as P,w as M}from"./element-plus.8e273e86.js";import{u as C,a as O,c as k,A as b,_ as X,b as Y,P as Z,d as G}from"./index.2078eb25.js";import{u as H,a as J}from"./vue-router.10bd5b90.js";import{d as E,b as L,o as _,c as f,a as r,T as Q,a9 as W,u as h,S as R,r as D,s as B,Z as ee,i as oe,U as o,L as c,aa as V,R as te}from"./@vue.76ce7aa3.js";import"./lodash-es.f52bd8b1.js";import"./async-validator.fb49d0f5.js";import"./@vueuse.9ffef7f8.js";import"./@element-plus.73235148.js";import"./dayjs.0112e2c7.js";import"./@babel.80d29b7b.js";import"./@ctrl.b082b0c1.js";import"./normalize-wheel-es.8aeb3683.js";import"./@popperjs.36402333.js";import"./lodash.41b9567d.js";import"./axios.b4cbdbc9.js";import"./jspdf.75308076.js";import"./fflate.0418c72f.js";import"./pinia.f3529286.js";import"./css-color-function.f23177ae.js";import"./color.a6ad6672.js";import"./clone.954ba32c.js";import"./color-convert.755d189f.js";import"./color-name.e7a4e1d3.js";import"./color-string.e356f5de.js";import"./balanced-match.d2a36341.js";import"./ms.564e106c.js";import"./nprogress.b502f541.js";import"./vue-clipboard3.e775fc74.js";import"./clipboard.6417898a.js";import"./echarts.5016c48c.js";import"./zrender.58d022a1.js";import"./tslib.60310f1a.js";import"./highlight.js.31cd7941.js";import"./@highlightjs.8d65305c.js";const se={class:"layout-footer"},ne={class:"text-center p-2 text-xs text-tx-secondary max-w-[900px] mx-auto"},re=["href"],ae=E({__name:"footer",setup(g){const t=C(),l=L(()=>t.config.copyright_config||[]);return(m,a)=>(_(),f("footer",se,[r("div",ne,[(_(!0),f(Q,null,W(h(l),u=>(_(),f("a",{class:"mx-1 hover:underline",href:u.value,target:"_blank",key:u.key},R(u.key),9,re))),128))])]))}});function ce(g){const t=D(!1);return{isLock:t,lockFn:async(...m)=>{if(!t.value){t.value=!0;try{const a=await g(...m);return t.value=!1,a}catch(a){throw t.value=!1,a}}}}}const le={class:"login flex flex-col"},ue={class:"flex-1 flex items-center justify-center"},ie={class:"login-card flex rounded-md"},pe={class:"flex-1 h-full hidden md:inline-block"},me={class:"login-form bg-body flex flex-col justify-center px-10 py-10 md:w-[400px] w-[375px] flex-none mx-auto"},de={class:"text-center text-3xl font-medium mb-8"},_e={class:"mb-5"},fe=E({__name:"login",setup(g){const t=B(),l=B(),m=C(),a=O(),u=H(),S=J(),i=D(!1),v=L(()=>m.config),n=ee({account:"",password:""}),U={account:[{required:!0,message:"\u8BF7\u8F93\u5165\u8D26\u53F7",trigger:["blur"]}],password:[{required:!0,message:"\u8BF7\u8F93\u5165\u5BC6\u7801",trigger:["blur"]}]},N=()=>{var e;if(!n.password)return(e=t.value)==null?void 0:e.focus();x()},x=async()=>{var d;await((d=l.value)==null?void 0:d.validate()),k.set(b,{remember:i.value,account:i.value?n.account:""}),await a.login(n);const{query:{redirect:e}}=u,s=typeof e=="string"?e:Z.INDEX;S.push(s)},{isLock:$,lockFn:A}=ce(x);return oe(()=>{const e=k.get(b);e!=null&&e.remember&&(i.value=e.remember,n.account=e.account)}),(e,s)=>{const d=X,y=Y,w=j,F=z,I=P,K=T,q=M;return _(),f("div",le,[r("div",ue,[r("div",ie,[r("div",pe,[o(d,{src:v.value.login_image,width:400,height:"100%"},null,8,["src"])]),r("div",me,[r("div",de,R(v.value.web_name),1),o(I,{ref_key:"formRef",ref:l,model:n,size:"large",rules:U},{default:c(()=>[o(F,{prop:"account"},{default:c(()=>[o(w,{modelValue:n.account,"onUpdate:modelValue":s[0]||(s[0]=p=>n.account=p),placeholder:"\u8BF7\u8F93\u5165\u8D26\u53F7",onKeyup:V(N,["enter"])},{prepend:c(()=>[o(y,{name:"el-icon-User"})]),_:1},8,["modelValue"])]),_:1}),o(F,{prop:"password"},{default:c(()=>[o(w,{ref_key:"passwordRef",ref:t,modelValue:n.password,"onUpdate:modelValue":s[1]||(s[1]=p=>n.password=p),"show-password":"",placeholder:"\u8BF7\u8F93\u5165\u5BC6\u7801",onKeyup:V(x,["enter"])},{prepend:c(()=>[o(y,{name:"el-icon-Lock"})]),_:1},8,["modelValue"])]),_:1})]),_:1},8,["model"]),r("div",_e,[o(K,{modelValue:i.value,"onUpdate:modelValue":s[2]||(s[2]=p=>i.value=p),label:"\u8BB0\u4F4F\u8D26\u53F7"},null,8,["modelValue"])]),o(q,{type:"primary",size:"large",loading:h($),onClick:h(A)},{default:c(()=>s[3]||(s[3]=[te(" \u767B\u5F55 ")])),_:1},8,["loading","onClick"])])])]),o(ae)])}}});const He=G(fe,[["__scopeId","data-v-5c84973f"]]);export{He as default};
