|
- import{B as le,Z as x,d as Ae,y as Ne,b as I,r as g,J as Ve,o as De,c as i,a2 as Me,e as d,f as k,h as t,i as o,u as h,G as C,k as b,F as O,H as ee,g as j,T as U,j as P,t as Pe,w as Ce,q as Te}from"./index.149277cd.js";import{E as Oe}from"./index.0221fd55.js";import"./uploadAction.da8c1cf8.js";import{o as Ee,l as Se,s as $e,p as Ye,e as Ie}from"./annualPlanStore.bbf22d74.js";import Ue from"./approvalDialog.1f75b1cb.js";import Re from"./importProjectDialog.8e58c789.js";import Le from"./exportFieldDialog.6bde2369.js";import{u as Fe}from"./useExportExc.c4f93108.js";import{g as G,a as Ge}from"./getIsShowRegionTree.4caa5c48.js";import qe from"./operationDialog.da3e18dc.js";import"./index.b88ae75b.js";const{statusOptions:f}=le.dictStore.globalDicts||{},oe={type:"selection",width:"50"},ae=[{label:"\u5E8F\u53F7",type:"index",width:"60"},{label:"\u9879\u76EE\u540D\u79F0",key:"projectName",prop:"projectName",minWidth:"200",showOverflowTooltip:!0},{label:"\u7533\u62A5\u5355\u4F4D",key:"buildOrg",prop:"buildOrg",minWidth:"200",showOverflowTooltip:!0},{label:"\u9879\u76EE\u7C7B\u578B",key:"projectTypeName",prop:"projectTypeName",width:80},{label:"\u9879\u76EE\u7533\u62A5\u8D44\u91D1(\u4E07\u5143)",key:"declaredAmount",prop:"declaredAmount",width:"150"},{label:"\u9879\u76EE\u6279\u590D\u8D44\u91D1(\u4E07\u5143)",key:"approvalAmount",prop:"approvalAmount",width:"150"},{label:"\u9884\u7B97\u5E74\u5EA6",key:"projectYear",prop:"projectYear",width:"80"},{label:"\u662F\u5426\u5F00\u542F\u65B9\u6848\u7533\u62A5",key:"isStartDeclaredProject",prop:"isStartDeclaredProject",width:"140",render:r=>x("span",r.isStartDeclaredProject?"\u662F":"\u5426")},{label:"\u9879\u76EE\u72B6\u6001",key:"status",prop:"status",width:"180",render:r=>{var c,v,u,_;return[x("span",{class:["dot mr-4",`bg-${(c=f[r.status])==null?void 0:c.color}`]}),x("span",{class:`text-${(v=f[r.status])==null?void 0:v.color}`},r.status&&((u=f[r.stage])==null?void 0:u.name)+"-"+((_=f[r.status])==null?void 0:_.name))]}},{label:"\u521B\u5EFA\u65F6\u95F4",key:"createOn",prop:"createOn",width:"180"},{label:"\u64CD\u4F5C",slot:"action",width:"120",fixed:"right"}],Be=[oe,{label:"\u5E8F\u53F7",type:"index",width:"60"},{label:"\u9879\u76EE\u540D\u79F0",key:"projectName",prop:"projectName",minWidth:"200",showOverflowTooltip:!0},{label:"\u7533\u62A5\u5355\u4F4D",key:"buildOrg",prop:"buildOrg",minWidth:"200",showOverflowTooltip:!0},{label:"\u9879\u76EE\u7C7B\u578B",key:"projectTypeName",prop:"projectTypeName",width:80},{label:"\u9879\u76EE\u7533\u62A5\u8D44\u91D1(\u4E07\u5143)",key:"declaredAmount",prop:"declaredAmount",width:"150"},{label:"\u9879\u76EE\u6279\u590D\u8D44\u91D1(\u4E07\u5143)",key:"approvalAmount",prop:"approvalAmount",width:"150"},{label:"\u9884\u7B97\u5E74\u5EA6",key:"projectYear",prop:"projectYear",width:"80"},{label:"\u662F\u5426\u5F00\u542F\u65B9\u6848\u7533\u62A5",key:"isStartDeclaredProject",prop:"isStartDeclaredProject",width:"140",render:r=>x("span",r.isStartDeclaredProject?"\u662F":"\u5426")},{label:"\u9879\u76EE\u72B6\u6001",key:"status",prop:"status",width:"180",render:r=>{var c,v,u,_;return[x("span",{class:["dot mr-4",`bg-${(c=f[r.status])==null?void 0:c.color}`]}),x("span",{class:`text-${(v=f[r.status])==null?void 0:v.color}`},r.status&&((u=f[r.stage])==null?void 0:u.name)+"-"+((_=f[r.status])==null?void 0:_.name))]}},{label:"\u521B\u5EFA\u65F6\u95F4",key:"createOn",prop:"createOn",width:"180"},{label:"\u64CD\u4F5C",slot:"action",width:"180",fixed:"right"}],ze=[oe,{label:"\u5E8F\u53F7",type:"index",width:"60"},{label:"\u9879\u76EE\u540D\u79F0",key:"projectName",prop:"projectName",minWidth:"200",showOverflowTooltip:!0},{label:"\u7533\u62A5\u5355\u4F4D",key:"buildOrg",prop:"buildOrg",minWidth:"200",showOverflowTooltip:!0},{label:"\u9879\u76EE\u7C7B\u578B",key:"projectTypeName",prop:"projectTypeName",width:80},{label:"\u8FD0\u7EF4\u5305",key:"operationPackageName",prop:"operationPackageName",width:"150"},{label:"\u9879\u76EE\u7533\u62A5\u8D44\u91D1(\u4E07\u5143)",key:"declaredAmount",prop:"declaredAmount",width:"150"},{label:"\u9879\u76EE\u6279\u590D\u8D44\u91D1(\u4E07\u5143)",key:"approvalAmount",prop:"approvalAmount",width:"150"},{label:"\u9884\u7B97\u5E74\u5EA6",key:"projectYear",prop:"projectYear",width:"80"},{label:"\u662F\u5426\u5F00\u542F\u65B9\u6848\u7533\u62A5",key:"isStartDeclaredProject",prop:"isStartDeclaredProject",width:"140",render:r=>x("span",r.isStartDeclaredProject?"\u662F":"\u5426")},{label:"\u9879\u76EE\u72B6\u6001",key:"status",prop:"status",width:"180",render:r=>{var c,v,u,_;return[x("span",{class:["dot mr-4",`bg-${(c=f[r.status])==null?void 0:c.color}`]}),x("span",{class:`text-${(v=f[r.status])==null?void 0:v.color}`},r.status&&((u=f[r.stage])==null?void 0:u.name)+"-"+((_=f[r.status])==null?void 0:_.name))]}},{label:"\u521B\u5EFA\u65F6\u95F4",key:"createOn",prop:"createOn",width:"180"},{label:"\u64CD\u4F5C",slot:"action",width:"150",fixed:"right"}],te={"00":ae,"01":Be,"02":ze,"03":ae},We={class:"flex"},He={class:"flex"},Je={class:"flex"},Ze={class:"flex justify-between items-center"},Ke={class:"flex justify-between items-center mb-20"},Qe={class:"flex items-center"};const Xe=["onClick"],ea=["onClick"],aa=["onClick"],ta=["onClick"],la=["onClick"],oa=["onClick"],na=Ae({name:"planList"}),ja=Object.assign(na,{props:{isTemporaryAugment:{type:Number,default:0}},setup(r){const{proxy:c}=Te(),v=r,u=Ne(),{statusOptionsCascader:_,projectTypeOptions:ne}=le.dictStore.globalDicts||{},a=I({projectName:void 0,buildOrg:void 0,projectType:void 0,operationPackageId:void 0,status:void 0,declareAmountMin:void 0,declareAmountMax:void 0,approveAmountMin:void 0,approveAmountMax:void 0,projectYear:void 0,times:void 0}),p=g("00"),N=g(),q=g(0),B=g(te[p.value]),z=g([]),re=g({}),V=g(),se=n=>{V.value=n.regionLevel===3?n.regionCode:void 0,N.value.pageParams.pageNumber=1,w()},w=async(n=N.value.pageParams)=>{var s,A,m;p.value!=="02"&&(a.operationPackageId=void 0);const e=await Se({...n,...a,queryProjectType:p.value,status:(s=a.status)==null?void 0:s[a.status.length-1],projectYear:a.projectYear*1||void 0,declareAmountMin:a.declareAmountMin*1||void 0,declareAmountMax:a.declareAmountMax*1||void 0,approveAmountMin:a.approveAmountMin*1||void 0,approveAmountMax:a.approveAmountMax*1||void 0,createOnMin:((A=a.times)==null?void 0:A[0])||void 0,createOnMax:((m=a.times)==null?void 0:m[1])||void 0,regionCode:V.value||void 0,times:void 0});z.value=e.data.records,q.value=e.data.total},ie=(n,e)=>p.value==="01"?!n.isStartDeclaredProject:!0,W=()=>{w()},de=()=>{a.projectName=void 0,a.buildOrg=void 0,a.operationPackageId=void 0,a.projectType=void 0,a.status=void 0,a.declareAmountMin=void 0,a.declareAmountMax=void 0,a.approveAmountMin=void 0,a.approveAmountMax=void 0,a.projectYear=void 0,a.times=void 0,N.value.pageParams.pageNumber=1,N.value.pageParams.pageSize=10,w()},D=g([]),ue=n=>{D.value=n},pe=()=>{if(!D.value.length){c.$message.warning("\u8BF7\u81F3\u5C11\u9009\u62E9\u4E00\u4E2A\u9879\u76EE");return}c.$messageBox.confirm(`\u662F\u5426${V.value==="331181"?"\u5217\u5165\u5E74\u5EA6\u8BA1\u5212":"\u5F00\u542F\u65B9\u6848\u7533\u62A5"}?`,"\u63D0\u793A\uFF01",{type:"warning"}).then(async()=>{await $e({projectIds:D.value.map(n=>n.projectId)}),c.$message.success(`${V.value==="331181"?"\u5217\u5165":"\u5F00\u542F"}\u6210\u529F\uFF01`),w()})},R=I({visible:!1}),ce=()=>{R.visible=!1},E=I({visible:!1}),ra=n=>{E.visible=!0},L=()=>{E.visible=!1},{exportData:H}=Fe(),me=async n=>{await H(()=>{var e,s,A;return Ye({...N.value.pageParams,...a,status:(e=a.status)==null?void 0:e[a.status.length-1],createOnMin:((s=a.times)==null?void 0:s[0])||void 0,createOnMax:((A=a.times)==null?void 0:A[1])||void 0,regionCode:V.value||void 0,isTemporaryAugment:v.isTemporaryAugment,times:void 0,exportOptionList:n})}),L()},sa=async()=>{await H(()=>{var n,e,s;return Ie({...N.value.pageParams,...a,status:(n=a.status)==null?void 0:n[a.status.length-1],createOnMin:((e=a.times)==null?void 0:e[0])||void 0,createOnMax:((s=a.times)==null?void 0:s[1])||void 0,regionCode:V.value||void 0,times:void 0,isTemporaryAugment:v.isTemporaryAugment})}),L()},fe=n=>{u.push({name:"planEdit",query:{id:n.projectId}})},M=I({visible:!1,title:void 0,rowData:void 0}),ve=n=>{M.visible=!0,M.title=`\u7ACB\u9879\u6279\u590D-${n.projectName}`,M.rowData=n},be=n=>{M.visible=!1,n&&w()};Ve(()=>re.value.file,async n=>{W()});const J=g([]);De(async()=>{G(["SUPER_ADMIN","REGION_MANAGER"])||w();const n=await Ee();J.value=n.data});function _e(){w(),B.value=te[p.value],D.value=[]}const F=g(!1);function ye(){if(!D.value.length){c.$message.warning("\u8BF7\u81F3\u5C11\u9009\u62E9\u4E00\u4E2A\u9879\u76EE");return}F.value=!0}function ge(){w()}return(n,e)=>{const s=i("el-col"),A=i("el-input"),m=i("el-form-item"),Z=i("el-option"),K=i("el-select"),T=i("el-row"),we=i("el-cascader"),S=i("el-input-number"),Q=i("el-date-picker"),$=i("el-button"),ke=i("el-form"),X=i("el-card"),Y=i("el-tab-pane"),he=i("el-tabs"),ia=i("el-upload"),je=i("table-list"),xe=Me("hasRole");return d(),k(O,null,[t(T,null,{default:o(()=>[h(G)(["SUPER_ADMIN","REGION_MANAGER"])?(d(),C(s,{key:0,span:4,class:"pr-16"},{default:o(()=>[t(Oe,{params:h(Ge)({SUPER_ADMIN:!1,REGION_MANAGER:!1}),onGetTree:se},null,8,["params"])]),_:1})):b("",!0),t(s,{span:h(G)(["SUPER_ADMIN","REGION_MANAGER"])?20:24},{default:o(()=>[t(X,{class:"w-full search"},{default:o(()=>[t(ke,{model:a,size:"small","label-suffix":":"},{default:o(()=>[t(T,{gutter:16,class:"mb-16"},{default:o(()=>[t(s,{span:8},{default:o(()=>[t(m,{label:"\u9879\u76EE\u540D\u79F0"},{default:o(()=>[t(A,{modelValue:a.projectName,"onUpdate:modelValue":e[0]||(e[0]=l=>a.projectName=l),placeholder:"\u8BF7\u8F93\u5165"},null,8,["modelValue"])]),_:1})]),_:1}),t(s,{span:8},{default:o(()=>[t(m,{label:"\u7533\u62A5\u5355\u4F4D"},{default:o(()=>[t(A,{modelValue:a.buildOrg,"onUpdate:modelValue":e[1]||(e[1]=l=>a.buildOrg=l),placeholder:"\u8BF7\u8F93\u5165"},null,8,["modelValue"])]),_:1})]),_:1}),t(s,{span:8},{default:o(()=>[t(m,{label:"\u9879\u76EE\u7C7B\u578B"},{default:o(()=>[t(K,{modelValue:a.projectType,"onUpdate:modelValue":e[2]||(e[2]=l=>a.projectType=l),placeholder:"\u5168\u90E8",class:"w-full"},{default:o(()=>[(d(!0),k(O,null,ee(h(ne),(l,y)=>(d(),C(Z,{key:y,label:l,value:y},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1})]),_:1})]),_:1}),t(T,{gutter:16,class:"mb-16"},{default:o(()=>[t(s,{span:8},{default:o(()=>[t(m,{label:"\u9879\u76EE\u72B6\u6001"},{default:o(()=>[t(we,{modelValue:a.status,"onUpdate:modelValue":e[3]||(e[3]=l=>a.status=l),class:"w-full",props:{label:"name",value:"code"},options:h(_)},null,8,["modelValue","options"])]),_:1})]),_:1}),t(s,{span:8},{default:o(()=>[t(m,{class:"whitespace-nowrap",label:"\u7533\u62A5\u8D44\u91D1(\u4E07\u5143)"},{default:o(()=>[j("div",We,[t(S,{modelValue:a.declareAmountMin,"onUpdate:modelValue":e[4]||(e[4]=l=>a.declareAmountMin=l),clearable:"",controls:!1,onMousewheel:e[5]||(e[5]=U(()=>{},["prevent"]))},null,8,["modelValue"]),e[19]||(e[19]=P(" \xA0\u81F3\xA0 ")),t(S,{modelValue:a.declareAmountMax,"onUpdate:modelValue":e[6]||(e[6]=l=>a.declareAmountMax=l),clearable:"",controls:!1,onMousewheel:e[7]||(e[7]=U(()=>{},["prevent"]))},null,8,["modelValue"])])]),_:1})]),_:1}),t(s,{span:8},{default:o(()=>[t(m,{class:"whitespace-nowrap",label:"\u6279\u590D\u8D44\u91D1(\u4E07\u5143)"},{default:o(()=>[j("div",He,[t(S,{modelValue:a.approveAmountMin,"onUpdate:modelValue":e[8]||(e[8]=l=>a.approveAmountMin=l),controls:!1,clearable:"",onMousewheel:e[9]||(e[9]=U(()=>{},["prevent"]))},null,8,["modelValue"]),e[20]||(e[20]=P(" \xA0\u81F3\xA0 ")),t(S,{modelValue:a.approveAmountMax,"onUpdate:modelValue":e[10]||(e[10]=l=>a.approveAmountMax=l),controls:!1,clearable:"",onMousewheel:e[11]||(e[11]=U(()=>{},["prevent"]))},null,8,["modelValue"])])]),_:1})]),_:1})]),_:1}),t(T,{gutter:16,class:"mb-16"},{default:o(()=>[t(s,{span:8},{default:o(()=>[t(m,{label:"\u9884\u7B97\u5E74\u5EA6"},{default:o(()=>[t(Q,{modelValue:a.projectYear,"onUpdate:modelValue":e[12]||(e[12]=l=>a.projectYear=l),type:"year","value-format":"YYYY",placeholder:"\u8BF7\u9009\u62E9"},null,8,["modelValue"])]),_:1})]),_:1}),t(s,{span:16},{default:o(()=>[t(m,{label:"\u521B\u5EFA\u65F6\u95F4"},{default:o(()=>[t(Q,{modelValue:a.times,"onUpdate:modelValue":e[13]||(e[13]=l=>a.times=l),type:"datetimerange",editable:!1,format:"YYYY-MM-DD HH:mm","value-format":"YYYY-MM-DD HH:mm","range-separator":"-","start-placeholder":"\u5F00\u59CB\u65F6\u95F4","end-placeholder":"\u7ED3\u675F\u65F6\u95F4"},null,8,["modelValue"])]),_:1})]),_:1})]),_:1}),p.value==="02"?(d(),C(s,{key:0,span:8},{default:o(()=>[t(m,{label:"\u8FD0\u7EF4\u5305"},{default:o(()=>[t(K,{modelValue:a.operationPackageId,"onUpdate:modelValue":e[14]||(e[14]=l=>a.operationPackageId=l),"reserve-keyword":"",filterable:"",placeholder:"\u5168\u90E8",class:"w-full"},{default:o(()=>[(d(!0),k(O,null,ee(J.value,(l,y)=>(d(),C(Z,{key:y,label:l.operationPackageName,value:l.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1})]),_:1})):b("",!0),t(T,null,{default:o(()=>[t(s,{span:24},{default:o(()=>[t(m,{class:"btn"},{default:o(()=>[j("div",Je,[t($,{type:"primary",onClick:W},{default:o(()=>e[21]||(e[21]=[P("\u67E5\u8BE2 ")])),_:1}),t($,{onClick:de},{default:o(()=>e[22]||(e[22]=[P("\u91CD\u7F6E ")])),_:1})])]),_:1})]),_:1})]),_:1})]),_:1},8,["model"])]),_:1}),t(X,{class:"w-full mt-8 tab-card"},{header:o(()=>[j("div",Ze,[t(he,{modelValue:p.value,"onUpdate:modelValue":e[15]||(e[15]=l=>p.value=l),onTabChange:_e},{default:o(()=>[t(Y,{label:"\u6240\u6709\u9879\u76EE",name:"00"}),t(Y,{label:"\u5EFA\u8BBE\u7C7B\u9879\u76EE",name:"01"}),t(Y,{label:"\u8FD0\u7EF4\u7C7B\u9879\u76EE",name:"02"}),t(Y,{label:"\u8DE8\u5E74\u5EA6\u9879\u76EE",name:"03"})]),_:1},8,["modelValue"])])]),default:o(()=>[j("div",Ke,[j("div",Qe,[e[24]||(e[24]=j("span",{class:"mr-24"},"\u5217\u8868",-1)),p.value==="01"?(d(),C($,{key:0,type:"primary",size:"small",onClick:pe},{default:o(()=>[P(Pe(V.value==="331181"?"\u5217\u5165\u5E74\u5EA6\u8BA1\u5212":"\u5F00\u542F\u65B9\u6848\u7533\u62A5"),1)]),_:1})):b("",!0),p.value==="02"?(d(),C($,{key:1,type:"primary",size:"small",onClick:ye},{default:o(()=>e[23]||(e[23]=[P("\u5173\u8054\u8FD0\u7EF4\u5305 ")])),_:1})):b("",!0)]),b("",!0)]),t(je,{ref_key:"tableListRef",ref:N,column:B.value,data:z.value,total:q.value,selectable:ie,onSelectionChange:ue,onGetTableData:w},{action:o(({scope:l})=>[p.value==="00"?(d(),k("a",{key:0,onClick:y=>h(u).push({name:"projectDetail",query:{id:l.row.projectId}})},"\u8BE6\u60C5",8,Xe)):b("",!0),p.value==="01"?(d(),k(O,{key:1},[l.row.status===10014?(d(),k("a",{key:0,onClick:y=>ve(l.row)},"\u7ACB\u9879\u6279\u590D",8,ea)):b("",!0),j("a",{onClick:y=>h(u).push({name:"projectDetail",query:{id:l.row.projectId}})},"\u8BE6\u60C5",8,aa)],64)):b("",!0),p.value==="02"?(d(),k("a",{key:2,onClick:y=>h(u).push({name:"projectDetail",query:{id:l.row.projectId}})},"\u8BE6\u60C5",8,ta)):b("",!0),p.value==="03"?(d(),k(O,{key:3},[l.row.status===10010?Ce((d(),k("a",{key:0,onClick:y=>fe(l.row)},e[28]||(e[28]=[P("\u7F16\u8F91")]),8,la)),[[xe,["\u8D85\u7EA7\u7BA1\u7406\u5458"]]]):b("",!0),j("a",{onClick:y=>h(u).push({name:"projectDetail",query:{id:l.row.projectId}})},"\u8BE6\u60C5",8,oa)],64)):b("",!0)]),_:1},8,["column","data","total"])]),_:1})]),_:1},8,["span"])]),_:1}),t(Ue,{visible:M.visible,title:M.title,data:M.rowData,onClose:be},null,8,["visible","title","data"]),t(Re,{visible:R.visible,data:R.rowData,onClose:ce},null,8,["visible","data"]),t(Le,{visible:E.visible,data:E.rowData,onClose:L,onExportProject:me},null,8,["visible","data"]),t(qe,{modelValue:F.value,"onUpdate:modelValue":e[17]||(e[17]=l=>F.value=l),"select-project-list":D.value,"onUpdate:selectProjectList":e[18]||(e[18]=l=>D.value=l),onRelevanceSuccess:ge},null,8,["modelValue","select-project-list"])],64)}}});export{ja as default};
|