diff options
author | Ahmed Abbas <ahmad.helmy@orange.com> | 2019-11-13 11:09:25 +0200 |
---|---|---|
committer | Ahmed Abbas <ahmad.helmy@orange.com> | 2019-11-14 09:06:58 +0200 |
commit | 43bbe44b1babdcfc91ad47df2b3c6a93e525b6a6 (patch) | |
tree | 422b5ecd30206fa0004bf16942f5c7262066b5a3 /cds-ui/server/src/datasources/blueprint.datasource-template.ts | |
parent | 54eb2f2680d4f2447a4d48b612b2b83e37d90754 (diff) |
add API to list blueprints with pagination in loopback server
Issue-ID: CCSDK-1770
Signed-off-by: Ahmed Abbas <ahmad.helmy@orange.com>
Change-Id: I705135af4898db68eeddb8b67bf62fbbea6921ac
Diffstat (limited to 'cds-ui/server/src/datasources/blueprint.datasource-template.ts')
-rw-r--r-- | cds-ui/server/src/datasources/blueprint.datasource-template.ts | 41 |
1 files changed, 28 insertions, 13 deletions
diff --git a/cds-ui/server/src/datasources/blueprint.datasource-template.ts b/cds-ui/server/src/datasources/blueprint.datasource-template.ts index b0aaf01eb..914021887 100644 --- a/cds-ui/server/src/datasources/blueprint.datasource-template.ts +++ b/cds-ui/server/src/datasources/blueprint.datasource-template.ts @@ -38,21 +38,36 @@ export default { } }, - { - "template": { - "method": "GET", - "url": processorApiConfig.http.url + "/blueprint-model/meta-data/{keyword}", - "headers": { - "accepts": "application/json", - "content-type": "application/json", - "authorization": processorApiConfig.http.authToken - }, - "responsePath": "$.*" + { + "template": { + "method": "GET", + "url": processorApiConfig.http.url + "/blueprint-model/meta-data/{keyword}", + "headers": { + "accepts": "application/json", + "content-type": "application/json", + "authorization": processorApiConfig.http.authToken }, - "functions": { - "getBlueprintsByKeyword": ["keyword"] + "responsePath": "$.*" + }, + "functions": { + "getBlueprintsByKeyword": ["keyword"] - } + } + }, + { + "template": { + "method": "GET", + "url": processorApiConfig.http.url + "/blueprint-model/paged?limit={limit}&offset={offset}&sort={sort}", + "headers": { + "accepts": "application/json", + "content-type": "application/json", + "authorization": processorApiConfig.http.authToken + }, + "responsePath": "$", }, + "functions": { + "getPagedBueprints": ["limit","offset", "sort"], + } + }, ] }; |