aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--app/views/errors/not_allowed.html.slim21
-rw-r--r--config/routes.rb7
2 files changed, 25 insertions, 3 deletions
diff --git a/app/views/errors/not_allowed.html.slim b/app/views/errors/not_allowed.html.slim
new file mode 100644
index 000000000..6c94328cc
--- /dev/null
+++ b/app/views/errors/not_allowed.html.slim
@@ -0,0 +1,21 @@
+/ PageHeader
+= pageheader 'bug',
+ 'Erreur 403',
+ ''
+
+.page_content
+ .container-fluid
+ .row
+ .col-lg-12
+ .alert.alert-danger
+ - if I18n.locale == :fr
+ p
+ strong = "Désolé, la page demandée la page n'est pas accessible avec votre profil utilisateur."
+
+ p = "Vous pouvez néanmoins continuer à utiliser l'application IBOO."
+
+ - else
+ p
+ strong = "You are not allowed to access the page you were looking for."
+
+ p = "You can still continue the use the IBOO application. Thank you for understanding."
diff --git a/config/routes.rb b/config/routes.rb
index 33f3961b1..12dbf0986 100644
--- a/config/routes.rb
+++ b/config/routes.rb
@@ -211,8 +211,9 @@ ChouetteIhm::Application.routes.draw do
get '/help/(*slug)' => 'help#show'
- get '/404', :to => 'errors#not_found'
- get '/422', :to => 'errors#server_error'
- get '/500', :to => 'errors#server_error'
+ get '/404', to: 'errors#not_found'
+ get '/403', to: 'errors#not_allowed'
+ get '/422', to: 'errors#server_error'
+ get '/500', to: 'errors#server_error'
end