Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

2 строки
5.3KB

  1. import{a as I}from"./index.cf3ded3c.js";import{d as S,A as G,D as J,b as j,a0 as C,r as Y,o as W,c as r,e as m,f as h,h as e,i as a,F as M,J as K,u as v,I as Q,g as f,j as g,k as N}from"./index.d340e473.js";import{u as X}from"./useExportExc.c3c2ae13.js";import{a as Z}from"./purchaseResults.c05c0e24.js";import ee from"./implementPlanDialog.492b7f36.js";import"./projectStore.d1b5c8dd.js";const te={class:"flex"},ae={class:"flex justify-between"},le=f("span",null,"\u5217\u8868",-1),oe=["onClick"],ne=["onClick"],se=["onClick"],re=S({name:"purchaseResults"}),_e=Object.assign(re,{setup(de){const k=G(),{statusOptions:_,projectTypeOptions:T}=J.dictStore.globalDicts||{},t=j({projectType:void 0,status:void 0,projectYear:void 0,projectName:void 0,createOnMin:void 0,createOnMax:void 0,times:[]}),R=j([{label:"\u5E8F\u53F7",type:"index",width:"80"},{label:"\u9879\u76EE\u540D\u79F0",key:"projectName",prop:"projectName",minWidth:"200",showOverflowTooltip:!0},{label:"\u9879\u76EE\u7C7B\u578B",key:"projectTypeName",prop:"projectTypeName",width:"80"},{label:"\u6279\u590D\u91D1\u989D\uFF08\u4E07\u5143\uFF09",key:"approvedAmount",prop:"approvedAmount",width:"150"},{label:"\u9884\u7B97\u5E74\u5EA6",key:"projectYear",prop:"projectYear",width:80},{label:"\u6279\u590D\u65F6\u95F4",key:"approvalDate",prop:"approvalDate",width:"200"},{label:"\u9879\u76EE\u72B6\u6001",key:"status",prop:"status",showOverflowTooltip:!0,width:"180",render:o=>{var l,d,s;return[C("span",{class:["dot mr-4",`bg-${_[o.status].color}`]}),C("span",{class:`text-${(l=_[o.status])==null?void 0:l.color}`},o.status&&((d=_[o.stage])==null?void 0:d.name)+"-"+((s=_[o.status])==null?void 0:s.name))]}},{label:"\u521B\u5EFA\u65F6\u95F4",key:"createOn",prop:"createOn",width:"200"},{label:"\u64CD\u4F5C",slot:"action",width:"180",fixed:"right"}]),w=Y([]),b=Y(),i=async(o=b.value.pageParams)=>{var d,s;const l=await Z({...o,...t,createOnMin:(d=t.times)==null?void 0:d[0],createOnMax:(s=t.times)==null?void 0:s[1],projectYear:t.projectYear*1||void 0,times:void 0});w.value=l.data.records,x.value=l.data.total},x=Y(2),P=()=>{i()},$=()=>{t.projectYear=void 0,t.projectName=void 0,t.projectType=void 0,t.createOnMin=void 0,t.createOnMax=void 0,t.times=void 0,b.value.pageParams.pageNumber=1,b.value.pageParams.pageSize=10,i()},{exportLoading:E,exportData:L}=X(),B=()=>{L(()=>{var o,l;return I(6,{...t,createOnMin:(o=t.times)==null?void 0:o[0],createOnMax:(l=t.times)==null?void 0:l[1],projectYear:t.projectYear*1||void 0,times:void 0})})},u=j({visible:!1,data:void 0}),H=o=>{u.visible=!0,u.data=o},U=o=>{u.visible=!1,o&&i()};return W(async()=>{i()}),(o,l)=>{const d=r("el-input"),s=r("el-form-item"),p=r("el-col"),z=r("el-option"),A=r("el-select"),V=r("el-date-picker"),D=r("el-row"),y=r("el-button"),F=r("el-form"),O=r("el-card"),q=r("table-list");return m(),h(M,null,[e(O,{class:"w-full search"},{default:a(()=>[e(F,{model:t,size:"small","label-suffix":":"},{default:a(()=>[e(D,{gutter:16,class:"mb-16"},{default:a(()=>[e(p,{span:8},{default:a(()=>[e(s,{label:"\u9879\u76EE\u540D\u79F0"},{default:a(()=>[e(d,{modelValue:t.projectName,"onUpdate:modelValue":l[0]||(l[0]=n=>t.projectName=n),maxlength:"50",placeholder:"\u8BF7\u8F93\u5165"},null,8,["modelValue"])]),_:1})]),_:1}),e(p,{span:8},{default:a(()=>[e(s,{label:"\u9879\u76EE\u7C7B\u578B"},{default:a(()=>[e(A,{modelValue:t.projectType,"onUpdate:modelValue":l[1]||(l[1]=n=>t.projectType=n),placeholder:"\u5168\u90E8",class:"w-full"},{default:a(()=>[(m(!0),h(M,null,K(v(T),(n,c)=>(m(),Q(z,{key:c,label:n,value:c},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1})]),_:1}),e(p,{span:8},{default:a(()=>[e(s,{label:"\u9884\u7B97\u5E74\u5EA6"},{default:a(()=>[e(V,{modelValue:t.projectYear,"onUpdate:modelValue":l[2]||(l[2]=n=>t.projectYear=n),type:"year",placeholder:"\u8BF7\u9009\u62E9",format:"YYYY","value-format":"YYYY"},null,8,["modelValue"])]),_:1})]),_:1})]),_:1}),e(D,{gutter:24},{default:a(()=>[e(p,{span:12},{default:a(()=>[e(s,{label:"\u521B\u5EFA\u65F6\u95F4"},{default:a(()=>[e(V,{modelValue:t.times,"onUpdate:modelValue":l[3]||(l[3]=n=>t.times=n),type:"datetimerange","range-separator":"-","start-placeholder":"\u5F00\u59CB\u65F6\u95F4","end-placeholder":"\u7ED3\u675F\u65F6\u95F4",format:"YYYY-MM-DD HH:mm","value-format":"YYYY-MM-DD HH:mm"},null,8,["modelValue"])]),_:1})]),_:1}),e(p,{span:12},{default:a(()=>[e(s,{class:"btn"},{default:a(()=>[f("div",te,[e(y,{type:"primary",onClick:P},{default:a(()=>[g("\u67E5\u8BE2")]),_:1}),e(y,{onClick:$},{default:a(()=>[g("\u91CD\u7F6E")]),_:1})])]),_:1})]),_:1})]),_:1})]),_:1},8,["model"])]),_:1}),e(O,{class:"w-full mt-8"},{header:a(()=>[f("div",ae,[le,f("div",null,[e(y,{type:"primary",size:"small",plain:"",loading:v(E),onClick:B},{default:a(()=>[g(" \u5BFC\u51FA ")]),_:1},8,["loading"])])])]),default:a(()=>[e(q,{ref_key:"tableListRef",ref:b,column:R,data:w.value,total:x.value,onGetTableData:i},{action:a(({scope:n})=>[n.row.status===20001?(m(),h("a",{key:0,onClick:c=>v(k).push({name:"fillPurchasingResult",query:{id:n.row.id}})},"\u586B\u5199\u91C7\u8D2D\u7ED3\u679C",8,oe)):N("",!0),n.row.status===20006?(m(),h("a",{key:1,onClick:c=>H(n.row)},"\u586B\u5199\u5B9E\u65BD\u8BA1\u5212",8,ne)):N("",!0),f("a",{onClick:c=>v(k).push({name:"purchasingResultDetail",query:{id:n.row.id}})},"\u8BE6\u60C5",8,se)]),_:1},8,["column","data","total"])]),_:1}),e(ee,{visible:u.visible,data:u.data,onClose:U},null,8,["visible","data"])],64)}}});export{_e as default};