vona-module-test-vona 5.0.30 → 5.0.32
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/dist/.metadata/index.d.ts +7 -0
- package/dist/dto/postCreate.d.ts +8 -0
- package/dist/dto/userCreate.d.ts +3 -6
- package/dist/dto/userUpdate.d.ts +3 -7
- package/dist/index.js +176 -174
- package/package.json +1 -1
|
@@ -844,6 +844,7 @@ export interface IModuleSummerCache {
|
|
|
844
844
|
/** summerCache: end */
|
|
845
845
|
/** dto: begin */
|
|
846
846
|
export * from '../dto/categoryTree.ts';
|
|
847
|
+
export * from '../dto/postCreate.ts';
|
|
847
848
|
export * from '../dto/profile.ts';
|
|
848
849
|
export * from '../dto/roleLazy.ts';
|
|
849
850
|
export * from '../dto/user.ts';
|
|
@@ -851,6 +852,7 @@ export * from '../dto/userCreate.ts';
|
|
|
851
852
|
export * from '../dto/userLazy.ts';
|
|
852
853
|
export * from '../dto/userUpdate.ts';
|
|
853
854
|
import type { IDtoOptionsCategoryTree } from '../dto/categoryTree.ts';
|
|
855
|
+
import type { IDtoOptionsPostCreate } from '../dto/postCreate.ts';
|
|
854
856
|
import type { IDtoOptionsProfile } from '../dto/profile.ts';
|
|
855
857
|
import type { IDtoOptionsRoleLazy } from '../dto/roleLazy.ts';
|
|
856
858
|
import type { IDtoOptionsUser } from '../dto/user.ts';
|
|
@@ -861,6 +863,7 @@ import 'vona';
|
|
|
861
863
|
declare module 'vona-module-a-web' {
|
|
862
864
|
interface IDtoRecord {
|
|
863
865
|
'test-vona:categoryTree': IDtoOptionsCategoryTree;
|
|
866
|
+
'test-vona:postCreate': IDtoOptionsPostCreate;
|
|
864
867
|
'test-vona:profile': IDtoOptionsProfile;
|
|
865
868
|
'test-vona:roleLazy': IDtoOptionsRoleLazy;
|
|
866
869
|
'test-vona:user': IDtoOptionsUser;
|
|
@@ -874,6 +877,7 @@ declare module 'vona-module-test-vona' {
|
|
|
874
877
|
/** dto: end */
|
|
875
878
|
/** dto: begin */
|
|
876
879
|
import type { DtoCategoryTree } from '../dto/categoryTree.ts';
|
|
880
|
+
import type { DtoPostCreate } from '../dto/postCreate.ts';
|
|
877
881
|
import type { DtoProfile } from '../dto/profile.ts';
|
|
878
882
|
import type { DtoRoleLazy } from '../dto/roleLazy.ts';
|
|
879
883
|
import type { DtoUser } from '../dto/user.ts';
|
|
@@ -884,6 +888,9 @@ declare module 'vona-module-test-vona' {
|
|
|
884
888
|
interface IDtoOptionsCategoryTree {
|
|
885
889
|
fields?: TypeEntityOptionsFields<DtoCategoryTree, IDtoOptionsCategoryTree[TypeSymbolKeyFieldsMore]>;
|
|
886
890
|
}
|
|
891
|
+
interface IDtoOptionsPostCreate {
|
|
892
|
+
fields?: TypeEntityOptionsFields<DtoPostCreate, IDtoOptionsPostCreate[TypeSymbolKeyFieldsMore]>;
|
|
893
|
+
}
|
|
887
894
|
interface IDtoOptionsProfile {
|
|
888
895
|
fields?: TypeEntityOptionsFields<DtoProfile, IDtoOptionsProfile[TypeSymbolKeyFieldsMore]>;
|
|
889
896
|
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { IDecoratorDtoOptions } from 'vona-module-a-web';
|
|
2
|
+
import { ModelPost } from '../model/post.ts';
|
|
3
|
+
export interface IDtoOptionsPostCreate extends IDecoratorDtoOptions {
|
|
4
|
+
}
|
|
5
|
+
declare const DtoPostCreate_base: import("vona-core").Constructable<import("vona-module-a-orm").TypeDtoMutateResult<ModelPost, undefined, "create", "iid" | "id" | "createdAt" | "updatedAt" | "deleted", true>>;
|
|
6
|
+
export declare class DtoPostCreate extends DtoPostCreate_base {
|
|
7
|
+
}
|
|
8
|
+
export {};
|
package/dist/dto/userCreate.d.ts
CHANGED
|
@@ -3,13 +3,10 @@ export interface IDtoOptionsUserCreate extends IDecoratorDtoOptions {
|
|
|
3
3
|
}
|
|
4
4
|
declare const DtoUserCreate_base: import("vona-core").Constructable<import("vona-module-a-orm").TypeDtoMutateResult<"test-vona:user", {
|
|
5
5
|
include: {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
user: false;
|
|
9
|
-
};
|
|
10
|
-
};
|
|
6
|
+
roles: true;
|
|
7
|
+
posts: true;
|
|
11
8
|
};
|
|
12
|
-
}>>;
|
|
9
|
+
}, "create", "iid" | "id" | "createdAt" | "updatedAt" | "deleted", true>>;
|
|
13
10
|
export declare class DtoUserCreate extends DtoUserCreate_base {
|
|
14
11
|
}
|
|
15
12
|
export {};
|
package/dist/dto/userUpdate.d.ts
CHANGED
|
@@ -1,15 +1,11 @@
|
|
|
1
1
|
import type { IDecoratorDtoOptions } from 'vona-module-a-web';
|
|
2
2
|
export interface IDtoOptionsUserUpdate extends IDecoratorDtoOptions {
|
|
3
3
|
}
|
|
4
|
-
declare const DtoUserUpdate_base: import("vona-core").Constructable<
|
|
4
|
+
declare const DtoUserUpdate_base: import("vona-core").Constructable<import("vona-module-a-orm").TypeDtoMutateResult<"test-vona:user", {
|
|
5
5
|
include: {
|
|
6
|
-
posts:
|
|
7
|
-
include: {
|
|
8
|
-
user: false;
|
|
9
|
-
};
|
|
10
|
-
};
|
|
6
|
+
posts: true;
|
|
11
7
|
};
|
|
12
|
-
}
|
|
8
|
+
}, "update", "iid" | "id" | "createdAt" | "updatedAt" | "deleted", true>>;
|
|
13
9
|
export declare class DtoUserUpdate extends DtoUserUpdate_base {
|
|
14
10
|
}
|
|
15
11
|
export {};
|
package/dist/index.js
CHANGED
|
@@ -21,15 +21,15 @@ import { z } from 'zod';
|
|
|
21
21
|
import { DtoJwtToken } from 'vona-module-a-jwt';
|
|
22
22
|
import { SymbolUploadValue } from 'vona-module-a-upload';
|
|
23
23
|
|
|
24
|
-
var _dec$
|
|
25
|
-
let AopRegExp = (_dec$
|
|
24
|
+
var _dec$X, _dec2$X, _class$X;
|
|
25
|
+
let AopRegExp = (_dec$X = Aop({
|
|
26
26
|
match: [/^test-vona\.service\.test\w+$/, 'testCtx'],
|
|
27
27
|
meta: {
|
|
28
28
|
mode: 'test'
|
|
29
29
|
}
|
|
30
|
-
}), _dec2$
|
|
30
|
+
}), _dec2$X = BeanInfo({
|
|
31
31
|
module: "test-vona"
|
|
32
|
-
}), _dec$
|
|
32
|
+
}), _dec$X(_class$X = _dec2$X(_class$X = class AopRegExp extends BeanAopBase {
|
|
33
33
|
__get_name__(next) {
|
|
34
34
|
const value = next();
|
|
35
35
|
return `${value}:regexpaop`;
|
|
@@ -51,24 +51,24 @@ let AopRegExp = (_dec$W = Aop({
|
|
|
51
51
|
const result = await next();
|
|
52
52
|
return `${result}:regexpaop`;
|
|
53
53
|
}
|
|
54
|
-
}) || _class$
|
|
54
|
+
}) || _class$X) || _class$X);
|
|
55
55
|
|
|
56
|
-
var _dec$
|
|
56
|
+
var _dec$W, _dec2$W, _class$W;
|
|
57
57
|
class AopSimpleBase extends BeanAopBase {
|
|
58
58
|
actionSync(_args, next) {
|
|
59
59
|
const result = next();
|
|
60
60
|
return `${result}:simpleaop`;
|
|
61
61
|
}
|
|
62
62
|
}
|
|
63
|
-
let AopSimple = (_dec$
|
|
63
|
+
let AopSimple = (_dec$W = Aop({
|
|
64
64
|
match: 'testCtx',
|
|
65
65
|
dependencies: 'test-vona:regExp',
|
|
66
66
|
meta: {
|
|
67
67
|
mode: 'test'
|
|
68
68
|
}
|
|
69
|
-
}), _dec2$
|
|
69
|
+
}), _dec2$W = BeanInfo({
|
|
70
70
|
module: "test-vona"
|
|
71
|
-
}), _dec$
|
|
71
|
+
}), _dec$W(_class$W = _dec2$W(_class$W = class AopSimple extends AopSimpleBase {
|
|
72
72
|
// magic
|
|
73
73
|
__get__(prop, next) {
|
|
74
74
|
const value = next();
|
|
@@ -108,14 +108,14 @@ let AopSimple = (_dec$V = Aop({
|
|
|
108
108
|
const result = await next();
|
|
109
109
|
return `${result}:simpleaop`;
|
|
110
110
|
}
|
|
111
|
-
}) || _class$
|
|
111
|
+
}) || _class$W) || _class$W);
|
|
112
112
|
|
|
113
|
-
var _dec$
|
|
114
|
-
let AopMethodTest = (_dec$
|
|
113
|
+
var _dec$V, _dec2$V, _class$V;
|
|
114
|
+
let AopMethodTest = (_dec$V = AopMethod({
|
|
115
115
|
wrapper: ''
|
|
116
|
-
}), _dec2$
|
|
116
|
+
}), _dec2$V = BeanInfo({
|
|
117
117
|
module: "test-vona"
|
|
118
|
-
}), _dec$
|
|
118
|
+
}), _dec$V(_class$V = _dec2$V(_class$V = class AopMethodTest extends BeanAopMethodBase {
|
|
119
119
|
get(options, next, _receiver, _prop) {
|
|
120
120
|
const res = next();
|
|
121
121
|
return this._wrapper(options.wrapper, res);
|
|
@@ -142,7 +142,7 @@ let AopMethodTest = (_dec$U = AopMethod({
|
|
|
142
142
|
if (index === data.length - wrapper.length) data = data.substring(0, index);
|
|
143
143
|
return data;
|
|
144
144
|
}
|
|
145
|
-
}) || _class$
|
|
145
|
+
}) || _class$V) || _class$V);
|
|
146
146
|
|
|
147
147
|
function _applyDecoratedDescriptor(i, e, r, n, l) {
|
|
148
148
|
var a = {};
|
|
@@ -161,10 +161,10 @@ function _initializerDefineProperty(e, i, r, l) {
|
|
|
161
161
|
});
|
|
162
162
|
}
|
|
163
163
|
|
|
164
|
-
var _dec$
|
|
165
|
-
let EntityCategory = (_dec$
|
|
164
|
+
var _dec$U, _dec2$U, _dec3$q, _dec4$q, _dec5$p, _dec6$p, _class$U, _class2$q, _descriptor$a, _descriptor2$9;
|
|
165
|
+
let EntityCategory = (_dec$U = Entity('testVonaCategory'), _dec2$U = BeanInfo({
|
|
166
166
|
module: "test-vona"
|
|
167
|
-
}), _dec3$q = Api.field(), _dec4$q = Reflect.metadata("design:type", String), _dec5$p = Api.field(v.tableIdentity()), _dec6$p = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec$
|
|
167
|
+
}), _dec3$q = Api.field(), _dec4$q = Reflect.metadata("design:type", String), _dec5$p = Api.field(v.tableIdentity()), _dec6$p = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec$U(_class$U = _dec2$U(_class$U = (_class2$q = class EntityCategory extends EntityBase {
|
|
168
168
|
constructor(...args) {
|
|
169
169
|
super(...args);
|
|
170
170
|
_initializerDefineProperty(this, "name", _descriptor$a, this);
|
|
@@ -180,12 +180,12 @@ let EntityCategory = (_dec$T = Entity('testVonaCategory'), _dec2$T = BeanInfo({
|
|
|
180
180
|
enumerable: true,
|
|
181
181
|
writable: true,
|
|
182
182
|
initializer: null
|
|
183
|
-
}), _class2$q)) || _class$
|
|
183
|
+
}), _class2$q)) || _class$U) || _class$U);
|
|
184
184
|
|
|
185
|
-
var _dec$
|
|
186
|
-
let EntityPost = (_dec$
|
|
185
|
+
var _dec$T, _dec2$T, _dec3$p, _dec4$p, _dec5$o, _dec6$o, _dec7$k, _dec8$g, _class$T, _class2$p, _descriptor$9, _descriptor2$8, _descriptor3$4;
|
|
186
|
+
let EntityPost = (_dec$T = Entity('testVonaPost'), _dec2$T = BeanInfo({
|
|
187
187
|
module: "test-vona"
|
|
188
|
-
}), _dec3$p = Api.field(), _dec4$p = Reflect.metadata("design:type", String), _dec5$o = Api.field(v.tableIdentity()), _dec6$o = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec7$k = Api.field(v.optional()), _dec8$g = Reflect.metadata("design:type", Number), _dec$
|
|
188
|
+
}), _dec3$p = Api.field(), _dec4$p = Reflect.metadata("design:type", String), _dec5$o = Api.field(v.tableIdentity()), _dec6$o = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec7$k = Api.field(v.optional()), _dec8$g = Reflect.metadata("design:type", Number), _dec$T(_class$T = _dec2$T(_class$T = (_class2$p = class EntityPost extends EntityBase {
|
|
189
189
|
constructor(...args) {
|
|
190
190
|
super(...args);
|
|
191
191
|
_initializerDefineProperty(this, "title", _descriptor$9, this);
|
|
@@ -207,12 +207,12 @@ let EntityPost = (_dec$S = Entity('testVonaPost'), _dec2$S = BeanInfo({
|
|
|
207
207
|
enumerable: true,
|
|
208
208
|
writable: true,
|
|
209
209
|
initializer: null
|
|
210
|
-
}), _class2$p)) || _class$
|
|
210
|
+
}), _class2$p)) || _class$T) || _class$T);
|
|
211
211
|
|
|
212
|
-
var _dec$
|
|
213
|
-
let EntityPostContent = (_dec$
|
|
212
|
+
var _dec$S, _dec2$S, _dec3$o, _dec4$o, _dec5$n, _dec6$n, _class$S, _class2$o, _descriptor$8, _descriptor2$7;
|
|
213
|
+
let EntityPostContent = (_dec$S = Entity('testVonaPostContent'), _dec2$S = BeanInfo({
|
|
214
214
|
module: "test-vona"
|
|
215
|
-
}), _dec3$o = Api.field(), _dec4$o = Reflect.metadata("design:type", String), _dec5$n = Api.field(v.tableIdentity()), _dec6$n = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec$
|
|
215
|
+
}), _dec3$o = Api.field(), _dec4$o = Reflect.metadata("design:type", String), _dec5$n = Api.field(v.tableIdentity()), _dec6$n = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec$S(_class$S = _dec2$S(_class$S = (_class2$o = class EntityPostContent extends EntityBase {
|
|
216
216
|
constructor(...args) {
|
|
217
217
|
super(...args);
|
|
218
218
|
_initializerDefineProperty(this, "content", _descriptor$8, this);
|
|
@@ -228,12 +228,12 @@ let EntityPostContent = (_dec$R = Entity('testVonaPostContent'), _dec2$R = BeanI
|
|
|
228
228
|
enumerable: true,
|
|
229
229
|
writable: true,
|
|
230
230
|
initializer: null
|
|
231
|
-
}), _class2$o)) || _class$
|
|
231
|
+
}), _class2$o)) || _class$S) || _class$S);
|
|
232
232
|
|
|
233
|
-
var _dec$
|
|
234
|
-
let EntityRole = (_dec$
|
|
233
|
+
var _dec$R, _dec2$R, _dec3$n, _dec4$n, _class$R, _class2$n, _descriptor$7;
|
|
234
|
+
let EntityRole = (_dec$R = Entity('testVonaRole'), _dec2$R = BeanInfo({
|
|
235
235
|
module: "test-vona"
|
|
236
|
-
}), _dec3$n = Api.field(), _dec4$n = Reflect.metadata("design:type", String), _dec$
|
|
236
|
+
}), _dec3$n = Api.field(), _dec4$n = Reflect.metadata("design:type", String), _dec$R(_class$R = _dec2$R(_class$R = (_class2$n = class EntityRole extends EntityBase {
|
|
237
237
|
constructor(...args) {
|
|
238
238
|
super(...args);
|
|
239
239
|
_initializerDefineProperty(this, "name", _descriptor$7, this);
|
|
@@ -243,12 +243,12 @@ let EntityRole = (_dec$Q = Entity('testVonaRole'), _dec2$Q = BeanInfo({
|
|
|
243
243
|
enumerable: true,
|
|
244
244
|
writable: true,
|
|
245
245
|
initializer: null
|
|
246
|
-
}), _class2$n)) || _class$
|
|
246
|
+
}), _class2$n)) || _class$R) || _class$R);
|
|
247
247
|
|
|
248
|
-
var _dec$
|
|
249
|
-
let EntityRoleUser = (_dec$
|
|
248
|
+
var _dec$Q, _dec2$Q, _dec3$m, _dec4$m, _dec5$m, _dec6$m, _class$Q, _class2$m, _descriptor$6, _descriptor2$6;
|
|
249
|
+
let EntityRoleUser = (_dec$Q = Entity('testVonaRoleUser'), _dec2$Q = BeanInfo({
|
|
250
250
|
module: "test-vona"
|
|
251
|
-
}), _dec3$m = Api.field(v.tableIdentity()), _dec4$m = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec5$m = Api.field(v.tableIdentity()), _dec6$m = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec$
|
|
251
|
+
}), _dec3$m = Api.field(v.tableIdentity()), _dec4$m = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec5$m = Api.field(v.tableIdentity()), _dec6$m = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec$Q(_class$Q = _dec2$Q(_class$Q = (_class2$m = class EntityRoleUser extends EntityBase {
|
|
252
252
|
constructor(...args) {
|
|
253
253
|
super(...args);
|
|
254
254
|
_initializerDefineProperty(this, "userId", _descriptor$6, this);
|
|
@@ -264,18 +264,18 @@ let EntityRoleUser = (_dec$P = Entity('testVonaRoleUser'), _dec2$P = BeanInfo({
|
|
|
264
264
|
enumerable: true,
|
|
265
265
|
writable: true,
|
|
266
266
|
initializer: null
|
|
267
|
-
}), _class2$m)) || _class$
|
|
267
|
+
}), _class2$m)) || _class$Q) || _class$Q);
|
|
268
268
|
|
|
269
|
-
var _dec$
|
|
270
|
-
let EntityTest = (_dec$
|
|
269
|
+
var _dec$P, _dec2$P, _dec3$l, _dec4$l, _dec5$l, _dec6$l, _dec7$j, _dec8$f, _class$P, _class2$l, _descriptor$5, _descriptor2$5, _descriptor3$3;
|
|
270
|
+
let EntityTest = (_dec$P = Entity('testVonaTest', {
|
|
271
271
|
openapi: {
|
|
272
272
|
title: $locale('Test')
|
|
273
273
|
}
|
|
274
|
-
}), _dec2$
|
|
274
|
+
}), _dec2$P = BeanInfo({
|
|
275
275
|
module: "test-vona"
|
|
276
276
|
}), _dec3$l = Api.field(v.title($locale('Test'))), _dec4$l = Reflect.metadata("design:type", String), _dec5$l = Api.field(), _dec6$l = Reflect.metadata("design:type", String), _dec7$j = Api.field(v.default(() => {
|
|
277
277
|
return new Date();
|
|
278
|
-
})), _dec8$f = Reflect.metadata("design:type", typeof Date === "undefined" ? Object : Date), _dec$
|
|
278
|
+
})), _dec8$f = Reflect.metadata("design:type", typeof Date === "undefined" ? Object : Date), _dec$P(_class$P = _dec2$P(_class$P = (_class2$l = class EntityTest extends EntityBase {
|
|
279
279
|
constructor(...args) {
|
|
280
280
|
super(...args);
|
|
281
281
|
_initializerDefineProperty(this, "title", _descriptor$5, this);
|
|
@@ -297,12 +297,12 @@ let EntityTest = (_dec$O = Entity('testVonaTest', {
|
|
|
297
297
|
enumerable: true,
|
|
298
298
|
writable: true,
|
|
299
299
|
initializer: null
|
|
300
|
-
}), _class2$l)) || _class$
|
|
300
|
+
}), _class2$l)) || _class$P) || _class$P);
|
|
301
301
|
|
|
302
|
-
var _dec$
|
|
303
|
-
let EntityUser = (_dec$
|
|
302
|
+
var _dec$O, _dec2$O, _dec3$k, _dec4$k, _dec5$k, _dec6$k, _dec7$i, _dec8$e, _class$O, _class2$k, _descriptor$4, _descriptor2$4, _descriptor3$2;
|
|
303
|
+
let EntityUser = (_dec$O = Entity('testVonaUser'), _dec2$O = BeanInfo({
|
|
304
304
|
module: "test-vona"
|
|
305
|
-
}), _dec3$k = Api.field(), _dec4$k = Reflect.metadata("design:type", String), _dec5$k = Api.field(v.optional()), _dec6$k = Reflect.metadata("design:type", Number), _dec7$i = Api.field(v.optional()), _dec8$e = Reflect.metadata("design:type", Number), _dec$
|
|
305
|
+
}), _dec3$k = Api.field(), _dec4$k = Reflect.metadata("design:type", String), _dec5$k = Api.field(v.optional()), _dec6$k = Reflect.metadata("design:type", Number), _dec7$i = Api.field(v.optional()), _dec8$e = Reflect.metadata("design:type", Number), _dec$O(_class$O = _dec2$O(_class$O = (_class2$k = class EntityUser extends EntityBase {
|
|
306
306
|
constructor(...args) {
|
|
307
307
|
super(...args);
|
|
308
308
|
_initializerDefineProperty(this, "name", _descriptor$4, this);
|
|
@@ -324,10 +324,10 @@ let EntityUser = (_dec$N = Entity('testVonaUser'), _dec2$N = BeanInfo({
|
|
|
324
324
|
enumerable: true,
|
|
325
325
|
writable: true,
|
|
326
326
|
initializer: null
|
|
327
|
-
}), _class2$k)) || _class$
|
|
327
|
+
}), _class2$k)) || _class$O) || _class$O);
|
|
328
328
|
|
|
329
|
-
var _dec$
|
|
330
|
-
let ModelCategory = (_dec$
|
|
329
|
+
var _dec$N, _dec2$N, _class$N;
|
|
330
|
+
let ModelCategory = (_dec$N = Model({
|
|
331
331
|
entity: EntityCategory,
|
|
332
332
|
relations: {
|
|
333
333
|
children: $relation.hasMany(() => ModelCategory, 'categoryIdParent', {
|
|
@@ -335,12 +335,12 @@ let ModelCategory = (_dec$M = Model({
|
|
|
335
335
|
columns: ['id', 'name']
|
|
336
336
|
})
|
|
337
337
|
}
|
|
338
|
-
}), _dec2$
|
|
338
|
+
}), _dec2$N = BeanInfo({
|
|
339
339
|
module: "test-vona"
|
|
340
|
-
}), _dec$
|
|
340
|
+
}), _dec$N(_class$N = _dec2$N(_class$N = class ModelCategory extends BeanModelBase {}) || _class$N) || _class$N);
|
|
341
341
|
|
|
342
|
-
var _dec$
|
|
343
|
-
let ModelPostContent = (_dec$
|
|
342
|
+
var _dec$M, _dec2$M, _class$M;
|
|
343
|
+
let ModelPostContent = (_dec$M = Model({
|
|
344
344
|
entity: EntityPostContent,
|
|
345
345
|
relations: {
|
|
346
346
|
post: $relation.belongsTo(ModelPostContent, () => ModelPost, 'postId')
|
|
@@ -348,12 +348,12 @@ let ModelPostContent = (_dec$L = Model({
|
|
|
348
348
|
cache: {
|
|
349
349
|
modelsClear: () => ModelPost
|
|
350
350
|
}
|
|
351
|
-
}), _dec2$
|
|
351
|
+
}), _dec2$M = BeanInfo({
|
|
352
352
|
module: "test-vona"
|
|
353
|
-
}), _dec$
|
|
353
|
+
}), _dec$M(_class$M = _dec2$M(_class$M = class ModelPostContent extends BeanModelBase {}) || _class$M) || _class$M);
|
|
354
354
|
|
|
355
|
-
var _dec$
|
|
356
|
-
let ModelUserStats = (_dec$
|
|
355
|
+
var _dec$L, _dec2$L, _class$L;
|
|
356
|
+
let ModelUserStats = (_dec$L = Model({
|
|
357
357
|
entity: EntityUser,
|
|
358
358
|
relations: {
|
|
359
359
|
posts: $relation.hasMany(() => ModelPost, 'userId', {
|
|
@@ -369,12 +369,12 @@ let ModelUserStats = (_dec$K = Model({
|
|
|
369
369
|
}
|
|
370
370
|
})
|
|
371
371
|
}
|
|
372
|
-
}), _dec2$
|
|
372
|
+
}), _dec2$L = BeanInfo({
|
|
373
373
|
module: "test-vona"
|
|
374
|
-
}), _dec$
|
|
374
|
+
}), _dec$L(_class$L = _dec2$L(_class$L = class ModelUserStats extends BeanModelBase {}) || _class$L) || _class$L);
|
|
375
375
|
|
|
376
|
-
var _dec$
|
|
377
|
-
let ModelUserStatsGroup = (_dec$
|
|
376
|
+
var _dec$K, _dec2$K, _class$K;
|
|
377
|
+
let ModelUserStatsGroup = (_dec$K = Model({
|
|
378
378
|
entity: EntityUser,
|
|
379
379
|
relations: {
|
|
380
380
|
posts: $relation.hasMany(() => ModelPost, 'userId', {
|
|
@@ -394,12 +394,12 @@ let ModelUserStatsGroup = (_dec$J = Model({
|
|
|
394
394
|
orders: [['name', 'asc']]
|
|
395
395
|
}, undefined, true)
|
|
396
396
|
}
|
|
397
|
-
}), _dec2$
|
|
397
|
+
}), _dec2$K = BeanInfo({
|
|
398
398
|
module: "test-vona"
|
|
399
|
-
}), _dec$
|
|
399
|
+
}), _dec$K(_class$K = _dec2$K(_class$K = class ModelUserStatsGroup extends BeanModelBase {}) || _class$K) || _class$K);
|
|
400
400
|
|
|
401
|
-
var _dec$
|
|
402
|
-
let ModelUser = (_dec$
|
|
401
|
+
var _dec$J, _dec2$J, _class$J;
|
|
402
|
+
let ModelUser = (_dec$J = Model({
|
|
403
403
|
entity: EntityUser,
|
|
404
404
|
relations: {
|
|
405
405
|
posts: $relation.hasMany(() => ModelPost, 'userId', {
|
|
@@ -412,12 +412,12 @@ let ModelUser = (_dec$I = Model({
|
|
|
412
412
|
cache: {
|
|
413
413
|
modelsClear: [() => ModelUserStats, () => ModelUserStatsGroup]
|
|
414
414
|
}
|
|
415
|
-
}), _dec2$
|
|
415
|
+
}), _dec2$J = BeanInfo({
|
|
416
416
|
module: "test-vona"
|
|
417
|
-
}), _dec$
|
|
417
|
+
}), _dec$J(_class$J = _dec2$J(_class$J = class ModelUser extends BeanModelBase {}) || _class$J) || _class$J);
|
|
418
418
|
|
|
419
|
-
var _dec$
|
|
420
|
-
let ModelPost = (_dec$
|
|
419
|
+
var _dec$I, _dec2$I, _class$I;
|
|
420
|
+
let ModelPost = (_dec$I = Model({
|
|
421
421
|
entity: EntityPost,
|
|
422
422
|
relations: {
|
|
423
423
|
postContent: $relation.hasOne('test-vona:postContent', 'postId', {
|
|
@@ -428,39 +428,39 @@ let ModelPost = (_dec$H = Model({
|
|
|
428
428
|
columns: ['id', 'name']
|
|
429
429
|
})
|
|
430
430
|
}
|
|
431
|
-
}), _dec2$
|
|
431
|
+
}), _dec2$I = BeanInfo({
|
|
432
432
|
module: "test-vona"
|
|
433
|
-
}), _dec$
|
|
433
|
+
}), _dec$I(_class$I = _dec2$I(_class$I = class ModelPost extends BeanModelBase {}) || _class$I) || _class$I);
|
|
434
434
|
|
|
435
|
-
var _dec$
|
|
436
|
-
let ModelRoleUser = (_dec$
|
|
435
|
+
var _dec$H, _dec2$H, _class$H;
|
|
436
|
+
let ModelRoleUser = (_dec$H = Model({
|
|
437
437
|
entity: EntityRoleUser
|
|
438
|
-
}), _dec2$
|
|
438
|
+
}), _dec2$H = BeanInfo({
|
|
439
439
|
module: "test-vona"
|
|
440
|
-
}), _dec$
|
|
440
|
+
}), _dec$H(_class$H = _dec2$H(_class$H = class ModelRoleUser extends BeanModelBase {}) || _class$H) || _class$H);
|
|
441
441
|
|
|
442
|
-
var _dec$
|
|
443
|
-
let ModelRole = (_dec$
|
|
442
|
+
var _dec$G, _dec2$G, _class$G;
|
|
443
|
+
let ModelRole = (_dec$G = Model({
|
|
444
444
|
entity: EntityRole,
|
|
445
445
|
relations: {
|
|
446
446
|
users: $relation.belongsToMany(() => ModelRoleUser, () => ModelUser, 'roleId', 'userId', {
|
|
447
447
|
columns: ['id', 'name']
|
|
448
448
|
})
|
|
449
449
|
}
|
|
450
|
-
}), _dec2$
|
|
450
|
+
}), _dec2$G = BeanInfo({
|
|
451
451
|
module: "test-vona"
|
|
452
|
-
}), _dec$
|
|
452
|
+
}), _dec$G(_class$G = _dec2$G(_class$G = class ModelRole extends BeanModelBase {}) || _class$G) || _class$G);
|
|
453
453
|
|
|
454
|
-
var _dec$
|
|
455
|
-
let ModelTest = (_dec$
|
|
454
|
+
var _dec$F, _dec2$F, _class$F;
|
|
455
|
+
let ModelTest = (_dec$F = Model({
|
|
456
456
|
entity: EntityTest,
|
|
457
457
|
client: 'default'
|
|
458
|
-
}), _dec2$
|
|
458
|
+
}), _dec2$F = BeanInfo({
|
|
459
459
|
module: "test-vona"
|
|
460
|
-
}), _dec$
|
|
460
|
+
}), _dec$F(_class$F = _dec2$F(_class$F = class ModelTest extends BeanModelBase {}) || _class$F) || _class$F);
|
|
461
461
|
|
|
462
|
-
var _dec$
|
|
463
|
-
let ModelTestDynamicTable = (_dec$
|
|
462
|
+
var _dec$E, _dec2$E, _class$E;
|
|
463
|
+
let ModelTestDynamicTable = (_dec$E = Model({
|
|
464
464
|
entity: EntityTest,
|
|
465
465
|
table(ctx, defaultTable) {
|
|
466
466
|
if (ctx.instanceName !== '') return defaultTable;
|
|
@@ -471,11 +471,11 @@ let ModelTestDynamicTable = (_dec$D = Model({
|
|
|
471
471
|
// do nothing
|
|
472
472
|
}
|
|
473
473
|
}
|
|
474
|
-
}), _dec2$
|
|
474
|
+
}), _dec2$E = BeanInfo({
|
|
475
475
|
module: "test-vona"
|
|
476
|
-
}), _dec$
|
|
476
|
+
}), _dec$E(_class$E = _dec2$E(_class$E = class ModelTestDynamicTable extends BeanModelBase {}) || _class$E) || _class$E);
|
|
477
477
|
|
|
478
|
-
var _dec$
|
|
478
|
+
var _dec$D, _dec2$D, _class$D;
|
|
479
479
|
class TestCtx0 extends BeanBase {
|
|
480
480
|
constructor(...args) {
|
|
481
481
|
super(...args);
|
|
@@ -537,20 +537,20 @@ class TestCtx1 extends TestCtx0 {
|
|
|
537
537
|
});
|
|
538
538
|
}
|
|
539
539
|
}
|
|
540
|
-
let BeanTestCtx = (_dec$
|
|
540
|
+
let BeanTestCtx = (_dec$D = Bean(), _dec2$D = BeanInfo({
|
|
541
541
|
module: "test-vona"
|
|
542
|
-
}), _dec$
|
|
542
|
+
}), _dec$D(_class$D = _dec2$D(_class$D = class BeanTestCtx extends TestCtx1 {}) || _class$D) || _class$D);
|
|
543
543
|
|
|
544
|
-
var _dec$
|
|
545
|
-
let ServiceAopMethodBase = (_dec$
|
|
544
|
+
var _dec$C, _dec2$C, _dec3$j, _dec4$j, _class$C, _dec5$j, _dec6$j, _dec7$h, _dec8$d, _dec9$9, _dec0$9, _dec1$9, _dec10$7, _dec11$7, _dec12$7, _dec13$7, _dec14$6, _dec15$6, _dec16$6, _class2$j, _class3;
|
|
545
|
+
let ServiceAopMethodBase = (_dec$C = Aspect.aopMethod('test-vona:test', {
|
|
546
546
|
wrapper: '+'
|
|
547
|
-
}), _dec2$
|
|
547
|
+
}), _dec2$C = Aspect.aopMethod('test-vona:test', {
|
|
548
548
|
wrapper: '-'
|
|
549
|
-
}), _dec3$j = Reflect.metadata("design:type", Function), _dec4$j = Reflect.metadata("design:paramtypes", []), _class$
|
|
549
|
+
}), _dec3$j = Reflect.metadata("design:type", Function), _dec4$j = Reflect.metadata("design:paramtypes", []), _class$C = class ServiceAopMethodBase extends BeanBase {
|
|
550
550
|
testSyncBase() {
|
|
551
551
|
return 'hello';
|
|
552
552
|
}
|
|
553
|
-
}, _applyDecoratedDescriptor(_class$
|
|
553
|
+
}, _applyDecoratedDescriptor(_class$C.prototype, "testSyncBase", [_dec$C, _dec2$C, _dec3$j, _dec4$j], Object.getOwnPropertyDescriptor(_class$C.prototype, "testSyncBase"), _class$C.prototype), _class$C);
|
|
554
554
|
let ServiceAopMethod = (_dec5$j = Service(), _dec6$j = BeanInfo({
|
|
555
555
|
module: "test-vona"
|
|
556
556
|
}), _dec7$h = Aspect.aopMethod('test-vona:test', {
|
|
@@ -584,11 +584,11 @@ let ServiceAopMethod = (_dec5$j = Service(), _dec6$j = BeanInfo({
|
|
|
584
584
|
}
|
|
585
585
|
}, _applyDecoratedDescriptor(_class3.prototype, "testSync", [_dec7$h, _dec8$d, _dec9$9, _dec0$9], Object.getOwnPropertyDescriptor(_class3.prototype, "testSync"), _class3.prototype), _applyDecoratedDescriptor(_class3.prototype, "testAsync", [_dec1$9, _dec10$7, _dec11$7, _dec12$7], Object.getOwnPropertyDescriptor(_class3.prototype, "testAsync"), _class3.prototype), _applyDecoratedDescriptor(_class3.prototype, "name", [_dec13$7, _dec14$6, _dec15$6, _dec16$6], Object.getOwnPropertyDescriptor(_class3.prototype, "name"), _class3.prototype), _class3)) || _class2$j) || _class2$j);
|
|
586
586
|
|
|
587
|
-
var _dec$
|
|
587
|
+
var _dec$B, _dec2$B, _dec3$i, _dec4$i, _dec5$i, _dec6$i, _dec7$g, _dec8$c, _dec9$8, _dec0$8, _dec1$8, _dec10$6, _dec11$6, _dec12$6, _dec13$6, _dec14$5, _dec15$5, _dec16$5, _dec17$4, _dec18$4, _dec19$4, _dec20$4, _dec21$4, _dec22$4, _dec23$4, _dec24$4, _dec25$4, _dec26$3, _dec27$3, _class$B, _class2$i;
|
|
588
588
|
function cacheKeyFn(args, prop, options) {
|
|
589
589
|
return `${this.$beanFullName}_${options.cacheProp ?? prop}_${getKeyHash(args)}`;
|
|
590
590
|
}
|
|
591
|
-
let ServiceCaching = (_dec$
|
|
591
|
+
let ServiceCaching = (_dec$B = Service(), _dec2$B = BeanInfo({
|
|
592
592
|
module: "test-vona"
|
|
593
593
|
}), _dec3$i = Caching.get({
|
|
594
594
|
cacheName: 'test-vona:test',
|
|
@@ -624,7 +624,7 @@ let ServiceCaching = (_dec$A = Service(), _dec2$A = BeanInfo({
|
|
|
624
624
|
cacheProp: 'test'
|
|
625
625
|
}), _dec23$4 = Reflect.metadata("design:type", Function), _dec24$4 = Reflect.metadata("design:paramtypes", [Number]), _dec25$4 = Caching.clear({
|
|
626
626
|
cacheName: 'test-vona:test'
|
|
627
|
-
}), _dec26$3 = Reflect.metadata("design:type", Function), _dec27$3 = Reflect.metadata("design:paramtypes", []), _dec$
|
|
627
|
+
}), _dec26$3 = Reflect.metadata("design:type", Function), _dec27$3 = Reflect.metadata("design:paramtypes", []), _dec$B(_class$B = _dec2$B(_class$B = (_class2$i = class ServiceCaching extends BeanBase {
|
|
628
628
|
cacheKey(args, prop, options) {
|
|
629
629
|
return `${this.$beanFullName}_${options.cacheProp ?? prop}_${getKeyHash(args)}`;
|
|
630
630
|
}
|
|
@@ -668,21 +668,21 @@ let ServiceCaching = (_dec$A = Service(), _dec2$A = BeanInfo({
|
|
|
668
668
|
async clear() {
|
|
669
669
|
// do nothing
|
|
670
670
|
}
|
|
671
|
-
}, _applyDecoratedDescriptor(_class2$i.prototype, "get", [_dec3$i, _dec4$i, _dec5$i], Object.getOwnPropertyDescriptor(_class2$i.prototype, "get"), _class2$i.prototype), _applyDecoratedDescriptor(_class2$i.prototype, "get2", [_dec6$i, _dec7$g, _dec8$c], Object.getOwnPropertyDescriptor(_class2$i.prototype, "get2"), _class2$i.prototype), _applyDecoratedDescriptor(_class2$i.prototype, "get3", [_dec9$8, _dec0$8, _dec1$8], Object.getOwnPropertyDescriptor(_class2$i.prototype, "get3"), _class2$i.prototype), _applyDecoratedDescriptor(_class2$i.prototype, "get4", [_dec10$6, _dec11$6, _dec12$6], Object.getOwnPropertyDescriptor(_class2$i.prototype, "get4"), _class2$i.prototype), _applyDecoratedDescriptor(_class2$i.prototype, "set", [_dec13$6, _dec14$5, _dec15$5], Object.getOwnPropertyDescriptor(_class2$i.prototype, "set"), _class2$i.prototype), _applyDecoratedDescriptor(_class2$i.prototype, "set2", [_dec16$5, _dec17$4, _dec18$4], Object.getOwnPropertyDescriptor(_class2$i.prototype, "set2"), _class2$i.prototype), _applyDecoratedDescriptor(_class2$i.prototype, "set3", [_dec19$4, _dec20$4, _dec21$4], Object.getOwnPropertyDescriptor(_class2$i.prototype, "set3"), _class2$i.prototype), _applyDecoratedDescriptor(_class2$i.prototype, "del", [_dec22$4, _dec23$4, _dec24$4], Object.getOwnPropertyDescriptor(_class2$i.prototype, "del"), _class2$i.prototype), _applyDecoratedDescriptor(_class2$i.prototype, "clear", [_dec25$4, _dec26$3, _dec27$3], Object.getOwnPropertyDescriptor(_class2$i.prototype, "clear"), _class2$i.prototype), _class2$i)) || _class$
|
|
671
|
+
}, _applyDecoratedDescriptor(_class2$i.prototype, "get", [_dec3$i, _dec4$i, _dec5$i], Object.getOwnPropertyDescriptor(_class2$i.prototype, "get"), _class2$i.prototype), _applyDecoratedDescriptor(_class2$i.prototype, "get2", [_dec6$i, _dec7$g, _dec8$c], Object.getOwnPropertyDescriptor(_class2$i.prototype, "get2"), _class2$i.prototype), _applyDecoratedDescriptor(_class2$i.prototype, "get3", [_dec9$8, _dec0$8, _dec1$8], Object.getOwnPropertyDescriptor(_class2$i.prototype, "get3"), _class2$i.prototype), _applyDecoratedDescriptor(_class2$i.prototype, "get4", [_dec10$6, _dec11$6, _dec12$6], Object.getOwnPropertyDescriptor(_class2$i.prototype, "get4"), _class2$i.prototype), _applyDecoratedDescriptor(_class2$i.prototype, "set", [_dec13$6, _dec14$5, _dec15$5], Object.getOwnPropertyDescriptor(_class2$i.prototype, "set"), _class2$i.prototype), _applyDecoratedDescriptor(_class2$i.prototype, "set2", [_dec16$5, _dec17$4, _dec18$4], Object.getOwnPropertyDescriptor(_class2$i.prototype, "set2"), _class2$i.prototype), _applyDecoratedDescriptor(_class2$i.prototype, "set3", [_dec19$4, _dec20$4, _dec21$4], Object.getOwnPropertyDescriptor(_class2$i.prototype, "set3"), _class2$i.prototype), _applyDecoratedDescriptor(_class2$i.prototype, "del", [_dec22$4, _dec23$4, _dec24$4], Object.getOwnPropertyDescriptor(_class2$i.prototype, "del"), _class2$i.prototype), _applyDecoratedDescriptor(_class2$i.prototype, "clear", [_dec25$4, _dec26$3, _dec27$3], Object.getOwnPropertyDescriptor(_class2$i.prototype, "clear"), _class2$i.prototype), _class2$i)) || _class$B) || _class$B);
|
|
672
672
|
|
|
673
|
-
var _dec$
|
|
674
|
-
let ServiceTest = (_dec$
|
|
673
|
+
var _dec$A, _dec2$A, _class$A;
|
|
674
|
+
let ServiceTest = (_dec$A = Service(), _dec2$A = BeanInfo({
|
|
675
675
|
module: "test-vona"
|
|
676
|
-
}), _dec$
|
|
676
|
+
}), _dec$A(_class$A = _dec2$A(_class$A = class ServiceTest extends BeanBase {
|
|
677
677
|
get name() {
|
|
678
678
|
return 'serviceTest';
|
|
679
679
|
}
|
|
680
|
-
}) || _class$
|
|
680
|
+
}) || _class$A) || _class$A);
|
|
681
681
|
|
|
682
|
-
var _dec$
|
|
683
|
-
let ServiceTestApp = (_dec$
|
|
682
|
+
var _dec$z, _dec2$z, _class$z;
|
|
683
|
+
let ServiceTestApp = (_dec$z = Service(), _dec2$z = BeanInfo({
|
|
684
684
|
module: "test-vona"
|
|
685
|
-
}), _dec$
|
|
685
|
+
}), _dec$z(_class$z = _dec2$z(_class$z = class ServiceTestApp extends BeanBase {
|
|
686
686
|
actionSync({
|
|
687
687
|
a,
|
|
688
688
|
b
|
|
@@ -695,9 +695,9 @@ let ServiceTestApp = (_dec$y = Service(), _dec2$y = BeanInfo({
|
|
|
695
695
|
}) {
|
|
696
696
|
return Promise.resolve(a + b);
|
|
697
697
|
}
|
|
698
|
-
}) || _class$
|
|
698
|
+
}) || _class$z) || _class$z);
|
|
699
699
|
|
|
700
|
-
var _dec$
|
|
700
|
+
var _dec$y, _dec2$y, _class$y;
|
|
701
701
|
class ClassBeanBase extends BeanBase {
|
|
702
702
|
actionSync({
|
|
703
703
|
a,
|
|
@@ -706,21 +706,21 @@ class ClassBeanBase extends BeanBase {
|
|
|
706
706
|
return a + b;
|
|
707
707
|
}
|
|
708
708
|
}
|
|
709
|
-
let ServiceTestClass = (_dec$
|
|
709
|
+
let ServiceTestClass = (_dec$y = Service(), _dec2$y = BeanInfo({
|
|
710
710
|
module: "test-vona"
|
|
711
|
-
}), _dec$
|
|
711
|
+
}), _dec$y(_class$y = _dec2$y(_class$y = class ServiceTestClass extends ClassBeanBase {
|
|
712
712
|
async actionAsync({
|
|
713
713
|
a,
|
|
714
714
|
b
|
|
715
715
|
}) {
|
|
716
716
|
return Promise.resolve(a + b);
|
|
717
717
|
}
|
|
718
|
-
}) || _class$
|
|
718
|
+
}) || _class$y) || _class$y);
|
|
719
719
|
|
|
720
|
-
var _dec$
|
|
721
|
-
let ServiceTestData = (_dec$
|
|
720
|
+
var _dec$x, _dec2$x, _class$x;
|
|
721
|
+
let ServiceTestData = (_dec$x = Service(), _dec2$x = BeanInfo({
|
|
722
722
|
module: "test-vona"
|
|
723
|
-
}), _dec$
|
|
723
|
+
}), _dec$x(_class$x = _dec2$x(_class$x = class ServiceTestData extends BeanBase {
|
|
724
724
|
async create(prefix) {
|
|
725
725
|
const scopeTest = this.scope;
|
|
726
726
|
const userTom = await scopeTest.model.user.insert({
|
|
@@ -807,14 +807,14 @@ let ServiceTestData = (_dec$w = Service(), _dec2$w = BeanInfo({
|
|
|
807
807
|
id: userJimmy.id
|
|
808
808
|
});
|
|
809
809
|
}
|
|
810
|
-
}) || _class$
|
|
810
|
+
}) || _class$x) || _class$x);
|
|
811
811
|
|
|
812
|
-
var _dec$
|
|
812
|
+
var _dec$w, _dec2$w, _dec3$h, _dec4$h, _dec5$h, _dec6$h, _dec7$f, _dec8$b, _class$w, _class2$h;
|
|
813
813
|
const tableNameFail$1 = '__tempTransactionFail';
|
|
814
814
|
const tableNameSuccess$1 = '__tempTransactionSuccess';
|
|
815
|
-
let ServiceTransaction = (_dec$
|
|
815
|
+
let ServiceTransaction = (_dec$w = Service(), _dec2$w = BeanInfo({
|
|
816
816
|
module: "test-vona"
|
|
817
|
-
}), _dec3$h = Database.transaction(), _dec4$h = Reflect.metadata("design:type", Function), _dec5$h = Reflect.metadata("design:paramtypes", [Object]), _dec6$h = Database.transaction(), _dec7$f = Reflect.metadata("design:type", Function), _dec8$b = Reflect.metadata("design:paramtypes", [Object]), _dec$
|
|
817
|
+
}), _dec3$h = Database.transaction(), _dec4$h = Reflect.metadata("design:type", Function), _dec5$h = Reflect.metadata("design:paramtypes", [Object]), _dec6$h = Database.transaction(), _dec7$f = Reflect.metadata("design:type", Function), _dec8$b = Reflect.metadata("design:paramtypes", [Object]), _dec$w(_class$w = _dec2$w(_class$w = (_class2$h = class ServiceTransaction extends BeanBase {
|
|
818
818
|
async fail(item) {
|
|
819
819
|
await this.bean.model.update(`${tableNameFail$1}`, item);
|
|
820
820
|
await this.bean.model.update(`${tableNameFail$1}error`, item);
|
|
@@ -822,56 +822,56 @@ let ServiceTransaction = (_dec$v = Service(), _dec2$v = BeanInfo({
|
|
|
822
822
|
async success(item) {
|
|
823
823
|
await this.bean.model.update(tableNameSuccess$1, item);
|
|
824
824
|
}
|
|
825
|
-
}, _applyDecoratedDescriptor(_class2$h.prototype, "fail", [_dec3$h, _dec4$h, _dec5$h], Object.getOwnPropertyDescriptor(_class2$h.prototype, "fail"), _class2$h.prototype), _applyDecoratedDescriptor(_class2$h.prototype, "success", [_dec6$h, _dec7$f, _dec8$b], Object.getOwnPropertyDescriptor(_class2$h.prototype, "success"), _class2$h.prototype), _class2$h)) || _class$
|
|
825
|
+
}, _applyDecoratedDescriptor(_class2$h.prototype, "fail", [_dec3$h, _dec4$h, _dec5$h], Object.getOwnPropertyDescriptor(_class2$h.prototype, "fail"), _class2$h.prototype), _applyDecoratedDescriptor(_class2$h.prototype, "success", [_dec6$h, _dec7$f, _dec8$b], Object.getOwnPropertyDescriptor(_class2$h.prototype, "success"), _class2$h.prototype), _class2$h)) || _class$w) || _class$w);
|
|
826
826
|
|
|
827
|
-
var _dec$
|
|
828
|
-
let BroadcastTest = (_dec$
|
|
827
|
+
var _dec$v, _dec2$v, _class$v;
|
|
828
|
+
let BroadcastTest = (_dec$v = Broadcast(), _dec2$v = BeanInfo({
|
|
829
829
|
module: "test-vona"
|
|
830
|
-
}), _dec$
|
|
830
|
+
}), _dec$v(_class$v = _dec2$v(_class$v = class BroadcastTest extends BeanBroadcastBase {
|
|
831
831
|
async execute(data, isEmitter) {
|
|
832
832
|
// locale
|
|
833
833
|
assert.equal(this.ctx.locale, 'zh-cn');
|
|
834
834
|
// data
|
|
835
835
|
assert.equal(data.message, 'hello');
|
|
836
836
|
}
|
|
837
|
-
}) || _class$
|
|
837
|
+
}) || _class$v) || _class$v);
|
|
838
|
+
|
|
839
|
+
var _dec$u, _dec2$u, _class$u;
|
|
840
|
+
let CacheMemTest = (_dec$u = CacheMem({
|
|
841
|
+
ttl: 1 * 1000
|
|
842
|
+
}), _dec2$u = BeanInfo({
|
|
843
|
+
module: "test-vona"
|
|
844
|
+
}), _dec$u(_class$u = _dec2$u(_class$u = class CacheMemTest extends BeanCacheMemBase {}) || _class$u) || _class$u);
|
|
838
845
|
|
|
839
846
|
var _dec$t, _dec2$t, _class$t;
|
|
840
|
-
let
|
|
847
|
+
let CacheRedisTest = (_dec$t = CacheRedis({
|
|
841
848
|
ttl: 1 * 1000
|
|
842
849
|
}), _dec2$t = BeanInfo({
|
|
843
850
|
module: "test-vona"
|
|
844
|
-
}), _dec$t(_class$t = _dec2$t(_class$t = class
|
|
851
|
+
}), _dec$t(_class$t = _dec2$t(_class$t = class CacheRedisTest extends BeanCacheRedisBase {}) || _class$t) || _class$t);
|
|
845
852
|
|
|
846
853
|
var _dec$s, _dec2$s, _class$s;
|
|
847
|
-
let
|
|
848
|
-
ttl: 1 * 1000
|
|
849
|
-
}), _dec2$s = BeanInfo({
|
|
854
|
+
let EventHelloEcho = (_dec$s = Event(), _dec2$s = BeanInfo({
|
|
850
855
|
module: "test-vona"
|
|
851
|
-
}), _dec$s(_class$s = _dec2$s(_class$s = class
|
|
856
|
+
}), _dec$s(_class$s = _dec2$s(_class$s = class EventHelloEcho extends BeanEventBase {}) || _class$s) || _class$s);
|
|
852
857
|
|
|
853
858
|
var _dec$r, _dec2$r, _class$r;
|
|
854
|
-
let
|
|
855
|
-
module: "test-vona"
|
|
856
|
-
}), _dec$r(_class$r = _dec2$r(_class$r = class EventHelloEcho extends BeanEventBase {}) || _class$r) || _class$r);
|
|
857
|
-
|
|
858
|
-
var _dec$q, _dec2$q, _class$q;
|
|
859
|
-
let EventListenerHelloEcho = (_dec$q = EventListener({
|
|
859
|
+
let EventListenerHelloEcho = (_dec$r = EventListener({
|
|
860
860
|
match: 'test-vona:helloEcho'
|
|
861
|
-
}), _dec2$
|
|
861
|
+
}), _dec2$r = BeanInfo({
|
|
862
862
|
module: "test-vona"
|
|
863
|
-
}), _dec$
|
|
863
|
+
}), _dec$r(_class$r = _dec2$r(_class$r = class EventListenerHelloEcho extends BeanBase {
|
|
864
864
|
async execute(data, next) {
|
|
865
865
|
// next
|
|
866
866
|
const result = await next();
|
|
867
867
|
return `${data.text} ${result}`;
|
|
868
868
|
}
|
|
869
|
-
}) || _class$
|
|
869
|
+
}) || _class$r) || _class$r);
|
|
870
870
|
|
|
871
|
-
var _dec$
|
|
872
|
-
let MetaVersion = (_dec$
|
|
871
|
+
var _dec$q, _dec2$q, _class$q;
|
|
872
|
+
let MetaVersion = (_dec$q = Meta(), _dec2$q = BeanInfo({
|
|
873
873
|
module: "test-vona"
|
|
874
|
-
}), _dec$
|
|
874
|
+
}), _dec$q(_class$q = _dec2$q(_class$q = class MetaVersion extends BeanBase {
|
|
875
875
|
async update(options) {
|
|
876
876
|
if (options.version === 1) {
|
|
877
877
|
// testVonaTest
|
|
@@ -927,47 +927,47 @@ let MetaVersion = (_dec$p = Meta(), _dec2$p = BeanInfo({
|
|
|
927
927
|
});
|
|
928
928
|
}
|
|
929
929
|
}
|
|
930
|
-
}) || _class$
|
|
930
|
+
}) || _class$q) || _class$q);
|
|
931
931
|
|
|
932
|
-
var _dec$
|
|
933
|
-
let QueueTest = (_dec$
|
|
932
|
+
var _dec$p, _dec2$p, _class$p;
|
|
933
|
+
let QueueTest = (_dec$p = Queue(), _dec2$p = BeanInfo({
|
|
934
934
|
module: "test-vona"
|
|
935
|
-
}), _dec$
|
|
935
|
+
}), _dec$p(_class$p = _dec2$p(_class$p = class QueueTest extends BeanQueueBase {
|
|
936
936
|
async execute(data, _options) {
|
|
937
937
|
return data.a + data.b;
|
|
938
938
|
}
|
|
939
|
-
}) || _class$
|
|
939
|
+
}) || _class$p) || _class$p);
|
|
940
940
|
|
|
941
|
-
var _dec$
|
|
942
|
-
let ScheduleTest = (_dec$
|
|
941
|
+
var _dec$o, _dec2$o, _class$o;
|
|
942
|
+
let ScheduleTest = (_dec$o = Schedule({
|
|
943
943
|
enable: false,
|
|
944
944
|
repeat: {
|
|
945
945
|
every: 3000
|
|
946
946
|
}
|
|
947
|
-
}), _dec2$
|
|
947
|
+
}), _dec2$o = BeanInfo({
|
|
948
948
|
module: "test-vona"
|
|
949
|
-
}), _dec$
|
|
949
|
+
}), _dec$o(_class$o = _dec2$o(_class$o = class ScheduleTest extends BeanBase {
|
|
950
950
|
async execute(job) {
|
|
951
951
|
this.$logger.silly(`Schedule Test: iid=${this.ctx.instance.id}, every=${job?.data.options?.jobOptions?.repeat?.every}, ${new Date()}`);
|
|
952
952
|
}
|
|
953
|
-
}) || _class$
|
|
953
|
+
}) || _class$o) || _class$o);
|
|
954
954
|
|
|
955
|
-
var _dec$
|
|
956
|
-
let ScheduleTest3 = (_dec$
|
|
955
|
+
var _dec$n, _dec2$n, _class$n;
|
|
956
|
+
let ScheduleTest3 = (_dec$n = Schedule({
|
|
957
957
|
enable: false,
|
|
958
958
|
repeat: {
|
|
959
959
|
every: 5000
|
|
960
960
|
}
|
|
961
|
-
}), _dec2$
|
|
961
|
+
}), _dec2$n = BeanInfo({
|
|
962
962
|
module: "test-vona"
|
|
963
|
-
}), _dec$
|
|
963
|
+
}), _dec$n(_class$n = _dec2$n(_class$n = class ScheduleTest3 extends BeanBase {
|
|
964
964
|
async execute(job) {
|
|
965
965
|
this.$logger.silly(`Schedule Test3: iid=${this.ctx.instance.id}, every=${job?.data.options?.jobOptions?.repeat?.every}, ${new Date()}`);
|
|
966
966
|
}
|
|
967
|
-
}) || _class$
|
|
967
|
+
}) || _class$n) || _class$n);
|
|
968
968
|
|
|
969
|
-
var _dec$
|
|
970
|
-
let SummerCacheTest = (_dec$
|
|
969
|
+
var _dec$m, _dec2$m, _class$m;
|
|
970
|
+
let SummerCacheTest = (_dec$m = SummerCache({
|
|
971
971
|
mode: 'all',
|
|
972
972
|
mem: {
|
|
973
973
|
max: 2,
|
|
@@ -976,23 +976,30 @@ let SummerCacheTest = (_dec$l = SummerCache({
|
|
|
976
976
|
redis: {
|
|
977
977
|
ttl: 3 * 1000
|
|
978
978
|
}
|
|
979
|
-
}), _dec2$
|
|
979
|
+
}), _dec2$m = BeanInfo({
|
|
980
980
|
module: "test-vona"
|
|
981
|
-
}), _dec$
|
|
981
|
+
}), _dec$m(_class$m = _dec2$m(_class$m = class SummerCacheTest extends BeanSummerCacheBase {
|
|
982
982
|
async getNative(key, _options) {
|
|
983
983
|
return {
|
|
984
984
|
id: key.id,
|
|
985
985
|
name: `name_${key.id}`
|
|
986
986
|
};
|
|
987
987
|
}
|
|
988
|
-
}) || _class$
|
|
988
|
+
}) || _class$m) || _class$m);
|
|
989
989
|
|
|
990
|
-
var _dec$
|
|
991
|
-
let DtoCategoryTree = (_dec$
|
|
990
|
+
var _dec$l, _dec2$l, _class$l;
|
|
991
|
+
let DtoCategoryTree = (_dec$l = Dto(), _dec2$l = BeanInfo({
|
|
992
992
|
module: "test-vona"
|
|
993
|
-
}), _dec$
|
|
993
|
+
}), _dec$l(_class$l = _dec2$l(_class$l = class DtoCategoryTree extends $Dto.get('test-vona:category', {
|
|
994
994
|
columns: ['id', 'name']
|
|
995
|
-
}) {}) || _class$
|
|
995
|
+
}) {}) || _class$l) || _class$l);
|
|
996
|
+
|
|
997
|
+
var _dec$k, _dec2$k, _class$k;
|
|
998
|
+
let DtoPostCreate = (_dec$k = Dto({
|
|
999
|
+
independent: true
|
|
1000
|
+
}), _dec2$k = BeanInfo({
|
|
1001
|
+
module: "test-vona"
|
|
1002
|
+
}), _dec$k(_class$k = _dec2$k(_class$k = class DtoPostCreate extends $Dto.create(() => ModelPost) {}) || _class$k) || _class$k);
|
|
996
1003
|
|
|
997
1004
|
var _dec$j, _dec2$j, _dec3$g, _dec4$g, _dec5$g, _dec6$g, _class$j, _class2$g, _descriptor$3, _descriptor2$3;
|
|
998
1005
|
let DtoProfile = (_dec$j = Dto(), _dec2$j = BeanInfo({
|
|
@@ -1091,15 +1098,14 @@ let DtoUser = (_dec$g = Dto({
|
|
|
1091
1098
|
}), _class2$d)) || _class$g) || _class$g);
|
|
1092
1099
|
|
|
1093
1100
|
var _dec$f, _dec2$f, _class$f;
|
|
1094
|
-
let DtoUserCreate = (_dec$f = Dto(
|
|
1101
|
+
let DtoUserCreate = (_dec$f = Dto({
|
|
1102
|
+
independent: true
|
|
1103
|
+
}), _dec2$f = BeanInfo({
|
|
1095
1104
|
module: "test-vona"
|
|
1096
1105
|
}), _dec$f(_class$f = _dec2$f(_class$f = class DtoUserCreate extends $Dto.create('test-vona:user', {
|
|
1097
1106
|
include: {
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
user: false
|
|
1101
|
-
}
|
|
1102
|
-
}
|
|
1107
|
+
roles: true,
|
|
1108
|
+
posts: true
|
|
1103
1109
|
}
|
|
1104
1110
|
}) {}) || _class$f) || _class$f);
|
|
1105
1111
|
|
|
@@ -1108,11 +1114,7 @@ let DtoUserUpdate = (_dec$e = Dto(), _dec2$e = BeanInfo({
|
|
|
1108
1114
|
module: "test-vona"
|
|
1109
1115
|
}), _dec$e(_class$e = _dec2$e(_class$e = class DtoUserUpdate extends $Dto.update('test-vona:user', {
|
|
1110
1116
|
include: {
|
|
1111
|
-
posts:
|
|
1112
|
-
include: {
|
|
1113
|
-
user: false
|
|
1114
|
-
}
|
|
1115
|
-
}
|
|
1117
|
+
posts: true
|
|
1116
1118
|
}
|
|
1117
1119
|
}) {}) || _class$e) || _class$e);
|
|
1118
1120
|
|
|
@@ -1885,4 +1887,4 @@ function $locale(key) {
|
|
|
1885
1887
|
}
|
|
1886
1888
|
/** scope: end */
|
|
1887
1889
|
|
|
1888
|
-
export { $locale, AopMethodTest, AopRegExp, AopSimple, BeanTestCtx, BroadcastTest, CacheMemTest, CacheRedisTest, ControllerBean, ControllerCacheMem, ControllerCacheRedis, ControllerDtoTest, ControllerGuardPassport, ControllerOnion, ControllerPassport, ControllerPerformAction, ControllerQueue, ControllerSummer, ControllerTail, ControllerTransaction, ControllerUpload, DtoCategoryTree, DtoProfile, DtoRoleLazy, DtoUser, DtoUserCreate, DtoUserLazy, DtoUserUpdate, EntityCategory, EntityPost, EntityPostContent, EntityRole, EntityRoleUser, EntityTest, EntityUser, EventHelloEcho, EventListenerHelloEcho, MetaVersion, ModelCategory, ModelPost, ModelPostContent, ModelRole, ModelRoleUser, ModelTest, ModelTestDynamicTable, ModelUser, ModelUserStats, ModelUserStatsGroup, QueueTest, ScheduleTest, ScheduleTest3, ScopeModuleTestVona, ServiceAopMethod, ServiceCaching, ServiceTest, ServiceTestApp, ServiceTestClass, ServiceTestData, ServiceTransaction, SummerCacheTest, config, locales };
|
|
1890
|
+
export { $locale, AopMethodTest, AopRegExp, AopSimple, BeanTestCtx, BroadcastTest, CacheMemTest, CacheRedisTest, ControllerBean, ControllerCacheMem, ControllerCacheRedis, ControllerDtoTest, ControllerGuardPassport, ControllerOnion, ControllerPassport, ControllerPerformAction, ControllerQueue, ControllerSummer, ControllerTail, ControllerTransaction, ControllerUpload, DtoCategoryTree, DtoPostCreate, DtoProfile, DtoRoleLazy, DtoUser, DtoUserCreate, DtoUserLazy, DtoUserUpdate, EntityCategory, EntityPost, EntityPostContent, EntityRole, EntityRoleUser, EntityTest, EntityUser, EventHelloEcho, EventListenerHelloEcho, MetaVersion, ModelCategory, ModelPost, ModelPostContent, ModelRole, ModelRoleUser, ModelTest, ModelTestDynamicTable, ModelUser, ModelUserStats, ModelUserStatsGroup, QueueTest, ScheduleTest, ScheduleTest3, ScopeModuleTestVona, ServiceAopMethod, ServiceCaching, ServiceTest, ServiceTestApp, ServiceTestClass, ServiceTestData, ServiceTransaction, SummerCacheTest, config, locales };
|