import{d as A,u as K,p as s,o as L,i as g,a as D,z as M,m as n,k as i,e,K as N,L as R,l as $,v as E}from"./index-deffec86.js";import{I as H}from"./IndexPagePro-904e4e7b.js";import{_ as I}from"./index.vue_vue_type_script_setup_true_name_ProTable_lang-de39478e.js";import{_ as U}from"./index.vue_vue_type_script_setup_true_name_SearchForm_lang-692eb4fd.js";import{T as q}from"./index-0e777de8.js";import{u as G}from"./useTable-823c55eb.js";import{a as O}from"./plan-2fedc155.js";import{g as W}from"./common-8a6acaa7.js";import{u as j}from"./useMatchActivityPlan-b5b1e489.js";import{u as J}from"./useGetTagHook-96c6412e.js";import"./sortable.esm-441d9e5f.js";import"./tagManage-2aab0a1e.js";const pe=A({__name:"index",setup(Q){const{statusList:f}=J(),{columns:_,tableColumns:h,dataCallBack:y}=j([{prop:"status",label:"\u586B\u62A5\u5BA1\u6838\u72B6\u6001",tag:!0,isFilterEnum:!0,width:150,enum:f}],!1,150),{baseParam:C,tableData:b,pageable:o,searchParam:u,handleSizeChange:v,handleCurrentChange:z,getTableList:k,search:p,reset:x}=G(O,{},y),w=K(),T=s(!0),S=s(null),P=t=>{u.value.company_area_id=t,p()},m=s([]),c=s([]),d=s(""),V=async()=>{var l;let t=await W({});m.value=t.data;let a=(l=t==null?void 0:t.data[0])==null?void 0:l.company_area_id;c.value=[a],d.value=String(a)},F=t=>{w.push({name:"nationMatchActivityPlanEdit",query:{type:2,id:t.plan_id}})};return L(async()=>{C.value.plan_type=2,await V(),await k()}),(t,a)=>{const l=g("el-button"),B=g("el-pagination");return D(),M(H,{filterWidth:280},{treeCard:n(()=>[i(q,{ref_key:"TreeFilterRef",ref:S,title:"\u533A\u57DF",data:e(m),defaultValue:e(d),expandKeys:e(c),onChange:P},null,8,["data","defaultValue","expandKeys"])]),searchForm:n(()=>[N(i(U,{"search-param":e(u),columns:e(_),search:e(p),reset:e(x)},null,8,["search-param","columns","search","reset"]),[[R,e(T)]])]),pagination:n(()=>[i(B,{"current-page":e(o).page,"onUpdate:currentPage":a[0]||(a[0]=r=>e(o).page=r),"page-size":e(o).size,"onUpdate:pageSize":a[1]||(a[1]=r=>e(o).size=r),"page-sizes":[10,20,50,100],background:"",layout:"total, sizes, prev, pager, next",total:e(o).count,onSizeChange:e(v),onCurrentChange:e(z)},null,8,["current-page","page-size","total","onSizeChange","onCurrentChange"])]),default:n(()=>[i(I,{columns:e(h),data:e(b)},{tableHeader:n(()=>a[2]||(a[2]=[])),toolButton:n(()=>[$(' <el-button type="primary">\u5BFC\u51FA</el-button> ')]),operation:n(r=>[i(l,{type:"primary",link:"",onClick:X=>F(r.row)},{default:n(()=>a[3]||(a[3]=[E("\u67E5\u770B")])),_:2},1032,["onClick"])]),_:1},8,["columns","data"])]),_:1})}}});export{pe as default};
