FIX: catalog sort by

This commit is contained in:
Gabriel Rosa
2022-10-20 10:27:38 -03:00
parent b714f3cf36
commit 5b1eb19511
4 changed files with 13 additions and 15 deletions
+4 -6
View File
@@ -144,14 +144,10 @@ class CatalogService implements OnModuleInit {
return [customer_users, customer_roles];
}
async getAllOpenSearchDataAssets(
data: Messages.GetAllDataAssetsRequest,
metadata,
customer_id,
) {
async getAllOpenSearchDataAssets(query, metadata, customer_id) {
this.logger.info('CatalogService - getAllOpenSearchDashboard');
const { search, page, size, ...filters } = data;
const { search, page, size, sort_by, order, ...filters } = query;
const { data_assets, total } = await lastValueFrom(
this.catalogReadService.GetAllDataAssets(
@@ -159,6 +155,8 @@ class CatalogService implements OnModuleInit {
search,
page,
size,
sort_by,
order,
...filters,
},
metadata,