cancel
Showing results for 
Search instead for 
Did you mean: 

CAP Annotation equivalent for Path="@UI.PresentationVariant#DefaultPresentationVariant"

gauravkr75
Employee
Employee

Hi,

I am trying to write annotations in CAP with reference to an Odata EDMX annotation format.

I am having trouble figuring out the below part. What will be the CAP equivalent for the below annotation?

<PropertyValue Property="PresentationVariant" Path="@UI.PresentationVariant#DefaultPresentationVariant"/>

Complete Odata EDMX Annotation for reference:

<Annotation Term="UI.SelectionPresentationVariant" Qualifier="DefaultVariant">
  <Record>
    <PropertyValue Property="Text" String="Product Financial Analysis"/>
    <PropertyValue Property="PresentationVariant" Path="@UI.PresentationVariant#DefaultPresentationVariant"/>
  </Record>
</Annotation>

Accepted Solutions (0)

Answers (2)

Answers (2)

gregorw
Active Contributor
gauravkr75
Employee
Employee
0 Kudos

Hi Gregor,

Thanks for your answer. I looked into the example you gave but I was still not able to figure out how to specify the 'Path' attribute.

Path="@UI.PresentationVariant#DefaultPresentationVariant"

When I write like below in CDS annotation:

{PresentationVariant : DefaultPresentVariant}<br>

Then in the metadata I see 'Path' attribute as:

Path="DefaultPresentVariant"

But I don't know how to add the prefix '@UI.PresentationVariant#' to the 'Path' attribute.

jhodel18
Active Contributor
0 Kudos

Hi Gaurav,

Your example annotation doesn't seem to conform with how the annotation should be done:

https://help.sap.com/viewer/468a97775123488ab3345a0c48cadd8f/7.52.1/en-US/37aeed74e17a42caa2cba3123f...

Therefore, can't really answer your question.

gauravkr75
Employee
Employee
0 Kudos

Hi Jhodel,

The annotation in the example I gave is in reference to SAP document. I am trying to develop an Analytical list page and this is needed to create an Analytical Table in the content area of ALP. You can refer to the link below. You can click on the SelectionPresentationVariant box and see the annotations which I have mentioned.

https://help.sap.com/viewer/468a97775123488ab3345a0c48cadd8f/201809.002/en-US/d074e26b013647c7a93b8a...