Coder Social home page Coder Social logo

Comments (7)

cbrunsdon avatar cbrunsdon commented on August 14, 2024 1

For the record I've always though user should support first/last names. Only being on addresses drives me nuts.

from solidus_social.

jarednorman avatar jarednorman commented on August 14, 2024

Seems like a decent feature, though I'm not sure about what the best way to implement that would be as the only place names are currently stored is on addresses. Perhaps it might be desirable to add a hook so that developers could grab that info and store it where ever made sense in their schema?

from solidus_social.

mamhoff avatar mamhoff commented on August 14, 2024

Go for it. I personally believe first and last names are wrong in many ways (People have a name, and that's it, really), but I do understand there's a lot of use for this. 👍

from solidus_social.

Sinetheta avatar Sinetheta commented on August 14, 2024

http://www.kalzumeus.com/2010/06/17/falsehoods-programmers-believe-about-names/

from solidus_social.

braidn avatar braidn commented on August 14, 2024

Thank you all for the great feedback. I feel much like Clarke in this regard, the lack of a name of any kind (first,last,singular) on user drives me nuts. I will implement it so that if your User responds to first_name/firstname or last_name/lastname then we will save the returned info to that user.

from solidus_social.

zhuwu avatar zhuwu commented on August 14, 2024

This is my current workaround:

  1. Add the following in an initializer:

    class SolidusSocialConfig < Rails::Application
    config.after_initialize do
      Devise.omniauth_configs[:facebook]&.strategy&.merge!({ scope: 'email', info_fields: 'email,name,first_name,last_name' })
    end
    end
    

    Then, omniauth-facebook will request for first_name and last_name and you can get them in auth_hash.

  2. Override method omniauth_callback in Spree::OmniauthCallbacksController to include your own logic.

from solidus_social.

stale avatar stale commented on August 14, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

from solidus_social.

Related Issues (20)

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.