import{d as x,r as y,b as k,a6 as B,p as d,c as p,e as o,k as m,i as g,f as S,j as C,m as F,t as L,u as V,F as w,az as E}from"./index.0308b213.js";const j=x({props:{agentid:{type:Number,default:0},sid:{type:[Number,Array],default:0},multiple:{type:Boolean,default:!1}},emits:["changeStore"],setup(n,{emit:f}){const l=n,a=y({agentid:"",sid:"",multiple:!0}),i=k({list:[]}),{OpPlatform:r}=B();let s="";r.value=="agent"?s="agent/shop.index/selectList":s="adminapi/shop.index/selectList";const u=()=>{r.value=="agent"||E.post(s,{agentid:l.agentid}).then(e=>{i.list=e,console.log(e,"==============res8888888888")}).catch(e=>{console.log(e)})},h=e=>{f("changeStore",e),console.log(e,"===========")};return u(),d(()=>l.sid,()=>{a.value.sid=l.sid},{immediate:!0}),d(()=>l.agentid,()=>{u()},{immediate:!0}),(e,c)=>{const _=p("el-option"),b=p("el-select");return o(),m(b,{class:"agent-select",onChange:h,modelValue:a.value.sid,"onUpdate:modelValue":c[0]||(c[0]=t=>a.value.sid=t),placeholder:"\u8BF7\u9009\u62E9\u5E97\u94FA",filterable:"",clearable:"",multiple:n.multiple},{default:g(()=>[(o(!0),S(w,null,C(V(i).list,(t,v)=>(o(),m(_,{key:v,value:t.id,label:t.title},{default:g(()=>[F(L(t.title),1)]),_:2},1032,["value","label"]))),128))]),_:1},8,["modelValue","multiple"])}}});export{j as _};
