From 90a024b3840895446c04cd0be5aaeddf7dcb2c64 Mon Sep 17 00:00:00 2001 From: Rakshitha-D Date: Tue, 17 Dec 2024 18:41:59 +0530 Subject: [PATCH 1/3] #OBS-I410: updated list api to return connectors_config and version_key for draft dataset --- api-service/src/controllers/DatasetList/DatasetList.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/api-service/src/controllers/DatasetList/DatasetList.ts b/api-service/src/controllers/DatasetList/DatasetList.ts index 82acbf62..c11b3d37 100644 --- a/api-service/src/controllers/DatasetList/DatasetList.ts +++ b/api-service/src/controllers/DatasetList/DatasetList.ts @@ -12,8 +12,7 @@ export const apiId = "api.datasets.list" export const errorCode = "DATASET_LIST_FAILURE" const liveDatasetStatus = ["Live", "Retired", "Purged"] const draftDatasetStatus = ["Draft", "ReadyToPublish"] -const defaultFields = ["dataset_id", "name", "type", "status", "tags", "version", "api_version", "dataset_config", "created_date", "updated_date"] - +const defaultFields = ["dataset_id", "name", "type", "status", "tags", "version", "api_version", "dataset_config", "created_date", "updated_date", "data_schema", "validation_config", "dedup_config", "denorm_config"] const datasetList = async (req: Request, res: Response) => { const isRequestValid: Record = schemaValidation(req.body, DatasetCreate) @@ -37,7 +36,7 @@ const listDatasets = async (request: Record): Promise Date: Wed, 18 Dec 2024 10:43:56 +0530 Subject: [PATCH 2/3] #OBS-I410: added requierd fields for draft datasets --- api-service/src/controllers/DatasetList/DatasetList.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/api-service/src/controllers/DatasetList/DatasetList.ts b/api-service/src/controllers/DatasetList/DatasetList.ts index c11b3d37..986cd50e 100644 --- a/api-service/src/controllers/DatasetList/DatasetList.ts +++ b/api-service/src/controllers/DatasetList/DatasetList.ts @@ -12,7 +12,7 @@ export const apiId = "api.datasets.list" export const errorCode = "DATASET_LIST_FAILURE" const liveDatasetStatus = ["Live", "Retired", "Purged"] const draftDatasetStatus = ["Draft", "ReadyToPublish"] -const defaultFields = ["dataset_id", "name", "type", "status", "tags", "version", "api_version", "dataset_config", "created_date", "updated_date", "data_schema", "validation_config", "dedup_config", "denorm_config"] +const defaultFields = ["dataset_id", "name", "type", "status", "tags", "version", "api_version", "dataset_config", "created_date", "updated_date"] const datasetList = async (req: Request, res: Response) => { const isRequestValid: Record = schemaValidation(req.body, DatasetCreate) @@ -36,7 +36,7 @@ const listDatasets = async (request: Record): Promise Date: Wed, 18 Dec 2024 10:45:21 +0530 Subject: [PATCH 3/3] #OBS-I410: formatted --- api-service/src/controllers/DatasetList/DatasetList.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/api-service/src/controllers/DatasetList/DatasetList.ts b/api-service/src/controllers/DatasetList/DatasetList.ts index 986cd50e..6cad65dc 100644 --- a/api-service/src/controllers/DatasetList/DatasetList.ts +++ b/api-service/src/controllers/DatasetList/DatasetList.ts @@ -13,6 +13,7 @@ export const errorCode = "DATASET_LIST_FAILURE" const liveDatasetStatus = ["Live", "Retired", "Purged"] const draftDatasetStatus = ["Draft", "ReadyToPublish"] const defaultFields = ["dataset_id", "name", "type", "status", "tags", "version", "api_version", "dataset_config", "created_date", "updated_date"] + const datasetList = async (req: Request, res: Response) => { const isRequestValid: Record = schemaValidation(req.body, DatasetCreate)