Using Auth0 user id for database

有些话、适合烂在心里 提交于 2019-12-22 12:13:40

问题


I am a newb to RoR and I tried to throughly look this through before coming here for help. I am creating a web app and am using Auth0 for user authentication. The user information is saved on the Auth0 database and that's fine...but I want to create a database on my end of the app that allows the user to favorite a list of products that can be seen only to that specific user...if I'm making any sense.

So far for the dashboard I just have the basic set up where

class DashboardController < SecuredController


def show
    @user = session[:userinfo]
  end

  def destroy
    session[:userinfo] = nil if session[:userinfo]
    redirect_to root_url
  end

end

So nothing is really being done on my end but showing basic information of the user currently logged in.

来源:https://stackoverflow.com/questions/38626438/using-auth0-user-id-for-database

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!