diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2016-06-20 14:55:20 +0300 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2016-06-20 14:55:20 +0300 |
commit | 3f12e8d1b2bca17554780104fd668299a5a2e196 (patch) | |
tree | 364312c2494a45a36b548076b06ea28e12d9fd18 /app | |
parent | 73d431731f9f749557aa755848af3aa4e1c4cc9f (diff) |
Put some admin settings in dropdown
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'app')
-rw-r--r-- | app/views/admin/appearances/show.html.haml | 12 | ||||
-rw-r--r-- | app/views/admin/application_settings/_head.html.haml | 11 | ||||
-rw-r--r-- | app/views/admin/application_settings/show.html.haml | 8 | ||||
-rw-r--r-- | app/views/layouts/nav/_admin.html.haml | 84 | ||||
-rw-r--r-- | app/views/layouts/nav/_admin_settings.html.haml | 31 |
5 files changed, 75 insertions, 71 deletions
diff --git a/app/views/admin/appearances/show.html.haml b/app/views/admin/appearances/show.html.haml index e220f4956cb..454b779842c 100644 --- a/app/views/admin/appearances/show.html.haml +++ b/app/views/admin/appearances/show.html.haml @@ -1,7 +1,9 @@ -- @no_container = true - page_title "Appearance" -= render "admin/application_settings/head" -%div{ class: (container_class) } - .prepend-top-default - = render 'form' +%h3.page-title + Appearance settings +%p.light + You can modify the look and feel of GitLab here +%hr + += render 'form' diff --git a/app/views/admin/application_settings/_head.html.haml b/app/views/admin/application_settings/_head.html.haml deleted file mode 100644 index de919b298c1..00000000000 --- a/app/views/admin/application_settings/_head.html.haml +++ /dev/null @@ -1,11 +0,0 @@ -.nav-links.sub-nav - %ul{ class: (container_class) } - = nav_link(controller: :application_settings) do - = link_to admin_application_settings_path, title: 'Settings' do - %span - General - - = nav_link(controller: :appearances) do - = link_to admin_appearances_path, title: 'Appearances' do - %span - Appearance diff --git a/app/views/admin/application_settings/show.html.haml b/app/views/admin/application_settings/show.html.haml index 82588c275d0..ecc46d86afe 100644 --- a/app/views/admin/application_settings/show.html.haml +++ b/app/views/admin/application_settings/show.html.haml @@ -1,7 +1,5 @@ -- @no_container = true - page_title "Settings" -= render "admin/application_settings/head" -%div{ class: (container_class) } - .prepend-top-default - = render 'form' +%h3.page-title Settings +%hr += render 'form' diff --git a/app/views/layouts/nav/_admin.html.haml b/app/views/layouts/nav/_admin.html.haml index c6d8b17a1e5..4722c9d9353 100644 --- a/app/views/layouts/nav/_admin.html.haml +++ b/app/views/layouts/nav/_admin.html.haml @@ -1,55 +1,39 @@ -%ul.nav-links.scrolling-tabs - .fade-left - = nav_link(controller: %w(dashboard admin projects users groups builds runners), html_options: {class: 'home'}) do - = link_to admin_root_path, title: 'Overview', class: 'shortcuts-tree' do - %span - Overview - = nav_link(controller: %w(background_jobs logs health_check)) do - = link_to admin_background_jobs_path, title: 'Monitoring' do - %span - Monitoring - = nav_link(controller: :deploy_keys) do - = link_to admin_deploy_keys_path, title: 'Deploy Keys' do - %span - Deploy Keys - = nav_link(controller: :broadcast_messages) do - = link_to admin_broadcast_messages_path, title: 'Messages' do - %span - Messages - = nav_link(controller: :hooks) do - = link_to admin_hooks_path, title: 'Hooks' do - %span - Hooks +%div{ class: nav_control_class } + = render 'layouts/nav/admin_settings' - = nav_link(controller: :applications) do - = link_to admin_applications_path, title: 'Applications' do - %span - Applications - - = nav_link(controller: :services) do - = link_to admin_application_settings_services_path, title: 'Service Templates' do - %span - Service Templates - - = nav_link(controller: :labels) do - = link_to admin_labels_path, title: 'Labels' do - %span - Labels + %ul.nav-links.scrolling-tabs + .fade-left + = nav_link(controller: %w(dashboard admin projects users groups builds runners), html_options: {class: 'home'}) do + = link_to admin_root_path, title: 'Overview', class: 'shortcuts-tree' do + %span + Overview + = nav_link(controller: %w(background_jobs logs health_check)) do + = link_to admin_background_jobs_path, title: 'Monitoring' do + %span + Monitoring + = nav_link(controller: :broadcast_messages) do + = link_to admin_broadcast_messages_path, title: 'Messages' do + %span + Messages + = nav_link(controller: :hooks) do + = link_to admin_hooks_path, title: 'Hooks' do + %span + System Hooks - = nav_link(controller: :abuse_reports) do - = link_to admin_abuse_reports_path, title: "Abuse Reports" do - %span - Abuse Reports - %span.badge.count= number_with_delimiter(AbuseReport.count(:all)) + = nav_link(controller: :applications) do + = link_to admin_applications_path, title: 'Applications' do + %span + Applications - - if askimet_enabled? - = nav_link(controller: :spam_logs) do - = link_to admin_spam_logs_path, title: "Spam Logs" do + = nav_link(controller: :abuse_reports) do + = link_to admin_abuse_reports_path, title: "Abuse Reports" do %span - Spam Logs + Abuse Reports + %span.badge.count= number_with_delimiter(AbuseReport.count(:all)) - = nav_link(controller: [:application_settings, :appearances]) do - = link_to admin_application_settings_path, title: 'Settings' do - %span - Settings - .fade-right + - if askimet_enabled? + = nav_link(controller: :spam_logs) do + = link_to admin_spam_logs_path, title: "Spam Logs" do + %span + Spam Logs + .fade-right diff --git a/app/views/layouts/nav/_admin_settings.html.haml b/app/views/layouts/nav/_admin_settings.html.haml new file mode 100644 index 00000000000..38e9b80d129 --- /dev/null +++ b/app/views/layouts/nav/_admin_settings.html.haml @@ -0,0 +1,31 @@ +.controls + .dropdown.admin-settings-dropdown + %a.dropdown-new.btn.btn-default{href: '#', 'data-toggle' => 'dropdown'} + = icon('cog') + = icon('caret-down') + %ul.dropdown-menu.dropdown-menu-align-right + = nav_link(controller: :deploy_keys) do + = link_to admin_deploy_keys_path, title: 'Deploy Keys' do + %span + Deploy Keys + + = nav_link(controller: :services) do + = link_to admin_application_settings_services_path, title: 'Service Templates' do + %span + Service Templates + + = nav_link(controller: :labels) do + = link_to admin_labels_path, title: 'Labels' do + %span + Labels + + = nav_link(controller: :appearances) do + = link_to admin_appearances_path, title: 'Appearances' do + %span + Appearance + + %li.divider + = nav_link(controller: :application_settings) do + = link_to admin_application_settings_path, title: 'Settings' do + %span + Settings |