Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

@UI.presentationVariant.sortOrder is not working #38

Open
mainakaich opened this issue Jul 31, 2023 · 0 comments
Open

@UI.presentationVariant.sortOrder is not working #38

mainakaich opened this issue Jul 31, 2023 · 0 comments

Comments

@mainakaich
Copy link

In https://github.com/SAP-samples/abap-platform-rap-opensap/blob/main/week2/unit5.md, step 7, the following annotation is used

@ui: {
headerInfo: { typeName: 'Travel',
typeNamePlural: 'Travels',
title: { type: #STANDARD, label: 'Travel', value: 'TravelID' } } ,
presentationVariant: [{ sortOrder: [{ by: 'TravelID', direction: #DESC }] }] }

But this is giving following HTTP error when I am executing the fiori element preview from service binding.

{"error":{"code":"005056A509B11EE1B9A8FEA8DE87F78E","message":{"lang":"en","value":"Property desc not found in type TravelType"},"innererror":{"transactionid":"B59C0F42C9AF00D0E0064C6C73AFDC9D","timestamp":"20230731132547.3575230","Error_Resolution":{"SAP_Transaction":"For backend administrators: use ADT feed reader "SAP Gateway Error Log" or run transaction /IWFND/ERROR_LOG on SAP Gateway hub system and search for entries with the timestamp above for more details","SAP_Note":"See SAP Note 1797736 for error analysis (https://service.sap.com/sap/support/notes/1797736)"}}}}
--440328ACE08C04162E2AD8A5960092FD0--

The reason for the error is, the URL which is generated is -
GET Travel?sap-client=100&$skip=0&$top=20&$orderby=%20desc&$select=TravelId%2cAgencyId%2cAgencyName%2cCustomerId%2cCustomerName%2cBeginDate%2cEndDate%2cBookingFee%2cCurrencyCode%2cTotalPrice%2cDescription%2cTravelStatus%2cTravelUuid&$inlinecount=allpages HTTP/1.1

Here in the orderby=%20desc& is not containing the TravelID as mentioned in the @ui annotation. Could you please check and help me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant