summaryrefslogtreecommitdiff
path: root/app/views/shared/issuable
diff options
context:
space:
mode:
authorClement Ho <ClemMakesApps@gmail.com>2017-05-04 15:55:36 -0500
committerClement Ho <ClemMakesApps@gmail.com>2017-05-04 22:34:15 -0500
commitc4094b7ec4699811f928699ad67c90e1686da6e2 (patch)
treeae5535a19e15452baa0d08d4fd702a6a1465919b /app/views/shared/issuable
parent3f6477fd1f6fc83e5ef8d03e7c2fe960294c8a98 (diff)
downloadgitlab-ce-c4094b7ec4699811f928699ad67c90e1686da6e2.tar.gz
Fix specs
Diffstat (limited to 'app/views/shared/issuable')
-rw-r--r--app/views/shared/issuable/form/_metadata.html.haml5
1 files changed, 4 insertions, 1 deletions
diff --git a/app/views/shared/issuable/form/_metadata.html.haml b/app/views/shared/issuable/form/_metadata.html.haml
index 411cb717fc7..9281a515744 100644
--- a/app/views/shared/issuable/form/_metadata.html.haml
+++ b/app/views/shared/issuable/form/_metadata.html.haml
@@ -17,7 +17,10 @@
- issuable.assignees.each do |assignee|
= hidden_field_tag "#{issuable.to_ability_name}[assignee_ids][]", assignee.id, id: nil, data: { meta: assignee.name }
- = dropdown_tag(users_dropdown_label(issuable.assignees), options: issue_dropdown_options(issuable, true))
+ - if issuable.assignees.length === 0
+ = hidden_field_tag "#{issuable.to_ability_name}[assignee_ids][]", 0, id: nil, data: { meta: '' }
+
+ = dropdown_tag(users_dropdown_label(issuable.assignees), options: issue_dropdown_options(issuable,false))
= link_to 'Assign to me', '#', class: "assign-to-me-link #{'hide' if issuable.assignees.include?(current_user)}"
- else
= form.label :assignee_id, "Assignee", class: "control-label #{"col-lg-4" if has_due_date}"