- Added i18n to core tabs of the resource viewer (coverage, source, violations)tags/2.10
@@ -25,8 +25,10 @@ view.size.paragraphs_suffix=\ paragraphs | |||
add_verb=Add | |||
and=And | |||
assign=Assign | |||
author=Author | |||
ascending=Ascending | |||
blocker=Blocker | |||
build_date=Build date | |||
cancel=Cancel | |||
change_verb=Change | |||
@@ -34,6 +36,7 @@ class=Class | |||
classes=Classes | |||
color=Color | |||
criteria=Criteria | |||
critical=Critical | |||
date=Date | |||
days=Days | |||
delete=Delete | |||
@@ -44,13 +47,16 @@ display=Display | |||
edit=Edit | |||
file=File | |||
files=Files | |||
info=Info | |||
key=Key | |||
language=Language | |||
library=Library | |||
links=Links | |||
login=Login | |||
major=Major | |||
max=Max | |||
min=Min | |||
minor=Minor | |||
name=Name | |||
none=None | |||
operations=Operations | |||
@@ -66,8 +72,16 @@ search_verb=Search | |||
shared=Shared | |||
view=View | |||
views=Views | |||
raw=Raw | |||
reassign=Reassign | |||
reopen=Reopen | |||
reopened=Reopened | |||
resolve=Resolve | |||
result=Result | |||
rule=Rule | |||
review_verb=Review | |||
select_verb=Select | |||
severity=Severity | |||
size=Size | |||
sub_project=Sub-project | |||
sub_projects=Sub-projects | |||
@@ -80,6 +94,7 @@ unit_test=Unit test | |||
unit_tests=Unit tests | |||
value=Value | |||
variarion=Variation | |||
violations=Violations | |||
version=Version | |||
@@ -89,18 +104,31 @@ version=Version | |||
# | |||
#------------------------------------------------------------------------------ | |||
add_comment=Add comment | |||
added_over_x_days=Added over {0} days | |||
added_since=Added since {0} | |||
added_since_previous_analysis=Added since previous analysis | |||
added_since_previous_analysis_detailed=Added since previous analysis ({0}) | |||
added_since_version=Added since version {0} | |||
alerts_feed=Alerts feed | |||
all_violations=All violations | |||
assigned_to=Assigned to | |||
delta_since_previous_analysis=Δ since previous analysis | |||
delta_over_x_days=Δ over {0} days | |||
delta_since=Δ since {0} | |||
delta_since_version=Δ since version {0} | |||
equals=Equals | |||
false_positive=False-Positive | |||
false_positives_only=False-Positives only | |||
full_source=Full source | |||
greater_or_equals=Greater or equals | |||
greater_than=Greater than | |||
less_or_equals=Less or equals | |||
less_than=Less than | |||
move_left=Move left | |||
move_right=Move right | |||
new_violations=New violations | |||
new_window=New window | |||
no_results=No results | |||
page_size=Page size | |||
remove_column=Remove this column | |||
@@ -137,17 +165,14 @@ sidebar.system=System | |||
#------------------------------------------------------------------------------ | |||
# | |||
# PAGES | |||
# PAGES, sorted alphabetically | |||
# | |||
#------------------------------------------------------------------------------ | |||
backup.page=Backup | |||
clouds.page=Clouds | |||
components.page=Components | |||
components.size=Size | |||
components.color=Color | |||
backup.page=Backup | |||
coverage.page=Coverage | |||
default_dashboards.page=Default dashboards | |||
default_filters.page=Default filters | |||
dependencies.page=Dependencies | |||
@@ -163,13 +188,17 @@ project_settings.page=Settings | |||
quality_profiles.page=Quality profiles | |||
reviews.page=Reviews | |||
settings.page=Settings | |||
source.page=Source | |||
system_info.page=System Info | |||
timemachine.page=Time Machine | |||
user_groups.page=Groups | |||
users.page=Users | |||
violations.page=Violations | |||
violations_drilldown.page=Violations drilldown | |||
system_info.page=System Info | |||
update_center.page=Update Center | |||
org.sonar.plugins.core.hotspots.GwtHotspots.page=Hotspots | |||
org.sonar.plugins.core.duplicationsviewer.DuplicationsViewer.page=Duplications | |||
#------------------------------------------------------------------------------ | |||
@@ -214,6 +243,19 @@ filters.shared_filters=Shared filters | |||
filters.shared_filters_description=These filters are shared by administrators and can be followed without copying them. | |||
#------------------------------------------------------------------------------ | |||
# | |||
# REVIEWS | |||
# | |||
#------------------------------------------------------------------------------ | |||
reviews.do_you_want_to_reopen=Do you want to reopen this review? | |||
reviews.do_you_want_to_resolve=Do you want to resolve this review? | |||
reviews.flag_as_false_positive=Flag as false-positive | |||
reviews.unflag_as_false_positive=Unflag as false-positive | |||
reviews.do_you_want_to_delete_comment=Do you want to delete this comment? | |||
#------------------------------------------------------------------------------ | |||
# | |||
# METRIC DOMAINS |
@@ -46,17 +46,17 @@ module DashboardHelper | |||
if mode | |||
if mode=='days' | |||
label = "Added over %s days" % mode_param | |||
label = message('added_over_x_days', :params => mode_param.to_s) | |||
elsif mode=='version' | |||
label = "Added since version %s" % mode_param | |||
label = message('added_since_version', :params => mode_param.to_s) | |||
elsif mode=='previous_analysis' | |||
if !date.nil? | |||
label = "Added since previous analysis (%s)" % date.strftime("%Y %b. %d") | |||
label = message('added_since_previous_analysis_detailed', :params => date.strftime("%Y %b. %d").to_s) | |||
else | |||
label = "Added since previous analysis" | |||
label = message('added_since_previous_analysis') | |||
end | |||
elsif mode=='date' | |||
label = "Added since #{date.strftime("%Y %b %d")}" | |||
label = message('added_since', :params => date.strftime("%Y %b %d").to_s) | |||
end | |||
if label | |||
selected=(params[:period]==index.to_s ? 'selected' : '') |
@@ -8,7 +8,7 @@ | |||
<td class="sep"> </td> | |||
<% if m=measure('new_line_coverage') %> | |||
<td class="name">Line coverage:</td> | |||
<td class="name"><%= message('metric.line_coverage.name') -%>:</td> | |||
<td class="value"><%= format_variation(m, :period => @period, :style => 'none') -%></td> | |||
<% else %> | |||
<td colspan="2"></td> | |||
@@ -16,7 +16,7 @@ | |||
<td class="sep"> </td> | |||
<% if m=measure('new_branch_coverage') %> | |||
<td class="name">Branch coverage:</td> | |||
<td class="name"><%= message('metric.branch_coverage.name') -%>:</td> | |||
<td class="value"><%= format_variation(m, :period => @period, :style => 'none') -%></td> | |||
<% else %> | |||
<td colspan="2"></td> | |||
@@ -25,7 +25,7 @@ | |||
<tr> | |||
<td class="sep"> </td> | |||
<% if m=measure('new_uncovered_lines') %> | |||
<td class="name">Uncovered lines:</td> | |||
<td class="name"><%= message('metric.uncovered_lines.name') -%>:</td> | |||
<td class="value"><%= format_variation(m, :period => @period, :style => 'none') -%>/<%= format_variation('new_lines_to_cover', :period => @period, :style => 'none') -%></td> | |||
<% else %> | |||
<td colspan="2"></td> | |||
@@ -33,7 +33,7 @@ | |||
<td class="sep"> </td> | |||
<% if m=measure('new_uncovered_conditions') %> | |||
<td class="name">Uncovered conditions: </td> | |||
<td class="name"><%= message('metric.uncovered_conditions.name') -%>: </td> | |||
<td class="value"><%= format_variation(m, :period => @period, :style => 'none') -%>/<%= format_variation('new_conditions_to_cover', :period => @period, :style => 'none') -%></td> | |||
<% else %> | |||
<td colspan="2"></td> | |||
@@ -45,16 +45,16 @@ | |||
<tr> | |||
<td class="big" rowspan="2"><%= format_measure('coverage', :default => '-') -%></td> | |||
<td class="sep"> </td> | |||
<%= render :partial => 'measure', :locals => {:measure => measure('line_coverage'), :title => 'Line coverage'} -%> | |||
<%= render :partial => 'measure', :locals => {:measure => measure('line_coverage'), :title => message('metric.line_coverage.name')} -%> | |||
<td class="sep"> </td> | |||
<%= render :partial => 'measure', :locals => {:measure => measure('branch_coverage'), :title => 'Branch coverage'} -%> | |||
<%= render :partial => 'measure', :locals => {:measure => measure('branch_coverage'), :title => message('metric.branch_coverage.name')} -%> | |||
</tr> | |||
<tr> | |||
<td class="sep"> </td> | |||
<%= render :partial => 'measure', :locals => {:measure => measure('uncovered_lines'), :title => 'Uncovered lines', :ratio => measure('lines_to_cover')} -%> | |||
<%= render :partial => 'measure', :locals => {:measure => measure('uncovered_lines'), :title => message('metric.uncovered_lines.name'), :ratio => measure('lines_to_cover')} -%> | |||
<td class="sep"> </td> | |||
<%= render :partial => 'measure', :locals => {:measure => measure('uncovered_conditions'), :title => 'Uncovered conditions', :ratio => measure('conditions_to_cover')} -%> | |||
<%= render :partial => 'measure', :locals => {:measure => measure('uncovered_conditions'), :title => message('metric.uncovered_conditions.name'), :ratio => measure('conditions_to_cover')} -%> | |||
</tr> | |||
</table> | |||
<% end %> |
@@ -5,31 +5,31 @@ | |||
<table class="metrics"> | |||
<% if m=measure('lines') %> | |||
<tr> | |||
<td class="name">Lines:</td> | |||
<td class="name"><%= message('metric.lines.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
<% if m=measure('ncloc') %> | |||
<tr> | |||
<td class="name">Lines of code:</td> | |||
<td class="name"><%= message('metric.ncloc.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
<% if m=measure('functions') %> | |||
<tr> | |||
<td class="name">Methods:</td> | |||
<td class="name"><%= message('metric.functions.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
<% if m=measure('accessors') %> | |||
<tr> | |||
<td class="name">Accessors:</td> | |||
<td class="name"><%= message('metric.accessors.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
<% if m=measure('paragraphs') %> | |||
<tr> | |||
<td class="name">Paragraphs:</td> | |||
<td class="name"><%= message('metric.paragraphs.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
@@ -39,25 +39,25 @@ | |||
<table class="metrics"> | |||
<% if m=measure('statements') %> | |||
<tr> | |||
<td class="name">Statements:</td> | |||
<td class="name"><%= message('metric.statements.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
<% if m=measure('complexity') %> | |||
<tr> | |||
<td class="name">Complexity:</td> | |||
<td class="name"><%= message('metric.complexity.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
<% if m=measure('function_complexity') %> | |||
<tr> | |||
<td class="name">Complexity/method:</td> | |||
<td class="name"><%= message('metric.function_complexity.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
<% if m=measure('paragraph_complexity') %> | |||
<tr> | |||
<td class="name">Complexity/paragraph:</td> | |||
<td class="name"><%= message('metric.paragraph_complexity.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
@@ -67,25 +67,25 @@ | |||
<table class="metrics"> | |||
<% if m=measure('comment_lines_density') %> | |||
<tr> | |||
<td class="name">Comments:</td> | |||
<td class="name"><%= message('metric.comment_lines_density.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
<% if m=measure('comment_lines') %> | |||
<tr> | |||
<td class="name">Comment lines:</td> | |||
<td class="name"><%= message('metric.comment_lines.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
<% if m=measure('commented_out_code_lines') %> | |||
<tr> | |||
<td class="name">Commented-out LOC:</td> | |||
<td class="name"><%= message('metric.commented_out_code_lines.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
<% if m=measure('comment_blank_lines') %> | |||
<tr> | |||
<td class="name">Blank comments:</td> | |||
<td class="name"><%= message('metric.comment_blank_lines.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
@@ -95,19 +95,19 @@ | |||
<table class="metrics"> | |||
<% if m=measure('public_documented_api_density') %> | |||
<tr> | |||
<td class="name">Public documented API:</td> | |||
<td class="name"><%= message('metric.public_documented_api_density.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
<% if m=measure('public_undocumented_api') %> | |||
<tr> | |||
<td class="name">Public undocumented API:</td> | |||
<td class="name"><%= message('metric.public_undocumented_api.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
<% if m=measure('public_api') %> | |||
<tr> | |||
<td class="name">Public API:</td> | |||
<td class="name"><%= message('metric.public_api.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
@@ -117,25 +117,25 @@ | |||
<table class="metrics"> | |||
<% if m=measure('classes') %> | |||
<tr> | |||
<td class="name">Classes:</td> | |||
<td class="name"><%= message('metric.classes.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
<% if m=measure('noc') %> | |||
<tr> | |||
<td class="name">Number of Children:</td> | |||
<td class="name"><%= message('metric.noc.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
<% if m=measure('dit') %> | |||
<tr> | |||
<td class="name">Depth in Tree:</td> | |||
<td class="name"><%= message('metric.dit.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> | |||
<% if m=measure('rfc') %> | |||
<tr> | |||
<td class="name">Response for Class (RFC):</td> | |||
<td class="name"><%= message('metric.rfc.name') -%>:</td> | |||
<td class="value"><%= format_measure(m) -%></td> | |||
</tr> | |||
<% end %> |
@@ -2,31 +2,31 @@ | |||
<% if @period && measure('new_violations') %> | |||
<table> | |||
<tr> | |||
<td><span class="big"><%= format_variation('new_violations', :default => 0, :period => @period, :style => 'none') -%></span> new violations</td> | |||
<td><span class="big"><%= format_variation('new_violations', :default => 0, :period => @period, :style => 'none') -%></span> <%= message('new_violations').downcase -%></td> | |||
<td class="sep"> </td> | |||
<td><%= image_tag 'priority/BLOCKER.png' -%></td> | |||
<td class="name">Blocker:</td> | |||
<td class="name"><%= message('blocker') -%>:</td> | |||
<td class="value"><%= format_variation('new_blocker_violations', :default => 0, :period => @period, :style => 'none') -%></td> | |||
<td class="sep"> </td> | |||
<td><%= image_tag 'priority/CRITICAL.png' -%></td> | |||
<td class="name">Critical:</td> | |||
<td class="name"><%= message('critical') -%>:</td> | |||
<td class="value"><%= format_variation('new_critical_violations', :default => 0, :period => @period, :style => 'none') -%></td> | |||
<td class="sep"> </td> | |||
<td><%= image_tag 'priority/MAJOR.png' -%></td> | |||
<td class="name">Major:</td> | |||
<td class="name"><%= message('major') -%>:</td> | |||
<td class="value"><%= format_variation('new_major_violations', :default => 0, :period => @period, :style => 'none') -%></td> | |||
<td class="sep"> </td> | |||
<td><%= image_tag 'priority/MINOR.png' -%></td> | |||
<td class="name">Minor:</td> | |||
<td class="name"><%= message('minor') -%>:</td> | |||
<td class="value"><%= format_variation('new_minor_violations', :default => 0, :period => @period, :style => 'none') -%></td> | |||
<td class="sep"> </td> | |||
<td><%= image_tag 'priority/INFO.png' -%></td> | |||
<td class="name">Info:</td> | |||
<td class="name"><%= message('info') -%>:</td> | |||
<td class="value"><%= format_variation('new_info_violations', :default => 0, :period => @period, :style => 'none') -%></td> | |||
</tr> | |||
</table> | |||
@@ -34,31 +34,31 @@ | |||
<% else %> | |||
<table class="sourceHeader"> | |||
<tr> | |||
<td nowrap><span class="big"><%= format_measure('violations', :default => 0) -%></span> violations</td> | |||
<td nowrap><span class="big"><%= format_measure('violations', :default => 0) -%></span> <%= message('violations').downcase -%></td> | |||
<td class="sep"> </td> | |||
<td nowrap><%= image_tag 'priority/BLOCKER.png' -%></td> | |||
<td class="name">Blocker:</td> | |||
<td class="name"><%= message('blocker') -%>:</td> | |||
<td class="value"><%= format_measure('blocker_violations', :default => 0) -%></td> | |||
<td class="sep"> </td> | |||
<td><%= image_tag 'priority/CRITICAL.png' -%></td> | |||
<td class="name">Critical:</td> | |||
<td class="name"><%= message('critical') -%>:</td> | |||
<td class="value"><%= format_measure('critical_violations', :default => 0) -%></td> | |||
<td class="sep"> </td> | |||
<td><%= image_tag 'priority/MAJOR.png' -%></td> | |||
<td class="name">Major:</td> | |||
<td class="name"><%= message('major') -%>:</td> | |||
<td class="value"><%= format_measure('major_violations', :default => 0) -%></td> | |||
<td class="sep"> </td> | |||
<td><%= image_tag 'priority/MINOR.png' -%></td> | |||
<td class="name">Minor:</td> | |||
<td class="name"><%= message('minor') -%>:</td> | |||
<td class="value"><%= format_measure('minor_violations', :default => 0) -%></td> | |||
<td class="sep"> </td> | |||
<td><%= image_tag 'priority/INFO.png' -%></td> | |||
<td class="name">Info:</td> | |||
<td class="name"><%= message('info') -%>:</td> | |||
<td class="value"><%= format_measure('info_violations', :default => 0) -%></td> | |||
</tr> | |||
</table> |
@@ -28,7 +28,7 @@ | |||
if @expandable %> | |||
<td class="<%= 'first' if first -%>"> | |||
<input type="checkbox" value="true" name="expand" id="expand" <%= 'checked' if @expanded -%> onclick="applyOptions()"/> | |||
<label for="expand">Full source</label> | |||
<label for="expand"><%= message('full_source') -%></label> | |||
</td> | |||
<% first=false | |||
end %> | |||
@@ -36,7 +36,7 @@ | |||
<% if @scm_available && !@display_violations && @snapshot.project_snapshot.periods? %> | |||
<td class="<%= 'first' if first -%>"> | |||
<select id="period" name="period" onchange="applyOptions()"> | |||
<option value="">Time changes...</option> | |||
<option value=""><%= message('time_changes') -%>...</option> | |||
<%= period_select_options(@snapshot, 1) -%> | |||
<%= period_select_options(@snapshot, 2) -%> | |||
<%= period_select_options(@snapshot, 3) -%> | |||
@@ -51,7 +51,7 @@ | |||
<% if @display_violations %> | |||
<td class="<%= 'first' if first -%>"> | |||
<select id="period" name="period" onchange="applyOptions()"> | |||
<option value="">Time changes...</option> | |||
<option value=""><%= message('time_changes') -%>...</option> | |||
<%= violation_period_select_options(@snapshot, 1) -%> | |||
<%= violation_period_select_options(@snapshot, 2) -%> | |||
<%= violation_period_select_options(@snapshot, 3) -%> | |||
@@ -67,10 +67,10 @@ | |||
<% if @display_coverage %> | |||
<td class="<%= 'first' if first -%>"> | |||
<select id="coverage_filter" name="coverage_filter" onchange="applyOptions()"> | |||
<option value="lines_to_cover" <%= 'selected' if @coverage_filter=='lines_to_cover' -%>>Lines to cover</option> | |||
<option value="uncovered_lines" <%= 'selected' if @coverage_filter=='uncovered_lines' -%>>Uncovered lines</option> | |||
<option value="conditions_to_cover" <%= 'selected' if @coverage_filter=='conditions_to_cover' -%>>Branches to cover</option> | |||
<option value="uncovered_conditions" <%= 'selected' if @coverage_filter=='uncovered_conditions' -%>>Uncovered branches</option> | |||
<option value="lines_to_cover" <%= 'selected' if @coverage_filter=='lines_to_cover' -%>><%= message('metric.lines_to_cover.name') -%></option> | |||
<option value="uncovered_lines" <%= 'selected' if @coverage_filter=='uncovered_lines' -%>><%= message('metric.uncovered_lines.name') -%></option> | |||
<option value="conditions_to_cover" <%= 'selected' if @coverage_filter=='conditions_to_cover' -%>><%= message('metric.conditions_to_cover.name') -%></option> | |||
<option value="uncovered_conditions" <%= 'selected' if @coverage_filter=='uncovered_conditions' -%>><%= message('metric.uncovered_conditions.name') -%></option> | |||
</select> | |||
</td> | |||
<% first=false |
@@ -32,14 +32,14 @@ | |||
end | |||
%> | |||
<select id="rule" name="rule" onchange="applyOptions()"> | |||
<option value="">All violations</option> | |||
<option value="f-positive" <%= 'selected' if params[:rule]=="f-positive" -%>>False-Positives only</option> | |||
<optgroup label="Severity"> | |||
<option value=""><%= message('all_violations') -%></option> | |||
<option value="f-positive" <%= 'selected' if params[:rule]=="f-positive" -%>><%= message('false_positives_only') -%></option> | |||
<optgroup label="<%= message('severity') -%>"> | |||
<% if blocker_violations | |||
value=(@period ? blocker_violations.variation(@period) : blocker_violations.value) | |||
if value && value>0 | |||
%> | |||
<option value="<%= Sonar::RulePriority::BLOCKER.to_s -%>" <%= 'selected' if params[:rule]==Sonar::RulePriority::BLOCKER.to_s -%>>Blocker (<%= blocker_violations.format_numeric_value(value) -%>)</option> | |||
<option value="<%= Sonar::RulePriority::BLOCKER.to_s -%>" <%= 'selected' if params[:rule]==Sonar::RulePriority::BLOCKER.to_s -%>><%= message('blocker') -%> (<%= blocker_violations.format_numeric_value(value) -%>)</option> | |||
<% end | |||
end %> | |||
@@ -47,7 +47,7 @@ | |||
value=(@period ? critical_violations.variation(@period) : critical_violations.value) | |||
if value && value>0 | |||
%> | |||
<option value="<%= Sonar::RulePriority::CRITICAL.to_s -%>" <%= 'selected' if params[:rule]==Sonar::RulePriority::CRITICAL.to_s -%>>Critical (<%= critical_violations.format_numeric_value(value) -%>)</option> | |||
<option value="<%= Sonar::RulePriority::CRITICAL.to_s -%>" <%= 'selected' if params[:rule]==Sonar::RulePriority::CRITICAL.to_s -%>><%= message('critical') -%> (<%= critical_violations.format_numeric_value(value) -%>)</option> | |||
<% end | |||
end | |||
%> | |||
@@ -56,7 +56,7 @@ | |||
value=(@period ? major_violations.variation(@period) : major_violations.value) | |||
if value && value>0 | |||
%> | |||
<option value="<%= Sonar::RulePriority::MAJOR.to_s -%>" <%= 'selected' if params[:rule]==Sonar::RulePriority::MAJOR.to_s -%>>Major (<%= major_violations.format_numeric_value(value) -%>)</option> | |||
<option value="<%= Sonar::RulePriority::MAJOR.to_s -%>" <%= 'selected' if params[:rule]==Sonar::RulePriority::MAJOR.to_s -%>><%= message('major') -%> (<%= major_violations.format_numeric_value(value) -%>)</option> | |||
<% end | |||
end | |||
%> | |||
@@ -65,7 +65,7 @@ | |||
value=(@period ? minor_violations.variation(@period) : minor_violations.value) | |||
if value && value>0 | |||
%> | |||
<option value="<%= Sonar::RulePriority::MINOR.to_s -%>" <%= 'selected' if params[:rule]==Sonar::RulePriority::MINOR.to_s -%>>Minor (<%= minor_violations.format_numeric_value(value) -%>)</option> | |||
<option value="<%= Sonar::RulePriority::MINOR.to_s -%>" <%= 'selected' if params[:rule]==Sonar::RulePriority::MINOR.to_s -%>><%= message('minor') -%> (<%= minor_violations.format_numeric_value(value) -%>)</option> | |||
<% end | |||
end | |||
%> | |||
@@ -74,7 +74,7 @@ | |||
value=(@period ? info_violations.variation(@period) : info_violations.value) | |||
if value && value>0 | |||
%> | |||
<option value="<%= Sonar::RulePriority::INFO.to_s -%>" <%= 'selected' if params[:rule]==Sonar::RulePriority::INFO.to_s -%>>Info (<%= info_violations.format_numeric_value(value) -%>)</option> | |||
<option value="<%= Sonar::RulePriority::INFO.to_s -%>" <%= 'selected' if params[:rule]==Sonar::RulePriority::INFO.to_s -%>><%= message('info') -%> (<%= info_violations.format_numeric_value(value) -%>)</option> | |||
<% end | |||
end | |||
%> | |||
@@ -82,7 +82,7 @@ | |||
</optgroup> | |||
<optgroup label="Rule"> | |||
<optgroup label="<%= message('rule') -%>"> | |||
<%= options_for_select(rule_options, params[:rule].to_i) -%> | |||
</optgroup> | |||
</select> |
@@ -13,22 +13,22 @@ | |||
first=true | |||
if @snapshot.source | |||
%> | |||
<li class="<%= 'first' if first -%>"><a href="<%= ApplicationController.root_context -%>/api/sources?resource=<%= @resource.key -%>&format=txt">Raw</a></li> | |||
<li class="<%= 'first' if first -%>"><a href="<%= ApplicationController.root_context -%>/api/sources?resource=<%= @resource.key -%>&format=txt"><%= message('raw') -%></a></li> | |||
<% first=false | |||
end | |||
if request.xhr? %> | |||
<li class="<%= 'first' if first -%>"><a href="<%= ApplicationController.root_context -%>/resource/index/<%= @resource.key -%>" onclick="window.open(this.href,'resource','height=800,width=900,scrollbars=1,resizable=1');return false;">New Window</a></li> | |||
<li class="<%= 'first' if first -%>"><a href="<%= ApplicationController.root_context -%>/resource/index/<%= @resource.key -%>" onclick="window.open(this.href,'resource','height=800,width=900,scrollbars=1,resizable=1');return false;"><%= message('new_window') -%></a></li> | |||
<% end %> | |||
</ul> | |||
<ul class="tabs" > | |||
<% if request.xhr? %> | |||
<% @extensions.each do |extension| %> | |||
<li><a href="#" onclick="loadAjaxTab('<%= @resource.id -%>','<%= extension.getId() -%>',<%= display_title -%>)" class="<%= 'selected' if @extension && @extension.getId()==extension.getId() -%>"><%= extension.getTitle() -%></a></li> | |||
<li><a href="#" onclick="loadAjaxTab('<%= @resource.id -%>','<%= extension.getId() -%>',<%= display_title -%>)" class="<%= 'selected' if @extension && @extension.getId()==extension.getId() -%>"><%= message(extension.getId() + '.page', :default => extension.getTitle()) %></a></li> | |||
<% end %> | |||
<% else %> | |||
<script>function loadTab(url) {$('resource-loading').show();document.location.href=url;return false;}</script> | |||
<% @extensions.each do |extension| %> | |||
<li><a href="#" onClick="loadTab('<%= url_for(:overwrite_params => {:tab => extension.getId(), :metric => nil}) -%>')" class="<%= 'selected' if @extension && @extension.getId()==extension.getId() -%>"><%= extension.getTitle() -%></a></li> | |||
<li><a href="#" onClick="loadTab('<%= url_for(:overwrite_params => {:tab => extension.getId(), :metric => nil}) -%>')" class="<%= 'selected' if @extension && @extension.getId()==extension.getId() -%>"><%= message(extension.getId() + '.page', :default => extension.getTitle()) %></a></li> | |||
<% end %> | |||
<% end %> | |||
<li> |
@@ -22,19 +22,19 @@ | |||
<% if violation.switched_off? %> | |||
<%= image_tag("sep12.png") -%> | |||
| |||
<span class="falsePositive">False-Positive</span> | |||
<span class="falsePositive"><%= message('false_positive') -%></span> | |||
| |||
<% end %> | |||
<% if violation.review && violation.review.isReopened? %> | |||
<%= image_tag("sep12.png") -%> | |||
| |||
<span class="review-reopened">Reopened</span> | |||
<span class="review-reopened"><%= message('reopened') -%></span> | |||
| |||
<% end %> | |||
<% if violation.review && violation.review.assignee_id %> | |||
<%= image_tag("sep12.png") -%> | |||
| |||
Assigned to: <%= h(violation.review.assignee.name) -%> | |||
<%= message('assigned_to') -%>: <%= h(violation.review.assignee.name) -%> | |||
| |||
<% end %> | |||
@@ -46,14 +46,14 @@ | |||
unless violation.switched_off? | |||
%> | |||
| |||
<%= link_to_remote (violation.review.isResolved? ? "Reopen" : "Resolve"), | |||
<%= link_to_remote (violation.review.isResolved? ? message('reopen') : message('resolve')), | |||
:url => { :controller => "reviews", :action => "violation_change_status", :id => violation.id}, | |||
:update => "vId" + violation.id.to_s, | |||
:confirm => violation.review.isResolved? ? "Do you want to reopen this review?" : "Do you want to resolve this review?" -%> | |||
:confirm => violation.review.isResolved? ? message('reviews.do_you_want_to_reopen') : message('reviews.do_you_want_to_resolve') -%> | |||
<% unless violation.review && violation.review.isResolved? %> | |||
| |||
<%= link_to_remote (violation.review.assignee_id ? "Reassign" : "Assign"), | |||
<%= link_to_remote (violation.review.assignee_id ? message('reassign') : message('assign')), | |||
:url => { :controller => "reviews", :action => "violation_assign_form", :violation_id => violation.id}, | |||
:update => "vActions" + violation.id.to_s, | |||
:complete => "$('vActions" + violation.id.to_s + "').show();$('commentActions" + violation.id.to_s + "').hide();$('assignee_login').focus();" -%> | |||
@@ -63,7 +63,7 @@ | |||
else | |||
%> | |||
| |||
<%= link_to_remote "Review", | |||
<%= link_to_remote message('review_verb'), | |||
:url => { :controller => "reviews", :action => "violation_comment_form", :id => violation.id }, | |||
:update => "reviewForm" + violation.id.to_s, | |||
:complete => "$('reviewForm" + violation.id.to_s + "').show();$('commentText" + violation.id.to_s + "').focus();$('vActions#{violation.id}').hide();" -%> | |||
@@ -71,7 +71,7 @@ | |||
| |||
<% if (!violation.review) || (violation.review && violation.review.can_change_false_positive_flag?) %> | |||
<%= link_to_remote (violation.switched_off? ? "Unflag as false-positive" : "Flag as false-positive"), | |||
<%= link_to_remote (violation.switched_off? ? message('reviews.unflag_as_false_positive') : message('reviews.flag_as_false_positive')), | |||
:url => { :controller => "reviews", :action => "violation_false_positive_form", :id => violation.id, :false_positive => !violation.switched_off? }, | |||
:update => "reviewForm" + violation.id.to_s, | |||
:complete => "$('reviewForm" + violation.id.to_s + "').show();$('commentText" + violation.id.to_s + "').focus();$('vActions" + violation.id.to_s + "').hide();$('commentActions" + violation.id.to_s + "').hide();" -%> | |||
@@ -97,7 +97,7 @@ | |||
| |||
<%= image_tag("sep12.png") -%> | |||
| |||
<%= link_to_remote "Add comment", | |||
<%= link_to_remote message('add_comment'), | |||
:url => { :controller => "reviews", :action => "violation_comment_form", :id => violation.id }, | |||
:update => "reviewForm" + violation.id.to_s, | |||
:complete => "$('vActions#{violation.id}').hide();$('commentActions" + violation.id.to_s + "').hide();$('reviewForm" + violation.id.to_s + "').show();$('commentText" + violation.id.to_s + "').focus()" -%> | |||
@@ -105,16 +105,16 @@ | |||
if current_user.id == review_comment.user_id | |||
%> | |||
| |||
<%= link_to_remote "Edit", | |||
<%= link_to_remote message('edit'), | |||
:url => { :controller => "reviews", :action => "violation_comment_form", :comment_id => review_comment.id, :id => violation.id }, | |||
:update => "lastComment" + violation.id.to_s, | |||
:complete => "$('vActions#{violation.id}').hide();$('commentActions#{violation.id}').hide();$('commentText#{violation.id}').focus();" -%> | |||
<% unless comment_index == 0 %> | |||
| |||
<%= link_to_remote "Delete", | |||
<%= link_to_remote message('delete'), | |||
:url => { :controller => "reviews", :action => "violation_delete_comment", :comment_id => review_comment.id, :id => violation.id }, | |||
:update => "vId" + violation.id.to_s, | |||
:confirm => "Do you want to delete this comment?" -%> | |||
:confirm => message('reviews.do_you_want_to_delete_comment') -%> | |||
<% end %> | |||
<% | |||
end |