summaryrefslogtreecommitdiff
path: root/app/views/discussions
diff options
context:
space:
mode:
authorDouwe Maan <douwe@selenight.nl>2016-08-12 15:10:05 -0500
committerDouwe Maan <douwe@selenight.nl>2016-08-12 15:10:05 -0500
commit33edde50ab9a1f218ee4a5c9d2493a3d49d9b359 (patch)
tree4a6a086000e376f54b1d2ce0ae8065bba1ce4079 /app/views/discussions
parentc80f5e0a1c4906bf01ff02542d3c6b2afc79c5ff (diff)
downloadgitlab-ce-33edde50ab9a1f218ee4a5c9d2493a3d49d9b359.tar.gz
Don’t show “Resolve discussion” for non-author/members
Diffstat (limited to 'app/views/discussions')
-rw-r--r--app/views/discussions/_resolve_all.html.haml16
1 files changed, 8 insertions, 8 deletions
diff --git a/app/views/discussions/_resolve_all.html.haml b/app/views/discussions/_resolve_all.html.haml
index 5d751c60d2a..7a8767ddba0 100644
--- a/app/views/discussions/_resolve_all.html.haml
+++ b/app/views/discussions/_resolve_all.html.haml
@@ -1,11 +1,11 @@
-- if discussion.can_resolve?(current_user)
- .btn-group{ role: "group" }
- %resolve-discussion-btn{ ":namespace-path" => "'#{discussion.project.namespace.path}'",
- ":project-path" => "'#{discussion.project.path}'",
- ":discussion-id" => "'#{discussion.id}'",
- ":merge-request-id" => "#{discussion.noteable.iid}",
- "inline-template" => true,
- "v-cloak" => true }
+- if discussion.for_merge_request?
+ %resolve-discussion-btn{ ":namespace-path" => "'#{discussion.project.namespace.path}'",
+ ":project-path" => "'#{discussion.project.path}'",
+ ":discussion-id" => "'#{discussion.id}'",
+ ":merge-request-id" => discussion.noteable.iid,
+ ":can-resolve" => discussion.can_resolve?(current_user),
+ "inline-template" => true }
+ .btn-group{ role: "group", "v-if" => "showButton" }
%button.btn.btn-default{ type: "button", "@click" => "resolve", ":disabled" => "loading" }
= icon("spinner spin", "v-show" => "loading")
{{ buttonText }}