<%= notice %>
<% end %> - <%= render @user %> +diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index cd7f6aa..35d6731 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -1,3 +1,17 @@ class ApplicationController < ActionController::Base - before_action :authenticate_user! + before_action :authenticate_user! + before_action :configure_permitted_parameters, if: :devise_controller? + + protected + + def configure_permitted_parameters + devise_parameter_sanitizer.permit(:sign_up, keys: [:display_name]) + devise_parameter_sanitizer.permit(:account_update, keys: [:display_name]) + end + + # Uncomment for redirect after login + def after_sign_in_path_for(resource) + # return the path based on resource + '/checks' + end end diff --git a/app/views/devise/registrations/edit.html.erb b/app/views/devise/registrations/edit.html.erb index 38d95b8..9dbfd07 100644 --- a/app/views/devise/registrations/edit.html.erb +++ b/app/views/devise/registrations/edit.html.erb @@ -1,43 +1,181 @@ -
Currently waiting confirmation for: <%= resource.email %>
+ <% end %> ++ This information will be displayed publicly so be careful what you share. +
++ <%= @minimum_password_length %> characters minimum +
+ <% end %> +Unhappy? <%= button_to "Cancel my account", registration_path(resource_name), data: { confirm: "Are you sure?" }, method: :delete %>
- -<%= link_to "Back", :back %> diff --git a/app/views/devise/shared/_error_messages.html.erb b/app/views/devise/shared/_error_messages.html.erb index ba7ab88..db34382 100644 --- a/app/views/devise/shared/_error_messages.html.erb +++ b/app/views/devise/shared/_error_messages.html.erb @@ -1,15 +1,31 @@ <% if resource.errors.any? %> -<%= notice %>
<% end %> - <%= render @user %> +