import{r as p,o as n,g as l,b as e,u as o,w as u,F as m,a as t,t as c,d as _,e as f,D as h,c as g,f as $,h as x}from"./app-DnroACXc.js";import{i as v,c as S}from"./app-DckefXYL.js";import{_ as y}from"./app-Cx6egK0r.js";import{_ as V}from"./app-MnSDCF4P.js";import{_ as b}from"./app-BroehdXH.js";import{T as D}from"./app-B8VsrFxM.js";import{_ as N}from"./app-BbRQPmFH.js";import{_ as k}from"./app-COct4tsy.js";import{D as w}from"./app-Cx7ENVlu.js";import"./app-C9iVkiu5.js";import"./app-DrIi-dNq.js";import"./app-zueB50zj.js";import"./app-B0NrURRk.js";import"./app-Co2SIBzr.js";import"./app-CUPmXIij.js";import"./app-Cu6FD8m8.js";import"./app-CjXaciNY.js";import"./app-DPkDcD7h.js";import"./app-CF0qXH5Q.js";import"./app-Dd07dUxy.js";import"./app-CYYQ_Zep.js";import"./app-NVAx7Sc3.js";import"./app-B09rlSqG.js";import"./app-B4bUdtyo.js";import"./app-LqsmzyUT.js";function I(){v(this),this.$delay(function(){this.changeUserId(this.domain.userId)}),this.success=this.$NotifyReloadSuccess("保存成功"),this.hasGroups=!1,this.changeUserId=function(a){this.$post("/ns/domains/groups/options").params({userId:a}).success(function(i){this.hasGroups=i.data.groups.length>0,this.hasGroups&&this.$delay(function(){this.$refs.groupSelector.reload(a)})})}}const T=["value"],B=t("td",{class:"title"},"域名 *",-1),C=t("td",null,"DNS服务器",-1),G={class:"label-group"},H={key:0},O=t("td",null,"所属分组",-1),U=t("td",null,"启用当前域名",-1),ut={__name:"update",setup(a){const i=p(),s=S(new I,{refs:{groupSelector:i}});return(F,d)=>(n(),l(m,null,[e(y,{ctx:o(s),activeTab:"update"},null,8,["ctx"]),e(V,{action:"$",onSuccess:o(s).success},{default:u(()=>[t("input",{type:"hidden",name:"domainId",value:o(s).domain.id},null,8,T),e(w,null,{default:u(()=>[t("tbody",null,[t("tr",null,[B,t("td",null,c(o(s).domain.name),1)]),_(t("tr",null,[C,t("td",null,[t("div",G,[(n(!0),l(m,null,h(o(s).dnsHosts,r=>(n(),g(D,{outlined:""},{default:u(()=>[$(c(r),1)]),_:2},1024))),256))])])],512),[[f,o(s).dnsHosts!=null&&o(s).dnsHosts.length>0]]),o(s).hasGroups?(n(),l("tr",H,[O,t("td",null,[e(b,{"v-domain-group-id":o(s).domain.groupId,ref_key:"groupSelector",ref:i},null,8,["v-domain-group-id"])])])):x("",!0),t("tr",null,[U,t("td",null,[e(N,{name:"isOn",value:"1",modelValue:o(s).domain.isOn,"onUpdate:modelValue":d[0]||(d[0]=r=>o(s).domain.isOn=r)},null,8,["modelValue"])])])])]),_:1}),e(k)]),_:1},8,["onSuccess"])],64))}};export{ut as default};
