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 line
14KB

  1. import{h as ge,f as ye,b as G,c as Ce}from"./uploadAction-3962500e.js";import{E as xe,x as Ae,y as Re,r as _,a as we,o as Ve,C as Ie,b as c,c as v,d as U,e as p,f as s,h as a,L as w,F as N,H as W,i,t as d,j as O,u as x,k as ke,s as Ue}from"./index-dd5fae99.js";import{i as F}from"./index-b861e656.js";import{s as Ne}from"./finalInspectionDeclare-e797bcb5.js";import{p as De}from"./projectStore-30136ff6.js";import $e from"./projectContentDialog-4e6a46f0.js";const Ee={class:"uploadInitfinalAcceptanceMaterials footerPage"},He={class:"pb-24"},Me={class:"pl-24"},he={class:"font-semibold text-14 mb-16"},Le={class:"text-primary"},Se={class:"p-16"},Oe=["onClick"],Fe=["onClick"],je={class:"text-right w-full mt-8"},Be={class:"collapse-title"},qe={class:"footer"},Pe=ke({name:"declarationFinal"}),Xe=Object.assign(Pe,{setup(Je){const K=xe.dictStore.uploadUrl,D=Ae(),{proxy:Q}=Ue(),j=Re(),B=["1","2","3","4","5","6","7"],q=_(),f=_({finalAcceptanceMaterials:[{title:"验收材料",data:[{name:"用户使用报告",isHave:!0,files:[],reason:""},{name:"IRS应用试运行报告",isHave:!0,files:[],reason:""},{name:"信息安全等级保护测试报告",isHave:!0,files:[],reason:""},{name:"项目总结报告",isHave:!0,files:[],reason:""},{name:"建设核查表",isHave:!0,files:[],reason:""},{name:"其他附件",isHave:!0,files:[],reason:""}]}]}),X=[{label:"序号",type:"index",width:"60"},{label:"材料名称",key:"name",prop:"name"},{label:"是否有材料",key:"isHave",slot:"isHave",width:100},{label:"附件/说明(支持扩展名:.doc .docx .pdf)",key:"files",slot:"files"}],A=_([{name:"应用1",status:"运行中",memoryRate:11,cpuRate:33,cpRate:44},{name:"应用2",status:"运行中",memoryRate:68,cpuRate:43,cpRate:30}]),r=_({});let $,E,H;const Y=_(),Z=_(),ee=_(),M=(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=()=>{$||($=F(Y.value));const n=M(r.value.memoryRate,"#5ADE92","近三个月内存平均使用率");$.setOption(n)},le=()=>{E||(E=F(Z.value));const n=M(r.value.cpuRate,"#0967FD","近三个月CPU平均使用率");E.setOption(n)},te=()=>{H||(H=F(ee.value));const n=M(r.value.cpRate,"#ffae00","近三个月磁盘平均使用率");H.setOption(n)},se=()=>{ae(),le(),te()},h=_(0),oe=n=>{h.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("提交成功"),j.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:["软件类系统开发、部署等完成情况对照表","信息安全等级保护测评报告","用户使用报告","IRS应用试运行报告","终验意见"].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:["商业密码应用评估报告"].includes(u.name)?!0:u.isHave,required:["商业密码应用评估报告"].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:"运行中",finalIrsApps:n.data.finalIrsApps[u]})))||[],r.value=A.value[0]},re=[{label:"项目主要内容",prop:"mainContent",key:"mainContent"},{label:"业务对象",prop:"businessObject",key:"businessObject"},{label:"操作",slot:"action",key:"action"}],R=we({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 Ve(async()=>{await Ie(),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"),T=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",Ee,[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:B,"onUpdate:modelValue":e[3]||(e[3]=C=>B=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"},"关联的应用信息",-1)])),default:a(()=>[p("div",He,[s(de,{modelValue:h.value,"onUpdate:modelValue":e[0]||(e[0]=l=>h.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",Me,[p("p",he,[e[8]||(e[8]=i("应用状态:")),p("span",Le,d(r.value.status),1)]),e[23]||(e[23]=p("p",{class:"font-semibold text-14"},"资源概览",-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"},"云资源使用情况",-1)),s(u,{column:1,border:""},{default:a(()=>[s(o,{label:"云资源实例使用数"},{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:"云资源产品"},{default:a(()=>e[9]||(e[9]=[i(" 暂无 ")])),_:1}),s(o,{label:"云资源利用率"},{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"},"数据使用情况",-1)),s(u,{column:1,border:""},{default:a(()=>[s(o,{label:"数据共享申请量"},{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:"数据共享使用量"},{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:"协同接口调用量"},{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:"数据共享调用量"},{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"},"组件使用情况",-1)),s(u,{column:1,border:""},{default:a(()=>[s(o,{label:"组件申请量"},{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:"组件调用量"},{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:"组件使用量"},{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:"统一组件调用量"},{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:"使用组件"},{default:a(()=>e[14]||(e[14]=[i(" 暂无 ")])),_:1}),s(o,{label:"使用强制类组件"},{default:a(()=>e[15]||(e[15]=[i(" 暂无 ")])),_:1})]),_:1})]),_:1}),s(y,{span:12,class:"mb-16"},{default:a(()=>[e[18]||(e[18]=p("p",{class:"mb-8"},"产生数据",-1)),s(u,{column:1,border:""},{default:a(()=>[s(o,{label:"产生数据量"},{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:"产生数据共享使用量"},{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:"数据接口被调用量"},{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:"使用批量数据"},{default:a(()=>e[17]||(e[17]=[i(" 暂无 ")])),_: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:"产生数据共享申请量"},{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:"产生数据审批通过率"},{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:"协同接口被调用量"},{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:"使用共享接口"},{default:a(()=>e[19]||(e[19]=[i(" 暂无 ")])),_:1})]),_:1})]),_:1}),s(y,{span:12},{default:a(()=>[e[21]||(e[21]=p("p",{class:"mb-8"},"试运行报告",-1)),s(u,{column:1,border:""},{default:a(()=>[s(o,{label:"试运行报告通过率"},{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"},"实施信息",-1)])),default:a(()=>[s(I,{label:"是否完成日志数据归集","label-width":"170",prop:"isCompletedLogCollection",rules:[{required:!0,message:"请选择"}]},{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("是")])),_:1}),s(z,{label:!1},{default:a(()=>e[26]||(e[26]=[i("否")])),_:1})]),_:1},8,["modelValue"])]),_:1}),s(I,{label:"实际成效指标","label-width":"170",prop:"beseExpectedResults",rules:[{required:!0,message:"请选择"}]},{default:a(()=>[s(T,{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)},"编辑",8,Oe),p("a",{class:"text-danger",onClick:t=>pe(l.$index)},"删除",8,Fe)]),_:1},8,["data"]),p("p",je,[s(k,{type:"primary",class:"w-full",plain:"",icon:"Plus",onClick:e[2]||(e[2]=()=>P())},{default:a(()=>e[27]||(e[27]=[i("添加")])),_: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",Be,d(l.title),1)]),default:a(()=>[s(T,{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:"请上传"}],"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(G)}),accept:x(G).map(b=>`.${b}`).join(","),"on-preview":x(Ce)},{default:a(()=>[s(k,{type:"primary",plain:"",size:"small"},{default:a(()=>e[28]||(e[28]=[i("选择文件")])),_: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:"请输入"}],"label-width":"0",style:{"margin-bottom":"0"}},{default:a(()=>[s(be,{modelValue:m.row.reason,"onUpdate:modelValue":b=>m.row.reason=b,placeholder:"请填写缺少该材料的原因",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(j).go(-1))},{default:a(()=>e[29]||(e[29]=[i(" 返回 ")])),_:1}),s(k,{type:"primary",loading:V.value,onClick:e[5]||(e[5]=C=>ne(q.value))},{default:a(()=>e[30]||(e[30]=[i(" 提交 ")])),_: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};