cancel
Showing results for 
Search instead for 
Did you mean: 

Issue with annotation SemanticObjectMappingType

Kishore
Participant
0 Kudos
841

Hello,

I am building a Fiori Elements List Report. I have two columns (Customer and Payer) and I am using the DataFieldWithIntentBasedNavigation to navigate to factsheet Customer-displayFactSheet

I am using the mapping property with record type "SemanticObjectMappingType" of this annotation to map my field "Payer" to the semantic object property "Customer". But the navigation is always redirecting with Customer value instead of Payer value.

I have followed as mentioned in the link.

Here is my annotations. I used both the ways but its not working as expected.

Any pointers is of much helpful.

Option 1: Adding the Collection at the field level

<Record Type="UI.DataFieldWithIntentBasedNavigation">
    <PropertyValue Property="SemanticObject" String="Customer" />
    <PropertyValue Property="Value" Path="Customer" />
    <PropertyValue Property="Action" String="displayFactSheet" />
</Record>
<Record Type="UI.DataFieldWithIntentBasedNavigation">
       <PropertyValue Property="SemanticObject" String="Customer" />
       <PropertyValue Property="Value" Path="Payer" />
       <PropertyValue Property="Action" String="displayFactSheet" />
       <PropertyValue Property="Mapping">
           <Collection>
               <Record Type="Common.SemanticObjectMappingType">
       		     <PropertyValue Property="LocalProperty" PropertyPath="Payer" />
                     <PropertyValue Property="SemanticObjectProperty" String="Customer" />
 	       </Record>
    	   </Collection>
       </PropertyValue>
</Record>

Option: 2

<Annotations Target="ZSalesOrderManage/SoldToParty">
    <Annotation Term="Common.SemanticObjectMapping">
        <Collection>
            <Record Type="Common.SemanticObjectMappingType">
                <PropertyValue Property="LocalProperty" PropertyPath="Payer"/>
                <PropertyValue Property="SemanticObjectProperty" String="Customer"/>
            </Record>
        </Collection>
    </Annotation>
</Annotations>


<Record Type="UI.DataFieldWithIntentBasedNavigation">
       <PropertyValue Property="SemanticObject" String="Customer" />
       <PropertyValue Property="Value" Path="Payer" />
       <PropertyValue Property="Action" String="displayFactSheet" />
       <PropertyValue Property="Mapping">
           <Path>/Payer/@Common.SemanticObjectMappingType</Path>
       </PropertyValue>
</Record
View Entire Topic
Kishore
Participant

Added the annotation at the property level

<Annotations Target="ZSRV.SalesOrderHeader/Payer">
                <Annotation Term="Common.Text" Path="PayerName" />
                <Annotation Term="Common.SemanticObject" String="Customer" />
                <Annotation Term="Common.SemanticObjectMapping">
                    <Collection>
                        <Record Type="Common.SemanticObjectMappingType">
                            <PropertyValue Property="LocalProperty" PropertyPath="Payer" />
                            <PropertyValue Property="SemanticObjectProperty" String="Customer" />
                        </Record>
                    </Collection>
                </Annotation>
            </Annotations>