vona-module-test-vona 5.0.81 → 5.0.83
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/controller/order.d.ts +5 -5
- package/dist/controller/post.d.ts +6 -7
- package/dist/dto/orderCreate.d.ts +1 -1
- package/dist/dto/orderQueryPage.d.ts +1 -1
- package/dist/dto/orderUpdate.d.ts +1 -1
- package/dist/dto/postCreate.d.ts +1 -1
- package/dist/dto/postQuery.d.ts +2 -0
- package/dist/dto/userCreate.d.ts +1 -1
- package/dist/dto/userUpdate.d.ts +1 -1
- package/dist/index.js +112 -123
- package/dist/service/caching.d.ts +3 -4
- package/dist/service/post.d.ts +5 -5
- package/package.json +1 -1
- package/src/controller/bean.ts +1 -1
- package/src/controller/cacheMem.ts +1 -1
- package/src/controller/cacheRedis.ts +1 -1
- package/src/controller/dtoTest.ts +1 -1
- package/src/controller/onion.ts +1 -1
- package/src/controller/order.ts +4 -13
- package/src/controller/passport.ts +1 -1
- package/src/controller/performAction.ts +1 -1
- package/src/controller/post.ts +4 -8
- package/src/controller/queue.ts +1 -1
- package/src/controller/serializer.ts +1 -1
- package/src/controller/summer.ts +1 -1
- package/src/controller/tail.ts +1 -1
- package/src/controller/transaction.ts +1 -1
- package/src/controller/upload.ts +1 -1
- package/src/dto/orderQuery.ts +7 -10
- package/src/dto/orderQueryPage.ts +1 -1
- package/src/dto/postQuery.ts +13 -6
- package/src/dto/profile.ts +1 -1
- package/src/dto/roleLazy.ts +1 -1
- package/src/dto/serializerArray.ts +1 -1
- package/src/dto/serializerLazy.ts +1 -1
- package/src/dto/serializerSimple.ts +1 -1
- package/src/dto/signin.ts +1 -1
- package/src/dto/user.ts +1 -1
- package/src/dto/userLazy.ts +1 -1
- package/src/entity/category.ts +1 -1
- package/src/entity/order.ts +1 -1
- package/src/entity/post.ts +1 -1
- package/src/entity/postContent.ts +1 -1
- package/src/entity/product.ts +1 -1
- package/src/entity/role.ts +1 -1
- package/src/entity/roleUser.ts +1 -1
- package/src/entity/test.ts +1 -1
- package/src/entity/user.ts +1 -1
- package/src/model/testDynamicTable.ts +2 -2
- package/src/service/caching.ts +15 -20
- package/test/database/database.test.ts +2 -2
- package/test/database/dtoAggregate.test.ts +1 -1
- package/test/database/dtoGet.test.ts +3 -3
- package/test/database/dtoGroup.test.ts +1 -1
- package/test/database/dtoLazy.test.ts +1 -1
- package/test/database/dtoMutate.test.ts +2 -2
- package/test/database/dtoQuery.test.ts +9 -0
- package/test/runtime.test.ts +22 -0
- package/test/upload.test.ts +1 -1
- package/test/utils/mappedTypes.test.ts +1 -1
package/dist/index.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { BeanInfo, BeanAopBase, BeanAopMethodBase, BeanBase, $Class, cast, retry, BeanScopeBase } from 'vona';
|
|
2
2
|
import { Aop, AopMethod, Aspect } from 'vona-module-a-aspect';
|
|
3
|
-
import { Api, v } from 'vona-module-a-
|
|
3
|
+
import { Api, v } from 'vona-module-a-openapiutils';
|
|
4
4
|
import { Entity, EntityBase, Model, $relation, BeanModelBase, $relationDynamic, $Dto, $tableName } from 'vona-module-a-orm';
|
|
5
5
|
import { ModelCategoryChain as ModelCategoryChain$1, ModelOrder as ModelOrder$1 } from 'vona-module-test-vona';
|
|
6
|
-
import
|
|
6
|
+
import { DateTime } from 'luxon';
|
|
7
7
|
import { Bean, Service, Scope } from 'vona-module-a-bean';
|
|
8
|
-
import { getKeyHash, CacheMem, BeanCacheMemBase, CacheRedis, BeanCacheRedisBase } from 'vona-module-a-cache';
|
|
9
8
|
import { Caching } from 'vona-module-a-caching';
|
|
10
9
|
import assert from 'node:assert';
|
|
11
10
|
import { Core } from 'vona-module-a-core';
|
|
12
11
|
import { Broadcast, BeanBroadcastBase } from 'vona-module-a-broadcast';
|
|
12
|
+
import { CacheMem, BeanCacheMemBase, CacheRedis, BeanCacheRedisBase } from 'vona-module-a-cache';
|
|
13
13
|
import { Event, BeanEventBase, EventListener } from 'vona-module-a-event';
|
|
14
14
|
import { Meta } from 'vona-module-a-meta';
|
|
15
15
|
import { BeanAssetBase, BeanStaticBase } from 'vona-module-a-static';
|
|
@@ -178,28 +178,28 @@ function _initializerDefineProperty(e, i, r, l) {
|
|
|
178
178
|
});
|
|
179
179
|
}
|
|
180
180
|
|
|
181
|
-
var _dec$1p, _dec2$1p, _dec3$E, _dec4$E, _dec5$
|
|
181
|
+
var _dec$1p, _dec2$1p, _dec3$E, _dec4$E, _dec5$B, _dec6$A, _class$1p, _class2$E, _descriptor$j, _descriptor2$g;
|
|
182
182
|
let EntityCategory = (_dec$1p = Entity('testVonaCategory'), _dec2$1p = BeanInfo({
|
|
183
183
|
module: "test-vona"
|
|
184
|
-
}), _dec3$E = Api.field(), _dec4$E = Reflect.metadata("design:type", String), _dec5$
|
|
184
|
+
}), _dec3$E = Api.field(), _dec4$E = Reflect.metadata("design:type", String), _dec5$B = Api.field(v.optional(), v.tableIdentity()), _dec6$A = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec$1p(_class$1p = _dec2$1p(_class$1p = (_class2$E = class EntityCategory extends EntityBase {
|
|
185
185
|
constructor(...args) {
|
|
186
186
|
super(...args);
|
|
187
187
|
_initializerDefineProperty(this, "name", _descriptor$j, this);
|
|
188
|
-
_initializerDefineProperty(this, "categoryIdParent", _descriptor2$
|
|
188
|
+
_initializerDefineProperty(this, "categoryIdParent", _descriptor2$g, this);
|
|
189
189
|
}
|
|
190
190
|
}, _descriptor$j = _applyDecoratedDescriptor(_class2$E.prototype, "name", [_dec3$E, _dec4$E], {
|
|
191
191
|
configurable: true,
|
|
192
192
|
enumerable: true,
|
|
193
193
|
writable: true,
|
|
194
194
|
initializer: null
|
|
195
|
-
}), _descriptor2$
|
|
195
|
+
}), _descriptor2$g = _applyDecoratedDescriptor(_class2$E.prototype, "categoryIdParent", [_dec5$B, _dec6$A], {
|
|
196
196
|
configurable: true,
|
|
197
197
|
enumerable: true,
|
|
198
198
|
writable: true,
|
|
199
199
|
initializer: null
|
|
200
200
|
}), _class2$E)) || _class$1p) || _class$1p);
|
|
201
201
|
|
|
202
|
-
var _dec$1o, _dec2$1o, _dec3$D, _dec4$D, _dec5$
|
|
202
|
+
var _dec$1o, _dec2$1o, _dec3$D, _dec4$D, _dec5$A, _dec6$z, _dec7$t, _dec8$p, _class$1o, _class2$D, _descriptor$i, _descriptor2$f, _descriptor3$9;
|
|
203
203
|
let EntityOrder = (_dec$1o = Entity('testVonaOrder', {
|
|
204
204
|
openapi: {
|
|
205
205
|
title: $locale('Order')
|
|
@@ -208,91 +208,91 @@ let EntityOrder = (_dec$1o = Entity('testVonaOrder', {
|
|
|
208
208
|
module: "test-vona"
|
|
209
209
|
}), _dec3$D = Api.field(v.openapi({
|
|
210
210
|
title: $locale('OrderNo')
|
|
211
|
-
}), v.default(''), v.min(3)), _dec4$D = Reflect.metadata("design:type", String), _dec5$
|
|
211
|
+
}), v.default(''), v.min(3)), _dec4$D = Reflect.metadata("design:type", String), _dec5$A = Api.field(v.openapi({
|
|
212
212
|
title: $locale('Remark')
|
|
213
|
-
}), v.optional()), _dec6$
|
|
213
|
+
}), v.optional()), _dec6$z = Reflect.metadata("design:type", String), _dec7$t = Api.field(v.tableIdentity()), _dec8$p = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec$1o(_class$1o = _dec2$1o(_class$1o = (_class2$D = class EntityOrder extends EntityBase {
|
|
214
214
|
constructor(...args) {
|
|
215
215
|
super(...args);
|
|
216
216
|
_initializerDefineProperty(this, "orderNo", _descriptor$i, this);
|
|
217
|
-
_initializerDefineProperty(this, "remark", _descriptor2$
|
|
218
|
-
_initializerDefineProperty(this, "userId", _descriptor3$
|
|
217
|
+
_initializerDefineProperty(this, "remark", _descriptor2$f, this);
|
|
218
|
+
_initializerDefineProperty(this, "userId", _descriptor3$9, this);
|
|
219
219
|
}
|
|
220
220
|
}, _descriptor$i = _applyDecoratedDescriptor(_class2$D.prototype, "orderNo", [_dec3$D, _dec4$D], {
|
|
221
221
|
configurable: true,
|
|
222
222
|
enumerable: true,
|
|
223
223
|
writable: true,
|
|
224
224
|
initializer: null
|
|
225
|
-
}), _descriptor2$
|
|
225
|
+
}), _descriptor2$f = _applyDecoratedDescriptor(_class2$D.prototype, "remark", [_dec5$A, _dec6$z], {
|
|
226
226
|
configurable: true,
|
|
227
227
|
enumerable: true,
|
|
228
228
|
writable: true,
|
|
229
229
|
initializer: null
|
|
230
|
-
}), _descriptor3$
|
|
230
|
+
}), _descriptor3$9 = _applyDecoratedDescriptor(_class2$D.prototype, "userId", [_dec7$t, _dec8$p], {
|
|
231
231
|
configurable: true,
|
|
232
232
|
enumerable: true,
|
|
233
233
|
writable: true,
|
|
234
234
|
initializer: null
|
|
235
235
|
}), _class2$D)) || _class$1o) || _class$1o);
|
|
236
236
|
|
|
237
|
-
var _dec$1n, _dec2$1n, _dec3$C, _dec4$C, _dec5$
|
|
237
|
+
var _dec$1n, _dec2$1n, _dec3$C, _dec4$C, _dec5$z, _dec6$y, _dec7$s, _dec8$o, _class$1n, _class2$C, _descriptor$h, _descriptor2$e, _descriptor3$8;
|
|
238
238
|
let EntityPost = (_dec$1n = Entity('testVonaPost'), _dec2$1n = BeanInfo({
|
|
239
239
|
module: "test-vona"
|
|
240
|
-
}), _dec3$C = Api.field(), _dec4$C = Reflect.metadata("design:type", String), _dec5$
|
|
240
|
+
}), _dec3$C = Api.field(), _dec4$C = Reflect.metadata("design:type", String), _dec5$z = Api.field(v.tableIdentity()), _dec6$y = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec7$s = Api.field(v.optional()), _dec8$o = Reflect.metadata("design:type", Number), _dec$1n(_class$1n = _dec2$1n(_class$1n = (_class2$C = class EntityPost extends EntityBase {
|
|
241
241
|
constructor(...args) {
|
|
242
242
|
super(...args);
|
|
243
243
|
_initializerDefineProperty(this, "title", _descriptor$h, this);
|
|
244
|
-
_initializerDefineProperty(this, "userId", _descriptor2$
|
|
245
|
-
_initializerDefineProperty(this, "stars", _descriptor3$
|
|
244
|
+
_initializerDefineProperty(this, "userId", _descriptor2$e, this);
|
|
245
|
+
_initializerDefineProperty(this, "stars", _descriptor3$8, this);
|
|
246
246
|
}
|
|
247
247
|
}, _descriptor$h = _applyDecoratedDescriptor(_class2$C.prototype, "title", [_dec3$C, _dec4$C], {
|
|
248
248
|
configurable: true,
|
|
249
249
|
enumerable: true,
|
|
250
250
|
writable: true,
|
|
251
251
|
initializer: null
|
|
252
|
-
}), _descriptor2$
|
|
252
|
+
}), _descriptor2$e = _applyDecoratedDescriptor(_class2$C.prototype, "userId", [_dec5$z, _dec6$y], {
|
|
253
253
|
configurable: true,
|
|
254
254
|
enumerable: true,
|
|
255
255
|
writable: true,
|
|
256
256
|
initializer: null
|
|
257
|
-
}), _descriptor3$
|
|
257
|
+
}), _descriptor3$8 = _applyDecoratedDescriptor(_class2$C.prototype, "stars", [_dec7$s, _dec8$o], {
|
|
258
258
|
configurable: true,
|
|
259
259
|
enumerable: true,
|
|
260
260
|
writable: true,
|
|
261
261
|
initializer: null
|
|
262
262
|
}), _class2$C)) || _class$1n) || _class$1n);
|
|
263
263
|
|
|
264
|
-
var _dec$1m, _dec2$1m, _dec3$B, _dec4$B, _dec5$
|
|
264
|
+
var _dec$1m, _dec2$1m, _dec3$B, _dec4$B, _dec5$y, _dec6$x, _class$1m, _class2$B, _descriptor$g, _descriptor2$d;
|
|
265
265
|
let EntityPostContent = (_dec$1m = Entity('testVonaPostContent'), _dec2$1m = BeanInfo({
|
|
266
266
|
module: "test-vona"
|
|
267
|
-
}), _dec3$B = Api.field(), _dec4$B = Reflect.metadata("design:type", String), _dec5$
|
|
267
|
+
}), _dec3$B = Api.field(), _dec4$B = Reflect.metadata("design:type", String), _dec5$y = Api.field(v.tableIdentity()), _dec6$x = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec$1m(_class$1m = _dec2$1m(_class$1m = (_class2$B = class EntityPostContent extends EntityBase {
|
|
268
268
|
constructor(...args) {
|
|
269
269
|
super(...args);
|
|
270
270
|
_initializerDefineProperty(this, "content", _descriptor$g, this);
|
|
271
|
-
_initializerDefineProperty(this, "postId", _descriptor2$
|
|
271
|
+
_initializerDefineProperty(this, "postId", _descriptor2$d, this);
|
|
272
272
|
}
|
|
273
273
|
}, _descriptor$g = _applyDecoratedDescriptor(_class2$B.prototype, "content", [_dec3$B, _dec4$B], {
|
|
274
274
|
configurable: true,
|
|
275
275
|
enumerable: true,
|
|
276
276
|
writable: true,
|
|
277
277
|
initializer: null
|
|
278
|
-
}), _descriptor2$
|
|
278
|
+
}), _descriptor2$d = _applyDecoratedDescriptor(_class2$B.prototype, "postId", [_dec5$y, _dec6$x], {
|
|
279
279
|
configurable: true,
|
|
280
280
|
enumerable: true,
|
|
281
281
|
writable: true,
|
|
282
282
|
initializer: null
|
|
283
283
|
}), _class2$B)) || _class$1m) || _class$1m);
|
|
284
284
|
|
|
285
|
-
var _dec$1l, _dec2$1l, _dec3$A, _dec4$A, _dec5$
|
|
285
|
+
var _dec$1l, _dec2$1l, _dec3$A, _dec4$A, _dec5$x, _dec6$w, _dec7$r, _dec8$n, _dec9$e, _dec0$e, _dec1$e, _dec10$c, _class$1l, _class2$A, _descriptor$f, _descriptor2$c, _descriptor3$7, _descriptor4$1, _descriptor5$1;
|
|
286
286
|
let EntityProduct = (_dec$1l = Entity('testVonaProduct', {
|
|
287
287
|
independent: true
|
|
288
288
|
}), _dec2$1l = BeanInfo({
|
|
289
289
|
module: "test-vona"
|
|
290
|
-
}), _dec3$A = Api.field(v.title($locale('Name'))), _dec4$A = Reflect.metadata("design:type", String), _dec5$
|
|
290
|
+
}), _dec3$A = Api.field(v.title($locale('Name'))), _dec4$A = Reflect.metadata("design:type", String), _dec5$x = Api.field(v.title($locale('Price'))), _dec6$w = Reflect.metadata("design:type", Number), _dec7$r = Api.field(v.title($locale('Quantity'))), _dec8$n = Reflect.metadata("design:type", Number), _dec9$e = Api.field(v.title($locale('Amount'))), _dec0$e = Reflect.metadata("design:type", Number), _dec1$e = Api.field(v.tableIdentity()), _dec10$c = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec$1l(_class$1l = _dec2$1l(_class$1l = (_class2$A = class EntityProduct extends EntityBase {
|
|
291
291
|
constructor(...args) {
|
|
292
292
|
super(...args);
|
|
293
293
|
_initializerDefineProperty(this, "name", _descriptor$f, this);
|
|
294
|
-
_initializerDefineProperty(this, "price", _descriptor2$
|
|
295
|
-
_initializerDefineProperty(this, "quantity", _descriptor3$
|
|
294
|
+
_initializerDefineProperty(this, "price", _descriptor2$c, this);
|
|
295
|
+
_initializerDefineProperty(this, "quantity", _descriptor3$7, this);
|
|
296
296
|
_initializerDefineProperty(this, "amount", _descriptor4$1, this);
|
|
297
297
|
_initializerDefineProperty(this, "orderId", _descriptor5$1, this);
|
|
298
298
|
}
|
|
@@ -301,12 +301,12 @@ let EntityProduct = (_dec$1l = Entity('testVonaProduct', {
|
|
|
301
301
|
enumerable: true,
|
|
302
302
|
writable: true,
|
|
303
303
|
initializer: null
|
|
304
|
-
}), _descriptor2$
|
|
304
|
+
}), _descriptor2$c = _applyDecoratedDescriptor(_class2$A.prototype, "price", [_dec5$x, _dec6$w], {
|
|
305
305
|
configurable: true,
|
|
306
306
|
enumerable: true,
|
|
307
307
|
writable: true,
|
|
308
308
|
initializer: null
|
|
309
|
-
}), _descriptor3$
|
|
309
|
+
}), _descriptor3$7 = _applyDecoratedDescriptor(_class2$A.prototype, "quantity", [_dec7$r, _dec8$n], {
|
|
310
310
|
configurable: true,
|
|
311
311
|
enumerable: true,
|
|
312
312
|
writable: true,
|
|
@@ -338,81 +338,81 @@ let EntityRole = (_dec$1k = Entity('testVonaRole'), _dec2$1k = BeanInfo({
|
|
|
338
338
|
initializer: null
|
|
339
339
|
}), _class2$z)) || _class$1k) || _class$1k);
|
|
340
340
|
|
|
341
|
-
var _dec$1j, _dec2$1j, _dec3$y, _dec4$y, _dec5$
|
|
341
|
+
var _dec$1j, _dec2$1j, _dec3$y, _dec4$y, _dec5$w, _dec6$v, _class$1j, _class2$y, _descriptor$d, _descriptor2$b;
|
|
342
342
|
let EntityRoleUser = (_dec$1j = Entity('testVonaRoleUser'), _dec2$1j = BeanInfo({
|
|
343
343
|
module: "test-vona"
|
|
344
|
-
}), _dec3$y = Api.field(v.tableIdentity()), _dec4$y = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec5$
|
|
344
|
+
}), _dec3$y = Api.field(v.tableIdentity()), _dec4$y = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec5$w = Api.field(v.tableIdentity()), _dec6$v = Reflect.metadata("design:type", typeof TableIdentity === "undefined" ? Object : TableIdentity), _dec$1j(_class$1j = _dec2$1j(_class$1j = (_class2$y = class EntityRoleUser extends EntityBase {
|
|
345
345
|
constructor(...args) {
|
|
346
346
|
super(...args);
|
|
347
347
|
_initializerDefineProperty(this, "userId", _descriptor$d, this);
|
|
348
|
-
_initializerDefineProperty(this, "roleId", _descriptor2$
|
|
348
|
+
_initializerDefineProperty(this, "roleId", _descriptor2$b, this);
|
|
349
349
|
}
|
|
350
350
|
}, _descriptor$d = _applyDecoratedDescriptor(_class2$y.prototype, "userId", [_dec3$y, _dec4$y], {
|
|
351
351
|
configurable: true,
|
|
352
352
|
enumerable: true,
|
|
353
353
|
writable: true,
|
|
354
354
|
initializer: null
|
|
355
|
-
}), _descriptor2$
|
|
355
|
+
}), _descriptor2$b = _applyDecoratedDescriptor(_class2$y.prototype, "roleId", [_dec5$w, _dec6$v], {
|
|
356
356
|
configurable: true,
|
|
357
357
|
enumerable: true,
|
|
358
358
|
writable: true,
|
|
359
359
|
initializer: null
|
|
360
360
|
}), _class2$y)) || _class$1j) || _class$1j);
|
|
361
361
|
|
|
362
|
-
var _dec$1i, _dec2$1i, _dec3$x, _dec4$x, _dec5$
|
|
362
|
+
var _dec$1i, _dec2$1i, _dec3$x, _dec4$x, _dec5$v, _dec6$u, _dec7$q, _dec8$m, _class$1i, _class2$x, _descriptor$c, _descriptor2$a, _descriptor3$6;
|
|
363
363
|
let EntityTest = (_dec$1i = Entity('testVonaTest', {
|
|
364
364
|
openapi: {
|
|
365
365
|
title: $locale('Test')
|
|
366
366
|
}
|
|
367
367
|
}), _dec2$1i = BeanInfo({
|
|
368
368
|
module: "test-vona"
|
|
369
|
-
}), _dec3$x = Api.field(v.title($locale('Test'))), _dec4$x = Reflect.metadata("design:type", String), _dec5$
|
|
369
|
+
}), _dec3$x = Api.field(v.title($locale('Test'))), _dec4$x = Reflect.metadata("design:type", String), _dec5$v = Api.field(), _dec6$u = Reflect.metadata("design:type", String), _dec7$q = Api.field(v.default(() => {
|
|
370
370
|
return new Date();
|
|
371
|
-
})), _dec8$
|
|
371
|
+
})), _dec8$m = Reflect.metadata("design:type", typeof Date === "undefined" ? Object : Date), _dec$1i(_class$1i = _dec2$1i(_class$1i = (_class2$x = class EntityTest extends EntityBase {
|
|
372
372
|
constructor(...args) {
|
|
373
373
|
super(...args);
|
|
374
374
|
_initializerDefineProperty(this, "title", _descriptor$c, this);
|
|
375
|
-
_initializerDefineProperty(this, "description", _descriptor2$
|
|
376
|
-
_initializerDefineProperty(this, "testDate", _descriptor3$
|
|
375
|
+
_initializerDefineProperty(this, "description", _descriptor2$a, this);
|
|
376
|
+
_initializerDefineProperty(this, "testDate", _descriptor3$6, this);
|
|
377
377
|
}
|
|
378
378
|
}, _descriptor$c = _applyDecoratedDescriptor(_class2$x.prototype, "title", [_dec3$x, _dec4$x], {
|
|
379
379
|
configurable: true,
|
|
380
380
|
enumerable: true,
|
|
381
381
|
writable: true,
|
|
382
382
|
initializer: null
|
|
383
|
-
}), _descriptor2$
|
|
383
|
+
}), _descriptor2$a = _applyDecoratedDescriptor(_class2$x.prototype, "description", [_dec5$v, _dec6$u], {
|
|
384
384
|
configurable: true,
|
|
385
385
|
enumerable: true,
|
|
386
386
|
writable: true,
|
|
387
387
|
initializer: null
|
|
388
|
-
}), _descriptor3$
|
|
388
|
+
}), _descriptor3$6 = _applyDecoratedDescriptor(_class2$x.prototype, "testDate", [_dec7$q, _dec8$m], {
|
|
389
389
|
configurable: true,
|
|
390
390
|
enumerable: true,
|
|
391
391
|
writable: true,
|
|
392
392
|
initializer: null
|
|
393
393
|
}), _class2$x)) || _class$1i) || _class$1i);
|
|
394
394
|
|
|
395
|
-
var _dec$1h, _dec2$1h, _dec3$w, _dec4$w, _dec5$
|
|
395
|
+
var _dec$1h, _dec2$1h, _dec3$w, _dec4$w, _dec5$u, _dec6$t, _dec7$p, _dec8$l, _class$1h, _class2$w, _descriptor$b, _descriptor2$9, _descriptor3$5;
|
|
396
396
|
let EntityUser = (_dec$1h = Entity('testVonaUser'), _dec2$1h = BeanInfo({
|
|
397
397
|
module: "test-vona"
|
|
398
|
-
}), _dec3$w = Api.field(), _dec4$w = Reflect.metadata("design:type", String), _dec5$
|
|
398
|
+
}), _dec3$w = Api.field(), _dec4$w = Reflect.metadata("design:type", String), _dec5$u = Api.field(v.optional()), _dec6$t = Reflect.metadata("design:type", Number), _dec7$p = Api.field(v.optional()), _dec8$l = Reflect.metadata("design:type", Number), _dec$1h(_class$1h = _dec2$1h(_class$1h = (_class2$w = class EntityUser extends EntityBase {
|
|
399
399
|
constructor(...args) {
|
|
400
400
|
super(...args);
|
|
401
401
|
_initializerDefineProperty(this, "name", _descriptor$b, this);
|
|
402
|
-
_initializerDefineProperty(this, "age", _descriptor2$
|
|
403
|
-
_initializerDefineProperty(this, "scores", _descriptor3$
|
|
402
|
+
_initializerDefineProperty(this, "age", _descriptor2$9, this);
|
|
403
|
+
_initializerDefineProperty(this, "scores", _descriptor3$5, this);
|
|
404
404
|
}
|
|
405
405
|
}, _descriptor$b = _applyDecoratedDescriptor(_class2$w.prototype, "name", [_dec3$w, _dec4$w], {
|
|
406
406
|
configurable: true,
|
|
407
407
|
enumerable: true,
|
|
408
408
|
writable: true,
|
|
409
409
|
initializer: null
|
|
410
|
-
}), _descriptor2$
|
|
410
|
+
}), _descriptor2$9 = _applyDecoratedDescriptor(_class2$w.prototype, "age", [_dec5$u, _dec6$t], {
|
|
411
411
|
configurable: true,
|
|
412
412
|
enumerable: true,
|
|
413
413
|
writable: true,
|
|
414
414
|
initializer: null
|
|
415
|
-
}), _descriptor3$
|
|
415
|
+
}), _descriptor3$5 = _applyDecoratedDescriptor(_class2$w.prototype, "scores", [_dec7$p, _dec8$l], {
|
|
416
416
|
configurable: true,
|
|
417
417
|
enumerable: true,
|
|
418
418
|
writable: true,
|
|
@@ -624,7 +624,7 @@ let ModelTestDynamicTable = (_dec$13 = Model({
|
|
|
624
624
|
entity: EntityTest,
|
|
625
625
|
table(ctx, _where, defaultTable) {
|
|
626
626
|
if (ctx.instanceName !== '') return defaultTable;
|
|
627
|
-
return `${defaultTable}_${
|
|
627
|
+
return `${defaultTable}_${DateTime.now().toFormat('yyyyMMdd')}`;
|
|
628
628
|
},
|
|
629
629
|
softDeletionPrune: {
|
|
630
630
|
handler: async (_ctx, _modelInstance) => {
|
|
@@ -704,7 +704,7 @@ let BeanTestCtx = (_dec$12 = Bean(), _dec2$12 = BeanInfo({
|
|
|
704
704
|
module: "test-vona"
|
|
705
705
|
}), _dec$12(_class$12 = _dec2$12(_class$12 = class BeanTestCtx extends TestCtx1 {}) || _class$12) || _class$12);
|
|
706
706
|
|
|
707
|
-
var _dec$11, _dec2$11, _dec3$v, _dec4$v, _class$11, _dec5$
|
|
707
|
+
var _dec$11, _dec2$11, _dec3$v, _dec4$v, _class$11, _dec5$t, _dec6$s, _dec7$o, _dec8$k, _dec9$d, _dec0$d, _dec1$d, _dec10$b, _dec11$b, _dec12$b, _dec13$b, _dec14$a, _dec15$a, _dec16$a, _class2$v, _class3;
|
|
708
708
|
let ServiceAopMethodBase = (_dec$11 = Aspect.aopMethod('test-vona:test', {
|
|
709
709
|
wrapper: '+'
|
|
710
710
|
}), _dec2$11 = Aspect.aopMethod('test-vona:test', {
|
|
@@ -714,11 +714,11 @@ let ServiceAopMethodBase = (_dec$11 = Aspect.aopMethod('test-vona:test', {
|
|
|
714
714
|
return 'hello';
|
|
715
715
|
}
|
|
716
716
|
}, _applyDecoratedDescriptor(_class$11.prototype, "testSyncBase", [_dec$11, _dec2$11, _dec3$v, _dec4$v], Object.getOwnPropertyDescriptor(_class$11.prototype, "testSyncBase"), _class$11.prototype), _class$11);
|
|
717
|
-
let ServiceAopMethod = (_dec5$
|
|
717
|
+
let ServiceAopMethod = (_dec5$t = Service(), _dec6$s = BeanInfo({
|
|
718
718
|
module: "test-vona"
|
|
719
|
-
}), _dec7$
|
|
719
|
+
}), _dec7$o = Aspect.aopMethod('test-vona:test', {
|
|
720
720
|
wrapper: '+'
|
|
721
|
-
}), _dec8$
|
|
721
|
+
}), _dec8$k = Aspect.aopMethod('test-vona:test', {
|
|
722
722
|
wrapper: '-'
|
|
723
723
|
}), _dec9$d = Reflect.metadata("design:type", Function), _dec0$d = Reflect.metadata("design:paramtypes", []), _dec1$d = Aspect.aopMethod('test-vona:test', {
|
|
724
724
|
wrapper: '+'
|
|
@@ -728,7 +728,7 @@ let ServiceAopMethod = (_dec5$s = Service(), _dec6$r = BeanInfo({
|
|
|
728
728
|
wrapper: '+'
|
|
729
729
|
}), _dec14$a = Aspect.aopMethod('test-vona:test', {
|
|
730
730
|
wrapper: '-'
|
|
731
|
-
}), _dec15$a = Reflect.metadata("design:type", Function), _dec16$a = Reflect.metadata("design:paramtypes", []), _dec5$
|
|
731
|
+
}), _dec15$a = Reflect.metadata("design:type", Function), _dec16$a = Reflect.metadata("design:paramtypes", []), _dec5$t(_class2$v = _dec6$s(_class2$v = (_class3 = class ServiceAopMethod extends ServiceAopMethodBase {
|
|
732
732
|
constructor(...args) {
|
|
733
733
|
super(...args);
|
|
734
734
|
this._name = '';
|
|
@@ -745,57 +745,46 @@ let ServiceAopMethod = (_dec5$s = Service(), _dec6$r = BeanInfo({
|
|
|
745
745
|
set name(value) {
|
|
746
746
|
this._name = value;
|
|
747
747
|
}
|
|
748
|
-
}, _applyDecoratedDescriptor(_class3.prototype, "testSync", [_dec7$
|
|
748
|
+
}, _applyDecoratedDescriptor(_class3.prototype, "testSync", [_dec7$o, _dec8$k, _dec9$d, _dec0$d], Object.getOwnPropertyDescriptor(_class3.prototype, "testSync"), _class3.prototype), _applyDecoratedDescriptor(_class3.prototype, "testAsync", [_dec1$d, _dec10$b, _dec11$b, _dec12$b], Object.getOwnPropertyDescriptor(_class3.prototype, "testAsync"), _class3.prototype), _applyDecoratedDescriptor(_class3.prototype, "name", [_dec13$b, _dec14$a, _dec15$a, _dec16$a], Object.getOwnPropertyDescriptor(_class3.prototype, "name"), _class3.prototype), _class3)) || _class2$v) || _class2$v);
|
|
749
749
|
|
|
750
|
-
var _dec$10, _dec2$10, _dec3$u, _dec4$u, _dec5$
|
|
751
|
-
function cacheKeyFn(
|
|
752
|
-
return
|
|
750
|
+
var _dec$10, _dec2$10, _dec3$u, _dec4$u, _dec5$s, _dec6$r, _dec7$n, _dec8$j, _dec9$c, _dec0$c, _dec1$c, _dec10$a, _dec11$a, _dec12$a, _dec13$a, _dec14$9, _dec15$9, _dec16$9, _dec17$8, _dec18$8, _dec19$8, _dec20$8, _dec21$6, _dec22$5, _dec23$5, _dec24$5, _dec25$5, _dec26$4, _dec27$4, _class$10, _class2$u;
|
|
751
|
+
function cacheKeyFn(info, _options) {
|
|
752
|
+
return info.args[0];
|
|
753
753
|
}
|
|
754
754
|
let ServiceCaching = (_dec$10 = Service(), _dec2$10 = BeanInfo({
|
|
755
755
|
module: "test-vona"
|
|
756
756
|
}), _dec3$u = Caching.get({
|
|
757
757
|
cacheName: 'test-vona:test',
|
|
758
|
-
cacheProp: 'test',
|
|
759
758
|
cacheKeyFn: 'cacheKey'
|
|
760
|
-
}), _dec4$u = Reflect.metadata("design:type", Function), _dec5$
|
|
759
|
+
}), _dec4$u = Reflect.metadata("design:type", Function), _dec5$s = Reflect.metadata("design:paramtypes", [Number]), _dec6$r = Caching.get({
|
|
761
760
|
cacheName: 'test-vona:test',
|
|
762
|
-
cacheProp: 'test',
|
|
763
761
|
cacheKeyFn
|
|
764
|
-
}), _dec7$
|
|
762
|
+
}), _dec7$n = Reflect.metadata("design:type", Function), _dec8$j = Reflect.metadata("design:paramtypes", [Number]), _dec9$c = Caching.get({
|
|
765
763
|
cacheName: 'test-vona:test',
|
|
766
|
-
|
|
767
|
-
cacheKey: 'cel://join([get(self,"$beanFullName"),options.cacheProp,hashkey(args)],"_")'
|
|
764
|
+
cacheKey: 'cel://args[0]'
|
|
768
765
|
}), _dec0$c = Reflect.metadata("design:type", Function), _dec1$c = Reflect.metadata("design:paramtypes", [Number]), _dec10$a = Caching.get({
|
|
769
|
-
cacheName: 'test-vona:test'
|
|
770
|
-
cacheProp: 'test'
|
|
766
|
+
cacheName: 'test-vona:test'
|
|
771
767
|
}), _dec11$a = Reflect.metadata("design:type", Function), _dec12$a = Reflect.metadata("design:paramtypes", [Number]), _dec13$a = Caching.set({
|
|
772
768
|
cacheName: 'test-vona:test',
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
cacheValueFn: 'cacheValueSet'
|
|
769
|
+
cacheKeyFn: 'cacheKey',
|
|
770
|
+
cacheValueFn: 'cacheValue'
|
|
776
771
|
}), _dec14$9 = Reflect.metadata("design:type", Function), _dec15$9 = Reflect.metadata("design:paramtypes", [Number, typeof TSummerCacheTestData === "undefined" ? Object : TSummerCacheTestData]), _dec16$9 = Caching.set({
|
|
777
772
|
cacheName: 'test-vona:test',
|
|
778
|
-
|
|
779
|
-
cacheKey: 'cel://join([get(self,"$beanFullName"),options.cacheProp,hashkey([args[0]])],"_")',
|
|
773
|
+
cacheKey: 'cel://args[0]',
|
|
780
774
|
cacheValue: 'cel://{"id": args[1].id, "name": args[1].name}'
|
|
781
775
|
}), _dec17$8 = Reflect.metadata("design:type", Function), _dec18$8 = Reflect.metadata("design:paramtypes", [Number, typeof TSummerCacheTestData === "undefined" ? Object : TSummerCacheTestData]), _dec19$8 = Caching.set({
|
|
782
776
|
cacheName: 'test-vona:test',
|
|
783
|
-
|
|
784
|
-
cacheKeyFn: 'cacheKeySet'
|
|
777
|
+
cacheKeyFn: 'cacheKey'
|
|
785
778
|
}), _dec20$8 = Reflect.metadata("design:type", Function), _dec21$6 = Reflect.metadata("design:paramtypes", [Number, typeof TSummerCacheTestData === "undefined" ? Object : TSummerCacheTestData]), _dec22$5 = Caching.del({
|
|
786
|
-
cacheName: 'test-vona:test'
|
|
787
|
-
cacheProp: 'test'
|
|
779
|
+
cacheName: 'test-vona:test'
|
|
788
780
|
}), _dec23$5 = Reflect.metadata("design:type", Function), _dec24$5 = Reflect.metadata("design:paramtypes", [Number]), _dec25$5 = Caching.clear({
|
|
789
781
|
cacheName: 'test-vona:test'
|
|
790
782
|
}), _dec26$4 = Reflect.metadata("design:type", Function), _dec27$4 = Reflect.metadata("design:paramtypes", []), _dec$10(_class$10 = _dec2$10(_class$10 = (_class2$u = class ServiceCaching extends BeanBase {
|
|
791
|
-
cacheKey(
|
|
792
|
-
return
|
|
783
|
+
cacheKey(info, _options) {
|
|
784
|
+
return info.args[0];
|
|
793
785
|
}
|
|
794
|
-
|
|
795
|
-
return
|
|
796
|
-
}
|
|
797
|
-
cacheValueSet(_value, args, _prop, _options) {
|
|
798
|
-
return args[args.length - 1];
|
|
786
|
+
cacheValue(info, _options) {
|
|
787
|
+
return info.args[1];
|
|
799
788
|
}
|
|
800
789
|
async get(id) {
|
|
801
790
|
return {
|
|
@@ -831,7 +820,7 @@ let ServiceCaching = (_dec$10 = Service(), _dec2$10 = BeanInfo({
|
|
|
831
820
|
async clear() {
|
|
832
821
|
// do nothing
|
|
833
822
|
}
|
|
834
|
-
}, _applyDecoratedDescriptor(_class2$u.prototype, "get", [_dec3$u, _dec4$u, _dec5$
|
|
823
|
+
}, _applyDecoratedDescriptor(_class2$u.prototype, "get", [_dec3$u, _dec4$u, _dec5$s], Object.getOwnPropertyDescriptor(_class2$u.prototype, "get"), _class2$u.prototype), _applyDecoratedDescriptor(_class2$u.prototype, "get2", [_dec6$r, _dec7$n, _dec8$j], Object.getOwnPropertyDescriptor(_class2$u.prototype, "get2"), _class2$u.prototype), _applyDecoratedDescriptor(_class2$u.prototype, "get3", [_dec9$c, _dec0$c, _dec1$c], Object.getOwnPropertyDescriptor(_class2$u.prototype, "get3"), _class2$u.prototype), _applyDecoratedDescriptor(_class2$u.prototype, "get4", [_dec10$a, _dec11$a, _dec12$a], Object.getOwnPropertyDescriptor(_class2$u.prototype, "get4"), _class2$u.prototype), _applyDecoratedDescriptor(_class2$u.prototype, "set", [_dec13$a, _dec14$9, _dec15$9], Object.getOwnPropertyDescriptor(_class2$u.prototype, "set"), _class2$u.prototype), _applyDecoratedDescriptor(_class2$u.prototype, "set2", [_dec16$9, _dec17$8, _dec18$8], Object.getOwnPropertyDescriptor(_class2$u.prototype, "set2"), _class2$u.prototype), _applyDecoratedDescriptor(_class2$u.prototype, "set3", [_dec19$8, _dec20$8, _dec21$6], Object.getOwnPropertyDescriptor(_class2$u.prototype, "set3"), _class2$u.prototype), _applyDecoratedDescriptor(_class2$u.prototype, "del", [_dec22$5, _dec23$5, _dec24$5], Object.getOwnPropertyDescriptor(_class2$u.prototype, "del"), _class2$u.prototype), _applyDecoratedDescriptor(_class2$u.prototype, "clear", [_dec25$5, _dec26$4, _dec27$4], Object.getOwnPropertyDescriptor(_class2$u.prototype, "clear"), _class2$u.prototype), _class2$u)) || _class$10) || _class$10);
|
|
835
824
|
|
|
836
825
|
var _dec$$, _dec2$$, _class$$;
|
|
837
826
|
let ServiceCategory = (_dec$$ = Service(), _dec2$$ = BeanInfo({
|
|
@@ -1042,10 +1031,10 @@ let ServiceOrder = (_dec$_ = Service(), _dec2$_ = BeanInfo({
|
|
|
1042
1031
|
}
|
|
1043
1032
|
}) || _class$_) || _class$_);
|
|
1044
1033
|
|
|
1045
|
-
var _dec$Z, _dec2$Z, _dec3$t, _dec4$t, _dec5$
|
|
1034
|
+
var _dec$Z, _dec2$Z, _dec3$t, _dec4$t, _dec5$r, _class$Z, _class2$t;
|
|
1046
1035
|
let ServicePost = (_dec$Z = Service(), _dec2$Z = BeanInfo({
|
|
1047
1036
|
module: "test-vona"
|
|
1048
|
-
}), _dec3$t = Core.transaction(), _dec4$t = Reflect.metadata("design:type", Function), _dec5$
|
|
1037
|
+
}), _dec3$t = Core.transaction(), _dec4$t = Reflect.metadata("design:type", Function), _dec5$r = Reflect.metadata("design:paramtypes", []), _dec$Z(_class$Z = _dec2$Z(_class$Z = (_class2$t = class ServicePost extends BeanBase {
|
|
1049
1038
|
async findMany(params) {
|
|
1050
1039
|
return await this.scope.model.post.selectAndCount({
|
|
1051
1040
|
...params,
|
|
@@ -1287,7 +1276,7 @@ let ServicePost = (_dec$Z = Service(), _dec2$Z = BeanInfo({
|
|
|
1287
1276
|
// async count() {
|
|
1288
1277
|
// return await this.scope.model.post.count();
|
|
1289
1278
|
// }
|
|
1290
|
-
}, _applyDecoratedDescriptor(_class2$t.prototype, "transaction", [_dec3$t, _dec4$t, _dec5$
|
|
1279
|
+
}, _applyDecoratedDescriptor(_class2$t.prototype, "transaction", [_dec3$t, _dec4$t, _dec5$r], Object.getOwnPropertyDescriptor(_class2$t.prototype, "transaction"), _class2$t.prototype), _class2$t)) || _class$Z) || _class$Z);
|
|
1291
1280
|
|
|
1292
1281
|
var _dec$Y, _dec2$Y, _class$Y;
|
|
1293
1282
|
let ServiceProduct = (_dec$Y = Service(), _dec2$Y = BeanInfo({
|
|
@@ -1433,12 +1422,12 @@ let ServiceTestData = (_dec$U = Service(), _dec2$U = BeanInfo({
|
|
|
1433
1422
|
}
|
|
1434
1423
|
}) || _class$U) || _class$U);
|
|
1435
1424
|
|
|
1436
|
-
var _dec$T, _dec2$T, _dec3$s, _dec4$s, _dec5$
|
|
1425
|
+
var _dec$T, _dec2$T, _dec3$s, _dec4$s, _dec5$q, _dec6$q, _dec7$m, _dec8$i, _class$T, _class2$s;
|
|
1437
1426
|
const tableNameFail$1 = '__tempTransactionFail';
|
|
1438
1427
|
const tableNameSuccess$1 = '__tempTransactionSuccess';
|
|
1439
1428
|
let ServiceTransaction = (_dec$T = Service(), _dec2$T = BeanInfo({
|
|
1440
1429
|
module: "test-vona"
|
|
1441
|
-
}), _dec3$s = Core.transaction(), _dec4$s = Reflect.metadata("design:type", Function), _dec5$
|
|
1430
|
+
}), _dec3$s = Core.transaction(), _dec4$s = Reflect.metadata("design:type", Function), _dec5$q = Reflect.metadata("design:paramtypes", [Object]), _dec6$q = Core.transaction(), _dec7$m = Reflect.metadata("design:type", Function), _dec8$i = Reflect.metadata("design:paramtypes", [Object]), _dec$T(_class$T = _dec2$T(_class$T = (_class2$s = class ServiceTransaction extends BeanBase {
|
|
1442
1431
|
async fail(item) {
|
|
1443
1432
|
await this.bean.model.update(`${tableNameFail$1}`, item);
|
|
1444
1433
|
await this.bean.model.update(`${tableNameFail$1}error`, item);
|
|
@@ -1446,7 +1435,7 @@ let ServiceTransaction = (_dec$T = Service(), _dec2$T = BeanInfo({
|
|
|
1446
1435
|
async success(item) {
|
|
1447
1436
|
await this.bean.model.update(tableNameSuccess$1, item);
|
|
1448
1437
|
}
|
|
1449
|
-
}, _applyDecoratedDescriptor(_class2$s.prototype, "fail", [_dec3$s, _dec4$s, _dec5$
|
|
1438
|
+
}, _applyDecoratedDescriptor(_class2$s.prototype, "fail", [_dec3$s, _dec4$s, _dec5$q], Object.getOwnPropertyDescriptor(_class2$s.prototype, "fail"), _class2$s.prototype), _applyDecoratedDescriptor(_class2$s.prototype, "success", [_dec6$q, _dec7$m, _dec8$i], Object.getOwnPropertyDescriptor(_class2$s.prototype, "success"), _class2$s.prototype), _class2$s)) || _class$T) || _class$T);
|
|
1450
1439
|
|
|
1451
1440
|
var _dec$S, _dec2$S, _class$S;
|
|
1452
1441
|
let ServiceUser = (_dec$S = Service(), _dec2$S = BeanInfo({
|
|
@@ -1783,20 +1772,18 @@ let DtoOrderCreate = (_dec$C = Dto(), _dec2$C = BeanInfo({
|
|
|
1783
1772
|
var _dec$B, _dec2$B, _dec3$r, _dec4$r, _class$B, _class2$r, _descriptor$a;
|
|
1784
1773
|
let DtoOrderQuery = (_dec$B = Dto({
|
|
1785
1774
|
openapi: {
|
|
1786
|
-
|
|
1775
|
+
filter: {
|
|
1787
1776
|
table: $tableName(EntityOrder)
|
|
1788
1777
|
}
|
|
1789
1778
|
}
|
|
1790
1779
|
}), _dec2$B = BeanInfo({
|
|
1791
1780
|
module: "test-vona"
|
|
1792
|
-
}), _dec3$r = Api.field(v.
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
|
|
1798
|
-
}
|
|
1799
|
-
})), _dec4$r = Reflect.metadata("design:type", String), _dec$B(_class$B = _dec2$B(_class$B = (_class2$r = class DtoOrderQuery extends $Dto.query(EntityOrder, ['orderNo', 'remark']) {
|
|
1781
|
+
}), _dec3$r = Api.field(v.filter({
|
|
1782
|
+
table: $tableName(EntityUser),
|
|
1783
|
+
joinType: 'innerJoin',
|
|
1784
|
+
joinOn: ['userId', 'testVonaUser.id'],
|
|
1785
|
+
originalName: 'name'
|
|
1786
|
+
}), v.optional()), _dec4$r = Reflect.metadata("design:type", String), _dec$B(_class$B = _dec2$B(_class$B = (_class2$r = class DtoOrderQuery extends $Dto.query(EntityOrder, ['orderNo', 'remark']) {
|
|
1800
1787
|
constructor(...args) {
|
|
1801
1788
|
super(...args);
|
|
1802
1789
|
_initializerDefineProperty(this, "userName", _descriptor$a, this);
|
|
@@ -1870,28 +1857,40 @@ let DtoPostGroup = (_dec$u = Dto(), _dec2$u = BeanInfo({
|
|
|
1870
1857
|
sum: 'stars'
|
|
1871
1858
|
}) {}) || _class$u) || _class$u);
|
|
1872
1859
|
|
|
1873
|
-
var _dec$t, _dec2$t, _dec3$p, _dec4$p, _class$t, _class2$p, _descriptor$8;
|
|
1860
|
+
var _dec$t, _dec2$t, _dec3$p, _dec4$p, _dec5$p, _dec6$p, _dec7$l, _dec8$h, _class$t, _class2$p, _descriptor$8, _descriptor2$8, _descriptor3$4;
|
|
1874
1861
|
let DtoPostQuery = (_dec$t = Dto({
|
|
1875
1862
|
openapi: {
|
|
1876
|
-
|
|
1863
|
+
filter: {
|
|
1877
1864
|
table: $tableName(EntityPost)
|
|
1878
1865
|
}
|
|
1879
1866
|
}
|
|
1880
1867
|
}), _dec2$t = BeanInfo({
|
|
1881
1868
|
module: "test-vona"
|
|
1882
|
-
}), _dec3$p = Api.field(v.optional(), v.
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1889
|
-
})),
|
|
1869
|
+
}), _dec3$p = Api.field(v.optional()), _dec4$p = Reflect.metadata("design:type", String), _dec5$p = Api.field(v.filter({
|
|
1870
|
+
table: 'testVonaUser',
|
|
1871
|
+
joinOn: ['userId', 'testVonaUser.id'],
|
|
1872
|
+
originalName: 'name',
|
|
1873
|
+
op: '_eqI_'
|
|
1874
|
+
}), v.optional()), _dec6$p = Reflect.metadata("design:type", String), _dec7$l = Api.field(v.filterDateRange({
|
|
1875
|
+
separator: ' - '
|
|
1876
|
+
}), v.optional()), _dec8$h = Reflect.metadata("design:type", String), _dec$t(_class$t = _dec2$t(_class$t = (_class2$p = class DtoPostQuery extends $Dto.queryPage(EntityPost, ['title']) {
|
|
1890
1877
|
constructor(...args) {
|
|
1891
1878
|
super(...args);
|
|
1892
|
-
_initializerDefineProperty(this, "
|
|
1879
|
+
_initializerDefineProperty(this, "title", _descriptor$8, this);
|
|
1880
|
+
_initializerDefineProperty(this, "userName", _descriptor2$8, this);
|
|
1881
|
+
_initializerDefineProperty(this, "createdAt", _descriptor3$4, this);
|
|
1893
1882
|
}
|
|
1894
|
-
}, _descriptor$8 = _applyDecoratedDescriptor(_class2$p.prototype, "
|
|
1883
|
+
}, _descriptor$8 = _applyDecoratedDescriptor(_class2$p.prototype, "title", [_dec3$p, _dec4$p], {
|
|
1884
|
+
configurable: true,
|
|
1885
|
+
enumerable: true,
|
|
1886
|
+
writable: true,
|
|
1887
|
+
initializer: null
|
|
1888
|
+
}), _descriptor2$8 = _applyDecoratedDescriptor(_class2$p.prototype, "userName", [_dec5$p, _dec6$p], {
|
|
1889
|
+
configurable: true,
|
|
1890
|
+
enumerable: true,
|
|
1891
|
+
writable: true,
|
|
1892
|
+
initializer: null
|
|
1893
|
+
}), _descriptor3$4 = _applyDecoratedDescriptor(_class2$p.prototype, "createdAt", [_dec7$l, _dec8$h], {
|
|
1895
1894
|
configurable: true,
|
|
1896
1895
|
enumerable: true,
|
|
1897
1896
|
writable: true,
|
|
@@ -2660,13 +2659,6 @@ let ControllerOnion = (_dec$b = Controller({
|
|
|
2660
2659
|
}, _applyDecoratedDescriptor(_class2$a.prototype, "index", [_dec3$a, _dec4$a, _dec5$a, _dec6$a, _dec7$a], Object.getOwnPropertyDescriptor(_class2$a.prototype, "index"), _class2$a.prototype), _applyDecoratedDescriptor(_class2$a.prototype, "echo", [_dec8$8, _dec9$7, _dec0$7, _dec1$7, _dec10$6, _dec11$6, _dec12$6, _dec13$6, _dec14$5, _dec15$5, _dec16$5, _dec17$5], Object.getOwnPropertyDescriptor(_class2$a.prototype, "echo"), _class2$a.prototype), _applyDecoratedDescriptor(_class2$a.prototype, "echo2", [_dec18$5, _dec19$5, _dec20$5, _dec21$3, _dec22$2, _dec23$2, _dec24$2, _dec25$2], Object.getOwnPropertyDescriptor(_class2$a.prototype, "echo2"), _class2$a.prototype), _applyDecoratedDescriptor(_class2$a.prototype, "echo3", [_dec26$1, _dec27$1, _dec28, _dec29, _dec30, _dec31, _dec32], Object.getOwnPropertyDescriptor(_class2$a.prototype, "echo3"), _class2$a.prototype), _applyDecoratedDescriptor(_class2$a.prototype, "echo4", [_dec33, _dec34, _dec35, _dec36, _dec37, _dec38, _dec39], Object.getOwnPropertyDescriptor(_class2$a.prototype, "echo4"), _class2$a.prototype), _applyDecoratedDescriptor(_class2$a.prototype, "echo5", [_dec40, _dec41, _dec42, _dec43, _dec44], Object.getOwnPropertyDescriptor(_class2$a.prototype, "echo5"), _class2$a.prototype), _applyDecoratedDescriptor(_class2$a.prototype, "echo6", [_dec45, _dec46, _dec47, _dec48], Object.getOwnPropertyDescriptor(_class2$a.prototype, "echo6"), _class2$a.prototype), _class2$a)) || _class$b) || _class$b);
|
|
2661
2660
|
|
|
2662
2661
|
var _dec$a, _dec2$a, _dec3$9, _dec4$9, _dec5$9, _dec6$9, _dec7$9, _dec8$7, _dec9$6, _dec0$6, _dec1$6, _dec10$5, _dec11$5, _dec12$5, _dec13$5, _dec14$4, _dec15$4, _dec16$4, _dec17$4, _dec18$4, _dec19$4, _dec20$4, _class$a, _class2$9;
|
|
2663
|
-
function myCustomQueryTransform(_ctx, info) {
|
|
2664
|
-
if (info.key === 'userName') {
|
|
2665
|
-
info.params.where[info.fullName] = info.value;
|
|
2666
|
-
return true;
|
|
2667
|
-
}
|
|
2668
|
-
return undefined;
|
|
2669
|
-
}
|
|
2670
2662
|
let ControllerOrder = (_dec$a = Controller('order'), _dec2$a = BeanInfo({
|
|
2671
2663
|
module: "test-vona"
|
|
2672
2664
|
}), _dec3$9 = Web.post('create'), _dec4$9 = Api.body(v.tableIdentity()), _dec5$9 = function (target, key) {
|
|
@@ -2676,9 +2668,9 @@ let ControllerOrder = (_dec$a = Controller('order'), _dec2$a = BeanInfo({
|
|
|
2676
2668
|
}, _dec0$6 = function (target, key) {
|
|
2677
2669
|
return Arg.body()(target, key, 1);
|
|
2678
2670
|
}, _dec1$6 = Reflect.metadata("design:type", Function), _dec10$5 = Reflect.metadata("design:paramtypes", [typeof TableIdentity === "undefined" ? Object : TableIdentity, typeof DtoOrderUpdate === "undefined" ? Object : DtoOrderUpdate]), _dec11$5 = Web.get('findAll'), _dec12$5 = Api.body(v.array(DtoOrderResult)), _dec13$5 = function (target, key) {
|
|
2679
|
-
return Arg.
|
|
2671
|
+
return Arg.filter(DtoOrderQuery)(target, key, 0);
|
|
2680
2672
|
}, _dec14$4 = Reflect.metadata("design:type", Function), _dec15$4 = Reflect.metadata("design:paramtypes", [typeof IQueryParams === "undefined" ? Object : IQueryParams]), _dec16$4 = Web.get('findMany'), _dec17$4 = Api.body(DtoOrderResultPage), _dec18$4 = function (target, key) {
|
|
2681
|
-
return Arg.
|
|
2673
|
+
return Arg.filter(DtoOrderQueryPage)(target, key, 0);
|
|
2682
2674
|
}, _dec19$4 = Reflect.metadata("design:type", Function), _dec20$4 = Reflect.metadata("design:paramtypes", [typeof IQueryParams === "undefined" ? Object : IQueryParams]), _dec$a(_class$a = _dec2$a(_class$a = (_class2$9 = class ControllerOrder extends BeanBase {
|
|
2683
2675
|
async create(data) {
|
|
2684
2676
|
return (await this.scope.model.order.insert(data)).id;
|
|
@@ -2772,9 +2764,9 @@ let ControllerPost = (_dec$7 = Controller('post', {
|
|
|
2772
2764
|
}), _dec2$7 = BeanInfo({
|
|
2773
2765
|
module: "test-vona"
|
|
2774
2766
|
}), _dec3$6 = Web.get('group'), _dec4$6 = Api.body(v.array(DtoPostGroup)), _dec5$6 = Reflect.metadata("design:type", Function), _dec6$6 = Reflect.metadata("design:paramtypes", []), _dec7$6 = Web.get('aggregate'), _dec8$4 = Api.body(DtoPostAggregate), _dec9$4 = Reflect.metadata("design:type", Function), _dec0$4 = Reflect.metadata("design:paramtypes", []), _dec1$4 = Web.get('findManyEcho'), _dec10$3 = Api.body(DtoPostQueryRes), _dec11$3 = Passport.public(), _dec12$3 = function (target, key) {
|
|
2775
|
-
return Arg.
|
|
2767
|
+
return Arg.filter(DtoPostQuery)(target, key, 0);
|
|
2776
2768
|
}, _dec13$3 = Reflect.metadata("design:type", Function), _dec14$2 = Reflect.metadata("design:paramtypes", [typeof IQueryParams === "undefined" ? Object : IQueryParams]), _dec15$2 = Web.get('findMany'), _dec16$2 = Api.body(DtoPostQueryRes), _dec17$2 = Passport.public(), _dec18$2 = function (target, key) {
|
|
2777
|
-
return Arg.
|
|
2769
|
+
return Arg.filter(DtoPostQuery)(target, key, 0);
|
|
2778
2770
|
}, _dec19$2 = Reflect.metadata("design:type", Function), _dec20$2 = Reflect.metadata("design:paramtypes", [typeof IQueryParams === "undefined" ? Object : IQueryParams]), _dec$7(_class$7 = _dec2$7(_class$7 = (_class2$6 = class ControllerPost extends BeanBase {
|
|
2779
2771
|
async group() {
|
|
2780
2772
|
return await this.scope.model.post.group({
|
|
@@ -2799,9 +2791,6 @@ let ControllerPost = (_dec$7 = Controller('post', {
|
|
|
2799
2791
|
findManyEcho(params) {
|
|
2800
2792
|
return params;
|
|
2801
2793
|
}
|
|
2802
|
-
findManyQueryTransform(_info) {
|
|
2803
|
-
return undefined;
|
|
2804
|
-
}
|
|
2805
2794
|
async findMany(params) {
|
|
2806
2795
|
return await this.scope.service.post.findMany(params);
|
|
2807
2796
|
}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import type { TypeCachingActionOptions } from 'vona-module-a-caching';
|
|
1
|
+
import type { ICachingActionKeyInfo, ICachingActionValueInfo, TypeCachingActionOptions } from 'vona-module-a-caching';
|
|
2
2
|
import type { TSummerCacheTestData } from '../bean/summerCache.test.ts';
|
|
3
3
|
import { BeanBase } from 'vona';
|
|
4
4
|
export declare class ServiceCaching extends BeanBase {
|
|
5
|
-
cacheKey(
|
|
6
|
-
|
|
7
|
-
cacheValueSet(_value: any, args: any[], _prop: string, _options: TypeCachingActionOptions): any;
|
|
5
|
+
cacheKey(info: ICachingActionKeyInfo, _options: TypeCachingActionOptions): any;
|
|
6
|
+
cacheValue(info: ICachingActionValueInfo, _options: TypeCachingActionOptions): any;
|
|
8
7
|
get(id: number): Promise<TSummerCacheTestData>;
|
|
9
8
|
get2(_id: number): Promise<TSummerCacheTestData>;
|
|
10
9
|
get3(_id: number): Promise<TSummerCacheTestData>;
|