cancel
Showing results for 
Search instead for 
Did you mean: 

Multiple search criteria via picklist in WEB UI

0 Kudos
173

Hello ABAPers,

I have created search view via custom component, which is called in popup. Now, in my search criteria there is a attribute that I want to display multiple times (STATUS_COMMON from BTQSrvCon):

I was able to multiply lines by redifining SET_PARAMETER_COLLECTION( ) of search context node class using add_selection_param( ) of cl_crm_bol_dquery_service class:

    data:
      lr_qsearch type ref to cl_crm_bol_dquery_service,
      lr_qsearch_params_col         type ref to if_bol_bo_col.


    lr_qsearch ?= me->collection_wrapper->get_current( ).
    lr_qsearch_params_col ?= lr_qsearch->get_selection_params( ).

      lr_qsearch->add_selection_param(
        exporting
          iv_attr_name = 'STATUS_COMMON'
          iv_sign      = 'I'
          iv_option    = 'EQ'
          iv_low       = 'DVSM'
      ).
      lr_qsearch->add_selection_param(
        exporting
          iv_attr_name = 'STATUS_COMMON'
          iv_sign      = 'I'
          iv_option    = 'EQ'
          iv_low       = 'ZSJD'
      ).
      lr_qsearch->add_selection_param(
        exporting
          iv_attr_name = 'STATUS_COMMON'
          iv_sign      = 'I'
          iv_option    = 'EQ'
          iv_low       = 'ZNAV'
      ).
      lr_qsearch->add_selection_param(
        exporting
          iv_attr_name = 'STATUS_COMMON'
          iv_sign      = 'I'
          iv_option    = 'EQ'
          iv_low       = 'DPSM'
      ).

Now I would like to preset each of these lines to certain different value, but sadly, I am unable to do so. Even though I have inputed different values to low, it seems to me they get ignored and WEBUI simply dispaly picklist descripton as it is. Can you guide me how to set those values during initial display. Or is my enhancement of SET_PARAMETER_COLLECTION( ) completely wrong?

Thanks in advandce,

Jakub

Accepted Solutions (0)

Answers (1)

Answers (1)

0 Kudos

Solved,

key values in descripton object were in lower case. After adding them in lower case, default value displayed correctly for each line.

      lr_qsearch->add_selection_param(
        exporting
          iv_attr_name = 'STATUS_COMMON'
          iv_sign      = 'I'
          iv_option    = 'EQ'
          iv_low       = 'dvsm'
      ).
      lr_qsearch->add_selection_param(
        exporting
          iv_attr_name = 'STATUS_COMMON'
          iv_sign      = 'I'
          iv_option    = 'EQ'
          iv_low       = 'zsjd'
      ).
      lr_qsearch->add_selection_param(
        exporting
          iv_attr_name = 'STATUS_COMMON'
          iv_sign      = 'I'
          iv_option    = 'EQ'
          iv_low       = 'znav'
      ).
      lr_qsearch->add_selection_param(
        exporting
          iv_attr_name = 'STATUS_COMMON'
          iv_sign      = 'I'
          iv_option    = 'EQ'
          iv_low       = 'dpsm'
      ).