@tstdl/base 0.91.50 → 0.91.52

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (164) hide show
  1. package/ai/data-extracting.d.ts +1 -0
  2. package/ai/data-extracting.js +62 -0
  3. package/authentication/server/authentication.api-controller.js +4 -4
  4. package/cancellation/token.d.ts +1 -2
  5. package/cancellation/token.js +1 -1
  6. package/core.d.ts +1 -1
  7. package/core.js +1 -1
  8. package/document-management/api/document-management.api.d.ts +753 -0
  9. package/document-management/api/document-management.api.js +222 -0
  10. package/document-management/api/index.d.ts +1 -0
  11. package/document-management/api/index.js +1 -0
  12. package/document-management/drizzle/0000_wakeful_firebrand.sql +228 -0
  13. package/document-management/drizzle/meta/0000_snapshot.json +1538 -0
  14. package/document-management/drizzle/meta/_journal.json +13 -0
  15. package/document-management/drizzle.config.d.ts +2 -0
  16. package/document-management/drizzle.config.js +11 -0
  17. package/document-management/index.d.ts +5 -0
  18. package/document-management/index.js +5 -0
  19. package/document-management/localizations/english.d.ts +2 -0
  20. package/document-management/localizations/english.js +9 -0
  21. package/document-management/localizations/german.d.ts +2 -0
  22. package/document-management/localizations/german.js +9 -0
  23. package/document-management/localizations/index.d.ts +5 -0
  24. package/document-management/localizations/index.js +9 -0
  25. package/document-management/localizations/localization.d.ts +9 -0
  26. package/document-management/localizations/localization.js +2 -0
  27. package/document-management/models/document-category.model.d.ts +4 -0
  28. package/document-management/models/document-category.model.js +18 -0
  29. package/document-management/models/document-collection-document.model.d.ts +7 -0
  30. package/document-management/models/document-collection-document.model.js +33 -0
  31. package/document-management/models/document-collection.model.d.ts +3 -0
  32. package/document-management/models/document-collection.model.js +14 -0
  33. package/document-management/models/document-file.model.d.ts +7 -0
  34. package/document-management/models/document-file.model.js +33 -0
  35. package/document-management/models/document-property-value.model.d.ts +21 -0
  36. package/document-management/models/document-property-value.model.js +58 -0
  37. package/document-management/models/document-property.model.d.ts +11 -0
  38. package/document-management/models/document-property.model.js +30 -0
  39. package/document-management/models/document-request-collection.model.d.ts +6 -0
  40. package/document-management/models/document-request-collection.model.js +28 -0
  41. package/document-management/models/document-request-file.model.d.ts +11 -0
  42. package/document-management/models/document-request-file.model.js +56 -0
  43. package/document-management/models/document-request-template.d.ts +10 -0
  44. package/document-management/models/document-request-template.js +39 -0
  45. package/document-management/models/document-request.model.d.ts +9 -0
  46. package/document-management/models/document-request.model.js +37 -0
  47. package/document-management/models/document-requests-template.d.ts +5 -0
  48. package/document-management/models/document-requests-template.js +23 -0
  49. package/document-management/models/document-type-property.model.d.ts +6 -0
  50. package/document-management/models/document-type-property.model.js +28 -0
  51. package/document-management/models/document-type.model.d.ts +7 -0
  52. package/document-management/models/document-type.model.js +32 -0
  53. package/document-management/models/document.model.d.ts +9 -0
  54. package/document-management/models/document.model.js +44 -0
  55. package/document-management/models/index.d.ts +15 -0
  56. package/document-management/models/index.js +15 -0
  57. package/document-management/models/schemas.d.ts +33 -0
  58. package/document-management/models/schemas.js +34 -0
  59. package/document-management/models/service-models/categories-and-types.view-model.d.ts +6 -0
  60. package/document-management/models/service-models/categories-and-types.view-model.js +24 -0
  61. package/document-management/models/service-models/document-folders.view-model.d.ts +22 -0
  62. package/document-management/models/service-models/document-folders.view-model.js +56 -0
  63. package/document-management/models/service-models/document-requests-template.view-model.d.ts +8 -0
  64. package/document-management/models/service-models/document-requests-template.view-model.js +26 -0
  65. package/document-management/models/service-models/document.service-model.d.ts +262 -0
  66. package/document-management/models/service-models/document.service-model.js +50 -0
  67. package/document-management/models/service-models/document.view-model.d.ts +33 -0
  68. package/document-management/models/service-models/document.view-model.js +99 -0
  69. package/document-management/models/service-models/index.d.ts +8 -0
  70. package/document-management/models/service-models/index.js +8 -0
  71. package/document-management/models/service-models/normalized-document-collection-view.model.d.ts +73 -0
  72. package/document-management/models/service-models/normalized-document-collection-view.model.js +110 -0
  73. package/document-management/models/service-models/normalized-requests-template-data.model.d.ts +16 -0
  74. package/document-management/models/service-models/normalized-requests-template-data.model.js +13 -0
  75. package/document-management/models/service-models/stats.view-model.d.ts +6 -0
  76. package/document-management/models/service-models/stats.view-model.js +32 -0
  77. package/document-management/module.d.ts +11 -0
  78. package/document-management/module.js +27 -0
  79. package/document-management/services/document-management.service.d.ts +65 -0
  80. package/document-management/services/document-management.service.js +376 -0
  81. package/document-management/services/index.d.ts +1 -0
  82. package/document-management/services/index.js +1 -0
  83. package/examples/document-management/main.d.ts +1 -0
  84. package/examples/document-management/main.js +30 -0
  85. package/examples/orm/drizzle.config.js +2 -1
  86. package/examples/orm/schemas.d.ts +1 -1
  87. package/examples/orm/user.model.d.ts +1 -2
  88. package/examples/orm/user.model.js +0 -1
  89. package/http/server/node/node-http-server.js +5 -5
  90. package/injector/injector.d.ts +4 -1
  91. package/injector/injector.js +4 -1
  92. package/injector/interfaces.d.ts +3 -3
  93. package/json-path/json-path.d.ts +2 -0
  94. package/json-path/json-path.js +7 -0
  95. package/message-bus/message-bus.d.ts +4 -6
  96. package/orm/database-schema.d.ts +3 -0
  97. package/orm/database-schema.js +6 -2
  98. package/orm/database.d.ts +6 -0
  99. package/orm/database.js +14 -0
  100. package/orm/decorators.d.ts +25 -2
  101. package/orm/decorators.js +15 -0
  102. package/orm/drizzle/index.d.ts +1 -0
  103. package/orm/drizzle/index.js +1 -0
  104. package/orm/drizzle/schema-converter.d.ts +37 -8
  105. package/orm/drizzle/schema-converter.js +121 -40
  106. package/orm/entity.d.ts +15 -12
  107. package/orm/entity.js +24 -11
  108. package/orm/index.d.ts +3 -2
  109. package/orm/index.js +3 -2
  110. package/orm/module.d.ts +6 -0
  111. package/orm/module.js +15 -0
  112. package/orm/query-converter.d.ts +5 -0
  113. package/orm/query-converter.js +114 -0
  114. package/orm/query.d.ts +15 -13
  115. package/orm/repository.d.ts +90 -31
  116. package/orm/repository.js +357 -55
  117. package/orm/schemas/index.d.ts +3 -0
  118. package/orm/schemas/index.js +3 -0
  119. package/orm/schemas/json.d.ts +9 -0
  120. package/orm/schemas/json.js +19 -0
  121. package/orm/schemas/numeric-date.d.ts +8 -0
  122. package/orm/schemas/numeric-date.js +13 -0
  123. package/orm/schemas/timestamp.d.ts +10 -0
  124. package/orm/schemas/timestamp.js +20 -0
  125. package/orm/transaction.d.ts +29 -0
  126. package/orm/transaction.js +73 -0
  127. package/orm/types.d.ts +15 -8
  128. package/orm/types.js +3 -2
  129. package/package.json +23 -12
  130. package/{rxjs → rxjs-utils}/reject-error.d.ts +1 -1
  131. package/{rxjs → rxjs-utils}/retry-backoff.d.ts +2 -2
  132. package/{rxjs → rxjs-utils}/slow-array.d.ts +7 -7
  133. package/{rxjs → rxjs-utils}/slow-array.js +2 -2
  134. package/{rxjs → rxjs-utils}/start-with-provider.d.ts +1 -1
  135. package/{rxjs → rxjs-utils}/teardown.d.ts +1 -1
  136. package/{rxjs → rxjs-utils}/untrack.d.ts +1 -1
  137. package/schema/decorators/types.d.ts +2 -2
  138. package/schema/schemas/number.d.ts +1 -1
  139. package/signals/pipe.d.ts +1 -1
  140. package/signals/pipe.js +1 -2
  141. package/sse/server-sent-events.d.ts +54 -0
  142. package/sse/server-sent-events.js +54 -0
  143. package/types.d.ts +5 -1
  144. package/utils/comparison.d.ts +2 -1
  145. package/utils/comparison.js +4 -3
  146. package/utils/compression.d.ts +4 -4
  147. package/utils/compression.js +35 -43
  148. package/utils/object/dereference.d.ts +6 -4
  149. package/utils/object/dereference.js +20 -8
  150. package/utils/object/object.d.ts +2 -0
  151. package/utils/object/object.js +20 -0
  152. /package/{rxjs → rxjs-utils}/cast.d.ts +0 -0
  153. /package/{rxjs → rxjs-utils}/cast.js +0 -0
  154. /package/{rxjs → rxjs-utils}/index.d.ts +0 -0
  155. /package/{rxjs → rxjs-utils}/index.js +0 -0
  156. /package/{rxjs → rxjs-utils}/noop.d.ts +0 -0
  157. /package/{rxjs → rxjs-utils}/noop.js +0 -0
  158. /package/{rxjs → rxjs-utils}/reject-error.js +0 -0
  159. /package/{rxjs → rxjs-utils}/retry-backoff.js +0 -0
  160. /package/{rxjs → rxjs-utils}/start-with-provider.js +0 -0
  161. /package/{rxjs → rxjs-utils}/teardown.js +0 -0
  162. /package/{rxjs → rxjs-utils}/timing.d.ts +0 -0
  163. /package/{rxjs → rxjs-utils}/timing.js +0 -0
  164. /package/{rxjs → rxjs-utils}/untrack.js +0 -0
