Commit 5ab657177c17f22afefbf25572e7ae2b20291c74

Authored by Marcin Ciunelis
1 parent 41396b68
Exists in master and in 1 other branch production

make use of notices_count cached value

app/views/errs/_table.html.haml
... ... @@ -34,7 +34,7 @@
34 34 %em= truncate(comment.body, :length => 100, :separator => ' ')
35 35 %td.latest #{time_ago_in_words(last_notice_at problem)} ago
36 36 %td.deploy= problem.last_deploy_at ? problem.last_deploy_at.to_s(:micro) : 'n/a'
37   - %td.count= link_to problem.notices.count, app_err_path(problem.app, problem)
  37 + %td.count= link_to problem.notices_count, app_err_path(problem.app, problem)
38 38 - if any_issue_links
39 39 %td.issue_link
40 40 - if problem.issue_link.present?
... ...
app/views/issue_trackers/pivotal_body.txt.erb
... ... @@ -3,7 +3,7 @@ See this exception on Errbit: <%= app_err_url problem.app, problem %>
3 3 <% if notice.request['url'].present? %>URL: <%= notice.request['url'] %><% end %>
4 4 Where: <%= notice.where %>
5 5 Occurred: <%= notice.created_at.to_s :micro %>
6   - Similar: <%= (notice.problem.notices.count - 1).to_s %>
  6 + Similar: <%= (notice.problem.notices_count - 1).to_s %>
7 7  
8 8 Params:
9 9 <%= pretty_hash notice.params %>
... ...