demarches-normaliennes/app/views/layouts/_navbar.html.haml

44 lines
2 KiB
Text
Raw Normal View History

2016-08-22 14:00:34 +02:00
#beta{class:(Rails.env == 'production' ? '' : 'beta_staging')}
- if Rails.env == 'production'
Beta
- else
Env Test
2016-06-07 15:16:35 +02:00
= image_tag('marianne_small.png', class: 'logo')
%a{href: '/'}
2016-11-03 17:29:59 +01:00
= image_tag(image_url(LOGO_NAME), class: 'logo')
2016-10-13 18:26:44 +02:00
- if gestionnaire_signed_in? && user_signed_in?
%a{href: (current_gestionnaire.procedure_filter.blank? ? backoffice_dossiers_path : backoffice_dossiers_procedure_path(current_gestionnaire.procedure_filter)), class: 'btn btn-md'}
2016-11-03 16:46:26 +01:00
=t('dynamics.backoffice.dossiers')
2016-10-13 18:26:44 +02:00
%a{href: users_dossiers_path, class: 'btn btn-md'}
2016-11-03 16:46:26 +01:00
=t('dynamics.users.mes_dossiers')
2016-10-13 18:26:44 +02:00
- elsif gestionnaire_signed_in?
%a{href: (current_gestionnaire.procedure_filter.blank? ? backoffice_dossiers_path : backoffice_dossiers_procedure_path(current_gestionnaire.procedure_filter)), class: 'btn btn-md'}
2016-11-03 16:46:26 +01:00
=t('dynamics.users.mes_dossiers')
2016-09-26 14:11:57 +02:00
- elsif user_signed_in?
2016-10-13 18:26:44 +02:00
%a{href: users_dossiers_path, class: 'btn btn-md'}
2016-11-03 16:46:26 +01:00
=t('dynamics.users.mes_dossiers')
2016-09-26 14:11:57 +02:00
- elsif administrateur_signed_in?
2016-10-13 18:26:44 +02:00
%a{href: admin_procedures_path, class: 'btn btn-md'}
2016-11-03 16:46:26 +01:00
=t('dynamics.admin.menu.title')
2016-08-22 14:00:34 +02:00
2016-06-07 15:16:35 +02:00
#sign_out
2016-10-13 18:26:44 +02:00
-if user_signed_in?
= render partial: 'users/login_banner'
-elsif gestionnaire_signed_in?
2016-06-07 15:16:35 +02:00
= render partial: 'gestionnaires/login_banner'
-elsif administrateur_signed_in?
= render partial: 'administrateurs/login_banner'
2016-10-13 18:26:44 +02:00
-else
2016-06-07 15:16:35 +02:00
= link_to "Utilisateur", '/users/sign_in', method: :get, :class => 'btn btn-md'
-unless Features.unified_login
= link_to "Accompagnateur", '/gestionnaires/sign_in', method: :get, :class => 'btn btn-md'
2016-06-07 15:16:35 +02:00
= link_to "Administrateur", '/administrateurs/sign_in', method: :get, :class => 'btn btn-md'
2016-08-22 14:00:34 +02:00
- if Rails.env != 'production'
%div.staging_warning
2016-08-22 14:15:21 +02:00
%b{style:'color: #B00100', 'data-placement' => 'bottom', 'data-original-title' => "Aucune donnée présente sur cette plateforme ne pourra être transférée sur l'environnement final de production.", 'data-toggle' => 'tooltip'}
2016-08-22 14:00:34 +02:00
Vous vous trouvez actuellement sur la plateforme de test.
%div.badge.progress-bar-danger
?