Skip to Content

Suggestion values on Fiori Elements Selection Field with CDS-View

Hello,

I'm using a CDS-View with annotations to generate an oData-Service. So I haven't a mpc_ext class to redefined the "define-method" for adding some oData-Annotations. My CDS-View contains UI.LineItem- and UI.SelectionField-Annotations. Further I have an association which I used for a valueHelp. With this oData-Service I'm able to create a List Report Application in the WebIDE. The App generates a SmartTable and a SmartFilterBar. Everything works fine.

But I've seen the SmartTable-Example on the SAPUI5-Expored page. There are suggestion values on the input field of the SmartFilterBar. I know the SmartFilterBar is interpreting the oData-Metadata and annotations.

So now my question is: How can i annotate the CDS-View to get suggestion values on a selection field in the app?

Thanks for your help.

Regards,

Beat

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Best Answer
    avatar image
    Former Member
    Apr 03 at 07:55 PM

    Hello

    it definitely depends on what kind of associated view you are using, if you require to see something like a key field and a Text then you might need to implement a so called helper View specifically for this,

    _ValueHelp_View1

    and then annotate that field with annotation below

     @Consumption.valueHelp: '_ValueHelp_View1'

    don't forget to publish that association

    BR

    Kairat Alaichiev

    Add comment
    10|10000 characters needed characters exceeded

  • Mar 08 at 12:51 PM

    Hi Beat,

    Can you point to exactly what you mean or include a screenshot ? I'm guessing you mean the default keyword search field which is controlled by the annotation DefaultSearchElement ? Or is it something else?

    Rgds

    Jocelyn

    Add comment
    10|10000 characters needed characters exceeded