System.register(["./index.vue_vue_type_script_setup_true_lang-legacy-LjZ-8uGn.js?v=1773287522785","./index-legacy-DQdImDha.js?v=1773287522785","./useLoading-legacy-IiShPpjk.js?v=1773287522785","./index-legacy-BJ5UIh35.js?v=1773287522785","./vue-core-legacy-Cn1vuJ3s.js?v=1773287522785","./naive-ui-legacy-BW82sq8q.js?v=1773287522785","./prismjs-legacy-BN0FEcG9.js?v=1773287522785","./index.vue_vue_type_script_setup_true_lang-legacy-BWPgT9-g.js?v=1773287522785","./index.vue_vue_type_script_setup_true_lang-legacy-BQ2Kqzbl.js?v=1773287522785","./index.vue_vue_type_script_setup_true_lang-legacy-BBkGleHZ.js?v=1773287522785","./data-legacy-B9xdUIE5.js?v=1773287522785","./index.vue_vue_type_script_setup_true_lang-legacy-IFFYkvEY.js?v=1773287522785","./useTableColumns-legacy-DP6ypvsQ.js?v=1773287522785","./index-legacy-hh1mlQOF.js?v=1773287522785","./copy-legacy-CoXPjkKf.js?v=1773287522785","./index-legacy-DgZ0-E4f.js?v=1773287522785","./index.vue_vue_type_script_setup_true_lang-legacy-B9P08_gB.js?v=1773287522785","./index-legacy-BFkuWVH1.js?v=1773287522785","./useTableData-legacy-3kc3lnk4.js?v=1773287522785","./mail-legacy-BX4bHMTA.js?v=1773287522785"],(function(e,a){"use strict";var l,n,i,s,t,u,o,r,p,_,c,d,v,g,m,y,j,x,f,h,b,w,M,S,k,$,P;return{setters:[e=>{l=e._},e=>{n=e.m,i=e.cm,s=e.i},e=>{t=e.u},e=>{u=e.i},e=>{o=e.k,r=e.R,p=e.r,_=e.e,c=e.am,d=e.$,v=e.Z,g=e.a0,m=e.a9,y=e._,j=e.S,x=e.a8,f=e.j,h=e.aa,b=e.ak,w=e.F},e=>{M=e.a1,S=e.au,k=e.b,$=e.av,P=e.a6},null,null,null,null,null,null,null,null,null,null,null,null,null,null],execute:function(){const a={class:"p-20px pt-24px pb-8px"},W={class:"w-240px"},C={class:"w-240px"};e("default",o({__name:"install",props:{domain:{type:Object}},emits:["refresh"],setup(e,{expose:o,emit:E}){const I=E,{t:L}=r(),R=p(null),T=_({domain:"",php_version:null}),U={domain:{trigger:"change",validator:()=>""!==T.domain.trim()||new Error(L("Mail.Setting.index_20"))},php_version:{trigger:"change",validator:()=>null!==T.php_version||new Error(L("Mail.Setting.index_21"))}},Z=p([]),D=async()=>{const{message:e}=await i();if(s(e)){Z.value=e.versions.reverse().map((e=>({label:e.name,value:e.version})));const a=e.versions.findIndex((e=>"74"===e.version));T.php_version=-1!==a?e.versions[a].version:e.versions[0].version}},{loading:F,setLoading:H}=t(),O=c();return(async()=>{try{H(!0),await Promise.all([D()])}finally{H(!1)}})(),o({onConfirm:async()=>{await(R.value?.validate()),await u({webmail_domain:`${T.domain}.${e.domain?.domain||""}`,php_version:T.php_version||"",domain:e.domain?.domain||""});const{close:a}=n.success({content:()=>g(w,null,[f("WebMail Installation Successful, "),g("br",null,null),f(' Manage WebMail view in "'),g("a",{class:"bt-link",href:"javascript:;",onClick:()=>{O.push("/site/php"),a()}},[f("Website > PHP Project")]),f('"')]),close:!0,maxWidth:480});I("refresh")}}),(n,i)=>{const s=k,t=$,u=S,o=M,r=P,p=l;return d(),v("div",a,[g(p,{ref_key:"formRef",ref:R,model:j(T),rules:U},{default:m((()=>[g(o,{label:n.$t("Mail.Setting.index_18"),path:"domain"},{default:m((()=>[y("div",W,[g(u,null,{default:m((()=>[g(s,{value:j(T).domain,"onUpdate:value":i[0]||(i[0]=e=>j(T).domain=e)},null,8,["value"]),e.domain?.domain?(d(),x(t,{key:0},{default:m((()=>[f(" ."+h(e.domain?.domain),1)])),_:1})):b("",!0)])),_:1})])])),_:1},8,["label"]),g(o,{label:n.$t("Mail.Setting.index_19"),path:"php_version"},{default:m((()=>[y("div",C,[g(r,{value:j(T).php_version,"onUpdate:value":i[1]||(i[1]=e=>j(T).php_version=e),loading:j(F),options:j(Z)},null,8,["value","loading","options"])])])),_:1},8,["label"])])),_:1},8,["model"])])}}}))}}}));
