oak-domain 5.1.16 → 5.1.18

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 (96) hide show
  1. package/lib/base-app-domain/ActionAuth/Schema.d.ts +19 -171
  2. package/lib/base-app-domain/ActionAuth/Schema.js +2 -0
  3. package/lib/base-app-domain/ActionAuth/_baseSchema.d.ts +44 -0
  4. package/lib/base-app-domain/ActionAuth/_baseSchema.js +2 -0
  5. package/lib/base-app-domain/EntityDict.d.ts +695 -14
  6. package/lib/base-app-domain/I18n/Schema.d.ts +19 -129
  7. package/lib/base-app-domain/I18n/Schema.js +2 -0
  8. package/lib/base-app-domain/I18n/_baseSchema.d.ts +51 -0
  9. package/lib/base-app-domain/I18n/_baseSchema.js +2 -0
  10. package/lib/base-app-domain/Log/Schema.d.ts +19 -141
  11. package/lib/base-app-domain/Log/Schema.js +2 -0
  12. package/lib/base-app-domain/Log/Style.d.ts +2 -2
  13. package/lib/base-app-domain/Log/_baseSchema.d.ts +44 -0
  14. package/lib/base-app-domain/Log/_baseSchema.js +2 -0
  15. package/lib/base-app-domain/Modi/Schema.d.ts +19 -130
  16. package/lib/base-app-domain/Modi/Schema.js +2 -0
  17. package/lib/base-app-domain/Modi/Style.d.ts +2 -2
  18. package/lib/base-app-domain/Modi/_baseSchema.d.ts +61 -0
  19. package/lib/base-app-domain/Modi/_baseSchema.js +2 -0
  20. package/lib/base-app-domain/ModiEntity/Schema.d.ts +19 -367
  21. package/lib/base-app-domain/ModiEntity/Schema.js +2 -0
  22. package/lib/base-app-domain/ModiEntity/Storage.js +1 -2
  23. package/lib/base-app-domain/ModiEntity/_baseSchema.d.ts +44 -0
  24. package/lib/base-app-domain/ModiEntity/_baseSchema.js +2 -0
  25. package/lib/base-app-domain/Oper/Schema.d.ts +19 -201
  26. package/lib/base-app-domain/Oper/Schema.js +2 -0
  27. package/lib/base-app-domain/Oper/Style.d.ts +2 -2
  28. package/lib/base-app-domain/Oper/_baseSchema.d.ts +67 -0
  29. package/lib/base-app-domain/Oper/_baseSchema.js +2 -0
  30. package/lib/base-app-domain/OperEntity/Schema.d.ts +19 -367
  31. package/lib/base-app-domain/OperEntity/Schema.js +2 -0
  32. package/lib/base-app-domain/OperEntity/Storage.js +1 -2
  33. package/lib/base-app-domain/OperEntity/_baseSchema.d.ts +44 -0
  34. package/lib/base-app-domain/OperEntity/_baseSchema.js +2 -0
  35. package/lib/base-app-domain/Path/Schema.d.ts +19 -157
  36. package/lib/base-app-domain/Path/Schema.js +2 -0
  37. package/lib/base-app-domain/Path/_baseSchema.d.ts +52 -0
  38. package/lib/base-app-domain/Path/_baseSchema.js +2 -0
  39. package/lib/base-app-domain/Relation/Schema.d.ts +19 -198
  40. package/lib/base-app-domain/Relation/Schema.js +2 -0
  41. package/lib/base-app-domain/Relation/_baseSchema.d.ts +48 -0
  42. package/lib/base-app-domain/Relation/_baseSchema.js +2 -0
  43. package/lib/base-app-domain/RelationAuth/Schema.d.ts +19 -199
  44. package/lib/base-app-domain/RelationAuth/Schema.js +2 -0
  45. package/lib/base-app-domain/RelationAuth/_baseSchema.d.ts +41 -0
  46. package/lib/base-app-domain/RelationAuth/_baseSchema.js +2 -0
  47. package/lib/base-app-domain/User/Schema.d.ts +19 -222
  48. package/lib/base-app-domain/User/Schema.js +2 -0
  49. package/lib/base-app-domain/User/Style.d.ts +2 -2
  50. package/lib/base-app-domain/User/_baseSchema.d.ts +53 -0
  51. package/lib/base-app-domain/User/_baseSchema.js +2 -0
  52. package/lib/base-app-domain/UserEntityClaim/Schema.d.ts +19 -264
  53. package/lib/base-app-domain/UserEntityClaim/Schema.js +2 -0
  54. package/lib/base-app-domain/UserEntityClaim/_baseSchema.d.ts +49 -0
  55. package/lib/base-app-domain/UserEntityClaim/_baseSchema.js +2 -0
  56. package/lib/base-app-domain/UserEntityGrant/Schema.d.ts +19 -136
  57. package/lib/base-app-domain/UserEntityGrant/Schema.js +2 -0
  58. package/lib/base-app-domain/UserEntityGrant/_baseSchema.d.ts +46 -0
  59. package/lib/base-app-domain/UserEntityGrant/_baseSchema.js +2 -0
  60. package/lib/base-app-domain/UserRelation/Schema.d.ts +19 -212
  61. package/lib/base-app-domain/UserRelation/Schema.js +2 -0
  62. package/lib/base-app-domain/UserRelation/_baseSchema.d.ts +47 -0
  63. package/lib/base-app-domain/UserRelation/_baseSchema.js +2 -0
  64. package/lib/compiler/localeBuilder.d.ts +1 -0
  65. package/lib/compiler/localeBuilder.js +9 -2
  66. package/lib/compiler/schemalBuilder.d.ts +1 -0
  67. package/lib/compiler/schemalBuilder.js +1368 -186
  68. package/lib/data/i18n.d.ts +3 -0
  69. package/lib/data/i18n.js +32 -0
  70. package/lib/store/CascadeStore.d.ts +3 -3
  71. package/lib/store/CascadeStore.js +28 -27
  72. package/lib/store/RelationAuth.d.ts +1 -1
  73. package/lib/store/RelationAuth.js +6 -6
  74. package/lib/store/TriggerExecutor.js +11 -5
  75. package/lib/store/checker.js +1 -1
  76. package/lib/store/filter.d.ts +11 -11
  77. package/lib/store/filter.js +14 -8
  78. package/lib/store/modi.d.ts +2 -2
  79. package/lib/store/triggers.js +14 -14
  80. package/lib/timers/vaccum.d.ts +1 -1
  81. package/lib/types/Auth.d.ts +4 -4
  82. package/lib/types/Cluster.d.ts +1 -0
  83. package/lib/types/Configuration.d.ts +9 -0
  84. package/lib/types/Entity.d.ts +5 -1
  85. package/lib/types/EntityDesc.d.ts +1 -1
  86. package/lib/types/Exception.d.ts +26 -21
  87. package/lib/types/Exception.js +81 -71
  88. package/lib/types/Expression.d.ts +4 -1
  89. package/lib/types/Port.d.ts +1 -1
  90. package/lib/types/Trigger.d.ts +1 -1
  91. package/lib/types/Watcher.d.ts +3 -3
  92. package/lib/utils/projection.d.ts +2 -2
  93. package/lib/utils/relationPath.d.ts +4 -4
  94. package/lib/utils/relationPath.js +1 -1
  95. package/lib/utils/validator.d.ts +2 -2
  96. package/package.json +2 -2
