Mendix dynamic forms

Hi All, We are building a ticketing application. The ticket form varies based on the ticket type. We have submitter and operator roles where submitter would place the request and operator would be working on the tickets. When a submitter logs in he should be able to see all the tickets that he placed and when an operator logs in he should be able to see all the tickets assigned to him. Since the form is dynamic we cant hold all of the ticket information in one Ticket entity. Is there a way we can achieve this in Mendix. Please let me know. 
1 answers

Yes, I would use the role of the user to do this in combination with XPaths on the entities. So somebody with the role submitter always has the XPath to only show those tickets where the person is the owner of the ticket. Follow this learning path:

It gives you some better understading about the security of Mendix.



I would stick to the Ticket entity for all the fields that are generic to all the different tickets. But based on the Ticket type (make it an enumeration) I would create different objects for each of those types that holds the attributes for that specific ticket type. I would use a one on one association. Then you can also base on the enum do conditional visibility in the main ticket form so that it retrieves and shows the data over those associations.