import{_ as a}from"./index.vue_vue_type_script_setup_true_lang.js?v=1753954525509";import{_ as e}from"./index.vue_vue_type_script_setup_true_lang2.js?v=1753954525509";import{b1 as s,eX as r}from"./page_layout.js?v=1753954525509";import"./public.js?v=1753954525509";import{k as t,P as o,r as p,e as l,U as n,a1 as d,a2 as u,Q as i,W as m,X as _,N as f}from"./vue.js?v=1753954525509";import{aq as v,cA as w}from"./naive.js?v=1753954525509";import"./index96.js?v=1753954525509";import"./common.js?v=1753954525509";import"./__commonjsHelpers__.js?v=1753954525509";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),U=l({name:g.username,password:g.password}),k={password:{trigger:["blur","input"],validator:()=>U.password?!(U.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(U)};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:_(U),rules:k,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:_(U).name,"onUpdate:value":r[0]||(r[0]=a=>_(U).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:_(U).password,"onUpdate:value":r[1]||(r[1]=a=>_(U).password=a),default:!_(g).password,"input-props":{name:"password"}},null,8,["value","default"])])])),_:1},8,["label"])])),_:1},8,["model"])}}});export{b as default};
