mirror of
https://github.com/datahub-project/datahub.git
synced 2025-08-22 16:18:10 +00:00
14 lines
612 B
TypeScript
14 lines
612 B
TypeScript
import { IFunctionRouteHandler } from '@datahub/utils/types/vendor/ember-cli-mirage-deprecated';
|
|
import { IMirageDatasetCoreSchema } from '@datahub/entities/types/vendor/mirage-for-datasets';
|
|
import { IDataPlatform } from '@datahub/metadata-types/types/entity/dataset/platform';
|
|
|
|
/**
|
|
* This handler is used by the mirage route config to handle the get request for dataset compliance data types
|
|
*/
|
|
export const getDataPlatforms = function(
|
|
this: IFunctionRouteHandler,
|
|
schema: IMirageDatasetCoreSchema
|
|
): { platforms: Array<IDataPlatform> } {
|
|
return { platforms: this.serialize(schema.db.platforms) };
|
|
};
|