diff options
author | Stas Vilchik <vilchiks@gmail.com> | 2015-12-02 10:19:58 +0100 |
---|---|---|
committer | Stas Vilchik <vilchiks@gmail.com> | 2015-12-02 10:19:58 +0100 |
commit | b7555709cf2e71c76749b5d7780c98c1ac7d1d5d (patch) | |
tree | ae16c9bb1887698638bec3f1448d959ce94b0a86 /server | |
parent | 6d7a38d5a0c33e2fe816f6cf085871b194616fa7 (diff) | |
download | sonarqube-b7555709cf2e71c76749b5d7780c98c1ac7d1d5d.tar.gz sonarqube-b7555709cf2e71c76749b5d7780c98c1ac7d1d5d.zip |
SONAR-7078 Open drilldown on "Technical Debt on New code" when failed condition is "Technical Debt Ratio on New Code"
Diffstat (limited to 'server')
-rw-r--r-- | server/sonar-web/src/main/js/components/shared/drilldown-link.js | 4 | ||||
-rw-r--r-- | server/sonar-web/src/main/webapp/WEB-INF/app/helpers/application_helper.rb | 6 |
2 files changed, 8 insertions, 2 deletions
diff --git a/server/sonar-web/src/main/js/components/shared/drilldown-link.js b/server/sonar-web/src/main/js/components/shared/drilldown-link.js index 7623209e8a5..6431b846100 100644 --- a/server/sonar-web/src/main/js/components/shared/drilldown-link.js +++ b/server/sonar-web/src/main/js/components/shared/drilldown-link.js @@ -49,7 +49,9 @@ const HIGHLIGHT_MAPPING = { 'new_overall_coverage': 'new_overall_uncovered_lines', 'new_overall_line_coverage': 'new_overall_uncovered_lines', - 'new_overall_branch_coverage': 'new_overall_uncovered_conditions' + 'new_overall_branch_coverage': 'new_overall_uncovered_conditions', + + 'new_sqale_debt_ratio': 'new_technical_debt' }; diff --git a/server/sonar-web/src/main/webapp/WEB-INF/app/helpers/application_helper.rb b/server/sonar-web/src/main/webapp/WEB-INF/app/helpers/application_helper.rb index f0c82f2c13b..da06341aa5a 100644 --- a/server/sonar-web/src/main/webapp/WEB-INF/app/helpers/application_helper.rb +++ b/server/sonar-web/src/main/webapp/WEB-INF/app/helpers/application_helper.rb @@ -235,7 +235,11 @@ module ApplicationHelper url += 'resolved=false' end else - url = url_for(options.merge({:controller => 'drilldown', :action => 'measures', :metric => metric_key, :id => options[:resource]||@resource.id})) + if metric_key == 'new_sqale_debt_ratio' + url = url_for(options.merge({:controller => 'drilldown', :action => 'measures', :metric => 'new_technical_debt', :highlight => 'new_sqale_debt_ratio', :id => options[:resource]||@resource.id})) + else + url = url_for(options.merge({:controller => 'drilldown', :action => 'measures', :metric => metric_key, :id => options[:resource]||@resource.id})) + end end url |