cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

CDS Annotations and labels

roger_beach
Participant
0 Likes
10,050

We have developed an SAPUI5 application relying solely on CDS Annotations to build the UI. One thing we have noticed is that when using the UI.lineItem annotation and specifically the label property, it falls a little short.

We are pulling in SNAME from IT0001, from the domain it pulls text for the column heading as "Last name First name", the same is then populated in the filter bar.

If we use the label property to change "Last name First name" to something else like "Employee Name", it replaces the text for the column heading, but then leaves the filter bar as the original. This seems like a disconnect to me.

The annotation we are using is as follows:

        @UI.lineItem: { label: 'Employee Name', position: 1, importance: #HIGH }
        @UI.selectionField: {position:1 }
        @Search: { defaultSearchElement: true, fuzzinessThreshold: 0.7 }
         EmployeeData._pa0001.sname as EmployeeName,

I don't see a label property for UI.selectionField. How can we keep these two items in sync:

Is this intended or perhaps it's been addressed in later versions? We are using ABAP 7.50 and UI5 1.52.13.

Accepted Solutions (1)

Accepted Solutions (1)

former_member412549
Participant

Hi Roger Beach,

Try using "@EndUserText.label: '<text>'" instead of "@UI.LineItem.label:'<text>'".


Thanks & Regards,

Tushar Sharma

roger_beach
Participant
0 Likes

You are correct Tushar, thank you so much.

Answers (0)