You still need the custom solution anyway. Like you can't just query where user_id=? if you have multiple users logged in. Depends on your project needs, but maybe something like account is what you need. Like one user can have multiple accounts assigned to it. Then in most cases you would'nt need to care about account ids, but the user id.
Feb 7, 2023
5
Level 4
Multiple Logged In users
I have specific need to have multiple logged in users. By the term "user" I mean authenticated user through some kind of credentials (email/password, SSO, etc.). Similar to Google/Facebook but with the difference that user does not switch between users/accounts, but works with several logged in users at the same time.
I was thinking just adding second user id to the first logged session, but then will be having issues with almost everything standard like Auth::id(), pivot tables, API tokens and etc.
Has anyone had similar requirements.
Please or to participate in this conversation.