Has anyone used AppMaster to create a web app which allows for multi tenant user sign ups, registration and authentication.
I am trying to establish a web app which allows companies to register, those companies will then have both managers and employees. Employees and Managers will belong to a Company. The web app will allow for multipl companies to register.
Just wondering if anyone in the community has enabled something like this on AppMaster? Are there any tutorials or courses that are recommended?
Hey Hubcrate,
Many projects are built with multitenancy concept using AppMaster (every SaaS solution at least).
General steps are:
- Create a separate data model to track tenant (e.g. Company)
- Create relation Company has many Users (standard model)
- Create custom BP to get current company ID (for convenience, we usually create something like Get Current User/Company to get all contextual data with each request)
In your data schema should be a clear relation of any data model to company (sometimes using direct relation, sometimes indirect via other models). With every DB request make sure that you include current company ID as a filter.
No rocket science required in most cases, unless you need something very unusual or custom like to have fully custom login screens for each tenant etc.
P.S. Multitenancy is about how your backend needs to be designed, not web app (frontend).
Thanks so much Oleg. Really appreciate this.