diff --git a/src/client/dd-hub-react/src/_mock/_data.ts b/src/client/dd-hub-react/src/_mock/_data.ts index 6ba6589..c48a0e6 100644 --- a/src/client/dd-hub-react/src/_mock/_data.ts +++ b/src/client/dd-hub-react/src/_mock/_data.ts @@ -1,3 +1,5 @@ + +import { Doc } from 'src/api/document-service'; import { Product } from 'src/api/product-service'; import { Filter } from 'src/api/attribute-service'; @@ -212,6 +214,8 @@ export const _notifications = [ }, ]; +// ---------------------------------------------------------------------- + export const _products: Product[] = [ { id: '1', @@ -225,6 +229,8 @@ export const _products: Product[] = [ } ]; +// ---------------------------------------------------------------------- + export const _filters: Filter[] = [ { id: 1, label: 'Rechnungsnummer', name: 'invoiceNumber', type: 'VARCHAR' }, { id: 2, label: 'Kundenname', name: 'customerName', type: 'INTEGER' }, @@ -238,4 +244,34 @@ export const _filters: Filter[] = [ { id: 10, label: 'Erstellungsdatum', name: 'createdAt', type: 'DATE' }, { id: 11, label: 'Lieferzeit', name: 'deliveryTime', type: 'TIME' }, { id: 12, label: 'Letzte Aktualisierung', name: 'lastUpdated', type: 'DATETIME' } +]; + +// ---------------------------------------------------------------------- + +export const documents: Doc[] = [ + { + id: 1, + name: "example1.pdf", + data: new Uint8Array([37, 80, 68, 70, 45]) + }, + { + id: 2, + name: "example2.pdf", + data: new Uint8Array([37, 80, 68, 70, 45, 49, 46]) + }, + { + id: 3, + name: "document1.docx", + data: new Uint8Array([80, 75, 3, 4, 20]) + }, + { + id: 4, + name: "spreadsheet1.xlsx", + data: new Uint8Array([80, 75, 3, 4, 20]) + }, + { + id: 5, + name: "report.docx", + data: new Uint8Array([80, 75, 3, 4, 20, 0, 6]) + }, ]; \ No newline at end of file diff --git a/src/client/dd-hub-react/src/api/document-service.ts b/src/client/dd-hub-react/src/api/document-service.ts new file mode 100644 index 0000000..9d65c33 --- /dev/null +++ b/src/client/dd-hub-react/src/api/document-service.ts @@ -0,0 +1,5 @@ +export type Doc = { + id: number, + name: string, + data: Uint8Array +} \ No newline at end of file