Exericse: Lampant - A virtual suggestion box

2021-08-07

lampant is an SaaS web application for collecting new ideas from employees how to improve the business.

After a user has registered a new tenant in lampant, this user is assigned as an administrator for the newly created tenant. The administrator can configure a DNS domain, so that newly signed up users are automatically assigned to this tenant, if their e-mail address domain matches the tenant's configured domain.

Having finished the initial configuration, the administrator can add topics, e.g. Employee Engagement, Office, Sustainability. Each user assigned to the tenant can then add new ideas for each topic. An idea consists upon a subject and a body. For the topic Office there could be an idea Add plants to all rooms.

Other users can vote for an idea. A user can not vote for the same idea more than one time. Also, each user can write any number comments for an idea to discuss it.

Dashboard overview

Dashboard overview

Hints

  • For this exercise, you can skip the common username, password, verified_at fields for user management.
  • Modelling the Award mechanism in the screenshot above is not part of this exercise.
  • A user, identified by its email, can only be attached to one tenant.
  • We assume that multi-tenancy is modelled by having a shared schema between all tenants. Try to model the database by using only two foreign keys pointing to the tenant entity. The two tables containing the foreign keys are serving as root entity for other entities.