Skip to Content
avatar image
Former Member

sap fiori list report selection field search help

Hi Gurus,

I have implemented SAP Fiori List Report Application using Fiori Elements. I have added Selection Fields using annotations as well and they filter the data as well. I need to implement Search Help(F4) on selection fields similar to what F4 does in Backend instead of the standard Selection Field screen. How should i do this? Any pointers will be helpful.

Thanks everyone.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Mar 23 at 07:40 PM

    Hi Vinay,

    you can try the following annotation that ann

    @Consumption.valueHelp: '_Customer' 
      Customer,
    

    where the association would point to a another CDS view that contains the list of customers you want to choose from

    Regards,

    Andre

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Andre,

      Thanks for your prompt reply. I did the same thing as you mentioned but still it doesn't work.

      I'm sure, i'm missing something somewhere.

      Please see below code.

      Data Provider View:-

      @AbapCatalog.sqlViewName: 'ZSD_VBELN_VHelp'

      @AbapCatalog.compiler.compareFilter: true

      @AccessControl.authorizationCheck: #NOT_REQUIRED

      @Search.searchable: true

      @EndUserText.label: 'Value Help for VBELN'

      define view ZSD_VBELN_ValueHelp as select from v_vbuk_invoice {

      @Search.defaultSearchElement: true

      @Search.fuzzinessThreshold: 0.8

      key vbeln }

      Consumption View:-

      @AbapCatalog.sqlViewName: 'ZSD_CUS_HIS_REP'

      @AbapCatalog.compiler.compareFilter: true

      @AccessControl.authorizationCheck: #NOT_REQUIRED

      @Search.searchable: true

      @EndUserText.label: 'Customer History Report CDS View'

      @OData.publish: true

      define view ZSD_CUS_HIS_REP_CDS as

      select from vbrk

      join vbpa on vbrk.vbeln = vbpa.vbeln

      join vbrp on vbrk.vbeln = vbrp.vbeln

      association [0..1] to zsd_vbeln_vhelp as _VbelnHelp on $projection.vbeln = _VbelnHelp.vbeln {

      @UI: { lineItem: [{position: 10}]}

      @UI.selectionField.position: 10

      @ObjectModel.mandatory: true

      @Search: {defaultSearchElement: true, fuzzinessThreshold: 0.8, ranking: #HIGH}

      @Consumption.valueHelp: '_VbelnHelp'

      @Consumption.filter.selectionType: #RANGE

      key _VbelnHelp.vbeln

      }

  • avatar image
    Former Member
    Mar 27 at 01:51 PM

    Hello Experts,

    Please help. i know i'm missing something very basic. But can't catch it since few days.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Mar 28 at 05:22 AM

    Forgot to expose the association at the end of the Select query which solved the issue.

    @UI: { lineItem: [{position: 120}]}

    @Semantics.amount c.netwr,

    @UI: { lineItem: [{position: 130}]}

    a.cmwae,

    _VbelnHelp

    }

    Add comment
    10|10000 characters needed characters exceeded