import{_ as a}from"./index.vue_vue_type_script_setup_true_lang.js?v=1763625242172";import{_ as e}from"./index.vue_vue_type_script_setup_true_lang2.js?v=1763625242172";import{bn as s,fS as r}from"./page_layout.js?v=1763625242172";import"./public.js?v=1763625242172";import{k as t,P as o,r as p,e as l,R as n,a2 as d,a3 as u,X as i,U as m,V as _,N as f}from"./vue.js?v=1763625242172";import{au as v,dP as w}from"./naive.js?v=1763625242172";import"./index98.js?v=1763625242172";import"./common.js?v=1763625242172";import"./__commonjsHelpers__.js?v=1763625242172";const c={class:"w-280px"},x={class:"w-280px"},b=t({__name:"index",props:{data:{}},setup(t,{expose:b}){const{t:j}=o(),y=t,{row:g}=y.data,h=s(),D=p(null),R=l({name:g.username,password:g.password}),U={password:{trigger:["blur","input"],validator:()=>R.password?!(R.password.length<6)||new Error(j("Database.form.index_20")):new Error(j("Database.form.index_17"))}};return b({onConfirm:async()=>{var a;try{await(null==(a=D.value)?void 0:a.validate());const e={id:g.id,...f(R)};await r(h.type,e),h.setRefresh(!0)}catch(e){console.warn(e)}}}),(s,r)=>{const t=v,o=w,p=e,l=a;return n(),d(l,{ref_key:"formRef",ref:D,model:_(R),rules:U,class:"px-20px pt-28px pb-8px"},{default:u((()=>[i(o,{label:s.$t("Database.index_13"),path:"name"},{default:u((()=>[m("div",c,[i(t,{value:_(R).name,"onUpdate:value":r[0]||(r[0]=a=>_(R).name=a),disabled:!0},null,8,["value"])])])),_:1},8,["label"]),i(o,{label:s.$t("Database.index_14"),path:"password"},{default:u((()=>[m("div",x,[i(p,{value:_(R).password,"onUpdate:value":r[1]||(r[1]=a=>_(R).password=a),default:!_(g).password,"input-props":{name:"password"}},null,8,["value","default"])])])),_:1},8,["label"])])),_:1},8,["model"])}}});export{b as default};
