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.
- package/lib/base-app-domain/ActionAuth/Schema.d.ts +19 -171
- package/lib/base-app-domain/ActionAuth/Schema.js +2 -0
- package/lib/base-app-domain/ActionAuth/_baseSchema.d.ts +44 -0
- package/lib/base-app-domain/ActionAuth/_baseSchema.js +2 -0
- package/lib/base-app-domain/EntityDict.d.ts +695 -14
- package/lib/base-app-domain/I18n/Schema.d.ts +19 -129
- package/lib/base-app-domain/I18n/Schema.js +2 -0
- package/lib/base-app-domain/I18n/_baseSchema.d.ts +51 -0
- package/lib/base-app-domain/I18n/_baseSchema.js +2 -0
- package/lib/base-app-domain/Log/Schema.d.ts +19 -141
- package/lib/base-app-domain/Log/Schema.js +2 -0
- package/lib/base-app-domain/Log/Style.d.ts +2 -2
- package/lib/base-app-domain/Log/_baseSchema.d.ts +44 -0
- package/lib/base-app-domain/Log/_baseSchema.js +2 -0
- package/lib/base-app-domain/Modi/Schema.d.ts +19 -130
- package/lib/base-app-domain/Modi/Schema.js +2 -0
- package/lib/base-app-domain/Modi/Style.d.ts +2 -2
- package/lib/base-app-domain/Modi/_baseSchema.d.ts +61 -0
- package/lib/base-app-domain/Modi/_baseSchema.js +2 -0
- package/lib/base-app-domain/ModiEntity/Schema.d.ts +19 -367
- package/lib/base-app-domain/ModiEntity/Schema.js +2 -0
- package/lib/base-app-domain/ModiEntity/Storage.js +1 -2
- package/lib/base-app-domain/ModiEntity/_baseSchema.d.ts +44 -0
- package/lib/base-app-domain/ModiEntity/_baseSchema.js +2 -0
- package/lib/base-app-domain/Oper/Schema.d.ts +19 -201
- package/lib/base-app-domain/Oper/Schema.js +2 -0
- package/lib/base-app-domain/Oper/Style.d.ts +2 -2
- package/lib/base-app-domain/Oper/_baseSchema.d.ts +67 -0
- package/lib/base-app-domain/Oper/_baseSchema.js +2 -0
- package/lib/base-app-domain/OperEntity/Schema.d.ts +19 -367
- package/lib/base-app-domain/OperEntity/Schema.js +2 -0
- package/lib/base-app-domain/OperEntity/Storage.js +1 -2
- package/lib/base-app-domain/OperEntity/_baseSchema.d.ts +44 -0
- package/lib/base-app-domain/OperEntity/_baseSchema.js +2 -0
- package/lib/base-app-domain/Path/Schema.d.ts +19 -157
- package/lib/base-app-domain/Path/Schema.js +2 -0
- package/lib/base-app-domain/Path/_baseSchema.d.ts +52 -0
- package/lib/base-app-domain/Path/_baseSchema.js +2 -0
- package/lib/base-app-domain/Relation/Schema.d.ts +19 -198
- package/lib/base-app-domain/Relation/Schema.js +2 -0
- package/lib/base-app-domain/Relation/_baseSchema.d.ts +48 -0
- package/lib/base-app-domain/Relation/_baseSchema.js +2 -0
- package/lib/base-app-domain/RelationAuth/Schema.d.ts +19 -199
- package/lib/base-app-domain/RelationAuth/Schema.js +2 -0
- package/lib/base-app-domain/RelationAuth/_baseSchema.d.ts +41 -0
- package/lib/base-app-domain/RelationAuth/_baseSchema.js +2 -0
- package/lib/base-app-domain/User/Schema.d.ts +19 -222
- package/lib/base-app-domain/User/Schema.js +2 -0
- package/lib/base-app-domain/User/Style.d.ts +2 -2
- package/lib/base-app-domain/User/_baseSchema.d.ts +53 -0
- package/lib/base-app-domain/User/_baseSchema.js +2 -0
- package/lib/base-app-domain/UserEntityClaim/Schema.d.ts +19 -264
- package/lib/base-app-domain/UserEntityClaim/Schema.js +2 -0
- package/lib/base-app-domain/UserEntityClaim/_baseSchema.d.ts +49 -0
- package/lib/base-app-domain/UserEntityClaim/_baseSchema.js +2 -0
- package/lib/base-app-domain/UserEntityGrant/Schema.d.ts +19 -136
- package/lib/base-app-domain/UserEntityGrant/Schema.js +2 -0
- package/lib/base-app-domain/UserEntityGrant/_baseSchema.d.ts +46 -0
- package/lib/base-app-domain/UserEntityGrant/_baseSchema.js +2 -0
- package/lib/base-app-domain/UserRelation/Schema.d.ts +19 -212
- package/lib/base-app-domain/UserRelation/Schema.js +2 -0
- package/lib/base-app-domain/UserRelation/_baseSchema.d.ts +47 -0
- package/lib/base-app-domain/UserRelation/_baseSchema.js +2 -0
- package/lib/compiler/localeBuilder.d.ts +1 -0
- package/lib/compiler/localeBuilder.js +9 -2
- package/lib/compiler/schemalBuilder.d.ts +1 -0
- package/lib/compiler/schemalBuilder.js +1368 -186
- package/lib/data/i18n.d.ts +3 -0
- package/lib/data/i18n.js +32 -0
- package/lib/store/CascadeStore.d.ts +3 -3
- package/lib/store/CascadeStore.js +28 -27
- package/lib/store/RelationAuth.d.ts +1 -1
- package/lib/store/RelationAuth.js +6 -6
- package/lib/store/TriggerExecutor.js +11 -5
- package/lib/store/checker.js +1 -1
- package/lib/store/filter.d.ts +11 -11
- package/lib/store/filter.js +14 -8
- package/lib/store/modi.d.ts +2 -2
- package/lib/store/triggers.js +14 -14
- package/lib/timers/vaccum.d.ts +1 -1
- package/lib/types/Auth.d.ts +4 -4
- package/lib/types/Cluster.d.ts +1 -0
- package/lib/types/Configuration.d.ts +9 -0
- package/lib/types/Entity.d.ts +5 -1
- package/lib/types/EntityDesc.d.ts +1 -1
- package/lib/types/Exception.d.ts +26 -21
- package/lib/types/Exception.js +81 -71
- package/lib/types/Expression.d.ts +4 -1
- package/lib/types/Port.d.ts +1 -1
- package/lib/types/Trigger.d.ts +1 -1
- package/lib/types/Watcher.d.ts +3 -3
- package/lib/utils/projection.d.ts +2 -2
- package/lib/utils/relationPath.d.ts +4 -4
- package/lib/utils/relationPath.js +1 -1
- package/lib/utils/validator.d.ts +2 -2
- package/package.json +2 -2
|
@@ -1,171 +1,19 @@
|
|
|
1
|
-
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
type
|
|
11
|
-
export type
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
export type
|
|
17
|
-
type
|
|
18
|
-
type
|
|
19
|
-
export type
|
|
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"];
|
|
@@ -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 {};
|