vona-module-test-vona 5.0.47 → 5.0.49

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "vona-module-test-vona",
3
3
  "type": "module",
4
- "version": "5.0.47",
4
+ "version": "5.0.49",
5
5
  "title": "test-vona",
6
6
  "vonaModule": {
7
7
  "fileVersion": 1,
@@ -1,6 +1,7 @@
1
1
  /* eslint-disable */
2
2
  import type { TypeEntityMeta,TypeModelsClassLikeGeneral,TypeSymbolKeyFieldsMore,IModelRelationHasOne,IModelRelationBelongsTo,IModelRelationHasMany,IModelRelationBelongsToMany } from 'vona-module-a-orm';
3
3
  import type { TypeEntityOptionsFields,TypeControllerOptionsActions } from 'vona-module-a-openapi';
4
+ import type { TableIdentity } from 'table-identity';
4
5
  /** aop: begin */
5
6
  export * from '../bean/aop.regExp.ts';
6
7
  export * from '../bean/aop.simple.ts';
@@ -445,7 +446,7 @@ declare module 'vona' {
445
446
  }
446
447
  /** model: end */
447
448
  /** model: begin */
448
- import type { IModelGetOptions, IModelMethodOptions, IModelSelectParams, TableIdentity, TypeModelSelectAndCount, TypeModelRelationResult, TypeModelWhere, IModelInsertOptions, TypeModelMutateRelationData, IModelDeleteOptions, IModelUpdateOptions, IModelMutateOptions, IModelSelectCountParams, IModelSelectAggrParams, TypeModelAggrRelationResult, IModelSelectGroupParams, TypeModelGroupRelationResult } from 'vona-module-a-orm';
449
+ import type { IModelGetOptions, IModelMethodOptions, IModelSelectParams, TypeModelSelectAndCount, TypeModelRelationResult, TypeModelWhere, IModelInsertOptions, TypeModelMutateRelationData, IModelDeleteOptions, IModelUpdateOptions, IModelMutateOptions, IModelSelectCountParams, IModelSelectAggrParams, TypeModelAggrRelationResult, IModelSelectGroupParams, TypeModelGroupRelationResult } from 'vona-module-a-orm';
449
450
  import { SymbolKeyEntity, SymbolKeyEntityMeta, SymbolKeyModelOptions } from 'vona-module-a-orm';
450
451
  declare module 'vona-module-test-vona' {
451
452
  export interface IModelOptionsCategory {
@@ -1463,6 +1464,7 @@ export * from '../controller/captcha.ts';
1463
1464
  export * from '../controller/dtoTest.ts';
1464
1465
  export * from '../controller/guardPassport.ts';
1465
1466
  export * from '../controller/onion.ts';
1467
+ export * from '../controller/order.ts';
1466
1468
  export * from '../controller/passport.ts';
1467
1469
  export * from '../controller/performAction.ts';
1468
1470
  export * from '../controller/post.ts';
@@ -1478,6 +1480,7 @@ import type { IControllerOptionsCaptcha } from '../controller/captcha.ts';
1478
1480
  import type { IControllerOptionsDtoTest } from '../controller/dtoTest.ts';
1479
1481
  import type { IControllerOptionsGuardPassport } from '../controller/guardPassport.ts';
1480
1482
  import type { IControllerOptionsOnion } from '../controller/onion.ts';
1483
+ import type { IControllerOptionsOrder } from '../controller/order.ts';
1481
1484
  import type { IControllerOptionsPassport } from '../controller/passport.ts';
1482
1485
  import type { IControllerOptionsPerformAction } from '../controller/performAction.ts';
1483
1486
  import type { IControllerOptionsPost } from '../controller/post.ts';
@@ -1497,6 +1500,7 @@ declare module 'vona-module-a-web' {
1497
1500
  'test-vona:dtoTest': IControllerOptionsDtoTest;
1498
1501
  'test-vona:guardPassport': IControllerOptionsGuardPassport;
1499
1502
  'test-vona:onion': IControllerOptionsOnion;
1503
+ 'test-vona:order': IControllerOptionsOrder;
1500
1504
  'test-vona:passport': IControllerOptionsPassport;
1501
1505
  'test-vona:performAction': IControllerOptionsPerformAction;
1502
1506
  'test-vona:post': IControllerOptionsPost;
@@ -1581,6 +1585,16 @@ declare module 'vona-module-test-vona' {
1581
1585
  get $onionName(): 'test-vona:onion';
1582
1586
  }
1583
1587
 
1588
+ export interface ControllerOrder {
1589
+ /** @internal */
1590
+ get scope(): ScopeModuleTestVona;
1591
+ }
1592
+
1593
+ export interface ControllerOrder {
1594
+ get $beanFullName(): 'test-vona.controller.order';
1595
+ get $onionName(): 'test-vona:order';
1596
+ }
1597
+
1584
1598
  export interface ControllerPassport {
1585
1599
  /** @internal */
1586
1600
  get scope(): ScopeModuleTestVona;
@@ -1678,6 +1692,8 @@ import type { ControllerGuardPassport } from '../controller/guardPassport.ts';
1678
1692
  // @ts-ignore ignore
1679
1693
  import type { ControllerOnion } from '../controller/onion.ts';
1680
1694
  // @ts-ignore ignore
1695
+ import type { ControllerOrder } from '../controller/order.ts';
1696
+ // @ts-ignore ignore
1681
1697
  import type { ControllerPassport } from '../controller/passport.ts';
1682
1698
  // @ts-ignore ignore
1683
1699
  import type { ControllerPerformAction } from '../controller/performAction.ts';
@@ -1723,6 +1739,10 @@ declare module 'vona-module-test-vona' {
1723
1739
  actions?: TypeControllerOptionsActions<ControllerOnion>;
1724
1740
  }
1725
1741
 
1742
+ export interface IControllerOptionsOrder {
1743
+ actions?: TypeControllerOptionsActions<ControllerOrder>;
1744
+ }
1745
+
1726
1746
  export interface IControllerOptionsPassport {
1727
1747
  actions?: TypeControllerOptionsActions<ControllerPassport>;
1728
1748
  }
@@ -1773,6 +1793,7 @@ declare module 'vona-module-a-web' {
1773
1793
  '/test/vona/onion/echo3/:userId': undefined;
1774
1794
  '/test/vona/onion/echo5': undefined;
1775
1795
  '/test/vona/onion/echo6': undefined;
1796
+ '/test/vona/order/findAll': undefined;
1776
1797
  '/test/vona/passport/echo/:name': undefined;
1777
1798
  '/test/vona/passport/isAuthenticated': undefined;
1778
1799
  '/test/vona/post/findManyEcho': undefined;
@@ -1,7 +1,8 @@
1
+ import type { TableIdentity } from 'table-identity';
1
2
  import type { IDecoratorControllerOptions } from 'vona-module-a-web';
2
3
  import { BeanBase } from 'vona';
3
4
  import { Api, v } from 'vona-module-a-openapi';
4
- import { $Dto, TableIdentity } from 'vona-module-a-orm';
5
+ import { $Dto } from 'vona-module-a-orm';
5
6
  import { Arg, Controller, Web } from 'vona-module-a-web';
6
7
  import { DtoCategoryTree } from '../dto/categoryTree.ts';
7
8
  import { DtoUserCreate } from '../dto/userCreate.ts';
@@ -0,0 +1,20 @@
1
+ import type { IDecoratorControllerOptions } from 'vona-module-a-web';
2
+ import { BeanBase } from 'vona';
3
+ import { Api, v } from 'vona-module-a-openapi';
4
+ import { Controller, Web } from 'vona-module-a-web';
5
+ import { DtoOrderResult } from '../dto/orderResult.ts';
6
+
7
+ export interface IControllerOptionsOrder extends IDecoratorControllerOptions {}
8
+
9
+ @Controller<IControllerOptionsOrder>('order')
10
+ export class ControllerOrder extends BeanBase {
11
+ @Web.get('findAll')
12
+ @Api.body(v.array(DtoOrderResult))
13
+ async findAll(): Promise<DtoOrderResult[]> {
14
+ return this.scope.model.order.select({
15
+ include: {
16
+ products: true,
17
+ },
18
+ });
19
+ }
20
+ }
package/src/dto/user.ts CHANGED
@@ -1,4 +1,4 @@
1
- import type { TableIdentity } from 'vona-module-a-orm';
1
+ import type { TableIdentity } from 'table-identity';
2
2
  import type { IDecoratorDtoOptions } from 'vona-module-a-web';
3
3
  import { Api, v } from 'vona-module-a-openapi';
4
4
  import { Dto } from 'vona-module-a-web';
@@ -1,4 +1,5 @@
1
- import type { IDecoratorEntityOptions, TableIdentity } from 'vona-module-a-orm';
1
+ import type { TableIdentity } from 'table-identity';
2
+ import type { IDecoratorEntityOptions } from 'vona-module-a-orm';
2
3
  import { Api, v } from 'vona-module-a-openapi';
3
4
  import { Entity, EntityBase } from 'vona-module-a-orm';
4
5
 
@@ -1,4 +1,5 @@
1
- import type { IDecoratorEntityOptions, TableIdentity } from 'vona-module-a-orm';
1
+ import type { TableIdentity } from 'table-identity';
2
+ import type { IDecoratorEntityOptions } from 'vona-module-a-orm';
2
3
  import { Api, v } from 'vona-module-a-openapi';
3
4
  import { Entity, EntityBase } from 'vona-module-a-orm';
4
5
  import { $locale } from '../.metadata/index.ts';
@@ -1,4 +1,5 @@
1
- import type { IDecoratorEntityOptions, TableIdentity } from 'vona-module-a-orm';
1
+ import type { TableIdentity } from 'table-identity';
2
+ import type { IDecoratorEntityOptions } from 'vona-module-a-orm';
2
3
  import { Api, v } from 'vona-module-a-openapi';
3
4
  import { Entity, EntityBase } from 'vona-module-a-orm';
4
5
 
@@ -1,4 +1,5 @@
1
- import type { IDecoratorEntityOptions, TableIdentity } from 'vona-module-a-orm';
1
+ import type { TableIdentity } from 'table-identity';
2
+ import type { IDecoratorEntityOptions } from 'vona-module-a-orm';
2
3
  import { Api, v } from 'vona-module-a-openapi';
3
4
  import { Entity, EntityBase } from 'vona-module-a-orm';
4
5
 
@@ -1,4 +1,5 @@
1
- import type { IDecoratorEntityOptions, TableIdentity } from 'vona-module-a-orm';
1
+ import type { TableIdentity } from 'table-identity';
2
+ import type { IDecoratorEntityOptions } from 'vona-module-a-orm';
2
3
  import { Api, v } from 'vona-module-a-openapi';
3
4
  import { Entity, EntityBase } from 'vona-module-a-orm';
4
5
  import { $locale } from '../.metadata/index.ts';
@@ -1,4 +1,5 @@
1
- import type { IDecoratorEntityOptions, TableIdentity } from 'vona-module-a-orm';
1
+ import type { TableIdentity } from 'table-identity';
2
+ import type { IDecoratorEntityOptions } from 'vona-module-a-orm';
2
3
  import { Api, v } from 'vona-module-a-openapi';
3
4
  import { Entity, EntityBase } from 'vona-module-a-orm';
4
5