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-SC54XQDl.js";import{i as v,c as S}from"./app-Ba7ZqSpq.js";import{_ as y}from"./app-DhIf-bPn.js";import{_ as V}from"./app-DFulsyXy.js";import{_ as b}from"./app-BPiEnth_.js";import{T as D}from"./app-DoVkxbmA.js";import{_ as N}from"./app-FlPLZh9D.js";import{_ as k}from"./app-DWUwCFNm.js";import{D as w}from"./app-ZeVDYyDS.js";import"./app-CL60OiIv.js";import"./app-D9TrJBlL.js";import"./app-_Ovp2dOH.js";import"./app-BjSCO7rC.js";import"./app-Dhl-Bw0H.js";import"./app-B2C_dtYI.js";import"./app-COidJXl1.js";import"./app-DPYq7hh-.js";import"./app-CVQkwzlf.js";import"./app-DnXuoh8P.js";import"./app-BPIIxVwk.js";import"./app-PPG0ZS4d.js";import"./app-Dw0jKdCD.js";import"./app-C2mBgI5Z.js";import"./app-DZaelcLs.js";import"./app-CNHjdV6U.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};
