All Downloads are FREE. Search and download functionalities are using the official Maven repository.

scripts.views.sonar-technicaldept-view-min.js Maven / Gradle / Ivy

AJS.$.namespace("AJS.sonar.views.technicaldept");AJS.sonar.views.technicaldept.VIEW_NAME="technicaldept";AJS.sonar.views.technicaldept.METRICS="technical_debt_repart,technical_debt_days,technical_debt_ratio,technical_debt";AJS.sonar.views.technicaldept.generateView=function(D,F,G,A){AJS.sonar.text.load(D);var B=AJS.sonar.views.createViewContainer();var C=AJS.sonar.views.createColumn(true);C.append(AJS.sonar.views.createHeader("sonar.views.technicaldept"));AJS.sonar.views.createMeasureRow(F.host,AJS.sonar.views.technicaldept.VIEW_NAME,G.id,AJS.sonar.utils.getMeasureFromResource(G,"technical_debt_ratio"),AJS.sonar.utils.getMetricFromMetricsArray(A,"technical_debt_ratio"),true).appendTo(C);AJS.sonar.views.createMeasureRow(F.host,AJS.sonar.views.technicaldept.VIEW_NAME,G.id,AJS.sonar.utils.getMeasureFromResource(G,"technical_debt"),AJS.sonar.utils.getMetricFromMetricsArray(A,"technical_debt"),false).prepend(AJS.$("").text("$ ")).appendTo(C);AJS.sonar.views.createMeasureRow(F.host,AJS.sonar.views.technicaldept.VIEW_NAME,G.id,AJS.sonar.utils.getMeasureFromResource(G,"technical_debt_days"),AJS.sonar.utils.getMetricFromMetricsArray(A,"technical_debt_days"),false).appendTo(C);C.appendTo(B);var E=AJS.sonar.views.createColumn(false);AJS.sonar.views.technicaldept.createTechnicaldeptChart(F.host,AJS.sonar.utils.getMeasureFromResource(G,"technical_debt_repart")).appendTo(E);E.appendTo(B);AJS.sonar.views.addViewFooter(B,F.host);return B};AJS.sonar.views.technicaldept.createTechnicaldeptChart=function(A,C){var D="";var B="";AJS.$(C.data.split(";")).each(function(F,G){if(D.length>0){D+="|";B+=","}var E=G.split("=");D+=E[0];B+=E[1]});return AJS.$("").attr({width:248,height:65,src:A+"/gchart?chs=248x65&chd=t:"+B+"&cht=p&chl="+D})};




© 2015 - 2024 Weber Informatics LLC | Privacy Policy