import{d as w,a6 as z,b as h,r as f,p as P,c as u,e as b,f as U,g as i,h as l,i as n,u as o,k as N,A as I,a1 as L,m as d,t as y,F as T,E as K,_ as O}from"./index.0308b213.js";import{d as $,h as j}from"./setting.ffe79858.js";import{u as q}from"./useAgent.c0cb1751.js";import{A as M}from"./index.1d26a072.js";import"./list.5526c7ef.js";import"./install.524ae6f2.js";const Q={class:"filter-form"},G=d("\u7B5B\u9009"),H={class:"data"},J={class:"operation-container"},R={class:"operation-btn"},W=d("\u8BBE\u7F6E\u7279\u6B8A\u914D\u9001\u63D0\u793A\u8BED"),X={class:"table"},Y={class:"bottom"},Z={class:"pagination"},ee=w({setup(te){const{OpPlatform:B}=z(),a=h({keyword:"",agentid:"",areaid:"",page:1,limit:20});a.agentid=sessionStorage.getItem("shangpu_tuniao_agent_id");const p=h({list:[],count:0});let c=f([]);f("");const m=()=>{$(a).then(s=>{p.list=s.list,p.count=s.count})};m();const{getAgentList:A,getAgentTitle:D}=q();A();const _=f(""),x=s=>{if(c.value.length===0){K({message:"\u8BF7\u9009\u62E9\u9700\u8981\u64CD\u4F5C\u7684\u6570\u636E",type:"error"});return}j({ids:String(c.value),text:s}).then(e=>{console.log(e),m()})},g=()=>{a.page=1,m()},F=s=>{c.value=s.map(e=>String(e.id))};return P(()=>[a.page,a.limit],()=>{m()}),(s,e)=>{const E=u("el-input"),v=u("el-button"),S=u("el-form-item"),V=u("el-form"),r=u("el-table-column"),C=u("el-table"),k=u("el-pagination");return b(),U(T,null,[i("div",Q,[l(V,{model:o(a),"label-width":"80px"},{default:n(()=>[l(S,{class:"tn-el-form-item",label:"\u4EE3\u7406\u533A\u57DF"},{default:n(()=>[o(B)=="shangpu"?(b(),N(o(M),{key:0,modelValue:o(a).agentid,"onUpdate:modelValue":e[0]||(e[0]=t=>o(a).agentid=t),onChange:g},null,8,["modelValue"])):I("",!0),l(E,{modelValue:o(a).keyword,"onUpdate:modelValue":e[1]||(e[1]=t=>o(a).keyword=t),placeholder:"\u95E8\u5E97\u540D\u79F0/\u95E8\u5E97id",onKeyup:e[2]||(e[2]=L(t=>g(),["enter"])),style:{width:"auto","margin-left":"10px"}},null,8,["modelValue"]),l(v,{type:"primary",onClick:g,style:{"margin-left":"10px"}},{default:n(()=>[G]),_:1})]),_:1})]),_:1},8,["model"])]),i("div",H,[i("div",J,[i("div",R,[l(E,{modelValue:_.value,"onUpdate:modelValue":e[3]||(e[3]=t=>_.value=t),placeholder:"\u8F93\u5165\u7279\u6B8A\u914D\u9001\u63D0\u793A\u8BED\u5E76\u52FE\u9009\u76F8\u5E94\u5546\u6237",style:{width:"300px","margin-left":"10px"},clearable:""},null,8,["modelValue"]),l(v,{class:"btn",type:"primary",onClick:e[4]||(e[4]=t=>x(_.value)),style:{"margin-left":"10px"}},{default:n(()=>[W]),_:1})])]),i("div",X,[l(C,{data:o(p).list,onSelectionChange:F},{default:n(()=>[l(r,{type:"selection",width:"55"}),l(r,{label:"id",prop:"id"}),l(r,{label:"\u6240\u5C5E\u4EE3\u7406"},{default:n(({row:t})=>[d(y(o(D)(t.agentid)),1)]),_:1}),l(r,{label:"\u5E97\u94FA\u540D\u79F0"},{default:n(({row:t})=>[d(y(t.title),1)]),_:1}),l(r,{align:"center",label:"\u7279\u6B8A\u914D\u9001\u63D0\u793A\u8BED"},{default:n(({row:t})=>[d(y(t.special_delivery_status),1)]),_:1})]),_:1},8,["data"])])]),i("div",Y,[i("div",Z,[l(k,{currentPage:o(a).page,"onUpdate:currentPage":e[5]||(e[5]=t=>o(a).page=t),"page-size":o(a).limit,"onUpdate:page-size":e[6]||(e[6]=t=>o(a).limit=t),"page-sizes":[10,20,30,40],layout:"total, sizes, prev, pager, next, jumper",total:o(p).count},null,8,["currentPage","page-size","total"])])])],64)}}});const ie=O(ee,[["__scopeId","data-v-aa6d788a"]]);export{ie as default};
