import{T as f}from"./TableV2Empty-b6abe229.js";import{g as k}from"./index-ab911583.js";import{u as I,r as i,B as C,o as x,C as K,f as d,G as D,a as l,c as N,g as c,w as u,H as B,k as T}from"./index-ad591d72.js";import{_ as G}from"./_plugin-vue_export-helper-c27b6911.js";import"./request-2786ead7.js";import"./axios-4a70c6fc.js";const P={class:"tablev2-container shadow"},R=25,z={__name:"distributionData",setup(E){const{t,locale:h}=I();i(""),i("");const a=i(!1),r=i(null),n=i([{key:"index",dataKey:"ID",title:t("equipmentManagement.index"),align:"center",width:50},{key:"Name",dataKey:"Name",title:t("distribution.distributionInfo.Name"),align:"center",width:120},{key:"Bib",dataKey:"Bib",title:t("distribution.distributionInfo.Bib"),align:"center",width:120},{key:"Gender",dataKey:"Gender",title:t("distribution.distributionInfo.Gender"),align:"center",width:70},{key:"Contest",dataKey:"Contest",title:t("distribution.distributionInfo.Contest"),align:"center",width:100},{key:"IdCode",dataKey:"IdCode",title:t("distribution.distributionInfo.IdCode"),align:"center",width:180},{key:"date",dataKey:"PrintTime",title:t("distribution.distributionInfo.date"),align:"left",width:260},{key:"representName",dataKey:"RepresentativeName",title:t("distribution.distributionInfo.representName"),align:"center",width:120},{key:"representIdCode",dataKey:"RepresentativeIdCode",title:t("distribution.distributionInfo.representIdCode"),align:"center",width:200},{key:"representPhone",dataKey:"RepresentativePhone",title:t("distribution.distributionInfo.representPhone"),align:"center",width:120}]);C(()=>h.value,()=>{n.value=n.value.map(e=>({title:t(`distribution.distributionInfo.${e.key}`),key:e.key,dataKey:e.dataKey,align:e.align,width:e.width}))});const s=i([]),o=i(0),_=({rowIndex:e})=>{if(e===o.value)return"highlight-row"},b={onClick(e){o.value=e.rowIndex}},y=()=>{a.value=!0,k().then(e=>{s.value=e.Data,a.value=!1})};return x(()=>{y()}),K(()=>{r.value.scrollToTop(25*o.value)}),(e,H)=>{const p=d("el-table-v2"),g=d("el-auto-resizer"),m=D("loading");return l(),N("div",P,[c(g,null,{default:u(({height:v,width:w})=>[B((l(),T(p,{fixed:"","element-loading-text":"","element-loading-background":"rgba(122, 122, 122, 0.8)","row-event-handlers":b,ref_key:"myTable",ref:r,"row-key":"index","row-class":_,columns:n.value,data:s.value,"header-height":44,"row-height":R,width:w,height:v,style:{cursor:"pointer"}},{empty:u(()=>[c(f)]),_:2},1032,["columns","data","width","height"])),[[m,a.value]])]),_:1})])}}},F=G(z,[["__scopeId","data-v-634e3910"]]);export{F as default};
