taon 21.0.44 → 21.0.48
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/bin/start.js +8 -211
- package/bin/taon +1 -2
- package/bin/taon-debug +1 -1
- package/bin/taon-debug-brk +1 -2
- package/browser/package.json +1 -1
- package/browser/types/taon-browser.d.ts +3 -3
- package/browser-prod/package.json +1 -1
- package/browser-prod/types/taon-browser.d.ts +3 -3
- package/cli.js +3 -0
- package/cli.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/package.json +1 -1
- package/lib/ui/index.js +2 -2
- package/lib/ui/taon-admin-mode-configuration/index.js +2 -2
- package/lib-prod/base-classes/base-abstract-entity.ts +34 -0
- package/lib-prod/base-classes/base-angular-service.ts +107 -0
- package/lib-prod/base-classes/base-class.ts +46 -0
- package/lib-prod/base-classes/base-context.ts +21 -0
- package/lib-prod/base-classes/base-controller.ts +240 -0
- package/lib-prod/base-classes/base-crud-controller.ts +298 -0
- package/lib-prod/base-classes/base-custom-repository.ts +10 -0
- package/lib-prod/base-classes/{base-electron-service.js → base-electron-service.ts} +12 -2
- package/lib-prod/base-classes/base-entity.ts +28 -0
- package/lib-prod/base-classes/base-file-upload.middleware.ts +92 -0
- package/lib-prod/base-classes/base-injector.ts +278 -0
- package/lib-prod/base-classes/base-middleware.ts +71 -0
- package/lib-prod/base-classes/base-migration.ts +26 -0
- package/lib-prod/base-classes/{base-provider.d.ts → base-provider.ts} +2 -2
- package/lib-prod/base-classes/base-repository.ts +942 -0
- package/lib-prod/base-classes/base-subscriber-for-entity.ts +196 -0
- package/lib-prod/base-classes/{base.js → base.ts} +15 -4
- package/lib-prod/{build-info._auto-generated_.d.ts → build-info._auto-generated_.ts} +9 -6
- package/lib-prod/config/controller-config.ts +58 -0
- package/lib-prod/config/controller-options.ts +19 -0
- package/lib-prod/config/method-config.ts +55 -0
- package/lib-prod/config/param-config.ts +16 -0
- package/lib-prod/constants.ts +63 -0
- package/lib-prod/context-db-migrations.ts +488 -0
- package/lib-prod/create-context.ts +345 -0
- package/lib-prod/decorators/classes/controller-decorator.ts +25 -0
- package/lib-prod/decorators/classes/entity-decorator.ts +57 -0
- package/lib-prod/decorators/classes/middleware-decorator.ts +29 -0
- package/lib-prod/decorators/classes/migration-decorator.ts +27 -0
- package/lib-prod/decorators/classes/provider-decorator.ts +28 -0
- package/lib-prod/decorators/classes/repository-decorator.ts +26 -0
- package/lib-prod/decorators/classes/subscriber-decorator.ts +28 -0
- package/lib-prod/decorators/decorator-abstract-opt.ts +4 -0
- package/lib-prod/decorators/http/http-decorators.ts +26 -0
- package/lib-prod/decorators/http/http-methods-decorators.ts +275 -0
- package/lib-prod/decorators/http/http-params-decorators.ts +105 -0
- package/lib-prod/dependency-injection/di-container.ts +39 -0
- package/lib-prod/endpoint-context-storage.ts +47 -0
- package/lib-prod/endpoint-context.ts +3100 -0
- package/lib-prod/entity-process.ts +283 -0
- package/lib-prod/env/env.angular-node-app.ts +66 -0
- package/lib-prod/env/env.docs-webapp.ts +66 -0
- package/lib-prod/env/env.electron-app.ts +66 -0
- package/lib-prod/env/env.mobile-app.ts +66 -0
- package/lib-prod/env/env.npm-lib-and-cli-tool.ts +66 -0
- package/lib-prod/env/env.vscode-plugin.ts +66 -0
- package/lib-prod/express-types.ts +4 -0
- package/lib-prod/formly/formly.models.ts +7 -0
- package/lib-prod/formly/fromly.ts +261 -0
- package/lib-prod/formly/type-from-entity.ts +80 -0
- package/lib-prod/get-response-value.ts +30 -0
- package/lib-prod/global-state/taon-global-state/{index.d.ts → index.ts} +2 -1
- package/lib-prod/global-state/taon-global-state/taon-global-state.abstract.context.ts +21 -0
- package/lib-prod/global-state/taon-global-state/taon-global-state.constants.ts +9 -0
- package/lib-prod/global-state/taon-global-state/taon-global-state.controller.ts +44 -0
- package/lib-prod/global-state/taon-global-state/taon-global-state.entity.ts +40 -0
- package/lib-prod/global-state/taon-global-state/taon-global-state.middleware.ts +12 -0
- package/lib-prod/global-state/taon-global-state/taon-global-state.models.ts +48 -0
- package/lib-prod/global-state/taon-global-state/taon-global-state.provider.ts +16 -0
- package/lib-prod/global-state/taon-global-state/taon-global-state.repository.ts +47 -0
- package/lib-prod/global-state/taon-global-state/taon-global-state.subscriber.ts +18 -0
- package/lib-prod/global-state/taon-global-state/taon-global-state.utils.ts +21 -0
- package/lib-prod/global-state/taon-transaction-registry/{index.d.ts → index.ts} +2 -1
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.abstract.context.ts +23 -0
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.constants.ts +7 -0
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.controller.ts +38 -0
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.entity.ts +54 -0
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.middleware.ts +12 -0
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.models.ts +6 -0
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.provider.ts +16 -0
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.repository.ts +29 -0
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.subscriber.ts +20 -0
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.utils.ts +9 -0
- package/lib-prod/helpers/class-helpers.ts +315 -0
- package/lib-prod/helpers/clone-obj.ts +24 -0
- package/lib-prod/helpers/taon-helpers.ts +181 -0
- package/lib-prod/{index._auto-generated_.js → index._auto-generated_.ts} +0 -1
- package/lib-prod/index.ts +323 -0
- package/lib-prod/{inject.js → inject.ts} +57 -40
- package/lib-prod/lib-info.md +8 -0
- package/lib-prod/migrations/index.ts +2 -0
- package/lib-prod/migrations/migrations-info.md +6 -0
- package/lib-prod/migrations/{migrations_index._auto-generated_.js → migrations_index._auto-generated_.ts} +2 -1
- package/lib-prod/models.ts +427 -0
- package/lib-prod/orm/columns.ts +121 -0
- package/lib-prod/orm/index.ts +62 -0
- package/lib-prod/package.json +1 -1
- package/lib-prod/realtime/realtime-client.ts +288 -0
- package/lib-prod/realtime/realtime-core.ts +134 -0
- package/lib-prod/realtime/realtime-server.ts +398 -0
- package/lib-prod/realtime/realtime-strategy/{index.d.ts → index.ts} +1 -1
- package/lib-prod/realtime/realtime-strategy/realtime-strategy-ipc.ts +344 -0
- package/lib-prod/realtime/realtime-strategy/realtime-strategy-mock.ts +349 -0
- package/lib-prod/realtime/realtime-strategy/realtime-strategy-socket-io.ts +30 -0
- package/lib-prod/realtime/realtime-strategy/realtime-strategy.ts +21 -0
- package/lib-prod/realtime/realtime-subs-manager.ts +127 -0
- package/lib-prod/realtime/{realtime.models.d.ts → realtime.models.ts} +13 -5
- package/lib-prod/symbols.ts +136 -0
- package/lib-prod/ui/index.ts +1 -0
- package/lib-prod/ui/taon-admin-mode-configuration/index.ts +1 -0
- package/lib-prod/validators.ts +103 -0
- package/package.json +1 -1
- package/websql/package.json +1 -1
- package/websql/types/taon-websql.d.ts +3 -3
- package/websql-prod/package.json +1 -1
- package/websql-prod/types/taon-websql.d.ts +3 -3
- package/lib-prod/base-classes/base-abstract-entity.d.ts +0 -7
- package/lib-prod/base-classes/base-abstract-entity.js +0 -42
- package/lib-prod/base-classes/base-abstract-entity.js.map +0 -1
- package/lib-prod/base-classes/base-angular-service.d.ts +0 -27
- package/lib-prod/base-classes/base-angular-service.js +0 -89
- package/lib-prod/base-classes/base-angular-service.js.map +0 -1
- package/lib-prod/base-classes/base-class.d.ts +0 -15
- package/lib-prod/base-classes/base-class.js +0 -40
- package/lib-prod/base-classes/base-class.js.map +0 -1
- package/lib-prod/base-classes/base-context.d.ts +0 -20
- package/lib-prod/base-classes/base-context.js +0 -23
- package/lib-prod/base-classes/base-context.js.map +0 -1
- package/lib-prod/base-classes/base-controller.d.ts +0 -84
- package/lib-prod/base-classes/base-controller.js +0 -173
- package/lib-prod/base-classes/base-controller.js.map +0 -1
- package/lib-prod/base-classes/base-crud-controller.d.ts +0 -28
- package/lib-prod/base-classes/base-crud-controller.js +0 -318
- package/lib-prod/base-classes/base-crud-controller.js.map +0 -1
- package/lib-prod/base-classes/base-custom-repository.d.ts +0 -3
- package/lib-prod/base-classes/base-custom-repository.js +0 -19
- package/lib-prod/base-classes/base-custom-repository.js.map +0 -1
- package/lib-prod/base-classes/base-electron-service.d.ts +0 -0
- package/lib-prod/base-classes/base-electron-service.js.map +0 -1
- package/lib-prod/base-classes/base-entity.d.ts +0 -16
- package/lib-prod/base-classes/base-entity.js +0 -32
- package/lib-prod/base-classes/base-entity.js.map +0 -1
- package/lib-prod/base-classes/base-file-upload.middleware.d.ts +0 -14
- package/lib-prod/base-classes/base-file-upload.middleware.js +0 -85
- package/lib-prod/base-classes/base-file-upload.middleware.js.map +0 -1
- package/lib-prod/base-classes/base-injector.d.ts +0 -67
- package/lib-prod/base-classes/base-injector.js +0 -198
- package/lib-prod/base-classes/base-injector.js.map +0 -1
- package/lib-prod/base-classes/base-middleware.d.ts +0 -38
- package/lib-prod/base-classes/base-middleware.js +0 -14
- package/lib-prod/base-classes/base-middleware.js.map +0 -1
- package/lib-prod/base-classes/base-migration.d.ts +0 -11
- package/lib-prod/base-classes/base-migration.js +0 -25
- package/lib-prod/base-classes/base-migration.js.map +0 -1
- package/lib-prod/base-classes/base-provider.js +0 -13
- package/lib-prod/base-classes/base-provider.js.map +0 -1
- package/lib-prod/base-classes/base-repository.d.ts +0 -272
- package/lib-prod/base-classes/base-repository.js +0 -634
- package/lib-prod/base-classes/base-repository.js.map +0 -1
- package/lib-prod/base-classes/base-subscriber-for-entity.d.ts +0 -81
- package/lib-prod/base-classes/base-subscriber-for-entity.js +0 -155
- package/lib-prod/base-classes/base-subscriber-for-entity.js.map +0 -1
- package/lib-prod/base-classes/base.d.ts +0 -1
- package/lib-prod/base-classes/base.js.map +0 -1
- package/lib-prod/build-info._auto-generated_.js +0 -30
- package/lib-prod/build-info._auto-generated_.js.map +0 -1
- package/lib-prod/config/controller-config.d.ts +0 -21
- package/lib-prod/config/controller-config.js +0 -34
- package/lib-prod/config/controller-config.js.map +0 -1
- package/lib-prod/config/controller-options.d.ts +0 -16
- package/lib-prod/config/controller-options.js +0 -8
- package/lib-prod/config/controller-options.js.map +0 -1
- package/lib-prod/config/method-config.d.ts +0 -39
- package/lib-prod/config/method-config.js +0 -12
- package/lib-prod/config/method-config.js.map +0 -1
- package/lib-prod/config/param-config.d.ts +0 -8
- package/lib-prod/config/param-config.js +0 -8
- package/lib-prod/config/param-config.js.map +0 -1
- package/lib-prod/constants.d.ts +0 -9
- package/lib-prod/constants.js +0 -32
- package/lib-prod/constants.js.map +0 -1
- package/lib-prod/context-db-migrations.d.ts +0 -17
- package/lib-prod/context-db-migrations.js +0 -349
- package/lib-prod/context-db-migrations.js.map +0 -1
- package/lib-prod/create-context.d.ts +0 -78
- package/lib-prod/create-context.js +0 -223
- package/lib-prod/create-context.js.map +0 -1
- package/lib-prod/decorators/classes/controller-decorator.d.ts +0 -5
- package/lib-prod/decorators/classes/controller-decorator.js +0 -21
- package/lib-prod/decorators/classes/controller-decorator.js.map +0 -1
- package/lib-prod/decorators/classes/entity-decorator.d.ts +0 -19
- package/lib-prod/decorators/classes/entity-decorator.js +0 -43
- package/lib-prod/decorators/classes/entity-decorator.js.map +0 -1
- package/lib-prod/decorators/classes/middleware-decorator.d.ts +0 -8
- package/lib-prod/decorators/classes/middleware-decorator.js +0 -22
- package/lib-prod/decorators/classes/middleware-decorator.js.map +0 -1
- package/lib-prod/decorators/classes/migration-decorator.d.ts +0 -7
- package/lib-prod/decorators/classes/migration-decorator.js +0 -21
- package/lib-prod/decorators/classes/migration-decorator.js.map +0 -1
- package/lib-prod/decorators/classes/provider-decorator.d.ts +0 -7
- package/lib-prod/decorators/classes/provider-decorator.js +0 -21
- package/lib-prod/decorators/classes/provider-decorator.js.map +0 -1
- package/lib-prod/decorators/classes/repository-decorator.d.ts +0 -7
- package/lib-prod/decorators/classes/repository-decorator.js +0 -21
- package/lib-prod/decorators/classes/repository-decorator.js.map +0 -1
- package/lib-prod/decorators/classes/subscriber-decorator.d.ts +0 -8
- package/lib-prod/decorators/classes/subscriber-decorator.js +0 -22
- package/lib-prod/decorators/classes/subscriber-decorator.js.map +0 -1
- package/lib-prod/decorators/decorator-abstract-opt.d.ts +0 -3
- package/lib-prod/decorators/decorator-abstract-opt.js +0 -7
- package/lib-prod/decorators/decorator-abstract-opt.js.map +0 -1
- package/lib-prod/decorators/http/http-decorators.d.ts +0 -3
- package/lib-prod/decorators/http/http-decorators.js +0 -24
- package/lib-prod/decorators/http/http-decorators.js.map +0 -1
- package/lib-prod/decorators/http/http-methods-decorators.d.ts +0 -70
- package/lib-prod/decorators/http/http-methods-decorators.js +0 -112
- package/lib-prod/decorators/http/http-methods-decorators.js.map +0 -1
- package/lib-prod/decorators/http/http-params-decorators.d.ts +0 -8
- package/lib-prod/decorators/http/http-params-decorators.js +0 -50
- package/lib-prod/decorators/http/http-params-decorators.js.map +0 -1
- package/lib-prod/dependency-injection/di-container.d.ts +0 -5
- package/lib-prod/dependency-injection/di-container.js +0 -35
- package/lib-prod/dependency-injection/di-container.js.map +0 -1
- package/lib-prod/endpoint-context-storage.d.ts +0 -11
- package/lib-prod/endpoint-context-storage.js +0 -38
- package/lib-prod/endpoint-context-storage.js.map +0 -1
- package/lib-prod/endpoint-context.d.ts +0 -197
- package/lib-prod/endpoint-context.js +0 -2416
- package/lib-prod/endpoint-context.js.map +0 -1
- package/lib-prod/entity-process.d.ts +0 -39
- package/lib-prod/entity-process.js +0 -242
- package/lib-prod/entity-process.js.map +0 -1
- package/lib-prod/env/env.angular-node-app.d.ts +0 -64
- package/lib-prod/env/env.angular-node-app.js +0 -71
- package/lib-prod/env/env.angular-node-app.js.map +0 -1
- package/lib-prod/env/env.docs-webapp.d.ts +0 -64
- package/lib-prod/env/env.docs-webapp.js +0 -71
- package/lib-prod/env/env.docs-webapp.js.map +0 -1
- package/lib-prod/env/env.electron-app.d.ts +0 -64
- package/lib-prod/env/env.electron-app.js +0 -71
- package/lib-prod/env/env.electron-app.js.map +0 -1
- package/lib-prod/env/env.mobile-app.d.ts +0 -64
- package/lib-prod/env/env.mobile-app.js +0 -71
- package/lib-prod/env/env.mobile-app.js.map +0 -1
- package/lib-prod/env/env.npm-lib-and-cli-tool.d.ts +0 -64
- package/lib-prod/env/env.npm-lib-and-cli-tool.js +0 -71
- package/lib-prod/env/env.npm-lib-and-cli-tool.js.map +0 -1
- package/lib-prod/env/env.vscode-plugin.d.ts +0 -64
- package/lib-prod/env/env.vscode-plugin.js +0 -71
- package/lib-prod/env/env.vscode-plugin.js.map +0 -1
- package/lib-prod/env/index.js +0 -23
- package/lib-prod/env/index.js.map +0 -1
- package/lib-prod/express-types.d.ts +0 -1
- package/lib-prod/express-types.js +0 -3
- package/lib-prod/express-types.js.map +0 -1
- package/lib-prod/formly/formly.models.d.ts +0 -1
- package/lib-prod/formly/formly.models.js +0 -3
- package/lib-prod/formly/formly.models.js.map +0 -1
- package/lib-prod/formly/fromly.d.ts +0 -16
- package/lib-prod/formly/fromly.js +0 -209
- package/lib-prod/formly/fromly.js.map +0 -1
- package/lib-prod/formly/type-from-entity.d.ts +0 -20
- package/lib-prod/formly/type-from-entity.js +0 -60
- package/lib-prod/formly/type-from-entity.js.map +0 -1
- package/lib-prod/get-response-value.d.ts +0 -6
- package/lib-prod/get-response-value.js +0 -27
- package/lib-prod/get-response-value.js.map +0 -1
- package/lib-prod/global-state/taon-global-state/index.js +0 -23
- package/lib-prod/global-state/taon-global-state/index.js.map +0 -1
- package/lib-prod/global-state/taon-global-state/taon-global-state.abstract.context.d.ts +0 -19
- package/lib-prod/global-state/taon-global-state/taon-global-state.abstract.context.js +0 -23
- package/lib-prod/global-state/taon-global-state/taon-global-state.abstract.context.js.map +0 -1
- package/lib-prod/global-state/taon-global-state/taon-global-state.constants.d.ts +0 -2
- package/lib-prod/global-state/taon-global-state/taon-global-state.constants.js +0 -11
- package/lib-prod/global-state/taon-global-state/taon-global-state.constants.js.map +0 -1
- package/lib-prod/global-state/taon-global-state/taon-global-state.controller.d.ts +0 -11
- package/lib-prod/global-state/taon-global-state/taon-global-state.controller.js +0 -61
- package/lib-prod/global-state/taon-global-state/taon-global-state.controller.js.map +0 -1
- package/lib-prod/global-state/taon-global-state/taon-global-state.entity.d.ts +0 -7
- package/lib-prod/global-state/taon-global-state/taon-global-state.entity.js +0 -64
- package/lib-prod/global-state/taon-global-state/taon-global-state.entity.js.map +0 -1
- package/lib-prod/global-state/taon-global-state/taon-global-state.middleware.d.ts +0 -3
- package/lib-prod/global-state/taon-global-state/taon-global-state.middleware.js +0 -22
- package/lib-prod/global-state/taon-global-state/taon-global-state.middleware.js.map +0 -1
- package/lib-prod/global-state/taon-global-state/taon-global-state.models.d.ts +0 -28
- package/lib-prod/global-state/taon-global-state/taon-global-state.models.js +0 -48
- package/lib-prod/global-state/taon-global-state/taon-global-state.models.js.map +0 -1
- package/lib-prod/global-state/taon-global-state/taon-global-state.provider.d.ts +0 -3
- package/lib-prod/global-state/taon-global-state/taon-global-state.provider.js +0 -22
- package/lib-prod/global-state/taon-global-state/taon-global-state.provider.js.map +0 -1
- package/lib-prod/global-state/taon-global-state/taon-global-state.repository.d.ts +0 -9
- package/lib-prod/global-state/taon-global-state/taon-global-state.repository.js +0 -53
- package/lib-prod/global-state/taon-global-state/taon-global-state.repository.js.map +0 -1
- package/lib-prod/global-state/taon-global-state/taon-global-state.subscriber.d.ts +0 -7
- package/lib-prod/global-state/taon-global-state/taon-global-state.subscriber.js +0 -29
- package/lib-prod/global-state/taon-global-state/taon-global-state.subscriber.js.map +0 -1
- package/lib-prod/global-state/taon-global-state/taon-global-state.utils.d.ts +0 -2
- package/lib-prod/global-state/taon-global-state/taon-global-state.utils.js +0 -16
- package/lib-prod/global-state/taon-global-state/taon-global-state.utils.js.map +0 -1
- package/lib-prod/global-state/taon-transaction-registry/index.js +0 -28
- package/lib-prod/global-state/taon-transaction-registry/index.js.map +0 -1
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.abstract.context.d.ts +0 -19
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.abstract.context.js +0 -25
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.abstract.context.js.map +0 -1
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.constants.d.ts +0 -2
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.constants.js +0 -9
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.constants.js.map +0 -1
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.controller.d.ts +0 -9
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.controller.js +0 -51
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.controller.js.map +0 -1
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.entity.d.ts +0 -12
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.entity.js +0 -77
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.entity.js.map +0 -1
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.middleware.d.ts +0 -3
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.middleware.js +0 -22
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.middleware.js.map +0 -1
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.models.d.ts +0 -6
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.models.js +0 -11
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.models.js.map +0 -1
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.provider.d.ts +0 -3
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.provider.js +0 -22
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.provider.js.map +0 -1
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.repository.d.ts +0 -9
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.repository.js +0 -38
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.repository.js.map +0 -1
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.subscriber.d.ts +0 -7
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.subscriber.js +0 -29
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.subscriber.js.map +0 -1
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.utils.d.ts +0 -2
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.utils.js +0 -9
- package/lib-prod/global-state/taon-transaction-registry/taon-transaction-registry.utils.js.map +0 -1
- package/lib-prod/helpers/class-helpers.d.ts +0 -22
- package/lib-prod/helpers/class-helpers.js +0 -246
- package/lib-prod/helpers/class-helpers.js.map +0 -1
- package/lib-prod/helpers/clone-obj.d.ts +0 -1
- package/lib-prod/helpers/clone-obj.js +0 -22
- package/lib-prod/helpers/clone-obj.js.map +0 -1
- package/lib-prod/helpers/taon-helpers.d.ts +0 -16
- package/lib-prod/helpers/taon-helpers.js +0 -162
- package/lib-prod/helpers/taon-helpers.js.map +0 -1
- package/lib-prod/index._auto-generated_.d.ts +0 -0
- package/lib-prod/index._auto-generated_.js.map +0 -1
- package/lib-prod/index.d.ts +0 -230
- package/lib-prod/index.js +0 -273
- package/lib-prod/index.js.map +0 -1
- package/lib-prod/inject.d.ts +0 -4
- package/lib-prod/inject.js.map +0 -1
- package/lib-prod/migrations/index.d.ts +0 -1
- package/lib-prod/migrations/index.js +0 -19
- package/lib-prod/migrations/index.js.map +0 -1
- package/lib-prod/migrations/migrations_index._auto-generated_.d.ts +0 -0
- package/lib-prod/migrations/migrations_index._auto-generated_.js.map +0 -1
- package/lib-prod/models.d.ts +0 -255
- package/lib-prod/models.js +0 -117
- package/lib-prod/models.js.map +0 -1
- package/lib-prod/orm/columns.d.ts +0 -32
- package/lib-prod/orm/columns.js +0 -112
- package/lib-prod/orm/columns.js.map +0 -1
- package/lib-prod/orm/index.d.ts +0 -1
- package/lib-prod/orm/index.js +0 -73
- package/lib-prod/orm/index.js.map +0 -1
- package/lib-prod/realtime/realtime-client.d.ts +0 -41
- package/lib-prod/realtime/realtime-client.js +0 -204
- package/lib-prod/realtime/realtime-client.js.map +0 -1
- package/lib-prod/realtime/realtime-core.d.ts +0 -40
- package/lib-prod/realtime/realtime-core.js +0 -106
- package/lib-prod/realtime/realtime-core.js.map +0 -1
- package/lib-prod/realtime/realtime-server.d.ts +0 -43
- package/lib-prod/realtime/realtime-server.js +0 -243
- package/lib-prod/realtime/realtime-server.js.map +0 -1
- package/lib-prod/realtime/realtime-strategy/index.js +0 -21
- package/lib-prod/realtime/realtime-strategy/index.js.map +0 -1
- package/lib-prod/realtime/realtime-strategy/realtime-strategy-ipc.d.ts +0 -80
- package/lib-prod/realtime/realtime-strategy/realtime-strategy-ipc.js +0 -297
- package/lib-prod/realtime/realtime-strategy/realtime-strategy-ipc.js.map +0 -1
- package/lib-prod/realtime/realtime-strategy/realtime-strategy-mock.d.ts +0 -14
- package/lib-prod/realtime/realtime-strategy/realtime-strategy-mock.js +0 -303
- package/lib-prod/realtime/realtime-strategy/realtime-strategy-mock.js.map +0 -1
- package/lib-prod/realtime/realtime-strategy/realtime-strategy-socket-io.d.ts +0 -16
- package/lib-prod/realtime/realtime-strategy/realtime-strategy-socket-io.js +0 -33
- package/lib-prod/realtime/realtime-strategy/realtime-strategy-socket-io.js.map +0 -1
- package/lib-prod/realtime/realtime-strategy/realtime-strategy.d.ts +0 -11
- package/lib-prod/realtime/realtime-strategy/realtime-strategy.js +0 -17
- package/lib-prod/realtime/realtime-strategy/realtime-strategy.js.map +0 -1
- package/lib-prod/realtime/realtime-subs-manager.d.ts +0 -14
- package/lib-prod/realtime/realtime-subs-manager.js +0 -94
- package/lib-prod/realtime/realtime-subs-manager.js.map +0 -1
- package/lib-prod/realtime/realtime.models.js +0 -4
- package/lib-prod/realtime/realtime.models.js.map +0 -1
- package/lib-prod/symbols.d.ts +0 -63
- package/lib-prod/symbols.js +0 -109
- package/lib-prod/symbols.js.map +0 -1
- package/lib-prod/ui/index.d.ts +0 -1
- package/lib-prod/ui/index.js +0 -5
- package/lib-prod/ui/index.js.map +0 -1
- package/lib-prod/ui/taon-admin-mode-configuration/index.d.ts +0 -1
- package/lib-prod/ui/taon-admin-mode-configuration/index.js +0 -5
- package/lib-prod/ui/taon-admin-mode-configuration/index.js.map +0 -1
- package/lib-prod/validators.d.ts +0 -5
- package/lib-prod/validators.js +0 -88
- package/lib-prod/validators.js.map +0 -1
- /package/lib-prod/env/{index.d.ts → index.ts} +0 -0
package/lib-prod/models.js
DELETED
|
@@ -1,117 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Models__NS__DatabaseConfig = exports.Models__NS__DatabaseConfigTypeOrm = exports.Models__NS__ClassTypeKey = exports.Models__NS__ClassType = exports.Models__NS__DatabasesFolder = exports.TaonTempRoutesFolder = exports.TaonTempDatabasesFolder = exports.BaseTaonClassesNames = exports.TaonRestResponseWrapper = void 0;
|
|
4
|
-
const lib_prod_1 = require("ng2-rest/lib-prod");
|
|
5
|
-
const lib_prod_2 = require("tnp-core/lib-prod");
|
|
6
|
-
// ! TODO make it as a nice way to wrap normal request
|
|
7
|
-
class TaonRestResponseWrapper extends lib_prod_1.RestResponseWrapper {
|
|
8
|
-
}
|
|
9
|
-
exports.TaonRestResponseWrapper = TaonRestResponseWrapper;
|
|
10
|
-
exports.BaseTaonClassesNames = [
|
|
11
|
-
'BaseCrudController',
|
|
12
|
-
'BaseController',
|
|
13
|
-
'BaseAbstractEntity',
|
|
14
|
-
'BaseEntity',
|
|
15
|
-
'BaseContext',
|
|
16
|
-
'BaseCustomRepository',
|
|
17
|
-
'BaseFileUploadMiddleware',
|
|
18
|
-
'BaseMiddleware',
|
|
19
|
-
'BaseClass',
|
|
20
|
-
'BaseInjector',
|
|
21
|
-
'BaseMigration',
|
|
22
|
-
'BaseProvider',
|
|
23
|
-
'BaseRepository',
|
|
24
|
-
'BaseSubscriberForEntity',
|
|
25
|
-
'BaseCliWorkerController',
|
|
26
|
-
'PortsController',
|
|
27
|
-
'PortsContext',
|
|
28
|
-
];
|
|
29
|
-
exports.TaonTempDatabasesFolder = 'databases';
|
|
30
|
-
exports.TaonTempRoutesFolder = 'routes';
|
|
31
|
-
//namespace Models
|
|
32
|
-
exports.Models__NS__DatabasesFolder = exports.TaonTempDatabasesFolder;
|
|
33
|
-
//#region models / class types
|
|
34
|
-
var Models__NS__ClassType;
|
|
35
|
-
(function (Models__NS__ClassType) {
|
|
36
|
-
Models__NS__ClassType["ENTITY"] = "ENTITY";
|
|
37
|
-
Models__NS__ClassType["CONTROLLER"] = "CONTROLLER";
|
|
38
|
-
Models__NS__ClassType["REPOSITORY"] = "REPOSITORY";
|
|
39
|
-
Models__NS__ClassType["PROVIDER"] = "PROVIDER";
|
|
40
|
-
Models__NS__ClassType["SUBSCRIBER"] = "SUBSCRIBER";
|
|
41
|
-
Models__NS__ClassType["MIGRATION"] = "MIGRATION";
|
|
42
|
-
Models__NS__ClassType["MIDDLEWARE"] = "MIDDLEWARE";
|
|
43
|
-
})(Models__NS__ClassType || (exports.Models__NS__ClassType = Models__NS__ClassType = {}));
|
|
44
|
-
exports.Models__NS__ClassTypeKey = {
|
|
45
|
-
[Models__NS__ClassType.ENTITY]: 'entities',
|
|
46
|
-
[Models__NS__ClassType.CONTROLLER]: 'controllers',
|
|
47
|
-
[Models__NS__ClassType.REPOSITORY]: 'repositories',
|
|
48
|
-
[Models__NS__ClassType.PROVIDER]: 'providers',
|
|
49
|
-
[Models__NS__ClassType.SUBSCRIBER]: 'subscribers',
|
|
50
|
-
[Models__NS__ClassType.MIGRATION]: 'migrations',
|
|
51
|
-
[Models__NS__ClassType.MIDDLEWARE]: 'middlewares',
|
|
52
|
-
};
|
|
53
|
-
//#endregion
|
|
54
|
-
//#region models / database connection options
|
|
55
|
-
class Models__NS__DatabaseConfigTypeOrm {
|
|
56
|
-
/**
|
|
57
|
-
* database name
|
|
58
|
-
*/
|
|
59
|
-
database;
|
|
60
|
-
/**
|
|
61
|
-
* only for file base db: sqlite, sqljs
|
|
62
|
-
*/
|
|
63
|
-
location;
|
|
64
|
-
synchronize;
|
|
65
|
-
dropSchema;
|
|
66
|
-
type;
|
|
67
|
-
/**
|
|
68
|
-
* Persists db on disk/local-storage if serverless db
|
|
69
|
-
*/
|
|
70
|
-
autoSave;
|
|
71
|
-
/**
|
|
72
|
-
* for websql db mode
|
|
73
|
-
* true by default
|
|
74
|
-
*/
|
|
75
|
-
useLocalForage;
|
|
76
|
-
logging;
|
|
77
|
-
databasePort;
|
|
78
|
-
databaseHost;
|
|
79
|
-
databaseUsername;
|
|
80
|
-
databasePassword;
|
|
81
|
-
}
|
|
82
|
-
exports.Models__NS__DatabaseConfigTypeOrm = Models__NS__DatabaseConfigTypeOrm;
|
|
83
|
-
//#endregion
|
|
84
|
-
//#region models / database config
|
|
85
|
-
class Models__NS__DatabaseConfig extends Models__NS__DatabaseConfigTypeOrm {
|
|
86
|
-
/**
|
|
87
|
-
* Default value 'DROP_ALL'.
|
|
88
|
-
*
|
|
89
|
-
* Tell framework what is happening with db
|
|
90
|
-
* when context is starting.
|
|
91
|
-
*/
|
|
92
|
-
recreateMode;
|
|
93
|
-
static from(databasePartialConfig) {
|
|
94
|
-
return (0, lib_prod_2.___NS__merge)(new Models__NS__DatabaseConfig(), databasePartialConfig);
|
|
95
|
-
}
|
|
96
|
-
get databaseConfigTypeORM() {
|
|
97
|
-
//#region @websqlFunc
|
|
98
|
-
const result = (0, lib_prod_2.___NS__cloneDeep)(this);
|
|
99
|
-
if (result.recreateMode) {
|
|
100
|
-
if (result.recreateMode === 'DROP_DB+MIGRATIONS') {
|
|
101
|
-
result.synchronize = true;
|
|
102
|
-
result.dropSchema = true;
|
|
103
|
-
}
|
|
104
|
-
else if (result.recreateMode === 'PRESERVE_DATA+MIGRATIONS') {
|
|
105
|
-
result.synchronize = false;
|
|
106
|
-
result.dropSchema = false;
|
|
107
|
-
}
|
|
108
|
-
}
|
|
109
|
-
delete result.recreateMode;
|
|
110
|
-
return result;
|
|
111
|
-
//#endregion
|
|
112
|
-
}
|
|
113
|
-
}
|
|
114
|
-
exports.Models__NS__DatabaseConfig = Models__NS__DatabaseConfig;
|
|
115
|
-
//#endregion
|
|
116
|
-
//end of namespace Models
|
|
117
|
-
//# sourceMappingURL=models.js.map
|
package/lib-prod/models.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"models.js","sourceRoot":"","sources":[""],"names":[],"mappings":";;;AACA,gDAA2pD;AAC3pD,gDAAo8J;AAcp8J,sDAAsD;AACtD,MAAa,uBAAwB,SAAQ,8BAAmB;CAAG;AAAnE,0DAAmE;AAEtD,QAAA,oBAAoB,GAAG;IAClC,oBAAoB;IACpB,gBAAgB;IAChB,oBAAoB;IACpB,YAAY;IACZ,aAAa;IACb,sBAAsB;IACtB,0BAA0B;IAC1B,gBAAgB;IAChB,WAAW;IACX,cAAc;IACd,eAAe;IACf,cAAc;IACd,gBAAgB;IAChB,yBAAyB;IACzB,yBAAyB;IACzB,iBAAiB;IACjB,cAAc;CACN,CAAC;AAEE,QAAA,uBAAuB,GAAG,WAAW,CAAC;AAEtC,QAAA,oBAAoB,GAAG,QAAQ,CAAC;AAE7C,kBAAkB;AAEH,QAAA,2BAA2B,GAAG,+BAAuB,CAAC;AAQnE,8BAA8B;AAC9B,IAAY,qBAQX;AARD,WAAY,qBAAqB;IAC/B,0CAAiB,CAAA;IACjB,kDAAyB,CAAA;IACzB,kDAAyB,CAAA;IACzB,8CAAqB,CAAA;IACrB,kDAAyB,CAAA;IACzB,gDAAuB,CAAA;IACvB,kDAAyB,CAAA;AAC3B,CAAC,EARW,qBAAqB,qCAArB,qBAAqB,QAQhC;AAEY,QAAA,wBAAwB,GAAG;IACtC,CAAC,qBAAqB,CAAC,MAAM,CAAC,EAA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AAC,YAAY,KAAK,0BAA0B,EAAE,CAAC;gBAC9D,MAAM,CAAC,WAAW,GAAG,KAAK,CAAC;gBAC3B,MAAM,CAAC,UAAU,GAAG,KAAK,CAAC;YAC5B,CAAC;QACH,CAAC;QACD,OAAO,MAAM,CAAC,YAAY,CAAC;QAE3B,OAAO,MAAa,CAAC;QACrB,YAAY;IACd,CAAC;CACF;AArCD,gEAqCC;AA6OD,YAAY;AAEd,yBAAyB"}
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
export { Repository, Connection, Generated, AfterInsert, AfterLoad, AfterRecover, AfterRemove, AfterSoftRemove, AfterUpdate, BeforeInsert, BeforeRecover, BeforeRemove, BeforeSoftRemove, BeforeUpdate, TreeChildren, TreeParent, PrimaryGeneratedColumn, PrimaryColumn, Index, CreateDateColumn, UpdateDateColumn, DeleteDateColumn, Column, VersionColumn, VirtualColumn, JoinTable, JoinColumn, OneToMany, OneToOne, ManyToMany, ManyToOne, } from 'taon-typeorm/lib-prod';
|
|
2
|
-
export { Column as CustomColumn } from 'taon-typeorm/lib-prod';
|
|
3
|
-
export { Generated as GeneratedColumn } from 'taon-typeorm/lib-prod';
|
|
4
|
-
/**
|
|
5
|
-
* 100 default characters varchar
|
|
6
|
-
*/
|
|
7
|
-
export declare const StringColumn: <T = string>(defaultValue?: T, length?: number) => PropertyDecorator;
|
|
8
|
-
/**
|
|
9
|
-
* 100 characters varchar
|
|
10
|
-
*/
|
|
11
|
-
export declare const String100Column: <T = string>(defaultValue?: T) => PropertyDecorator;
|
|
12
|
-
/**
|
|
13
|
-
* 20 characters varchar
|
|
14
|
-
*/
|
|
15
|
-
export declare const String20Column: <T = string>(defaultValue?: T) => PropertyDecorator;
|
|
16
|
-
/**
|
|
17
|
-
* 45 characters varchar
|
|
18
|
-
*/
|
|
19
|
-
export declare const String45Column: <T = string>(defaultValue?: T) => PropertyDecorator;
|
|
20
|
-
/**
|
|
21
|
-
* 500 characters varchar
|
|
22
|
-
*/
|
|
23
|
-
export declare const String500Column: <T = string>(defaultValue?: T) => PropertyDecorator;
|
|
24
|
-
/**
|
|
25
|
-
* 200 characters varchar
|
|
26
|
-
*/
|
|
27
|
-
export declare const String200Column: <T = string>(defaultValue?: T) => PropertyDecorator;
|
|
28
|
-
export declare const NumberColumn: () => PropertyDecorator;
|
|
29
|
-
export declare const DecimalNumberColumn: () => PropertyDecorator;
|
|
30
|
-
export declare const SimpleJsonColumn: () => PropertyDecorator;
|
|
31
|
-
export declare const BooleanColumn: (defaultValue: boolean | null) => PropertyDecorator;
|
|
32
|
-
export declare const DateTimeColumn: (defaultValue?: boolean | null) => PropertyDecorator;
|
package/lib-prod/orm/columns.js
DELETED
|
@@ -1,112 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.DateTimeColumn = exports.BooleanColumn = exports.SimpleJsonColumn = exports.DecimalNumberColumn = exports.NumberColumn = exports.String200Column = exports.String500Column = exports.String45Column = exports.String20Column = exports.String100Column = exports.StringColumn = exports.GeneratedColumn = exports.CustomColumn = exports.ManyToOne = exports.ManyToMany = exports.OneToOne = exports.OneToMany = exports.JoinColumn = exports.JoinTable = exports.VirtualColumn = exports.VersionColumn = exports.Column = exports.DeleteDateColumn = exports.UpdateDateColumn = exports.CreateDateColumn = exports.Index = exports.PrimaryColumn = exports.PrimaryGeneratedColumn = exports.TreeParent = exports.TreeChildren = exports.BeforeUpdate = exports.BeforeSoftRemove = exports.BeforeRemove = exports.BeforeRecover = exports.BeforeInsert = exports.AfterUpdate = exports.AfterSoftRemove = exports.AfterRemove = exports.AfterRecover = exports.AfterLoad = exports.AfterInsert = exports.Generated = exports.Connection = exports.Repository = void 0;
|
|
4
|
-
const lib_prod_1 = require("taon-typeorm/lib-prod");
|
|
5
|
-
const lib_prod_2 = require("tnp-core/lib-prod");
|
|
6
|
-
var lib_prod_3 = require("taon-typeorm/lib-prod");
|
|
7
|
-
Object.defineProperty(exports, "Repository", { enumerable: true, get: function () { return lib_prod_3.Repository; } });
|
|
8
|
-
Object.defineProperty(exports, "Connection", { enumerable: true, get: function () { return lib_prod_3.Connection; } });
|
|
9
|
-
Object.defineProperty(exports, "Generated", { enumerable: true, get: function () { return lib_prod_3.Generated; } });
|
|
10
|
-
Object.defineProperty(exports, "AfterInsert", { enumerable: true, get: function () { return lib_prod_3.AfterInsert; } });
|
|
11
|
-
Object.defineProperty(exports, "AfterLoad", { enumerable: true, get: function () { return lib_prod_3.AfterLoad; } });
|
|
12
|
-
Object.defineProperty(exports, "AfterRecover", { enumerable: true, get: function () { return lib_prod_3.AfterRecover; } });
|
|
13
|
-
Object.defineProperty(exports, "AfterRemove", { enumerable: true, get: function () { return lib_prod_3.AfterRemove; } });
|
|
14
|
-
Object.defineProperty(exports, "AfterSoftRemove", { enumerable: true, get: function () { return lib_prod_3.AfterSoftRemove; } });
|
|
15
|
-
Object.defineProperty(exports, "AfterUpdate", { enumerable: true, get: function () { return lib_prod_3.AfterUpdate; } });
|
|
16
|
-
Object.defineProperty(exports, "BeforeInsert", { enumerable: true, get: function () { return lib_prod_3.BeforeInsert; } });
|
|
17
|
-
Object.defineProperty(exports, "BeforeRecover", { enumerable: true, get: function () { return lib_prod_3.BeforeRecover; } });
|
|
18
|
-
Object.defineProperty(exports, "BeforeRemove", { enumerable: true, get: function () { return lib_prod_3.BeforeRemove; } });
|
|
19
|
-
Object.defineProperty(exports, "BeforeSoftRemove", { enumerable: true, get: function () { return lib_prod_3.BeforeSoftRemove; } });
|
|
20
|
-
Object.defineProperty(exports, "BeforeUpdate", { enumerable: true, get: function () { return lib_prod_3.BeforeUpdate; } });
|
|
21
|
-
Object.defineProperty(exports, "TreeChildren", { enumerable: true, get: function () { return lib_prod_3.TreeChildren; } });
|
|
22
|
-
Object.defineProperty(exports, "TreeParent", { enumerable: true, get: function () { return lib_prod_3.TreeParent; } });
|
|
23
|
-
Object.defineProperty(exports, "PrimaryGeneratedColumn", { enumerable: true, get: function () { return lib_prod_3.PrimaryGeneratedColumn; } });
|
|
24
|
-
Object.defineProperty(exports, "PrimaryColumn", { enumerable: true, get: function () { return lib_prod_3.PrimaryColumn; } });
|
|
25
|
-
Object.defineProperty(exports, "Index", { enumerable: true, get: function () { return lib_prod_3.Index; } });
|
|
26
|
-
Object.defineProperty(exports, "CreateDateColumn", { enumerable: true, get: function () { return lib_prod_3.CreateDateColumn; } });
|
|
27
|
-
Object.defineProperty(exports, "UpdateDateColumn", { enumerable: true, get: function () { return lib_prod_3.UpdateDateColumn; } });
|
|
28
|
-
Object.defineProperty(exports, "DeleteDateColumn", { enumerable: true, get: function () { return lib_prod_3.DeleteDateColumn; } });
|
|
29
|
-
Object.defineProperty(exports, "Column", { enumerable: true, get: function () { return lib_prod_3.Column; } });
|
|
30
|
-
Object.defineProperty(exports, "VersionColumn", { enumerable: true, get: function () { return lib_prod_3.VersionColumn; } });
|
|
31
|
-
Object.defineProperty(exports, "VirtualColumn", { enumerable: true, get: function () { return lib_prod_3.VirtualColumn; } });
|
|
32
|
-
Object.defineProperty(exports, "JoinTable", { enumerable: true, get: function () { return lib_prod_3.JoinTable; } });
|
|
33
|
-
Object.defineProperty(exports, "JoinColumn", { enumerable: true, get: function () { return lib_prod_3.JoinColumn; } });
|
|
34
|
-
Object.defineProperty(exports, "OneToMany", { enumerable: true, get: function () { return lib_prod_3.OneToMany; } });
|
|
35
|
-
Object.defineProperty(exports, "OneToOne", { enumerable: true, get: function () { return lib_prod_3.OneToOne; } });
|
|
36
|
-
Object.defineProperty(exports, "ManyToMany", { enumerable: true, get: function () { return lib_prod_3.ManyToMany; } });
|
|
37
|
-
Object.defineProperty(exports, "ManyToOne", { enumerable: true, get: function () { return lib_prod_3.ManyToOne; } });
|
|
38
|
-
var lib_prod_4 = require("taon-typeorm/lib-prod");
|
|
39
|
-
Object.defineProperty(exports, "CustomColumn", { enumerable: true, get: function () { return lib_prod_4.Column; } });
|
|
40
|
-
var lib_prod_5 = require("taon-typeorm/lib-prod");
|
|
41
|
-
Object.defineProperty(exports, "GeneratedColumn", { enumerable: true, get: function () { return lib_prod_5.Generated; } });
|
|
42
|
-
/**
|
|
43
|
-
* 100 default characters varchar
|
|
44
|
-
*/
|
|
45
|
-
const StringColumn = (defaultValue = null, length = 100) => (0, lib_prod_1.Column)({
|
|
46
|
-
type: 'varchar',
|
|
47
|
-
length,
|
|
48
|
-
nullable: (0, lib_prod_2.___NS__isNil)(defaultValue),
|
|
49
|
-
default: defaultValue,
|
|
50
|
-
});
|
|
51
|
-
exports.StringColumn = StringColumn;
|
|
52
|
-
/**
|
|
53
|
-
* 100 characters varchar
|
|
54
|
-
*/
|
|
55
|
-
const String100Column = (defaultValue = null) => (0, lib_prod_1.Column)({
|
|
56
|
-
type: 'varchar',
|
|
57
|
-
length: 100,
|
|
58
|
-
nullable: (0, lib_prod_2.___NS__isNil)(defaultValue),
|
|
59
|
-
default: defaultValue,
|
|
60
|
-
});
|
|
61
|
-
exports.String100Column = String100Column;
|
|
62
|
-
/**
|
|
63
|
-
* 20 characters varchar
|
|
64
|
-
*/
|
|
65
|
-
const String20Column = (defaultValue = null) => (0, lib_prod_1.Column)({
|
|
66
|
-
type: 'varchar',
|
|
67
|
-
length: 20,
|
|
68
|
-
nullable: (0, lib_prod_2.___NS__isNil)(defaultValue),
|
|
69
|
-
default: defaultValue,
|
|
70
|
-
});
|
|
71
|
-
exports.String20Column = String20Column;
|
|
72
|
-
/**
|
|
73
|
-
* 45 characters varchar
|
|
74
|
-
*/
|
|
75
|
-
const String45Column = (defaultValue = null) => (0, lib_prod_1.Column)({
|
|
76
|
-
type: 'varchar',
|
|
77
|
-
length: 45,
|
|
78
|
-
nullable: (0, lib_prod_2.___NS__isNil)(defaultValue),
|
|
79
|
-
default: defaultValue,
|
|
80
|
-
});
|
|
81
|
-
exports.String45Column = String45Column;
|
|
82
|
-
/**
|
|
83
|
-
* 500 characters varchar
|
|
84
|
-
*/
|
|
85
|
-
const String500Column = (defaultValue = null) => (0, lib_prod_1.Column)({
|
|
86
|
-
type: 'varchar',
|
|
87
|
-
length: 500,
|
|
88
|
-
nullable: (0, lib_prod_2.___NS__isNil)(defaultValue),
|
|
89
|
-
default: defaultValue,
|
|
90
|
-
});
|
|
91
|
-
exports.String500Column = String500Column;
|
|
92
|
-
/**
|
|
93
|
-
* 200 characters varchar
|
|
94
|
-
*/
|
|
95
|
-
const String200Column = (defaultValue = null) => (0, lib_prod_1.Column)({
|
|
96
|
-
type: 'varchar',
|
|
97
|
-
length: 200,
|
|
98
|
-
nullable: (0, lib_prod_2.___NS__isNil)(defaultValue),
|
|
99
|
-
default: defaultValue,
|
|
100
|
-
});
|
|
101
|
-
exports.String200Column = String200Column;
|
|
102
|
-
const NumberColumn = () => (0, lib_prod_1.Column)({ type: 'int', nullable: true });
|
|
103
|
-
exports.NumberColumn = NumberColumn;
|
|
104
|
-
const DecimalNumberColumn = () => (0, lib_prod_1.Column)({ type: 'float', nullable: true });
|
|
105
|
-
exports.DecimalNumberColumn = DecimalNumberColumn;
|
|
106
|
-
const SimpleJsonColumn = () => (0, lib_prod_1.Column)({ type: 'simple-json', nullable: true });
|
|
107
|
-
exports.SimpleJsonColumn = SimpleJsonColumn;
|
|
108
|
-
const BooleanColumn = (defaultValue) => (0, lib_prod_1.Column)({ type: 'boolean', nullable: true, default: defaultValue });
|
|
109
|
-
exports.BooleanColumn = BooleanColumn;
|
|
110
|
-
const DateTimeColumn = (defaultValue = null) => (0, lib_prod_1.Column)({ type: 'datetime', nullable: true, default: defaultValue });
|
|
111
|
-
exports.DateTimeColumn = DateTimeColumn;
|
|
112
|
-
//# sourceMappingURL=columns.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"columns.js","sourceRoot":"","sources":[""],"names":[],"mappings":";;;AAAA,oDAA0D;AAC1D,gDAAo8J;AAEp8J,kDAgC+B;AA/B7B,sGAAA,UAAU,OAAA;AACV,sGAAA,UAAU,OAAA;AACV,qGAAA,SAAS,OAAA;AACT,uGAA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,YAAY,gBAAiD;AAEnE,MAAM,mBAAmB,GAAG,GAAG,EAAE,CACtC,IAAA,iBAAM,EAAC,EAAE,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;AAD/B,QAAA,mBAAmB,uBACY;AAErC,MAAM,gBAAgB,GAAG,GAAG,EAAE,CACnC,IAAA,iBAAM,EAAC,EAAE,IAAI,EAAE,aAAa,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC;AADrC,QAAA,gBAAgB,oBACqB;AAE3C,MAAM,aAAa,GAAG,CAAC,YAA4B,EAAE,EAAE,CAC5D,IAAA,iBAAM,EAAC,EAAE,IAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,EAAE,YAAY,EAAE,CAAC,CAAC;AADxD,QAAA,aAAa,iBAC2C;AAE9D,MAAM,cAAc,GAAG,CAAC,eAA+B,IAAI,EAAE,EAAE,CACpE,IAAA,iBAAM,EAAC,EAAE,IAAI,EAAE,UAAU,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,EAAE,YAAY,EAAE,CAAC,CAAC;AADzD,QAAA,cAAc,kBAC2C"}
|
package/lib-prod/orm/index.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './columns';
|
package/lib-prod/orm/index.js
DELETED
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./columns"), exports);
|
|
18
|
-
// TODO new 5.8 typescript is not allowing this
|
|
19
|
-
// export namespace Orm {
|
|
20
|
-
// export const Repository = tsorm.Repository;
|
|
21
|
-
// export import Connection = tsorm.Connection;
|
|
22
|
-
// export namespace ListenEvent {
|
|
23
|
-
// export import AfterInsert = tsorm.AfterInsert;
|
|
24
|
-
// export import AfterLoad = tsorm.AfterLoad;
|
|
25
|
-
// export import AfterRecover = tsorm.AfterRecover;
|
|
26
|
-
// export import AfterRemove = tsorm.AfterRemove;
|
|
27
|
-
// export import AfterSoftRemove = tsorm.AfterSoftRemove;
|
|
28
|
-
// export import AfterUpdate = tsorm.AfterUpdate;
|
|
29
|
-
// export import BeforeInsert = tsorm.BeforeInsert;
|
|
30
|
-
// export import BeforeRecover = tsorm.BeforeRecover;
|
|
31
|
-
// export import BeforeRemove = tsorm.BeforeRemove;
|
|
32
|
-
// export import BeforeSoftRemove = tsorm.BeforeSoftRemove;
|
|
33
|
-
// export import BeforeUpdate = tsorm.BeforeUpdate;
|
|
34
|
-
// }
|
|
35
|
-
// export namespace Tree {
|
|
36
|
-
// export import Children = tsorm.TreeChildren;
|
|
37
|
-
// export import Parent = tsorm.TreeParent;
|
|
38
|
-
// }
|
|
39
|
-
// export namespace Column {
|
|
40
|
-
// export import Generated = tsorm.PrimaryGeneratedColumn;
|
|
41
|
-
// export import Primary = tsorm.PrimaryColumn;
|
|
42
|
-
// export import Index = tsorm.Index;
|
|
43
|
-
// export import CreateDate = tsorm.CreateDateColumn;
|
|
44
|
-
// export import UpdateDate = tsorm.UpdateDateColumn;
|
|
45
|
-
// export import DeleteDate = tsorm.DeleteDateColumn;
|
|
46
|
-
// export import Custom = tsorm.Column;
|
|
47
|
-
// export import String = additionalColumns.StringColumn;
|
|
48
|
-
// export import String100 = additionalColumns.String100Column;
|
|
49
|
-
// export import String45 = additionalColumns.String45Column;
|
|
50
|
-
// export import String500 = additionalColumns.String500Column;
|
|
51
|
-
// export import String200 = additionalColumns.String200Column;
|
|
52
|
-
// export import Number = additionalColumns.NumberColumn;
|
|
53
|
-
// export import DecimalNumber = additionalColumns.DecimalNumberColumn;
|
|
54
|
-
// export import SimpleJson = additionalColumns.SimpleJsonColumn;
|
|
55
|
-
// export import Boolean = additionalColumns.BooleanColumn;
|
|
56
|
-
// export import DateTIme = additionalColumns.DateTImeColumn;
|
|
57
|
-
// // TODO has limitation => comma in name
|
|
58
|
-
// // export const SimpleArray = () => tsorm.Column({ type: 'simple-array', nullable: true });
|
|
59
|
-
// export import Version = tsorm.VersionColumn;
|
|
60
|
-
// export import Virtual = tsorm.VirtualColumn;
|
|
61
|
-
// }
|
|
62
|
-
// export namespace Join {
|
|
63
|
-
// export import Table = tsorm.JoinTable;
|
|
64
|
-
// export import Column = tsorm.JoinColumn;
|
|
65
|
-
// }
|
|
66
|
-
// export namespace Relation {
|
|
67
|
-
// export import OneToMany = tsorm.OneToMany;
|
|
68
|
-
// export import OneToOne = tsorm.OneToOne;
|
|
69
|
-
// export import ManyToMany = tsorm.ManyToMany;
|
|
70
|
-
// export import ManyToOne = tsorm.ManyToOne;
|
|
71
|
-
// }
|
|
72
|
-
// }
|
|
73
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":[""],"names":[],"mappings":";;;;;;;;;;;;;;;;AAKA,4CAA0B;AAE1B,+CAA+C;AAC/C,yBAAyB;AACzB,gDAAgD;AAChD,iDAAiD;AACjD,mCAAmC;AACnC,qDAAqD;AACrD,iDAAiD;AACjD,uDAAuD;AACvD,qDAAqD;AACrD,6DAA6D;AAC7D,qDAAqD;AACrD,uDAAuD;AACvD,yDAAyD;AACzD,uDAAuD;AACvD,+DAA+D;AAC/D,uDAAuD;AACvD,MAAM;AACN,4BAA4B;AAC5B,mDAAmD;AACnD,+CAA+C;AAC/C,MAAM;AACN,8BAA8B;AAC9B,8DAA8D;AAC9D,mDAAmD;AACnD,yCAAyC;AACzC,yDAAyD;AACzD,yDAAyD;AACzD,yDAAyD;AACzD,2CAA2C;AAC3C,6DAA6D;AAC7D,mEAAmE;AACnE,iEAAiE;AACjE,mEAAmE;AACnE,mEAAmE;AACnE,6DAA6D;AAC7D,2EAA2E;AAC3E,qEAAqE;AACrE,+DAA+D;AAC/D,iEAAiE;AACjE,8CAA8C;AAC9C,kGAAkG;AAClG,mDAAmD;AACnD,mDAAmD;AACnD,MAAM;AACN,4BAA4B;AAC5B,6CAA6C;AAC7C,+CAA+C;AAC/C,MAAM;AACN,gCAAgC;AAChC,iDAAiD;AACjD,+CAA+C;AAC/C,mDAAmD;AACnD,iDAAiD;AACjD,MAAM;AACN,IAAI"}
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import { Observable } from 'rxjs';
|
|
2
|
-
import { RealtimeCore } from './realtime-core';
|
|
3
|
-
import { RealtimeModels__NS__ChangeOption } from './realtime.models';
|
|
4
|
-
/**
|
|
5
|
-
* Client for realtime communication
|
|
6
|
-
* you can listen to:
|
|
7
|
-
* - entity changes (any property in table changed)
|
|
8
|
-
* - entity custom property changes (specific property changed)
|
|
9
|
-
* - entity table changes (new instance added, instance removed)
|
|
10
|
-
* - custom events
|
|
11
|
-
*/
|
|
12
|
-
export declare class RealtimeClient {
|
|
13
|
-
private core;
|
|
14
|
-
private subsManagers;
|
|
15
|
-
constructor(core: RealtimeCore);
|
|
16
|
-
private init;
|
|
17
|
-
/**
|
|
18
|
-
* Usage:
|
|
19
|
-
* myContext.realtimeClient.listenChangesEntity(myEntityInstance);
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
* Changes trigger on backend needs to be done manually.. example code:
|
|
23
|
-
*
|
|
24
|
-
* myContext.realtimeServer.triggerEntityChanges(myEntityInstance);
|
|
25
|
-
* ...
|
|
26
|
-
*/
|
|
27
|
-
listenChangesEntity<RESULT = any>(entityClassFnOrObj: Function | object, options?: RealtimeModels__NS__ChangeOption): Observable<RESULT>;
|
|
28
|
-
/**
|
|
29
|
-
* Listen changes entity table
|
|
30
|
-
* Example: for pagination, lists update ...
|
|
31
|
-
*/
|
|
32
|
-
listenChangesEntityTable<RESULT = any>(entityClassFn: Function): Observable<RESULT>;
|
|
33
|
-
listenChangesCustomEvent<RESULT = any>(customEvent: string): Observable<RESULT>;
|
|
34
|
-
/**
|
|
35
|
-
* Trigger custom event on backend
|
|
36
|
-
* @param customEvent global event name
|
|
37
|
-
* @param dataToPush
|
|
38
|
-
*/
|
|
39
|
-
triggerCustomEvent(customEvent: string, dataToPush?: any): void;
|
|
40
|
-
private getUniqueIdentifierForConnection;
|
|
41
|
-
}
|
|
@@ -1,204 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.RealtimeClient = void 0;
|
|
4
|
-
//#region imports
|
|
5
|
-
const rxjs_1 = require("rxjs");
|
|
6
|
-
const lib_prod_1 = require("tnp-core/lib-prod");
|
|
7
|
-
const lib_prod_2 = require("tnp-core/lib-prod");
|
|
8
|
-
const class_helpers_1 = require("../helpers/class-helpers");
|
|
9
|
-
const symbols_1 = require("../symbols");
|
|
10
|
-
const realtime_subs_manager_1 = require("./realtime-subs-manager");
|
|
11
|
-
//#endregion
|
|
12
|
-
/**
|
|
13
|
-
* Client for realtime communication
|
|
14
|
-
* you can listen to:
|
|
15
|
-
* - entity changes (any property in table changed)
|
|
16
|
-
* - entity custom property changes (specific property changed)
|
|
17
|
-
* - entity table changes (new instance added, instance removed)
|
|
18
|
-
* - custom events
|
|
19
|
-
*/
|
|
20
|
-
class RealtimeClient {
|
|
21
|
-
core;
|
|
22
|
-
subsManagers = {};
|
|
23
|
-
constructor(core) {
|
|
24
|
-
this.core = core;
|
|
25
|
-
this.core = core;
|
|
26
|
-
if (!core.ctx.disabledRealtime) {
|
|
27
|
-
// this.core.ctx.logRealtime &&
|
|
28
|
-
// Helpers__NS__info(`
|
|
29
|
-
// [ctx=${this.core.ctx.contextName}] init RealtimeClient (type: ${this.core.ctx.contextType})
|
|
30
|
-
// `);
|
|
31
|
-
this.init();
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
//#region methods & getters / init
|
|
35
|
-
init() {
|
|
36
|
-
//#region prepare naspaces pathes
|
|
37
|
-
const nspPath = {
|
|
38
|
-
global: this.core.pathFor(),
|
|
39
|
-
realtime: this.core.pathFor(symbols_1.Symbols__NS__REALTIME.NAMESPACE(this.core.ctx.contextName)),
|
|
40
|
-
};
|
|
41
|
-
// console.log('[browser] nspPath', nspPath);
|
|
42
|
-
if (this.core.ctx.config.frontendHost &&
|
|
43
|
-
this.core.ctx.config.frontendHost !== '' &&
|
|
44
|
-
this.core.ctx.isRunningInsideDocker) {
|
|
45
|
-
this.core.ctx.logRealtime &&
|
|
46
|
-
(0, lib_prod_2.Helpers__NS__logInfo)(`[${this.core.ctx.contextName}] USING FRONTEND HOST` +
|
|
47
|
-
` ${this.core.ctx.config.frontendHost} FOR REALTIME`);
|
|
48
|
-
nspPath.global = new URL(`${this.core.ctx.frontendHostUri.origin}${nspPath.global.pathname}`);
|
|
49
|
-
nspPath.realtime = new URL(`${this.core.ctx.frontendHostUri.origin}${nspPath.realtime.pathname}`);
|
|
50
|
-
}
|
|
51
|
-
else {
|
|
52
|
-
this.core.ctx.logRealtime &&
|
|
53
|
-
(0, lib_prod_2.Helpers__NS__logInfo)(`[${this.core.ctx.contextName}] Not using frontend host for realtime`);
|
|
54
|
-
}
|
|
55
|
-
this.core.ctx.logRealtime &&
|
|
56
|
-
console.info('[CLIENT] NAMESPACE GLOBAL ', nspPath.global.href + ` host: ${this.core.ctx.host}`);
|
|
57
|
-
this.core.ctx.logRealtime &&
|
|
58
|
-
console.info('[CLIENT] NAMESPACE REALTIME', nspPath.realtime.href + ` host: ${this.core.ctx.host}`);
|
|
59
|
-
//#endregion
|
|
60
|
-
//#region prepare globa FE socket
|
|
61
|
-
this.core.conectSocketFE = this.core.strategy.ioClient(nspPath.global.origin, {
|
|
62
|
-
path: nspPath.global.pathname,
|
|
63
|
-
});
|
|
64
|
-
if (this.core.conectSocketFE.on) {
|
|
65
|
-
this.core.conectSocketFE.on('connect', () => {
|
|
66
|
-
// console.info(
|
|
67
|
-
// `[CLIENT] connected to GLOBAL namespace ${global.nsp} of host: ${context.host}`,
|
|
68
|
-
// );
|
|
69
|
-
this.core.ctx.logRealtime &&
|
|
70
|
-
console.info(`[CLIENT] connected to GLOBAL namespace ${nspPath.global.pathname}` +
|
|
71
|
-
` of host: ${this.core.ctx.host}`);
|
|
72
|
-
});
|
|
73
|
-
}
|
|
74
|
-
//#endregion
|
|
75
|
-
//#region prepare realtime FE socket
|
|
76
|
-
this.core.socketFE = this.core.strategy.ioClient(nspPath.realtime.origin, {
|
|
77
|
-
path: nspPath.realtime.pathname,
|
|
78
|
-
});
|
|
79
|
-
if (this.core.socketFE.on) {
|
|
80
|
-
this.core.socketFE.on('connect', () => {
|
|
81
|
-
// console.info(
|
|
82
|
-
// `[CLIENT] connected to REALTIME namespace ${realtime.nsp} host: ${context.host}`,
|
|
83
|
-
// );
|
|
84
|
-
this.core.ctx.logRealtime &&
|
|
85
|
-
console.info(`[CLIENT] connected to REALTIME namespace ${nspPath.realtime.pathname}` +
|
|
86
|
-
` host: ${this.core.ctx.host}`);
|
|
87
|
-
});
|
|
88
|
-
}
|
|
89
|
-
//#endregion
|
|
90
|
-
}
|
|
91
|
-
//#endregion
|
|
92
|
-
//#region methods & getters / listen changes entity
|
|
93
|
-
/**
|
|
94
|
-
* Usage:
|
|
95
|
-
* myContext.realtimeClient.listenChangesEntity(myEntityInstance);
|
|
96
|
-
*
|
|
97
|
-
*
|
|
98
|
-
* Changes trigger on backend needs to be done manually.. example code:
|
|
99
|
-
*
|
|
100
|
-
* myContext.realtimeServer.triggerEntityChanges(myEntityInstance);
|
|
101
|
-
* ...
|
|
102
|
-
*/
|
|
103
|
-
listenChangesEntity(entityClassFnOrObj, options) {
|
|
104
|
-
options = options || {};
|
|
105
|
-
if ((0, lib_prod_1.___NS__isObject)(entityClassFnOrObj)) {
|
|
106
|
-
const orgObj = entityClassFnOrObj;
|
|
107
|
-
entityClassFnOrObj =
|
|
108
|
-
(0, class_helpers_1.ClassHelpers__NS__getClassFnFromObject)(entityClassFnOrObj);
|
|
109
|
-
const uniqueKey = (0, class_helpers_1.ClassHelpers__NS__getUniqueKey)(entityClassFnOrObj);
|
|
110
|
-
if (uniqueKey) {
|
|
111
|
-
options.idOrUniqValue = orgObj[uniqueKey];
|
|
112
|
-
}
|
|
113
|
-
}
|
|
114
|
-
//#region parameters validation
|
|
115
|
-
const { property, customEvent } = options;
|
|
116
|
-
const className = !customEvent && (0, class_helpers_1.ClassHelpers__NS__getName)(entityClassFnOrObj);
|
|
117
|
-
if ((0, lib_prod_1.___NS__isString)(property)) {
|
|
118
|
-
if (property.trim() === '') {
|
|
119
|
-
throw new Error(`[Taon][listenChangesEntity.. incorrect property '' for ${className}`);
|
|
120
|
-
}
|
|
121
|
-
}
|
|
122
|
-
//#endregion
|
|
123
|
-
return new rxjs_1.Observable(observer => {
|
|
124
|
-
//#region prepare parameters for manager
|
|
125
|
-
if (this.core.ctx.disabledRealtime) {
|
|
126
|
-
console.error(`[Taon][realtime rxjs] remove taon config flag:
|
|
127
|
-
|
|
128
|
-
...
|
|
129
|
-
disabledRealtime: true
|
|
130
|
-
...
|
|
131
|
-
|
|
132
|
-
to use socket realtime connection;
|
|
133
|
-
`);
|
|
134
|
-
return () => {
|
|
135
|
-
// empty nothing to do
|
|
136
|
-
};
|
|
137
|
-
}
|
|
138
|
-
let roomName;
|
|
139
|
-
if (customEvent) {
|
|
140
|
-
roomName = symbols_1.Symbols__NS__REALTIME.ROOM_NAME_CUSTOM(this.core.ctx.contextName, customEvent);
|
|
141
|
-
}
|
|
142
|
-
else {
|
|
143
|
-
roomName = (0, lib_prod_1.___NS__isString)(property)
|
|
144
|
-
? symbols_1.Symbols__NS__REALTIME.ROOM_NAME_UPDATE_ENTITY_PROPERTY(this.core.ctx.contextName, className, property, options.idOrUniqValue)
|
|
145
|
-
: symbols_1.Symbols__NS__REALTIME.ROOM_NAME_UPDATE_ENTITY(this.core.ctx.contextName, className, options.idOrUniqValue);
|
|
146
|
-
}
|
|
147
|
-
const roomSubOptions = {
|
|
148
|
-
core: this.core,
|
|
149
|
-
property,
|
|
150
|
-
roomName,
|
|
151
|
-
customEvent,
|
|
152
|
-
};
|
|
153
|
-
//#endregion
|
|
154
|
-
const subManagerId = this.getUniqueIdentifierForConnection(roomSubOptions);
|
|
155
|
-
if (!this.subsManagers[subManagerId]) {
|
|
156
|
-
this.subsManagers[subManagerId] = new realtime_subs_manager_1.RealtimeSubsManager(roomSubOptions);
|
|
157
|
-
}
|
|
158
|
-
const inst = this.subsManagers[subManagerId];
|
|
159
|
-
inst.add(observer);
|
|
160
|
-
inst.startListenIfNotStarted(this.core.socketFE);
|
|
161
|
-
return () => {
|
|
162
|
-
inst.remove(observer);
|
|
163
|
-
};
|
|
164
|
-
});
|
|
165
|
-
}
|
|
166
|
-
//#endregion
|
|
167
|
-
//#region listen changes entity table
|
|
168
|
-
/**
|
|
169
|
-
* Listen changes entity table
|
|
170
|
-
* Example: for pagination, lists update ...
|
|
171
|
-
*/
|
|
172
|
-
listenChangesEntityTable(entityClassFn) {
|
|
173
|
-
const className = (0, class_helpers_1.ClassHelpers__NS__getName)(entityClassFn);
|
|
174
|
-
return this.listenChangesEntity(entityClassFn, {
|
|
175
|
-
customEvent: symbols_1.Symbols__NS__REALTIME.TABLE_CHANGE(this.core.ctx.contextName, className),
|
|
176
|
-
});
|
|
177
|
-
}
|
|
178
|
-
//#endregion
|
|
179
|
-
//#region listen changes custom event
|
|
180
|
-
listenChangesCustomEvent(customEvent) {
|
|
181
|
-
return this.listenChangesEntity(void 0, {
|
|
182
|
-
customEvent,
|
|
183
|
-
});
|
|
184
|
-
}
|
|
185
|
-
//#endregion
|
|
186
|
-
//#region methods & getters / trigger custom event\
|
|
187
|
-
/**
|
|
188
|
-
* Trigger custom event on backend
|
|
189
|
-
* @param customEvent global event name
|
|
190
|
-
* @param dataToPush
|
|
191
|
-
*/
|
|
192
|
-
triggerCustomEvent(customEvent, dataToPush) {
|
|
193
|
-
this.core.socketFE.emit(customEvent, dataToPush);
|
|
194
|
-
}
|
|
195
|
-
//#endregion
|
|
196
|
-
//#region methods & getters / get room id from
|
|
197
|
-
getUniqueIdentifierForConnection(options) {
|
|
198
|
-
let url = new URL(options.core.ctx.host);
|
|
199
|
-
let contextNameForCommunication = options.core.ctx.contextNameForCommunication;
|
|
200
|
-
return `${contextNameForCommunication}:${url.origin}|${options.roomName}|${options.property}|${options.customEvent}`;
|
|
201
|
-
}
|
|
202
|
-
}
|
|
203
|
-
exports.RealtimeClient = RealtimeClient;
|
|
204
|
-
//# sourceMappingURL=realtime-client.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"realtime-client.js","sourceRoot":"","sources":[""],"names":[],"mappings":";;;AAAA,iBAAiB;AACjB,+BAAkC;AAClC,gDAAovM;AACpvM,gDAAimF;AAGjmF,4DAA4hB;AAC5hB,wCAA8S;AAG9S,mEAA8D;AAG9D,YAAY;AAEZ;;;;;;;GAOG;AACH,MAAa,cAAc;IAEL;IADZ,YAAY,GAA4C,EAAE,CAAC;IACnE,YAAoB,IAAkB;QAAlB,SAAI,GAAJ,IAAI,CAAc;QACpC,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;QACjB,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,gBAAgB,EAAE,CAAC;YAC/B,+BAA+B;YAC/B,wBAAwB;YAExB,gGAAgG;YAEhG,QAA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CAAC,2BAA2B,CAAC;QAC/C,OAAO,GAAG,2BAA2B,IAAI,GAAG,CAAC,MAAM,IAAI,OAAO,CAAC,QAAQ,IAAI,OAAO,CAAC,QAAQ,IAAI,OAAO,CAAC,WAAW,EAAE,CAAC;IACvH,CAAC;CAEF;AAxQD,wCAwQC"}
|
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
import { Server } from 'socket.io';
|
|
2
|
-
import { DefaultEventsMap } from 'socket.io';
|
|
3
|
-
import { Socket as SocketClient } from 'socket.io-client';
|
|
4
|
-
import type { EndpointContext } from '../endpoint-context';
|
|
5
|
-
import { RealtimeClient } from './realtime-client';
|
|
6
|
-
import { RealtimeServer } from './realtime-server';
|
|
7
|
-
import type { RealtimeStrategy } from './realtime-strategy';
|
|
8
|
-
/**
|
|
9
|
-
* Realtime class
|
|
10
|
-
* - mock (when browser-browser)
|
|
11
|
-
* - sockets (from socket io when backend-browser)
|
|
12
|
-
* - ipc (when electron is used or between processes)
|
|
13
|
-
* - webworker (when webworker is used in browser or nodejs)
|
|
14
|
-
*/
|
|
15
|
-
export declare class RealtimeCore {
|
|
16
|
-
ctx: EndpointContext;
|
|
17
|
-
readonly allHttpMethods: string[];
|
|
18
|
-
readonly client: RealtimeClient;
|
|
19
|
-
readonly server: RealtimeServer;
|
|
20
|
-
readonly strategy: RealtimeStrategy;
|
|
21
|
-
/**
|
|
22
|
-
* global FE socket - only for established connection
|
|
23
|
-
*/
|
|
24
|
-
conectSocketFE: SocketClient<DefaultEventsMap, DefaultEventsMap>;
|
|
25
|
-
/**
|
|
26
|
-
* socket for namespaces and rooms
|
|
27
|
-
*/
|
|
28
|
-
socketFE: SocketClient<DefaultEventsMap, DefaultEventsMap>;
|
|
29
|
-
/**
|
|
30
|
-
* global BE socket - only for established connection
|
|
31
|
-
*/
|
|
32
|
-
connectSocketBE: Server<DefaultEventsMap, DefaultEventsMap, DefaultEventsMap, any>;
|
|
33
|
-
/**
|
|
34
|
-
* socket for namespaces and rooms
|
|
35
|
-
*/
|
|
36
|
-
socketBE: Server<DefaultEventsMap, DefaultEventsMap, DefaultEventsMap, any>;
|
|
37
|
-
constructor(ctx: EndpointContext);
|
|
38
|
-
private resolveStrategy;
|
|
39
|
-
pathFor(namespace?: string): URL;
|
|
40
|
-
}
|