|
|
"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[95125,72114,2755,7182],{22596:function(e,n,l){l.d(n,{Z:function(){return o}});var t=l(1565),i=l(59301),r={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M872 474H286.9l350.2-304c5.6-4.9 2.2-14-5.2-14h-88.5c-3.9 0-7.6 1.4-10.5 3.9L155 487.8a31.96 31.96 0 000 48.3L535.1 866c1.5 1.3 3.3 2 5.2 2h91.5c7.4 0 10.8-9.2 5.2-14L286.9 550H872c4.4 0 8-3.6 8-8v-60c0-4.4-3.6-8-8-8z"}}]},name:"arrow-left",theme:"outlined"},s=l(68475),a=function(e,n){return i.createElement(s.Z,(0,t.Z)({},e,{ref:n,icon:r}))};var o=i.forwardRef(a)},89136:function(e,n,l){l.d(n,{Z:function(){return o}});var t=l(1565),i=l(59301),r={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M942.2 486.2C847.4 286.5 704.1 186 512 186c-192.2 0-335.4 100.5-430.2 300.3a60.3 60.3 0 000 51.5C176.6 737.5 319.9 838 512 838c192.2 0 335.4-100.5 430.2-300.3 7.7-16.2 7.7-35 0-51.5zM512 766c-161.3 0-279.4-81.8-362.7-254C232.6 339.8 350.7 258 512 258c161.3 0 279.4 81.8 362.7 254C791.5 684.2 673.4 766 512 766zm-4-430c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm0 288c-61.9 0-112-50.1-112-112s50.1-112 112-112 112 50.1 112 112-50.1 112-112 112z"}}]},name:"eye",theme:"outlined"},s=l(68475),a=function(e,n){return i.createElement(s.Z,(0,t.Z)({},e,{ref:n,icon:r}))};var o=i.forwardRef(a)},14806:function(e,n,l){l.r(n),l.d(n,{default:function(){return N}});var t=l(82242),i=l.n(t),r=l(7557),s=l.n(r),a=l(41498),o=l.n(a),c=l(79800),d=l.n(c),u=l(59301),p=l(7880),m=l(95237),x=l(66104),h=l(43604),v=l(99313),f=l(5112),j=l(14491),g=l(43418),b=l(22596),y={flex_box_center:"flex_box_center___Qx5by",flex_space_between:"flex_space_between___Jovvb",flex_box_vertical_center:"flex_box_vertical_center___ZgKxt",flex_box_center_end:"flex_box_center_end___rLoZQ",flex_box_column:"flex_box_column___H7gvw",title:"title___mKlZQ",link:"link____MbLK",wrap:"wrap___M54Mm",info:"info___LS1sD",name:"name___XFTyf",box:"box___MY5TN",tab:"tab___Pts7W",group:"group___KTR8B",modal:"modal___wynb6",head:"head___rpYjK",des:"des___PNfp8",sub:"sub___LF5wd",tags:"tags___tdrDl"},_=l(51136),C=l(99232),O=l.n(C),k=l(27065),w=l(37712),N=(0,p.connect)((function(e){return{exercise:e.exercise,user:e.user}}))((function(e){e.exercise;var n,l,t,r=e.user,a=(e.dispatch,null===(n=window.location.pathname)||void 0===n?void 0:n.includes("exercise")),c=a?"exercise":"shixun_homework",C=(0,p.useParams)(),N=r.userInfo,E=(0,u.useState)({}),S=d()(E,2),I=S[0],Z=S[1],P=(0,u.useState)(),z=d()(P,2),L=z[0],M=z[1],T=(0,u.useState)(0),$=d()(T,2),B=$[0],D=$[1],R=(0,u.useState)([]),A=d()(R,2),F=A[0],X=A[1],H=(0,u.useState)(!0),Q=d()(H,2),q=Q[0],K=Q[1],U=(0,u.useState)(!1),W=d()(U,2),G=W[0],V=W[1],J=(0,u.useState)(0),Y=d()(J,2),ee=Y[0],ne=Y[1],le=(0,u.useState)({type:"2",degree:0,page:1,limit:10,id:C.studentId}),te=d()(le,2),ie=te[0],re=te[1],se=(null==I?void 0:I.analysis_data)||{},ae=se.bug,oe=se.vulnerability,ce=se.codeSmall;(0,u.useEffect)((function(){de(),ue(ie)}),[]);var de=function(){var e=o()(s()().mark((function e(){var n;return s()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,_.ZP)("/api/code_analyses_detail/analyse_detail.json",{method:"get",params:{id:C.studentId}});case 2:0===(n=e.sent).status&&Z(n.data);case 4:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),ue=function(){var e=o()(s()().mark((function e(n){var l,t;return s()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return K(!0),e.next=3,(0,_.ZP)("/api/code_analyses_detail/analyse_detail_list.json",{method:"get",params:n});case 3:0===(l=e.sent).status&&(X(l.data.recordList),ne(null===(t=l.data)||void 0===t?void 0:t.recordSum)),K(!1);case 6:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}(),pe={"阻断":(0,w.jsx)("i",{style:{color:"#D4333F"},className:"iconfont icon-zuduan font14"}),"严重":(0,w.jsx)("i",{style:{color:"#D4333F"},className:"iconfont icon-yanzhong font14"}),"主要":(0,w.jsx)("i",{style:{color:"#D4333F"},className:"iconfont icon-zhuyao font14"}),"次要":(0,w.jsx)("i",{style:{color:"#B0D513"},className:"iconfont icon-ciyao font14"}),"提示":(0,w.jsx)("i",{style:{color:"#4B9FD5"},className:"iconfont icon-tishi10 font14"}),Bug:(0,w.jsx)("i",{className:"iconfont icon-bug"}),"漏洞":(0,w.jsx)("i",{className:"iconfont icon-loudong1"}),"代码规范":(0,w.jsx)("i",{className:"iconfont icon-yiwei"})},me=[{title:"序号",dataIndex:"name",align:"left",width:80,render:function(e,n,l){return ie.limit*(ie.page-1)+l+1}},{title:"".concat("2"===ie.type?"Bug":"3"===ie.type?"漏洞":"规范异常","名称"),align:"left",ellipsis:!0,dataIndex:"name",render:function(e,n){return(0,w.jsx)("a",{target:"_blank",href:"/classrooms/".concat(C.coursesId,"/").concat(c,"/").concat(C.exerciseId,"/analysis/").concat(C.studentId,"/code?name=").concat(null==I?void 0:I.user_name,"&rule_id=").concat(n.ruleId,"&uuid=").concat(n.uuid,"&issueId=").concat(n.issueId,"&language=").concat(n.language,"&rowNumber=").concat(n.rowNumber),className:y.link,children:e})}},{title:"文件路径",align:"left",ellipsis:!0,dataIndex:"filePath"},{title:"严重程度",align:"left",width:90,dataIndex:"level",render:function(e){return(0,w.jsxs)("span",{children:[pe[e],(0,w.jsx)("span",{className:"ml5",children:e})]})}},{title:"操作",width:154,align:"left",dataIndex:"action",render:function(e,n){return(0,w.jsxs)(m.Z,{justify:"space-between",align:"middle",children:[(0,w.jsx)("span",{onClick:function(){return xe(n)},className:"current c-light-primary",children:"问题分析"}),(0,w.jsx)("a",{target:"_blank",href:"/classrooms/".concat(C.coursesId,"/").concat(c,"/").concat(C.exerciseId,"/analysis/").concat(C.studentId,"/code?name=").concat(null==I?void 0:I.user_name,"&rule_id=").concat(n.ruleId,"&uuid=").concat(n.uuid,"&issueId=").concat(n.issueId,"&language=").concat(n.language,"&rowNumber=").concat(n.rowNumber),className:"current c-light-primary",children:"代码详情"})]})}}],xe=function(){var e=o()(s()().mark((function e(n){var l;return s()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,_.ZP)("/api/code_analyses_detail/problem_analysis.json",{method:"get",params:{rule_id:n.ruleId}});case 2:0===(l=e.sent).status&&(M(i()(i()({},l.data),{},{level:n.level,type:"2"===ie.type?"Bug":"3"===ie.type?"漏洞":"代码规范"})),D(32));case 4:case"end":return e.stop()}}),e)})));return function(n){return e.apply(this,arguments)}}();return(0,w.jsxs)("section",{className:"edu-container",children:[(0,w.jsxs)("section",{className:"animated fadeIn",children:[(0,w.jsx)("aside",{className:"mt10",children:N&&(0,w.jsxs)(x.Z,{separator:">",children:[(0,w.jsx)(x.Z.Item,{children:(0,w.jsx)(p.Link,{to:"/classrooms/".concat(C.coursesId,"/").concat(c),children:null==N||null===(l=N.course)||void 0===l?void 0:l.course_name})}),(0,w.jsx)(x.Z.Item,{children:(0,w.jsxs)(p.Link,{to:"/classrooms/".concat(C.coursesId,"/").concat(c),children:[a?"考试":"实训","列表"]})}),(0,w.jsx)(x.Z.Item,{children:(0,w.jsxs)(p.Link,{to:"/classrooms/".concat(C.coursesId,"/").concat(c,"/").concat(null==C?void 0:C.exerciseId,"/detail"),children:[a?"试卷":"作业","详情"]})}),(0,w.jsx)(x.Z.Item,{children:null==I?void 0:I.user_name})]})}),(0,w.jsx)("aside",{className:[y.title,"mt20"].join(" "),children:(0,w.jsx)(m.Z,{style:{width:"100%"},children:(0,w.jsxs)(h.Z,{flex:"1",style:{lineHeight:"24px"},children:[(0,w.jsx)(p.Link,{to:"/classrooms/".concat(C.coursesId,"/").concat(c,"/").concat(null==C?void 0:C.exerciseId,"/detail"),children:(0,w.jsx)(b.Z,{className:"font16 c-black"})}),(0,w.jsx)("strong",{className:"font20 ml5",children:null==I?void 0:I.name}),(0,w.jsx)("span",{className:"iconfont icon-a-wenhaobeifen2",onClick:function(){V(!0)},style:{fontWeight:800,color:"#0152d9",float:"right",cursor:"pointer"},children:"规则说明"})]})})})]}),(0,w.jsxs)("section",{className:y.wrap,children:[(0,w.jsxs)("div",{className:y.info,children:[(0,w.jsx)("img",{src:"".concat(k.Z.IMG_SERVER,"/images/").concat(null==I?void 0:I.avatar),alt:""}),(0,w.jsxs)("ul",{style:{marginLeft:30},children:[(0,w.jsx)("li",{className:y.name,children:null==I?void 0:I.user_name}),(0,w.jsxs)("li",{children:[(0,w.jsx)("span",{children:"学号:"}),null==I?void 0:I.student_number]}),(0,w.jsxs)("li",{children:[(0,w.jsx)("span",{children:"代码行数:"}),null==I?void 0:I.total_row_number]})]}),(0,w.jsxs)("ul",{style:{marginTop:65},children:[(0,w.jsxs)("li",{children:[(0,w.jsx)("span",{children:"分班:"}),null==I?void 0:I.group_course_name]}),(0,w.jsxs)("li",{children:[(0,w.jsx)("span",{children:"复杂代码:"}),null==I?void 0:I.complexity]})]}),(0,w.jsxs)("ol",{children:[(0,w.jsx)("li",{children:"质量评分:"}),(0,w.jsx)("li",{children:null==I?void 0:I.quality_score})]})]}),(0,w.jsxs)("div",{className:y.box,children:[(0,w.jsxs)("ul",{children:[(0,w.jsxs)("li",{children:[(0,w.jsx)("p",{className:"mb20",children:null==ae?void 0:ae.total}),(0,w.jsx)("div",{children:"缺陷"})]}),(0,w.jsxs)("li",{children:[(0,w.jsxs)("div",{children:["等级:",(0,w.jsx)("b",{children:null==ae?void 0:ae.levelStr})]}),(0,w.jsxs)("div",{children:[(0,w.jsx)("span",{children:"阻断"}),(0,w.jsx)("div",{children:(0,w.jsx)("aside",{style:{background:"#A73E38",width:0===(null==ae?void 0:ae.blocker)?0:"".concat((null==ae?void 0:ae.blocker)/(null==ae?void 0:ae.total)*100,"%")}})}),(0,w.jsx)("span",{children:null==ae?void 0:ae.blocker})]}),(0,w.jsxs)("div",{children:[(0,w.jsx)("span",{children:"严重"}),(0,w.jsx)("div",{children:(0,w.jsx)("aside",{style:{background:"#DB544D",width:0===(null==ae?void 0:ae.critical)?0:"".concat((null==ae?void 0:ae.critical)/(null==ae?void 0:ae.total)*100,"%")}})}),(0,w.jsx)("span",{children:null==ae?void 0:ae.critical})]}),(0,w.jsxs)("div",{children:[(0,w.jsx)("span",{children:"主要"}),(0,w.jsx)("div",{children:(0,w.jsx)("aside",{style:{background:"#F7AB3E",width:0===(null==ae?void 0:ae.major)?0:"".concat((null==ae?void 0:ae.major)/(null==ae?void 0:ae.total)*100,"%")}})}),(0,w.jsx)("span",{children:null==ae?void 0:ae.major})]}),(0,w.jsxs)("div",{children:[(0,w.jsx)("span",{children:"次要"}),(0,w.jsx)("div",{children:(0,w.jsx)("aside",{style:{background:"#E7DF37",width:0===(null==ae?void 0:ae.minor)?0:"".concat((null==ae?void 0:ae.minor)/(null==ae?void 0:ae.total)*100,"%")}})}),(0,w.jsx)("span",{children:null==ae?void 0:ae.minor})]})]})]}),(0,w.jsxs)("ul",{children:[(0,w.jsxs)("li",{children:[(0,w.jsx)("p",{className:"mb20",children:null==oe?void 0:oe.total}),(0,w.jsx)("div",{children:"漏洞"})]}),(0,w.jsxs)("li",{children:[(0,w.jsxs)("div",{children:["等级:",(0,w.jsx)("b",{children:null==oe?void 0:oe.levelStr})]}),(0,w.jsxs)("div",{children:[(0,w.jsx)("span",{children:"阻断"}),(0,w.jsx)("div",{children:(0,w.jsx)("aside",{style:{background:"#A73E38",width:0===(null==oe?void 0:oe.blocker)?0:"".concat((null==oe?void 0:oe.blocker)/(null==oe?void 0:oe.total)*100,"%")}})}),(0,w.jsx)("span",{children:null==oe?void 0:oe.blocker})]}),(0,w.jsxs)("div",{children:[(0,w.jsx)("span",{children:"严重"}),(0,w.jsx)("div",{children:(0,w.jsx)("aside",{style:{background:"#DB544D",width:0===(null==oe?void 0:oe.critical)?0:"".concat((null==oe?void 0:oe.critical)/(null==oe?void 0:oe.total)*100,"%")}})}),(0,w.jsx)("span",{children:null==oe?void 0:oe.critical})]}),(0,w.jsxs)("div",{children:[(0,w.jsx)("span",{children:"主要"}),(0,w.jsx)("div",{children:(0,w.jsx)("aside",{style:{background:"#F7AB3E",width:0===(null==oe?void 0:oe.major)?0:"".concat((null==oe?void 0:oe.major)/(null==oe?void 0:oe.total)*100,"%")}})}),(0,w.jsx)("span",{children:null==oe?void 0:oe.major})]}),(0,w.jsxs)("div",{children:[(0,w.jsx)("span",{children:"次要"}),(0,w.jsx)("div",{children:(0,w.jsx)("aside",{style:{background:"#E7DF37",width:0===(null==oe?void 0:oe.minor)?0:"".concat((null==oe?void 0:oe.minor)/(null==oe?void 0:oe.total)*100,"%")}})}),(0,w.jsx)("span",{children:null==oe?void 0:oe.minor})]})]})]}),(0,w.jsxs)("ul",{children:[(0,w.jsxs)("li",{children:[(0,w.jsx)("p",{className:"mb20",children:null==ce?void 0:ce.total}),(0,w.jsx)("div",{children:"代码规范"})]}),(0,w.jsxs)("li",{children:[(0,w.jsxs)("div",{children:["等级:",(0,w.jsx)("b",{children:null==ce?void 0:ce.levelStr})]}),(0,w.jsxs)("div",{children:[(0,w.jsx)("span",{children:"阻断"}),(0,w.jsx)("div",{children:(0,w.jsx)("aside",{style:{background:"#A73E38",width:0===(null==ce?void 0:ce.blocker)?0:"".concat((null==ce?void 0:ce.blocker)/(null==ce?void 0:ce.total)*100,"%")}})}),(0,w.jsx)("span",{children:null==ce?void 0:ce.blocker})]}),(0,w.jsxs)("div",{children:[(0,w.jsx)("span",{children:"严重"}),(0,w.jsx)("div",{children:(0,w.jsx)("aside",{style:{background:"#DB544D",width:0===(null==ce?void 0:ce.critical)?0:"".concat((null==ce?void 0:ce.critical)/(null==ce?void 0:ce.total)*100,"%")}})}),(0,w.jsx)("span",{children:null==ce?void 0:ce.critical})]}),(0,w.jsxs)("div",{children:[(0,w.jsx)("span",{children:"主要"}),(0,w.jsx)("div",{children:(0,w.jsx)("aside",{style:{background:"#F7AB3E",width:0===(null==ce?void 0:ce.major)?0:"".concat((null==ce?void 0:ce.major)/(null==ce?void 0:ce.total)*100,"%")}})}),(0,w.jsx)("span",{children:null==ce?void 0:ce.major})]}),(0,w.jsxs)("div",{children:[(0,w.jsx)("span",{children:"次要"}),(0,w.jsx)("div",{children:(0,w.jsx)("aside",{style:{background:"#E7DF37",width:0===(null==ce?void 0:ce.minor)?0:"".concat((null==ce?void 0:ce.minor)/(null==ce?void 0:ce.total)*100,"%")}})}),(0,w.jsx)("span",{children:null==ce?void 0:ce.minor})]})]})]})]}),(0,w.jsxs)(v.Z,{className:y.tab,activeKey:ie.type,onChange:function(e){ie.page=1,ie.type=e,re(i()({},ie)),ue(ie)},children:[(0,w.jsx)(v.Z.TabPane,{tab:"Bug (".concat((null==ae?void 0:ae.total)||0,")")},"2"),(0,w.jsx)(v.Z.TabPane,{tab:"漏洞 (".concat((null==oe?void 0:oe.total)||0,")")},"3"),(0,w.jsx)(v.Z.TabPane,{tab:"代码规范 (".concat((null==ce?void 0:ce.total)||0,")")},"1")]}),(0,w.jsxs)("div",{className:y.group,children:[(0,w.jsx)("span",{className:"mr5",children:"严重程度:"}),(0,w.jsxs)(f.ZP.Group,{value:ie.degree,onChange:function(e){ie.page=1,ie.degree=e.target.value,re(i()({},ie)),ue(ie)},children:[(0,w.jsx)(f.ZP,{value:0,children:"全部"}),(0,w.jsx)(f.ZP,{value:1,children:"阻断"}),(0,w.jsx)(f.ZP,{value:2,children:"严重"}),(0,w.jsx)(f.ZP,{value:3,children:"主要"}),(0,w.jsx)(f.ZP,{value:4,children:"次要"})]})]}),(0,w.jsx)(j.Z,{style:{padding:"30px 30px 0 30px"},dataSource:F,columns:me,onChange:function(e){ie.page=null==e?void 0:e.current,ie.limit=null==e?void 0:e.pageSize,re(i()({},ie)),ue(ie)},loading:q,pagination:{pageSize:ie.limit,total:ee,current:ie.page,showQuickJumper:!0,hideOnSinglePage:!0,position:["bottomCenter"],showTotal:function(e){return(0,w.jsxs)("span",{className:"mr10",children:["共",(0,w.jsx)("span",{className:"c-orange",children:e}),"条数据"]})}}})]}),(0,w.jsxs)("div",{className:y.modal,style:{height:"".concat(B,"vh")},children:[(0,w.jsxs)("div",{className:y.head,children:[(0,w.jsx)("span",{children:"问题分析"}),(0,w.jsx)("i",{className:"icon-zuixiaohua iconfont mt10",onClick:function(){return D(32)}}),(0,w.jsx)("i",{style:{margin:"0 18px"},className:"icon-fangda iconfont",onClick:function(){return D(80)}}),(0,w.jsx)("i",{className:"icon-guanbi7 iconfont",onClick:function(){return D(0)}})]}),(0,w.jsxs)("div",{className:y.des,children:[(0,w.jsx)("div",{className:y.sub,children:null==L?void 0:L.title}),(0,w.jsxs)("div",{className:y.tags,children:[(0,w.jsxs)("span",{children:[pe[null==L?void 0:L.type]," ",null==L?void 0:L.type]}),(0,w.jsxs)("span",{children:[pe[null==L?void 0:L.level]," ",null==L?void 0:L.level]}),(0,w.jsxs)("span",{children:[(0,w.jsx)("i",{className:"iconfont icon-biaoqian4 mr5"}),null==L||null===(t=L.tags)||void 0===t?void 0:t.join(",")]}),(0,w.jsxs)("span",{children:["生效时间",O()(null==L?void 0:L.createTime).format("ll")]}),(0,w.jsx)("span",{children:null==L?void 0:L.language}),(0,w.jsxs)("span",{children:["常量/任务:",null==L?void 0:L.constantIssue]})]}),(0,w.jsx)("div",{className:y.example,dangerouslySetInnerHTML:{__html:(null==L?void 0:L.example)||""}})]})]}),(0,w.jsxs)(g.Z,{open:G,title:"规则说明",width:800,footer:null,onCancel:function(){V(!1)},children:[(0,w.jsx)("p",{children:"一、等级规则"}),(0,w.jsx)("p",{style:{marginLeft:"10px"},children:"1. 缺陷等级"}),(0,w.jsx)("p",{style:{marginLeft:"10px"},children:(0,w.jsx)(j.Z,{dataSource:[{live:"A",gz:"0个错误",ld:"0个漏洞",gf:"0 - 5%"},{live:"B",gz:"至少1个次要错误",ld:"至少1个次要漏洞",gf:"6% - 10%"},{live:"C",gz:"至少1个主要错误",ld:"至少1个主要漏洞",gf:"11% - 20%"},{live:"D",gz:"至少1个严重错误",ld:"至少1个严重漏洞",gf:"21% - 50%"},{live:"E",gz:"至少1个阻断错误",ld:"至少1个阻断漏洞",gf:"超过50%"}],columns:[{title:"等级",dataIndex:"live"},{title:"缺陷评估规则",dataIndex:"gz"},{title:"漏洞评估规则",dataIndex:"ld"},{title:"代码规范评估规则",dataIndex:"gf"}],pagination:!1})}),(0,w.jsx)("p",{style:{marginLeft:"10px"},children:"注:代码规范评估规则中数值来源为计算技术债务时间占开发所有代码所需要的时间的比例(Technical Debt Ratio)"}),(0,w.jsx)("p",{style:{marginLeft:"20px"},children:"Technical Debt Ratio = 技术债务时间 / 开发时间"}),(0,w.jsx)("p",{style:{marginLeft:"20px"},children:"技术债务时间为修复所有问题所需要的时间。"}),(0,w.jsx)("p",{children:"二、复杂度规则"}),(0,w.jsx)("p",{style:{marginLeft:"10px"},children:"根据代码路径数计算的数值,每当一个函数的控制流分叉时,复杂度计数器就会自增一。"}),(0,w.jsx)("p",{style:{marginLeft:"10px"},children:"每个程序语言的关键字对应的复杂度数据不同,但每个函数的最小复杂度为1。(特定语言的详细数据略)"}),(0,w.jsx)("p",{children:"三、代码质量分规则"}),(0,w.jsx)("p",{style:{marginLeft:"10px"},children:"代码质量分 = 0.5*缺陷分数 + 0.3*漏洞分数 + 0.2*代码规范性分数"}),(0,w.jsx)("p",{style:{marginLeft:"10px"},children:"其中:"}),(0,w.jsx)("p",{style:{marginLeft:"10px"},children:"缺陷/漏洞/代码规范性分数计算规则为:100 - 100 *((100*阻断数 + 5*严重数 + 3*主要数 + 1*次数)/ 代码行数)"}),(0,w.jsx)("p",{style:{marginLeft:"10px"},children:"注:分数为空的代表不支持的文件格式。"})]})]})}))},66104:function(e,n,l){l.d(n,{Z:function(){return I}});var t=l(92310),i=l.n(t),r=l(55401),s=l(87147),a=l(59301),o=l(92343),c=l(36355),d=l(43501),u=l(91857);const p=e=>{let{children:n}=e;const{getPrefixCls:l}=a.useContext(c.E_),t=l("breadcrumb");return a.createElement("li",{className:`${t}-separator`,"aria-hidden":"true"},""===n?n:n||"/")};p.__ANT_BREADCRUMB_SEPARATOR=!0;var m=p,x=function(e,n){var l={};for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&n.indexOf(t)<0&&(l[t]=e[t]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(t=Object.getOwnPropertySymbols(e);i<t.length;i++)n.indexOf(t[i])<0&&Object.prototype.propertyIsEnumerable.call(e,t[i])&&(l[t[i]]=e[t[i]])}return l};function h(e,n,l,t){if(null==l)return null;const{className:r,onClick:o}=n,c=x(n,["className","onClick"]),d=Object.assign(Object.assign({},(0,s.Z)(c,{data:!0,aria:!0})),{onClick:o});return void 0!==t?a.createElement("a",Object.assign({},d,{className:i()(`${e}-link`,r),href:t}),l):a.createElement("span",Object.assign({},d,{className:i()(`${e}-link`,r)}),l)}function v(e,n){return(l,t,i,r,s)=>{if(n)return n(l,t,i,r);const a=function(e,n){if(void 0===e.title||null===e.title)return null;const l=Object.keys(n).join("|");return"object"==typeof e.title?e.title:String(e.title).replace(new RegExp(`:(${l})`,"g"),((e,l)=>n[l]||e))}(l,t);return h(e,l,a,s)}}var f=function(e,n){var l={};for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&n.indexOf(t)<0&&(l[t]=e[t]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(t=Object.getOwnPropertySymbols(e);i<t.length;i++)n.indexOf(t[i])<0&&Object.prototype.propertyIsEnumerable.call(e,t[i])&&(l[t[i]]=e[t[i]])}return l};const j=e=>{const{prefixCls:n,separator:l="/",children:t,menu:i,overlay:r,dropdownProps:s,href:o}=e;const c=(e=>{if(i||r){const l=Object.assign({},s);if(i){const e=i||{},{items:n}=e,t=f(e,["items"]);l.menu=Object.assign(Object.assign({},t),{items:null==n?void 0:n.map(((e,n)=>{var{key:l,title:t,label:i,path:r}=e,s=f(e,["key","title","label","path"]);let c=null!=i?i:t;return r&&(c=a.createElement("a",{href:`${o}${r}`},c)),Object.assign(Object.assign({},s),{key:null!=l?l:n,label:c})}))})}else r&&(l.overlay=r);return a.createElement(u.Z,Object.assign({placement:"bottom"},l),a.createElement("span",{className:`${n}-overlay-link`},e,a.createElement(d.Z,null)))}return e})(t);return null!=c?a.createElement(a.Fragment,null,a.createElement("li",null,c),l&&a.createElement(m,null,l)):null},g=e=>{const{prefixCls:n,children:l,href:t}=e,i=f(e,["prefixCls","children","href"]),{getPrefixCls:r}=a.useContext(c.E_),s=r("breadcrumb",n);return a.createElement(j,Object.assign({},i,{prefixCls:s}),h(s,i,l,t))};g.__ANT_BREADCRUMB_ITEM=!0;var b=g,y=l(17313),_=l(83116),C=l(37613);const O=e=>{const{componentCls:n,iconCls:l}=e;return{[n]:Object.assign(Object.assign({},(0,y.Wf)(e)),{color:e.itemColor,fontSize:e.fontSize,[l]:{fontSize:e.iconFontSize},ol:{display:"flex",flexWrap:"wrap",margin:0,padding:0,listStyle:"none"},a:Object.assign({color:e.linkColor,transition:`color ${e.motionDurationMid}`,padding:`0 ${e.paddingXXS}px`,borderRadius:e.borderRadiusSM,height:e.lineHeight*e.fontSize,display:"inline-block",marginInline:-e.marginXXS,"&:hover":{color:e.linkHoverColor,backgroundColor:e.colorBgTextHover}},(0,y.Qy)(e)),"li:last-child":{color:e.lastItemColor},[`${n}-separator`]:{marginInline:e.separatorMargin,color:e.separatorColor},[`${n}-link`]:{[`\n > ${l} + span,\n > ${l} + a\n `]:{marginInlineStart:e.marginXXS}},[`${n}-overlay-link`]:{borderRadius:e.borderRadiusSM,height:e.lineHeight*e.fontSize,display:"inline-block",padding:`0 ${e.paddingXXS}px`,marginInline:-e.marginXXS,[`> ${l}`]:{marginInlineStart:e.marginXXS,fontSize:e.fontSizeIcon},"&:hover":{color:e.linkHoverColor,backgroundColor:e.colorBgTextHover,a:{color:e.linkHoverColor}},a:{"&:hover":{backgroundColor:"transparent"}}},[`&${e.componentCls}-rtl`]:{direction:"rtl"}})}};var k=(0,_.Z)("Breadcrumb",(e=>{const n=(0,C.TS)(e,{});return[O(n)]}),(e=>({itemColor:e.colorTextDescription,lastItemColor:e.colorText,iconFontSize:e.fontSize,linkColor:e.colorTextDescription,linkHoverColor:e.colorText,separatorColor:e.colorTextDescription,separatorMargin:e.marginXS}))),w=function(e,n){var l={};for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&n.indexOf(t)<0&&(l[t]=e[t]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(t=Object.getOwnPropertySymbols(e);i<t.length;i++)n.indexOf(t[i])<0&&Object.prototype.propertyIsEnumerable.call(e,t[i])&&(l[t[i]]=e[t[i]])}return l};function N(e){const{breadcrumbName:n,children:l}=e,t=w(e,["breadcrumbName","children"]),i=Object.assign({title:n},t);return l&&(i.menu={items:l.map((e=>{var{breadcrumbName:n}=e,l=w(e,["breadcrumbName"]);return Object.assign(Object.assign({},l),{title:n})}))}),i}var E=function(e,n){var l={};for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&n.indexOf(t)<0&&(l[t]=e[t]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(t=Object.getOwnPropertySymbols(e);i<t.length;i++)n.indexOf(t[i])<0&&Object.prototype.propertyIsEnumerable.call(e,t[i])&&(l[t[i]]=e[t[i]])}return l};const S=e=>{const{prefixCls:n,separator:l="/",style:t,className:d,rootClassName:u,routes:p,items:x,children:h,itemRender:f,params:g={}}=e,b=E(e,["prefixCls","separator","style","className","rootClassName","routes","items","children","itemRender","params"]),{getPrefixCls:y,direction:_,breadcrumb:C}=a.useContext(c.E_);let O;const w=y("breadcrumb",n),[S,I]=k(w),Z=function(e,n){return(0,a.useMemo)((()=>e||(n?n.map(N):null)),[e,n])}(x,p);const P=v(w,f);if(Z&&Z.length>0){const e=[],n=x||p;O=Z.map(((t,i)=>{const{path:r,key:o,type:c,menu:d,overlay:u,onClick:p,className:x,separator:h,dropdownProps:v}=t,f=((e,n)=>{if(void 0===n)return n;let l=(n||"").replace(/^\//,"");return Object.keys(e).forEach((n=>{l=l.replace(`:${n}`,e[n])})),l})(g,r);void 0!==f&&e.push(f);const b=null!=o?o:i;if("separator"===c)return a.createElement(m,{key:b},h);const y={},_=i===Z.length-1;d?y.menu=d:u&&(y.overlay=u);let{href:C}=t;return e.length&&void 0!==f&&(C=`#/${e.join("/")}`),a.createElement(j,Object.assign({key:b},y,(0,s.Z)(t,{data:!0,aria:!0}),{className:x,dropdownProps:v,href:C,separator:_?"":l,onClick:p,prefixCls:w}),P(t,g,n,e,C))}))}else if(h){const e=(0,r.Z)(h).length;O=(0,r.Z)(h).map(((n,t)=>{if(!n)return n;const i=t===e-1;return(0,o.Tm)(n,{separator:i?"":l,key:t})}))}const z=i()(w,null==C?void 0:C.className,{[`${w}-rtl`]:"rtl"===_},d,u,I),L=Object.assign(Object.assign({},null==C?void 0:C.style),t);return S(a.createElement("nav",Object.assign({className:z,style:L},b),a.createElement("ol",null,O)))};S.Item=b,S.Separator=m;var I=S},98135:function(e,n,l){l.d(n,{Z:function(){return z}});var t=l(92310),i=l.n(t),r=l(59301),s=l(36355),a=l(32441),o=l(9937);var c=e=>{const{getPrefixCls:n,direction:l}=(0,r.useContext)(s.E_),{prefixCls:t,className:c}=e,d=n("input-group",t),u=n("input"),[p,m]=(0,o.ZP)(u),x=i()(d,{[`${d}-lg`]:"large"===e.size,[`${d}-sm`]:"small"===e.size,[`${d}-compact`]:e.compact,[`${d}-rtl`]:"rtl"===l},m,c),h=(0,r.useContext)(a.aM),v=(0,r.useMemo)((()=>Object.assign(Object.assign({},h),{isFormItemInput:!1})),[h]);return p(r.createElement("span",{className:x,style:e.style,onMouseEnter:e.onMouseEnter,onMouseLeave:e.onMouseLeave,onFocus:e.onFocus,onBlur:e.onBlur},r.createElement(a.aM.Provider,{value:v},e.children)))},d=l(9432),u=l(1565),p={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M942.2 486.2Q889.47 375.11 816.7 305l-50.88 50.88C807.31 395.53 843.45 447.4 874.7 512 791.5 684.2 673.4 766 512 766q-72.67 0-133.87-22.38L323 798.75Q408 838 512 838q288.3 0 430.2-300.3a60.29 60.29 0 000-51.5zm-63.57-320.64L836 122.88a8 8 0 00-11.32 0L715.31 232.2Q624.86 186 512 186q-288.3 0-430.2 300.3a60.3 60.3 0 000 51.5q56.69 119.4 136.5 191.41L112.48 835a8 8 0 000 11.31L155.17 889a8 8 0 0011.31 0l712.15-712.12a8 8 0 000-11.32zM149.3 512C232.6 339.8 350.7 258 512 258c54.54 0 104.13 9.36 149.12 28.39l-70.3 70.3a176 176 0 00-238.13 238.13l-83.42 83.42C223.1 637.49 183.3 582.28 149.3 512zm246.7 0a112.11 112.11 0 01146.2-106.69L401.31 546.2A112 112 0 01396 512z"}},{tag:"path",attrs:{d:"M508 624c-3.46 0-6.87-.16-10.25-.47l-52.82 52.82a176.09 176.09 0 00227.42-227.42l-52.82 52.82c.31 3.38.47 6.79.47 10.25a111.94 111.94 0 01-112 112z"}}]},name:"eye-invisible",theme:"outlined"},m=l(68475),x=function(e,n){return r.createElement(m.Z,(0,u.Z)({},e,{ref:n,icon:p}))};var h=r.forwardRef(x),v=l(89136),f=l(70521),j=l(16863),g=l(59412),b=function(e,n){var l={};for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&n.indexOf(t)<0&&(l[t]=e[t]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(t=Object.getOwnPropertySymbols(e);i<t.length;i++)n.indexOf(t[i])<0&&Object.prototype.propertyIsEnumerable.call(e,t[i])&&(l[t[i]]=e[t[i]])}return l};const y=e=>e?r.createElement(v.Z,null):r.createElement(h,null),_={click:"onClick",hover:"onMouseOver"};var C=r.forwardRef(((e,n)=>{const{visibilityToggle:l=!0}=e,t="object"==typeof l&&void 0!==l.visible,[a,o]=(0,r.useState)((()=>!!t&&l.visible)),c=(0,r.useRef)(null);r.useEffect((()=>{t&&o(l.visible)}),[t,l]);const u=(0,g.Z)(c),p=()=>{const{disabled:n}=e;n||(a&&u(),o((e=>{var n;const t=!e;return"object"==typeof l&&(null===(n=l.onVisibleChange)||void 0===n||n.call(l,t)),t})))},{className:m,prefixCls:x,inputPrefixCls:h,size:v}=e,C=b(e,["className","prefixCls","inputPrefixCls","size"]),{getPrefixCls:O}=r.useContext(s.E_),k=O("input",h),w=O("input-password",x),N=l&&(n=>{const{action:l="click",iconRender:t=y}=e,i=_[l]||"",s=t(a),o={[i]:p,className:`${n}-icon`,key:"passwordIcon",onMouseDown:e=>{e.preventDefault()},onMouseUp:e=>{e.preventDefault()}};return r.cloneElement(r.isValidElement(s)?s:r.createElement("span",null,s),o)})(w),E=i()(w,m,{[`${w}-${v}`]:!!v}),S=Object.assign(Object.assign({},(0,f.Z)(C,["suffix","iconRender","visibilityToggle"])),{type:a?"text":"password",className:E,prefixCls:k,suffix:N});return v&&(S.size=v),r.createElement(d.Z,Object.assign({ref:(0,j.sQ)(n,c)},S))})),O=l(11013),k=l(92343),w=l(3113),N=l(19716),E=l(33234),S=function(e,n){var l={};for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&n.indexOf(t)<0&&(l[t]=e[t]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(t=Object.getOwnPropertySymbols(e);i<t.length;i++)n.indexOf(t[i])<0&&Object.prototype.propertyIsEnumerable.call(e,t[i])&&(l[t[i]]=e[t[i]])}return l};var I=r.forwardRef(((e,n)=>{const{prefixCls:l,inputPrefixCls:t,className:a,size:o,suffix:c,enterButton:u=!1,addonAfter:p,loading:m,disabled:x,onSearch:h,onChange:v,onCompositionStart:f,onCompositionEnd:g}=e,b=S(e,["prefixCls","inputPrefixCls","className","size","suffix","enterButton","addonAfter","loading","disabled","onSearch","onChange","onCompositionStart","onCompositionEnd"]),{getPrefixCls:y,direction:_}=r.useContext(s.E_),C=r.useRef(!1),I=y("input-search",l),Z=y("input",t),{compactSize:P}=(0,E.ri)(I,_),z=(0,N.Z)((e=>{var n;return null!==(n=null!=o?o:P)&&void 0!==n?n:e})),L=r.useRef(null),M=e=>{var n;document.activeElement===(null===(n=L.current)||void 0===n?void 0:n.input)&&e.preventDefault()},T=e=>{var n,l;h&&h(null===(l=null===(n=L.current)||void 0===n?void 0:n.input)||void 0===l?void 0:l.value,e,{source:"input"})},$="boolean"==typeof u?r.createElement(O.Z,null):null,B=`${I}-button`;let D;const R=u||{},A=R.type&&!0===R.type.__ANT_BUTTON;D=A||"button"===R.type?(0,k.Tm)(R,Object.assign({onMouseDown:M,onClick:e=>{var n,l;null===(l=null===(n=null==R?void 0:R.props)||void 0===n?void 0:n.onClick)||void 0===l||l.call(n,e),T(e)},key:"enterButton"},A?{className:B,size:z}:{})):r.createElement(w.ZP,{className:B,type:u?"primary":void 0,size:z,disabled:x,key:"enterButton",onMouseDown:M,onClick:T,loading:m,icon:$},u),p&&(D=[D,(0,k.Tm)(p,{key:"addonAfter"})]);const F=i()(I,{[`${I}-rtl`]:"rtl"===_,[`${I}-${z}`]:!!z,[`${I}-with-button`]:!!u},a);return r.createElement(d.Z,Object.assign({ref:(0,j.sQ)(L,n),onPressEnter:e=>{C.current||m||T(e)}},b,{size:z,onCompositionStart:e=>{C.current=!0,null==f||f(e)},onCompositionEnd:e=>{C.current=!1,null==g||g(e)},prefixCls:Z,addonAfter:D,suffix:c,onChange:e=>{e&&e.target&&"click"===e.type&&h&&h(e.target.value,e,{source:"clear"}),v&&v(e)},className:F,disabled:x}))})),Z=l(1643);const P=d.Z;P.Group=c,P.Search=I,P.TextArea=Z.Z,P.Password=C;var z=P}}]); |