X-Git-Url: https://git.arvados.org/arvados-workbench2.git/blobdiff_plain/1a9eb2261e6030ba78078e2a206bad27653f2475..c952afae1af2fb31b68be04f70bd7ae6f9d52aba:/src/models/collection.ts diff --git a/src/models/collection.ts b/src/models/collection.ts index 316b1fac..3effe672 100644 --- a/src/models/collection.ts +++ b/src/models/collection.ts @@ -2,7 +2,38 @@ // // SPDX-License-Identifier: AGPL-3.0 -import { Resource } from "./resource"; +import { + ResourceKind, + TrashableResource, + ResourceWithProperties +} from "./resource"; -export interface Collection extends Resource { +export interface CollectionResource extends TrashableResource, ResourceWithProperties { + kind: ResourceKind.COLLECTION; + name: string; + description: string; + portableDataHash: string; + manifestText: string; + replicationDesired: number; + replicationConfirmed: number; + replicationConfirmedAt: string; + storageClassesDesired: string[]; + storageClassesConfirmed: string[]; + storageClassesConfirmedAt: string; + currentVersionUuid: string; + version: number; + preserveVersion: boolean; + unsignedManifestText?: string; + fileCount: number; + fileSizeTotal: number; +} + +export const getCollectionUrl = (uuid: string) => { + return `/collections/${uuid}`; +}; + +export enum CollectionType { + GENERAL = 'nil', + OUTPUT = 'output', + LOG = 'log', }