From 03441769dfc09776eb8511275a3f492ded1a7c42 Mon Sep 17 00:00:00 2001 From: Dmitriy Zaporozhets Date: Tue, 7 May 2013 19:26:41 +0300 Subject: Include default labels in issues autocomplete etc. Show colored labels on issues show page --- app/views/labels/_label.html.haml | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) (limited to 'app/views/labels/_label.html.haml') diff --git a/app/views/labels/_label.html.haml b/app/views/labels/_label.html.haml index 027b041d58e..2b1aafc546b 100644 --- a/app/views/labels/_label.html.haml +++ b/app/views/labels/_label.html.haml @@ -1,9 +1,15 @@ +- frequency = @project.issues.tagged_with(label.name).count %li %strong - %i.icon-tag - = label.name + %span{class: "label #{label_css_class(label.name)}"} + %i.icon-tag + - if frequency.zero? + %span.light= label.name + - else + = label.name .pull-right - = link_to project_issues_path(label_name: label.name) do - %strong - = pluralize(label.count, 'issue') - = "»" + - unless frequency.zero? + = link_to project_issues_path(label_name: label.name) do + %strong + = pluralize(frequency, 'issue') + = "»" -- cgit v1.2.1