cancel
Showing results for 
Search instead for 
Did you mean: 

Programmatically changing/setting sort/filter in FPM ATS LIST

former_member243452
Discoverer
0 Kudos

Hi,

i am implementing a list based on FPM_LIST_UIBB_ATS.

Filter and sort work just fine, but i would like to set the filter from my feeder class or via some other interface.

Do you know if this is possibile?

I yes how?

Thanks in advance and best regards

Wolf

Accepted Solutions (0)

Answers (1)

Answers (1)

AbhishekSharma
Active Contributor
0 Kudos

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



former_member243452
Discoverer
0 Kudos

Hi Abhishek,

Thank you for your answer. No that's not what i mean.

I already have the filter and sort enabled the way you correctly describe in my list.


Now i want for example to set the filter value to Range 'A*-M*' for my column 'NAME' in my feeder class or via some interface without user intervention.


Hope this clarifies my question.

thanks

Regards

wolf

Former Member
0 Kudos

Hi Abhishek,

Good Morning!

I have been trying to get the Layout reference of List feeder class using GET_DEFAULT_CONFIG method. But even though I have implemented the method, the controller is not going through the method. As a result I am unable to find the layout reference.

But I see you have mentioned about using GET_DEFAULT_CONFIG method. Could you please let me know if I need to do changes elsewhere to use GET_DEFAULT_CONFIG method?

I have already posted on this but none replied. Sorry for posting my question in this thread.

Regards,

Yugesh A

AbhishekSharma
Active Contributor
0 Kudos

Hi Yugesh,

No problem we can check on your problem.

Please give me link where you have posted the Question initially..

And requesting you to please remove this question from here, as some other discussion is going on here, this causes confusion to other members who are involved.

Thanks-

Abhishek