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.vue_vue_type_script_setup_true_lang-legacy-CERfgfry.js?v=1773287522785","./vue-core-legacy-Cn1vuJ3s.js?v=1773287522785","./naive-ui-legacy-BW82sq8q.js?v=1773287522785","./prismjs-legacy-BN0FEcG9.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"],(function(e,l){"use strict";var a,t,s,n,u,i,r,c,_,d,o,g,p,y,v,j,f,x;return{setters:[e=>{a=e._},e=>{t=e.n,s=e.m},e=>{n=e.u},e=>{u=e.$,i=e.a0},e=>{r=e.k,c=e.R,_=e.r,d=e.$,o=e.Z,g=e.a0,p=e.a9,y=e._,v=e.S,j=e.X},e=>{f=e.a1,x=e.a6},null,null,null,null,null,null,null,null],execute:function(){const l={class:"p-20px"},m={class:"w-150px"};e("default",r({__name:"batch",props:{data:{}},setup(e,{expose:r}){const b=e,{t:h}=c(),{siteType:w,ids:P,onRefresh:S}=b.data,H=_(null),T=_([]),{loading:$,setLoading:k}=n();return(async()=>{try{k(!0);const{message:e}=await u({project_type:w});t(e)&&e.length>0?(T.value=e.map((e=>({label:e.name,value:e.id}))),H.value=e[0].id):(H.value=null,T.value=[])}finally{k(!1)}})(),r({onConfirm:async({hide:e})=>{await i((()=>{if(null===H.value)throw s.error(h("Site.PHP.add_site_46")),new Error(h("Site.PHP.add_site_46"));return{id:H.value,site_ids:JSON.stringify(P),project_type:w}})()),S(),e()}}),(e,t)=>{const s=x,n=f,u=a;return d(),o("div",l,[g(u,null,{default:p((()=>[g(n,{label:e.$t("Site.PHP.add_site_22"),"show-feedback":!1},{default:p((()=>[y("div",m,[g(s,{value:v(H),"onUpdate:value":t[0]||(t[0]=e=>j(H)?H.value=e:null),loading:v($),options:v(T)},null,8,["value","loading","options"])])])),_:1},8,["label"])])),_:1})])}}}))}}}));
