How a user role send a message to another user role.

Hi, iam building an app for a school, where student fills a leave application. this request needs to go to teacher and teacher needs to accept it. upon accepting his leave request, student will get  a leave approval message as popup when he login to the app. can anyone help me how to do that,its just a sample practice application, please simplify your ideas and tell me. here student and teacher are user roles.
1 answers

One of the simplest approaches would be something like:

  • Create an entity LeaveApproval
  • The Student role can only see his own LeaveApproval objects
  • The Teacher can see all LeaveApproval objects (or perhaps only those of his students)
  • LeaveApproval has a status parameter with values like: Waiting for approval, Approved, Denied.
  • The student creates an object of LeaveApproval. and it gets status Waiting for approval
  • The teacher sees in a list (maybe filtered on status in different tabs) this new object and can change the status to Approved or Denied.
  • When this change is commited, this status will be visible for the Student, and based on that status you can then think about how you want to notify this Student.


The idea of 'sending a message’ between users in an application is often just an illusion from the users perspective. From a software point of view it's often done by making the object visible to the different users based on different statuses.

As for examples, I think the basics for building your features is covered in Intermediate level (purple) Learning Paths in the Mendix Academy. If you work though those, you might get a better feeling for how to approach your challenge. It's been a while since I've done the learning paths, but maybe this one is of particular interest: Building an Event App Using Microflows