import{P as a,e as s}from"./utils-lib.js?v=1761009159";import{c as t,r as e,e as l,q as c,v as p,x as m,z as o,K as r,C as n,A as i,D as d,B as f,N as u,b1 as D}from"./base-lib.js?v=1761009159";import{setSiteDns as x}from"./site.js?v=1761009159";import"./__commonjsHelpers__.js?v=1761009159";const y={class:"p-28px"},v={class:"flex items-center"},g={key:0,class:"flex flex-col flex-shrink w-full ml-32px",style:{gap:"12px"}},S={key:0,class:"flex flex-col"},k={class:"flex items-center"},h={class:"flex items-center"},b={key:1,class:"text-danger my-8px"},q={key:2,class:"text-danger my-8px"},w={key:3,class:"flex flex-col"},_={key:0,class:"flex items-center"},j={class:"flex items-center"},P={class:"flex items-center"},T={key:1,class:"flex items-center"},A={key:4,class:"flex items-center"},F={key:5,class:"text-danger my-8px"},z={key:6,class:"my-8px"},B={key:1,class:"ml-1rem"},C=t({__name:"add-result",props:{compData:{default:()=>({ftp:!0,sql:!0,ftpStatus:!0,databaseStatus:!0,ftpData:{username:"",password:""},sqlData:{username:"",password:""},siteStatus:!0,site:{name:""},accessSite:""})}},setup(t){const C=t,H=e([]);e([{label:"域名",prop:"domain",width:120},{label:"结果",prop:"msg",align:"right",showOverflowTooltip:!0,render:a=>a.msg?l("div",{class:"truncate ".concat(a.status?"text-primary":"text-danger")},[a.msg]):l("div",{class:"svgtofont-el-loading text-base"},null)}]);return c(()=>{(async()=>{var s;C.compData.dns&&(H.value=C.compData.dns,a({request:x({domains:null==(s=H.value.map(a=>a.domain))?void 0:s.join(",")}),data:[Array,H]}))})()}),(a,t)=>{const e=D,c=s;return p(),m("div",y,[o("div",v,[o("i",{class:r(["svgtofont-el-success-filled text-primary","".concat(a.compData.title?"!text-titleLarge":"!text-large100")])},null,2),a.compData.ftp||a.compData.sql?(p(),m("div",g,[a.compData.ftp&&a.compData.ftpStatus?(p(),m("div",S,[t[2]||(t[2]=n(" FTP账号资料 ",-1)),l(e,{class:"!my-8px"}),o("span",k,[t[0]||(t[0]=n(" 用户： ",-1)),o("strong",null,i(a.compData.ftpData.username),1)]),o("span",h,[t[1]||(t[1]=n(" 密码： ",-1)),o("strong",null,i(a.compData.ftpData.password),1)])])):d("",!0),a.compData.ftp&&!a.compData.ftpStatus?(p(),m("div",b,"FTP账号添加失败！")):d("",!0),a.compData.sql&&!a.compData.databaseStatus?(p(),m("div",q,"数据库添加失败！")):d("",!0),a.compData.sql&&a.compData.databaseStatus?(p(),m("div",w,[t[7]||(t[7]=n(" 数据库账号资料 ",-1)),l(e,{class:"!my-8px"}),a.compData.siteStatus?(p(),m("span",_,[t[3]||(t[3]=n(" 数据库名： ",-1)),o("strong",null,i(a.compData.sqlData.username),1)])):d("",!0),o("span",j,[t[4]||(t[4]=n(" 用户： ",-1)),o("strong",null,i(a.compData.sqlData.username),1)]),o("span",P,[t[5]||(t[5]=n(" 密码： ",-1)),o("strong",null,i(a.compData.sqlData.password),1)]),a.compData.siteStatus&&a.compData.site.name?(p(),m("span",T,[t[6]||(t[6]=n(" 访问站点： ",-1)),l(c,{href:"http://"+a.compData.site.name},{default:f(()=>[n(i("http://"+a.compData.site.name),1)]),_:1},8,["href"])])):d("",!0)])):d("",!0),a.compData.accessSite?(p(),m("span",A,[t[8]||(t[8]=o("div",{class:"whitespace-nowrap"},"初次启动url：",-1)),a.compData.accessSite?(p(),u(c,{key:0,href:a.compData.accessSite},{default:f(()=>[n(i(a.compData.accessSite),1)]),_:1},8,["href"])):d("",!0)])):d("",!0),a.compData.siteStatus?d("",!0):(p(),m("div",F,"网站添加失败！")),a.compData.siteStatus?(p(),m("div",z,"网站添加成功！")):d("",!0)])):(p(),m("div",B,i(a.compData.title),1))])])}}});export{C as default};
