diff options
author | Harry Kiselev <harry.kiselev@gmail.com> | 2018-12-25 23:41:32 +0300 |
---|---|---|
committer | Harry Kiselev <harry.kiselev@gmail.com> | 2018-12-25 23:41:32 +0300 |
commit | c01444a79bc1d1dc1576b1d1e71680b27199f48d (patch) | |
tree | 7d1cfcca3739e4b42ebf35d07af9bc914f4342fa /app | |
parent | 5dc656fc1f053d397ad1e6c1d85a815f03a5d634 (diff) |
Update condition to visibility collaboration status text, #44642.
Diffstat (limited to 'app')
-rw-r--r-- | app/assets/javascripts/vue_merge_request_widget/mr_widget_options.vue | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/app/assets/javascripts/vue_merge_request_widget/mr_widget_options.vue b/app/assets/javascripts/vue_merge_request_widget/mr_widget_options.vue index d8a75388e84..b7f12076958 100644 --- a/app/assets/javascripts/vue_merge_request_widget/mr_widget_options.vue +++ b/app/assets/javascripts/vue_merge_request_widget/mr_widget_options.vue @@ -106,6 +106,9 @@ export default { (!this.mr.isNothingToMergeState && !this.mr.isMergedState) ); }, + shouldRenderCollaborationStatus() { + return this.mr.allowCollaboration && this.mr.isOpen; + }, shouldRenderMergedPipeline() { return this.mr.state === 'merged' && !_.isEmpty(this.mr.mergePipeline); }, @@ -315,7 +318,7 @@ export default { <div class="mr-widget-section"> <component :is="componentName" :mr="mr" :service="service" /> - <section v-if="mr.allowCollaboration" class="mr-info-list mr-links"> + <section v-if="shouldRenderCollaborationStatus" class="mr-info-list mr-links"> {{ s__('mrWidget|Allows commits from members who can merge to the target branch') }} </section> |