From 77bde9a0e41e9229357983d258eaea9d7ef67017 Mon Sep 17 00:00:00 2001 From: Riyad Preukschas Date: Thu, 4 Oct 2012 23:02:37 +0200 Subject: [PATCH] Add notes count to commits in lists. --- app/assets/stylesheets/sections/commits.scss | 5 +++++ app/views/commits/_commit.html.haml | 7 +++++++ 2 files changed, 12 insertions(+) diff --git a/app/assets/stylesheets/sections/commits.scss b/app/assets/stylesheets/sections/commits.scss index 711f603f75c..1da812750c3 100644 --- a/app/assets/stylesheets/sections/commits.scss +++ b/app/assets/stylesheets/sections/commits.scss @@ -203,6 +203,11 @@ @extend .cgray; } + .notes_count { + float:right; + margin: -6px 8px 6px; + } + code { background:#FCEEC1; color:$style_color; diff --git a/app/views/commits/_commit.html.haml b/app/views/commits/_commit.html.haml index 259e8e26260..9abadc5d807 100644 --- a/app/views/commits/_commit.html.haml +++ b/app/views/commits/_commit.html.haml @@ -13,3 +13,10 @@ = time_ago_in_words(commit.committed_date) ago   + + %span.notes_count + - notes = @project.commit_notes(commit) + @project.commit_line_notes(commit) + - if notes.any? + %span.btn.small.disabled.grouped + %i.icon-comment + = notes.count