Dynamic Color Display in page Based on Claim Status.

0
Hello Experts,   we have an entity named "Status" with a status attribute represented by an enumeration: "No Images," "Have Images," and "Submit." The status changes based on user actions: initially set to "No Images," updated to "Have Images" when an image is uploaded, and finally changed to "Submit" when the claim is submitted. Now, for the user interface, we want to display different colors in a Mendix container based on the current status of the claim. We have three distinct colors corresponding to the three statuses: "No Images," "Have Images," and "Submit." How can we achieve this dynamic color display in the Mendix container based on the status of the "Status" entity?   example image :     tried below input getting error :    
asked
2 answers
1

simply you can use dynamic class on the container based on the status attribute 

on click on upload call a nano flow to change the statues

on click on submit call another nano flow to change status

 

 

image.png

answered
0

Hello Lokesh babu Dake

 

There are multiple ways how to achieve this in Mendix, one is to duplicate your values that you want to show in different colors and use visibility based on status. 

 

image.png

 

Another way to achieve this and my preferred way is to use dynamic classes, this also helps you to maintain it better, it adapts your styling based on your status value. 

 

more info https://docs.mendix.com/refguide/common-widget-properties/

image.png

 

Hope this helps!

 

Good luck

 

answered