Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Calling OData V4 with $expand

DebashishDas
Active Participant
0 Kudos
403
  • SAP Managed Tags:

Hi All,

I was trying to access OData V4 service. Problem is accessing the expand level.

It's not working for $expand. Below is the code sample.

manifest.json

"models": { "": { "dataSource": "default", "preload": true, "settings": { "autoExpandSelect": true, "earlyRequests": true, "operationMode": "Server", "synchronizationMode": "None", "groupId" : "$direct", "httpHeaders": { "X-CSRF-Token":"Fetch" } } } } "models": { "": { "dataSource": "default", "preload": true, "settings": { "autoExpandSelect": true, "earlyRequests": true, "operationMode": "Server", "synchronizationMode": "None", "groupId" : "$direct", "httpHeaders": { "X-CSRF-Token":"Fetch" } } } }
view.xml <List items="{ path: '/Notifications', templateShareable: true }" > <items> <CustomListItem> <content> <VBox> <Label text="{Text}" /> <Text text="{SensitiveText}" /> </VBox> </content> </CustomListItem> </items> </List>
Till now it works fine.

When i am use expanded entity "Actions" it stops working.

<List items="{ path: '/Notifications', templateShareable: true }" > <items> <CustomListItem> <content> <VBox> <Label text="{Text}" /> <Text text="{SensitiveText}" /> <List items="{path: 'Actions', templateShareable: true }" > <items> <StandardListItem title="{ActionText}" /> </items> </List> </VBox> </content> </CustomListItem> </items> </List>

Payload

Response

Any help here.

0 REPLIES 0