Skip to content

Commit

Permalink
shorten severity names and th to save space
Browse files Browse the repository at this point in the history
fixes #WEBINTERFACE-211
  • Loading branch information
Lennart Koopmann committed Dec 23, 2011
1 parent 79169d6 commit 23ac9e7
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
16 changes: 8 additions & 8 deletions app/helpers/application_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ def tab_link tab

def get_ordered_severities_for_select
[
["Emergency", 0],
["Emerg", 0],
["Alert", 1],
["Critical", 2],
["Crit", 2],
["Error", 3],
["Warning", 4],
["Warn", 4],
["Notice", 5],
["Informational", 6],
["Info", 6],
["Debug", 7]
]
end
Expand All @@ -39,13 +39,13 @@ def syslog_level_to_human level
return "None" if level == nil

case level.to_i
when 0 then return "Emergency"
when 0 then return "Emerg"
when 1 then return "Alert"
when 2 then return "Critical"
when 2 then return "Crit"
when 3 then return "Error"
when 4 then return "Warning"
when 4 then return "Warn"
when 5 then return "Notice"
when 6 then return "Informational"
when 6 then return "Info"
when 7 then return "Debug"
end
return "Invalid"
Expand Down
2 changes: 1 addition & 1 deletion app/views/messages/_table.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ additional_columns ||= []
<tr>
<th class="messages-c-date">Date</th>
<th class="messages-c-host">Host</th>
<th class="messages-c-severity">Severity</th>
<th class="messages-c-severity">Sev.</th>
<th class="messages-c-facility">Facility</th>
<% additional_columns.each do |col| %>
<th><%= col %></th>
Expand Down

0 comments on commit 23ac9e7

Please sign in to comment.