on 03-02-2015 12:57 PM
Hi all.
I need to adapt coding to a existing Fiori App. This App has the search functionality that of course should be implemented.
Debbuging the ABAP code I can see content of IV_FILTER_STRING with value ( SearchTerm eq 'Hello World' ). URL sent by the browser is :
In the search box I just typed 'dtbes'.
Is there any class/method to directly filter et_entityset with those entries that contain word 'dtbes'?
Your help is much appreciated.
Iñigo.
Hello Garcia,
In the Get_Entity_Set method of the Data Provider Class you can read all the filter parameters and then can be sent to your backend logic as input to fetch the matching records.
There would be already code written to read filter parameters in Get_Entity_Set method. Please check.
If not below will help ->
$filter System Query Option APIs - SAP NetWeaver Gateway - SAP Library
You need to have the logic written inside Get_Entity_Set method of your Data Provider Class which filters data by taking inputs from the application.
Regards,
Ashwin
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
No, there is no utility class to do it for you.
However in your GET_ENTITYSET method, you have a parameter IT_FILTER_SELECT_OPTIONS. This gives you the corresponding select options for your filter property.
Here you get SELECT OPTIONS for every filter property. You can make use of this SELECT OPTION table to easily filter the data.
sample code would look like....
DATA: ls_filter_select_option TYPE /iwbep/s_mgw_select_option .
READ TABLE it_filter_select_options INTO ls_filter_select_option
WITH KEY property = '<PROPERTY NAME>'.
"Populate ET_ENTITYSET
..........
.................
DELETE et_entityset WHERE <PROPERTY NAME> NOT IN ls_filter_select_option-select_options.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.