Best practice for users
Question time: in my application, I have both customers and technicians. While technicians are simply users, customers have their own dedicated model. At some point, I need to grant customers access to view their purchase history.
Which approach is better:
Creating a user concurrently when creating a customer, with a user_id field in the customers table?
Extending the user model?
It's important to note that technicians and customers have distinct sets of data.
1 Reply
if you need the customer as a user (for auth and permissions for example), create a
user
for it
if not keep them separate