taon 21.0.3 → 21.0.6
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/browser/fesm2022/taon.mjs +1953 -1238
- package/browser/fesm2022/taon.mjs.map +1 -1
- package/browser/package.json +1 -1
- package/browser/types/taon.d.ts +2152 -0
- package/lib/base-classes/base-abstract-entity.d.ts +1 -1
- package/lib/base-classes/base-abstract-entity.js +12 -12
- package/lib/base-classes/base-abstract-entity.js.map +1 -1
- package/lib/base-classes/base-angular-service.d.ts +1 -1
- package/lib/base-classes/base-angular-service.js +6 -3
- package/lib/base-classes/base-angular-service.js.map +1 -1
- package/lib/base-classes/base-context.d.ts +2 -2
- package/lib/base-classes/base-controller.js +7 -1
- package/lib/base-classes/base-controller.js.map +1 -1
- package/lib/base-classes/base-crud-controller.js +52 -12
- package/lib/base-classes/base-crud-controller.js.map +1 -1
- package/lib/base-classes/base-entity.js +2 -6
- package/lib/base-classes/base-entity.js.map +1 -1
- package/lib/base-classes/base-repository.d.ts +3 -3
- package/lib/base-classes/base-repository.js +15 -10
- package/lib/base-classes/base-repository.js.map +1 -1
- package/lib/base-classes/base.d.ts +1 -46
- package/lib/base-classes/base.js +17 -30
- package/lib/base-classes/base.js.map +1 -1
- package/lib/build-info._auto-generated_.d.ts +1 -1
- package/lib/build-info._auto-generated_.js +1 -1
- package/lib/context-db-migrations.d.ts +2 -1
- package/lib/create-context.d.ts +4 -4
- package/lib/decorators/classes/entity-decorator.js +1 -1
- package/lib/decorators/classes/entity-decorator.js.map +1 -1
- package/lib/decorators/http/http-decorators.d.ts +1 -19
- package/lib/decorators/http/http-decorators.js +20 -22
- package/lib/decorators/http/http-decorators.js.map +1 -1
- package/lib/endpoint-context.d.ts +3 -2
- package/lib/formly/{formly-group-wrapper-component.d.ts → formly-group-wrapper.component.d.ts} +1 -1
- package/lib/formly/{formly-repeat-component.d.ts → formly-repeat.component.d.ts} +1 -1
- package/lib/formly/fromly.js +24 -24
- package/lib/formly/fromly.js.map +1 -1
- package/lib/index.d.ts +146 -45
- package/lib/index.js +166 -55
- package/lib/index.js.map +1 -1
- package/lib/orm/columns.d.ts +28 -0
- package/lib/orm/columns.js +102 -0
- package/lib/orm/columns.js.map +1 -0
- package/lib/orm/index.d.ts +1 -0
- package/lib/orm/index.js +73 -0
- package/lib/orm/index.js.map +1 -0
- package/lib/realtime/realtime-core.d.ts +1 -1
- package/lib/realtime/realtime-strategy/realtime-strategy-socket-io.d.ts +1 -2
- package/lib/realtime/realtime-strategy/realtime-strategy-socket-io.js.map +1 -1
- package/lib/realtime/realtime-strategy/realtime-strategy.d.ts +1 -1
- package/lib/realtime/realtime-subs-manager.d.ts +1 -1
- package/lib/symbols.d.ts +31 -31
- package/lib/symbols.js +59 -59
- package/lib/symbols.js.map +1 -1
- package/lib/ui/index.js +2 -2
- package/lib/ui/taon-admin-mode-configuration/index.js +2 -2
- package/package.json +1 -1
- package/websql/fesm2022/taon.mjs +1316 -648
- package/websql/fesm2022/taon.mjs.map +1 -1
- package/websql/package.json +1 -1
- package/websql/types/taon.d.ts +2161 -0
- package/browser/index.d.ts +0 -6
- package/browser/lib/base-classes/base-abstract-entity.d.ts +0 -8
- package/browser/lib/base-classes/base-angular-service.d.ts +0 -34
- package/browser/lib/base-classes/base-class.d.ts +0 -16
- package/browser/lib/base-classes/base-context.d.ts +0 -21
- package/browser/lib/base-classes/base-controller.d.ts +0 -83
- package/browser/lib/base-classes/base-crud-controller.d.ts +0 -29
- package/browser/lib/base-classes/base-custom-repository.d.ts +0 -4
- package/browser/lib/base-classes/base-entity.d.ts +0 -17
- package/browser/lib/base-classes/base-file-upload.middleware.d.ts +0 -15
- package/browser/lib/base-classes/base-injector.d.ts +0 -68
- package/browser/lib/base-classes/base-middleware.d.ts +0 -39
- package/browser/lib/base-classes/base-migration.d.ts +0 -12
- package/browser/lib/base-classes/base-provider.d.ts +0 -9
- package/browser/lib/base-classes/base-repository.d.ts +0 -267
- package/browser/lib/base-classes/base-subscriber-for-entity.d.ts +0 -82
- package/browser/lib/base-classes/base.d.ts +0 -47
- package/browser/lib/config/controller-config.d.ts +0 -22
- package/browser/lib/config/controller-options.d.ts +0 -17
- package/browser/lib/config/method-config.d.ts +0 -40
- package/browser/lib/config/param-config.d.ts +0 -9
- package/browser/lib/constants.d.ts +0 -10
- package/browser/lib/context-db-migrations.d.ts +0 -18
- package/browser/lib/create-context.d.ts +0 -79
- package/browser/lib/decorators/classes/controller-decorator.d.ts +0 -6
- package/browser/lib/decorators/classes/entity-decorator.d.ts +0 -20
- package/browser/lib/decorators/classes/middleware-decorator.d.ts +0 -8
- package/browser/lib/decorators/classes/migration-decorator.d.ts +0 -8
- package/browser/lib/decorators/classes/provider-decorator.d.ts +0 -8
- package/browser/lib/decorators/classes/repository-decorator.d.ts +0 -8
- package/browser/lib/decorators/classes/subscriber-decorator.d.ts +0 -9
- package/browser/lib/decorators/decorator-abstract-opt.d.ts +0 -4
- package/browser/lib/decorators/http/http-decorators.d.ts +0 -21
- package/browser/lib/decorators/http/http-methods-decorators.d.ts +0 -71
- package/browser/lib/decorators/http/http-params-decorators.d.ts +0 -9
- package/browser/lib/dependency-injection/di-container.d.ts +0 -6
- package/browser/lib/endpoint-context-storage.d.ts +0 -12
- package/browser/lib/endpoint-context.d.ts +0 -198
- package/browser/lib/entity-process.d.ts +0 -40
- package/browser/lib/get-response-value.d.ts +0 -7
- package/browser/lib/helpers/class-helpers.d.ts +0 -25
- package/browser/lib/helpers/clone-obj.d.ts +0 -2
- package/browser/lib/helpers/taon-helpers.d.ts +0 -19
- package/browser/lib/index.d.ts +0 -129
- package/browser/lib/inject.d.ts +0 -5
- package/browser/lib/models.d.ts +0 -257
- package/browser/lib/orm.d.ts +0 -3
- package/browser/lib/realtime/realtime-client.d.ts +0 -42
- package/browser/lib/realtime/realtime-core.d.ts +0 -41
- package/browser/lib/realtime/realtime-server.d.ts +0 -44
- package/browser/lib/realtime/realtime-strategy/index.d.ts +0 -5
- package/browser/lib/realtime/realtime-strategy/realtime-strategy-ipc.d.ts +0 -82
- package/browser/lib/realtime/realtime-strategy/realtime-strategy-mock.d.ts +0 -15
- package/browser/lib/realtime/realtime-strategy/realtime-strategy-socket-io.d.ts +0 -16
- package/browser/lib/realtime/realtime-strategy/realtime-strategy.d.ts +0 -12
- package/browser/lib/realtime/realtime-subs-manager.d.ts +0 -15
- package/browser/lib/realtime/realtime.models.d.ts +0 -28
- package/browser/lib/symbols.d.ts +0 -66
- package/browser/lib/ui/index.d.ts +0 -2
- package/browser/lib/ui/taon-admin-mode-configuration/index.d.ts +0 -2
- package/browser/lib/ui/taon-admin-mode-configuration/taon-admin.service.d.ts +0 -22
- package/browser/lib/validators.d.ts +0 -8
- package/browser/public-api.d.ts +0 -2
- package/lib/decorators/classes/controller-config.d.ts +0 -20
- package/lib/decorators/classes/controller-config.js +0 -21
- package/lib/decorators/classes/controller-config.js.map +0 -1
- package/lib/decorators/classes/controller-options.d.ts +0 -16
- package/lib/decorators/classes/controller-options.js +0 -20
- package/lib/decorators/classes/controller-options.js.map +0 -1
- package/lib/formly/formly-group-wrapper-component.js +0 -51
- package/lib/formly/formly-group-wrapper-component.js.map +0 -1
- package/lib/formly/formly-repeat-component.js +0 -95
- package/lib/formly/formly-repeat-component.js.map +0 -1
- package/lib/orm.d.ts +0 -68
- package/lib/orm.js +0 -112
- package/lib/orm.js.map +0 -1
- package/websql/index.d.ts +0 -6
- package/websql/lib/base-classes/base-abstract-entity.d.ts +0 -8
- package/websql/lib/base-classes/base-angular-service.d.ts +0 -34
- package/websql/lib/base-classes/base-class.d.ts +0 -16
- package/websql/lib/base-classes/base-context.d.ts +0 -21
- package/websql/lib/base-classes/base-controller.d.ts +0 -83
- package/websql/lib/base-classes/base-crud-controller.d.ts +0 -29
- package/websql/lib/base-classes/base-custom-repository.d.ts +0 -4
- package/websql/lib/base-classes/base-entity.d.ts +0 -17
- package/websql/lib/base-classes/base-file-upload.middleware.d.ts +0 -15
- package/websql/lib/base-classes/base-injector.d.ts +0 -68
- package/websql/lib/base-classes/base-middleware.d.ts +0 -39
- package/websql/lib/base-classes/base-migration.d.ts +0 -12
- package/websql/lib/base-classes/base-provider.d.ts +0 -9
- package/websql/lib/base-classes/base-repository.d.ts +0 -272
- package/websql/lib/base-classes/base-subscriber-for-entity.d.ts +0 -82
- package/websql/lib/base-classes/base.d.ts +0 -47
- package/websql/lib/config/controller-config.d.ts +0 -22
- package/websql/lib/config/controller-options.d.ts +0 -17
- package/websql/lib/config/method-config.d.ts +0 -40
- package/websql/lib/config/param-config.d.ts +0 -9
- package/websql/lib/constants.d.ts +0 -10
- package/websql/lib/context-db-migrations.d.ts +0 -18
- package/websql/lib/create-context.d.ts +0 -79
- package/websql/lib/decorators/classes/controller-decorator.d.ts +0 -6
- package/websql/lib/decorators/classes/entity-decorator.d.ts +0 -20
- package/websql/lib/decorators/classes/middleware-decorator.d.ts +0 -8
- package/websql/lib/decorators/classes/migration-decorator.d.ts +0 -8
- package/websql/lib/decorators/classes/provider-decorator.d.ts +0 -8
- package/websql/lib/decorators/classes/repository-decorator.d.ts +0 -8
- package/websql/lib/decorators/classes/subscriber-decorator.d.ts +0 -9
- package/websql/lib/decorators/decorator-abstract-opt.d.ts +0 -4
- package/websql/lib/decorators/http/http-decorators.d.ts +0 -21
- package/websql/lib/decorators/http/http-methods-decorators.d.ts +0 -71
- package/websql/lib/decorators/http/http-params-decorators.d.ts +0 -9
- package/websql/lib/dependency-injection/di-container.d.ts +0 -6
- package/websql/lib/endpoint-context-storage.d.ts +0 -12
- package/websql/lib/endpoint-context.d.ts +0 -200
- package/websql/lib/entity-process.d.ts +0 -40
- package/websql/lib/get-response-value.d.ts +0 -7
- package/websql/lib/helpers/class-helpers.d.ts +0 -25
- package/websql/lib/helpers/clone-obj.d.ts +0 -2
- package/websql/lib/helpers/taon-helpers.d.ts +0 -19
- package/websql/lib/index.d.ts +0 -129
- package/websql/lib/inject.d.ts +0 -5
- package/websql/lib/models.d.ts +0 -261
- package/websql/lib/orm.d.ts +0 -69
- package/websql/lib/realtime/realtime-client.d.ts +0 -42
- package/websql/lib/realtime/realtime-core.d.ts +0 -41
- package/websql/lib/realtime/realtime-server.d.ts +0 -44
- package/websql/lib/realtime/realtime-strategy/index.d.ts +0 -5
- package/websql/lib/realtime/realtime-strategy/realtime-strategy-ipc.d.ts +0 -82
- package/websql/lib/realtime/realtime-strategy/realtime-strategy-mock.d.ts +0 -15
- package/websql/lib/realtime/realtime-strategy/realtime-strategy-socket-io.d.ts +0 -16
- package/websql/lib/realtime/realtime-strategy/realtime-strategy.d.ts +0 -12
- package/websql/lib/realtime/realtime-subs-manager.d.ts +0 -15
- package/websql/lib/realtime/realtime.models.d.ts +0 -28
- package/websql/lib/symbols.d.ts +0 -66
- package/websql/lib/ui/index.d.ts +0 -2
- package/websql/lib/ui/taon-admin-mode-configuration/index.d.ts +0 -2
- package/websql/lib/ui/taon-admin-mode-configuration/taon-admin.service.d.ts +0 -22
- package/websql/lib/validators.d.ts +0 -8
- package/websql/public-api.d.ts +0 -2
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import type { EndpointContext } from './endpoint-context';
|
|
2
|
+
import { Table } from 'taon-typeorm';
|
|
2
3
|
export type MigrationStatus = 'completed' | 'pending';
|
|
3
4
|
export declare class ContextDbMigrations {
|
|
4
5
|
private ctx;
|
|
5
6
|
readonly DEFAULT_MIGRATION_TABLE_NAME = "TAON_MIGRATION_META";
|
|
6
7
|
readonly MIGRATION_STATUS_COMPLETED: MigrationStatus;
|
|
7
8
|
readonly MIGRATION_STATUS_PENDING: MigrationStatus;
|
|
8
|
-
readonly table:
|
|
9
|
+
readonly table: Table;
|
|
9
10
|
constructor(ctx: EndpointContext);
|
|
10
11
|
ensureMigrationTableExists(): Promise<void>;
|
|
11
12
|
private logSelectALl;
|
package/lib/create-context.d.ts
CHANGED
|
@@ -36,8 +36,8 @@ export declare const createContextTemplate: <CTX extends Record<string, object>,
|
|
|
36
36
|
* TCP(upgrade) socket.io (or ipc) based.
|
|
37
37
|
*/
|
|
38
38
|
readonly realtime: {
|
|
39
|
-
readonly client: import("
|
|
40
|
-
readonly server: import("
|
|
39
|
+
readonly client: import(".").RealtimeClient;
|
|
40
|
+
readonly server: import(".").RealtimeServer;
|
|
41
41
|
};
|
|
42
42
|
};
|
|
43
43
|
export declare const createContext: <CTX extends Record<string, object>, CTRL extends Record<string, new (...args: any[]) => any>, ENTITY extends Record<string, new (...args: any[]) => any>, REPO extends Record<string, new (...args: any[]) => any>, PROVIDER extends Record<string, new (...args: any[]) => any>, SUBSCRIBER extends Record<string, new (...args: any[]) => any>, MIGRATION extends Record<string, new (...args: any[]) => any>, MIDDLEWARES extends Record<string, new (...args: any[]) => any>>(configFn: (env: any) => Models.ContextOptions<CTX, CTRL, ENTITY, REPO, PROVIDER, SUBSCRIBER, MIGRATION, MIDDLEWARES>) => {
|
|
@@ -71,8 +71,8 @@ export declare const createContext: <CTX extends Record<string, object>, CTRL ex
|
|
|
71
71
|
* TCP(upgrade) socket.io (or ipc) based.
|
|
72
72
|
*/
|
|
73
73
|
readonly realtime: {
|
|
74
|
-
readonly client: import("
|
|
75
|
-
readonly server: import("
|
|
74
|
+
readonly client: import(".").RealtimeClient;
|
|
75
|
+
readonly server: import(".").RealtimeServer;
|
|
76
76
|
};
|
|
77
77
|
};
|
|
78
78
|
export type TaonContext = ReturnType<typeof createContext>;
|
|
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.TaonEntityOptions = void 0;
|
|
4
4
|
exports.TaonEntity = TaonEntity;
|
|
5
5
|
const lib_1 = require("ng2-rest/lib");
|
|
6
|
-
const lib_2 = require("taon-typeorm/lib");
|
|
6
|
+
const lib_2 = require("taon-typeorm/lib");
|
|
7
7
|
const lib_3 = require("tnp-core/lib");
|
|
8
8
|
const lib_4 = require("typescript-class-helpers/lib");
|
|
9
9
|
const class_helpers_1 = require("../../helpers/class-helpers");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"entity-decorator.js","sourceRoot":"","sources":[""],"names":[],"mappings":";;;AAYA,gCAgCC;AA5CD,sCAAuC;AACvC,
|
|
1
|
+
{"version":3,"file":"entity-decorator.js","sourceRoot":"","sources":[""],"names":[],"mappings":";;;AAYA,gCAgCC;AA5CD,sCAAuC;AACvC,0CAA0C;AAC1C,sCAAiC;AACjC,sDAAqD;AAErD,+DAA2D;AAC3D,2CAAwC;AACxC,sEAAiE;AAEjE;;GAEG;AACH,SAAgB,UAAU,CAAU,OAA8B;IAChE,OAAO,UAAU,WAAqB;QACpC,OAAO,GAAG,OAAO,IAAK,EAAU,CAAC;QACjC,OAAO,CAAC,aAAa,GAAG,OAAO,CAAC,aAAa,IAAK,IAAY,CAAC;QAC/D,4BAAY,CAAC,OAAO,CAAC,WAAW,EAAE,OAAO,EAAE,SAAS,CAAC,CAAC;QAEtD,aAAO,CAAC,uBAAuB,CAC7B,OAAO,EAAE,kBAAkB,IAAI,EAAE,EACjC,OAAC,CAAC,KAAK,CACL,OAAO,EAAE,mBAAmB,IAAI,EAAE,EAClC,CAAC,OAAO,EAAE,uBAAuB,IAAI,EAAE,CAAQ,CAChD,CACF,CAAC,WAAW,CAAC,CAAC;QAEf,mDAAmD;QACnD,aAAO,CAAC,uBAAuB,CAAI,KAAK,CAAC,EAAE,EAAE,CAAC,CAAC,WAAW,CAAC,CAAC;QAE5D,OAAO,CAAC,cAAc,CACpB,iBAAO,CAAC,QAAQ,CAAC,OAAO,CAAC,MAAM,EAC/B,OAAO,EACP,WAAW,CACZ,CAAC;QACF,OAAO,CAAC,cAAc,CACpB,iBAAO,CAAC,QAAQ,CAAC,SAAS,EAC1B,OAAO,EAAE,SAAS,IAAI,WAAW,CAAC,IAAI,EACtC,WAAW,CACZ,CAAC;QACF,iBAAiB;QACjB,IAAA,YAAM,EAAC,OAAO,EAAE,SAAS,CAAC,CAAC,WAAW,CAAC,CAAC;QACxC,YAAY;QACZ,WAAK,CAAC,OAAO,CAAC,WAAW,EAAE,OAAO,EAAE,SAAS,CAAC,CAAC,CAAC,8BAA8B;IAChF,CAAC,CAAC;AACJ,CAAC;AAED,MAAa,iBAA2B,SAAQ,6CAAoB;IAClE;;;OAGG;IACH,aAAa,CAAU;IACvB,WAAW,CAAW;IACtB,kBAAkB,CAAyB;IAC3C,mBAAmB,CAAsB;IACzC,uBAAuB,CAAiD;CACzE;AAVD,8CAUC"}
|
|
@@ -1,20 +1,2 @@
|
|
|
1
1
|
import { Models } from 'ng2-rest';
|
|
2
|
-
import
|
|
3
|
-
import * as params from './http-params-decorators';
|
|
4
|
-
export declare namespace Http {
|
|
5
|
-
export import GET = methods.GET;
|
|
6
|
-
export import POST = methods.POST;
|
|
7
|
-
export import PUT = methods.PUT;
|
|
8
|
-
export import DELETE = methods.DELETE;
|
|
9
|
-
export import PATCH = methods.PATCH;
|
|
10
|
-
export import HEAD = methods.HEAD;
|
|
11
|
-
export import HTML = methods.HTML;
|
|
12
|
-
export import Response = Models.HttpResponse;
|
|
13
|
-
namespace Param {
|
|
14
|
-
export import Query = params.Query;
|
|
15
|
-
export import Path = params.Path;
|
|
16
|
-
export import Body = params.Body;
|
|
17
|
-
export import Cookie = params.Cookie;
|
|
18
|
-
export import Header = params.Header;
|
|
19
|
-
}
|
|
20
|
-
}
|
|
2
|
+
export import HttpResponse = Models.HttpResponse;
|
|
@@ -1,26 +1,24 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.HttpResponse = void 0;
|
|
4
4
|
const lib_1 = require("ng2-rest/lib");
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
})(Param = Http.Param || (Http.Param = {}));
|
|
25
|
-
})(Http || (exports.Http = Http = {}));
|
|
5
|
+
exports.HttpResponse = lib_1.Models.HttpResponse;
|
|
6
|
+
// TODO new 5.8 typescript is not allowing this
|
|
7
|
+
// export namespace Http {
|
|
8
|
+
// export import GET = methods.GET;
|
|
9
|
+
// export import POST = methods.POST;
|
|
10
|
+
// export import PUT = methods.PUT;
|
|
11
|
+
// export import DELETE = methods.DELETE;
|
|
12
|
+
// export import PATCH = methods.PATCH;
|
|
13
|
+
// export import HEAD = methods.HEAD;
|
|
14
|
+
// export import HTML = methods.HTML;
|
|
15
|
+
// export import Response = Models.HttpResponse;
|
|
16
|
+
// export namespace Param {
|
|
17
|
+
// export import Query = params.Query;
|
|
18
|
+
// export import Path = params.Path;
|
|
19
|
+
// export import Body = params.Body;
|
|
20
|
+
// export import Cookie = params.Cookie;
|
|
21
|
+
// export import Header = params.Header;
|
|
22
|
+
// }
|
|
23
|
+
// }
|
|
26
24
|
//# sourceMappingURL=http-decorators.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"http-decorators.js","sourceRoot":"","sources":[""],"names":[],"mappings":";;;AAAA,sCAAsC;
|
|
1
|
+
{"version":3,"file":"http-decorators.js","sourceRoot":"","sources":[""],"names":[],"mappings":";;;AAAA,sCAAsC;AAKxB,QAAA,YAAY,GAAG,YAAM,CAAC,YAAY,CAAC;AAEjD,+CAA+C;AAC/C,0BAA0B;AAC1B,qCAAqC;AACrC,uCAAuC;AACvC,qCAAqC;AACrC,2CAA2C;AAC3C,yCAAyC;AACzC,uCAAuC;AACvC,uCAAuC;AACvC,kDAAkD;AAClD,6BAA6B;AAC7B,0CAA0C;AAC1C,wCAAwC;AACxC,wCAAwC;AACxC,4CAA4C;AAC5C,4CAA4C;AAC5C,MAAM;AACN,IAAI"}
|
|
@@ -3,6 +3,7 @@ import { URL } from 'url';
|
|
|
3
3
|
import type { NgZone } from '@angular/core';
|
|
4
4
|
import * as express from 'express';
|
|
5
5
|
import type { Application } from 'express';
|
|
6
|
+
import type { Repository } from 'taon-typeorm';
|
|
6
7
|
import { DataSource } from 'taon-typeorm';
|
|
7
8
|
import type { TaonBaseInjector } from './base-classes/base-injector';
|
|
8
9
|
import { ContextDbMigrations } from './context-db-migrations';
|
|
@@ -59,8 +60,8 @@ export declare class EndpointContext {
|
|
|
59
60
|
connection: DataSource;
|
|
60
61
|
private entitiesTriggers;
|
|
61
62
|
private realtime;
|
|
62
|
-
get realtimeClient(): import("
|
|
63
|
-
get realtimeServer(): import("
|
|
63
|
+
get realtimeClient(): import(".").RealtimeClient;
|
|
64
|
+
get realtimeServer(): import(".").RealtimeServer;
|
|
64
65
|
/**
|
|
65
66
|
* available after init()
|
|
66
67
|
*/
|
package/lib/formly/fromly.js
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.getFromlyConfigFor = getFromlyConfigFor;
|
|
4
|
-
const lib_1 = require("
|
|
5
|
-
const lib_2 = require("
|
|
6
|
-
const type_from_entity_1 = require("./type-from-entity");
|
|
4
|
+
const lib_1 = require("ng2-rest/lib");
|
|
5
|
+
const lib_2 = require("tnp-core/lib");
|
|
7
6
|
const lib_3 = require("typescript-class-helpers/lib");
|
|
7
|
+
const type_from_entity_1 = require("./type-from-entity");
|
|
8
8
|
function getFromlyConfigFor(target, options = {}) {
|
|
9
9
|
const { formType = 'material', keysPathesToExclude = [], keysPathesToInclude = [], parentModel, relativePath = '', level = 0, maxLevel = 4, } = options;
|
|
10
10
|
if (level === maxLevel) {
|
|
11
11
|
return [];
|
|
12
12
|
}
|
|
13
|
-
const mapping =
|
|
13
|
+
const mapping = lib_1.Mapping.getModelsMapping(target);
|
|
14
14
|
// console.log('mapping', mapping)
|
|
15
15
|
const fieldNames = lib_3.CLASS.describeProperites(target);
|
|
16
|
-
const checkExclude =
|
|
17
|
-
const checkInclude =
|
|
16
|
+
const checkExclude = lib_2._.isArray(keysPathesToExclude) && keysPathesToExclude.length > 0;
|
|
17
|
+
const checkInclude = lib_2._.isArray(keysPathesToInclude) && keysPathesToInclude.length > 0;
|
|
18
18
|
if (checkExclude && checkInclude) {
|
|
19
19
|
throw new Error(`In Taon function getFromlyConfigFor(...) please use keysPathesToInclude or keysPathesToExclude, `);
|
|
20
20
|
}
|
|
@@ -47,7 +47,7 @@ function getFromlyConfigFor(target, options = {}) {
|
|
|
47
47
|
fieldArray: {
|
|
48
48
|
fieldGroupClassName: 'row',
|
|
49
49
|
templateOptions: {
|
|
50
|
-
label: `Add new ${
|
|
50
|
+
label: `Add new ${lib_2._.startCase(key)}`,
|
|
51
51
|
},
|
|
52
52
|
fieldGroup,
|
|
53
53
|
},
|
|
@@ -68,7 +68,7 @@ function getFromlyConfigFor(target, options = {}) {
|
|
|
68
68
|
res = {
|
|
69
69
|
fieldGroupClassName: 'row',
|
|
70
70
|
templateOptions: {
|
|
71
|
-
label: `${
|
|
71
|
+
label: `${lib_2._.startCase(key)}`,
|
|
72
72
|
},
|
|
73
73
|
wrappers: ['groupwrap'],
|
|
74
74
|
fieldGroup,
|
|
@@ -80,16 +80,16 @@ function getFromlyConfigFor(target, options = {}) {
|
|
|
80
80
|
key,
|
|
81
81
|
model,
|
|
82
82
|
type,
|
|
83
|
-
defaultValue: !
|
|
83
|
+
defaultValue: !lib_2._.isUndefined(target.prototype[key])
|
|
84
84
|
? target.prototype[key]
|
|
85
85
|
: undefined,
|
|
86
86
|
templateOptions: {
|
|
87
|
-
label:
|
|
87
|
+
label: lib_2._.isString(model)
|
|
88
88
|
? `${model
|
|
89
89
|
.split('.')
|
|
90
|
-
.map(l =>
|
|
91
|
-
.join(' / ')} / ${
|
|
92
|
-
:
|
|
90
|
+
.map(l => lib_2._.startCase(l))
|
|
91
|
+
.join(' / ')} / ${lib_2._.startCase(key)}`
|
|
92
|
+
: lib_2._.startCase(key),
|
|
93
93
|
options: selectOptions,
|
|
94
94
|
},
|
|
95
95
|
};
|
|
@@ -131,30 +131,30 @@ function getFromlyConfigFor(target, options = {}) {
|
|
|
131
131
|
function resolveSimpleTypes() {
|
|
132
132
|
for (const key in target.prototype) {
|
|
133
133
|
if (target.prototype.hasOwnProperty(key) &&
|
|
134
|
-
!
|
|
134
|
+
!lib_2._.isFunction(target.prototype[key])) {
|
|
135
135
|
if (!isAlowedPath(key)) {
|
|
136
136
|
continue;
|
|
137
137
|
}
|
|
138
|
-
if (!
|
|
138
|
+
if (!lib_2._.isUndefined(mapping[key])) {
|
|
139
139
|
continue;
|
|
140
140
|
}
|
|
141
141
|
const element = target.prototype[key];
|
|
142
142
|
let type = 'input';
|
|
143
|
-
if (
|
|
143
|
+
if (lib_2._.isBoolean(element)) {
|
|
144
144
|
type = 'switch';
|
|
145
145
|
}
|
|
146
|
-
else if (
|
|
146
|
+
else if (lib_2._.isDate(element)) {
|
|
147
147
|
type = 'datepicker';
|
|
148
148
|
}
|
|
149
|
-
else if (
|
|
149
|
+
else if (lib_2._.isFunction(target['getOptionsFor'])) {
|
|
150
150
|
var selectOptions = target['getOptionsFor'](key);
|
|
151
|
-
if (!
|
|
151
|
+
if (!lib_2._.isUndefined(selectOptions)) {
|
|
152
152
|
type = 'select';
|
|
153
153
|
}
|
|
154
154
|
}
|
|
155
|
-
else if (
|
|
155
|
+
else if (lib_2._.isFunction(target.prototype?.getOptionsFor)) {
|
|
156
156
|
var selectOptions = target.prototype?.getOptionsFor(key);
|
|
157
|
-
if (!
|
|
157
|
+
if (!lib_2._.isUndefined(selectOptions)) {
|
|
158
158
|
type = 'select';
|
|
159
159
|
}
|
|
160
160
|
}
|
|
@@ -169,10 +169,10 @@ function getFromlyConfigFor(target, options = {}) {
|
|
|
169
169
|
fieldNames
|
|
170
170
|
.filter(key => !simpleResolved.includes(key))
|
|
171
171
|
.forEach(key => {
|
|
172
|
-
if (isAlowedPath(key) && !
|
|
172
|
+
if (isAlowedPath(key) && !lib_2._.isUndefined(mapping[key])) {
|
|
173
173
|
let className = mapping[key];
|
|
174
|
-
const isArray =
|
|
175
|
-
className = isArray ?
|
|
174
|
+
const isArray = lib_2._.isArray(className);
|
|
175
|
+
className = isArray ? lib_2._.first(className) : className;
|
|
176
176
|
if (className === 'Date') {
|
|
177
177
|
fields.push(inputToPush(key, 'datepicker', parentModel));
|
|
178
178
|
}
|
package/lib/formly/fromly.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fromly.js","sourceRoot":"","sources":[""],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"fromly.js","sourceRoot":"","sources":[""],"names":[],"mappings":";;AASA,gDAsPC;AA9PD,sCAAuC;AACvC,sCAAiC;AAEjC,sDAAqD;AAGrD,yDAAuD;AAEvD,SAAgB,kBAAkB,CAChC,MAAgB,EAChB,UAQI,EAAE;IAEN,MAAM,EACJ,QAAQ,GAAG,UAAU,EACrB,mBAAmB,GAAG,EAAE,EACxB,mBAAmB,GAAG,EAAE,EACxB,WAAW,EACX,YAAY,GAAG,EAAE,EACjB,KAAK,GAAG,CAAC,EACT,QAAQ,GAAG,CAAC,GACb,GAAG,OAAO,CAAC;IAEZ,IAAI,KAAK,KAAK,QAAQ,EAAE,CAAC;QACvB,OAAO,EAAE,CAAC;IACZ,CAAC;IAED,MAAM,OAAO,GAAoB,aAAO,CAAC,gBAAgB,CAAC,MAAM,CAAC,CAAC;IAClE,kCAAkC;IAClC,MAAM,UAAU,GAAG,WAAK,CAAC,kBAAkB,CAAC,MAAM,CAAC,CAAC;IACpD,MAAM,YAAY,GAChB,OAAC,CAAC,OAAO,CAAC,mBAAmB,CAAC,IAAI,mBAAmB,CAAC,MAAM,GAAG,CAAC,CAAC;IACnE,MAAM,YAAY,GAChB,OAAC,CAAC,OAAO,CAAC,mBAAmB,CAAC,IAAI,mBAAmB,CAAC,MAAM,GAAG,CAAC,CAAC;IACnE,IAAI,YAAY,IAAI,YAAY,EAAE,CAAC;QACj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IACP,CAAC;IACD,YAAY;IAEZ,SAAS,QAAQ;QACf,kBAAkB,EAAE,CAAC;QACrB,uCAAuC;QACvC,mBAAmB,EAAE,CAAC;QACtB,yCAAyC;IAC3C,CAAC;IAED,QAAQ,EAAE,CAAC;IACX,OAAO,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AACjC,CAAC"}
|
package/lib/index.d.ts
CHANGED
|
@@ -1,58 +1,81 @@
|
|
|
1
1
|
import 'reflect-metadata';
|
|
2
2
|
import { NgZone } from '@angular/core';
|
|
3
3
|
import { RestErrorResponseWrapper } from 'ng2-rest';
|
|
4
|
-
import * as base from './base-classes/base';
|
|
5
|
-
import * as controllerDecorator from './decorators/classes/controller-decorator';
|
|
6
|
-
import * as entityDecorator from './decorators/classes/entity-decorator';
|
|
7
|
-
import * as middlewareDecorator from './decorators/classes/middleware-decorator';
|
|
8
|
-
import * as migrationDecorator from './decorators/classes/migration-decorator';
|
|
9
|
-
import * as providerDecorator from './decorators/classes/provider-decorator';
|
|
10
|
-
import * as repositoryDecorator from './decorators/classes/repository-decorator';
|
|
11
|
-
import * as subscriberDecorator from './decorators/classes/subscriber-decorator';
|
|
12
|
-
import * as http from './decorators/http/http-decorators';
|
|
13
4
|
import * as endpointContext from './endpoint-context';
|
|
14
5
|
import * as models from './models';
|
|
15
|
-
import * as orm from './orm';
|
|
16
6
|
import * as allSymbols from './symbols';
|
|
17
|
-
export * from './ui';
|
|
18
|
-
export { EndpointContext } from './endpoint-context';
|
|
19
|
-
export { TaonBaseRepository } from './base-classes/base-repository';
|
|
20
|
-
export { TaonBaseCustomRepository } from './base-classes/base-custom-repository';
|
|
21
|
-
export { TaonBaseController } from './base-classes/base-controller';
|
|
22
|
-
export { TaonBaseProvider } from './base-classes/base-provider';
|
|
23
|
-
export { TaonBaseEntity } from './base-classes/base-entity';
|
|
24
|
-
export { TaonBaseContext } from './base-classes/base-context';
|
|
25
|
-
export { TaonBaseMigration } from './base-classes/base-migration';
|
|
26
|
-
export { TaonBaseClass } from './base-classes/base-class';
|
|
27
|
-
export { TaonAdditionalMiddlewareMethodInfo } from './base-classes/base-middleware';
|
|
28
|
-
export { createContext, TaonContext } from './create-context';
|
|
29
|
-
export { inject } from './inject';
|
|
30
|
-
export { Models, BaseTaonClassesNames, TaonTempDatabasesFolder, TaonTempRoutesFolder, } from './models';
|
|
31
|
-
export { TaonBaseFileUploadMiddleware } from './base-classes/base-file-upload.middleware';
|
|
32
7
|
export * from './constants';
|
|
33
|
-
export
|
|
34
|
-
export
|
|
35
|
-
export
|
|
8
|
+
export * from './context-db-migrations';
|
|
9
|
+
export * from './create-context';
|
|
10
|
+
export * from './endpoint-context-storage';
|
|
11
|
+
export * from './endpoint-context';
|
|
12
|
+
export * from './entity-process';
|
|
13
|
+
export * from './get-response-value';
|
|
14
|
+
export * from './inject';
|
|
15
|
+
export * from './models';
|
|
16
|
+
export * from './symbols';
|
|
17
|
+
export * from './validators';
|
|
18
|
+
export * from './base-classes/base-abstract-entity';
|
|
19
|
+
export * from './base-classes/base-angular-service';
|
|
20
|
+
export * from './base-classes/base-class';
|
|
21
|
+
export * from './base-classes/base-context';
|
|
22
|
+
export * from './base-classes/base-controller';
|
|
23
|
+
export * from './base-classes/base-crud-controller';
|
|
24
|
+
export * from './base-classes/base-custom-repository';
|
|
25
|
+
export * from './base-classes/base-entity';
|
|
26
|
+
export * from './base-classes/base-file-upload.middleware';
|
|
27
|
+
export * from './base-classes/base-injector';
|
|
28
|
+
export * from './base-classes/base-middleware';
|
|
29
|
+
export * from './base-classes/base-migration';
|
|
30
|
+
export * from './base-classes/base-provider';
|
|
31
|
+
export * from './base-classes/base-repository';
|
|
32
|
+
export * from './base-classes/base-subscriber-for-entity';
|
|
33
|
+
export * from './config/controller-config';
|
|
34
|
+
export * from './config/controller-options';
|
|
35
|
+
export * from './config/method-config';
|
|
36
|
+
export * from './config/param-config';
|
|
37
|
+
export * from './decorators/decorator-abstract-opt';
|
|
38
|
+
export * from './dependency-injection/di-container';
|
|
39
|
+
export * from './formly/formly-group-wrapper.component';
|
|
40
|
+
export * from './formly/formly-repeat.component';
|
|
41
|
+
export * from './formly/formly.models';
|
|
42
|
+
export * from './formly/fromly';
|
|
43
|
+
export * from './formly/type-from-entity';
|
|
44
|
+
export * from './helpers/class-helpers';
|
|
45
|
+
export * from './helpers/clone-obj';
|
|
46
|
+
export * from './helpers/taon-helpers';
|
|
47
|
+
export * from './orm/columns';
|
|
48
|
+
export * from './realtime/realtime-client';
|
|
49
|
+
export * from './realtime/realtime-core';
|
|
50
|
+
export * from './realtime/realtime-server';
|
|
51
|
+
export * from './realtime/realtime-subs-manager';
|
|
52
|
+
export * from './realtime/realtime.models';
|
|
53
|
+
export * from './decorators/classes/controller-decorator';
|
|
54
|
+
export * from './decorators/classes/entity-decorator';
|
|
55
|
+
export * from './decorators/classes/middleware-decorator';
|
|
56
|
+
export * from './decorators/classes/migration-decorator';
|
|
57
|
+
export * from './decorators/classes/provider-decorator';
|
|
58
|
+
export * from './decorators/classes/repository-decorator';
|
|
59
|
+
export * from './decorators/classes/subscriber-decorator';
|
|
60
|
+
export * from './decorators/http/http-methods-decorators';
|
|
61
|
+
export * from './decorators/http/http-params-decorators';
|
|
62
|
+
export * from './realtime/realtime-strategy/realtime-strategy-ipc';
|
|
63
|
+
export * from './realtime/realtime-strategy/realtime-strategy-mock';
|
|
64
|
+
export * from './realtime/realtime-strategy/realtime-strategy-socket-io';
|
|
65
|
+
export * from './realtime/realtime-strategy/realtime-strategy';
|
|
66
|
+
export * from './ui/taon-admin-mode-configuration/taon-admin.service';
|
|
67
|
+
export * from './formly/formly-group-wrapper.component';
|
|
68
|
+
export * from './formly/formly-repeat.component';
|
|
36
69
|
export type { TaonClientMiddlewareInterceptOptions, TaonServerMiddlewareInterceptOptions, } from 'ng2-rest';
|
|
37
70
|
export declare namespace Taon {
|
|
38
71
|
const error: (opt: Pick<RestErrorResponseWrapper, "message" | "status" | "details" | "code"> | string) => void;
|
|
39
72
|
type ResponseHtml = models.Models.Http.Response<string>;
|
|
40
73
|
export import Response = models.Models.Http.Response;
|
|
41
|
-
export import Http = http.Http;
|
|
42
|
-
export import Base = base.Base;
|
|
43
|
-
export import Orm = orm.Orm;
|
|
44
74
|
export import StartParams = models.Models.StartParams;
|
|
45
75
|
const getResponseValue: <T>(response: Response<T>, options?: {
|
|
46
76
|
req: import("express").Request;
|
|
47
77
|
res: import("express").Response;
|
|
48
78
|
}) => Promise<T>;
|
|
49
|
-
export import Controller = controllerDecorator.TaonController;
|
|
50
|
-
export import Entity = entityDecorator.TaonEntity;
|
|
51
|
-
export import Provider = providerDecorator.TaonProvider;
|
|
52
|
-
export import Repository = repositoryDecorator.TaonRepository;
|
|
53
|
-
export import Subscriber = subscriberDecorator.TaonSubscriber;
|
|
54
|
-
export import Migration = migrationDecorator.TaonMigration;
|
|
55
|
-
export import Middleware = middlewareDecorator.TaonMiddleware;
|
|
56
79
|
const isBrowser: boolean;
|
|
57
80
|
const isNode: boolean;
|
|
58
81
|
const isWebSQL: boolean;
|
|
@@ -72,8 +95,8 @@ export declare namespace Taon {
|
|
|
72
95
|
getClass<T>(ctor: new (...args: any[]) => T): new (...args: any[]) => T;
|
|
73
96
|
initialize: (overrideOptions?: models.Models.TaonInitializeParams) => Promise<endpointContext.EndpointContext>;
|
|
74
97
|
readonly realtime: {
|
|
75
|
-
readonly client: import("
|
|
76
|
-
readonly server: import("
|
|
98
|
+
readonly client: import(".").RealtimeClient;
|
|
99
|
+
readonly server: import(".").RealtimeServer;
|
|
77
100
|
};
|
|
78
101
|
};
|
|
79
102
|
const createContextTemplate: <CTX extends Record<string, object>, CTRL extends Record<string, new (...args: any[]) => any>, ENTITY extends Record<string, new (...args: any[]) => any>, REPO extends Record<string, new (...args: any[]) => any>, PROVIDER extends Record<string, new (...args: any[]) => any>, SUBSCRIBER extends Record<string, new (...args: any[]) => any>, MIGRATION extends Record<string, new (...args: any[]) => any>, MIDDLEWARE extends Record<string, new (...args: any[]) => any>>(configFn: (env: any) => models.Models.ContextOptions<CTX, CTRL, ENTITY, REPO, PROVIDER, SUBSCRIBER, MIGRATION, MIDDLEWARE>) => () => {
|
|
@@ -91,8 +114,8 @@ export declare namespace Taon {
|
|
|
91
114
|
getClass<T>(ctor: new (...args: any[]) => T): new (...args: any[]) => T;
|
|
92
115
|
initialize: (overrideOptions?: models.Models.TaonInitializeParams) => Promise<endpointContext.EndpointContext>;
|
|
93
116
|
readonly realtime: {
|
|
94
|
-
readonly client: import("
|
|
95
|
-
readonly server: import("
|
|
117
|
+
readonly client: import(".").RealtimeClient;
|
|
118
|
+
readonly server: import(".").RealtimeServer;
|
|
96
119
|
};
|
|
97
120
|
};
|
|
98
121
|
const inject: <T>(entity: () => new (...args: any[]) => T) => T;
|
|
@@ -121,8 +144,86 @@ export declare namespace Taon {
|
|
|
121
144
|
getClass<T>(ctor: new (...args: any[]) => T): new (...args: any[]) => T;
|
|
122
145
|
initialize: (overrideOptions?: models.Models.TaonInitializeParams) => Promise<endpointContext.EndpointContext>;
|
|
123
146
|
readonly realtime: {
|
|
124
|
-
readonly client: import("
|
|
125
|
-
readonly server: import("
|
|
147
|
+
readonly client: import(".").RealtimeClient;
|
|
148
|
+
readonly server: import(".").RealtimeServer;
|
|
126
149
|
};
|
|
127
150
|
}>;
|
|
128
|
-
}
|
|
151
|
+
}
|
|
152
|
+
export declare const TAON_FLATTEN_MAPPING: {
|
|
153
|
+
'taon': {
|
|
154
|
+
'Taon.Http.GET': string;
|
|
155
|
+
'Taon.Http.POST': string;
|
|
156
|
+
'Taon.Http.PUT': string;
|
|
157
|
+
'Taon.Http.DELETE': string;
|
|
158
|
+
'Taon.Http.PATCH': string;
|
|
159
|
+
'Taon.Http.HEAD': string;
|
|
160
|
+
'Taon.Http.HTML': string;
|
|
161
|
+
'Taon.Http.Response': string;
|
|
162
|
+
'Taon.Http.Param.Query': string;
|
|
163
|
+
'Taon.Http.Param.Path': string;
|
|
164
|
+
'Taon.Http.Param.Body': string;
|
|
165
|
+
'Taon.Http.Param.Cookie': string;
|
|
166
|
+
'Taon.Http.Param.Header': string;
|
|
167
|
+
'Taon.Base.Controller': string;
|
|
168
|
+
'Taon.Base.CrudController': string;
|
|
169
|
+
'Taon.Base.Entity': string;
|
|
170
|
+
'Taon.Base.AbstractEntity': string;
|
|
171
|
+
'Taon.Base.AbstractEntityOmitKeys': string;
|
|
172
|
+
'Taon.Base.Provider': string;
|
|
173
|
+
'Taon.Base.Class': string;
|
|
174
|
+
'Taon.Base.Repository': string;
|
|
175
|
+
'Taon.Base.CustomRepository': string;
|
|
176
|
+
'Taon.Base.SubscriberForEntity': string;
|
|
177
|
+
'Taon.Base.Migration': string;
|
|
178
|
+
'Taon.Base.Middleware': string;
|
|
179
|
+
'Taon.Base.AngularService': string;
|
|
180
|
+
'Taon.Base.Context': string;
|
|
181
|
+
'Taon.Controller': string;
|
|
182
|
+
'Taon.Entity': string;
|
|
183
|
+
'Taon.Provider': string;
|
|
184
|
+
'Taon.Repository': string;
|
|
185
|
+
'Taon.Subscriber': string;
|
|
186
|
+
'Taon.Migration': string;
|
|
187
|
+
'Taon.Middleware': string;
|
|
188
|
+
'Taon.Orm.Repository': string;
|
|
189
|
+
'Taon.Orm.Connection': string;
|
|
190
|
+
'Taon.Orm.ListenEvent.AfterInsert': string;
|
|
191
|
+
'Taon.Orm.ListenEvent.AfterLoad': string;
|
|
192
|
+
'Taon.Orm.ListenEvent.AfterRecover': string;
|
|
193
|
+
'Taon.Orm.ListenEvent.AfterRemove': string;
|
|
194
|
+
'Taon.Orm.ListenEvent.AfterSoftRemove': string;
|
|
195
|
+
'Taon.Orm.ListenEvent.AfterUpdate': string;
|
|
196
|
+
'Taon.Orm.ListenEvent.BeforeInsert': string;
|
|
197
|
+
'Taon.Orm.ListenEvent.BeforeRecover': string;
|
|
198
|
+
'Taon.Orm.ListenEvent.BeforeRemove': string;
|
|
199
|
+
'Taon.Orm.ListenEvent.BeforeSoftRemove': string;
|
|
200
|
+
'Taon.Orm.ListenEvent.BeforeUpdate': string;
|
|
201
|
+
'Taon.Orm.Tree.Children': string;
|
|
202
|
+
'Taon.Orm.Tree.Parent': string;
|
|
203
|
+
'Taon.Orm.Column.Generated': string;
|
|
204
|
+
'Taon.Orm.Column.Primary': string;
|
|
205
|
+
'Taon.Orm.Column.Index': string;
|
|
206
|
+
'Taon.Orm.Column.CreateDate': string;
|
|
207
|
+
'Taon.Orm.Column.UpdateDate': string;
|
|
208
|
+
'Taon.Orm.Column.DeleteDate': string;
|
|
209
|
+
'Taon.Orm.Column.Custom': string;
|
|
210
|
+
'Taon.Orm.Column.String': string;
|
|
211
|
+
'Taon.Orm.Column.String100': string;
|
|
212
|
+
'Taon.Orm.Column.String45': string;
|
|
213
|
+
'Taon.Orm.Column.String500': string;
|
|
214
|
+
'Taon.Orm.Column.String200': string;
|
|
215
|
+
'Taon.Orm.Column.Number': string;
|
|
216
|
+
'Taon.Orm.Column.DecimalNumber': string;
|
|
217
|
+
'Taon.Orm.Column.SimpleJson': string;
|
|
218
|
+
'Taon.Orm.Column.Boolean': string;
|
|
219
|
+
'Taon.Orm.Column.DateTIme': string;
|
|
220
|
+
'Taon.Orm.Column.Version': string;
|
|
221
|
+
'Taon.Orm.Column.Virtual': string;
|
|
222
|
+
'Taon.Orm.Join.Table': string;
|
|
223
|
+
'Taon.Orm.Join.Column': string;
|
|
224
|
+
'Taon.Orm.Relation.OneToMany': string;
|
|
225
|
+
'Taon.Orm.Relation.OneToOne': string;
|
|
226
|
+
'Taon.Orm.Relation.ManyToMany': string;
|
|
227
|
+
'Taon.Orm.Relation.ManyToOne': string;
|
|
228
|
+
};
|
|
229
|
+
};
|