lock-4ece2fa6.js 1018 B

1
  1. var r=(I,e,t)=>new Promise((n,s)=>{var a=o=>{try{l(t.next(o))}catch(i){s(i)}},c=o=>{try{l(t.throw(o))}catch(i){s(i)}},l=o=>o.done?n(o.value):Promise.resolve(o.value).then(a,c);l((t=t.apply(I,e)).next())});import{cI as g,g2 as f,g3 as k,g as u,__tla as L}from"./index-b5895273.js";let h,m=Promise.all([(()=>{try{return L}catch(I){}})()]).then(()=>r(void 0,null,function*(){h=g({id:"app-lock",state:()=>({lockInfo:f.getLocal(k)}),getters:{getLockInfo(){return this.lockInfo}},actions:{setLockInfo(e){this.lockInfo=Object.assign({},this.lockInfo,e),f.setLocal(k,this.lockInfo,!0)},resetLockInfo(){f.removeLocal(k,!0),this.lockInfo=null},unLock(e){return r(this,null,function*(){var n;const t=u();return((n=this.lockInfo)==null?void 0:n.pwd)===e?(this.resetLockInfo(),!0):yield(()=>r(this,null,function*(){var s;try{const a=(s=t.getUserInfo)==null?void 0:s.userName,c=yield t.login({userName:a,password:e,goHome:!1,mode:"none"});return c&&this.resetLockInfo(),c}catch(a){return!1}}))()})}}})}));export{m as __tla,h as u};