oak-pay-business 2.3.3 → 2.4.0
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/es/aspects/withdraw.d.ts +12 -12
- package/es/components/AbstractComponents.d.ts +17 -7
- package/es/components/account/detail/web.pc.module.less +68 -68
- package/es/components/order/pay/info.js +6 -6
- package/es/components/order/pay/info.module.less +24 -24
- package/es/components/order/pay/web.mobile.module.less +35 -35
- package/es/components/order/pay/web.pc.module.less +35 -35
- package/es/components/payConfig/upsert/offline/web.pc.module.less +4 -4
- package/es/components/payConfig/upsert/web.pc.module.less +10 -10
- package/es/context/BackendRuntimeContext.d.ts +38 -0
- package/es/oak-app-domain/ActionDefDict.d.ts +9 -0
- package/es/oak-app-domain/ActionDefDict.js +6 -0
- package/es/oak-app-domain/Application/Schema.d.ts +22 -0
- package/es/oak-app-domain/ApplicationPassport/Schema.d.ts +160 -0
- package/es/oak-app-domain/ApplicationPassport/Schema.js +1 -0
- package/es/oak-app-domain/ApplicationPassport/Storage.d.ts +3 -0
- package/es/oak-app-domain/ApplicationPassport/Storage.js +21 -0
- package/es/oak-app-domain/ApplicationPassport/locales/zh_CN.json +1 -0
- package/es/oak-app-domain/Captcha/Schema.d.ts +13 -7
- package/es/oak-app-domain/Captcha/Storage.js +9 -4
- package/es/oak-app-domain/Captcha/locales/zh_CN.json +1 -1
- package/es/oak-app-domain/Domain/Schema.d.ts +3 -3
- package/es/oak-app-domain/Domain/Storage.js +1 -1
- package/es/oak-app-domain/Domain/Style.js +2 -2
- package/es/oak-app-domain/Domain/locales/zh_CN.json +1 -1
- package/es/oak-app-domain/Email/Schema.d.ts +2 -2
- package/es/oak-app-domain/Email/Storage.js +1 -1
- package/es/oak-app-domain/EntityDict.d.ts +8 -0
- package/es/oak-app-domain/Log/Action.d.ts +12 -0
- package/es/oak-app-domain/Log/Action.js +11 -0
- package/es/oak-app-domain/Log/Schema.d.ts +111 -0
- package/es/oak-app-domain/Log/Schema.js +1 -0
- package/es/oak-app-domain/Log/Storage.d.ts +3 -0
- package/es/oak-app-domain/Log/Storage.js +25 -0
- package/es/oak-app-domain/Log/Style.d.ts +3 -0
- package/es/oak-app-domain/Log/Style.js +12 -0
- package/es/oak-app-domain/Log/locales/zh_CN.json +1 -0
- package/es/oak-app-domain/LoginName/Action.d.ts +10 -0
- package/es/oak-app-domain/LoginName/Action.js +6 -0
- package/es/oak-app-domain/LoginName/Schema.d.ts +142 -0
- package/es/oak-app-domain/LoginName/Schema.js +1 -0
- package/es/oak-app-domain/LoginName/Storage.d.ts +3 -0
- package/es/oak-app-domain/LoginName/Storage.js +38 -0
- package/es/oak-app-domain/LoginName/Style.d.ts +3 -0
- package/es/oak-app-domain/LoginName/Style.js +12 -0
- package/es/oak-app-domain/LoginName/locales/zh_CN.json +1 -0
- package/es/oak-app-domain/Message/Schema.d.ts +5 -5
- package/es/oak-app-domain/Notification/Storage.js +1 -1
- package/es/oak-app-domain/Notification/Style.js +1 -0
- package/es/oak-app-domain/Notification/locales/zh_CN.json +1 -1
- package/es/oak-app-domain/Oper/Action.d.ts +12 -0
- package/es/oak-app-domain/Oper/Action.js +11 -0
- package/es/oak-app-domain/Oper/Schema.d.ts +56 -6
- package/es/oak-app-domain/Oper/Storage.js +13 -2
- package/es/oak-app-domain/Oper/Style.d.ts +3 -0
- package/es/oak-app-domain/Oper/Style.js +12 -0
- package/es/oak-app-domain/Oper/locales/zh_CN.json +1 -1
- package/es/oak-app-domain/OperEntity/Schema.d.ts +12 -1
- package/es/oak-app-domain/Passport/Schema.d.ts +167 -0
- package/es/oak-app-domain/Passport/Schema.js +1 -0
- package/es/oak-app-domain/Passport/Storage.d.ts +3 -0
- package/es/oak-app-domain/Passport/Storage.js +24 -0
- package/es/oak-app-domain/Passport/Style.d.ts +3 -0
- package/es/oak-app-domain/Passport/Style.js +14 -0
- package/es/oak-app-domain/Passport/locales/zh_CN.json +1 -0
- package/es/oak-app-domain/Storage.js +8 -0
- package/es/oak-app-domain/StyleDict.js +8 -0
- package/es/oak-app-domain/System/Schema.d.ts +12 -0
- package/es/oak-app-domain/Token/Schema.d.ts +63 -5
- package/es/oak-app-domain/Token/Storage.js +1 -1
- package/es/oak-app-domain/User/Schema.d.ts +14 -2
- package/es/oak-app-domain/WechatLogin/Schema.d.ts +53 -2
- package/es/oak-app-domain/WechatLogin/Storage.js +4 -0
- package/es/oak-app-domain/WechatLogin/locales/zh_CN.json +1 -1
- package/es/oak-app-domain/WechatUser/Schema.d.ts +12 -0
- package/es/oak-app-domain/_SubQuery.d.ts +42 -2
- package/es/triggers/withdraw.d.ts +1 -1
- package/es/utils/application.d.ts +38 -0
- package/es/utils/payClazz/WechatPay/index.d.ts +1 -1
- package/lib/aspects/withdraw.d.ts +8 -8
- package/lib/context/BackendRuntimeContext.d.ts +39 -1
- package/lib/oak-app-domain/ActionDefDict.d.ts +9 -0
- package/lib/oak-app-domain/ActionDefDict.js +60 -54
- package/lib/oak-app-domain/Application/Schema.d.ts +22 -0
- package/lib/oak-app-domain/ApplicationPassport/Schema.d.ts +160 -0
- package/lib/oak-app-domain/ApplicationPassport/Schema.js +2 -0
- package/lib/oak-app-domain/ApplicationPassport/Storage.d.ts +3 -0
- package/lib/oak-app-domain/ApplicationPassport/Storage.js +24 -0
- package/lib/oak-app-domain/ApplicationPassport/locales/zh_CN.json +1 -0
- package/lib/oak-app-domain/Captcha/Schema.d.ts +13 -7
- package/lib/oak-app-domain/Captcha/Storage.js +9 -4
- package/lib/oak-app-domain/Captcha/locales/zh_CN.json +1 -1
- package/lib/oak-app-domain/Domain/Schema.d.ts +3 -3
- package/lib/oak-app-domain/Domain/Storage.js +1 -1
- package/lib/oak-app-domain/Domain/Style.js +2 -2
- package/lib/oak-app-domain/Domain/locales/zh_CN.json +1 -1
- package/lib/oak-app-domain/Email/Schema.d.ts +2 -2
- package/lib/oak-app-domain/Email/Storage.js +1 -1
- package/lib/oak-app-domain/EntityDict.d.ts +8 -0
- package/lib/oak-app-domain/Log/Action.d.ts +12 -0
- package/lib/oak-app-domain/Log/Action.js +14 -0
- package/lib/oak-app-domain/Log/Schema.d.ts +111 -0
- package/lib/oak-app-domain/Log/Schema.js +2 -0
- package/lib/oak-app-domain/Log/Storage.d.ts +3 -0
- package/lib/oak-app-domain/Log/Storage.js +28 -0
- package/lib/oak-app-domain/Log/Style.d.ts +3 -0
- package/lib/oak-app-domain/Log/Style.js +15 -0
- package/lib/oak-app-domain/Log/locales/zh_CN.json +1 -0
- package/lib/oak-app-domain/LoginName/Action.d.ts +10 -0
- package/lib/oak-app-domain/LoginName/Action.js +9 -0
- package/lib/oak-app-domain/LoginName/Schema.d.ts +142 -0
- package/lib/oak-app-domain/LoginName/Schema.js +2 -0
- package/lib/oak-app-domain/LoginName/Storage.d.ts +3 -0
- package/lib/oak-app-domain/LoginName/Storage.js +41 -0
- package/lib/oak-app-domain/LoginName/Style.d.ts +3 -0
- package/lib/oak-app-domain/LoginName/Style.js +15 -0
- package/lib/oak-app-domain/LoginName/locales/zh_CN.json +1 -0
- package/lib/oak-app-domain/Message/Schema.d.ts +5 -5
- package/lib/oak-app-domain/Notification/Storage.js +1 -1
- package/lib/oak-app-domain/Notification/Style.js +1 -0
- package/lib/oak-app-domain/Notification/locales/zh_CN.json +1 -1
- package/lib/oak-app-domain/Oper/Action.d.ts +12 -0
- package/lib/oak-app-domain/Oper/Action.js +14 -0
- package/lib/oak-app-domain/Oper/Schema.d.ts +56 -6
- package/lib/oak-app-domain/Oper/Storage.js +14 -3
- package/lib/oak-app-domain/Oper/Style.d.ts +3 -0
- package/lib/oak-app-domain/Oper/Style.js +15 -0
- package/lib/oak-app-domain/Oper/locales/zh_CN.json +1 -1
- package/lib/oak-app-domain/OperEntity/Schema.d.ts +12 -1
- package/lib/oak-app-domain/Passport/Schema.d.ts +167 -0
- package/lib/oak-app-domain/Passport/Schema.js +2 -0
- package/lib/oak-app-domain/Passport/Storage.d.ts +3 -0
- package/lib/oak-app-domain/Passport/Storage.js +27 -0
- package/lib/oak-app-domain/Passport/Style.d.ts +3 -0
- package/lib/oak-app-domain/Passport/Style.js +17 -0
- package/lib/oak-app-domain/Passport/locales/zh_CN.json +1 -0
- package/lib/oak-app-domain/Storage.js +146 -138
- package/lib/oak-app-domain/StyleDict.js +86 -78
- package/lib/oak-app-domain/System/Schema.d.ts +12 -0
- package/lib/oak-app-domain/Token/Schema.d.ts +63 -5
- package/lib/oak-app-domain/Token/Storage.js +1 -1
- package/lib/oak-app-domain/User/Schema.d.ts +14 -2
- package/lib/oak-app-domain/WechatLogin/Schema.d.ts +53 -2
- package/lib/oak-app-domain/WechatLogin/Storage.js +4 -0
- package/lib/oak-app-domain/WechatLogin/locales/zh_CN.json +1 -1
- package/lib/oak-app-domain/WechatUser/Schema.d.ts +12 -0
- package/lib/oak-app-domain/_SubQuery.d.ts +42 -2
- package/lib/utils/application.d.ts +39 -1
- package/lib/utils/payClazz/WechatPay/index.d.ts +1 -1
- package/package.json +3 -3
|
@@ -7,6 +7,7 @@ import { String, Text } from "oak-domain/lib/types/DataType";
|
|
|
7
7
|
import { Style } from "oak-general-business/lib/types/Style";
|
|
8
8
|
import * as System from "../System/Schema";
|
|
9
9
|
import * as Domain from "../Domain/Schema";
|
|
10
|
+
import * as ApplicationPassport from "../ApplicationPassport/Schema";
|
|
10
11
|
import * as ExtraFile from "../ExtraFile/Schema";
|
|
11
12
|
import * as Notification from "../Notification/Schema";
|
|
12
13
|
import * as SessionMessage from "../SessionMessage/Schema";
|
|
@@ -46,6 +47,11 @@ export type WebConfig = {
|
|
|
46
47
|
enable?: boolean;
|
|
47
48
|
};
|
|
48
49
|
passport?: Passport[];
|
|
50
|
+
location: {
|
|
51
|
+
protocol: "http:" | "https:";
|
|
52
|
+
hostname: string;
|
|
53
|
+
port: string;
|
|
54
|
+
};
|
|
49
55
|
};
|
|
50
56
|
export type WechatPublicTemplateMsgsConfig = Record<string, string>;
|
|
51
57
|
export type WechatPublicConfig = {
|
|
@@ -67,6 +73,11 @@ export type WechatPublicConfig = {
|
|
|
67
73
|
originalId: string;
|
|
68
74
|
};
|
|
69
75
|
passport?: Passport[];
|
|
76
|
+
location: {
|
|
77
|
+
protocol: "http:" | "https:";
|
|
78
|
+
hostname: string;
|
|
79
|
+
port: string;
|
|
80
|
+
};
|
|
70
81
|
};
|
|
71
82
|
export type NativeConfig = {
|
|
72
83
|
type: "native";
|
|
@@ -92,6 +103,8 @@ export type Schema = EntityShape & {
|
|
|
92
103
|
domainId?: ForeignKey<"domain"> | null;
|
|
93
104
|
system: System.Schema;
|
|
94
105
|
domain?: Domain.Schema | null;
|
|
106
|
+
applicationPassport$application?: Array<ApplicationPassport.Schema>;
|
|
107
|
+
applicationPassport$application$$aggr?: AggregationResult<ApplicationPassport.Schema>;
|
|
95
108
|
extraFile$application?: Array<ExtraFile.Schema>;
|
|
96
109
|
extraFile$application$$aggr?: AggregationResult<ExtraFile.Schema>;
|
|
97
110
|
notification$application?: Array<Notification.Schema>;
|
|
@@ -135,6 +148,7 @@ type AttrFilter = {
|
|
|
135
148
|
style: JsonFilter<Style>;
|
|
136
149
|
domainId: Q_StringValue;
|
|
137
150
|
domain: Domain.Filter;
|
|
151
|
+
applicationPassport$application: ApplicationPassport.Filter & SubQueryPredicateMetadata;
|
|
138
152
|
extraFile$application: ExtraFile.Filter & SubQueryPredicateMetadata;
|
|
139
153
|
notification$application: Notification.Filter & SubQueryPredicateMetadata;
|
|
140
154
|
sessionMessage$application: SessionMessage.Filter & SubQueryPredicateMetadata;
|
|
@@ -166,6 +180,12 @@ export type Projection = {
|
|
|
166
180
|
style?: number | JsonProjection<Style>;
|
|
167
181
|
domainId?: number;
|
|
168
182
|
domain?: Domain.Projection;
|
|
183
|
+
applicationPassport$application?: ApplicationPassport.Selection & {
|
|
184
|
+
$entity: "applicationPassport";
|
|
185
|
+
};
|
|
186
|
+
applicationPassport$application$$aggr?: ApplicationPassport.Aggregation & {
|
|
187
|
+
$entity: "applicationPassport";
|
|
188
|
+
};
|
|
169
189
|
extraFile$application?: ExtraFile.Selection & {
|
|
170
190
|
$entity: "extraFile";
|
|
171
191
|
};
|
|
@@ -308,6 +328,7 @@ export type CreateOperationData = FormCreateData<Omit<OpSchema, "systemId" | "do
|
|
|
308
328
|
domain?: never;
|
|
309
329
|
domainId?: ForeignKey<"domain">;
|
|
310
330
|
})) & {
|
|
331
|
+
applicationPassport$application?: OakOperation<ApplicationPassport.UpdateOperation["action"], Omit<ApplicationPassport.UpdateOperationData, "application" | "applicationId">, Omit<ApplicationPassport.Filter, "application" | "applicationId">> | OakOperation<"create", Omit<ApplicationPassport.CreateOperationData, "application" | "applicationId">[]> | Array<OakOperation<"create", Omit<ApplicationPassport.CreateOperationData, "application" | "applicationId">> | OakOperation<ApplicationPassport.UpdateOperation["action"], Omit<ApplicationPassport.UpdateOperationData, "application" | "applicationId">, Omit<ApplicationPassport.Filter, "application" | "applicationId">>>;
|
|
311
332
|
extraFile$application?: OakOperation<ExtraFile.UpdateOperation["action"], Omit<ExtraFile.UpdateOperationData, "application" | "applicationId">, Omit<ExtraFile.Filter, "application" | "applicationId">> | OakOperation<"create", Omit<ExtraFile.CreateOperationData, "application" | "applicationId">[]> | Array<OakOperation<"create", Omit<ExtraFile.CreateOperationData, "application" | "applicationId">> | OakOperation<ExtraFile.UpdateOperation["action"], Omit<ExtraFile.UpdateOperationData, "application" | "applicationId">, Omit<ExtraFile.Filter, "application" | "applicationId">>>;
|
|
312
333
|
notification$application?: OakOperation<Notification.UpdateOperation["action"], Omit<Notification.UpdateOperationData, "application" | "applicationId">, Omit<Notification.Filter, "application" | "applicationId">> | OakOperation<"create", Omit<Notification.CreateOperationData, "application" | "applicationId">[]> | Array<OakOperation<"create", Omit<Notification.CreateOperationData, "application" | "applicationId">> | OakOperation<Notification.UpdateOperation["action"], Omit<Notification.UpdateOperationData, "application" | "applicationId">, Omit<Notification.Filter, "application" | "applicationId">>>;
|
|
313
334
|
sessionMessage$application?: OakOperation<SessionMessage.UpdateOperation["action"], Omit<SessionMessage.UpdateOperationData, "application" | "applicationId">, Omit<SessionMessage.Filter, "application" | "applicationId">> | OakOperation<"create", Omit<SessionMessage.CreateOperationData, "application" | "applicationId">[]> | Array<OakOperation<"create", Omit<SessionMessage.CreateOperationData, "application" | "applicationId">> | OakOperation<SessionMessage.UpdateOperation["action"], Omit<SessionMessage.UpdateOperationData, "application" | "applicationId">, Omit<SessionMessage.Filter, "application" | "applicationId">>>;
|
|
@@ -351,6 +372,7 @@ export type UpdateOperationData = FormUpdateData<Omit<OpSchema, "systemId" | "do
|
|
|
351
372
|
domainId?: ForeignKey<"domain"> | null;
|
|
352
373
|
})) & {
|
|
353
374
|
[k: string]: any;
|
|
375
|
+
applicationPassport$application?: OakOperation<ApplicationPassport.UpdateOperation["action"], Omit<ApplicationPassport.UpdateOperationData, "application" | "applicationId">, Omit<ApplicationPassport.Filter, "application" | "applicationId">> | OakOperation<ApplicationPassport.RemoveOperation["action"], Omit<ApplicationPassport.RemoveOperationData, "application" | "applicationId">, Omit<ApplicationPassport.Filter, "application" | "applicationId">> | OakOperation<"create", Omit<ApplicationPassport.CreateOperationData, "application" | "applicationId">[]> | Array<OakOperation<"create", Omit<ApplicationPassport.CreateOperationData, "application" | "applicationId">> | OakOperation<ApplicationPassport.UpdateOperation["action"], Omit<ApplicationPassport.UpdateOperationData, "application" | "applicationId">, Omit<ApplicationPassport.Filter, "application" | "applicationId">> | OakOperation<ApplicationPassport.RemoveOperation["action"], Omit<ApplicationPassport.RemoveOperationData, "application" | "applicationId">, Omit<ApplicationPassport.Filter, "application" | "applicationId">>>;
|
|
354
376
|
extraFile$application?: OakOperation<ExtraFile.UpdateOperation["action"], Omit<ExtraFile.UpdateOperationData, "application" | "applicationId">, Omit<ExtraFile.Filter, "application" | "applicationId">> | OakOperation<ExtraFile.RemoveOperation["action"], Omit<ExtraFile.RemoveOperationData, "application" | "applicationId">, Omit<ExtraFile.Filter, "application" | "applicationId">> | OakOperation<"create", Omit<ExtraFile.CreateOperationData, "application" | "applicationId">[]> | Array<OakOperation<"create", Omit<ExtraFile.CreateOperationData, "application" | "applicationId">> | OakOperation<ExtraFile.UpdateOperation["action"], Omit<ExtraFile.UpdateOperationData, "application" | "applicationId">, Omit<ExtraFile.Filter, "application" | "applicationId">> | OakOperation<ExtraFile.RemoveOperation["action"], Omit<ExtraFile.RemoveOperationData, "application" | "applicationId">, Omit<ExtraFile.Filter, "application" | "applicationId">>>;
|
|
355
377
|
notification$application?: OakOperation<Notification.UpdateOperation["action"], Omit<Notification.UpdateOperationData, "application" | "applicationId">, Omit<Notification.Filter, "application" | "applicationId">> | OakOperation<Notification.RemoveOperation["action"], Omit<Notification.RemoveOperationData, "application" | "applicationId">, Omit<Notification.Filter, "application" | "applicationId">> | OakOperation<"create", Omit<Notification.CreateOperationData, "application" | "applicationId">[]> | Array<OakOperation<"create", Omit<Notification.CreateOperationData, "application" | "applicationId">> | OakOperation<Notification.UpdateOperation["action"], Omit<Notification.UpdateOperationData, "application" | "applicationId">, Omit<Notification.Filter, "application" | "applicationId">> | OakOperation<Notification.RemoveOperation["action"], Omit<Notification.RemoveOperationData, "application" | "applicationId">, Omit<Notification.Filter, "application" | "applicationId">>>;
|
|
356
378
|
sessionMessage$application?: OakOperation<SessionMessage.UpdateOperation["action"], Omit<SessionMessage.UpdateOperationData, "application" | "applicationId">, Omit<SessionMessage.Filter, "application" | "applicationId">> | OakOperation<SessionMessage.RemoveOperation["action"], Omit<SessionMessage.RemoveOperationData, "application" | "applicationId">, Omit<SessionMessage.Filter, "application" | "applicationId">> | OakOperation<"create", Omit<SessionMessage.CreateOperationData, "application" | "applicationId">[]> | Array<OakOperation<"create", Omit<SessionMessage.CreateOperationData, "application" | "applicationId">> | OakOperation<SessionMessage.UpdateOperation["action"], Omit<SessionMessage.UpdateOperationData, "application" | "applicationId">, Omit<SessionMessage.Filter, "application" | "applicationId">> | OakOperation<SessionMessage.RemoveOperation["action"], Omit<SessionMessage.RemoveOperationData, "application" | "applicationId">, Omit<SessionMessage.Filter, "application" | "applicationId">>>;
|
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
import { ForeignKey } from "oak-domain/lib/types/DataType";
|
|
2
|
+
import { Q_DateValue, Q_BooleanValue, Q_NumberValue, Q_StringValue, NodeId, MakeFilter, ExprOp, ExpressionKey } from "oak-domain/lib/types/Demand";
|
|
3
|
+
import { OneOf } from "oak-domain/lib/types/Polyfill";
|
|
4
|
+
import { FormCreateData, FormUpdateData, DeduceAggregation, Operation as OakOperation, Selection as OakSelection, MakeAction as OakMakeAction, EntityShape } from "oak-domain/lib/types/Entity";
|
|
5
|
+
import { GenericAction } from "oak-domain/lib/actions/action";
|
|
6
|
+
import { Boolean } from "oak-domain/lib/types/DataType";
|
|
7
|
+
import * as Application from "../Application/Schema";
|
|
8
|
+
import * as Passport from "../Passport/Schema";
|
|
9
|
+
export type OpSchema = EntityShape & {
|
|
10
|
+
applicationId: ForeignKey<"application">;
|
|
11
|
+
passportId: ForeignKey<"passport">;
|
|
12
|
+
isDefault: Boolean;
|
|
13
|
+
};
|
|
14
|
+
export type OpAttr = keyof OpSchema;
|
|
15
|
+
export type Schema = EntityShape & {
|
|
16
|
+
applicationId: ForeignKey<"application">;
|
|
17
|
+
passportId: ForeignKey<"passport">;
|
|
18
|
+
isDefault: Boolean;
|
|
19
|
+
application: Application.Schema;
|
|
20
|
+
passport: Passport.Schema;
|
|
21
|
+
} & {
|
|
22
|
+
[A in ExpressionKey]?: any;
|
|
23
|
+
};
|
|
24
|
+
type AttrFilter = {
|
|
25
|
+
id: Q_StringValue;
|
|
26
|
+
$$createAt$$: Q_DateValue;
|
|
27
|
+
$$seq$$: Q_NumberValue;
|
|
28
|
+
$$updateAt$$: Q_DateValue;
|
|
29
|
+
applicationId: Q_StringValue;
|
|
30
|
+
application: Application.Filter;
|
|
31
|
+
passportId: Q_StringValue;
|
|
32
|
+
passport: Passport.Filter;
|
|
33
|
+
isDefault: Q_BooleanValue;
|
|
34
|
+
};
|
|
35
|
+
export type Filter = MakeFilter<AttrFilter & ExprOp<OpAttr | string>>;
|
|
36
|
+
export type Projection = {
|
|
37
|
+
"#id"?: NodeId;
|
|
38
|
+
[k: string]: any;
|
|
39
|
+
id?: number;
|
|
40
|
+
$$createAt$$?: number;
|
|
41
|
+
$$updateAt$$?: number;
|
|
42
|
+
$$seq$$?: number;
|
|
43
|
+
applicationId?: number;
|
|
44
|
+
application?: Application.Projection;
|
|
45
|
+
passportId?: number;
|
|
46
|
+
passport?: Passport.Projection;
|
|
47
|
+
isDefault?: number;
|
|
48
|
+
} & Partial<ExprOp<OpAttr | string>>;
|
|
49
|
+
type ApplicationPassportIdProjection = OneOf<{
|
|
50
|
+
id: number;
|
|
51
|
+
}>;
|
|
52
|
+
type ApplicationIdProjection = OneOf<{
|
|
53
|
+
applicationId: number;
|
|
54
|
+
}>;
|
|
55
|
+
type PassportIdProjection = OneOf<{
|
|
56
|
+
passportId: number;
|
|
57
|
+
}>;
|
|
58
|
+
export type SortAttr = {
|
|
59
|
+
id: number;
|
|
60
|
+
} | {
|
|
61
|
+
$$createAt$$: number;
|
|
62
|
+
} | {
|
|
63
|
+
$$seq$$: number;
|
|
64
|
+
} | {
|
|
65
|
+
$$updateAt$$: number;
|
|
66
|
+
} | {
|
|
67
|
+
applicationId: number;
|
|
68
|
+
} | {
|
|
69
|
+
application: Application.SortAttr;
|
|
70
|
+
} | {
|
|
71
|
+
passportId: number;
|
|
72
|
+
} | {
|
|
73
|
+
passport: Passport.SortAttr;
|
|
74
|
+
} | {
|
|
75
|
+
isDefault: number;
|
|
76
|
+
} | {
|
|
77
|
+
[k: string]: any;
|
|
78
|
+
} | OneOf<ExprOp<OpAttr | string>>;
|
|
79
|
+
export type SortNode = {
|
|
80
|
+
$attr: SortAttr;
|
|
81
|
+
$direction?: "asc" | "desc";
|
|
82
|
+
};
|
|
83
|
+
export type Sorter = SortNode[];
|
|
84
|
+
export type SelectOperation<P extends Object = Projection> = OakSelection<"select", P, Filter, Sorter>;
|
|
85
|
+
export type Selection<P extends Object = Projection> = SelectOperation<P>;
|
|
86
|
+
export type Aggregation = DeduceAggregation<Projection, Filter, Sorter>;
|
|
87
|
+
export type CreateOperationData = FormCreateData<Omit<OpSchema, "applicationId" | "passportId">> & (({
|
|
88
|
+
applicationId?: never;
|
|
89
|
+
application: Application.CreateSingleOperation;
|
|
90
|
+
} | {
|
|
91
|
+
applicationId: ForeignKey<"application">;
|
|
92
|
+
application?: Application.UpdateOperation;
|
|
93
|
+
} | {
|
|
94
|
+
application?: never;
|
|
95
|
+
applicationId: ForeignKey<"application">;
|
|
96
|
+
}) & ({
|
|
97
|
+
passportId?: never;
|
|
98
|
+
passport: Passport.CreateSingleOperation;
|
|
99
|
+
} | {
|
|
100
|
+
passportId: ForeignKey<"passport">;
|
|
101
|
+
passport?: Passport.UpdateOperation;
|
|
102
|
+
} | {
|
|
103
|
+
passport?: never;
|
|
104
|
+
passportId: ForeignKey<"passport">;
|
|
105
|
+
}));
|
|
106
|
+
export type CreateSingleOperation = OakOperation<"create", CreateOperationData>;
|
|
107
|
+
export type CreateMultipleOperation = OakOperation<"create", Array<CreateOperationData>>;
|
|
108
|
+
export type CreateOperation = CreateSingleOperation | CreateMultipleOperation;
|
|
109
|
+
export type UpdateOperationData = FormUpdateData<Omit<OpSchema, "applicationId" | "passportId">> & (({
|
|
110
|
+
application?: Application.CreateSingleOperation;
|
|
111
|
+
applicationId?: never;
|
|
112
|
+
} | {
|
|
113
|
+
application?: Application.UpdateOperation;
|
|
114
|
+
applicationId?: never;
|
|
115
|
+
} | {
|
|
116
|
+
application?: Application.RemoveOperation;
|
|
117
|
+
applicationId?: never;
|
|
118
|
+
} | {
|
|
119
|
+
application?: never;
|
|
120
|
+
applicationId?: ForeignKey<"application">;
|
|
121
|
+
}) & ({
|
|
122
|
+
passport?: Passport.CreateSingleOperation;
|
|
123
|
+
passportId?: never;
|
|
124
|
+
} | {
|
|
125
|
+
passport?: Passport.UpdateOperation;
|
|
126
|
+
passportId?: never;
|
|
127
|
+
} | {
|
|
128
|
+
passport?: Passport.RemoveOperation;
|
|
129
|
+
passportId?: never;
|
|
130
|
+
} | {
|
|
131
|
+
passport?: never;
|
|
132
|
+
passportId?: ForeignKey<"passport">;
|
|
133
|
+
})) & {
|
|
134
|
+
[k: string]: any;
|
|
135
|
+
};
|
|
136
|
+
export type UpdateOperation = OakOperation<"update" | string, UpdateOperationData, Filter, Sorter>;
|
|
137
|
+
export type RemoveOperationData = {} & (({
|
|
138
|
+
application?: Application.UpdateOperation | Application.RemoveOperation;
|
|
139
|
+
}) & ({
|
|
140
|
+
passport?: Passport.UpdateOperation | Passport.RemoveOperation;
|
|
141
|
+
}));
|
|
142
|
+
export type RemoveOperation = OakOperation<"remove", RemoveOperationData, Filter, Sorter>;
|
|
143
|
+
export type Operation = CreateOperation | UpdateOperation | RemoveOperation;
|
|
144
|
+
export type ApplicationIdSubQuery = Selection<ApplicationIdProjection>;
|
|
145
|
+
export type PassportIdSubQuery = Selection<PassportIdProjection>;
|
|
146
|
+
export type ApplicationPassportIdSubQuery = Selection<ApplicationPassportIdProjection>;
|
|
147
|
+
export type EntityDef = {
|
|
148
|
+
Schema: Schema;
|
|
149
|
+
OpSchema: OpSchema;
|
|
150
|
+
Action: OakMakeAction<GenericAction> | string;
|
|
151
|
+
Selection: Selection;
|
|
152
|
+
Aggregation: Aggregation;
|
|
153
|
+
Operation: Operation;
|
|
154
|
+
Create: CreateOperation;
|
|
155
|
+
Update: UpdateOperation;
|
|
156
|
+
Remove: RemoveOperation;
|
|
157
|
+
CreateSingle: CreateSingleOperation;
|
|
158
|
+
CreateMulti: CreateMultipleOperation;
|
|
159
|
+
};
|
|
160
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { genericActions as actions } from "oak-domain/lib/actions/action";
|
|
2
|
+
export const desc = {
|
|
3
|
+
attributes: {
|
|
4
|
+
applicationId: {
|
|
5
|
+
notNull: true,
|
|
6
|
+
type: "ref",
|
|
7
|
+
ref: "application"
|
|
8
|
+
},
|
|
9
|
+
passportId: {
|
|
10
|
+
notNull: true,
|
|
11
|
+
type: "ref",
|
|
12
|
+
ref: "passport"
|
|
13
|
+
},
|
|
14
|
+
isDefault: {
|
|
15
|
+
notNull: true,
|
|
16
|
+
type: "boolean"
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
actionType: "crud",
|
|
20
|
+
actions
|
|
21
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{ "name": "应用登录方式", "attr": { "application": "应用", "passport": "登录方式", "isDefault": "是否默认" } }
|
|
@@ -4,8 +4,9 @@ import { FormCreateData, FormUpdateData, DeduceAggregation, Operation as OakOper
|
|
|
4
4
|
import { Action, ParticularAction, IState } from "./Action";
|
|
5
5
|
import { String, Text, Boolean, Datetime } from "oak-domain/lib/types/DataType";
|
|
6
6
|
export type OpSchema = EntityShape & {
|
|
7
|
-
|
|
8
|
-
|
|
7
|
+
origin: "mobile" | "email";
|
|
8
|
+
content: String<32>;
|
|
9
|
+
code: String<8>;
|
|
9
10
|
visitorId: Text;
|
|
10
11
|
reason?: Text | null;
|
|
11
12
|
env: Object;
|
|
@@ -16,8 +17,9 @@ export type OpSchema = EntityShape & {
|
|
|
16
17
|
};
|
|
17
18
|
export type OpAttr = keyof OpSchema;
|
|
18
19
|
export type Schema = EntityShape & {
|
|
19
|
-
|
|
20
|
-
|
|
20
|
+
origin: "mobile" | "email";
|
|
21
|
+
content: String<32>;
|
|
22
|
+
code: String<8>;
|
|
21
23
|
visitorId: Text;
|
|
22
24
|
reason?: Text | null;
|
|
23
25
|
env: Object;
|
|
@@ -33,7 +35,8 @@ type AttrFilter = {
|
|
|
33
35
|
$$createAt$$: Q_DateValue;
|
|
34
36
|
$$seq$$: Q_NumberValue;
|
|
35
37
|
$$updateAt$$: Q_DateValue;
|
|
36
|
-
|
|
38
|
+
origin: Q_EnumValue<"mobile" | "email">;
|
|
39
|
+
content: Q_StringValue;
|
|
37
40
|
code: Q_StringValue;
|
|
38
41
|
visitorId: Q_StringValue;
|
|
39
42
|
reason: Q_StringValue;
|
|
@@ -51,7 +54,8 @@ export type Projection = {
|
|
|
51
54
|
$$createAt$$?: number;
|
|
52
55
|
$$updateAt$$?: number;
|
|
53
56
|
$$seq$$?: number;
|
|
54
|
-
|
|
57
|
+
origin?: number;
|
|
58
|
+
content?: number;
|
|
55
59
|
code?: number;
|
|
56
60
|
visitorId?: number;
|
|
57
61
|
reason?: number;
|
|
@@ -73,7 +77,9 @@ export type SortAttr = {
|
|
|
73
77
|
} | {
|
|
74
78
|
$$updateAt$$: number;
|
|
75
79
|
} | {
|
|
76
|
-
|
|
80
|
+
origin: number;
|
|
81
|
+
} | {
|
|
82
|
+
content: number;
|
|
77
83
|
} | {
|
|
78
84
|
code: number;
|
|
79
85
|
} | {
|
|
@@ -1,18 +1,23 @@
|
|
|
1
1
|
import { actions } from "./Action";
|
|
2
2
|
export const desc = {
|
|
3
3
|
attributes: {
|
|
4
|
-
|
|
4
|
+
origin: {
|
|
5
|
+
notNull: true,
|
|
6
|
+
type: "enum",
|
|
7
|
+
enumeration: ["mobile", "email"]
|
|
8
|
+
},
|
|
9
|
+
content: {
|
|
5
10
|
notNull: true,
|
|
6
11
|
type: "varchar",
|
|
7
12
|
params: {
|
|
8
|
-
length:
|
|
13
|
+
length: 32
|
|
9
14
|
}
|
|
10
15
|
},
|
|
11
16
|
code: {
|
|
12
17
|
notNull: true,
|
|
13
18
|
type: "varchar",
|
|
14
19
|
params: {
|
|
15
|
-
length:
|
|
20
|
+
length: 8
|
|
16
21
|
}
|
|
17
22
|
},
|
|
18
23
|
visitorId: {
|
|
@@ -51,7 +56,7 @@ export const desc = {
|
|
|
51
56
|
name: 'index_mobile_code',
|
|
52
57
|
attributes: [
|
|
53
58
|
{
|
|
54
|
-
name: '
|
|
59
|
+
name: 'content',
|
|
55
60
|
direction: 'ASC',
|
|
56
61
|
},
|
|
57
62
|
{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{ "name": "验证码", "attr": { "
|
|
1
|
+
{ "name": "验证码", "attr": { "origin": "源", "content": "内容", "code": "验证码", "visitorId": "用户标识", "reason": "失败原因", "env": "用户环境", "expired": "是否过期", "expiresAt": "过期时间", "iState": "状态", "type": "类型" }, "action": { "send": "发送", "fail": "失败", "success": "成功" }, "v": { "iState": { "unsent": "未发送", "sending": "发送中", "sent": "已发送", "failure": "已失败" }, "type": { "login": "登录", "changePassword": "修改密码", "confirm": "校验" } } }
|
|
@@ -9,7 +9,7 @@ import * as Application from "../Application/Schema";
|
|
|
9
9
|
export type OpSchema = EntityShape & {
|
|
10
10
|
url: String<64>;
|
|
11
11
|
apiPath?: String<32> | null;
|
|
12
|
-
protocol: "http" | "https";
|
|
12
|
+
protocol: "http:" | "https:";
|
|
13
13
|
port: Int<2>;
|
|
14
14
|
systemId: ForeignKey<"system">;
|
|
15
15
|
};
|
|
@@ -17,7 +17,7 @@ export type OpAttr = keyof OpSchema;
|
|
|
17
17
|
export type Schema = EntityShape & {
|
|
18
18
|
url: String<64>;
|
|
19
19
|
apiPath?: String<32> | null;
|
|
20
|
-
protocol: "http" | "https";
|
|
20
|
+
protocol: "http:" | "https:";
|
|
21
21
|
port: Int<2>;
|
|
22
22
|
systemId: ForeignKey<"system">;
|
|
23
23
|
system: System.Schema;
|
|
@@ -33,7 +33,7 @@ type AttrFilter = {
|
|
|
33
33
|
$$updateAt$$: Q_DateValue;
|
|
34
34
|
url: Q_StringValue;
|
|
35
35
|
apiPath: Q_StringValue;
|
|
36
|
-
protocol: Q_EnumValue<"http" | "https">;
|
|
36
|
+
protocol: Q_EnumValue<"http:" | "https:">;
|
|
37
37
|
port: Q_NumberValue;
|
|
38
38
|
systemId: Q_StringValue;
|
|
39
39
|
system: System.Filter;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{ "name": "域名", "attr": { "url": "域名", "apiPath": "api路径", "protocol": "协议", "port": "端口", "system": "系统" }, "v": { "protocol": { "http": "http", "https": "https" } } }
|
|
1
|
+
{ "name": "域名", "attr": { "url": "域名", "apiPath": "api路径", "protocol": "协议", "port": "端口", "system": "系统" }, "v": { "protocol": { "http:": "http", "https:": "https" } } }
|
|
@@ -8,13 +8,13 @@ import { String } from "oak-domain/lib/types/DataType";
|
|
|
8
8
|
import * as User from "../User/Schema";
|
|
9
9
|
import * as Token from "../Token/Schema";
|
|
10
10
|
export type OpSchema = EntityShape & {
|
|
11
|
-
email: String<
|
|
11
|
+
email: String<32>;
|
|
12
12
|
userId: ForeignKey<"user">;
|
|
13
13
|
ableState?: AbleState | null;
|
|
14
14
|
};
|
|
15
15
|
export type OpAttr = keyof OpSchema;
|
|
16
16
|
export type Schema = EntityShape & {
|
|
17
|
-
email: String<
|
|
17
|
+
email: String<32>;
|
|
18
18
|
userId: ForeignKey<"user">;
|
|
19
19
|
ableState?: AbleState | null;
|
|
20
20
|
user: User.Schema;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { EntityDef as ActionAuth } from "./ActionAuth/Schema";
|
|
2
2
|
import { EntityDef as I18n } from "./I18n/Schema";
|
|
3
|
+
import { EntityDef as Log } from "./Log/Schema";
|
|
3
4
|
import { EntityDef as Modi } from "./Modi/Schema";
|
|
4
5
|
import { EntityDef as ModiEntity } from "./ModiEntity/Schema";
|
|
5
6
|
import { EntityDef as Oper } from "./Oper/Schema";
|
|
@@ -13,6 +14,7 @@ import { EntityDef as UserEntityGrant } from "./UserEntityGrant/Schema";
|
|
|
13
14
|
import { EntityDef as UserRelation } from "./UserRelation/Schema";
|
|
14
15
|
import { EntityDef as Address } from "./Address/Schema";
|
|
15
16
|
import { EntityDef as Application } from "./Application/Schema";
|
|
17
|
+
import { EntityDef as ApplicationPassport } from "./ApplicationPassport/Schema";
|
|
16
18
|
import { EntityDef as Area } from "./Area/Schema";
|
|
17
19
|
import { EntityDef as Article } from "./Article/Schema";
|
|
18
20
|
import { EntityDef as ArticleMenu } from "./ArticleMenu/Schema";
|
|
@@ -22,6 +24,7 @@ import { EntityDef as Domain } from "./Domain/Schema";
|
|
|
22
24
|
import { EntityDef as Email } from "./Email/Schema";
|
|
23
25
|
import { EntityDef as ExtraFile } from "./ExtraFile/Schema";
|
|
24
26
|
import { EntityDef as Livestream } from "./Livestream/Schema";
|
|
27
|
+
import { EntityDef as LoginName } from "./LoginName/Schema";
|
|
25
28
|
import { EntityDef as Message } from "./Message/Schema";
|
|
26
29
|
import { EntityDef as MessageSystem } from "./MessageSystem/Schema";
|
|
27
30
|
import { EntityDef as MessageType } from "./MessageType/Schema";
|
|
@@ -30,6 +33,7 @@ import { EntityDef as MessageTypeTemplate } from "./MessageTypeTemplate/Schema";
|
|
|
30
33
|
import { EntityDef as Mobile } from "./Mobile/Schema";
|
|
31
34
|
import { EntityDef as Notification } from "./Notification/Schema";
|
|
32
35
|
import { EntityDef as Parasite } from "./Parasite/Schema";
|
|
36
|
+
import { EntityDef as Passport } from "./Passport/Schema";
|
|
33
37
|
import { EntityDef as Platform } from "./Platform/Schema";
|
|
34
38
|
import { EntityDef as ReadRemark } from "./ReadRemark/Schema";
|
|
35
39
|
import { EntityDef as Session } from "./Session/Schema";
|
|
@@ -72,6 +76,7 @@ import { EntityDef as WpProduct } from "./WpProduct/Schema";
|
|
|
72
76
|
export type EntityDict = {
|
|
73
77
|
actionAuth: ActionAuth;
|
|
74
78
|
i18n: I18n;
|
|
79
|
+
log: Log;
|
|
75
80
|
modi: Modi;
|
|
76
81
|
modiEntity: ModiEntity;
|
|
77
82
|
oper: Oper;
|
|
@@ -85,6 +90,7 @@ export type EntityDict = {
|
|
|
85
90
|
userRelation: UserRelation;
|
|
86
91
|
address: Address;
|
|
87
92
|
application: Application;
|
|
93
|
+
applicationPassport: ApplicationPassport;
|
|
88
94
|
area: Area;
|
|
89
95
|
article: Article;
|
|
90
96
|
articleMenu: ArticleMenu;
|
|
@@ -94,6 +100,7 @@ export type EntityDict = {
|
|
|
94
100
|
email: Email;
|
|
95
101
|
extraFile: ExtraFile;
|
|
96
102
|
livestream: Livestream;
|
|
103
|
+
loginName: LoginName;
|
|
97
104
|
message: Message;
|
|
98
105
|
messageSystem: MessageSystem;
|
|
99
106
|
messageType: MessageType;
|
|
@@ -102,6 +109,7 @@ export type EntityDict = {
|
|
|
102
109
|
mobile: Mobile;
|
|
103
110
|
notification: Notification;
|
|
104
111
|
parasite: Parasite;
|
|
112
|
+
passport: Passport;
|
|
105
113
|
platform: Platform;
|
|
106
114
|
readRemark: ReadRemark;
|
|
107
115
|
session: Session;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ActionDef } from "oak-domain/lib/types/Action";
|
|
2
|
+
import { GenericAction } from "oak-domain/lib/actions/action";
|
|
3
|
+
export type IState = 'normal' | 'rollbacked' | string;
|
|
4
|
+
export type State = IState | string;
|
|
5
|
+
export type IAction = 'undo' | 'redo' | string;
|
|
6
|
+
export type ParticularAction = IAction;
|
|
7
|
+
export declare const actions: string[];
|
|
8
|
+
export declare const IActionDef: ActionDef<IAction, IState>;
|
|
9
|
+
export type Action = GenericAction | ParticularAction | string;
|
|
10
|
+
export declare const actionDefDict: {
|
|
11
|
+
iState: ActionDef<string, string>;
|
|
12
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export const actions = ["count", "stat", "download", "select", "aggregate", "create", "remove", "update", "undo", "redo"];
|
|
2
|
+
export const IActionDef = {
|
|
3
|
+
stm: {
|
|
4
|
+
undo: ['normal', 'rollbacked'],
|
|
5
|
+
redo: ['rollbacked', 'normal'],
|
|
6
|
+
},
|
|
7
|
+
is: 'normal',
|
|
8
|
+
};
|
|
9
|
+
export const actionDefDict = {
|
|
10
|
+
iState: IActionDef
|
|
11
|
+
};
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
import { Q_DateValue, Q_NumberValue, Q_StringValue, Q_EnumValue, NodeId, MakeFilter, ExprOp, ExpressionKey, SubQueryPredicateMetadata } from "oak-domain/lib/types/Demand";
|
|
2
|
+
import { OneOf } from "oak-domain/lib/types/Polyfill";
|
|
3
|
+
import { FormCreateData, FormUpdateData, DeduceAggregation, Operation as OakOperation, Selection as OakSelection, MakeAction as OakMakeAction, AggregationResult, EntityShape } from "oak-domain/lib/types/Entity";
|
|
4
|
+
import { Action, ParticularAction, IState } from "./Action";
|
|
5
|
+
import { String } from "oak-domain/lib/types/DataType";
|
|
6
|
+
import * as Oper from "../Oper/Schema";
|
|
7
|
+
export type OpSchema = EntityShape & {
|
|
8
|
+
entity: String<32>;
|
|
9
|
+
entityId: String<64>;
|
|
10
|
+
iState?: IState | null;
|
|
11
|
+
};
|
|
12
|
+
export type OpAttr = keyof OpSchema;
|
|
13
|
+
export type Schema = EntityShape & {
|
|
14
|
+
entity: String<32>;
|
|
15
|
+
entityId: String<64>;
|
|
16
|
+
iState?: IState | null;
|
|
17
|
+
oper$log?: Array<Oper.Schema>;
|
|
18
|
+
oper$log$$aggr?: AggregationResult<Oper.Schema>;
|
|
19
|
+
} & {
|
|
20
|
+
[A in ExpressionKey]?: any;
|
|
21
|
+
};
|
|
22
|
+
type AttrFilter = {
|
|
23
|
+
id: Q_StringValue;
|
|
24
|
+
$$createAt$$: Q_DateValue;
|
|
25
|
+
$$seq$$: Q_NumberValue;
|
|
26
|
+
$$updateAt$$: Q_DateValue;
|
|
27
|
+
entity: Q_StringValue;
|
|
28
|
+
entityId: Q_StringValue;
|
|
29
|
+
iState: Q_EnumValue<IState>;
|
|
30
|
+
oper$log: Oper.Filter & SubQueryPredicateMetadata;
|
|
31
|
+
};
|
|
32
|
+
export type Filter = MakeFilter<AttrFilter & ExprOp<OpAttr | string>>;
|
|
33
|
+
export type Projection = {
|
|
34
|
+
"#id"?: NodeId;
|
|
35
|
+
[k: string]: any;
|
|
36
|
+
id?: number;
|
|
37
|
+
$$createAt$$?: number;
|
|
38
|
+
$$updateAt$$?: number;
|
|
39
|
+
$$seq$$?: number;
|
|
40
|
+
entity?: number;
|
|
41
|
+
entityId?: number;
|
|
42
|
+
iState?: number;
|
|
43
|
+
oper$log?: Oper.Selection & {
|
|
44
|
+
$entity: "oper";
|
|
45
|
+
};
|
|
46
|
+
oper$log$$aggr?: Oper.Aggregation & {
|
|
47
|
+
$entity: "oper";
|
|
48
|
+
};
|
|
49
|
+
} & Partial<ExprOp<OpAttr | string>>;
|
|
50
|
+
type LogIdProjection = OneOf<{
|
|
51
|
+
id: number;
|
|
52
|
+
}>;
|
|
53
|
+
export type SortAttr = {
|
|
54
|
+
id: number;
|
|
55
|
+
} | {
|
|
56
|
+
$$createAt$$: number;
|
|
57
|
+
} | {
|
|
58
|
+
$$seq$$: number;
|
|
59
|
+
} | {
|
|
60
|
+
$$updateAt$$: number;
|
|
61
|
+
} | {
|
|
62
|
+
entity: number;
|
|
63
|
+
} | {
|
|
64
|
+
entityId: number;
|
|
65
|
+
} | {
|
|
66
|
+
iState: number;
|
|
67
|
+
} | {
|
|
68
|
+
[k: string]: any;
|
|
69
|
+
} | OneOf<ExprOp<OpAttr | string>>;
|
|
70
|
+
export type SortNode = {
|
|
71
|
+
$attr: SortAttr;
|
|
72
|
+
$direction?: "asc" | "desc";
|
|
73
|
+
};
|
|
74
|
+
export type Sorter = SortNode[];
|
|
75
|
+
export type SelectOperation<P extends Object = Projection> = OakSelection<"select", P, Filter, Sorter>;
|
|
76
|
+
export type Selection<P extends Object = Projection> = SelectOperation<P>;
|
|
77
|
+
export type Aggregation = DeduceAggregation<Projection, Filter, Sorter>;
|
|
78
|
+
export type CreateOperationData = FormCreateData<Omit<OpSchema, "entity" | "entityId">> & ({
|
|
79
|
+
entity?: string;
|
|
80
|
+
entityId?: string;
|
|
81
|
+
[K: string]: any;
|
|
82
|
+
}) & {
|
|
83
|
+
oper$log?: OakOperation<Oper.UpdateOperation["action"], Omit<Oper.UpdateOperationData, "log" | "logId">, Omit<Oper.Filter, "log" | "logId">> | OakOperation<"create", Omit<Oper.CreateOperationData, "log" | "logId">[]> | Array<OakOperation<"create", Omit<Oper.CreateOperationData, "log" | "logId">> | OakOperation<Oper.UpdateOperation["action"], Omit<Oper.UpdateOperationData, "log" | "logId">, Omit<Oper.Filter, "log" | "logId">>>;
|
|
84
|
+
};
|
|
85
|
+
export type CreateSingleOperation = OakOperation<"create", CreateOperationData>;
|
|
86
|
+
export type CreateMultipleOperation = OakOperation<"create", Array<CreateOperationData>>;
|
|
87
|
+
export type CreateOperation = CreateSingleOperation | CreateMultipleOperation;
|
|
88
|
+
export type UpdateOperationData = FormUpdateData<OpSchema> & {
|
|
89
|
+
[k: string]: any;
|
|
90
|
+
oper$log?: OakOperation<Oper.UpdateOperation["action"], Omit<Oper.UpdateOperationData, "log" | "logId">, Omit<Oper.Filter, "log" | "logId">> | OakOperation<Oper.RemoveOperation["action"], Omit<Oper.RemoveOperationData, "log" | "logId">, Omit<Oper.Filter, "log" | "logId">> | OakOperation<"create", Omit<Oper.CreateOperationData, "log" | "logId">[]> | Array<OakOperation<"create", Omit<Oper.CreateOperationData, "log" | "logId">> | OakOperation<Oper.UpdateOperation["action"], Omit<Oper.UpdateOperationData, "log" | "logId">, Omit<Oper.Filter, "log" | "logId">> | OakOperation<Oper.RemoveOperation["action"], Omit<Oper.RemoveOperationData, "log" | "logId">, Omit<Oper.Filter, "log" | "logId">>>;
|
|
91
|
+
};
|
|
92
|
+
export type UpdateOperation = OakOperation<"update" | ParticularAction | string, UpdateOperationData, Filter, Sorter>;
|
|
93
|
+
export type RemoveOperationData = {};
|
|
94
|
+
export type RemoveOperation = OakOperation<"remove", RemoveOperationData, Filter, Sorter>;
|
|
95
|
+
export type Operation = CreateOperation | UpdateOperation | RemoveOperation;
|
|
96
|
+
export type LogIdSubQuery = Selection<LogIdProjection>;
|
|
97
|
+
export type EntityDef = {
|
|
98
|
+
Schema: Schema;
|
|
99
|
+
OpSchema: OpSchema;
|
|
100
|
+
Action: OakMakeAction<Action> | string;
|
|
101
|
+
Selection: Selection;
|
|
102
|
+
Aggregation: Aggregation;
|
|
103
|
+
Operation: Operation;
|
|
104
|
+
Create: CreateOperation;
|
|
105
|
+
Update: UpdateOperation;
|
|
106
|
+
Remove: RemoveOperation;
|
|
107
|
+
CreateSingle: CreateSingleOperation;
|
|
108
|
+
CreateMulti: CreateMultipleOperation;
|
|
109
|
+
ParticularAction: ParticularAction;
|
|
110
|
+
};
|
|
111
|
+
export {};
|