Quantcast
Viewing all articles
Browse latest Browse all 8065

Re: Programmatically changing/setting sort/filter in FPM ATS LIST

Hi Wolf,

 

Yes you can set filter and sorting using Feeder class as follows:

 

In IF_FPM_GUIBB_LIST~GET_DEFINITION method of your Feeder class there is one Parameter with name ET_FIELD_DESCRIPTION which contains attributes for Sorting, Readonly, filter.

 

*--> setting table properties ex readonly, dropdown values etc
   LOOP AT srch_list_attr ASSIGNING <fs_list>.                                               "all field names from config table
     APPEND INITIAL LINE TO et_field_description ASSIGNING <fs_field_description>.              "Setting table properties
     <fs_field_description>-read_only    = abap_true.
     <fs_field_description>-allow_filter = abap_true.
     <fs_field_description>-allow_sort   = abap_true.

  EndLoop.


In Order to work this setting for Sorting and Searching you need to disable the Grouping on this List, that can be done as follows:


You can set this in IF_FPM_GUIBB_LIST~GET_DEFAULT_CONFIG method of your Feeder Class.



*--> Settings height and disabeling Grouping in grid
     io_layout_config->set_settings(
       EXPORTING
         iv_height_mode_ats = if_fpm_list_types=>cs_height_mode_ats-automatic "Setting Height of  List
         iv_allow_grouping  = '02'       "Disabled (Sorting and Searching does't work without this)
     ).


Hope this will help.


Thanks-

Abhishek




Viewing all articles
Browse latest Browse all 8065

Trending Articles