There are several methods to visualize your data in a list report and on an object page.
We will look at the annotations for criticality and rating indicator and progress bar.
Criticality can be used in any data field displayed on a list report and an object page. It also works with other annotations with DataField as datatype like UI.fieldGroup and UI.Identification.
If you are using local annotation, criticality is an optional attribute for DataField, you can either set it to a static value or reference it to a property.
Steps to use criticality in list report by writing CDS view are:
Rating Indicator and Progress Bar
For rating and progress data, you can use the rating indicator and the progress bar.
To use those controls, set your @UI.lineItem (also apply to @UI.fieldGroup , @UI.identification, and other annotations refer to a DataField) to the type of #AS_DATAPOINT. Then, add a @UI.dataPoint annotation and set visualization property to @RATING or #PROGRESS.
By default, the rating indicator has five stars and the progress bar is set to 100 as the target. You can customize those further by setting the value of the targetValue property.