Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

2 lignes
10.0KB

  1. import{d as pe,B as h,r as m,b as N,Z as z,y as me,o as ce,c as u,e as c,f as b,h as e,i as a,w as C,F as O,H as I,u as P,G as R,v as x,g,j as v,k as M,$ as fe,q as _e}from"./index.88314652.js";import{l as be,m as ge,n as ve,a as ye,r as je}from"./index.52f0c4e2.js";import{u as we}from"./useExportExc.d7823a98.js";const Ye="/video/project_study_video.mp4",ke={class:"flex"},Ve={class:"flex"},Te={class:"flex justify-between items-center"},he=["onClick"],Ce=["onClick"],xe=["onClick"],De=["onClick"],Ne=pe({name:"projectDeclare"}),$e=Object.assign(Ne,{setup(Oe){const{statusOptionsCascader:A,statusOptions:Y,projectConTypeOptions:G}=h.dictStore.globalDicts||{},{proxy:U}=_e(),D=m(!1),l=N({stage:void 0,status:void 0,projectName:"",projectType:void 0,projectYear:void 0,createTiming_:void 0}),y=async(r=V.value.pageParams)=>{var n,s,j;const t={...r,...l,createOnMin:((n=l.createTiming_)==null?void 0:n.length)&&l.createTiming_[0],createOnMax:((s=l.createTiming_)==null?void 0:s.length)&&l.createTiming_[1],projectYear:l.projectYear*1||void 0,createTiming_:void 0,status:(j=l.status)==null?void 0:j[l.status.length-1]},i=d.value?await be(t):await ge(t);E.value=i.data.records,H.value=i.data.total},$=m("\u5DF2\u7533\u62A5"),W=(r,t)=>{switch(r.props.name){case"\u5DF2\u7533\u62A5":d.value=!0,k();break;case"\u8349\u7A3F\u7BB1":d.value=!1,k();break}},d=m(!0),J=N([{label:"\u5E8F\u53F7",type:"index",width:"80"},{label:"\u9879\u76EE\u540D\u79F0",key:"projectName",prop:"projectName",minWidth:"250",showOverflowTooltip:!0},{label:"\u9879\u76EE\u7C7B\u578B",key:"projectTypeName",prop:"projectTypeName",width:"100"},{label:"\u7533\u62A5\u91D1\u989D(\u4E07\u5143)",key:"declaredAmount",prop:"declaredAmount",width:"120"},{label:"\u9884\u7B97\u5E74\u5EA6",key:"projectYear",prop:"projectYear",width:"100"},{label:"\u521B\u5EFA\u65F6\u95F4",key:"createOn",prop:"createOn",showOverflowTooltip:!0,width:"180"},{label:"\u9879\u76EE\u72B6\u6001",key:"status",prop:"status",width:"220",render:r=>{var t,i,n,s;return[z("span",{class:["dot mr-4",`bg-${r.status&&((t=Y[r.status])==null?void 0:t.color)}`]}),z("span",{class:`text-${r.status&&((i=Y[r.status])==null?void 0:i.color)}`},r.status&&((n=Y[r.stage])==null?void 0:n.name)+"-"+((s=Y[r.status])==null?void 0:s.name))]}},{label:"\u64CD\u4F5C",slot:"action",width:"200",fixed:"right"}]),Z=N([{label:"\u5E8F\u53F7",type:"index",width:"80"},{label:"\u9879\u76EE\u540D\u79F0",key:"projectName",prop:"projectName",minWidth:"250",showOverflowTooltip:!0},{label:"\u9879\u76EE\u7C7B\u578B",key:"projectTypeName",prop:"projectTypeName",width:"100"},{label:"\u7533\u62A5\u91D1\u989D(\u4E07\u5143)",key:"declareAmount",prop:"declareAmount",width:"120"},{label:"\u9884\u7B97\u5E74\u5EA6",key:"projectYear",prop:"projectYear",width:"80"},{label:"\u521B\u5EFA\u65F6\u95F4",key:"createOn",prop:"createOn",showOverflowTooltip:!0,width:"180"},{label:"\u64CD\u4F5C",slot:"action",width:"160",fixed:"right"}]),E=m([]),H=m(1),K=r=>{f.push({name:"declarePage",query:{id:r.id,isDraft:1}})},Q=r=>{d.value?f.push({name:"projectDeclareDetail",query:{id:r.id}}):f.push({name:"draftDetails",query:{id:r.id}})},X=r=>{r.status===20005?f.push({name:"reDeclarationFinal",query:{id:r.id}}):f.push({name:"declarePage",query:{id:r.id}})},B=()=>{y()},k=()=>{l.status=void 0,l.projectName=void 0,l.createTiming_=void 0,l.projectType=void 0,l.projectYear=void 0,V.value.pageParams.pageNumber=1,V.value.pageParams.pageSize=10,y()},f=me(),ee=()=>{if(h.userStore.userInfo.isFirstCreateProject===0){f.push({name:"declarePage"});return}fe.alert("\u60A8\u662F\u7B2C\u4E00\u6B21\u4F7F\u7528\u9879\u76EE\u7533\u62A5\uFF0C\u8BF7\u5148\u89C2\u770B\u6559\u5B66\u89C6\u9891",{showCancelButton:!1}).then(()=>{D.value=!0,ve(h.userStore.userInfo.userId),h.userStore.userInfo.isFirstCreateProject=0})},V=m(),{exportLoading:te,exportData:ae}=we(),le=()=>{ae(()=>{var r,t,i;return ye(1,{...l,createOnMin:((r=l.createTiming_)==null?void 0:r.length)&&l.createTiming_[0],createOnMax:((t=l.createTiming_)==null?void 0:t.length)&&l.createTiming_[1],projectYear:l.projectYear*1||void 0,status:(i=l.status)==null?void 0:i[l.status.length-1]})})},oe=m([]),re=r=>{U.$messageBox.confirm(`\u786E\u5B9A\u8981\u5220\u9664${r.projectName}\u5417?`,"\u63D0\u793A\uFF01",{type:"warning"}).then(async()=>{await je(r.projectCode),U.$message.success("\u5220\u9664\u6210\u529F"),y()})};return ce(async()=>{d.value=m(!0),y()}),(r,t)=>{const i=u("el-input"),n=u("el-form-item"),s=u("el-col"),j=u("el-option"),S=u("el-select"),ne=u("el-cascader"),w=u("el-row"),T=u("el-date-picker"),_=u("el-button"),L=u("el-form"),q=u("el-card"),F=u("el-tab-pane"),se=u("el-tabs"),ue=u("table-list"),de=u("el-dialog");return c(),b(O,null,[e(w,null,{default:a(()=>[e(q,{class:"w-full search"},{default:a(()=>[C(e(L,{size:"small",model:l,"label-suffix":":"},{default:a(()=>[e(w,{gutter:16,class:"mb-16"},{default:a(()=>[e(s,{span:8},{default:a(()=>[e(n,{label:"\u9879\u76EE\u540D\u79F0",class:"w-full"},{default:a(()=>[e(i,{modelValue:l.projectName,"onUpdate:modelValue":t[0]||(t[0]=o=>l.projectName=o),maxlength:"50",placeholder:"\u8BF7\u8F93\u5165"},null,8,["modelValue"])]),_:1})]),_:1}),e(s,{span:8},{default:a(()=>[e(n,{label:"\u9879\u76EE\u7C7B\u578B"},{default:a(()=>[e(S,{modelValue:l.projectType,"onUpdate:modelValue":t[1]||(t[1]=o=>l.projectType=o),placeholder:"\u5168\u90E8",class:"w-full"},{default:a(()=>[(c(!0),b(O,null,I(P(G),(o,p)=>(c(),R(j,{key:p,label:o,value:p},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1})]),_:1}),e(s,{span:8},{default:a(()=>[C(e(n,{label:"\u9879\u76EE\u72B6\u6001"},{default:a(()=>[e(ne,{modelValue:l.status,"onUpdate:modelValue":t[2]||(t[2]=o=>l.status=o),class:"w-full",props:{label:"name",value:"code"},options:P(A)},null,8,["modelValue","options"])]),_:1},512),[[x,d.value]])]),_:1})]),_:1}),e(w,{gutter:16},{default:a(()=>[e(s,{span:8},{default:a(()=>[e(n,{label:"\u9884\u7B97\u5E74\u5EA6"},{default:a(()=>[e(T,{modelValue:l.projectYear,"onUpdate:modelValue":t[3]||(t[3]=o=>l.projectYear=o),class:"w-full",type:"year",format:"YYYY","value-format":"YYYY",placeholder:"\u8BF7\u9009\u62E9"},null,8,["modelValue"])]),_:1})]),_:1}),e(s,{span:12},{default:a(()=>[e(n,{label:"\u521B\u5EFA\u65F6\u95F4",class:"w-full"},{default:a(()=>[e(T,{modelValue:l.createTiming_,"onUpdate:modelValue":t[4]||(t[4]=o=>l.createTiming_=o),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(s,{span:4},{default:a(()=>[e(n,{class:"btn"},{default:a(()=>[g("div",ke,[e(_,{type:"primary",onClick:B},{default:a(()=>t[11]||(t[11]=[v("\u67E5\u8BE2")])),_:1}),e(_,{onClick:k},{default:a(()=>t[12]||(t[12]=[v("\u91CD\u7F6E")])),_:1})])]),_:1})]),_:1})]),_:1})]),_:1},8,["model"]),[[x,d.value]]),C(e(L,{"label-suffix":":",model:l,size:"small"},{default:a(()=>[e(w,{gutter:16,class:"mb-16"},{default:a(()=>[e(s,{span:8},{default:a(()=>[e(n,{label:"\u9879\u76EE\u540D\u79F0",class:"w-full"},{default:a(()=>[e(i,{modelValue:l.projectName,"onUpdate:modelValue":t[5]||(t[5]=o=>l.projectName=o),placeholder:"\u8BF7\u8F93\u5165"},null,8,["modelValue"])]),_:1})]),_:1}),e(s,{span:8},{default:a(()=>[e(n,{label:"\u9879\u76EE\u7C7B\u578B"},{default:a(()=>[e(S,{modelValue:l.projectType,"onUpdate:modelValue":t[6]||(t[6]=o=>l.projectType=o),placeholder:"\u5168\u90E8",class:"w-full"},{default:a(()=>{var o;return[(c(!0),b(O,null,I((o=oe.value)==null?void 0:o.filter(p=>p.type==="PROJECT_TYPE"),(p,ie)=>(c(),R(j,{key:ie,label:p.label,value:p.value},null,8,["label","value"]))),128))]}),_:1},8,["modelValue"])]),_:1})]),_:1}),e(s,{span:8},{default:a(()=>[e(n,{label:"\u9884\u7B97\u5E74\u5EA6"},{default:a(()=>[e(T,{modelValue:l.projectYear,"onUpdate:modelValue":t[7]||(t[7]=o=>l.projectYear=o),class:"w-full",type:"year","value-format":"YYYY",placeholder:"\u8BF7\u9009\u62E9"},null,8,["modelValue"])]),_:1})]),_:1})]),_:1}),e(w,{gutter:16},{default:a(()=>[e(s,{span:10},{default:a(()=>[e(n,{label:"\u521B\u5EFA\u65F6\u95F4"},{default:a(()=>[e(T,{modelValue:l.createTiming_,"onUpdate:modelValue":t[8]||(t[8]=o=>l.createTiming_=o),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(s,{span:14},{default:a(()=>[e(n,{class:"btn"},{default:a(()=>[g("div",Ve,[e(_,{type:"primary",onClick:B},{default:a(()=>t[13]||(t[13]=[v("\u67E5\u8BE2")])),_:1}),e(_,{onClick:k},{default:a(()=>t[14]||(t[14]=[v("\u91CD\u7F6E")])),_:1})])]),_:1})]),_:1})]),_:1})]),_:1},8,["model"]),[[x,!d.value]])]),_:1}),e(q,{class:"w-full mt-8 tab-card"},{header:a(()=>[g("div",Te,[e(se,{modelValue:$.value,"onUpdate:modelValue":t[9]||(t[9]=o=>$.value=o),onTabClick:W},{default:a(()=>[e(F,{label:"\u5DF2\u7533\u62A5",name:"\u5DF2\u7533\u62A5"}),e(F,{label:"\u8349\u7A3F\u7BB1",name:"\u8349\u7A3F\u7BB1"})]),_:1},8,["modelValue"]),g("div",null,[C(e(_,{type:"primary",size:"small",plain:"",loading:P(te),onClick:le},{default:a(()=>t[15]||(t[15]=[v("\u5BFC\u51FA ")])),_:1},8,["loading"]),[[x,d.value]]),e(_,{type:"primary",size:"small",icon:"plus",onClick:ee},{default:a(()=>t[16]||(t[16]=[v("\u9879\u76EE\u7533\u62A5 ")])),_:1})])])]),default:a(()=>[e(ue,{ref_key:"tableListRef",ref:V,column:d.value?J:Z,data:E.value,total:H.value,onGetTableData:y},{action:a(({scope:o})=>[g("a",{onClick:p=>Q(o.row)},"\u8BE6\u60C5",8,he),d.value?M("",!0):(c(),b("a",{key:0,onClick:p=>K(o.row)},"\u7F16\u8F91",8,Ce)),d.value&&[10002,10005,10007,10013,20005].includes(o.row.status)?(c(),b("a",{key:1,onClick:p=>X(o.row)},"\u91CD\u65B0\u7533\u62A5",8,xe)):M("",!0),d.value&&[10007].includes(o.row.status)?(c(),b("a",{key:2,onClick:p=>re(o.row)},"\u5220\u9664",8,De)):M("",!0)]),_:1},8,["column","data","total"])]),_:1})]),_:1}),e(de,{modelValue:D.value,"onUpdate:modelValue":t[10]||(t[10]=o=>D.value=o),title:"\u9879\u76EE\u7533\u62A5\u6559\u5B66\u89C6\u9891",width:"800"},{default:a(()=>t[17]||(t[17]=[g("video",{style:{width:"100%"},src:Ye,controls:""},null,-1)])),_:1},8,["modelValue"])],64)}}});export{$e as default};