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
15KB

  1. import{h as ge,f as ye,c as T,b as Ce}from"./uploadAction.6ab57011.js";import{d as xe,B as Ae,x as Re,y as we,r as _,b as Ve,o as Ie,L as ke,c,e as v,f as U,g as p,h as s,i as a,G as w,F as N,H as W,j as i,t as d,k as O,u as x,q as Ue}from"./index.55251523.js";import{i as B}from"./index.f55de596.js";import{s as Ne}from"./finalInspectionDeclare.fd1d0194.js";import{p as De}from"./projectStore.aceb2df8.js";import $e from"./projectContentDialog.7baa1045.js";const He={class:"uploadInitfinalAcceptanceMaterials footerPage"},Me={class:"pb-24"},he={class:"pl-24"},Ee={class:"font-semibold text-14 mb-16"},Le={class:"text-primary"},Se={class:"p-16"},Oe=["onClick"],Be=["onClick"],Fe={class:"text-right w-full mt-8"},je={class:"collapse-title"},qe={class:"footer"},Pe=xe({name:"declarationFinal"}),Xe=Object.assign(Pe,{setup(Je){const K=Ae.dictStore.uploadUrl,D=Re(),{proxy:Q}=Ue(),F=we(),j=["1","2","3","4","5","6","7"],q=_(),f=_({finalAcceptanceMaterials:[{title:"\u9A8C\u6536\u6750\u6599",data:[{name:"\u7528\u6237\u4F7F\u7528\u62A5\u544A",isHave:!0,files:[],reason:""},{name:"IRS\u5E94\u7528\u8BD5\u8FD0\u884C\u62A5\u544A",isHave:!0,files:[],reason:""},{name:"\u4FE1\u606F\u5B89\u5168\u7B49\u7EA7\u4FDD\u62A4\u6D4B\u8BD5\u62A5\u544A",isHave:!0,files:[],reason:""},{name:"\u9879\u76EE\u603B\u7ED3\u62A5\u544A",isHave:!0,files:[],reason:""},{name:"\u5EFA\u8BBE\u6838\u67E5\u8868",isHave:!0,files:[],reason:""},{name:"\u5176\u4ED6\u9644\u4EF6",isHave:!0,files:[],reason:""}]}]}),X=[{label:"\u5E8F\u53F7",type:"index",width:"60"},{label:"\u6750\u6599\u540D\u79F0",key:"name",prop:"name"},{label:"\u662F\u5426\u6709\u6750\u6599",key:"isHave",slot:"isHave",width:100},{label:"\u9644\u4EF6/\u8BF4\u660E\uFF08\u652F\u6301\u6269\u5C55\u540D\uFF1A.doc .docx .pdf\uFF09",key:"files",slot:"files"}],A=_([{name:"\u5E94\u75281",status:"\u8FD0\u884C\u4E2D",memoryRate:11,cpuRate:33,cpRate:44},{name:"\u5E94\u75282",status:"\u8FD0\u884C\u4E2D",memoryRate:68,cpuRate:43,cpRate:30}]),r=_({});let $,H,M;const Y=_(),Z=_(),ee=_(),h=(n,e,g)=>{const o=[e,"rgba(0, 0, 0, 0.1)"];return{legend:{show:!1},graphic:[{type:"text",left:"center",top:"48%",style:{text:`${n}%`,fill:"#333333",fontSize:16,fontWeight:"bold",fontFamily:"DINAlternate-Bold, DINAlternate"}},{type:"text",left:"center",bottom:"0",style:{text:`${g}`,fill:"#333333",fontSize:12}}],series:[{type:"pie",radius:["58%","75%"],center:["50%","50%"],avoidLabelOverlap:!1,data:[{value:n},{value:100-n}],itemStyle:{color:function(u){return o[u.dataIndex]}},labelLine:{show:!1}}]}},ae=()=>{$||($=B(Y.value));const n=h(r.value.memoryRate,"#5ADE92","\u8FD1\u4E09\u4E2A\u6708\u5185\u5B58\u5E73\u5747\u4F7F\u7528\u7387");$.setOption(n)},le=()=>{H||(H=B(Z.value));const n=h(r.value.cpuRate,"#0967FD","\u8FD1\u4E09\u4E2A\u6708CPU\u5E73\u5747\u4F7F\u7528\u7387");H.setOption(n)},te=()=>{M||(M=B(ee.value));const n=h(r.value.cpRate,"#ffae00","\u8FD1\u4E09\u4E2A\u6708\u78C1\u76D8\u5E73\u5747\u4F7F\u7528\u7387");M.setOption(n)},se=()=>{ae(),le(),te()},E=_(0),oe=n=>{E.value=n,r.value=A.value[n],se()},V=_(!1),ne=async n=>{!n||n.validate(async(e,g)=>{if(e){V.value=!0;const o={id:D.query.id,isCompletedLogCollection:f.value.isCompletedLogCollection,finalAcceptanceMaterials:JSON.stringify(f.value.finalAcceptanceMaterials),beseExpectedResults:f.value.beseExpectedResults&&JSON.stringify(f.value.beseExpectedResults)||void 0};try{await Ne(D.name==="declarationFinal"?1:2,{projectInfo:o}),V.value=!1,Q.$message.success("\u63D0\u4EA4\u6210\u529F"),F.go(-1)}catch{V.value=!1}}else console.log(g)})},ie=async()=>{var e,g;const n=await De(D.query.id);f.value={isCompletedLogCollection:n.data.isCompletedLogCollection,finalAcceptanceMaterials:n.data.finalAcceptanceMaterials?JSON.parse(n.data.finalAcceptanceMaterials):f.value.finalAcceptanceMaterials,beseExpectedResults:n.data.beseExpectedResults&&JSON.parse(n.data.beseExpectedResults)||n.data.beseExpectedResults&&JSON.parse(n.data.beseExpectedResults)},f.value.finalAcceptanceMaterials=f.value.finalAcceptanceMaterials.map(o=>({...o,data:o.data.map(u=>({...u,isHave:["\u8F6F\u4EF6\u7C7B\u7CFB\u7EDF\u5F00\u53D1\u3001\u90E8\u7F72\u7B49\u5B8C\u6210\u60C5\u51B5\u5BF9\u7167\u8868","\u4FE1\u606F\u5B89\u5168\u7B49\u7EA7\u4FDD\u62A4\u6D4B\u8BC4\u62A5\u544A","\u7528\u6237\u4F7F\u7528\u62A5\u544A","IRS\u5E94\u7528\u8BD5\u8FD0\u884C\u62A5\u544A","\u7EC8\u9A8C\u610F\u89C1"].includes(u.name)?!0:u.isHave,required:!0}))})),(e=n.data.projectApplications)!=null&&e.length&&(n.data.projectApplications.map(o=>o.secrecyGrade).includes(3)||n.data.projectApplications.map(o=>o.secrecyGrade).includes(4)||n.data.projectApplications.map(o=>o.secrecyGrade).includes(5))&&(f.value.finalAcceptanceMaterials=f.value.finalAcceptanceMaterials.map(o=>({...o,data:o.data.map(u=>({...u,isHave:["\u5546\u4E1A\u5BC6\u7801\u5E94\u7528\u8BC4\u4F30\u62A5\u544A"].includes(u.name)?!0:u.isHave,required:["\u5546\u4E1A\u5BC6\u7801\u5E94\u7528\u8BC4\u4F30\u62A5\u544A"].includes(u.name)?!0:u.required}))}))),A.value=((g=n.data.projectApplications)==null?void 0:g.map((o,u)=>({name:o.applicationName||o.relatedExistsApplication,status:"\u8FD0\u884C\u4E2D",finalIrsApps:n.data.finalIrsApps[u]})))||[],r.value=A.value[0]},re=[{label:"\u9879\u76EE\u4E3B\u8981\u5185\u5BB9",prop:"mainContent",key:"mainContent"},{label:"\u4E1A\u52A1\u5BF9\u8C61",prop:"businessObject",key:"businessObject"},{label:"\u64CD\u4F5C",slot:"action",key:"action"}],R=Ve({visible:!1,data:void 0}),L=_(),P=(n,e)=>{R.data=n,R.visible=!0,L.value=e},ue=n=>{L.value===void 0?f.value.beseExpectedResults.push(n):f.value.beseExpectedResults[L.value]=n},pe=n=>{f.value.beseExpectedResults.splice(n,1)};return Ie(async()=>{await ke(),ie()}),(n,e)=>{const g=c("el-tab-pane"),o=c("el-descriptions-item"),u=c("el-descriptions"),y=c("el-col"),J=c("el-row"),de=c("el-tabs"),S=c("el-collapse-item"),z=c("el-radio"),fe=c("el-radio-group"),I=c("el-form-item"),G=c("table-list"),k=c("el-button"),ce=c("el-switch"),me=c("el-upload"),be=c("el-input"),_e=c("el-collapse"),ve=c("el-form");return v(),U(N,null,[p("div",He,[s(ve,{ref_key:"formRef",ref:q,model:f.value,"label-position":"right","label-width":"90px","label-suffix":":","scroll-to-error":"",class:"table-form"},{default:a(()=>[s(_e,{modelValue:j,"onUpdate:modelValue":e[3]||(e[3]=C=>j=C)},{default:a(()=>{var C;return[(C=A.value)!=null&&C.length?(v(),w(S,{key:0,name:"1",class:"mb-16"},{title:a(()=>e[7]||(e[7]=[p("div",{class:"collapse-title"},"\u5173\u8054\u7684\u5E94\u7528\u4FE1\u606F",-1)])),default:a(()=>[p("div",Me,[s(de,{modelValue:E.value,"onUpdate:modelValue":e[0]||(e[0]=l=>E.value=l),"tab-position":"left",onTabChange:oe},{default:a(()=>[(v(!0),U(N,null,W(A.value,(l,t)=>(v(),w(g,{key:t,label:l.name,name:t},null,8,["label","name"]))),128)),p("div",he,[p("p",Ee,[e[8]||(e[8]=i("\u5E94\u7528\u72B6\u6001\uFF1A")),p("span",Le,d(r.value.status),1)]),e[23]||(e[23]=p("p",{class:"font-semibold text-14"},"\u8D44\u6E90\u6982\u89C8",-1)),p("div",Se,[s(J,{class:"mb-16"},{default:a(()=>[s(y,{span:12},{default:a(()=>[e[10]||(e[10]=p("p",{class:"mb-8"},"\u4E91\u8D44\u6E90\u4F7F\u7528\u60C5\u51B5",-1)),s(u,{column:1,border:""},{default:a(()=>[s(o,{label:"\u4E91\u8D44\u6E90\u5B9E\u4F8B\u4F7F\u7528\u6570"},{default:a(()=>{var l,t;return[i(d((t=(l=r.value)==null?void 0:l.finalIrsApps)==null?void 0:t.cloudResourceUsage.instancesNum),1)]}),_:1}),s(o,{label:"\u4E91\u8D44\u6E90\u4EA7\u54C1"},{default:a(()=>e[9]||(e[9]=[i(" \u6682\u65E0 ")])),_:1}),s(o,{label:"\u4E91\u8D44\u6E90\u5229\u7528\u7387"},{default:a(()=>{var l,t;return[i(d((t=(l=r.value)==null?void 0:l.finalIrsApps)==null?void 0:t.cloudResourceUsage.utilizationRate),1)]}),_:1})]),_:1})]),_:1})]),_:1}),s(J,{gutter:24},{default:a(()=>[s(y,{span:12,class:"mb-16"},{default:a(()=>[e[11]||(e[11]=p("p",{class:"mb-8"},"\u6570\u636E\u4F7F\u7528\u60C5\u51B5",-1)),s(u,{column:1,border:""},{default:a(()=>[s(o,{label:"\u6570\u636E\u5171\u4EAB\u7533\u8BF7\u91CF"},{default:a(()=>{var l,t;return[i(d((t=(l=r.value)==null?void 0:l.finalIrsApps)==null?void 0:t.dataUsage.sharedApplicationVolume),1)]}),_:1}),s(o,{label:"\u6570\u636E\u5171\u4EAB\u4F7F\u7528\u91CF"},{default:a(()=>{var l,t;return[i(d((t=(l=r.value)==null?void 0:l.finalIrsApps)==null?void 0:t.dataUsage.sharedUsage),1)]}),_:1})]),_:1})]),_:1}),s(y,{span:12,class:"mb-16"},{default:a(()=>[e[12]||(e[12]=p("p",{class:"mb-31"},null,-1)),s(u,{column:1,border:""},{default:a(()=>[s(o,{label:"\u534F\u540C\u63A5\u53E3\u8C03\u7528\u91CF"},{default:a(()=>{var l,t;return[i(d((t=(l=r.value)==null?void 0:l.finalIrsApps)==null?void 0:t.dataUsage.collaborativeInterfaceCallVolume),1)]}),_:1}),s(o,{label:"\u6570\u636E\u5171\u4EAB\u8C03\u7528\u91CF"},{default:a(()=>{var l,t;return[i(d((t=(l=r.value)==null?void 0:l.finalIrsApps)==null?void 0:t.dataUsage.sharedInterfaceCallVolume),1)]}),_:1})]),_:1})]),_:1}),s(y,{span:12,class:"mb-16"},{default:a(()=>[e[13]||(e[13]=p("p",{class:"mb-8"},"\u7EC4\u4EF6\u4F7F\u7528\u60C5\u51B5",-1)),s(u,{column:1,border:""},{default:a(()=>[s(o,{label:"\u7EC4\u4EF6\u7533\u8BF7\u91CF"},{default:a(()=>{var l,t;return[i(d((t=(l=r.value)==null?void 0:l.finalIrsApps)==null?void 0:t.componentUsage.applicationVolume),1)]}),_:1}),s(o,{label:"\u7EC4\u4EF6\u8C03\u7528\u91CF"},{default:a(()=>{var l,t;return[i(d((t=(l=r.value)==null?void 0:l.finalIrsApps)==null?void 0:t.componentUsage.callVolume),1)]}),_:1}),s(o,{label:"\u7EC4\u4EF6\u4F7F\u7528\u91CF"},{default:a(()=>{var l,t;return[i(d((t=(l=r.value)==null?void 0:l.finalIrsApps)==null?void 0:t.componentUsage.useVolume),1)]}),_:1})]),_:1})]),_:1}),s(y,{span:12,class:"mb-16"},{default:a(()=>[e[16]||(e[16]=p("p",{class:"mb-31"},null,-1)),s(u,{column:1,border:""},{default:a(()=>[s(o,{label:"\u7EDF\u4E00\u7EC4\u4EF6\u8C03\u7528\u91CF"},{default:a(()=>{var l,t;return[i(d((t=(l=r.value)==null?void 0:l.finalIrsApps)==null?void 0:t.componentUsage.unifyCallolVolume),1)]}),_:1}),s(o,{label:"\u4F7F\u7528\u7EC4\u4EF6"},{default:a(()=>e[14]||(e[14]=[i(" \u6682\u65E0 ")])),_:1}),s(o,{label:"\u4F7F\u7528\u5F3A\u5236\u7C7B\u7EC4\u4EF6"},{default:a(()=>e[15]||(e[15]=[i(" \u6682\u65E0 ")])),_:1})]),_:1})]),_:1}),s(y,{span:12,class:"mb-16"},{default:a(()=>[e[18]||(e[18]=p("p",{class:"mb-8"},"\u4EA7\u751F\u6570\u636E",-1)),s(u,{column:1,border:""},{default:a(()=>[s(o,{label:"\u4EA7\u751F\u6570\u636E\u91CF"},{default:a(()=>{var l,t;return[i(d((t=(l=r.value)==null?void 0:l.finalIrsApps)==null?void 0:t.generateData.volume),1)]}),_:1}),s(o,{label:"\u4EA7\u751F\u6570\u636E\u5171\u4EAB\u4F7F\u7528\u91CF"},{default:a(()=>{var l,t;return[i(d((t=(l=r.value)==null?void 0:l.finalIrsApps)==null?void 0:t.generateData.sharedUseVolume),1)]}),_:1}),s(o,{label:"\u6570\u636E\u63A5\u53E3\u88AB\u8C03\u7528\u91CF"},{default:a(()=>{var l,t;return[i(d((t=(l=r.value)==null?void 0:l.finalIrsApps)==null?void 0:t.generateData.dataInterfaceCallsVolume),1)]}),_:1}),s(o,{label:"\u4F7F\u7528\u6279\u91CF\u6570\u636E"},{default:a(()=>e[17]||(e[17]=[i(" \u6682\u65E0 ")])),_:1})]),_:1})]),_:1}),s(y,{span:12,class:"mb-16"},{default:a(()=>[e[20]||(e[20]=p("p",{class:"mb-31"},null,-1)),s(u,{column:1,border:""},{default:a(()=>[s(o,{label:"\u4EA7\u751F\u6570\u636E\u5171\u4EAB\u7533\u8BF7\u91CF"},{default:a(()=>{var l,t;return[i(d((t=(l=r.value)==null?void 0:l.finalIrsApps)==null?void 0:t.generateData.sharedApplicationVolume),1)]}),_:1}),s(o,{label:"\u4EA7\u751F\u6570\u636E\u5BA1\u6279\u901A\u8FC7\u7387"},{default:a(()=>{var l,t;return[i(d((t=(l=r.value)==null?void 0:l.finalIrsApps)==null?void 0:t.generateData.approvalPassRate),1)]}),_:1}),s(o,{label:"\u534F\u540C\u63A5\u53E3\u88AB\u8C03\u7528\u91CF"},{default:a(()=>{var l,t;return[i(d((t=(l=r.value)==null?void 0:l.finalIrsApps)==null?void 0:t.generateData.collaborativeInterfaceCallVolume),1)]}),_:1}),s(o,{label:"\u4F7F\u7528\u5171\u4EAB\u63A5\u53E3"},{default:a(()=>e[19]||(e[19]=[i(" \u6682\u65E0 ")])),_:1})]),_:1})]),_:1}),s(y,{span:12},{default:a(()=>[e[21]||(e[21]=p("p",{class:"mb-8"},"\u8BD5\u8FD0\u884C\u62A5\u544A",-1)),s(u,{column:1,border:""},{default:a(()=>[s(o,{label:"\u8BD5\u8FD0\u884C\u62A5\u544A\u901A\u8FC7\u7387"},{default:a(()=>{var l,t;return[i(d((t=(l=r.value)==null?void 0:l.finalIrsApps)==null?void 0:t.operationReport.passRate),1)]}),_:1})]),_:1})]),_:1})]),_:1})]),O("",!0)])]),_:1},8,["modelValue"])])]),_:1})):O("",!0),s(S,{name:"7",class:"mb-16"},{title:a(()=>e[24]||(e[24]=[p("div",{class:"collapse-title"},"\u5B9E\u65BD\u4FE1\u606F",-1)])),default:a(()=>[s(I,{label:"\u662F\u5426\u5B8C\u6210\u65E5\u5FD7\u6570\u636E\u5F52\u96C6","label-width":"170",prop:"isCompletedLogCollection",rules:[{required:!0,message:"\u8BF7\u9009\u62E9"}]},{default:a(()=>[s(fe,{modelValue:f.value.isCompletedLogCollection,"onUpdate:modelValue":e[1]||(e[1]=l=>f.value.isCompletedLogCollection=l)},{default:a(()=>[s(z,{label:!0},{default:a(()=>e[25]||(e[25]=[i("\u662F")])),_:1}),s(z,{label:!1},{default:a(()=>e[26]||(e[26]=[i("\u5426")])),_:1})]),_:1},8,["modelValue"])]),_:1}),s(I,{label:"\u5B9E\u9645\u6210\u6548\u6307\u6807","label-width":"170",prop:"beseExpectedResults",rules:[{required:!0,message:"\u8BF7\u9009\u62E9"}]},{default:a(()=>[s(G,{pagination:!1,style:{width:"100%"},column:re,data:f.value.beseExpectedResults,"empty-temp":!1},{action:a(({scope:l})=>[p("a",{onClick:t=>P(l.row,l.$index)},"\u7F16\u8F91",8,Oe),p("a",{class:"text-danger",onClick:t=>pe(l.$index)},"\u5220\u9664",8,Be)]),_:1},8,["data"]),p("p",Fe,[s(k,{type:"primary",class:"w-full",plain:"",icon:"Plus",onClick:e[2]||(e[2]=()=>P())},{default:a(()=>e[27]||(e[27]=[i("\u6DFB\u52A0")])),_:1})])]),_:1})]),_:1}),(v(!0),U(N,null,W(f.value.finalAcceptanceMaterials,(l,t)=>(v(),w(S,{key:t,name:t+2+"",class:"mb-16"},{title:a(()=>[p("div",je,d(l.title),1)]),default:a(()=>[s(G,{ref_for:!0,ref:"tableListRef",column:X,data:l.data,pagination:!1,"empty-temp":!1},{isHave:a(({scope:m})=>[s(ce,{modelValue:m.row.isHave,"onUpdate:modelValue":b=>m.row.isHave=b,disabled:m.row.required},null,8,["modelValue","onUpdate:modelValue","disabled"])]),files:a(({scope:m})=>[m.$index>=0?(v(),U(N,{key:0},[m.row.isHave?(v(),w(I,{key:0,prop:`finalAcceptanceMaterials[${t}].data[${m.$index}].files`,rules:[{required:!0,message:"\u8BF7\u4E0A\u4F20"}],"label-width":"0",style:{"margin-bottom":"0"},class:"uploadFormItem"},{default:a(()=>[s(me,{"file-list":m.row.files,"onUpdate:fileList":b=>m.row.files=b,class:"w-full table-upload",action:x(K),"on-success":b=>x(ge)(b,m.row.files),"before-upload":b=>x(ye)(b,{types:x(T)}),accept:x(T).map(b=>`.${b}`).join(","),"on-preview":x(Ce)},{default:a(()=>[s(k,{type:"primary",plain:"",size:"small"},{default:a(()=>e[28]||(e[28]=[i("\u9009\u62E9\u6587\u4EF6")])),_:1})]),_:2},1032,["file-list","onUpdate:fileList","action","on-success","before-upload","accept","on-preview"])]),_:2},1032,["prop"])):(v(),w(I,{key:1,prop:`finalAcceptanceMaterials[${t}].data[${m.$index}].reason`,rules:[{required:!0,message:"\u8BF7\u8F93\u5165"}],"label-width":"0",style:{"margin-bottom":"0"}},{default:a(()=>[s(be,{modelValue:m.row.reason,"onUpdate:modelValue":b=>m.row.reason=b,placeholder:"\u8BF7\u586B\u5199\u7F3A\u5C11\u8BE5\u6750\u6599\u7684\u539F\u56E0",maxlength:"50"},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1032,["prop"]))],64)):O("",!0)]),_:2},1032,["data"])]),_:2},1032,["name"]))),128))]}),_:1})]),_:1},8,["model"]),p("div",qe,[s(k,{onClick:e[4]||(e[4]=C=>x(F).go(-1))},{default:a(()=>e[29]||(e[29]=[i(" \u8FD4\u56DE ")])),_:1}),s(k,{type:"primary",loading:V.value,onClick:e[5]||(e[5]=C=>ne(q.value))},{default:a(()=>e[30]||(e[30]=[i(" \u63D0\u4EA4 ")])),_:1},8,["loading"])])]),s($e,{visible:R.visible,data:R.data,onSetContent:ue,onClose:e[6]||(e[6]=C=>R.visible=!1)},null,8,["visible","data"])],64)}}});export{Xe as default};