import{E as g,g as v,a as _,_ as x,p as w}from"./index-BkJoNt0J.js";import{d as N}from"./download-DA4MPZiT.js";import{u as k,g as B,h as E,r as l,i as f,j as r,o as s,c as V,d as a,w as o,k as y,e as D}from"./index-CsSGZIOI.js";const j={class:"app-container"},O=Object.assign({name:"supplierMrpMonth"},{__name:"index",setup(F){const h=k(),t=B({apiName:"cherysuppliermrpmonth",loading:!1,pageParams:{page:1,pageSize:10,total:1,filters:{materialCode:null}},tableColumns:[{prop:"releaseEdition",title:"需求发布版次",width:120},{prop:"materialCode",title:"零件号"},{prop:"materialDescription",title:"零件名称"},{prop:"plantId",title:"工厂代码"},{prop:"plantName",title:"工厂名称"},{prop:"startMonth",title:"起始年月"},{prop:"quantityDemand1",title:"需求数量1"},{prop:"quantityDemand2",title:"需求数量2"},{prop:"quantityDemand3",title:"需求数量3"},{prop:"quantityDemand4",title:"需求数量4"},{prop:"quantityDemand5",title:"需求数量5"},{prop:"quantityDemand6",title:"需求数量6"},{prop:"quantityDemand7",title:"需求数量7"},{prop:"quantityDemand8",title:"需求数量8"},{prop:"quantityDemand9",title:"需求数量9"},{prop:"quantityDemand10",title:"需求数量10"},{prop:"quantityDemand11",title:"需求数量11"},{prop:"quantityDemand12",title:"需求数量12"},{prop:"isUpdate",title:"是否更新",type:"tagFilter",options:g.whether},{prop:"createByUser",title:"创建人"},{prop:"createTime",title:"创建时间",type:"datetime",width:180},{prop:"updateByUser",title:"修改人"},{prop:"updateTime",title:"修改时间",type:"datetime",width:180},{prop:"isDelete",title:"是否删除",type:"tagFilter",options:g.whether},{prop:"version",title:"版本号"}],tableData:[]});E(()=>{n(1)});function n(i){t.loading=!0,t.pageParams.page=i,v(t.apiName,Object.assign({},_(t.pageParams))).then(e=>{t.tableData=e.data.data,t.pageParams.total=e.data.totalPages}).finally(()=>t.loading=!1)}function b(){t.loading=!0,w(t.apiName,Object.assign({},_(t.pageParams))).then(i=>{N(i.data,h.meta.title+".xlsx")}).finally(()=>t.loading=!1)}return(i,e)=>{const C=l("el-input"),m=l("el-form-item"),d=l("el-button"),P=l("el-form"),u=l("el-card"),c=f("auth"),q=f("loading");return r((s(),V("div",j,[a(u,{class:"search-container"},{default:o(()=>[a(P,{inline:!0},{default:o(()=>[a(m,{label:"零件号"},{default:o(()=>[a(C,{modelValue:t.pageParams.filters.materialCode,"onUpdate:modelValue":e[0]||(e[0]=p=>t.pageParams.filters.materialCode=p),placeholder:"零件号",clearable:""},null,8,["modelValue"])]),_:1}),a(m,null,{default:o(()=>[r((s(),y(d,{onClick:e[1]||(e[1]=p=>n(1)),icon:"Search"},{default:o(()=>e[3]||(e[3]=[D("查询")])),_:1})),[[c,t.apiName+":page"]]),r((s(),y(d,{onClick:e[2]||(e[2]=p=>b()),icon:"TopRight",type:"success"},{default:o(()=>e[4]||(e[4]=[D("导出")])),_:1})),[[c,t.apiName+":export"]])]),_:1})]),_:1})]),_:1}),a(u,{class:"paged-table-container"},{default:o(()=>[a(x,{tableData:t.tableData,tableColumns:t.tableColumns,pageParams:t.pageParams,onPageSizeChange:n,onPageCurrentChange:n},null,8,["tableData","tableColumns","pageParams"])]),_:1})])),[[q,t.loading]])}}});export{O as default};