summaryrefslogtreecommitdiff
path: root/app/views/groups/merge_requests.html.haml
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/groups/merge_requests.html.haml')
-rw-r--r--app/views/groups/merge_requests.html.haml30
1 files changed, 12 insertions, 18 deletions
diff --git a/app/views/groups/merge_requests.html.haml b/app/views/groups/merge_requests.html.haml
index 33fcda6129c..6c4a8b53764 100644
--- a/app/views/groups/merge_requests.html.haml
+++ b/app/views/groups/merge_requests.html.haml
@@ -1,24 +1,18 @@
-- @can_bulk_update = can?(current_user, :admin_merge_request, @group) && @group.licensed_feature_available?(:group_bulk_edit)
+- @can_bulk_update = can?(current_user, :admin_merge_request, @group) && @group.licensed_feature_available?(:group_bulk_edit) && issuables_count_for_state(:merge_requests, :all) > 0
- page_title _("Merge requests")
-- if issuables_count_for_state(:merge_requests, :all) == 0
- = render 'shared/issuable/search_bar', type: :merge_requests
+.top-area
+ = render 'shared/issuable/nav', type: :merge_requests
+ - if current_user
+ .nav-controls
+ - if @can_bulk_update
+ = render_if_exists 'projects/merge_requests/bulk_update_button'
- = render 'shared/empty_states/merge_requests', project_select_button: true
-- else
- .top-area
- = render 'shared/issuable/nav', type: :merge_requests
- - if current_user
- .nav-controls
- - if @can_bulk_update
- = render_if_exists 'projects/merge_requests/bulk_update_button'
+ = render 'shared/new_project_item_select', path: 'merge_requests/new', label: _("merge request"), type: :merge_requests, with_feature_enabled: 'merge_requests', with_shared: false, include_projects_in_subgroups: true
- = render 'shared/new_project_item_select', path: 'merge_requests/new', label: _("merge request"), type: :merge_requests, with_feature_enabled: 'merge_requests', with_shared: false, include_projects_in_subgroups: true
+= render 'shared/issuable/search_bar', type: :merge_requests
+- if @can_bulk_update
+ = render_if_exists 'shared/issuable/group_bulk_update_sidebar', group: @group, type: :merge_requests
- = render 'shared/issuable/search_bar', type: :merge_requests
-
- - if @can_bulk_update
- = render_if_exists 'shared/issuable/group_bulk_update_sidebar', group: @group, type: :merge_requests
-
- = render 'shared/merge_requests'
+= render 'shared/merge_requests'