Giter Site home page Giter Site logo

Comments (5)

cmaxw avatar cmaxw commented on August 30, 2024 1

Yeah, I pulled all that stuff out and changed everything back to match the engine except the look/feel. That fixed it.

Set up a UserProfile class to manage that other stuff.

from action_auth.

kobaltz avatar kobaltz commented on August 30, 2024

ActionAuth::User isn't a great place to store additional attributes. However, if you wanted to do this, you would need to override the controller's user_params method found in app/controllers/action_auth/registrations_controller.rb.

It may be better to have a "wizard" style of sign up, where you can sign up the user then get the user's first_name, last_name, etc in a turbo_frame_tag. We may need a PR for a configurable option of redirect_after_signup to handle this without overriding the controllers.

from action_auth.

kobaltz avatar kobaltz commented on August 30, 2024

Alternatively and a perhaps easier method is having an "Additional Attributes" model (like UserSetting) that will store the first_name, last_name, etc. In your application_controller, you could check if the User is signed in and if they have finished setting up their profile. If they have not, then redirect to their edit user settings page.

from action_auth.

cmaxw avatar cmaxw commented on August 30, 2024

I tried overriding the controller in the main Rails application and only overriding the private method for user_params caused it to tell me that it couldn't find the method for the create action.

I'll back out the extra parameters, but I'm still getting the unpermitted params on :authenticity_token and :button. I'll post where I end up and see if there's something else we can do to make it work.

from action_auth.

kobaltz avatar kobaltz commented on August 30, 2024

I put together a sample application which adds in Action Auth and then a model for User Settings. This should help you compare what's working with this branch and your code base. In this example, I also added a check in the ApplicationController to see if the user has updated their user settings already and if not then it takes them to this page.

https://github.com/kobaltz/action_auth_example

from action_auth.

Related Issues (2)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.