Search code examples
odatasapui5

Is there any way to send a filter/parameter in Client OperationMode?


Hello Stackoverflow Community,

i developed an abap program that displays roles in a tree output and now want to create a ui5 application with the same functionality. For this, i created an OData Service where the GET-Method simulates my abap program via a SUBMIT-Call and returns the output tree after then displays it using a TreeTable.

Now the problem: I am using OperationMode "Client" for my OData Service so filtering is done on the client side. My backend program needs parameters to function though. Is there a way to pass any arguments to my GET-Method while using OperationMode "Client"?

I have tried the bindRows() approach where u pass filters but this only works in "Server" OperationMode. Sadly i cant use "Server" OperationMode because it would result in having to simulate my abap program everytime the user expands a TreeTable-Node, rendering my program unuseable because of performance issues.

Hoping someone can help me on this issue and looking forward to your answers!


Solution

  • Solved this issue by sending a request in "Server"-Mode, saving the odata response to a json model and then binding said model to my treetable with "Client" operationmode.