From 2e2424ec3fb055d34a9eda379e6f75fffcf4c27d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Chai=CC=88b=20Martinez?= Date: Tue, 12 Feb 2019 16:18:29 +0100 Subject: [PATCH 1/6] Minor html/css change --- app/assets/stylesheets/switch_menu.scss | 13 ++++++- .../_switch_devise_profile_module.html.haml | 38 +++++++------------ 2 files changed, 26 insertions(+), 25 deletions(-) diff --git a/app/assets/stylesheets/switch_menu.scss b/app/assets/stylesheets/switch_menu.scss index e9c18733c..adf6b15df 100644 --- a/app/assets/stylesheets/switch_menu.scss +++ b/app/assets/stylesheets/switch_menu.scss @@ -1,6 +1,17 @@ #switch-menu { position: fixed; - left: 10px; bottom: 10px; z-index: 300; + color:#ffffff; + list-style: none; + text-decoration : none; + padding-left: 20px; + } + +#switch-menu a, #switch-menu a:link , #switch-menu a:visited , #switch-menu a:hover { + text-decoration : none; + color:#ffffff; + +} + diff --git a/app/views/layouts/_switch_devise_profile_module.html.haml b/app/views/layouts/_switch_devise_profile_module.html.haml index 2b13779b5..e70e11ffa 100644 --- a/app/views/layouts/_switch_devise_profile_module.html.haml +++ b/app/views/layouts/_switch_devise_profile_module.html.haml @@ -1,25 +1,15 @@ - if SwitchDeviseProfileService.new(warden).multiple_devise_profile_connect? - #switch-menu.dropdown.dropup - %button.btn.btn-default.dropdown-toggle{ type: :button, 'data-toggle' => 'dropdown', 'aria-haspopup' => true, 'aria-expanded' => false } - %i.fa.fa-toggle-on - %span.caret - %ul.dropdown-menu.dropdown-menu-left - - if user_signed_in? - %li - = link_to(dossiers_path, id: :menu_item_procedure) do - %i.fa.fa-user -   - Usager - - if gestionnaire_signed_in? - %li - = link_to(gestionnaire_procedures_path) do - %i.fa.fa-user -   - Instructeur - - - if administrateur_signed_in? - %li - = link_to(admin_procedures_path) do - %i.fa.fa-user -   - Administrateur + %ul#switch-menu + %li Tester en tant que... + - if user_signed_in? + %li + = link_to(dossiers_path, id: :menu_item_procedure, title:'Aller dans votre espace usager. Vous pourrez revenir ici ensuite') do + %i.fa.fa-users +   + Usager + - if gestionnaire_signed_in? + %li + = link_to(gestionnaire_procedures_path, title:'Aller dans votre espace instructeur. Vous pourrez revenir ici ensuite.') do + %i.fa.fa-user +   + Instructeur From e29415d4013b0dceba54add5bc72f3f1bdb55440 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Chai=CC=88b=20Martinez?= Date: Wed, 20 Feb 2019 14:49:42 +0100 Subject: [PATCH 2/6] remove switch button MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Chaïb Martinez --- app/views/layouts/application_old.html.haml | 2 -- 1 file changed, 2 deletions(-) diff --git a/app/views/layouts/application_old.html.haml b/app/views/layouts/application_old.html.haml index a5a6a67b8..633e368dc 100644 --- a/app/views/layouts/application_old.html.haml +++ b/app/views/layouts/application_old.html.haml @@ -48,6 +48,4 @@ %h1 %i.fa.fa-times{ style: 'position: fixed; top: 10; right: 30; color: white;' } - = render partial: 'layouts/switch_devise_profile_module' - = render partial: 'layouts/footer', locals: { main_container_size: main_container_size } From 97fda013c0ec03a34d78c8bbd15f6df82424899a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Chai=CC=88b=20Martinez?= Date: Wed, 20 Feb 2019 14:49:56 +0100 Subject: [PATCH 3/6] Minor texte changes MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Chaïb Martinez --- app/views/layouts/_switch_devise_profile_module.html.haml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/views/layouts/_switch_devise_profile_module.html.haml b/app/views/layouts/_switch_devise_profile_module.html.haml index e70e11ffa..6cbcdbad1 100644 --- a/app/views/layouts/_switch_devise_profile_module.html.haml +++ b/app/views/layouts/_switch_devise_profile_module.html.haml @@ -1,6 +1,6 @@ - if SwitchDeviseProfileService.new(warden).multiple_devise_profile_connect? %ul#switch-menu - %li Tester en tant que... + %li Changer de rôle... - if user_signed_in? %li = link_to(dossiers_path, id: :menu_item_procedure, title:'Aller dans votre espace usager. Vous pourrez revenir ici ensuite') do @@ -12,4 +12,4 @@ = link_to(gestionnaire_procedures_path, title:'Aller dans votre espace instructeur. Vous pourrez revenir ici ensuite.') do %i.fa.fa-user   - Instructeur + Instructeur \ No newline at end of file From b532d6521ebb482cf3afef863810c743c3571ce4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Chai=CC=88b=20Martinez?= Date: Wed, 20 Feb 2019 14:50:28 +0100 Subject: [PATCH 4/6] Add switch account type layout MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Chaïb Martinez --- .../_left_panel_admin_procedurescontroller_index.html.haml | 1 + 1 file changed, 1 insertion(+) diff --git a/app/views/layouts/left_panels/_left_panel_admin_procedurescontroller_index.html.haml b/app/views/layouts/left_panels/_left_panel_admin_procedurescontroller_index.html.haml index bdf47c5e3..30c64b9bf 100644 --- a/app/views/layouts/left_panels/_left_panel_admin_procedurescontroller_index.html.haml +++ b/app/views/layouts/left_panels/_left_panel_admin_procedurescontroller_index.html.haml @@ -31,6 +31,7 @@ = current_administrateur.procedures.archivees.count .split-hr-left + = render partial: 'layouts/switch_devise_profile_module' #infos-block From 221ed952d191a008c63c489962a78a4a1641e34b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Chai=CC=88b=20Martinez?= Date: Tue, 12 Feb 2019 16:18:29 +0100 Subject: [PATCH 5/6] Redesign admin roles menu --- app/assets/stylesheets/switch_menu.scss | 16 ++++++++-------- .../_switch_devise_profile_module.html.haml | 13 ++++++------- 2 files changed, 14 insertions(+), 15 deletions(-) diff --git a/app/assets/stylesheets/switch_menu.scss b/app/assets/stylesheets/switch_menu.scss index adf6b15df..8333eef90 100644 --- a/app/assets/stylesheets/switch_menu.scss +++ b/app/assets/stylesheets/switch_menu.scss @@ -2,16 +2,16 @@ position: fixed; bottom: 10px; z-index: 300; - color:#ffffff; + color: #FFFFFF; list-style: none; - text-decoration : none; + text-decoration: none; padding-left: 20px; - } -#switch-menu a, #switch-menu a:link , #switch-menu a:visited , #switch-menu a:hover { - text-decoration : none; - color:#ffffff; - +#switch-menu a, +#switch-menu a:link, +#switch-menu a:visited, +#switch-menu a:hover { + text-decoration: none; + color: #FFFFFF; } - diff --git a/app/views/layouts/_switch_devise_profile_module.html.haml b/app/views/layouts/_switch_devise_profile_module.html.haml index 6cbcdbad1..02f2678a2 100644 --- a/app/views/layouts/_switch_devise_profile_module.html.haml +++ b/app/views/layouts/_switch_devise_profile_module.html.haml @@ -1,15 +1,14 @@ - if SwitchDeviseProfileService.new(warden).multiple_devise_profile_connect? %ul#switch-menu - %li Changer de rôle... + %li + Changer de rôle - if user_signed_in? %li - = link_to(dossiers_path, id: :menu_item_procedure, title:'Aller dans votre espace usager. Vous pourrez revenir ici ensuite') do + = link_to(dossiers_path, id: :menu_item_procedure, title: 'Aller dans votre espace usager. Vous pourrez revenir ici ensuite') do %i.fa.fa-users -   - Usager +   Usager - if gestionnaire_signed_in? %li - = link_to(gestionnaire_procedures_path, title:'Aller dans votre espace instructeur. Vous pourrez revenir ici ensuite.') do + = link_to(gestionnaire_procedures_path, title: 'Aller dans votre espace instructeur. Vous pourrez revenir ici ensuite.') do %i.fa.fa-user -   - Instructeur \ No newline at end of file +   Instructeur From 9f1c089b304b134913ad644d255bdfbf4ed0b1bf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Chai=CC=88b=20Martinez?= Date: Wed, 20 Feb 2019 14:53:19 +0100 Subject: [PATCH 6/6] Minor css changes MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Chaïb Martinez --- app/assets/stylesheets/switch_menu.scss | 1 - 1 file changed, 1 deletion(-) diff --git a/app/assets/stylesheets/switch_menu.scss b/app/assets/stylesheets/switch_menu.scss index 8333eef90..bd8e913ea 100644 --- a/app/assets/stylesheets/switch_menu.scss +++ b/app/assets/stylesheets/switch_menu.scss @@ -1,7 +1,6 @@ #switch-menu { position: fixed; bottom: 10px; - z-index: 300; color: #FFFFFF; list-style: none; text-decoration: none;