diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-05-20 14:34:42 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-05-20 14:34:42 +0000 |
commit | 9f46488805e86b1bc341ea1620b866016c2ce5ed (patch) | |
tree | f9748c7e287041e37d6da49e0a29c9511dc34768 /app/views/groups | |
parent | dfc92d081ea0332d69c8aca2f0e745cb48ae5e6d (diff) | |
download | gitlab-ce-9f46488805e86b1bc341ea1620b866016c2ce5ed.tar.gz |
Add latest changes from gitlab-org/gitlab@13-0-stable-ee
Diffstat (limited to 'app/views/groups')
-rw-r--r-- | app/views/groups/_flash_messages.html.haml | 2 | ||||
-rw-r--r-- | app/views/groups/_home_panel.html.haml | 46 | ||||
-rw-r--r-- | app/views/groups/edit.html.haml | 4 | ||||
-rw-r--r-- | app/views/groups/group_members/index.html.haml | 22 | ||||
-rw-r--r-- | app/views/groups/settings/_advanced.html.haml | 2 | ||||
-rw-r--r-- | app/views/groups/settings/_default_branch_protection.html.haml | 3 | ||||
-rw-r--r-- | app/views/groups/settings/_export.html.haml | 28 | ||||
-rw-r--r-- | app/views/groups/settings/_permissions.html.haml | 2 | ||||
-rw-r--r-- | app/views/groups/settings/integrations/index.html.haml | 2 | ||||
-rw-r--r-- | app/views/groups/settings/repository/show.html.haml | 2 | ||||
-rw-r--r-- | app/views/groups/show.html.haml | 6 | ||||
-rw-r--r-- | app/views/groups/sidebar/_packages.html.haml | 4 |
12 files changed, 81 insertions, 42 deletions
diff --git a/app/views/groups/_flash_messages.html.haml b/app/views/groups/_flash_messages.html.haml new file mode 100644 index 00000000000..fa1a9d2cca4 --- /dev/null +++ b/app/views/groups/_flash_messages.html.haml @@ -0,0 +1,2 @@ += content_for :flash_message do + = render_if_exists 'shared/shared_runners_minutes_limit', namespace: @group, classes: [container_class, ("limit-container-width" unless fluid_layout)] diff --git a/app/views/groups/_home_panel.html.haml b/app/views/groups/_home_panel.html.haml index 6772ee94d46..d083288edc8 100644 --- a/app/views/groups/_home_panel.html.haml +++ b/app/views/groups/_home_panel.html.haml @@ -1,4 +1,5 @@ - can_create_subgroups = can?(current_user, :create_subgroup, @group) +- can_create_projects = can?(current_user, :create_projects, @group) - emails_disabled = @group.emails_disabled? .group-home-panel @@ -23,32 +24,33 @@ - if current_user .group-buttons = render 'shared/notifications/new_button', notification_setting: @notification_setting, btn_class: 'btn', emails_disabled: emails_disabled - - if can? current_user, :create_projects, @group - - new_project_label = _("New project") - - new_subgroup_label = _("New subgroup") - - if can_create_subgroups - .btn-group.new-project-subgroup.droplab-dropdown.home-panel-action-button.prepend-top-default.js-new-project-subgroup.qa-new-project-or-subgroup-dropdown{ data: { project_path: new_project_path(namespace_id: @group.id), subgroup_path: new_group_path(parent_id: @group.id) } } - %input.btn.btn-success.dropdown-primary.js-new-group-child.qa-new-in-group-button{ type: "button", value: new_project_label, data: { action: "new-project" } } - %button.btn.btn-success.dropdown-toggle.js-dropdown-toggle.qa-new-project-or-subgroup-dropdown-toggle{ type: "button", data: { "dropdown-trigger" => "#new-project-or-subgroup-dropdown", 'display' => 'static' } } - = sprite_icon("chevron-down", css_class: "icon dropdown-btn-icon") - %ul#new-project-or-subgroup-dropdown.dropdown-menu.dropdown-menu-right{ data: { dropdown: true } } - %li.droplab-item-selected.qa-new-project-option{ role: "button", data: { value: "new-project", text: new_project_label } } + - new_project_label = _("New project") + - new_subgroup_label = _("New subgroup") + - if can_create_projects and can_create_subgroups + .btn-group.new-project-subgroup.droplab-dropdown.home-panel-action-button.prepend-top-default.js-new-project-subgroup.qa-new-project-or-subgroup-dropdown{ data: { project_path: new_project_path(namespace_id: @group.id), subgroup_path: new_group_path(parent_id: @group.id) } } + %input.btn.btn-success.dropdown-primary.js-new-group-child.qa-new-in-group-button{ type: "button", value: new_project_label, data: { action: "new-project" } } + %button.btn.btn-success.dropdown-toggle.js-dropdown-toggle.qa-new-project-or-subgroup-dropdown-toggle{ type: "button", data: { "dropdown-trigger" => "#new-project-or-subgroup-dropdown", 'display' => 'static' } } + = sprite_icon("chevron-down", css_class: "icon dropdown-btn-icon") + %ul#new-project-or-subgroup-dropdown.dropdown-menu.dropdown-menu-right{ data: { dropdown: true } } + %li.droplab-item-selected.qa-new-project-option{ role: "button", data: { value: "new-project", text: new_project_label } } + .menu-item + .icon-container + = icon("check", class: "list-item-checkmark") + .description + %strong= new_project_label + %span= s_("GroupsTree|Create a project in this group.") + %li.divider.droplap-item-ignore + %li.qa-new-subgroup-option{ role: "button", data: { value: "new-subgroup", text: new_subgroup_label } } .menu-item .icon-container = icon("check", class: "list-item-checkmark") .description - %strong= new_project_label - %span= s_("GroupsTree|Create a project in this group.") - %li.divider.droplap-item-ignore - %li.qa-new-subgroup-option{ role: "button", data: { value: "new-subgroup", text: new_subgroup_label } } - .menu-item - .icon-container - = icon("check", class: "list-item-checkmark") - .description - %strong= new_subgroup_label - %span= s_("GroupsTree|Create a subgroup in this group.") - - else - = link_to new_project_label, new_project_path(namespace_id: @group.id), class: "btn btn-success prepend-top-default" + %strong= new_subgroup_label + %span= s_("GroupsTree|Create a subgroup in this group.") + - elsif can_create_projects + = link_to new_project_label, new_project_path(namespace_id: @group.id), class: "btn btn-success prepend-top-default" + - elsif can_create_subgroups + = link_to new_subgroup_label, new_group_path(parent_id: @group.id), class: "btn btn-success prepend-top-default" - if @group.description.present? .group-home-desc.mt-1 diff --git a/app/views/groups/edit.html.haml b/app/views/groups/edit.html.haml index fe5a00e3be9..2e58517fdc7 100644 --- a/app/views/groups/edit.html.haml +++ b/app/views/groups/edit.html.haml @@ -45,11 +45,11 @@ %section.settings.gs-advanced.no-animate#js-advanced-settings{ class: ('expanded' if expanded) } .settings-header %h4.settings-title.js-settings-toggle.js-settings-toggle-trigger-only{ role: 'button' } - = _('Path, transfer, remove') + = _('Advanced') %button.btn.js-settings-toggle{ type: 'button' } = expanded ? _('Collapse') : _('Expand') %p - = _('Perform advanced options such as changing path, transferring, or removing the group.') + = _('Perform advanced options such as changing path, transferring, exporting, or removing the group.') .settings-content = render 'groups/settings/advanced' diff --git a/app/views/groups/group_members/index.html.haml b/app/views/groups/group_members/index.html.haml index 048edb80d99..1f2fb747c7d 100644 --- a/app/views/groups/group_members/index.html.haml +++ b/app/views/groups/group_members/index.html.haml @@ -9,20 +9,16 @@ = _("Group members") %hr - if can_manage_members - - if Feature.enabled?(:share_group_with_group, default_enabled: true) - %ul.nav-links.nav.nav-tabs.gitlab-tabs{ role: 'tablist' } + %ul.nav-links.nav.nav-tabs.gitlab-tabs{ role: 'tablist' } + %li.nav-tab{ role: 'presentation' } + %a.nav-link.active{ href: '#invite-member-pane', id: 'invite-member-tab', data: { toggle: 'tab' }, role: 'tab' }= _("Invite member") %li.nav-tab{ role: 'presentation' } - %a.nav-link.active{ href: '#invite-member-pane', id: 'invite-member-tab', data: { toggle: 'tab' }, role: 'tab' }= _("Invite member") - %li.nav-tab{ role: 'presentation' } - %a.nav-link{ href: '#invite-group-pane', id: 'invite-group-tab', data: { toggle: 'tab', qa_selector: 'invite_group_tab' }, role: 'tab' }= _("Invite group") - .tab-content.gitlab-tab-content - .tab-pane.active{ id: 'invite-member-pane', role: 'tabpanel' } - = render_invite_member_for_group(@group, @group_member.access_level) - - if Feature.enabled?(:share_group_with_group, default_enabled: true) - .tab-pane{ id: 'invite-group-pane', role: 'tabpanel' } - = render 'shared/members/invite_group', submit_url: group_group_links_path(@group), access_levels: GroupMember.access_level_roles, default_access_level: @group_member.access_level, group_link_field: 'shared_with_group_id', group_access_field: 'shared_group_access' - - else - = render_invite_member_for_group(@group, @group_member.access_level) + %a.nav-link{ href: '#invite-group-pane', id: 'invite-group-tab', data: { toggle: 'tab', qa_selector: 'invite_group_tab' }, role: 'tab' }= _("Invite group") + .tab-content.gitlab-tab-content + .tab-pane.active{ id: 'invite-member-pane', role: 'tabpanel' } + = render_invite_member_for_group(@group, @group_member.access_level) + .tab-pane{ id: 'invite-group-pane', role: 'tabpanel' } + = render 'shared/members/invite_group', submit_url: group_group_links_path(@group), access_levels: GroupMember.access_level_roles, default_access_level: @group_member.access_level, group_link_field: 'shared_with_group_id', group_access_field: 'shared_group_access' = render 'shared/members/requests', membership_source: @group, requesters: @requesters diff --git a/app/views/groups/settings/_advanced.html.haml b/app/views/groups/settings/_advanced.html.haml index 2734ab538a0..0df82898644 100644 --- a/app/views/groups/settings/_advanced.html.haml +++ b/app/views/groups/settings/_advanced.html.haml @@ -1,3 +1,5 @@ += render 'groups/settings/export', group: @group + .sub-section %h4.warning-title= s_('GroupSettings|Change group path') = form_for @group, html: { multipart: true, class: 'gl-show-field-errors' }, authenticity_token: true do |f| diff --git a/app/views/groups/settings/_default_branch_protection.html.haml b/app/views/groups/settings/_default_branch_protection.html.haml new file mode 100644 index 00000000000..e0e901cbc4a --- /dev/null +++ b/app/views/groups/settings/_default_branch_protection.html.haml @@ -0,0 +1,3 @@ +- return unless can_update_default_branch_protection?(group) + += render 'shared/default_branch_protection', f: f, selected_level: group.default_branch_protection diff --git a/app/views/groups/settings/_export.html.haml b/app/views/groups/settings/_export.html.haml new file mode 100644 index 00000000000..ef7bf562c69 --- /dev/null +++ b/app/views/groups/settings/_export.html.haml @@ -0,0 +1,28 @@ +- return unless Feature.enabled?(:group_import_export, @group, default_enabled: true) + +- group = local_assigns.fetch(:group) + +.sub-section + %h4= s_('GroupSettings|Export group') + %p= _('Export this group with all related data to a new GitLab instance. Once complete, you can import the data file from the "New Group" page.') + + .bs-callout.bs-callout-info + %p.append-bottom-0 + %p= _('The following items will be exported:') + %ul + - group_export_descriptions.each do |description| + %li= description + %p= _('The following items will NOT be exported:') + %ul + %li= _('Projects') + %li= _('Runner tokens') + %li= _('SAML discovery tokens') + %p= _('Once the exported file is ready, you will receive a notification email with a download link, or you can download it from this page.') + - if group.export_file_exists? + = link_to _('Regenerate export'), export_group_path(group), + method: :post, class: 'btn btn-default', data: { qa_selector: 'regenerate_export_group_link' } + = link_to _('Download export'), download_export_group_path(group), + rel: 'nofollow', method: :get, class: 'btn btn-default', data: { qa_selector: 'download_export_link' } + - else + = link_to _('Export group'), export_group_path(group), + method: :post, class: 'btn btn-default', data: { qa_selector: 'export_group_link' } diff --git a/app/views/groups/settings/_permissions.html.haml b/app/views/groups/settings/_permissions.html.haml index 1ddaa855e62..e886c99a656 100644 --- a/app/views/groups/settings/_permissions.html.haml +++ b/app/views/groups/settings/_permissions.html.haml @@ -33,7 +33,7 @@ = render_if_exists 'groups/settings/ip_restriction', f: f, group: @group = render_if_exists 'groups/settings/allowed_email_domain', f: f, group: @group = render 'groups/settings/lfs', f: f - = render 'shared/default_branch_protection', f: f, selected_level: @group.default_branch_protection + = render 'groups/settings/default_branch_protection', f: f, group: @group = render 'groups/settings/project_creation_level', f: f, group: @group = render 'groups/settings/subgroup_creation_level', f: f, group: @group = render 'groups/settings/two_factor_auth', f: f diff --git a/app/views/groups/settings/integrations/index.html.haml b/app/views/groups/settings/integrations/index.html.haml index 78825cc72b0..96bd6d69a96 100644 --- a/app/views/groups/settings/integrations/index.html.haml +++ b/app/views/groups/settings/integrations/index.html.haml @@ -6,4 +6,4 @@ %p = s_('GroupSettings|Integrations configured here will automatically apply to all projects in this group.') = link_to _('Learn more'), '#' -= render 'shared/integrations/integrations', integrations: @integrations += render 'shared/integrations/index', integrations: @integrations diff --git a/app/views/groups/settings/repository/show.html.haml b/app/views/groups/settings/repository/show.html.haml index 1f1d7779267..ff0c9de4fef 100644 --- a/app/views/groups/settings/repository/show.html.haml +++ b/app/views/groups/settings/repository/show.html.haml @@ -1,6 +1,6 @@ - breadcrumb_title _('Repository Settings') - page_title _('Repository') -- deploy_token_description = s_('DeployTokens|Group deploy tokens allow read-only access to the repositories and registry images within the group.') +- deploy_token_description = s_('DeployTokens|Group deploy tokens allow access to the packages, repositories, and registry images within the group.') = render "shared/deploy_tokens/index", group_or_project: @group, description: deploy_token_description diff --git a/app/views/groups/show.html.haml b/app/views/groups/show.html.haml index a9c19502a7c..032766327ca 100644 --- a/app/views/groups/show.html.haml +++ b/app/views/groups/show.html.haml @@ -1,9 +1,15 @@ - breadcrumb_title _("Details") - @content_class = "limit-container-width" unless fluid_layout += content_for :flash_message do + - if Feature.enabled?(:subscribable_banner_subscription) + = render_if_exists "layouts/header/ee_subscribable_banner", subscription: true + = content_for :meta_tags do = auto_discovery_link_tag(:atom, group_url(@group, rss_url_options), title: "#{@group.name} activity") += render partial: 'flash_messages' + %div{ class: [("limit-container-width" unless fluid_layout)] } = render_if_exists 'trials/banner', namespace: @group diff --git a/app/views/groups/sidebar/_packages.html.haml b/app/views/groups/sidebar/_packages.html.haml index 16b902a18b9..67e759a4d63 100644 --- a/app/views/groups/sidebar/_packages.html.haml +++ b/app/views/groups/sidebar/_packages.html.haml @@ -4,12 +4,12 @@ .nav-icon-container = sprite_icon('package') %span.nav-item-name - = _('Packages') + = _('Packages & Registries') %ul.sidebar-sub-level-items = nav_link(controller: [:packages, :repositories], html_options: { class: "fly-out-top-item" } ) do = link_to group_container_registries_path(@group), title: _('Container Registry') do %strong.fly-out-top-item-name - = _('Packages') + = _('Packages & Registries') %li.divider.fly-out-top-item = nav_link(controller: 'groups/container_registries') do = link_to group_container_registries_path(@group), title: _('Container Registry') do |