开发者

The party model, permissions, customers and staff

开发者 https://www.devze.com 2023-04-06 05:29 出处:网络
We are using a party model for a booking application, so that customers and staff effectively share the same table in the database.

We are using a party model for a booking application, so that customers and staff effectively share the same table in the database.

Previously customers could only 'book' an appointment if they paid and if a slot was available. Now, we want to create a premium_customer type rol开发者_运维知识库e so that customers can make bookings without paying and even if there is no availability.

Does it make sense to add customers to a single security model, such as in an ACL or RBAC?

  • If so, do we introduce roles called normal_customer and premium_customer alongside our reception and duty_manager and other staff roles?
  • If not, should there be a separate security model for website users?


As I don't know all your requirements, i can't give you a definitive solution, but your Approach to create a role could be correct i many cases. However, you could also create a "Subscription", wich could have start- and end date.


yes it is fair to create another role to record premium customer

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号