import{a as E}from"./index.f03e77c5.js";import{a as F}from"./index.cc3a594a.js";import{d as B,a6 as z,r as P,b,p as C,c as u,e as U,k as A,i,g as c,h as l,u as a,q as L,m as h,_ as N}from"./index.0308b213.js";const O={class:"filter-form"},q=h("\u641C\u7D22"),I={class:"table"},j=["src"],G=h("\u9009\u62E9"),Q={class:"pagination"},R=B({props:{modelValue:{type:Boolean,default:!1},agentid:{default:0}},emits:["update:modelValue","onClose","onSelect"],setup(y,{emit:r}){const _=y,{OpPlatform:V}=z();let d=P(!1);const t=b({keyword:"",page:1,limit:10}),s=b({list:[],count:0}),m=()=>{console.log("props.agentid",_.agentid),t.agentid=_.agentid,V.value==="agent"?F(t).then(o=>{s.count=o.count,s.list=o.list}):E(t).then(o=>{s.count=o.count,s.list=o.list})};C(()=>_.modelValue,o=>{d.value=o,o&&m()}),C(()=>[t.page,t.limit],()=>{m()});const v=()=>{m()},x=o=>{r("onSelect",o),g()},g=()=>{r("update:modelValue",!1),r("onClose")};return(o,n)=>{const D=u("el-input"),f=u("el-button"),p=u("el-table-column"),S=u("el-table"),k=u("el-pagination"),w=u("el-dialog");return U(),A(w,{modelValue:a(d),"onUpdate:modelValue":n[3]||(n[3]=e=>L(d)?d.value=e:d=e),title:"\u9009\u62E9\u5546\u6237",width:"50%","destroy-on-close":"","append-to-body":!0,onClose:g},{default:i(()=>[c("div",O,[l(D,{modelValue:a(t).keyword,"onUpdate:modelValue":n[0]||(n[0]=e=>a(t).keyword=e),placeholder:"\u8BF7\u8F93\u5165\u5546\u6237\u540D\u79F0\u8FDB\u884C\u641C\u7D22"},null,8,["modelValue"]),l(f,{type:"primary",onClick:v},{default:i(()=>[q]),_:1})]),c("div",I,[l(S,{data:a(s).list,height:"400px"},{default:i(()=>[l(p,{label:"\u95E8\u5E97LOGO",width:"100px"},{default:i(({row:e})=>[c("img",{class:"thumb",src:e.logo},null,8,j)]),_:1}),l(p,{label:"\u95E8\u5E97ID",prop:"id"}),l(p,{label:"\u95E8\u5E97\u540D\u79F0",prop:"title"}),l(p,{fixed:"right",label:"\u64CD\u4F5C",width:"90px"},{default:i(({row:e})=>[l(f,{onClick:T=>x(e)},{default:i(()=>[G]),_:2},1032,["onClick"])]),_:1})]),_:1},8,["data"])]),c("div",Q,[l(k,{currentPage:a(t).page,"onUpdate:currentPage":n[1]||(n[1]=e=>a(t).page=e),"page-size":a(t).limit,"onUpdate:page-size":n[2]||(n[2]=e=>a(t).limit=e),"page-sizes":[10,20,30,40],layout:"total, sizes, prev, pager, next, jumper",total:a(s).count},null,8,["currentPage","page-size","total"])])]),_:1},8,["modelValue"])}}});const M=N(R,[["__scopeId","data-v-c337f550"]]);export{M as default};
