summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRubén Dávila <rdavila84@gmail.com>2016-02-23 22:21:04 -0500
committerRubén Dávila <rdavila84@gmail.com>2016-03-04 22:37:03 -0500
commit3c157b6bf7fa97cba769ecacd11cdcdba43adf4a (patch)
tree65582691cb47177f92f2878fe05017929ab8315d
parentb6e5de2cfbc396ae4f59de2c2bb56432e705d695 (diff)
downloadgitlab-ce-3c157b6bf7fa97cba769ecacd11cdcdba43adf4a.tar.gz
Show Project name on Labels tab for Group and Dashboard context.
-rw-r--r--app/views/shared/milestones/_labels_tab.html.haml9
1 files changed, 8 insertions, 1 deletions
diff --git a/app/views/shared/milestones/_labels_tab.html.haml b/app/views/shared/milestones/_labels_tab.html.haml
index bb6ce0afb40..88e8e4f9006 100644
--- a/app/views/shared/milestones/_labels_tab.html.haml
+++ b/app/views/shared/milestones/_labels_tab.html.haml
@@ -1,12 +1,19 @@
+- show_project_name = local_assigns.fetch(:show_project_name, false)
+- show_full_project_name = local_assigns.fetch(:show_full_project_name, false)
+
%ul.bordered-list.manage-labels-list
- labels.each do |label|
- milestone = @milestone.is_a?(Milestone) ? @milestone : label.milestone
%li
= render_colored_label(label)
+ - if show_project_name
+ %strong &middot; #{milestone.project.name}
+ - elsif show_full_project_name
+ %strong &middot; #{milestone.project.name_with_namespace}
+
- args = [milestone.project.namespace, milestone.project, milestone_title: milestone.title, label_name: label.title]
- options = args.extract_options!
-
%span.issues-count
= link_to namespace_project_issues_path(*args, options.merge(state: 'opened')) do
= pluralize label.open_issues_count, 'open issue'