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-BYcXwl4U.js";import{i as v,c as S}from"./app-a6cKceqE.js";import{_ as y}from"./app-COPzq7M0.js";import{_ as V}from"./app-CQ-vNlMj.js";import{_ as b}from"./app-BS0eerYg.js";import{T as D}from"./app-D2Wz0BUQ.js";import{_ as N}from"./app-DwtlHtUX.js";import{_ as k}from"./app-CignoBaV.js";import{D as w}from"./app-7GBSHA5C.js";import"./app-DCd54JMo.js";import"./app-MrAtUXr3.js";import"./app-BWSI2Z1R.js";import"./app-DPDEogA0.js";import"./app-DxjODhok.js";import"./app-CabATHnR.js";import"./app-BhzV4gWo.js";import"./app-DNz6g4aI.js";import"./app-Ufpj4Ll4.js";import"./app-ysQ8KbGS.js";import"./app--MWyBMkA.js";import"./app-BG60hdvp.js";import"./app-D5k1HLu9.js";import"./app-D3zbrzdO.js";import"./app-BHl80pFw.js";import"./app-CrjU8lgK.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};