@@ -1,171 +1,19 @@
1
- import { ForeignKey, JsonProjection } from "../../types/DataType";
2
- import { Q_DateValue, Q_NumberValue, Q_StringValue, NodeId, MakeFilter, ExprOp, ExpressionKey, JsonFilter, SubQueryPredicateMetadata } from "../../types/Demand";
3
- import { OneOf } from "../../types/Polyfill";
4
- import { FormCreateData, FormUpdateData, DeduceAggregation, Operation as OakOperation, Selection as OakSelection, MakeAction as OakMakeAction, AggregationResult, EntityShape } from "../../types/Entity";
5
- import { GenericAction } from "../../actions/action";
6
- import * as Relation from "../Relation/Schema";
7
- import * as Path from "../Path/Schema";
8
- import * as ModiEntity from "../ModiEntity/Schema";
9
- import * as OperEntity from "../OperEntity/Schema";
10
- type Actions = string[];
11
- export type OpSchema = EntityShape & {
12
- relationId?: ForeignKey<"relation"> | null;
13
- pathId: ForeignKey<"path">;
14
- deActions: Actions;
15
- };
16
- export type OpAttr = keyof OpSchema;
17
- type ModiEntity$entityAggr = "modiEntity$entity$$aggr" | "modiEntity$entity$$0$$aggr" | "modiEntity$entity$$1$$aggr" | "modiEntity$entity$$2$$aggr" | "modiEntity$entity$$3$$aggr" | "modiEntity$entity$$4$$aggr" | "modiEntity$entity$$5$$aggr" | "modiEntity$entity$$6$$aggr" | "modiEntity$entity$$7$$aggr" | "modiEntity$entity$$8$$aggr" | "modiEntity$entity$$9$$aggr";
18
- type OperEntity$entityAggr = "operEntity$entity$$aggr" | "operEntity$entity$$0$$aggr" | "operEntity$entity$$1$$aggr" | "operEntity$entity$$2$$aggr" | "operEntity$entity$$3$$aggr" | "operEntity$entity$$4$$aggr" | "operEntity$entity$$5$$aggr" | "operEntity$entity$$6$$aggr" | "operEntity$entity$$7$$aggr" | "operEntity$entity$$8$$aggr" | "operEntity$entity$$9$$aggr";
19
- export type Schema = OpSchema & {
20
- relation?: Relation.Schema | null;
21
- path: Path.Schema;
22
- modiEntity$entity?: Array<ModiEntity.Schema>;
23
- operEntity$entity?: Array<OperEntity.Schema>;
24
- } & {
25
- [A in ExpressionKey]?: any;
26
- } & {
27
- [A in ModiEntity$entityAggr]?: AggregationResult<ModiEntity.Schema>;
28
- } & {
29
- [A in OperEntity$entityAggr]?: AggregationResult<OperEntity.Schema>;
30
- };
31
- type AttrFilter = {
32
- id: Q_StringValue;
33
- $$createAt$$: Q_DateValue;
34
- $$seq$$: Q_NumberValue;
35
- $$updateAt$$: Q_DateValue;
36
- relationId: Q_StringValue;
37
- relation: Relation.Filter;
38
- pathId: Q_StringValue;
39
- path: Path.Filter;
40
- deActions: JsonFilter<Actions>;
41
- modiEntity$entity: ModiEntity.Filter & SubQueryPredicateMetadata;
42
- operEntity$entity: OperEntity.Filter & SubQueryPredicateMetadata;
43
- };
44
- export type Filter = MakeFilter<AttrFilter & ExprOp<OpAttr | string>>;
45
- export type Projection = {
46
- "#id"?: NodeId;
47
- [k: string]: any;
48
- id?: number;
49
- $$createAt$$?: number;
50
- $$updateAt$$?: number;
51
- $$seq$$?: number;
52
- relationId?: number;
53
- relation?: Relation.Projection;
54
- pathId?: number;
55
- path?: Path.Projection;
56
- deActions?: number | JsonProjection<Actions>;
57
- modiEntity$entity?: ModiEntity.Selection & {
58
- $entity: "modiEntity";
59
- };
60
- operEntity$entity?: OperEntity.Selection & {
61
- $entity: "operEntity";
62
- };
63
- } & Partial<ExprOp<OpAttr | string>> & {
64
- [A in ModiEntity$entityAggr]?: ModiEntity.Aggregation & {
65
- $entity: "modiEntity";
66
- };
67
- } & {
68
- [A in OperEntity$entityAggr]?: OperEntity.Aggregation & {
69
- $entity: "operEntity";
70
- };
71
- };
72
- type ActionAuthIdProjection = OneOf<{
73
- id: number;
74
- }>;
75
- type RelationIdProjection = OneOf<{
76
- relationId: number;
77
- }>;
78
- type PathIdProjection = OneOf<{
79
- pathId: number;
80
- }>;
81
- export type SortAttr = {
82
- id: number;
83
- } | {
84
- $$createAt$$: number;
85
- } | {
86
- $$seq$$: number;
87
- } | {
88
- $$updateAt$$: number;
89
- } | {
90
- relationId: number;
91
- } | {
92
- relation: Relation.SortAttr;
93
- } | {
94
- pathId: number;
95
- } | {
96
- path: Path.SortAttr;
97
- } | {
98
- deActions: number;
99
- } | {
100
- [k: string]: any;
101
- } | OneOf<ExprOp<OpAttr | string>>;
102
- export type SortNode = {
103
- $attr: SortAttr;
104
- $direction?: "asc" | "desc";
105
- };
106
- export type Sorter = SortNode[];
107
- export type SelectOperation<P extends Object = Projection> = OakSelection<"select", P, Filter, Sorter>;
108
- export type Selection<P extends Object = Projection> = SelectOperation<P>;
109
- export type Aggregation = DeduceAggregation<Projection, Filter, Sorter>;
110
- export type CreateOperationData = FormCreateData<Omit<OpSchema, "relationId" | "pathId">> & (({
111
- relationId?: never;
112
- relation?: Relation.CreateSingleOperation;
113
- } | {
114
- relationId: ForeignKey<"relation">;
115
- relation?: Relation.UpdateOperation;
116
- } | {
117
- relation?: never;
118
- relationId?: ForeignKey<"relation">;
119
- }) & {
120
- path?: never;
121
- pathId: ForeignKey<"path">;
122
- }) & {
123
- modiEntity$entity?: OakOperation<"create", Omit<ModiEntity.CreateOperationData, "entity" | "entityId">[]> | Array<OakOperation<"create", Omit<ModiEntity.CreateOperationData, "entity" | "entityId">>>;
124
- operEntity$entity?: OakOperation<"create", Omit<OperEntity.CreateOperationData, "entity" | "entityId">[]> | Array<OakOperation<"create", Omit<OperEntity.CreateOperationData, "entity" | "entityId">>>;
125
- };
126
- export type CreateSingleOperation = OakOperation<"create", CreateOperationData>;
127
- export type CreateMultipleOperation = OakOperation<"create", Array<CreateOperationData>>;
128
- export type CreateOperation = CreateSingleOperation | CreateMultipleOperation;
129
- export type UpdateOperationData = FormUpdateData<Omit<OpSchema, "relationId" | "pathId">> & (({
130
- relation?: Relation.CreateSingleOperation;
131
- relationId?: never;
132
- } | {
133
- relation?: Relation.UpdateOperation;
134
- relationId?: never;
135
- } | {
136
- relation?: Relation.RemoveOperation;
137
- relationId?: never;
138
- } | {
139
- relation?: never;
140
- relationId?: ForeignKey<"relation"> | null;
141
- }) & {
142
- path?: never;
143
- pathId?: ForeignKey<"path">;
144
- }) & {
145
- [k: string]: any;
146
- modiEntity$entity?: OakOperation<"create", Omit<ModiEntity.CreateOperationData, "entity" | "entityId">[]> | Array<OakOperation<"create", Omit<ModiEntity.CreateOperationData, "entity" | "entityId">>>;
147
- operEntity$entity?: OakOperation<"create", Omit<OperEntity.CreateOperationData, "entity" | "entityId">[]> | Array<OakOperation<"create", Omit<OperEntity.CreateOperationData, "entity" | "entityId">>>;
148
- };
149
- export type UpdateOperation = OakOperation<"update" | string, UpdateOperationData, Filter, Sorter>;
150
- export type RemoveOperationData = {} & (({
151
- relation?: Relation.UpdateOperation | Relation.RemoveOperation;
152
- }));
153
- export type RemoveOperation = OakOperation<"remove", RemoveOperationData, Filter, Sorter>;
154
- export type Operation = CreateOperation | UpdateOperation | RemoveOperation;
155
- export type RelationIdSubQuery = Selection<RelationIdProjection>;
156
- export type PathIdSubQuery = Selection<PathIdProjection>;
157
- export type ActionAuthIdSubQuery = Selection<ActionAuthIdProjection>;
158
- export type EntityDef = {
159
- Schema: Schema;
160
- OpSchema: OpSchema;
161
- Action: OakMakeAction<GenericAction> | string;
162
- Selection: Selection;
163
- Aggregation: Aggregation;
164
- Operation: Operation;
165
- Create: CreateOperation;
166
- Update: UpdateOperation;
167
- Remove: RemoveOperation;
168
- CreateSingle: CreateSingleOperation;
169
- CreateMulti: CreateMultipleOperation;
170
- };
171
- export {};
1
+ export * from "./_baseSchema";
2
+ import { ActionAuth } from "../EntityDict";
3
+ export type Schema = ActionAuth["Schema"];
4
+ export type Action = ActionAuth["Action"];
5
+ export type Projection = ActionAuth["Projection"];
6
+ export type Filter = ActionAuth["Filter"];
7
+ export type SortNode = ActionAuth["SortNode"];
8
+ export type Sorter = ActionAuth["Sorter"];
9
+ export type Selection = ActionAuth["Selection"];
10
+ export type Aggregation = ActionAuth["Aggregation"];
11
+ export type CreateOperationData = ActionAuth["CreateOperationData"];
12
+ export type CreateSingle = ActionAuth["CreateSingle"];
13
+ export type CreateMulti = ActionAuth["CreateMulti"];
14
+ export type Create = ActionAuth["Create"];
15
+ export type UpdateOperationData = ActionAuth["UpdateOperationData"];
16
+ export type Update = ActionAuth["Update"];
17
+ export type RemoveOperationData = ActionAuth["RemoveOperationData"];
18
+ export type Remove = ActionAuth["Remove"];
19
+ export type Operation = ActionAuth["Operation"];
@@ -1,2 +1,4 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
+ const tslib_1 = require("tslib");
4
+ tslib_1.__exportStar(require("./_baseSchema"), exports);
@@ -0,0 +1,44 @@
1
+ import { ForeignKey, JsonProjection } from "../../types/DataType";
2
+ import { Q_DateValue, Q_NumberValue, Q_StringValue, NodeId, ExprOp, ExpressionKey, JsonFilter } from "../../types/Demand";
3
+ import { MakeAction as OakMakeAction, EntityShape } from "../../types/Entity";
4
+ import { GenericAction } from "../../actions/action";
5
+ type Actions = string[];
6
+ export type OpSchema = EntityShape & {
7
+ relationId?: ForeignKey<"relation"> | null;
8
+ pathId: ForeignKey<"path">;
9
+ deActions: Actions;
10
+ } & {
11
+ [A in ExpressionKey]?: any;
12
+ };
13
+ export type OpAttr = keyof OpSchema;
14
+ export type OpFilter = {
15
+ id: Q_StringValue;
16
+ $$createAt$$: Q_DateValue;
17
+ $$seq$$: Q_NumberValue;
18
+ $$updateAt$$: Q_DateValue;
19
+ relationId: Q_StringValue;
20
+ pathId: Q_StringValue;
21
+ deActions: JsonFilter<Actions>;
22
+ } & ExprOp<OpAttr | string>;
23
+ export type OpProjection = {
24
+ "#id"?: NodeId;
25
+ [k: string]: any;
26
+ id?: number;
27
+ $$createAt$$?: number;
28
+ $$updateAt$$?: number;
29
+ $$seq$$?: number;
30
+ relationId?: number;
31
+ pathId?: number;
32
+ deActions?: number | JsonProjection<Actions>;
33
+ } & Partial<ExprOp<OpAttr | string>>;
34
+ export type OpSortAttr = Partial<{
35
+ id: number;
36
+ $$createAt$$: number;
37
+ $$seq$$: number;
38
+ $$updateAt$$: number;
39
+ deActions: number;
40
+ [k: string]: any;
41
+ } | ExprOp<OpAttr | string>>;
42
+ export type OpAction = OakMakeAction<GenericAction | string>;
43
+ export type OpUpdateAction = "update" | string;
44
+ export {};
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });