How to assign different background color for badges

0
Ex: I want to create a record of a file process then i want to know the status of the file having enumerations like Created, Approved, Completed Then i created badges for the enumerations to know how many files are  Created, Approved, Completed So i want Created badge in red, Approved in cream, Completed in green here the count is trigerred by a microflow
asked
1 answers
0

You can use the dynamic class option for that. There you can write an if statement.

 

if $currentObject/status = Module.{enumname}.Completed then ‘classForCompleted’

else if $currentObject/status = Module.{enumname}.Approved then ‘classForApproved’

 

Then you add your classes (in this example ‘classForCompleted’ and ‘classForApproved’) in your main.scss or own scss file (picture) file like this:

.classForCompleted {
background-color: green;
}

.classForApproved {
background-color: cream;
}

.classForCreated {
background-color: red;
}

 

answered