diff --git a/app/controllers/quality_analysis_controller.rb b/app/controllers/quality_analysis_controller.rb index 1d23c28c2..db5fac9c7 100644 --- a/app/controllers/quality_analysis_controller.rb +++ b/app/controllers/quality_analysis_controller.rb @@ -83,6 +83,9 @@ class QualityAnalysisController < ApplicationController end end + # sonar 缓冲,取数据 + sleep(5) + # 获取sonar output结果 console_build = @client.job.get_console_output("#{job_name}", build_num = 0, start = 0, mode = 'text')["output"] logger.info("@current_build_status is ==> #{@current_build_status}") diff --git a/app/views/quality_analysis/_show.html.erb b/app/views/quality_analysis/_show.html.erb index 3a2b17720..347f33cb5 100644 --- a/app/views/quality_analysis/_show.html.erb +++ b/app/views/quality_analysis/_show.html.erb @@ -78,27 +78,27 @@ <%= @ha["blocker_violations"].nil? ? 0 : @ha["blocker_violations"] %> - %;"> + %;">
严重 <%= @ha["critical_violations"].nil? ? 0 : @ha["critical_violations"] %> - %;">
+ %;">
主要 <%= @ha["major_violations"].nil? ? 0 : @ha["major_violations"] %> - %;">
+ %;">
次要 <%= @ha["minor_violations"].nil? ? 0 : @ha["minor_violations"] %> - %;">
+ %;">
信息 <%= @ha["info_violations"].nil? ? 0 : @ha["info_violations"] %> - %;">
+ %;">