You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

2 lines
27KB

  1. import{g as ba}from"./formConfiguration.64ebe247.js";import{_ as Ta,d as xa,z as $a,A as Ea,G as La,D as qa,r as v,b as Ja,o as Va,N as Ha,c as O,e as b,f as Ie,g as l,u as x,h as u,i as r,t as L,j as S,k as P,I as C,F as ke,J as Ga,a2 as Ya,a3 as Ua,q as za,s as Wa,x as Ka}from"./index.121be81f.js";import Qa from"./basicInfo.b4be05de.js";import Xa from"./plannedUseResources.38740c5e.js";import Za from"./fundsInfo.cd1ed58b.js";import et from"./fundsAllocation.f7dba3fe.js";import at from"./annualPaymentPlan.d2ea2ed4.js";import tt from"./coreBusiness.86b608b7.js";import st from"./safetyInput.156b53af.js";import ot from"./projectImageProgress.9b451e1a.js";import rt from"./accessory.9714ee3a.js";import lt from"./projectRemark.dd7ed55b.js";import it from"./newModuleForm.ba512a3d.js";import nt from"./applications.2e41b598.js";import ut from"./hiddenAppForm.ae9becbd.js";import ft from"./flowRecordDialog.06003bc1.js";import{j as ct,k as dt,d as mt,s as pt}from"./index.c4a348b4.js";import{p as vt}from"./projectStore.94f188d8.js";import{a as _t}from"./annualPlanStore.ec71ef52.js";import{r as Dt,g as F}from"./uploadAction.544df052.js";import{d as yt}from"./projectCollectionEnter.4643d944.js";import gt from"./reviewCheck.3ff0ae14.js";import{g as Pa}from"./getIsShowReviewCheck.2beaaf24.js";import ht from"./provincialExamine.c2d271e0.js";import"./index.1f774a5b.js";import"./unitManage.f69733da.js";import"./userDialog.bf7a15df.js";import"./relatedProjectDialog.2489f763.js";import"./renewalProjectCapitalDeclare.d967b251.js";import"./projectContentDialog.4232318a.js";import"./indicatorTemplate.80c727a2.js";import"./appBasicInfo.c2768597.js";import"./appSafeInfo.28ebe685.js";import"./appResourceInfo.4bcc7b9f.js";import"./applicationInfo.a4798d62.js";import"./flowRecord.6f96f817.js";import"./index.3b212700.js";import"./index.3de4dfbb.js";import"./sjFlowRecord.d524d603.js";const k=de=>(za("data-v-29a32ad4"),de=de(),Wa(),de),It={class:"declarePage footerPage"},bt={key:0,class:"errorTip mb-16"},Pt=k(()=>l("p",{class:"title"},"\u6D41\u7A0B\u88AB\u9000\u56DE",-1)),jt={class:"card-header"},Ct={class:"flex justify-between items-center"},kt={class:"flex-1"},wt={class:"font-bold"},Ft={class:"mt-8 search"},Rt=k(()=>l("div",{class:"collapse-title"},"\u57FA\u672C\u4FE1\u606F",-1)),At={class:"p-24"},Ot=k(()=>l("div",{class:"collapse-title"},[l("span",null,"\u8D44\u91D1\u7533\u62A5\u60C5\u51B5\uFF08\u5355\u4F4D\uFF1A\u4E07\u5143\uFF09"),l("span",{class:"text-info"},"\u7533\u62A5\u91D1\u989D = \u81EA\u6709\u8D44\u91D1 + \u653F\u5E9C\u6295\u8D44-\u672C\u7EA7\u8D22\u653F\u8D44\u91D1 + \u653F\u5E9C\u6295\u8D44-\u4E0A\u7EA7\u8865\u52A9\u8D44\u91D1 + \u94F6\u884C\u8D37\u6B3E + \u5176\u4ED6\u8D44\u91D1")],-1)),St={class:"p-24"},Mt=k(()=>l("div",{class:"collapse-title"},[S(" \u8D44\u91D1\u5206\u914D\u60C5\u51B5\uFF08\u5355\u4F4D\uFF1A\u4E07\u5143\uFF09 "),l("span",{class:"text-info"},"\u8F6F\u4EF6\u5F00\u53D1 + \u4E91\u8D44\u6E90\u3001\u786C\u4EF6\u914D\u7F6E + \u7B2C\u4E09\u65B9\u670D\u52A1 = \u7533\u62A5\u91D1\u989D")],-1)),Nt={class:"p-24"},Bt=k(()=>l("div",{class:"collapse-title"}," \u91CD\u5927\u9879\u76EE\u7701\u7EA7\u8054\u5BA1\u4FE1\u606F ",-1)),Tt={class:"p-24"},xt=k(()=>l("div",{class:"collapse-title"},[S(" \u5E74\u5EA6\u652F\u4ED8\u8BA1\u5212\uFF08\u5355\u4F4D\uFF1A\u4E07\u5143\uFF09 "),l("span",{class:"text-info"},"\u5E74\u5EA6\u652F\u4ED8\u91D1\u989D = \u81EA\u6709\u8D44\u91D1 + \u653F\u5E9C\u6295\u8D44-\u672C\u7EA7\u8D22\u653F\u8D44\u91D1 + \u653F\u5E9C\u6295\u8D44-\u4E0A\u7EA7\u8865\u52A9\u8D44\u91D1 + \u94F6\u884C\u8D37\u6B3E + \u5176\u4ED6\u8D44\u91D1")],-1)),$t={class:"p-24"},Et=k(()=>l("div",{class:"collapse-title"},"\u6838\u5FC3\u4E1A\u52A1",-1)),Lt={class:"p-24"},qt=k(()=>l("div",{class:"collapse-title"},"\u5B89\u5168\u6295\u5165",-1)),Jt={class:"p-24"},Vt=k(()=>l("div",{class:"collapse-title"},"\u5DE5\u7A0B\u5F62\u8C61\u8FDB\u5EA6",-1)),Ht={class:"p-24"},Gt=k(()=>l("div",{class:"collapse-title"},"\u5BA1\u67E5\u6E05\u5355",-1)),Yt={class:"p-24"},Ut=k(()=>l("div",{class:"collapse-title"},"\u9644\u4EF6",-1)),zt={class:"p-24"},Wt=k(()=>l("div",{class:"collapse-title"},"\u5907\u6CE8",-1)),Kt={class:"p-24"},Qt={class:"collapse-title"},Xt={class:"p-24"},Zt=k(()=>l("div",{class:"collapse-title"},"\u5E94\u7528\u4FE1\u606F",-1)),es={class:"p-24"},as=k(()=>l("div",{class:"collapse-title"},"\u8BA1\u5212\u4F7F\u7528\u8D44\u6E90",-1)),ts={class:"p-24"},ss={class:"footer"},os=xa({name:"declarePage"}),rs=Object.assign(os,{setup(de){const{proxy:me}=Ka(),f=$a(),pe=Ea(),M=La(qa.userStore).userInfo||{},n=v({}),be=v(["1","2","3","4","5","6","7","8","9","10"]),a=v(),ve=v(),d=v(),N=v(),Pe=v(),_e=v(),$=v(),q=v(),De=v(),D=v(),je=v(),J=v({}),j=v(),we=v(),Ce=v(),ja=()=>{var s,m,y;const t=[];if(((s=a.value.formData)==null?void 0:s.baseProjIsConfidentiality)==="02")t.push(new Promise((e,i)=>{a.value.validForm(o=>{o&&e()})}));else{t.push(new Promise((e,i)=>{a.value.validForm(o=>{o&&(d.value.formData.declareAmount>=1e3&&a.value.formData.baseProvManDeprtType==="2"?(a.value.formData.baseProvManDeprtType="",i("\u6839\u636E\u300A\u6D59\u6C5F\u7701\u7535\u5B50\u653F\u52A1\u91CD\u5927\u5E94\u7528\u9879\u76EE\u8054\u5BA1\u300B\u8981\u6C42\uFF1A\u5927\u4E8E1000\u4E07\u5143\u7684\u91CD\u5927\u9879\u76EE\u5C06\u7531\u7701\u7EA7\u6570\u6539\u7275\u5934\u90E8\u95E8\u53CA\u4E1A\u52A1\u4E3B\u7BA1\u5355\u4F4D\u8FDB\u884C\u8054\u5BA1\uFF0C\u8BF7\u5C06\u4E0A\u7EA7\u4E3B\u7BA1\u5355\u4F4D\u4FEE\u6539\u4E3A\u60A8\u5BF9\u5E94\u6761\u7EBF\u7684\u7701\u7EA7\u4E3B\u7BA1\u5355\u4F4D\u3002")):e())})})),t.push(new Promise((e,i)=>{d.value.validForm(o=>{o&&e()})})),t.push(new Promise((e,i)=>{N.value.validForm(o=>{o&&e()})})),t.push(new Promise((e,i)=>{_e.value.validForm(o=>{o&&e()})})),n.value.isCoreBusiness&&t.push(new Promise((e,i)=>{$.value.validForm(o=>{o&&e()})})),n.value.isSafetyInput&&t.push(new Promise((e,i)=>{q.value.validForm(o=>{o&&e()})})),n.value.isProjectImageProgress&&t.push(new Promise((e,i)=>{De.value.validForm(o=>{o&&e()})})),Pa()&&n.value.isReviewChecklist&&(f.name==="declarePlan"||[10012,10013,10016].includes((m=c.value)==null?void 0:m.status))&&t.push(new Promise((e,i)=>{Ce.value.validForm(o=>{o&&e()})})),t.push(new Promise((e,i)=>{D.value.validForm(o=>{o&&e()})}));for(const e in J.value)t.push(new Promise((i,o)=>{J.value[e].validForm(h=>{h&&i()})}));j.value&&t.push(new Promise((e,i)=>{j.value.validForm(o=>{o&&e()})})),t.push(new Promise((e,i)=>{d.value.validForm(o=>{if(o){const h=Fe([d.value.formData.declareHaveAmount,d.value.formData.declareGovOwnFinanceAmount,d.value.formData.declareGovSuperiorFinanceAmount,d.value.formData.declareBankLendingAmount,d.value.formData.declareOtherAmount]);d.value.formData.declareAmount>0&&d.value.formData.declareAmount===h?e():i("\u8D44\u91D1\u7533\u62A5\u60C5\u51B5\uFF1A5\u7C7B\u8D44\u91D1\u603B\u548C\u5FC5\u987B\u7B49\u4E8E\u7533\u62A5\u91D1\u989D")}})})),t.push(new Promise((e,i)=>{N.value.validForm(o=>{if(o){const h=Fe([N.value.formData.softwareDevelopmentAmount,N.value.formData.cloudHardwarePurchaseAmount,N.value.formData.thirdPartyAmount]);d.value.formData.declareAmount>0&&d.value.formData.declareAmount===h?e():i("\u8D44\u91D1\u5206\u914D\u60C5\u51B5\uFF1A3\u7C7B\u8D44\u91D1\u603B\u548C\u5FC5\u987B\u7B49\u4E8E\u7533\u62A5\u91D1\u989D")}})})),((y=j.value)==null?void 0:y.formData.includeApplication)===1&&t.push(new Promise((e,i)=>{we.value.validAllAppForm(o=>{o?e():i("\u8BF7\u5B8C\u5584\u5DF2\u6DFB\u52A0\u7684\u5E94\u7528\u4FE1\u606F")})})),ve.value&&t.push(new Promise((e,i)=>{ve.value.validForm(o=>{o&&e()})}))}Promise.all([...t]).then(async()=>{var e,i;((e=a.value.formData)==null?void 0:e.baseProjIsConfidentiality)==="02"?V(1):n.value.isSafetyInput&&((i=q.value)==null?void 0:i.formData.safetyInput.reduce((g,R)=>g+R.safetyInputAmount,0))/d.value.formData.declareAmount*100<5?me.$messageBox.confirm("\u5F53\u524D\u5B89\u5168\u6295\u5165\u5360\u6BD4\u4F4E\u4E8E5%\uFF0C\u786E\u8BA4\u8981\u63D0\u4EA4\u5417?","\u786E\u8BA4\u8981\u63D0\u4EA4\u5417\uFF1F",{type:"warning"}).then(async()=>{V(1)}):V(1)}).catch(e=>{e&&me.$message.warning(e)})},Fe=t=>{const s=[];t.forEach(e=>{try{s.push(e.toString().split(".")[1].length)}catch{s.push(0)}});const m=Math.pow(10,Math.max(...s));let y=0;return t.forEach(e=>{y+=e*m}),y/m},Ca=async()=>{V(2)},ka=t=>{var s,m,y,e,i,o,h;((s=j.value)==null?void 0:s.formData)&&((m=j.value)==null?void 0:m.formData.includeApplication)===1&&((i=(e=(y=j.value)==null?void 0:y.formData)==null?void 0:e.applicationList)==null?void 0:i.length)&&(j.value.formData.applicationList=(h=(o=j.value.formData)==null?void 0:o.applicationList)==null?void 0:h.map(g=>({...g,applicationName:t?g.applicationName:void 0,relatedExistsApplication:t?void 0:g.relatedExistsApplication,relatedExistsApplicationCode:t?void 0:g.relatedExistsApplication})))},ye=v(!1),ge=v(!1),V=async t=>{var m,y,e,i,o,h,g,R,_,he,Y,U,z,W,K,Q,X,B,Z,ee,ae,te,se,oe,re,le,ie,ne,ue,fe,I,w,A,ce,Ae,Oe,Se,Me,Ne,Be,Te,xe,$e,Ee,Le,qe,Je,Ve,He,Ge,Ye,Ue,ze,We,Ke,Qe,Xe,Ze,ea,aa,ta,sa,oa,ra,la,ia,na,ua,fa,ca,da,ma,pa,va,_a;var s={};if(((m=a.value.formData)==null?void 0:m.baseProjIsConfidentiality)==="02")s={isRemarks:n.value.isRemarks,isOpenCoreBusiness:n.value.isCoreBusiness,isOpenSafetyInput:n.value.isSafetyInput,isEngineeringSpeed:n.value.isProjectImageProgress,isReviewChecklist:n.value.isReviewChecklist,id:f.query.id*1||void 0,baseProjIsConfidentiality:(y=a.value.formData)==null?void 0:y.baseProjIsConfidentiality,projectName:(e=a.value.formData)==null?void 0:e.projectName,projectType:(i=a.value.formData)==null?void 0:i.projectType,baseConstructionType:((h=(o=a.value.formData)==null?void 0:o.baseConstructionType)==null?void 0:h.join("\uFF1B"))||"",responsibleMan:(g=a.value.formData)==null?void 0:g.responsibleMan,responsibleManMobile:(R=a.value.formData)==null?void 0:R.responsibleManMobile,contactName:(_=a.value.formData)==null?void 0:_.contactName,contactPhone:(he=a.value.formData)==null?void 0:he.contactPhone,buildOrgName:(Y=a.value.formData)==null?void 0:Y.buildOrgName,orgCreditCode:(U=a.value.formData)==null?void 0:U.orgCreditCode,baseProvManDeprtType:a.value.formData.baseProvManDeprtType*1||void 0,higherSuperOrg:(z=a.value.formData)==null?void 0:z.higherSuperOrg,higherSuperOrgCode:(W=a.value.formData)==null?void 0:W.higherSuperOrgCode,superOrg:(K=a.value.formData)==null?void 0:K.superOrg,superOrgCode:(Q=a.value.formData)==null?void 0:Q.superOrgCode,superOrgCreditCode:(X=a.value.formData)==null?void 0:X.superOrgCreditCode,projectYear:((B=a.value.formData)==null?void 0:B.projectYear)*1,declareAmount:(Z=a.value.formData)==null?void 0:Z.declareAmount,annualPlanAmount:(ee=a.value.formData)==null?void 0:ee.declareAmount};else if(s={isRemarks:n.value.isRemarks,isOpenCoreBusiness:n.value.isCoreBusiness,isOpenSafetyInput:n.value.isSafetyInput,isEngineeringSpeed:n.value.isProjectImageProgress,isReviewChecklist:n.value.isReviewChecklist,id:f.query.id*1||void 0,...a.value.formData,...d.value.formData,...N.value.formData,...(ae=ve.value)==null?void 0:ae.formData,baseConstructionType:((se=(te=a.value.formData)==null?void 0:te.baseConstructionType)==null?void 0:se.join("\uFF1B"))||"",baseProvManDeprtType:a.value.formData.baseProvManDeprtType*1||void 0,projectYear:((oe=d.value.formData)==null?void 0:oe.projectYear)*1,beginTime:((le=(re=a.value.formData)==null?void 0:re.buildDuration)==null?void 0:le.length)&&a.value.formData.buildDuration[0],endTime:((ne=(ie=a.value.formData)==null?void 0:ie.buildDuration)==null?void 0:ne.length)&&a.value.formData.buildDuration[1],buildDuration:void 0,lowestLevel:!(((fe=(ue=a.value.formData)==null?void 0:ue.baseConstructionType)==null?void 0:fe.includes("03"))&&!((w=(I=a.value.formData)==null?void 0:I.baseConstructionType)!=null&&w.includes("01")))&&((A=a.value.formData)==null?void 0:A.lowestLevel)||"",baseProjBasis:((Oe=(Ae=(ce=a.value.formData)==null?void 0:ce.baseProjBasis)==null?void 0:Ae.map(p=>p.value))==null?void 0:Oe.join("\uFF1B"))||void 0,baseProjBasisFile:((Ne=(Me=(Se=a.value.formData)==null?void 0:Se.baseProjBasis)==null?void 0:Me.map(p=>p.fileList&&JSON.stringify(F(p.fileList))))==null?void 0:Ne.join("\uFF1B"))||"",baseHistorProjId:((xe=(Te=(Be=a.value.formData)==null?void 0:Be.baseHistorProjs)==null?void 0:Te.map(p=>p.baseProjId))==null?void 0:xe.join("\uFF1B"))||"",baseHistorProjName:((Le=(Ee=($e=a.value.formData)==null?void 0:$e.baseHistorProjs)==null?void 0:Ee.map(p=>p.baseProjName))==null?void 0:Le.join("\uFF1B"))||"",baseHistorProjYear:((Ve=(Je=(qe=a.value.formData)==null?void 0:qe.baseHistorProjs)==null?void 0:Je.map(p=>p.baseProjSetYear))==null?void 0:Ve.join("\uFF1B"))||"",baseHistorProjs:void 0,beseExpectedResults:((Ge=(He=a.value.formData)==null?void 0:He.beseExpectedResults)==null?void 0:Ge.length)&&JSON.stringify(a.value.formData.beseExpectedResults)||"",baseBasisAmountOri:((Ye=d.value)==null?void 0:Ye.formData.declareOtherAmount)>0&&((Ue=d.value.formData)==null?void 0:Ue.baseBasisAmountOri)||"",consultancy:((ze=d.value)==null?void 0:ze.formData.declareAmount)>400&&((We=d.value.formData)==null?void 0:We.consultancy)||"",operationManageUnit:((Ke=d.value)==null?void 0:Ke.formData.declareAmount)>=1e3&&Pe.value.formData.operationManageUnit||void 0,...(Qe=j.value)==null?void 0:Qe.formData,..._e.value.formData,...D.value.formData,constructionPlanFile:((Xe=D.value.formData)==null?void 0:Xe.constructionPlanFile)&&JSON.stringify(F(D.value.formData.constructionPlanFile)),preliminaryPlanFile:((Ze=D.value.formData)==null?void 0:Ze.preliminaryPlanFile)&&JSON.stringify(F(D.value.formData.preliminaryPlanFile)),mainResponsibilitiesApplicantFile:((ea=D.value.formData)==null?void 0:ea.mainResponsibilitiesApplicantFile)&&JSON.stringify(F(D.value.formData.mainResponsibilitiesApplicantFile)),supportingMaterialsFile:((aa=D.value.formData)==null?void 0:aa.supportingMaterialsFile)&&JSON.stringify(F(D.value.formData.supportingMaterialsFile)),calculationTotalInvestmentFile:((ta=D.value.formData)==null?void 0:ta.calculationTotalInvestmentFile)&&JSON.stringify(F(D.value.formData.calculationTotalInvestmentFile)),projectApplicationForm:((sa=a.value.formData)==null?void 0:sa.projectType)!=="03"&&((oa=D.value.formData)==null?void 0:oa.projectApplicationForm)&&JSON.stringify(F(D.value.formData.projectApplicationForm))||"",baseResearchReportFile:((ra=a.value.formData)==null?void 0:ra.projectType)!=="03"&&((la=D.value.formData)==null?void 0:la.baseResearchReportFile)&&JSON.stringify(F(D.value.formData.baseResearchReportFile))||"",baseProjOtherFile:((ia=D.value.formData)==null?void 0:ia.baseProjOtherFile)&&JSON.stringify(F(D.value.formData.baseProjOtherFile)),mainAccusationDoc:((na=d.value)==null?void 0:na.formData.declareAmount)>=1e3&&((ua=D.value.formData)==null?void 0:ua.mainAccusationDoc)&&JSON.stringify(F(D.value.formData.mainAccusationDoc))||"",reviewChecklist:((ca=(fa=Ce.value)==null?void 0:fa.formData)==null?void 0:ca.reviewChecklist)||void 0},n.value.isCoreBusiness&&(s=Object.assign(s,{...$.value.formData,coreBusiness:$.value.formData.coreBusiness&&JSON.stringify($.value.formData.coreBusiness)})),n.value.isSafetyInput&&(s=Object.assign(s,{safetyInputDescribe:JSON.stringify(q.value.formData.safetyInput)})),n.value.isProjectImageProgress&&(s=Object.assign(s,{...De.value.formData})),n.value.isRemark&&(s=Object.assign(s,{...je.value.formData})),((ma=(da=j.value)==null?void 0:da.formData)==null?void 0:ma.includeApplication)&&((va=(pa=j.value)==null?void 0:pa.formData.applicationList)==null?void 0:va.length)&&(s.applicationList=j.value.formData.applicationList.map(p=>{var E,T,Da,ya,ga;return{...p,isFirst:(E=a.value.formData)!=null&&E.isFirst?1:0,relatedExistsApplication:(!((T=a.value.formData)!=null&&T.isFirst)&&M.value.regionCode==="331123"||M.regionCode!=="331123")&&((Da=p.relatedExistsApplication)==null?void 0:Da.applicationName)||void 0,relatedExistsApplicationCode:(!((ya=a.value.formData)!=null&&ya.isFirst)&&M.value.regionCode==="331123"||M.regionCode!=="331123")&&p.relatedExistsApplicationCode||void 0,applicationName:((ga=a.value.formData)==null?void 0:ga.isFirst)&&M.regionCode==="331123"&&p.applicationName||void 0,coreBusinessList:p.coreBusinessList.map(Ba=>{var ha,Ia;return{...Ba,projectId:((ha=c.value)==null?void 0:ha.projectId)||void 0,projectCode:((Ia=c.value)==null?void 0:Ia.projectCode)||void 0}})}})),(_a=n.value.safetyInputModular)!=null&&_a.length){s.safetyInputModular=[];for(const E in J.value)s.safetyInputModular.push(J.value[E].formData);const p=s.safetyInputModular.map(E=>({...E,formList:E.formList.map(T=>({...T,value:T.value?T.props.type==="\u6587\u4EF6\u4E0A\u4F20"?F(T.value):T.value:void 0}))}));s.safetyInputModular=JSON.stringify(p)}else s.safetyInputModular=void 0;if(t===1){ge.value=!0;try{const p={projectInfo:{...s,id:f.query.isDraft?void 0:s.id,draftId:f.query.isDraft?f.query.id*1:void 0}};f.name==="declarePage"?await dt(!f.query.isDraft&&f.query.id?2:1,p):f.name==="planEdit"?await _t(p.projectInfo):f.name==="handleAfterGiveBack"?await Ya({...p,projectId:f.query.id,instanceId:f.query.instanceId,taskId:f.query.taskId}):f.name==="declarePlan"&&await mt(p),me.$message.success("\u63D0\u4EA4\u6210\u529F"),ge.value=!1,f.name==="projectDeclare"?pe.push({name:"projectDeclare"}):pe.go(-1)}catch{ge.value=!1}}else if(t===2){ye.value=!0;try{await pt({projectInfo:{...s},user:M.value}),me.$message.success("\u4FDD\u5B58\u6210\u529F"),ye.value=!1,pe.go(-1)}catch{ye.value=!1}}},c=v({}),wa=()=>{var t,s;a.value.setFormData(c.value),((t=c.value)==null?void 0:t.baseProjIsConfidentiality)!=="02"&&(d.value.setFormData(c.value),N.value.setFormData(c.value),_e.value.setFormData(c.value),n.value.isCoreBusiness&&$.value.setFormData(c.value),n.value.isSafetyInput&&q.value.setFormData(c.value),n.value.isProjectImageProgress&&De.value.setFormData(c.value),D.value.setFormData(c.value),n.value.isRemark&&je.value.setFormData(c.value),(s=j.value)==null||s.setFormData(c.value),setTimeout(()=>{var m;(m=Pe.value)==null||m.setFormData(c.value)}))},H=v({processProgressVo:{progressInfo:[]}}),Fa=v(),Ra=async()=>{var s,m;const t=await Ua({instanceId:f.query.instanceId,projectId:f.query.id,nodeId:f.query.nodeId});H.value={...t.data,processProgressVo:{...t.data.processProgressVo,progressInfo:Oa(t.data.processProgressVo.progressInfo)}},Fa.value=((m=(s=H.value.processProgressVo.progressInfo.slice(-1)[0])==null?void 0:s.children)==null?void 0:m.slice(-1)[0])||H.value.processProgressVo.progressInfo.slice(-1)[0]},G=Ja({visible:!1,flowData:void 0}),Aa=t=>{G.visible=!0,G.flowData=H.value.processProgressVo.progressInfo},Oa=t=>(t.forEach(s=>{if(s.children){const m=[],y=[];s.children.forEach(e=>{m.includes(e.nodeId)?(y.find(i=>i.nodeId===e.nodeId).list.push(e),y.find(i=>i.nodeId===e.nodeId).userIds.push(e.userId)):(m.push(e.nodeId),y.push({nodeId:e.nodeId,approvalMode:e.approvalMode,name:e.name,taskId:e.taskId,nodeType:e.nodeType,list:[{...e}],userIds:[e.userId]}))}),s.children=y}else s.userIds=[s.userId]}),t),Sa=()=>{G.visible=!1},Re=v([]),Ma=v(),Na=t=>{Ma.value=t};return Va(async()=>{var e,i,o,h;if(Re.value=(await yt()).data,f.query.id){var t={},s={},m=[],y=!1;(e=f.query)!=null&&e.isDraft?t=await ct({id:f.query.id}):(t=await vt(f.query.id),s=await ba({regionCode:M.value.regionCode}),(f.name==="declarePlan"||[10012,10013,10016].includes((i=c.value)==null?void 0:i.status))&&(y=t.data.reviewChecklist&&((o=JSON.parse(t.data.reviewChecklist))==null?void 0:o.length)?!0:s.data.isReviewChecklist,m=s.data.reviewChecklist&&JSON.parse(s.data.reviewChecklist)||[])),c.value={...t.data,reviewChecklist:t.data.reviewChecklist?JSON.parse(t.data.reviewChecklist):void 0};const g=t.data.safetyInputModular&&JSON.parse(t.data.safetyInputModular).map(R=>({...R,formList:R.formList.map(_=>({..._,value:_.value?_.props.type==="\u6587\u4EF6\u4E0A\u4F20"?Dt(_.value):_.value:void 0}))}));n.value={isCoreBusiness:t.data.isOpenCoreBusiness,isProjectImageProgress:t.data.isEngineeringSpeed,isRemark:t.data.isRemark,isSafetyInput:t.data.isOpenSafetyInput,safetyInputModular:g||[],isReviewChecklist:y,reviewChecklist:m},Ha(()=>{wa()}),f.name==="handleAfterGiveBack"&&Ra()}else{const g=await ba({regionCode:M.value.regionCode});n.value={isCoreBusiness:g.data.isCoreBusiness,isProjectImageProgress:g.data.isProjectImageProgress,isRemark:g.data.isRemark,isSafetyInput:g.data.isSafetyInput,safetyInputModular:g.data.safetyInputModular||[]}}if((h=n.value.safetyInputModular)!=null&&h.length){let g=11;n.value.safetyInputModular.forEach(R=>{be.value.push(g+++"")})}}),(t,s)=>{var Y,U,z,W,K,Q,X;const m=O("Warning"),y=O("el-icon"),e=O("el-button"),i=O("el-form-item"),o=O("el-col"),h=O("el-row"),g=O("el-form"),R=O("el-card"),_=O("el-collapse-item"),he=O("el-collapse");return b(),Ie(ke,null,[l("div",It,[x(f).name==="handleAfterGiveBack"?(b(),Ie("div",bt,[u(y,{class:"icon"},{default:r(()=>[u(m)]),_:1}),l("div",null,[Pt,l("p",null,[l("span",null,L((Y=c.value)==null?void 0:Y.projectName)+"\u7684"+L((z=(U=H.value)==null?void 0:U.processProgressVo)==null?void 0:z.processDefName)+"\u88AB\u9000\u56DE\uFF0C\u8BF7\u6839\u636E\u5BA1\u6838\u8BB0\u5F55\u8C03\u6574\u9879\u76EE\u4FE1\u606F",1),u(e,{type:"primary",plain:"",size:"small",class:"ml-16",onClick:Aa},{default:r(()=>[S("\u67E5\u770B\u5BA1\u6838\u8BB0\u5F55")]),_:1})])])])):P("",!0),x(f).name==="declarePlan"?(b(),C(R,{key:1,shadow:"never",class:"mb-16"},{default:r(()=>[l("div",jt,[l("div",Ct,[l("div",kt,[l("p",wt,L(c.value.projectName),1),l("div",Ft,[u(g,{"label-suffix":":"},{default:r(()=>[u(h,{gutter:24},{default:r(()=>[u(o,{span:6},{default:r(()=>[u(i,{label:"\u7533\u62A5\u5355\u4F4D"},{default:r(()=>[S(L(c.value.buildOrgName||"-"),1)]),_:1})]),_:1}),u(o,{span:6},{default:r(()=>[u(i,{label:"\u4E3B\u7BA1\u5355\u4F4D"},{default:r(()=>[S(L(c.value.superOrg||"-"),1)]),_:1})]),_:1}),u(o,{span:6},{default:r(()=>[u(i,{label:"\u521B\u5EFA\u65F6\u95F4"},{default:r(()=>[S(L(c.value.createOn||"-"),1)]),_:1})]),_:1})]),_:1})]),_:1})])])])])]),_:1})):P("",!0),u(h,null,{default:r(()=>[u(o,{class:"leftCol",span:24},{default:r(()=>[u(he,{modelValue:be.value,"onUpdate:modelValue":s[0]||(s[0]=B=>be.value=B)},{default:r(()=>{var B,Z,ee,ae,te,se,oe,re,le,ie,ne,ue,fe;return[u(_,{name:"1",class:"mb-16"},{title:r(()=>[Rt]),default:r(()=>{var I;return[l("div",At,[u(Qa,{ref_key:"basicInfoRef",ref:a,"detail-data":c.value,"dictionary-list":Re.value,"declare-amount":(I=d.value)==null?void 0:I.formData.declareAmount,onChangeIsFirst:ka,onGetBasicInfoData:Na},null,8,["detail-data","dictionary-list","declare-amount"])])]}),_:1}),((Z=(B=a.value)==null?void 0:B.formData)==null?void 0:Z.baseProjIsConfidentiality)==="01"?(b(),Ie(ke,{key:0},[((ae=(ee=a.value)==null?void 0:ee.formData)==null?void 0:ae.baseProjIsConfidentiality)==="01"?(b(),C(_,{key:0,name:"2",class:"mb-16"},{title:r(()=>[Ot]),default:r(()=>[l("div",St,[u(Za,{ref_key:"fundsInfoRef",ref:d,"detail-data":c.value},null,8,["detail-data"])])]),_:1})):P("",!0),((se=(te=a.value)==null?void 0:te.formData)==null?void 0:se.baseProjIsConfidentiality)==="01"?(b(),C(_,{key:1,name:"3",class:"mb-16"},{title:r(()=>[Mt]),default:r(()=>[l("div",Nt,[u(et,{ref_key:"fundsAllocationRef",ref:N},null,512)])]),_:1})):P("",!0),((oe=d.value)==null?void 0:oe.formData.declareAmount)>=1e3&&((le=(re=a.value)==null?void 0:re.formData)==null?void 0:le.baseProjIsConfidentiality)==="01"?(b(),C(_,{key:2,name:"10",class:"mb-16"},{title:r(()=>[Bt]),default:r(()=>[l("div",Tt,[u(ht,{ref_key:"provincialExamineRef",ref:Pe},null,512)])]),_:1})):P("",!0),((ne=(ie=a.value)==null?void 0:ie.formData)==null?void 0:ne.baseProjIsConfidentiality)==="01"?(b(),C(_,{key:3,name:"4",class:"mb-16"},{title:r(()=>[xt]),default:r(()=>[l("div",$t,[u(at,{ref_key:"annualPaymentPlanRef",ref:_e},null,512)])]),_:1})):P("",!0),n.value.isCoreBusiness?(b(),C(_,{key:4,name:"5",class:"mb-16"},{title:r(()=>[Et]),default:r(()=>{var I;return[l("div",Lt,[u(tt,{ref_key:"coreBusinessRef",ref:$,"basic-info-data":(I=a.value)==null?void 0:I.formData},null,8,["basic-info-data"])])]}),_:1})):P("",!0),n.value.isSafetyInput?(b(),C(_,{key:5,name:"6",class:"mb-16"},{title:r(()=>[qt]),default:r(()=>[l("div",Jt,[u(st,{ref_key:"safetyInputRef",ref:q},null,512)])]),_:1})):P("",!0),n.value.isProjectImageProgress?(b(),C(_,{key:6,name:"7",class:"mb-16"},{title:r(()=>[Vt]),default:r(()=>[l("div",Ht,[u(ot,{ref_key:"projectImageProgressRef",ref:De},null,512)])]),_:1})):P("",!0),x(Pa)()&&n.value.isReviewChecklist&&(t.$route.name==="declarePlan"||[10012,10013,10016].includes((ue=c.value)==null?void 0:ue.status))?(b(),C(_,{key:7,name:"8",class:"mb-16"},{title:r(()=>[Gt]),default:r(()=>[l("div",Yt,[u(gt,{ref_key:"reviewCheckRef",ref:Ce,"detail-data":c.value,data:c.value.reviewChecklist||n.value.reviewChecklist},null,8,["detail-data","data"])])]),_:1})):P("",!0),u(_,{name:"8",class:"mb-16"},{title:r(()=>[Ut]),default:r(()=>{var I,w,A;return[l("div",zt,[u(rt,{ref_key:"accessoryRef",ref:D,"detail-data":c.value,"project-type":(w=(I=a.value)==null?void 0:I.formData)==null?void 0:w.projectType,"declare-amount":(A=d.value)==null?void 0:A.formData.declareAmount},null,8,["detail-data","project-type","declare-amount"])])]}),_:1}),n.value.isRemark?(b(),C(_,{key:8,name:"9",class:"mb-16"},{title:r(()=>[Wt]),default:r(()=>[l("div",Kt,[u(lt,{ref_key:"projectRemarkRef",ref:je},null,512)])]),_:1})):P("",!0),(fe=n.value.safetyInputModular)!=null&&fe.length?(b(!0),Ie(ke,{key:9},Ga(n.value.safetyInputModular,(I,w)=>(b(),C(_,{key:w,name:11+w+"",class:"mb-16"},{title:r(()=>[l("div",Qt,L(I.moduleName),1)]),default:r(()=>[l("div",Xt,[u(it,{ref_for:!0,ref:A=>{J.value[I.id]=A},data:I},null,8,["data"])])]),_:2},1032,["name"]))),128)):P("",!0),t.$route.name==="declarePlan"||[10012,10016,10013].includes(c.value.status)?(b(),C(_,{key:10,name:"4",class:"mb-16"},{title:r(()=>[Zt]),default:r(()=>{var I,w,A,ce;return[l("div",es,[u(nt,{ref_key:"applicationsRef",ref:j,"is-first":(w=(I=a.value)==null?void 0:I.formData)==null?void 0:w.isFirst,"core-business":(ce=(A=$.value)==null?void 0:A.formData)==null?void 0:ce.coreBusiness},null,8,["is-first","core-business"])])]}),_:1})):P("",!0),t.$route.name==="declarePlan"||[10012,10016,10013].includes(c.value.status)?(b(),C(_,{key:11,name:"1",class:"mb-16"},{title:r(()=>[as]),default:r(()=>[l("div",ts,[u(Xa,{ref_key:"planndedUseResourcesRef",ref:ve,"detail-data":c.value},null,8,["detail-data"])])]),_:1})):P("",!0)],64)):P("",!0)]}),_:1},8,["modelValue"])]),_:1})]),_:1}),u(ut,{ref_key:"hiddenAppFormRef",ref:we,"application-list":(K=(W=j.value)==null?void 0:W.formData)==null?void 0:K.applicationList,"is-first":(X=(Q=a.value)==null?void 0:Q.formData)==null?void 0:X.isFirst},null,8,["application-list","is-first"]),l("div",ss,[u(e,{onClick:s[1]||(s[1]=B=>x(pe).go(-1))},{default:r(()=>[S(" \u8FD4\u56DE ")]),_:1}),x(f).name==="declarePage"&&(!x(f).query.id||x(f).query.id&&x(f).query.isDraft)?(b(),C(e,{key:0,plain:"",type:"primary",loading:ye.value,onClick:Ca},{default:r(()=>[S(" \u6682 \u5B58 ")]),_:1},8,["loading"])):P("",!0),u(e,{type:"primary",loading:ge.value,onClick:ja},{default:r(()=>[S(" \u63D0\u4EA4\u5BA1\u6838 ")]),_:1},8,["loading"])])]),u(ft,{visible:G.visible,"flow-data":G.flowData,onClose:Sa},null,8,["visible","flow-data"])],64)}}}),Gs=Ta(rs,[["__scopeId","data-v-29a32ad4"]]);export{Gs as default};