Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Authentication for Restaurant Owners and Staff

The first release of our app uses the Owner model to sign in to the app. Each restaurant belongs to one owner. Then after a few months, there is an owner that has many restaurants/branches So there is a “Restaurant Group” model to handle many restaurants a Restaurant Group has many restaurants After a few years, there was a case where a restaurant had many staffs, and they wanted to give some scope for each staff account to limit application access, so we created a new model called “Staff.” a Staff has many restaurants, and a restaurant has many staffs So, for now, we should use the Staff model instead of the Owner and Restaurant Group model to maintain app compatibility. We should mark it as deprecated.