Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
27pchrisl committed Mar 22, 2024
1 parent 625ada9 commit b4aad37
Show file tree
Hide file tree
Showing 3 changed files with 392 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
<Schema xmlns="http://docs.oasis-open.org/odata/ns/edm" Namespace="com.example.odata">
<EntityContainer Name="DefaultContainer">
<EntitySet Name="Users" EntityType="com.example.odata.User">
<NavigationPropertyBinding Path="orders" Target="Orders"/>
<Annotation Term="Org.OData.Capabilities.V1.CountRestrictions">
<Record>
<PropertyValue Property="Countable" Bool="true"/>
Expand Down Expand Up @@ -73,6 +74,7 @@
</EntitySet>
<FunctionImport Name="function1" Function="com.example.odata.function1"/>
<EntitySet Name="Orders" EntityType="com.example.odata.Order">
<NavigationPropertyBinding Path="user" Target="Users"/>
<Annotation Term="Org.OData.Capabilities.V1.CountRestrictions">
<Record>
<PropertyValue Property="Countable" Bool="true"/>
Expand Down Expand Up @@ -143,6 +145,7 @@
<Property Name="id" Type="Edm.Int64" Nullable="false">
<Annotation Term="Org.OData.Core.V1.Computed" Bool="true"/>
</Property>
<NavigationProperty Name="orders" Type="Collection(com.example.odata.Order)" Nullable="true"/>
</EntityType>
<EntityType Name="Order">
<Key>
Expand All @@ -151,6 +154,7 @@
<Property Name="id" Type="Edm.Int64" Nullable="false">
<Annotation Term="Org.OData.Core.V1.Computed" Bool="true"/>
</Property>
<NavigationProperty Name="user" Type="com.example.odata.User" Nullable="true"/>
</EntityType>
<Function Name="function1" IsBound="false">
<Parameter Name="param" Type="Edm.String" Nullable="false"/>
Expand Down
16 changes: 16 additions & 0 deletions tests/__snapshots__/Operation/MultiModelTest__test_multi__3.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@
"$Kind": "EntityContainer",
"Users": {
"$EntityType": "com.example.odata.User",
"$NavigationPropertyBinding": {
"orders": "Orders"
},
"@Org.OData.Capabilities.V1.CountRestrictions": {
"Countable": true
},
Expand Down Expand Up @@ -65,6 +68,9 @@
},
"Orders": {
"$EntityType": "com.example.odata.Order",
"$NavigationPropertyBinding": {
"user": "Users"
},
"@Org.OData.Capabilities.V1.CountRestrictions": {
"Countable": true
},
Expand Down Expand Up @@ -154,6 +160,11 @@
"$Type": "Edm.Int64",
"$Nullable": false,
"@Org.OData.Core.V1.Computed": true
},
"orders": {
"$Collection": true,
"$Type": "com.example.odata.Order",
"$Nullable": true
}
},
"Order": {
Expand All @@ -165,6 +176,11 @@
"$Type": "Edm.Int64",
"$Nullable": false,
"@Org.OData.Core.V1.Computed": true
},
"user": {
"$Collection": false,
"$Type": "com.example.odata.User",
"$Nullable": true
}
},
"function1": {
Expand Down
Loading

0 comments on commit b4aad37

Please sign in to comment.