Skip to content

Commit

Permalink
udpate custom ord content (#76)
Browse files Browse the repository at this point in the history
  • Loading branch information
zongqichen authored Oct 23, 2024
1 parent 7b1fcba commit 3b1f489
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 55 deletions.
14 changes: 7 additions & 7 deletions docs/ord.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,14 @@ Example:

```js
annotate ProcessorService with @ORD.Extensions : {
title : 'This is Processor Service title',
shortDescription: 'short description for Processor Service',
visibility : 'public',
extensible : {
supported : 'no'
}
title : 'This is Processor Service title',
industry : [
'Retail',
'Consumer Products'
],
lineOfBusiness: ['Sales'],
extensible : {supported: 'no'}
};

```

Also note that annotations like `@Core.Description` and `@description` are also read.
Expand Down
28 changes: 1 addition & 27 deletions xmpl/ord/custom.ord.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"apiResources": [
{
"partOfGroups": null,
"ordId": "sap.sample:apiResource:AdminService:v1",
"ordId": "sap.sample:apiResource:manualImplementedService:v1",
"entityTypeMappings": [
{
"entityTypeTargets": [
Expand All @@ -36,31 +36,5 @@
"supported": "yes"
}
}
],
"dataProducts": [
{
"ordId": "sap.sm:dataProduct:Supplier:v1",
"localId": "Supplier",
"title": "Supplier",
"shortDescription": "Ariba Supplier data product",
"description": "The Supplier data product offers access to all customers.",
"partOfPackage": "sap.sm:package:smDataProducts:v1",
"visibility": "public",
"releaseStatus": "active",
"version": "1.1.11",
"lastUpdate": "2024-06-20T14:04:01+01:00",
"type": "primary",
"category": "business-object",
"outputPorts": [
{
"ordId": "sap.sm:apiResource:SupplierService:v1"
}
],
"responsible": "sap:ach:CIC-DP-CO",
"entityTypes": [
"sap.odm:entityType:BusinessPartner:v1",
"sap.sm:entityType:BusinessPartner:v1"
]
}
]
}
47 changes: 26 additions & 21 deletions xmpl/srv/services.cds
Original file line number Diff line number Diff line change
@@ -1,38 +1,43 @@
using {ProcessorService,AdminService} from '@capire/incidents/srv/services';
using {
ProcessorService,
AdminService
} from '@capire/incidents/srv/services';
using from '@capire/incidents/db/schema';

namespace sap.capire.incidents;

annotate ProcessorService with @ORD.Extensions : {
annotate ProcessorService with @ORD.Extensions: {
title : 'This is Processor Service title',
shortDescription: 'short description for Processor Service',
visibility : 'public',
extensible : {
supported : 'no'
}
visibility : 'public',
extensible : {supported: 'no'}
};

@AsyncAPI.Title : 'SAP Incident Management'
@AsyncAPI.SchemaVersion : '1.0'
@AsyncAPI.Title : 'SAP Incident Management'
@AsyncAPI.SchemaVersion: '1.0'
extend service ProcessorService {
event TitleChange : {
ID : Integer;
title : String @title: 'Title';
}
event TitleChange : {
ID : Integer;
title : String @title: 'Title';
}
}

@AsyncAPI.Title : 'SAP Incident Management'
@AsyncAPI.SchemaVersion : '1.0'
@AsyncAPI.Title : 'SAP Incident Management'
@AsyncAPI.SchemaVersion: '1.0'
service LocalService {
event TitleChange2 : {
ID : Integer;
title : String @title: 'Title';
}
event TitleChange2 : {
ID : Integer;
title : String @title: 'Title';
}
}

annotate AdminService with @ORD.Extensions : {
title : 'This is Admin Service title',
shortDescription : 'short description for Admin Service'
annotate AdminService with @ORD.Extensions: {
title : 'This is Admin Service title',
industry : [
'Retail',
'Consumer Products'
],
lineOfBusiness: ['Sales']
};

annotate sap.capire.incidents.Customers with @ODM.entityName: 'Customers';
Expand Down

0 comments on commit 3b1f489

Please sign in to comment.