summaryrefslogtreecommitdiff
path: root/app/views/projects/labels/_label.html.haml
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2014-07-30 15:15:39 +0300
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2014-07-30 15:15:39 +0300
commit593df8e69a81a3ab0a4755db74dc282c00e02ef5 (patch)
treecdbec00afa3289a9fe4065a8c7ba56e5c82a365f /app/views/projects/labels/_label.html.haml
parentcc331684593143cba773b0160222865eeb86b134 (diff)
downloadgitlab-ce-593df8e69a81a3ab0a4755db74dc282c00e02ef5.tar.gz
Improve labels
* allow developers to manage labels * add ability to remove label Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'app/views/projects/labels/_label.html.haml')
-rw-r--r--app/views/projects/labels/_label.html.haml8
1 files changed, 7 insertions, 1 deletions
diff --git a/app/views/projects/labels/_label.html.haml b/app/views/projects/labels/_label.html.haml
index 59bf31314e7..488f86a3ce1 100644
--- a/app/views/projects/labels/_label.html.haml
+++ b/app/views/projects/labels/_label.html.haml
@@ -1,4 +1,10 @@
%li
= render_colored_label(label)
.pull-right
- = link_to 'Edit', edit_project_label_path(@project, label), class: 'btn'
+ %strong.append-right-20
+ = link_to project_issues_path(@project, label_name: label.name) do
+ = pluralize label.open_issues_count, 'open issue'
+
+ - if can? current_user, :admin_label, @project
+ = link_to 'Edit', edit_project_label_path(@project, label), class: 'btn'
+ = link_to 'Remove', project_label_path(@project, label), class: 'btn btn-remove', method: :delete, data: {confirm: "Remove this label? Are you sure?"}