@@ -0,0 +1,13 @@
1
+ {
2
+ "version": "7",
3
+ "dialect": "postgresql",
4
+ "entries": [
5
+ {
6
+ "idx": 0,
7
+ "version": "7",
8
+ "when": 1735923279239,
9
+ "tag": "0000_wakeful_firebrand",
10
+ "breakpoints": true
11
+ }
12
+ ]
13
+ }
@@ -0,0 +1,2 @@
1
+ declare const _default: import("drizzle-kit").Config;
2
+ export default _default;
@@ -0,0 +1,11 @@
1
+ import { relative, resolve } from 'node:path';
2
+ import { defineConfig } from 'drizzle-kit';
3
+ export default defineConfig({
4
+ dialect: 'postgresql',
5
+ out: relative('./', resolve(__dirname, './drizzle/').replace('dist', 'source')),
6
+ schema: resolve(__dirname, './models/schemas.js'),
7
+ migrations: {
8
+ schema: 'document_management',
9
+ table: '_orm_migrations'
10
+ }
11
+ });
@@ -0,0 +1,5 @@
1
+ export * from './api/index.js';
2
+ export * from './localizations/index.js';
3
+ export * from './models/index.js';
4
+ export * from './module.js';
5
+ export * from './services/index.js';
@@ -0,0 +1,5 @@
1
+ export * from './api/index.js';
2
+ export * from './localizations/index.js';
3
+ export * from './models/index.js';
4
+ export * from './module.js';
5
+ export * from './services/index.js';
@@ -0,0 +1,2 @@
1
+ import type { DocumentManagementLocalization } from './localization.js';
2
+ export declare const english: DocumentManagementLocalization;
@@ -0,0 +1,9 @@
1
+ export const english = {
2
+ language: { name: 'English', code: 'en' },
3
+ keys: {
4
+ documentManagement: {
5
+ documentRequests: 'Dokumentenanforderungen'
6
+ }
7
+ },
8
+ enums: []
9
+ };
@@ -0,0 +1,2 @@
1
+ import type { DocumentManagementLocalization } from './localization.js';
2
+ export declare const german: DocumentManagementLocalization;
@@ -0,0 +1,9 @@
1
+ export const german = {
2
+ language: { name: 'German', code: 'de' },
3
+ keys: {
4
+ documentManagement: {
5
+ documentRequests: 'Dokumentenanforderungen'
6
+ }
7
+ },
8
+ enums: []
9
+ };
@@ -0,0 +1,5 @@
1
+ import type { DocumentManagementLocalization } from './localization.js';
2
+ export * from './english.js';
3
+ export * from './german.js';
4
+ export * from './localization.js';
5
+ export declare const documentManagementLocalizations: DocumentManagementLocalization[];
@@ -0,0 +1,9 @@
1
+ import { english } from './english.js';
2
+ import { german } from './german.js';
3
+ export * from './english.js';
4
+ export * from './german.js';
5
+ export * from './localization.js';
6
+ export const documentManagementLocalizations = [
7
+ english,
8
+ german
9
+ ];
@@ -0,0 +1,9 @@
1
+ import { type Localization, type LocalizeItem } from '../../text/localization.service.js';
2
+ export declare const documentManagementlocalizationKeys: import("../../text/localization.service.js").ProxyLocalizationKeys<{
3
+ documentRequests: LocalizeItem;
4
+ }>;
5
+ export type DocumentManagementLocalization = Localization<{
6
+ documentManagement: {
7
+ documentRequests: LocalizeItem;
8
+ };
9
+ }, []>;
@@ -0,0 +1,2 @@
1
+ import { getLocalizationKeys } from '../../text/localization.service.js';
2
+ export const documentManagementlocalizationKeys = getLocalizationKeys().documentManagement;
@@ -0,0 +1,4 @@
1
+ import { Entity } from '../../orm/entity.js';
2
+ export declare class DocumentCategory extends Entity {
3
+ label: string;
4
+ }
@@ -0,0 +1,18 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ var __metadata = (this && this.__metadata) || function (k, v) {
8
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
+ };
10
+ import { Entity } from '../../orm/entity.js';
11
+ import { StringProperty } from '../../schema/index.js';
12
+ export class DocumentCategory extends Entity {
13
+ label;
14
+ }
15
+ __decorate([
16
+ StringProperty(),
17
+ __metadata("design:type", String)
18
+ ], DocumentCategory.prototype, "label", void 0);
@@ -0,0 +1,7 @@
1
+ import { Entity } from '../../orm/entity.js';
2
+ import { Timestamp, Uuid } from '../../orm/types.js';
3
+ export declare class DocumentCollectionDocument extends Entity {
4
+ collectionId: Uuid;
5
+ documentId: Uuid;
6
+ archiveTimestamp: Timestamp | null;
7
+ }
@@ -0,0 +1,33 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ var __metadata = (this && this.__metadata) || function (k, v) {
8
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
+ };
10
+ import { References } from '../../orm/decorators.js';
11
+ import { Entity } from '../../orm/entity.js';
12
+ import { Timestamp, Uuid } from '../../orm/types.js';
13
+ import { DocumentCollection } from './document-collection.model.js';
14
+ import { Document } from './document.model.js';
15
+ export class DocumentCollectionDocument extends Entity {
16
+ collectionId;
17
+ documentId;
18
+ archiveTimestamp;
19
+ }
20
+ __decorate([
21
+ Uuid(),
22
+ References(() => DocumentCollection),
23
+ __metadata("design:type", String)
24
+ ], DocumentCollectionDocument.prototype, "collectionId", void 0);
25
+ __decorate([
26
+ Uuid(),
27
+ References(() => Document),
28
+ __metadata("design:type", String)
29
+ ], DocumentCollectionDocument.prototype, "documentId", void 0);
30
+ __decorate([
31
+ Timestamp({ nullable: true }),
32
+ __metadata("design:type", Object)
33
+ ], DocumentCollectionDocument.prototype, "archiveTimestamp", void 0);
@@ -0,0 +1,3 @@
1
+ import { Entity } from '../../orm/entity.js';
2
+ export declare class DocumentCollection extends Entity {
3
+ }
@@ -0,0 +1,14 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ import { Entity } from '../../orm/entity.js';
8
+ import { Class } from '../../schema/index.js';
9
+ let DocumentCollection = class DocumentCollection extends Entity {
10
+ };
11
+ DocumentCollection = __decorate([
12
+ Class()
13
+ ], DocumentCollection);
14
+ export { DocumentCollection };
@@ -0,0 +1,7 @@
1
+ import { Entity } from '../../orm/entity.js';
2
+ export declare class DocumentFile extends Entity {
3
+ originalFileName: string | null;
4
+ mimeType: string;
5
+ hash: string;
6
+ size: number;
7
+ }
@@ -0,0 +1,33 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ var __metadata = (this && this.__metadata) || function (k, v) {
8
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
+ };
10
+ import { Entity } from '../../orm/entity.js';
11
+ import { Integer, StringProperty } from '../../schema/index.js';
12
+ export class DocumentFile extends Entity {
13
+ originalFileName;
14
+ mimeType;
15
+ hash;
16
+ size;
17
+ }
18
+ __decorate([
19
+ StringProperty({ nullable: true }),
20
+ __metadata("design:type", Object)
21
+ ], DocumentFile.prototype, "originalFileName", void 0);
22
+ __decorate([
23
+ StringProperty(),
24
+ __metadata("design:type", String)
25
+ ], DocumentFile.prototype, "mimeType", void 0);
26
+ __decorate([
27
+ StringProperty(),
28
+ __metadata("design:type", String)
29
+ ], DocumentFile.prototype, "hash", void 0);
30
+ __decorate([
31
+ Integer(),
32
+ __metadata("design:type", Number)
33
+ ], DocumentFile.prototype, "size", void 0);
@@ -0,0 +1,21 @@
1
+ import { Entity } from '../../orm/entity.js';
2
+ import { Uuid } from '../../orm/types.js';
3
+ import { SchemaOutput } from '../../schema/index.js';
4
+ export declare abstract class DocumentPropertyValueBase extends Entity {
5
+ documentId: Uuid;
6
+ propertyId: Uuid;
7
+ }
8
+ export declare class DocumentPropertyTextValue extends DocumentPropertyValueBase {
9
+ value: string | null;
10
+ }
11
+ export declare class DocumentPropertyIntegerValue extends DocumentPropertyValueBase {
12
+ value: number | null;
13
+ }
14
+ export declare class DocumentPropertyDecimalValue extends DocumentPropertyValueBase {
15
+ value: number | null;
16
+ }
17
+ export declare class DocumentPropertyBooleanValue extends DocumentPropertyValueBase {
18
+ value: boolean | null;
19
+ }
20
+ export declare const documentPropertyValueSchema: import("../../schema/index.js").UnionSchema<[typeof DocumentPropertyTextValue, typeof DocumentPropertyIntegerValue, typeof DocumentPropertyDecimalValue, typeof DocumentPropertyBooleanValue]>;
21
+ export type DocumentPropertyValue = SchemaOutput<typeof documentPropertyValueSchema>;
@@ -0,0 +1,58 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ var __metadata = (this && this.__metadata) || function (k, v) {
8
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
+ };
10
+ import { References } from '../../orm/decorators.js';
11
+ import { Entity } from '../../orm/entity.js';
12
+ import { Uuid } from '../../orm/types.js';
13
+ import { BooleanProperty, Integer, NumberProperty, StringProperty, union } from '../../schema/index.js';
14
+ import { DocumentProperty } from './document-property.model.js';
15
+ import { Document } from './document.model.js';
16
+ export class DocumentPropertyValueBase extends Entity {
17
+ documentId;
18
+ propertyId;
19
+ }
20
+ __decorate([
21
+ Uuid(),
22
+ References(() => Document),
23
+ __metadata("design:type", String)
24
+ ], DocumentPropertyValueBase.prototype, "documentId", void 0);
25
+ __decorate([
26
+ Uuid(),
27
+ References(() => DocumentProperty),
28
+ __metadata("design:type", String)
29
+ ], DocumentPropertyValueBase.prototype, "propertyId", void 0);
30
+ export class DocumentPropertyTextValue extends DocumentPropertyValueBase {
31
+ value;
32
+ }
33
+ __decorate([
34
+ StringProperty({ nullable: true }),
35
+ __metadata("design:type", Object)
36
+ ], DocumentPropertyTextValue.prototype, "value", void 0);
37
+ export class DocumentPropertyIntegerValue extends DocumentPropertyValueBase {
38
+ value;
39
+ }
40
+ __decorate([
41
+ Integer({ nullable: true }),
42
+ __metadata("design:type", Object)
43
+ ], DocumentPropertyIntegerValue.prototype, "value", void 0);
44
+ export class DocumentPropertyDecimalValue extends DocumentPropertyValueBase {
45
+ value;
46
+ }
47
+ __decorate([
48
+ NumberProperty({ nullable: true }),
49
+ __metadata("design:type", Object)
50
+ ], DocumentPropertyDecimalValue.prototype, "value", void 0);
51
+ export class DocumentPropertyBooleanValue extends DocumentPropertyValueBase {
52
+ value;
53
+ }
54
+ __decorate([
55
+ BooleanProperty({ nullable: true }),
56
+ __metadata("design:type", Object)
57
+ ], DocumentPropertyBooleanValue.prototype, "value", void 0);
58
+ export const documentPropertyValueSchema = union(DocumentPropertyTextValue, DocumentPropertyIntegerValue, DocumentPropertyDecimalValue, DocumentPropertyBooleanValue);
@@ -0,0 +1,11 @@
1
+ import { Entity } from '../../orm/entity.js';
2
+ export declare enum DocumentPropertyDataType {
3
+ Text = 0,
4
+ Integer = 1,
5
+ Decimal = 2,
6
+ Boolean = 3
7
+ }
8
+ export declare class DocumentProperty extends Entity {
9
+ label: string;
10
+ dataType: DocumentPropertyDataType;
11
+ }
@@ -0,0 +1,30 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ var __metadata = (this && this.__metadata) || function (k, v) {
8
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
+ };
10
+ import { Entity } from '../../orm/entity.js';
11
+ import { Enumeration, StringProperty } from '../../schema/index.js';
12
+ export var DocumentPropertyDataType;
13
+ (function (DocumentPropertyDataType) {
14
+ DocumentPropertyDataType[DocumentPropertyDataType["Text"] = 0] = "Text";
15
+ DocumentPropertyDataType[DocumentPropertyDataType["Integer"] = 1] = "Integer";
16
+ DocumentPropertyDataType[DocumentPropertyDataType["Decimal"] = 2] = "Decimal";
17
+ DocumentPropertyDataType[DocumentPropertyDataType["Boolean"] = 3] = "Boolean";
18
+ })(DocumentPropertyDataType || (DocumentPropertyDataType = {}));
19
+ export class DocumentProperty extends Entity {
20
+ label;
21
+ dataType;
22
+ }
23
+ __decorate([
24
+ StringProperty(),
25
+ __metadata("design:type", String)
26
+ ], DocumentProperty.prototype, "label", void 0);
27
+ __decorate([
28
+ Enumeration(DocumentPropertyDataType),
29
+ __metadata("design:type", Number)
30
+ ], DocumentProperty.prototype, "dataType", void 0);
@@ -0,0 +1,6 @@
1
+ import { Entity } from '../../orm/entity.js';
2
+ import { Uuid } from '../../orm/types.js';
3
+ export declare class DocumentRequestCollection extends Entity {
4
+ requestId: Uuid;
5
+ collectionId: Uuid;
6
+ }
@@ -0,0 +1,28 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ var __metadata = (this && this.__metadata) || function (k, v) {
8
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
+ };
10
+ import { References } from '../../orm/decorators.js';
11
+ import { Entity } from '../../orm/entity.js';
12
+ import { Uuid } from '../../orm/types.js';
13
+ import { DocumentCollection } from './document-collection.model.js';
14
+ import { DocumentRequest } from './document-request.model.js';
15
+ export class DocumentRequestCollection extends Entity {
16
+ requestId;
17
+ collectionId;
18
+ }
19
+ __decorate([
20
+ Uuid(),
21
+ References(() => DocumentRequest),
22
+ __metadata("design:type", String)
23
+ ], DocumentRequestCollection.prototype, "requestId", void 0);
24
+ __decorate([
25
+ Uuid(),
26
+ References(() => DocumentCollection),
27
+ __metadata("design:type", String)
28
+ ], DocumentRequestCollection.prototype, "collectionId", void 0);
@@ -0,0 +1,11 @@
1
+ import { Entity } from '../../orm/entity.js';
2
+ import { Timestamp, Uuid } from '../../orm/types.js';
3
+ export declare class DocumentRequestFile extends Entity {
4
+ requestId: Uuid;
5
+ fileId: Uuid;
6
+ addition: string | null;
7
+ createdDocumentId: Uuid | null;
8
+ approval: boolean | null;
9
+ approvalComment: string | null;
10
+ approvalTimestamp: Timestamp | null;
11
+ }
@@ -0,0 +1,56 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ var __metadata = (this && this.__metadata) || function (k, v) {
8
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
+ };
10
+ import { References } from '../../orm/decorators.js';
11
+ import { Entity } from '../../orm/entity.js';
12
+ import { Timestamp, Uuid } from '../../orm/types.js';
13
+ import { BooleanProperty, StringProperty } from '../../schema/index.js';
14
+ import { DocumentFile } from './document-file.model.js';
15
+ import { DocumentRequest } from './document-request.model.js';
16
+ import { Document } from './document.model.js';
17
+ export class DocumentRequestFile extends Entity {
18
+ requestId;
19
+ fileId;
20
+ addition;
21
+ createdDocumentId;
22
+ approval;
23
+ approvalComment;
24
+ approvalTimestamp;
25
+ }
26
+ __decorate([
27
+ Uuid(),
28
+ References(() => DocumentRequest),
29
+ __metadata("design:type", String)
30
+ ], DocumentRequestFile.prototype, "requestId", void 0);
31
+ __decorate([
32
+ Uuid(),
33
+ References(() => DocumentFile),
34
+ __metadata("design:type", String)
35
+ ], DocumentRequestFile.prototype, "fileId", void 0);
36
+ __decorate([
37
+ StringProperty({ nullable: true }),
38
+ __metadata("design:type", Object)
39
+ ], DocumentRequestFile.prototype, "addition", void 0);
40
+ __decorate([
41
+ Uuid({ nullable: true }),
42
+ References(() => Document),
43
+ __metadata("design:type", Object)
44
+ ], DocumentRequestFile.prototype, "createdDocumentId", void 0);
45
+ __decorate([
46
+ BooleanProperty({ nullable: true }),
47
+ __metadata("design:type", Object)
48
+ ], DocumentRequestFile.prototype, "approval", void 0);
49
+ __decorate([
50
+ StringProperty({ nullable: true }),
51
+ __metadata("design:type", Object)
52
+ ], DocumentRequestFile.prototype, "approvalComment", void 0);
53
+ __decorate([
54
+ Timestamp({ nullable: true }),
55
+ __metadata("design:type", Object)
56
+ ], DocumentRequestFile.prototype, "approvalTimestamp", void 0);
@@ -0,0 +1,10 @@
1
+ import { Entity } from '../../orm/entity.js';
2
+ import { Uuid } from '../../orm/types.js';
3
+ import { TypedOmit } from '../../types.js';
4
+ import { DocumentRequest } from './document-request.model.js';
5
+ export declare class DocumentRequestTemplate extends Entity implements TypedOmit<DocumentRequest, 'completed'> {
6
+ requestsTemplateId: Uuid;
7
+ typeId: Uuid | null;
8
+ requiredFilesCount: number;
9
+ comment: string | null;
10
+ }
@@ -0,0 +1,39 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ var __metadata = (this && this.__metadata) || function (k, v) {
8
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
+ };
10
+ import { References } from '../../orm/decorators.js';
11
+ import { Entity } from '../../orm/entity.js';
12
+ import { Uuid } from '../../orm/types.js';
13
+ import { Integer, StringProperty } from '../../schema/index.js';
14
+ import { DocumentRequestsTemplate } from './document-requests-template.js';
15
+ import { DocumentType } from './document-type.model.js';
16
+ export class DocumentRequestTemplate extends Entity {
17
+ requestsTemplateId;
18
+ typeId;
19
+ requiredFilesCount;
20
+ comment;
21
+ }
22
+ __decorate([
23
+ Uuid(),
24
+ References(() => DocumentRequestsTemplate),
25
+ __metadata("design:type", String)
26
+ ], DocumentRequestTemplate.prototype, "requestsTemplateId", void 0);
27
+ __decorate([
28
+ Uuid({ nullable: true }),
29
+ References(() => DocumentType),
30
+ __metadata("design:type", Object)
31
+ ], DocumentRequestTemplate.prototype, "typeId", void 0);
32
+ __decorate([
33
+ Integer(),
34
+ __metadata("design:type", Number)
35
+ ], DocumentRequestTemplate.prototype, "requiredFilesCount", void 0);
36
+ __decorate([
37
+ StringProperty({ nullable: true }),
38
+ __metadata("design:type", Object)
39
+ ], DocumentRequestTemplate.prototype, "comment", void 0);
@@ -0,0 +1,9 @@
1
+ import { Entity } from '../../orm/entity.js';
2
+ import { Uuid } from '../../orm/types.js';
3
+ import { Document } from './document.model.js';
4
+ export declare class DocumentRequest extends Entity implements Pick<Document, 'typeId'> {
5
+ typeId: Uuid | null;
6
+ requiredFilesCount: number;
7
+ comment: string | null;
8
+ completed: boolean;
9
+ }
@@ -0,0 +1,37 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ var __metadata = (this && this.__metadata) || function (k, v) {
8
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
+ };
10
+ import { References } from '../../orm/decorators.js';
11
+ import { Entity } from '../../orm/entity.js';
12
+ import { Uuid } from '../../orm/types.js';
13
+ import { BooleanProperty, Integer, StringProperty } from '../../schema/index.js';
14
+ import { DocumentType } from './document-type.model.js';
15
+ export class DocumentRequest extends Entity {
16
+ typeId;
17
+ requiredFilesCount;
18
+ comment;
19
+ completed;
20
+ }
21
+ __decorate([
22
+ Uuid({ nullable: true }),
23
+ References(() => DocumentType),
24
+ __metadata("design:type", Object)
25
+ ], DocumentRequest.prototype, "typeId", void 0);
26
+ __decorate([
27
+ Integer(),
28
+ __metadata("design:type", Number)
29
+ ], DocumentRequest.prototype, "requiredFilesCount", void 0);
30
+ __decorate([
31
+ StringProperty({ nullable: true }),
32
+ __metadata("design:type", Object)
33
+ ], DocumentRequest.prototype, "comment", void 0);
34
+ __decorate([
35
+ BooleanProperty(),
36
+ __metadata("design:type", Boolean)
37
+ ], DocumentRequest.prototype, "completed", void 0);
@@ -0,0 +1,5 @@
1
+ import { Entity } from '../../orm/entity.js';
2
+ export declare class DocumentRequestsTemplate extends Entity {
3
+ label: string;
4
+ description: string | null;
5
+ }
@@ -0,0 +1,23 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ var __metadata = (this && this.__metadata) || function (k, v) {
8
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
+ };
10
+ import { Entity } from '../../orm/entity.js';
11
+ import { StringProperty } from '../../schema/index.js';
12
+ export class DocumentRequestsTemplate extends Entity {
13
+ label;
14
+ description;
15
+ }
16
+ __decorate([
17
+ StringProperty(),
18
+ __metadata("design:type", String)
19
+ ], DocumentRequestsTemplate.prototype, "label", void 0);
20
+ __decorate([
21
+ StringProperty({ nullable: true }),
22
+ __metadata("design:type", Object)
23
+ ], DocumentRequestsTemplate.prototype, "description", void 0);
@@ -0,0 +1,6 @@
1
+ import { Entity } from '../../orm/entity.js';
2
+ import { Uuid } from '../../orm/types.js';
3
+ export declare class DocumentTypeProperty extends Entity {
4
+ typeId: Uuid;
5
+ propertyId: Uuid;
6
+ }