import{az as k,d as L,r as f,b as C,p as M,c as o,at as O,e as c,f as j,g as i,h as t,i as u,u as a,w as I,k as p,A as g,F as R,m as d,N as F,E,_ as G}from"./index.0308b213.js";const H=r=>k.request({url:"addon/spread.web.apply/list",params:r}),J=r=>k.request({url:"addon/spread.web.apply/delete",method:"POST",data:r}),x=r=>k.request({url:"addon/spread.web.apply/changeStatus",method:"POST",data:r}),K={class:"filter-form"},Q=d("\u67E5\u8BE2"),W={class:"data"},X={class:"table"},Y=d("\u5DF2\u901A\u8FC7"),Z=d("\u5F85\u5904\u7406"),ee=d("\u5DF2\u62D2\u7EDD"),te={class:"table-operation-btn"},ue={class:"top"},se=d("\u901A\u8FC7"),ae=d("\u62D2\u7EDD"),le=d("\u5220\u9664"),oe={class:"bottom"},ne={class:"pagination"},ce=L({setup(r){let b=f(!1);const s=C({page:1,limit:10,keywords:"",status:""});C({store:[]});const h=C({list:[],count:0});f([]);const _=()=>{b.value=!0,H(s).then(l=>{h.list=l.list,h.count=l.count,b.value=!1})};_(),M(()=>[s.page,s.limit],()=>{_()});const w=()=>{_()};f(!1),f(!1),f(0);const V=l=>{F.alert("\u786E\u5B9A\u9700\u8981\u5220\u9664\u6570\u636E\u5417?","\u63D0\u793A",{confirmButtonText:"\u786E\u8BA4",showCancelButton:!0,cancelButtonText:"\u53D6\u6D88"}).then(()=>{J({id:l}).then(()=>{E({message:"\u5220\u9664\u6210\u529F",type:"success"}),_()})}).catch(()=>{})},z=l=>{console.log(l),F.alert("\u786E\u5B9A\u9700\u8981\u901A\u8FC7\u5417?","\u63D0\u793A",{confirmButtonText:"\u786E\u8BA4",showCancelButton:!0,cancelButtonText:"\u53D6\u6D88"}).then(()=>{x({id:l,status:1}).then(()=>{E({message:"\u901A\u8FC7\u6210\u529F",type:"success"}),_()})}).catch(()=>{})},T=l=>{F.alert("\u786E\u5B9A\u9700\u8981\u62D2\u7EDD\u5417?","\u63D0\u793A",{confirmButtonText:"\u786E\u8BA4",showCancelButton:!0,cancelButtonText:"\u53D6\u6D88"}).then(()=>{x({id:l,status:2}).then(()=>{E({message:"\u62D2\u7EDD\u6210\u529F",type:"success"}),_()})}).catch(()=>{})};return(l,n)=>{const P=o("el-input"),B=o("el-form-item"),y=o("el-option"),q=o("el-select"),D=o("el-button"),N=o("el-form"),m=o("el-table-column"),v=o("el-tag"),S=o("el-table"),U=o("el-pagination"),$=O("loading");return c(),j(R,null,[i("div",K,[t(N,{model:a(s),"label-width":"90px"},{default:u(()=>[t(B,{class:"tn-el-form-item",label:"\u5173\u952E\u8BCD"},{default:u(()=>[t(P,{modelValue:a(s).keywords,"onUpdate:modelValue":n[0]||(n[0]=e=>a(s).keywords=e),placeholder:"\u8BF7\u8F93\u5165\u59D3\u540D/\u624B\u673A\u53F7/\u5907\u6CE8"},null,8,["modelValue"])]),_:1}),t(B,null,{default:u(()=>[t(q,{modelValue:a(s).status,"onUpdate:modelValue":n[1]||(n[1]=e=>a(s).status=e),placeholder:"\u8BF7\u9009\u62E9\u72B6\u6001"},{default:u(()=>[t(y,{label:"\u5F85\u5904\u7406",value:"0"}),t(y,{label:"\u5DF2\u901A\u8FC7",value:"1"}),t(y,{label:"\u5DF2\u62D2\u7EDD",value:"2"})]),_:1},8,["modelValue"])]),_:1}),t(B,null,{default:u(()=>[t(D,{class:"tn-el-form-item--item tn-button tn-button--blue",onClick:w},{default:u(()=>[Q]),_:1})]),_:1})]),_:1},8,["model"])]),i("div",W,[i("div",X,[I((c(),p(S,{data:a(h).list},{default:u(()=>[t(m,{label:"\u59D3\u540D",prop:"name"}),t(m,{label:"\u624B\u673A\u53F7",prop:"mobile"}),t(m,{label:"\u5907\u6CE8",prop:"remark"}),t(m,{label:"\u72B6\u6001",prop:"status"},{default:u(({row:e})=>[e.status==1?(c(),p(v,{key:0,type:"success"},{default:u(()=>[Y]),_:1})):g("",!0),e.status==0?(c(),p(v,{key:1,type:"warning"},{default:u(()=>[Z]),_:1})):g("",!0),e.status==2?(c(),p(v,{key:2,type:"danger"},{default:u(()=>[ee]),_:1})):g("",!0)]),_:1}),t(m,{fixed:"right",label:"\u64CD\u4F5C",width:"290px",align:"center"},{default:u(({row:e})=>[i("div",te,[i("div",ue,[e.status==0?(c(),p(D,{key:0,size:"small",type:"success",onClick:A=>z(e.id)},{default:u(()=>[se]),_:2},1032,["onClick"])):g("",!0),e.status==0?(c(),p(D,{key:1,size:"small",type:"warning",onClick:A=>T(e.id)},{default:u(()=>[ae]),_:2},1032,["onClick"])):g("",!0),t(D,{size:"small",type:"danger",onClick:A=>V(e.id)},{default:u(()=>[le]),_:2},1032,["onClick"])])])]),_:1})]),_:1},8,["data"])),[[$,a(b)]])])]),i("div",oe,[i("div",ne,[t(U,{currentPage:a(s).page,"onUpdate:currentPage":n[2]||(n[2]=e=>a(s).page=e),"page-size":a(s).limit,"onUpdate:page-size":n[3]||(n[3]=e=>a(s).limit=e),"page-sizes":[10,20,30,40],layout:"total, sizes, prev, pager, next, jumper",total:a(h).count},null,8,["currentPage","page-size","total"])])])],64)}}});const de=G(ce,[["__scopeId","data-v-2cb35eb6"]]);export{de as default};
