Commit 682e1d09 authored by Phil Hughes's avatar Phil Hughes

Merge branch 'layouts-scb' into 'master'

Resolve CE/EE diffs in app/views/layouts view

Closes gitlab-ee#6647

See merge request gitlab-org/gitlab-ce!28197
parents 9d5afa1c 974e71a9
...@@ -58,6 +58,14 @@ module NavHelper ...@@ -58,6 +58,14 @@ module NavHelper
current_path?('milestones#show') current_path?('milestones#show')
end end
def admin_monitoring_nav_links
%w(system_info background_jobs logs health_check requests_profiles)
end
def group_issues_sub_menu_items
%w(groups#issues labels#index milestones#index boards#index boards#show)
end
private private
def get_header_links def get_header_links
......
...@@ -7,6 +7,7 @@ class DeviseMailer < Devise::Mailer ...@@ -7,6 +7,7 @@ class DeviseMailer < Devise::Mailer
layout 'mailer/devise' layout 'mailer/devise'
helper EmailsHelper helper EmailsHelper
helper ApplicationHelper
protected protected
......
...@@ -77,3 +77,4 @@ ...@@ -77,3 +77,4 @@
= render 'layouts/google_analytics' if extra_config.has_key?('google_analytics_id') = render 'layouts/google_analytics' if extra_config.has_key?('google_analytics_id')
= render 'layouts/piwik' if extra_config.has_key?('piwik_url') && extra_config.has_key?('piwik_site_id') = render 'layouts/piwik' if extra_config.has_key?('piwik_url') && extra_config.has_key?('piwik_site_id')
= render_if_exists 'layouts/snowplow'
...@@ -64,6 +64,8 @@ ...@@ -64,6 +64,8 @@
%tbody %tbody
= yield = yield
= render_if_exists 'layouts/mailer/additional_text'
%tr.footer %tr.footer
%td{ style: "font-family:'Helvetica Neue',Helvetica,Arial,sans-serif;padding:25px 0;font-size:13px;line-height:1.6;color:#5c5c5c;" } %td{ style: "font-family:'Helvetica Neue',Helvetica,Arial,sans-serif;padding:25px 0;font-size:13px;line-height:1.6;color:#5c5c5c;" }
%img{ alt: "GitLab", height: "33", src: image_url('mailers/gitlab_footer_logo.gif'), style: "display:block;margin:0 auto 1em;", width: "90" }/ %img{ alt: "GitLab", height: "33", src: image_url('mailers/gitlab_footer_logo.gif'), style: "display:block;margin:0 auto 1em;", width: "90" }/
......
...@@ -5,6 +5,7 @@ ...@@ -5,6 +5,7 @@
= render 'shared/outdated_browser' = render 'shared/outdated_browser'
.mobile-overlay .mobile-overlay
.alert-wrapper .alert-wrapper
= render_if_exists "layouts/header/ee_license_banner"
= render "layouts/broadcast" = render "layouts/broadcast"
= render "layouts/header/read_only_banner" = render "layouts/header/read_only_banner"
= render "layouts/nav/classification_level_banner" = render "layouts/nav/classification_level_banner"
......
...@@ -26,6 +26,9 @@ ...@@ -26,6 +26,9 @@
- if Gitlab::CurrentSettings.sign_in_text.present? - if Gitlab::CurrentSettings.sign_in_text.present?
= markdown_field(Gitlab::CurrentSettings.current_application_settings, :sign_in_text) = markdown_field(Gitlab::CurrentSettings.current_application_settings, :sign_in_text)
= render_if_exists 'layouts/devise_help_text'
.col-sm-5.new-session-forms-container .col-sm-5.new-session-forms-container
= yield = yield
......
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
= link_to _("Submit feedback"), "https://about.gitlab.com/submit-feedback" = link_to _("Submit feedback"), "https://about.gitlab.com/submit-feedback"
- if current_user_menu?(:help) || current_user_menu?(:settings) || current_user_menu?(:profile) - if current_user_menu?(:help) || current_user_menu?(:settings) || current_user_menu?(:profile)
= render 'shared/user_dropdown_contributing_link' = render 'shared/user_dropdown_contributing_link'
= render_if_exists 'shared/user_dropdown_instance_review'
- if Gitlab.com? - if Gitlab.com?
%li.js-canary-link %li.js-canary-link
= link_to _("Switch to GitLab Next"), "https://next.gitlab.com/" = link_to _("Switch to GitLab Next"), "https://next.gitlab.com/"
...@@ -4,5 +4,6 @@ ...@@ -4,5 +4,6 @@
-- <%# signature marker %> -- <%# signature marker %>
<%= _("You're receiving this email because of your account on %{host}.") % { host: Gitlab.config.gitlab.host } %> <%= _("You're receiving this email because of your account on %{host}.") % { host: Gitlab.config.gitlab.host } %>
<%= render_if_exists 'layouts/mailer/additional_text' %>
<%= text_footer_message %> <%= text_footer_message %>
...@@ -95,3 +95,4 @@ ...@@ -95,3 +95,4 @@
= link_to sherlock_transactions_path, class: 'admin-icon d-none d-lg-block d-xl-block', title: _('Sherlock Transactions'), = link_to sherlock_transactions_path, class: 'admin-icon d-none d-lg-block d-xl-block', title: _('Sherlock Transactions'),
data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do
= icon('tachometer fw') = icon('tachometer fw')
= render_if_exists 'layouts/nav/geo_primary_node_url'
...@@ -48,7 +48,7 @@ ...@@ -48,7 +48,7 @@
%span %span
= _('Gitaly Servers') = _('Gitaly Servers')
= nav_link(controller: %w(system_info background_jobs logs health_check requests_profiles)) do = nav_link(controller: admin_monitoring_nav_links) do
= link_to admin_system_info_path do = link_to admin_system_info_path do
.nav-icon-container .nav-icon-container
= sprite_icon('monitor') = sprite_icon('monitor')
...@@ -81,6 +81,7 @@ ...@@ -81,6 +81,7 @@
= link_to admin_requests_profiles_path, title: _('Requests Profiles') do = link_to admin_requests_profiles_path, title: _('Requests Profiles') do
%span %span
= _('Requests Profiles') = _('Requests Profiles')
= render_if_exists 'layouts/nav/ee/admin/new_monitoring_sidebar'
= nav_link(controller: :broadcast_messages) do = nav_link(controller: :broadcast_messages) do
= link_to admin_broadcast_messages_path do = link_to admin_broadcast_messages_path do
...@@ -132,6 +133,8 @@ ...@@ -132,6 +133,8 @@
= _('Abuse Reports') = _('Abuse Reports')
%span.badge.badge-pill.count.merge_counter.js-merge-counter.fly-out-badge= number_with_delimiter(AbuseReport.count(:all)) %span.badge.badge-pill.count.merge_counter.js-merge-counter.fly-out-badge= number_with_delimiter(AbuseReport.count(:all))
= render_if_exists 'layouts/nav/sidebar/licenses_link'
- if instance_clusters_enabled? - if instance_clusters_enabled?
= nav_link(controller: :clusters) do = nav_link(controller: :clusters) do
= link_to admin_clusters_path do = link_to admin_clusters_path do
...@@ -158,6 +161,10 @@ ...@@ -158,6 +161,10 @@
%strong.fly-out-top-item-name %strong.fly-out-top-item-name
= _('Spam Logs') = _('Spam Logs')
= render_if_exists 'layouts/nav/sidebar/push_rules_link'
= render_if_exists 'layouts/nav/ee/admin/geo_sidebar'
= nav_link(controller: :deploy_keys) do = nav_link(controller: :deploy_keys) do
= link_to admin_deploy_keys_path do = link_to admin_deploy_keys_path do
.nav-icon-container .nav-icon-container
......
- issues_count = group_issues_count(state: 'opened') - issues_count = group_issues_count(state: 'opened')
- merge_requests_count = group_merge_requests_count(state: 'opened') - merge_requests_count = group_merge_requests_count(state: 'opened')
- issues_sub_menu_items = ['groups#issues', 'labels#index', 'milestones#index', 'boards#index', 'boards#show']
.nav-sidebar{ class: ("sidebar-collapsed-desktop" if collapsed_sidebar?) } .nav-sidebar{ class: ("sidebar-collapsed-desktop" if collapsed_sidebar?) }
.nav-sidebar-inner-scroll .nav-sidebar-inner-scroll
...@@ -51,7 +50,7 @@ ...@@ -51,7 +50,7 @@
= render_if_exists "layouts/nav/ee/epic_link", group: @group = render_if_exists "layouts/nav/ee/epic_link", group: @group
- if group_sidebar_link?(:issues) - if group_sidebar_link?(:issues)
= nav_link(path: issues_sub_menu_items) do = nav_link(path: group_issues_sub_menu_items) do
= link_to issues_group_path(@group) do = link_to issues_group_path(@group) do
.nav-icon-container .nav-icon-container
= sprite_icon('issues') = sprite_icon('issues')
......
...@@ -28,6 +28,8 @@ ...@@ -28,6 +28,8 @@
= link_to profile_account_path do = link_to profile_account_path do
%strong.fly-out-top-item-name %strong.fly-out-top-item-name
= _('Account') = _('Account')
= render_if_exists 'layouts/nav/sidebar/profile_billing_link'
= nav_link(controller: 'oauth/applications') do = nav_link(controller: 'oauth/applications') do
= link_to applications_profile_path do = link_to applications_profile_path do
.nav-icon-container .nav-icon-container
...@@ -151,4 +153,6 @@ ...@@ -151,4 +153,6 @@
%strong.fly-out-top-item-name %strong.fly-out-top-item-name
= _('Authentication Log') = _('Authentication Log')
= render_if_exists 'layouts/nav/sidebar/profile_pipeline_quota_link'
= render 'shared/sidebar_toggle_button' = render 'shared/sidebar_toggle_button'
...@@ -270,6 +270,8 @@ ...@@ -270,6 +270,8 @@
%span= _("Got it!") %span= _("Got it!")
= sprite_icon('thumb-up') = sprite_icon('thumb-up')
= render_if_exists 'layouts/nav/sidebar/project_feature_flags_link'
- if project_nav_tab? :container_registry - if project_nav_tab? :container_registry
= nav_link(controller: %w[projects/registry/repositories]) do = nav_link(controller: %w[projects/registry/repositories]) do
= link_to project_container_registry_index_path(@project), class: 'shortcuts-container-registry' do = link_to project_container_registry_index_path(@project), class: 'shortcuts-container-registry' do
...@@ -283,7 +285,9 @@ ...@@ -283,7 +285,9 @@
%strong.fly-out-top-item-name %strong.fly-out-top-item-name
= _('Registry') = _('Registry')
- if project_nav_tab?(:wiki) = render_if_exists 'layouts/nav/sidebar/project_packages_link'
- if project_nav_tab? :wiki
- wiki_url = project_wiki_path(@project, :home) - wiki_url = project_wiki_path(@project, :home)
= nav_link(controller: :wikis) do = nav_link(controller: :wikis) do
= link_to wiki_url, class: 'shortcuts-wiki qa-wiki-link' do = link_to wiki_url, class: 'shortcuts-wiki qa-wiki-link' do
......
...@@ -31,4 +31,6 @@ ...@@ -31,4 +31,6 @@
adjust your notification settings. adjust your notification settings.
= email_action @target_url = email_action @target_url
= render_if_exists 'layouts/email_additional_text'
= html_footer_message = html_footer_message
...@@ -12,5 +12,6 @@ ...@@ -12,5 +12,6 @@
<% end -%> <% end -%>
<%= "You're receiving this email because #{notification_reason_text(@reason)}." %> <%= "You're receiving this email because #{notification_reason_text(@reason)}." %>
<%= render_if_exists 'layouts/mailer/additional_text' %>
<%= text_footer_message -%> <%= text_footer_message -%>
...@@ -50,4 +50,16 @@ describe NavHelper do ...@@ -50,4 +50,16 @@ describe NavHelper do
expect(helper.header_links).to contain_exactly(:sign_in, :search) expect(helper.header_links).to contain_exactly(:sign_in, :search)
end end
end end
context '.admin_monitoring_nav_links' do
subject { helper.admin_monitoring_nav_links }
it { is_expected.to all(be_a(String)) }
end
context '.group_issues_sub_menu_items' do
subject { helper.group_issues_sub_menu_items }
it { is_expected.to all(be_a(String)) }
end
end end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment