import{_ as C,__tla as P}from"./Dialog-1050d437.js";import{d as U,r as a,o as b,l as A,w as t,i as u,a as r,y as p,j as v,c4 as G,J as H,E as J,s as q,_ as z,__tla as B}from"./index-2c56227b.js";import{g as D,__tla as F}from"./index-0f7aa9db.js";let y,I=Promise.all([(()=>{try{return P}catch{}})(),(()=>{try{return B}catch{}})(),(()=>{try{return F}catch{}})()]).then(async()=>{y=z(U({__name:"OwerSelect",emits:["confirmOwerSelect"],setup(K,{expose:h,emit:w}){const s=a(!1),O=a("\u9009\u62E9"),c=a(!1),V=a(""),k=a(["\u5F85\u9009\u62E9","\u5DF2\u9009\u62E9"]),x=a({key:"id",label:"nickname"}),E=w,o=a([]),l=a([]),S=a([]);h({open:async(n,e)=>{if(s.value=!0,V.value=n,e){c.value=!0;try{e.forEach(i=>{l.value.push(i.id)})}finally{c.value=!1}}S.value=[],o.value=await D()}});const d=()=>{const n=a([]);o.value.forEach(e=>{l.value.indexOf(e.id)>-1&&n.value.push(e)}),E("confirmOwerSelect",n),s.value=!1,l.value=[]};return(n,e)=>{const i=G,m=H,f=J,g=q,j=C;return b(),A(j,{title:r(O),modelValue:r(s),"onUpdate:modelValue":e[1]||(e[1]=_=>p(s)?s.value=_:null),width:"600px"},{default:t(()=>[u(i,{modelValue:r(l),"onUpdate:modelValue":e[0]||(e[0]=_=>p(l)?l.value=_:null),data:r(o),titles:r(k),props:r(x),"right-default-checked":[1]},null,8,["modelValue","data","titles","props"]),u(g,{justify:"end"},{default:t(()=>[u(f,{span:4},{default:t(()=>[u(m,{type:"primary",onClick:d},{default:t(()=>[v("\u786E\u8BA4")]),_:1})]),_:1}),u(f,{span:4},{default:t(()=>[u(m,{type:"primary",onClick:d},{default:t(()=>[v("\u53D6\u6D88")]),_:1})]),_:1})]),_:1})]),_:1},8,["title","modelValue"])}}}),[["__file","E:/GAOHP_2023/mall/newfeifan-front/yudao-ui-admin-vue3/src/views/crm/contact/OwerSelect.vue"]])});export{I as __tla,y as default};
