System.register(["./index.vue_vue_type_script_setup_true_lang-legacy.js?v=1753954525509","./page_layout-legacy.js?v=1753954525509","./index-legacy124.js?v=1753954525509","./vue-legacy.js?v=1753954525509","./naive-legacy.js?v=1753954525509","./common-legacy.js?v=1753954525509","./__commonjsHelpers__-legacy.js?v=1753954525509","./public-legacy.js?v=1753954525509","./index-legacy.js?v=1753954525509","./index.vue_vue_type_script_setup_true_lang-legacy4.js?v=1753954525509","./index.vue_vue_type_script_setup_true_lang-legacy7.js?v=1753954525509","./index.vue_vue_type_script_setup_true_lang-legacy6.js?v=1753954525509"],(function(e,a){"use strict";var l,s,t,u,n,r,i,p,d,o,_,c,v,g,b,x,y,m,f;return{setters:[e=>{l=e._},e=>{s=e.bi,t=e.gq},e=>{u=e._},e=>{n=e.k,r=e.P,i=e.r,p=e.e,d=e.U,o=e.V,_=e.Q,c=e.a2,v=e.X,g=e.a1,b=e.al},e=>{x=e.cA,y=e.aq,m=e.cG,f=e.bY},null,null,null,null,null,null,null],execute:function(){const a={class:"p-16px"};e("default",n({__name:"index",props:{data:{}},setup(e,{expose:n}){const{t:h}=r(),w=e,{getList:j}=w.data,D=i(null),q=p({sid:0,username:"",password:s(10),host:"127.0.0.1",ip:""}),$={username:{required:!0,message:h("Config.Panel.index_60"),trigger:["blur","input"]},password:{required:!0,message:h("Config.Panel.index_67"),trigger:["blur","input"]},ip:{trigger:["blur","input"],validator:()=>"ip"!==q.host||""!==q.ip||new Error(h("Database.Mysql.index_6"))}},U=i([{label:h("Database.form.index_13"),value:"%"},{label:h("Database.form.index_12"),value:"127.0.0.1"},{label:h("Database.form.index_14"),value:"ip"}]);return n({onConfirm:async()=>{await(D.value?.validate()),await t({sid:q.sid,username:q.username,password:q.password,host:"ip"===q.host?q.ip:q.host,db_name:"*",tb_name:"*"}),j?.()}}),(e,s)=>{const t=x,n=y,r=m,i=f,p=l;return d(),o("div",a,[_(p,{ref_key:"formRef",ref:D,model:v(q),rules:$},{default:c((()=>[_(t,{label:e.$t("Database.Mysql.index_5"),path:"server"},{default:c((()=>[_(u,{class:"w-200px",value:v(q).sid,"onUpdate:value":s[0]||(s[0]=e=>v(q).sid=e)},null,8,["value"])])),_:1},8,["label"]),_(t,{label:e.$t("Database.index_13"),path:"username"},{default:c((()=>[_(n,{class:"w-350px!",value:v(q).username,"onUpdate:value":s[1]||(s[1]=e=>v(q).username=e),placeholder:e.$t("Config.Panel.index_60")},null,8,["value","placeholder"])])),_:1},8,["label"]),_(t,{label:e.$t("Database.index_14"),path:"password"},{default:c((()=>[_(n,{class:"w-350px!",value:v(q).password,"onUpdate:value":s[2]||(s[2]=e=>v(q).password=e),placeholder:e.$t("Config.Panel.index_67")},null,8,["value","placeholder"])])),_:1},8,["label"]),_(i,null,{default:c((()=>[_(t,{label:e.$t("Database.Mysql.index_4")},{default:c((()=>[_(r,{class:"w-200px",value:v(q).host,"onUpdate:value":s[3]||(s[3]=e=>v(q).host=e),options:v(U)},null,8,["value","options"])])),_:1},8,["label"]),_(t,{"show-label":!1,path:"ip"},{default:c((()=>["ip"===v(q).host?(d(),g(n,{key:0,class:"w-150px!",value:v(q).ip,"onUpdate:value":s[4]||(s[4]=e=>v(q).ip=e),placeholder:e.$t("Database.Mysql.index_6")},null,8,["value","placeholder"])):b("",!0)])),_:1})])),_:1})])),_:1},8,["model"])])}}}))}}}));
