taon 18.0.20 → 18.0.22
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/README.md +3 -7
- package/assets/shared/logo-header-admin-mode.png +0 -0
- package/assets/shared/shared_folder_info.txt +1 -1
- package/browser/esm2022/lib/base-classes/base-class.mjs +2 -2
- package/browser/esm2022/lib/base-classes/base-controller.mjs +3 -2
- package/browser/esm2022/lib/base-classes/base-migration.mjs +23 -0
- package/browser/esm2022/lib/base-classes/base-subscriber-for-entity.mjs +20 -20
- package/browser/esm2022/lib/base-classes/base.mjs +3 -1
- package/browser/esm2022/lib/context-db-migrations.mjs +425 -0
- package/browser/esm2022/lib/create-context.mjs +17 -4
- package/browser/esm2022/lib/decorators/classes/controller-decorator.mjs +4 -1
- package/browser/esm2022/lib/decorators/classes/entity-decorator.mjs +4 -1
- package/browser/esm2022/lib/decorators/classes/migration-decorator.mjs +18 -0
- package/browser/esm2022/lib/decorators/classes/provider-decorator.mjs +4 -1
- package/browser/esm2022/lib/decorators/classes/repository-decorator.mjs +4 -1
- package/browser/esm2022/lib/decorators/classes/subscriber-decorator.mjs +5 -2
- package/browser/esm2022/lib/endpoint-context.mjs +83 -49
- package/browser/esm2022/lib/index.mjs +4 -1
- package/browser/esm2022/lib/inject.mjs +1 -1
- package/browser/esm2022/lib/models.mjs +30 -1
- package/browser/esm2022/lib/symbols.mjs +2 -1
- package/browser/esm2022/lib/ui/taon-admin-mode-configuration/index.mjs +1 -3
- package/browser/esm2022/lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.component.mjs +55 -37
- package/browser/esm2022/lib/ui/taon-admin-mode-configuration/taon-admin.service.mjs +17 -21
- package/browser/esm2022/lib/ui/taon-notifications/taon-notifications.module.mjs +1 -1
- package/browser/esm2022/lib/ui/taon-progress-bar/taon-progress-bar.component.mjs +1 -1
- package/browser/esm2022/lib/ui/taon-table/taon-table.component.mjs +1 -2
- package/browser/fesm2022/taon.mjs +688 -420
- package/browser/fesm2022/taon.mjs.map +1 -1
- package/browser/lib/base-classes/base-class.d.ts +1 -1
- package/browser/lib/base-classes/base-context.d.ts +3 -0
- package/browser/lib/base-classes/base-controller.d.ts +2 -1
- package/browser/lib/base-classes/base-migration.d.ts +12 -0
- package/browser/lib/base-classes/base.d.ts +5 -0
- package/browser/lib/context-db-migrations.d.ts +18 -0
- package/browser/lib/create-context.d.ts +4 -1
- package/browser/lib/decorators/classes/controller-decorator.d.ts +3 -0
- package/browser/lib/decorators/classes/entity-decorator.d.ts +3 -0
- package/browser/lib/decorators/classes/migration-decorator.d.ts +8 -0
- package/browser/lib/decorators/classes/provider-decorator.d.ts +3 -0
- package/browser/lib/decorators/classes/repository-decorator.d.ts +3 -0
- package/browser/lib/decorators/classes/subscriber-decorator.d.ts +3 -0
- package/browser/lib/endpoint-context.d.ts +12 -5
- package/browser/lib/index.d.ts +14 -1
- package/browser/lib/models.d.ts +44 -19
- package/browser/lib/symbols.d.ts +1 -0
- package/browser/lib/ui/taon-admin-mode-configuration/index.d.ts +1 -3
- package/browser/lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.component.d.ts +5 -8
- package/browser/lib/ui/taon-admin-mode-configuration/taon-admin.service.d.ts +8 -8
- package/client/esm2022/lib/base-classes/base-class.mjs +2 -2
- package/client/esm2022/lib/base-classes/base-controller.mjs +3 -2
- package/client/esm2022/lib/base-classes/base-migration.mjs +23 -0
- package/client/esm2022/lib/base-classes/base-subscriber-for-entity.mjs +20 -20
- package/client/esm2022/lib/base-classes/base.mjs +3 -1
- package/client/esm2022/lib/context-db-migrations.mjs +425 -0
- package/client/esm2022/lib/create-context.mjs +17 -4
- package/client/esm2022/lib/decorators/classes/controller-decorator.mjs +4 -1
- package/client/esm2022/lib/decorators/classes/entity-decorator.mjs +4 -1
- package/client/esm2022/lib/decorators/classes/migration-decorator.mjs +18 -0
- package/client/esm2022/lib/decorators/classes/provider-decorator.mjs +4 -1
- package/client/esm2022/lib/decorators/classes/repository-decorator.mjs +4 -1
- package/client/esm2022/lib/decorators/classes/subscriber-decorator.mjs +5 -2
- package/client/esm2022/lib/endpoint-context.mjs +83 -49
- package/client/esm2022/lib/index.mjs +4 -1
- package/client/esm2022/lib/inject.mjs +1 -1
- package/client/esm2022/lib/models.mjs +30 -1
- package/client/esm2022/lib/symbols.mjs +2 -1
- package/client/esm2022/lib/ui/taon-admin-mode-configuration/index.mjs +1 -3
- package/client/esm2022/lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.component.mjs +55 -37
- package/client/esm2022/lib/ui/taon-admin-mode-configuration/taon-admin.service.mjs +17 -21
- package/client/esm2022/lib/ui/taon-notifications/taon-notifications.module.mjs +1 -1
- package/client/esm2022/lib/ui/taon-progress-bar/taon-progress-bar.component.mjs +1 -1
- package/client/esm2022/lib/ui/taon-table/taon-table.component.mjs +1 -2
- package/client/fesm2022/taon.mjs +688 -420
- package/client/fesm2022/taon.mjs.map +1 -1
- package/client/lib/base-classes/base-class.d.ts +1 -1
- package/client/lib/base-classes/base-context.d.ts +3 -0
- package/client/lib/base-classes/base-controller.d.ts +2 -1
- package/client/lib/base-classes/base-migration.d.ts +12 -0
- package/client/lib/base-classes/base.d.ts +5 -0
- package/client/lib/context-db-migrations.d.ts +18 -0
- package/client/lib/create-context.d.ts +4 -1
- package/client/lib/decorators/classes/controller-decorator.d.ts +3 -0
- package/client/lib/decorators/classes/entity-decorator.d.ts +3 -0
- package/client/lib/decorators/classes/migration-decorator.d.ts +8 -0
- package/client/lib/decorators/classes/provider-decorator.d.ts +3 -0
- package/client/lib/decorators/classes/repository-decorator.d.ts +3 -0
- package/client/lib/decorators/classes/subscriber-decorator.d.ts +3 -0
- package/client/lib/endpoint-context.d.ts +12 -5
- package/client/lib/index.d.ts +14 -1
- package/client/lib/models.d.ts +44 -19
- package/client/lib/symbols.d.ts +1 -0
- package/client/lib/ui/taon-admin-mode-configuration/index.d.ts +1 -3
- package/client/lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.component.d.ts +5 -8
- package/client/lib/ui/taon-admin-mode-configuration/taon-admin.service.d.ts +8 -8
- package/lib/base-classes/base-class.d.ts +1 -1
- package/lib/base-classes/base-class.js +1 -1
- package/lib/base-classes/base-context.d.ts +3 -0
- package/lib/base-classes/base-controller.d.ts +2 -1
- package/lib/base-classes/base-controller.js +2 -1
- package/lib/base-classes/base-controller.js.map +1 -1
- package/lib/base-classes/base-migration.d.ts +11 -0
- package/lib/base-classes/base-migration.js +41 -0
- package/lib/base-classes/base-migration.js.map +1 -0
- package/lib/base-classes/base-repository.js +4 -4
- package/lib/base-classes/base-repository.js.map +1 -1
- package/lib/base-classes/base-subscriber-for-entity.js +19 -19
- package/lib/base-classes/base-subscriber-for-entity.js.map +1 -1
- package/lib/base-classes/base.d.ts +5 -0
- package/lib/base-classes/base.js +2 -0
- package/lib/base-classes/base.js.map +1 -1
- package/lib/context-db-migrations.d.ts +17 -0
- package/lib/context-db-migrations.js +605 -0
- package/lib/context-db-migrations.js.map +1 -0
- package/lib/create-context.d.ts +4 -1
- package/lib/create-context.js +30 -21
- package/lib/create-context.js.map +1 -1
- package/lib/decorators/classes/controller-decorator.d.ts +3 -0
- package/lib/decorators/classes/controller-decorator.js +3 -0
- package/lib/decorators/classes/controller-decorator.js.map +1 -1
- package/lib/decorators/classes/entity-decorator.d.ts +3 -0
- package/lib/decorators/classes/entity-decorator.js +3 -0
- package/lib/decorators/classes/entity-decorator.js.map +1 -1
- package/lib/decorators/classes/migration-decorator.d.ts +7 -0
- package/lib/decorators/classes/migration-decorator.js +27 -0
- package/lib/decorators/classes/migration-decorator.js.map +1 -0
- package/lib/decorators/classes/provider-decorator.d.ts +3 -0
- package/lib/decorators/classes/provider-decorator.js +3 -0
- package/lib/decorators/classes/provider-decorator.js.map +1 -1
- package/lib/decorators/classes/repository-decorator.d.ts +3 -0
- package/lib/decorators/classes/repository-decorator.js +3 -0
- package/lib/decorators/classes/repository-decorator.js.map +1 -1
- package/lib/decorators/classes/subscriber-decorator.d.ts +3 -0
- package/lib/decorators/classes/subscriber-decorator.js +4 -1
- package/lib/decorators/classes/subscriber-decorator.js.map +1 -1
- package/lib/endpoint-context.d.ts +12 -5
- package/lib/endpoint-context.js +234 -189
- package/lib/endpoint-context.js.map +1 -1
- package/lib/index.d.ts +14 -1
- package/lib/index.js +5 -1
- package/lib/index.js.map +1 -1
- package/lib/inject.js +0 -2
- package/lib/inject.js.map +1 -1
- package/lib/models.d.ts +44 -19
- package/lib/models.js +45 -0
- package/lib/models.js.map +1 -1
- package/lib/symbols.d.ts +1 -0
- package/lib/symbols.js +1 -0
- package/lib/symbols.js.map +1 -1
- package/lib/ui/directives/index.js +2 -2
- package/lib/ui/index.js +2 -2
- package/lib/ui/taon-admin-mode-configuration/index.d.ts +1 -3
- package/lib/ui/taon-admin-mode-configuration/index.js +2 -2
- package/lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.component.d.ts +4 -7
- package/lib/ui/taon-admin-mode-configuration/{models/taon-admin-mode-tabs.js → taon-admin.models.js} +1 -1
- package/lib/ui/taon-admin-mode-configuration/taon-admin.models.js.map +1 -0
- package/lib/ui/taon-admin-mode-configuration/taon-admin.service.d.ts +6 -6
- package/lib/ui/taon-github-fork-me-corner/index.js +2 -2
- package/lib/ui/taon-github-fork-me-ribbon/index.js +2 -2
- package/lib/ui/taon-notifications/taon-notifications.models.js +2 -2
- package/lib/ui/taon-progress-bar/index.js +2 -2
- package/lib/ui/taon-session-passcode/index.js +2 -2
- package/lib/ui/taon-table/index.js +2 -2
- package/migrations/index.d.ts +1 -0
- package/migrations/index.js +6 -0
- package/migrations/index.js.map +1 -0
- package/migrations/migrations_index._auto-generated_.d.ts +0 -0
- package/migrations/migrations_index._auto-generated_.js +4 -0
- package/migrations/migrations_index._auto-generated_.js.map +1 -0
- package/package.json +7 -7
- package/tmp-environment.json +32 -29
- package/websql/esm2022/lib/base-classes/base-class.mjs +2 -2
- package/websql/esm2022/lib/base-classes/base-controller.mjs +3 -2
- package/websql/esm2022/lib/base-classes/base-migration.mjs +23 -0
- package/websql/esm2022/lib/base-classes/base-repository.mjs +5 -5
- package/websql/esm2022/lib/base-classes/base-subscriber-for-entity.mjs +20 -20
- package/websql/esm2022/lib/base-classes/base.mjs +3 -1
- package/websql/esm2022/lib/context-db-migrations.mjs +274 -0
- package/websql/esm2022/lib/create-context.mjs +17 -4
- package/websql/esm2022/lib/decorators/classes/controller-decorator.mjs +4 -1
- package/websql/esm2022/lib/decorators/classes/entity-decorator.mjs +4 -1
- package/websql/esm2022/lib/decorators/classes/migration-decorator.mjs +18 -0
- package/websql/esm2022/lib/decorators/classes/provider-decorator.mjs +4 -1
- package/websql/esm2022/lib/decorators/classes/repository-decorator.mjs +4 -1
- package/websql/esm2022/lib/decorators/classes/subscriber-decorator.mjs +5 -2
- package/websql/esm2022/lib/endpoint-context.mjs +117 -85
- package/websql/esm2022/lib/index.mjs +4 -1
- package/websql/esm2022/lib/inject.mjs +1 -1
- package/websql/esm2022/lib/models.mjs +28 -1
- package/websql/esm2022/lib/symbols.mjs +2 -1
- package/websql/esm2022/lib/ui/taon-admin-mode-configuration/index.mjs +1 -3
- package/websql/esm2022/lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.component.mjs +55 -37
- package/websql/esm2022/lib/ui/taon-admin-mode-configuration/taon-admin.service.mjs +17 -21
- package/websql/esm2022/lib/ui/taon-notifications/taon-notifications.module.mjs +1 -1
- package/websql/esm2022/lib/ui/taon-progress-bar/taon-progress-bar.component.mjs +1 -1
- package/websql/esm2022/lib/ui/taon-table/taon-table.component.mjs +1 -2
- package/websql/fesm2022/taon.mjs +569 -460
- package/websql/fesm2022/taon.mjs.map +1 -1
- package/websql/lib/base-classes/base-class.d.ts +1 -1
- package/websql/lib/base-classes/base-context.d.ts +3 -0
- package/websql/lib/base-classes/base-controller.d.ts +2 -1
- package/websql/lib/base-classes/base-migration.d.ts +12 -0
- package/websql/lib/base-classes/base.d.ts +5 -0
- package/websql/lib/context-db-migrations.d.ts +18 -0
- package/websql/lib/create-context.d.ts +4 -1
- package/websql/lib/decorators/classes/controller-decorator.d.ts +3 -0
- package/websql/lib/decorators/classes/entity-decorator.d.ts +3 -0
- package/websql/lib/decorators/classes/migration-decorator.d.ts +8 -0
- package/websql/lib/decorators/classes/provider-decorator.d.ts +3 -0
- package/websql/lib/decorators/classes/repository-decorator.d.ts +3 -0
- package/websql/lib/decorators/classes/subscriber-decorator.d.ts +3 -0
- package/websql/lib/endpoint-context.d.ts +12 -5
- package/websql/lib/index.d.ts +14 -1
- package/websql/lib/models.d.ts +44 -19
- package/websql/lib/symbols.d.ts +1 -0
- package/websql/lib/ui/taon-admin-mode-configuration/index.d.ts +1 -3
- package/websql/lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.component.d.ts +5 -8
- package/websql/lib/ui/taon-admin-mode-configuration/taon-admin.service.d.ts +8 -8
- package/browser/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/index.mjs +0 -5
- package/browser/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.component.mjs +0 -115
- package/browser/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.module.mjs +0 -50
- package/browser/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/index.mjs +0 -5
- package/browser/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.component.mjs +0 -61
- package/browser/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.module.mjs +0 -21
- package/browser/esm2022/lib/ui/taon-admin-mode-configuration/models/taon-admin-mode-tabs.mjs +0 -4
- package/browser/esm2022/lib/ui/taon-admin-mode-configuration/taon-admin-control.service.mjs +0 -32
- package/browser/esm2022/lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.module.mjs +0 -54
- package/browser/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/index.d.ts +0 -3
- package/browser/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.component.d.ts +0 -33
- package/browser/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.module.d.ts +0 -16
- package/browser/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/index.d.ts +0 -3
- package/browser/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.component.d.ts +0 -17
- package/browser/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.module.d.ts +0 -10
- package/browser/lib/ui/taon-admin-mode-configuration/models/taon-admin-mode-tabs.d.ts +0 -6
- package/browser/lib/ui/taon-admin-mode-configuration/taon-admin-control.service.d.ts +0 -18
- package/browser/lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.module.d.ts +0 -17
- package/client/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/index.mjs +0 -5
- package/client/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.component.mjs +0 -115
- package/client/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.module.mjs +0 -50
- package/client/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/index.mjs +0 -5
- package/client/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.component.mjs +0 -61
- package/client/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.module.mjs +0 -21
- package/client/esm2022/lib/ui/taon-admin-mode-configuration/models/taon-admin-mode-tabs.mjs +0 -4
- package/client/esm2022/lib/ui/taon-admin-mode-configuration/taon-admin-control.service.mjs +0 -32
- package/client/esm2022/lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.module.mjs +0 -54
- package/client/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/index.d.ts +0 -3
- package/client/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.component.d.ts +0 -33
- package/client/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.module.d.ts +0 -16
- package/client/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/index.d.ts +0 -3
- package/client/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.component.d.ts +0 -17
- package/client/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.module.d.ts +0 -10
- package/client/lib/ui/taon-admin-mode-configuration/models/taon-admin-mode-tabs.d.ts +0 -6
- package/client/lib/ui/taon-admin-mode-configuration/taon-admin-control.service.d.ts +0 -18
- package/client/lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.module.d.ts +0 -17
- package/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/index.d.ts +0 -2
- package/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/index.js +0 -5
- package/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/index.js.map +0 -1
- package/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.component.d.ts +0 -29
- package/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.module.d.ts +0 -2
- package/lib/ui/taon-admin-mode-configuration/components/taon-db-admin/index.d.ts +0 -1
- package/lib/ui/taon-admin-mode-configuration/components/taon-db-admin/index.js +0 -5
- package/lib/ui/taon-admin-mode-configuration/components/taon-db-admin/index.js.map +0 -1
- package/lib/ui/taon-admin-mode-configuration/components/taon-db-admin/taon-db-admin.component.d.ts +0 -8
- package/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/index.d.ts +0 -2
- package/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/index.js +0 -5
- package/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/index.js.map +0 -1
- package/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.component.d.ts +0 -13
- package/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.module.d.ts +0 -2
- package/lib/ui/taon-admin-mode-configuration/models/taon-admin-mode-tabs.js.map +0 -1
- package/lib/ui/taon-admin-mode-configuration/taon-admin-control.service.d.ts +0 -14
- package/lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.module.d.ts +0 -2
- package/websql/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/index.mjs +0 -5
- package/websql/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.component.mjs +0 -115
- package/websql/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.module.mjs +0 -50
- package/websql/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/index.mjs +0 -5
- package/websql/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.component.mjs +0 -61
- package/websql/esm2022/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.module.mjs +0 -21
- package/websql/esm2022/lib/ui/taon-admin-mode-configuration/models/taon-admin-mode-tabs.mjs +0 -4
- package/websql/esm2022/lib/ui/taon-admin-mode-configuration/taon-admin-control.service.mjs +0 -32
- package/websql/esm2022/lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.module.mjs +0 -54
- package/websql/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/index.d.ts +0 -3
- package/websql/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.component.d.ts +0 -33
- package/websql/lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.module.d.ts +0 -16
- package/websql/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/index.d.ts +0 -3
- package/websql/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.component.d.ts +0 -17
- package/websql/lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.module.d.ts +0 -10
- package/websql/lib/ui/taon-admin-mode-configuration/models/taon-admin-mode-tabs.d.ts +0 -6
- package/websql/lib/ui/taon-admin-mode-configuration/taon-admin-control.service.d.ts +0 -18
- package/websql/lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.module.d.ts +0 -17
- /package/lib/ui/taon-admin-mode-configuration/{models/taon-admin-mode-tabs.d.ts → taon-admin.models.d.ts} +0 -0
package/websql/fesm2022/taon.mjs
CHANGED
|
@@ -1,16 +1,15 @@
|
|
|
1
1
|
import 'reflect-metadata';
|
|
2
2
|
import * as coreHelpers from 'tnp-core/websql';
|
|
3
|
-
import { _ as _$1, Helpers, path } from 'tnp-core/websql';
|
|
3
|
+
import { _ as _$1, Helpers, UtilsMigrations, UtilsOs, path } from 'tnp-core/websql';
|
|
4
4
|
import { Models as Models$1, RestHeaders, Resource, Mapping } from 'ng2-rest/websql';
|
|
5
5
|
import * as tsorm from 'taon-typeorm/websql';
|
|
6
|
-
import { OrignalClassKey, Entity, EventSubscriber, DataSource } from 'taon-typeorm/websql';
|
|
6
|
+
import { OrignalClassKey, Entity, Table, TableIndex, EventSubscriber, DataSource } from 'taon-typeorm/websql';
|
|
7
7
|
import { SYMBOL, CLASS } from 'typescript-class-helpers/websql';
|
|
8
8
|
import * as JSON5 from 'json5';
|
|
9
9
|
import { __decorate, __param, __metadata } from 'tslib';
|
|
10
10
|
import { MySqlQuerySource } from 'taon-type-sql/websql';
|
|
11
11
|
import { Stor } from 'taon-storage/websql';
|
|
12
|
-
import { Subject, Observable, from, interval, tap, defer, fromEvent, map, debounceTime, distinctUntilChanged, share, Subscription, takeUntil
|
|
13
|
-
import { config } from 'tnp-config/websql';
|
|
12
|
+
import { Subject, Observable, from, interval, tap, defer, fromEvent, map, debounceTime, distinctUntilChanged, share, Subscription, takeUntil } from 'rxjs';
|
|
14
13
|
import * as i0 from '@angular/core';
|
|
15
14
|
import { Injectable, inject as inject$1, EventEmitter, Directive, Input, Output, HostBinding, HostListener, Pipe, NgModule, Component, DestroyRef, Self, ViewChild, ChangeDetectorRef } from '@angular/core';
|
|
16
15
|
import { JSON10 } from 'json10/websql';
|
|
@@ -19,7 +18,7 @@ import { io } from 'socket.io-client';
|
|
|
19
18
|
import { Log, Level } from 'ng2-logger/websql';
|
|
20
19
|
import * as i1 from '@angular/platform-browser';
|
|
21
20
|
import { A11yModule } from '@angular/cdk/a11y';
|
|
22
|
-
import * as
|
|
21
|
+
import * as i6$1 from '@angular/cdk/drag-drop';
|
|
23
22
|
import { DragDropModule } from '@angular/cdk/drag-drop';
|
|
24
23
|
import { ScrollingModule } from '@angular/cdk/scrolling';
|
|
25
24
|
import { CdkStepperModule } from '@angular/cdk/stepper';
|
|
@@ -28,11 +27,11 @@ import { CdkTreeModule } from '@angular/cdk/tree';
|
|
|
28
27
|
import { MatAutocompleteModule } from '@angular/material/autocomplete';
|
|
29
28
|
import { MatBadgeModule } from '@angular/material/badge';
|
|
30
29
|
import { MatBottomSheetModule } from '@angular/material/bottom-sheet';
|
|
31
|
-
import * as
|
|
30
|
+
import * as i7 from '@angular/material/button';
|
|
32
31
|
import { MatButtonModule } from '@angular/material/button';
|
|
33
|
-
import * as
|
|
32
|
+
import * as i8 from '@angular/material/card';
|
|
34
33
|
import { MatCardModule } from '@angular/material/card';
|
|
35
|
-
import * as
|
|
34
|
+
import * as i9 from '@angular/material/checkbox';
|
|
36
35
|
import { MatCheckboxModule } from '@angular/material/checkbox';
|
|
37
36
|
import { MatButtonToggleModule } from '@angular/material/button-toggle';
|
|
38
37
|
import { MatStepperModule } from '@angular/material/stepper';
|
|
@@ -41,7 +40,6 @@ import { MatExpansionModule } from '@angular/material/expansion';
|
|
|
41
40
|
import { MatGridListModule } from '@angular/material/grid-list';
|
|
42
41
|
import * as i6 from '@angular/material/icon';
|
|
43
42
|
import { MatIconModule } from '@angular/material/icon';
|
|
44
|
-
import * as i11$1 from '@angular/material/list';
|
|
45
43
|
import { MatListModule } from '@angular/material/list';
|
|
46
44
|
import { MatDatepickerModule } from '@angular/material/datepicker';
|
|
47
45
|
import { MatPaginatorModule } from '@angular/material/paginator';
|
|
@@ -55,19 +53,19 @@ import { MatNativeDateModule, MatRippleModule } from '@angular/material/core';
|
|
|
55
53
|
import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
|
|
56
54
|
import { MatRadioModule } from '@angular/material/radio';
|
|
57
55
|
import { MatSelectModule } from '@angular/material/select';
|
|
58
|
-
import * as
|
|
56
|
+
import * as i11 from '@angular/material/sidenav';
|
|
59
57
|
import { MatSidenavModule } from '@angular/material/sidenav';
|
|
60
58
|
import { MatSliderModule } from '@angular/material/slider';
|
|
61
59
|
import { MatSlideToggleModule } from '@angular/material/slide-toggle';
|
|
62
60
|
import { MatSnackBarModule } from '@angular/material/snack-bar';
|
|
63
61
|
import { MatSortModule } from '@angular/material/sort';
|
|
64
62
|
import { MatTableModule } from '@angular/material/table';
|
|
65
|
-
import * as
|
|
63
|
+
import * as i12 from '@angular/material/tabs';
|
|
66
64
|
import { MatTabsModule } from '@angular/material/tabs';
|
|
67
65
|
import { MatToolbarModule } from '@angular/material/toolbar';
|
|
68
66
|
import { MatTooltipModule } from '@angular/material/tooltip';
|
|
69
67
|
import { MatTreeModule } from '@angular/material/tree';
|
|
70
|
-
import * as
|
|
68
|
+
import * as i3 from '@angular/common';
|
|
71
69
|
import { CommonModule } from '@angular/common';
|
|
72
70
|
import * as i1$1 from '@ngneat/hot-toast';
|
|
73
71
|
import * as i2 from '@angular/forms';
|
|
@@ -77,21 +75,14 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
|
77
75
|
import * as i1$2 from 'ngx-progressbar';
|
|
78
76
|
import { NgProgressModule } from 'ngx-progressbar';
|
|
79
77
|
import * as _ from 'lodash';
|
|
80
|
-
import * as i2$
|
|
78
|
+
import * as i2$1 from '@angular/material/form-field';
|
|
81
79
|
import { MatFormFieldModule } from '@angular/material/form-field';
|
|
82
|
-
import * as i3 from '@ng-matero/extensions/grid';
|
|
80
|
+
import * as i3$1 from '@ng-matero/extensions/grid';
|
|
83
81
|
import { MtxGridModule } from '@ng-matero/extensions/grid';
|
|
84
82
|
import * as i1$3 from 'static-columns/websql';
|
|
85
83
|
import { StaticColumnsModule } from 'static-columns/websql';
|
|
86
|
-
import * as
|
|
84
|
+
import * as i5 from 'ngx-scrollbar';
|
|
87
85
|
import { NgScrollbarModule } from 'ngx-scrollbar';
|
|
88
|
-
import * as i1$4 from '@angular/router';
|
|
89
|
-
import 'brace';
|
|
90
|
-
import 'brace/mode/css';
|
|
91
|
-
import 'brace/mode/typescript';
|
|
92
|
-
import 'brace/theme/github';
|
|
93
|
-
import * as i13 from 'ngx-pipes';
|
|
94
|
-
import { NgArrayPipesModule } from 'ngx-pipes';
|
|
95
86
|
|
|
96
87
|
var Symbols;
|
|
97
88
|
(function (Symbols) {
|
|
@@ -157,6 +148,7 @@ var Symbols;
|
|
|
157
148
|
repository: `repository:options`,
|
|
158
149
|
provider: `provider:options`,
|
|
159
150
|
subscriber: `subscriber:options`,
|
|
151
|
+
migration: `migration:options`,
|
|
160
152
|
},
|
|
161
153
|
};
|
|
162
154
|
Symbols.old = {
|
|
@@ -566,6 +558,7 @@ var Models;
|
|
|
566
558
|
ClassType["REPOSITORY"] = "REPOSITORY";
|
|
567
559
|
ClassType["PROVIDER"] = "PROVIDER";
|
|
568
560
|
ClassType["SUBSCRIBER"] = "SUBSCRIBER";
|
|
561
|
+
ClassType["MIGRATION"] = "MIGRATION";
|
|
569
562
|
})(ClassType = Models.ClassType || (Models.ClassType = {}));
|
|
570
563
|
Models.ClassTypeKey = {
|
|
571
564
|
[ClassType.ENTITY]: 'entities',
|
|
@@ -573,7 +566,32 @@ var Models;
|
|
|
573
566
|
[ClassType.REPOSITORY]: 'repositories',
|
|
574
567
|
[ClassType.PROVIDER]: 'providers',
|
|
575
568
|
[ClassType.SUBSCRIBER]: 'subscribers',
|
|
569
|
+
[ClassType.MIGRATION]: 'migrations',
|
|
576
570
|
};
|
|
571
|
+
class DatabaseConfigTypeOrm {
|
|
572
|
+
}
|
|
573
|
+
Models.DatabaseConfigTypeOrm = DatabaseConfigTypeOrm;
|
|
574
|
+
class DatabaseConfig extends DatabaseConfigTypeOrm {
|
|
575
|
+
static from(databasePartialConfig) {
|
|
576
|
+
return _$1.merge(new DatabaseConfig(), databasePartialConfig);
|
|
577
|
+
}
|
|
578
|
+
get databaseConfigTypeORM() {
|
|
579
|
+
const result = _$1.cloneDeep(this);
|
|
580
|
+
if (result.recreateMode) {
|
|
581
|
+
if (result.recreateMode === 'DROP_DB+MIGRATIONS') {
|
|
582
|
+
result.synchronize = true;
|
|
583
|
+
result.dropSchema = true;
|
|
584
|
+
}
|
|
585
|
+
else if (result.recreateMode === 'PRESERVE_DATA+MIGRATIONS') {
|
|
586
|
+
result.synchronize = false;
|
|
587
|
+
result.dropSchema = false;
|
|
588
|
+
}
|
|
589
|
+
}
|
|
590
|
+
delete result.recreateMode;
|
|
591
|
+
return result;
|
|
592
|
+
}
|
|
593
|
+
}
|
|
594
|
+
Models.DatabaseConfig = DatabaseConfig;
|
|
577
595
|
class DecoratorAbstractOpt {
|
|
578
596
|
}
|
|
579
597
|
Models.DecoratorAbstractOpt = DecoratorAbstractOpt;
|
|
@@ -764,6 +782,9 @@ var Http;
|
|
|
764
782
|
;
|
|
765
783
|
({}); // @--end-of-file-for-module=taon lib/decorators/http/http-decorators.ts
|
|
766
784
|
|
|
785
|
+
/**
|
|
786
|
+
* Controller decorator
|
|
787
|
+
*/
|
|
767
788
|
function TaonController(options) {
|
|
768
789
|
return function (constructor) {
|
|
769
790
|
ClassHelpers.setName(constructor, options?.className);
|
|
@@ -942,7 +963,8 @@ class BaseInjector {
|
|
|
942
963
|
|
|
943
964
|
let BaseController = class BaseController extends BaseInjector {
|
|
944
965
|
/**
|
|
945
|
-
*
|
|
966
|
+
* THIS ONLY WORKS IF NO MIGRATIONS PROVIDED IN CONFIG
|
|
967
|
+
* Purpose: init example data for db.
|
|
946
968
|
*/
|
|
947
969
|
initExampleDbData() {
|
|
948
970
|
return void 0;
|
|
@@ -1176,7 +1198,7 @@ BaseCrudController = __decorate([
|
|
|
1176
1198
|
class BaseClass {
|
|
1177
1199
|
/**
|
|
1178
1200
|
* class initialization hook
|
|
1179
|
-
* taon after class
|
|
1201
|
+
* taon after class instance creation
|
|
1180
1202
|
*/
|
|
1181
1203
|
async _() { }
|
|
1182
1204
|
clone(override) {
|
|
@@ -1279,6 +1301,9 @@ BaseAbstractEntity = __decorate([
|
|
|
1279
1301
|
;
|
|
1280
1302
|
({}); // @--end-of-file-for-module=taon lib/base-classes/base-abstract-entity.ts
|
|
1281
1303
|
|
|
1304
|
+
/**
|
|
1305
|
+
* Repository decorator
|
|
1306
|
+
*/
|
|
1282
1307
|
function TaonRepository(options) {
|
|
1283
1308
|
return function (constructor) {
|
|
1284
1309
|
Reflect.defineMetadata(Symbols.metadata.options.repository, options, constructor);
|
|
@@ -1301,20 +1326,20 @@ let BaseRepository = class BaseRepository extends BaseInjector {
|
|
|
1301
1326
|
}
|
|
1302
1327
|
get dbQuery() {
|
|
1303
1328
|
if (!this.__dbQuery) {
|
|
1304
|
-
if (!this.
|
|
1329
|
+
if (!this.ctx) {
|
|
1305
1330
|
return; // TODO
|
|
1306
1331
|
throw new Error(`[BaseRepository] Context not inited for class ${ClassHelpers.getName(this)}`);
|
|
1307
1332
|
}
|
|
1308
|
-
const connection = this.
|
|
1333
|
+
const connection = this.ctx?.connection;
|
|
1309
1334
|
if (!connection) {
|
|
1310
|
-
throw new Error(`[BaseRepository] Database not inited for context ${this.
|
|
1335
|
+
throw new Error(`[BaseRepository] Database not inited for context ${this.ctx?.contextName}`);
|
|
1311
1336
|
}
|
|
1312
1337
|
this.__dbQuery = new MySqlQuerySource(connection);
|
|
1313
1338
|
}
|
|
1314
1339
|
return this.__dbQuery;
|
|
1315
1340
|
}
|
|
1316
1341
|
get connection() {
|
|
1317
|
-
return this.
|
|
1342
|
+
return this.ctx?.connection;
|
|
1318
1343
|
}
|
|
1319
1344
|
get repository() {
|
|
1320
1345
|
return this.__repository;
|
|
@@ -1719,25 +1744,19 @@ class BaseProvider extends BaseInjector {
|
|
|
1719
1744
|
;
|
|
1720
1745
|
({}); // @--end-of-file-for-module=taon lib/base-classes/base-provider.ts
|
|
1721
1746
|
|
|
1722
|
-
const globalPublicStorage = Helpers.isBrowser ? window : global;
|
|
1723
|
-
;
|
|
1724
|
-
({}); // @--end-of-file-for-module=taon lib/storage.ts
|
|
1725
|
-
|
|
1726
1747
|
const ENV$2 = Helpers.isBrowser ? window['ENV'] : global['ENV'];
|
|
1727
|
-
class
|
|
1748
|
+
class TaonAdminService {
|
|
1749
|
+
static get Instance() {
|
|
1750
|
+
return this._instance;
|
|
1751
|
+
}
|
|
1728
1752
|
constructor() {
|
|
1729
1753
|
this.scrollableEnabled = false; // TOOD false by default
|
|
1730
1754
|
this.onEditMode = new Subject();
|
|
1731
1755
|
this.onEditMode$ = this.onEditMode.asObservable();
|
|
1732
1756
|
this.enabledTabs = [];
|
|
1757
|
+
TaonAdminService._instance = this;
|
|
1733
1758
|
this.scrollableEnabled = !!ENV$2?.useGlobalNgxScrollbar;
|
|
1734
1759
|
}
|
|
1735
|
-
static get Instance() {
|
|
1736
|
-
if (!globalPublicStorage[config.frameworkNames.productionFrameworkName]) {
|
|
1737
|
-
globalPublicStorage[config.frameworkNames.productionFrameworkName] = new TaonAdmin();
|
|
1738
|
-
}
|
|
1739
|
-
return globalPublicStorage[config.frameworkNames.productionFrameworkName];
|
|
1740
|
-
}
|
|
1741
1760
|
setEditMode(value) {
|
|
1742
1761
|
this.onEditMode.next(value);
|
|
1743
1762
|
}
|
|
@@ -1753,26 +1772,26 @@ class TaonAdmin {
|
|
|
1753
1772
|
this.adminPanelIsOpen = true;
|
|
1754
1773
|
}
|
|
1755
1774
|
logout() { }
|
|
1756
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type:
|
|
1757
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type:
|
|
1775
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1776
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminService, providedIn: 'root' }); }
|
|
1758
1777
|
}
|
|
1759
1778
|
__decorate([
|
|
1760
|
-
Stor.property.in.localstorage.for(
|
|
1779
|
+
(Stor.property.in.localstorage.for(TaonAdminService).withDefaultValue(false)),
|
|
1761
1780
|
__metadata("design:type", Boolean)
|
|
1762
|
-
],
|
|
1781
|
+
], TaonAdminService.prototype, "adminPanelIsOpen", void 0);
|
|
1763
1782
|
__decorate([
|
|
1764
|
-
Stor.property.in.localstorage.for(
|
|
1783
|
+
(Stor.property.in.localstorage.for(TaonAdminService).withDefaultValue(false)),
|
|
1765
1784
|
__metadata("design:type", Boolean)
|
|
1766
|
-
],
|
|
1785
|
+
], TaonAdminService.prototype, "draggablePopupMode", void 0);
|
|
1767
1786
|
__decorate([
|
|
1768
|
-
Stor.property.in.localstorage.for(
|
|
1787
|
+
(Stor.property.in.localstorage.for(TaonAdminService).withDefaultValue(false)),
|
|
1769
1788
|
__metadata("design:type", Boolean)
|
|
1770
|
-
],
|
|
1789
|
+
], TaonAdminService.prototype, "draggablePopupModeFullScreen", void 0);
|
|
1771
1790
|
__decorate([
|
|
1772
|
-
Stor.property.in.localstorage.for(
|
|
1791
|
+
(Stor.property.in.localstorage.for(TaonAdminService).withDefaultValue(false)),
|
|
1773
1792
|
__metadata("design:type", Boolean)
|
|
1774
|
-
],
|
|
1775
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type:
|
|
1793
|
+
], TaonAdminService.prototype, "keepWebsqlDbDataAfterReload", void 0);
|
|
1794
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminService, decorators: [{
|
|
1776
1795
|
type: Injectable,
|
|
1777
1796
|
args: [{ providedIn: 'root' }]
|
|
1778
1797
|
}], ctorParameters: () => [] });
|
|
@@ -2765,11 +2784,284 @@ class RealtimeCore {
|
|
|
2765
2784
|
;
|
|
2766
2785
|
({}); // @--end-of-file-for-module=taon lib/realtime/realtime-core.ts
|
|
2767
2786
|
|
|
2787
|
+
class ContextDbMigrations {
|
|
2788
|
+
constructor(ctx) {
|
|
2789
|
+
this.ctx = ctx;
|
|
2790
|
+
this.DEFAULT_MIGRATION_TABLE_NAME = 'TAON_MIGRATION_META';
|
|
2791
|
+
this.MIGRATION_STATUS_COMPLETED = 'completed';
|
|
2792
|
+
this.MIGRATION_STATUS_PENDING = 'pending';
|
|
2793
|
+
this.table = new Table({
|
|
2794
|
+
name: this.DEFAULT_MIGRATION_TABLE_NAME,
|
|
2795
|
+
columns: [
|
|
2796
|
+
{
|
|
2797
|
+
name: 'id',
|
|
2798
|
+
type: 'integer',
|
|
2799
|
+
isPrimary: true, // Mark it as the primary key
|
|
2800
|
+
isGenerated: true, // Enable auto-generation
|
|
2801
|
+
generationStrategy: 'increment', // Use auto-increment strategy
|
|
2802
|
+
},
|
|
2803
|
+
{
|
|
2804
|
+
name: 'name',
|
|
2805
|
+
type: 'varchar',
|
|
2806
|
+
length: '255',
|
|
2807
|
+
isUnique: true, // Ensure the name is unique
|
|
2808
|
+
isNullable: false, // Ensure this field is required
|
|
2809
|
+
},
|
|
2810
|
+
{
|
|
2811
|
+
name: 'context',
|
|
2812
|
+
type: 'varchar',
|
|
2813
|
+
length: '255',
|
|
2814
|
+
isNullable: false, // Optional context for migrations (e.g., tenant or module name)
|
|
2815
|
+
},
|
|
2816
|
+
{
|
|
2817
|
+
name: 'applied_at',
|
|
2818
|
+
type: 'timestamp',
|
|
2819
|
+
default: 'CURRENT_TIMESTAMP', // Automatically set the timestamp
|
|
2820
|
+
isNullable: true,
|
|
2821
|
+
},
|
|
2822
|
+
{
|
|
2823
|
+
name: 'status',
|
|
2824
|
+
type: 'varchar',
|
|
2825
|
+
length: '50',
|
|
2826
|
+
default: `'${this.MIGRATION_STATUS_COMPLETED}'`,
|
|
2827
|
+
isNullable: false,
|
|
2828
|
+
},
|
|
2829
|
+
],
|
|
2830
|
+
});
|
|
2831
|
+
}
|
|
2832
|
+
async ensureMigrationTableExists() {
|
|
2833
|
+
if (this.ctx.remoteHost) {
|
|
2834
|
+
return;
|
|
2835
|
+
}
|
|
2836
|
+
const queryRunner = this.ctx.connection.createQueryRunner();
|
|
2837
|
+
await queryRunner.connect();
|
|
2838
|
+
await queryRunner.startTransaction();
|
|
2839
|
+
const hasTable = await queryRunner.hasTable(this.DEFAULT_MIGRATION_TABLE_NAME);
|
|
2840
|
+
if (hasTable) {
|
|
2841
|
+
this.ctx.logMigrations &&
|
|
2842
|
+
console.log(`Table ${this.DEFAULT_MIGRATION_TABLE_NAME} already exists.`);
|
|
2843
|
+
await queryRunner.commitTransaction();
|
|
2844
|
+
await queryRunner.release();
|
|
2845
|
+
return; // Exit early if the table exists
|
|
2846
|
+
}
|
|
2847
|
+
try {
|
|
2848
|
+
await queryRunner.createTable(this.table);
|
|
2849
|
+
await queryRunner.createIndex(this.DEFAULT_MIGRATION_TABLE_NAME, new TableIndex({
|
|
2850
|
+
name: 'IDX_NAME',
|
|
2851
|
+
columnNames: ['name'],
|
|
2852
|
+
}));
|
|
2853
|
+
await queryRunner.commitTransaction();
|
|
2854
|
+
}
|
|
2855
|
+
catch (error) {
|
|
2856
|
+
this.ctx.logMigrations &&
|
|
2857
|
+
console.error(`Transaction failed [ensureMigrationTableExists]` + `, rolling back:`, error);
|
|
2858
|
+
await queryRunner.rollbackTransaction();
|
|
2859
|
+
}
|
|
2860
|
+
finally {
|
|
2861
|
+
await queryRunner.release();
|
|
2862
|
+
}
|
|
2863
|
+
}
|
|
2864
|
+
async logSelectALl(name, queryRunner) {
|
|
2865
|
+
console.log(name, (await queryRunner.query(`SELECT * FROM ${this.DEFAULT_MIGRATION_TABLE_NAME} WHERE context = $1`, [this.ctx.contextName])).map(m => m.name));
|
|
2866
|
+
}
|
|
2867
|
+
async revertMigrationToTimestamp(timestamp) {
|
|
2868
|
+
if (this.ctx.remoteHost) {
|
|
2869
|
+
return;
|
|
2870
|
+
}
|
|
2871
|
+
if (!UtilsMigrations.isValidTimestamp(timestamp)) {
|
|
2872
|
+
Helpers.throw(`Invalid timestamp provided for migration revert: ${timestamp}`);
|
|
2873
|
+
}
|
|
2874
|
+
const migrationsClassFns = this.ctx
|
|
2875
|
+
.getClassFunByArr(Models.ClassType.MIGRATION)
|
|
2876
|
+
.reverse();
|
|
2877
|
+
const migrationClassesInstancesToRevert = migrationsClassFns
|
|
2878
|
+
.map(classFn => {
|
|
2879
|
+
const timestampFromClassName = Number(UtilsMigrations.getTimestampFromClassName(ClassHelpers.getName(classFn)));
|
|
2880
|
+
if (timestampFromClassName <= timestamp) {
|
|
2881
|
+
return null;
|
|
2882
|
+
}
|
|
2883
|
+
return this.ctx.getInstanceBy(classFn);
|
|
2884
|
+
})
|
|
2885
|
+
.filter(f => !!f)
|
|
2886
|
+
.map(f => f)
|
|
2887
|
+
.filter(migrationInstance => migrationInstance.isReadyToRun());
|
|
2888
|
+
const queryRunner = this.ctx.connection.createQueryRunner();
|
|
2889
|
+
await queryRunner.connect();
|
|
2890
|
+
try {
|
|
2891
|
+
await queryRunner.startTransaction();
|
|
2892
|
+
const appliedMigrationsForContext = await queryRunner.query(`SELECT name FROM ${this.DEFAULT_MIGRATION_TABLE_NAME}
|
|
2893
|
+
WHERE status = $1 AND context = $2`, [this.MIGRATION_STATUS_COMPLETED, this.ctx.contextName]);
|
|
2894
|
+
const appliedMigrationsForContextNames = appliedMigrationsForContext.map(m => m.name);
|
|
2895
|
+
for (const migrationClassInstance of migrationClassesInstancesToRevert) {
|
|
2896
|
+
const migrationName = ClassHelpers.getName(migrationClassInstance);
|
|
2897
|
+
if (!appliedMigrationsForContextNames.includes(migrationName)) {
|
|
2898
|
+
this.ctx.logMigrations &&
|
|
2899
|
+
console.warn(`Skipping migration not marked as applied: ${migrationName}`);
|
|
2900
|
+
continue;
|
|
2901
|
+
}
|
|
2902
|
+
this.ctx.logMigrations &&
|
|
2903
|
+
console.log(`Reverting migration: ${migrationName} , context: ${this.ctx.contextName}`);
|
|
2904
|
+
await migrationClassInstance.down(queryRunner);
|
|
2905
|
+
await queryRunner.query(`DELETE FROM ${this.DEFAULT_MIGRATION_TABLE_NAME} WHERE name = $1`, [migrationName]);
|
|
2906
|
+
}
|
|
2907
|
+
await queryRunner.commitTransaction();
|
|
2908
|
+
this.ctx.logMigrations &&
|
|
2909
|
+
console.log(`Migrations successfully reverted ` +
|
|
2910
|
+
`to the specified timestamp ${timestamp} .`);
|
|
2911
|
+
}
|
|
2912
|
+
catch (error) {
|
|
2913
|
+
this.ctx.logMigrations &&
|
|
2914
|
+
console.error('Transaction failed, rolling back:', error);
|
|
2915
|
+
await queryRunner.rollbackTransaction();
|
|
2916
|
+
}
|
|
2917
|
+
finally {
|
|
2918
|
+
await queryRunner.release();
|
|
2919
|
+
}
|
|
2920
|
+
}
|
|
2921
|
+
async clearMigrationTable() {
|
|
2922
|
+
if (this.ctx.remoteHost) {
|
|
2923
|
+
return;
|
|
2924
|
+
}
|
|
2925
|
+
const queryRunner = this.ctx.connection.createQueryRunner();
|
|
2926
|
+
await queryRunner.connect();
|
|
2927
|
+
await queryRunner.startTransaction();
|
|
2928
|
+
try {
|
|
2929
|
+
await queryRunner.clearTable(this.DEFAULT_MIGRATION_TABLE_NAME);
|
|
2930
|
+
await queryRunner.commitTransaction();
|
|
2931
|
+
}
|
|
2932
|
+
catch (error) {
|
|
2933
|
+
this.ctx.logMigrations &&
|
|
2934
|
+
console.error('Transaction failed, rolling back:', error);
|
|
2935
|
+
await queryRunner.rollbackTransaction();
|
|
2936
|
+
}
|
|
2937
|
+
finally {
|
|
2938
|
+
await queryRunner.release();
|
|
2939
|
+
}
|
|
2940
|
+
}
|
|
2941
|
+
async markAllMigrationsAsApplied() {
|
|
2942
|
+
if (this.ctx.remoteHost) {
|
|
2943
|
+
return;
|
|
2944
|
+
}
|
|
2945
|
+
const migrationsClassFns = this.ctx.getClassFunByArr(Models.ClassType.MIGRATION);
|
|
2946
|
+
const migrationClassesInstances = migrationsClassFns
|
|
2947
|
+
.map(classFn => this.ctx.getInstanceBy(classFn))
|
|
2948
|
+
.map(f => f)
|
|
2949
|
+
.filter(migrationInstance => migrationInstance.isReadyToRun());
|
|
2950
|
+
const queryRunner = this.ctx.connection.createQueryRunner();
|
|
2951
|
+
await queryRunner.connect();
|
|
2952
|
+
try {
|
|
2953
|
+
await queryRunner.startTransaction();
|
|
2954
|
+
const allMigrationsInDb = await queryRunner.query(`SELECT name FROM ${this.DEFAULT_MIGRATION_TABLE_NAME}`);
|
|
2955
|
+
const allMigrationInDBNames = allMigrationsInDb.map(m => m.name);
|
|
2956
|
+
for (const instance of migrationClassesInstances) {
|
|
2957
|
+
const migrationName = ClassHelpers.getName(instance);
|
|
2958
|
+
if (allMigrationInDBNames.includes(migrationName)) {
|
|
2959
|
+
this.ctx.logMigrations &&
|
|
2960
|
+
console.log(`Skipping already applied migration: ${migrationName}`);
|
|
2961
|
+
continue;
|
|
2962
|
+
}
|
|
2963
|
+
this.ctx.logMigrations &&
|
|
2964
|
+
console.log(`Marking migration as applied: ${migrationName}`);
|
|
2965
|
+
await queryRunner.query(`INSERT INTO ${this.DEFAULT_MIGRATION_TABLE_NAME} (name, status, context, applied_at) ` +
|
|
2966
|
+
`VALUES ($1, $2, $3, CURRENT_TIMESTAMP)`, [
|
|
2967
|
+
migrationName,
|
|
2968
|
+
this.MIGRATION_STATUS_COMPLETED,
|
|
2969
|
+
instance.ctx.contextName,
|
|
2970
|
+
]);
|
|
2971
|
+
}
|
|
2972
|
+
await queryRunner.query(`UPDATE ${this.DEFAULT_MIGRATION_TABLE_NAME}
|
|
2973
|
+
SET status = $1, applied_at = CURRENT_TIMESTAMP
|
|
2974
|
+
WHERE status = $2`, [this.MIGRATION_STATUS_COMPLETED, this.MIGRATION_STATUS_PENDING]);
|
|
2975
|
+
await queryRunner.commitTransaction();
|
|
2976
|
+
this.ctx.logMigrations &&
|
|
2977
|
+
console.log('All migrations marked as applied.');
|
|
2978
|
+
}
|
|
2979
|
+
catch (error) {
|
|
2980
|
+
this.ctx.logMigrations &&
|
|
2981
|
+
console.error('Failed to mark all migrations as applied, rolling back:', error);
|
|
2982
|
+
await queryRunner.rollbackTransaction();
|
|
2983
|
+
}
|
|
2984
|
+
finally {
|
|
2985
|
+
await queryRunner.release();
|
|
2986
|
+
}
|
|
2987
|
+
}
|
|
2988
|
+
async runAllNotCompletedMigrations() {
|
|
2989
|
+
if (this.ctx.remoteHost) {
|
|
2990
|
+
return;
|
|
2991
|
+
}
|
|
2992
|
+
const migrationsClassFns = this.ctx.getClassFunByArr(Models.ClassType.MIGRATION);
|
|
2993
|
+
const migrationClassesInstances = migrationsClassFns
|
|
2994
|
+
.map(classFn => this.ctx.getInstanceBy(classFn))
|
|
2995
|
+
.map(f => f)
|
|
2996
|
+
.filter(migrationInstance => migrationInstance.isReadyToRun());
|
|
2997
|
+
const queryRunner = this.ctx.connection.createQueryRunner();
|
|
2998
|
+
await queryRunner.connect();
|
|
2999
|
+
try {
|
|
3000
|
+
await queryRunner.startTransaction();
|
|
3001
|
+
const appliedMigrationsForContext = await queryRunner.query(`SELECT name, status FROM ${this.DEFAULT_MIGRATION_TABLE_NAME} ` +
|
|
3002
|
+
`WHERE context = $1`, [this.ctx.contextName]);
|
|
3003
|
+
const pendingMigrationsForContext = appliedMigrationsForContext.filter(m => m.status === this.MIGRATION_STATUS_PENDING);
|
|
3004
|
+
for (const pendingContextMigration of pendingMigrationsForContext) {
|
|
3005
|
+
const migrationInstance = migrationClassesInstances.find(instance => ClassHelpers.getName(instance) === pendingContextMigration.name);
|
|
3006
|
+
if (!migrationInstance) {
|
|
3007
|
+
this.ctx.logMigrations &&
|
|
3008
|
+
console.warn(`Pending migration ${pendingContextMigration.name} not found in loaded migrations.`);
|
|
3009
|
+
continue;
|
|
3010
|
+
}
|
|
3011
|
+
this.ctx.logMigrations &&
|
|
3012
|
+
console.log(`Completing pending migration: ${pendingContextMigration.name}`);
|
|
3013
|
+
await migrationInstance.up(queryRunner);
|
|
3014
|
+
await queryRunner.query(`UPDATE ${this.DEFAULT_MIGRATION_TABLE_NAME}
|
|
3015
|
+
SET status = $1, applied_at = CURRENT_TIMESTAMP
|
|
3016
|
+
WHERE name = $2`, [this.MIGRATION_STATUS_COMPLETED, pendingContextMigration.name]);
|
|
3017
|
+
}
|
|
3018
|
+
for (const instance of migrationClassesInstances) {
|
|
3019
|
+
const migrationName = ClassHelpers.getName(instance);
|
|
3020
|
+
if (appliedMigrationsForContext.some(m => m.name === migrationName)) {
|
|
3021
|
+
this.ctx.logMigrations &&
|
|
3022
|
+
console.log(`Skipping already applied migration: ${migrationName}`);
|
|
3023
|
+
continue;
|
|
3024
|
+
}
|
|
3025
|
+
this.ctx.logMigrations &&
|
|
3026
|
+
console.log(`Applying new migration: ${migrationName}`);
|
|
3027
|
+
await queryRunner.query(`INSERT INTO ${this.DEFAULT_MIGRATION_TABLE_NAME} (name, status, context, applied_at) ` +
|
|
3028
|
+
`VALUES ($1, $2, $3, NULL)`, [migrationName, this.MIGRATION_STATUS_PENDING, this.ctx.contextName]);
|
|
3029
|
+
try {
|
|
3030
|
+
await instance.up(queryRunner);
|
|
3031
|
+
await queryRunner.query(`UPDATE ${this.DEFAULT_MIGRATION_TABLE_NAME} ` +
|
|
3032
|
+
`SET status = '${this.MIGRATION_STATUS_COMPLETED}', applied_at = CURRENT_TIMESTAMP ` +
|
|
3033
|
+
`WHERE name = $1`, [migrationName]);
|
|
3034
|
+
}
|
|
3035
|
+
catch (error) {
|
|
3036
|
+
this.ctx.logMigrations &&
|
|
3037
|
+
console.error(`Failed to apply migration: ${migrationName}`, error);
|
|
3038
|
+
await queryRunner.query(`DELETE FROM ${this.DEFAULT_MIGRATION_TABLE_NAME} WHERE name = $1`, [migrationName]);
|
|
3039
|
+
throw error; // Rethrow to ensure the transaction is rolled back
|
|
3040
|
+
}
|
|
3041
|
+
}
|
|
3042
|
+
await queryRunner.commitTransaction();
|
|
3043
|
+
}
|
|
3044
|
+
catch (error) {
|
|
3045
|
+
this.ctx.logMigrations &&
|
|
3046
|
+
console.error('Transaction failed, rolling back:', error);
|
|
3047
|
+
await queryRunner.rollbackTransaction();
|
|
3048
|
+
}
|
|
3049
|
+
finally {
|
|
3050
|
+
await queryRunner.release();
|
|
3051
|
+
}
|
|
3052
|
+
}
|
|
3053
|
+
}
|
|
3054
|
+
;
|
|
3055
|
+
({}); // @--end-of-file-for-module=taon lib/context-db-migrations.ts
|
|
3056
|
+
|
|
2768
3057
|
/* eslint-disable @typescript-eslint/typedef */
|
|
2769
3058
|
class EndpointContext {
|
|
2770
3059
|
static initNgZone(ngZone) {
|
|
2771
3060
|
this.ngZone = ngZone;
|
|
2772
3061
|
}
|
|
3062
|
+
get isRunOrRevertOnlyMigrationAppStart() {
|
|
3063
|
+
return !!(this.onlyMigrationRun || this.onlyMigrationRevertToTimestamp);
|
|
3064
|
+
}
|
|
2773
3065
|
get realtimeClient() {
|
|
2774
3066
|
return this.realtime.client;
|
|
2775
3067
|
}
|
|
@@ -2800,6 +3092,12 @@ class EndpointContext {
|
|
|
2800
3092
|
}
|
|
2801
3093
|
return this.config?.logs === true;
|
|
2802
3094
|
}
|
|
3095
|
+
get logMigrations() {
|
|
3096
|
+
if (_$1.isObject(this.config?.logs)) {
|
|
3097
|
+
return !!this.config.logs.migrations;
|
|
3098
|
+
}
|
|
3099
|
+
return this.config?.logs === true;
|
|
3100
|
+
}
|
|
2803
3101
|
constructor(originalConfig, configFn) {
|
|
2804
3102
|
this.originalConfig = originalConfig;
|
|
2805
3103
|
this.configFn = configFn;
|
|
@@ -2809,6 +3107,7 @@ class EndpointContext {
|
|
|
2809
3107
|
* (with init() function )
|
|
2810
3108
|
*/
|
|
2811
3109
|
this.inited = false;
|
|
3110
|
+
this.dbMigrations = new ContextDbMigrations(this);
|
|
2812
3111
|
this.localInstaceObjSymbol = Symbol('localInstaceObjSymbol');
|
|
2813
3112
|
/**
|
|
2814
3113
|
* all instances of classes from context
|
|
@@ -2823,12 +3122,15 @@ class EndpointContext {
|
|
|
2823
3122
|
Models.ClassType.PROVIDER,
|
|
2824
3123
|
Models.ClassType.REPOSITORY,
|
|
2825
3124
|
Models.ClassType.SUBSCRIBER,
|
|
3125
|
+
Models.ClassType.MIGRATION,
|
|
2826
3126
|
];
|
|
2827
3127
|
this.allTypesfromContexts = [
|
|
2828
3128
|
...this.injectableTypesfromContexts,
|
|
2829
3129
|
Models.ClassType.ENTITY,
|
|
2830
3130
|
];
|
|
2831
3131
|
this.expressApp = {};
|
|
3132
|
+
this.onlyMigrationRun = false;
|
|
3133
|
+
this.onlyMigrationRevertToTimestamp = undefined;
|
|
2832
3134
|
this.entitiesTriggers = {};
|
|
2833
3135
|
this.cloneClassWithNewMetadata = ({ BaseClass, className, config, ctx, classType, }) => {
|
|
2834
3136
|
const cloneClass = () => {
|
|
@@ -2896,9 +3198,16 @@ class EndpointContext {
|
|
|
2896
3198
|
};
|
|
2897
3199
|
}
|
|
2898
3200
|
async init(options) {
|
|
2899
|
-
const { initFromRecrusiveContextResovle, overrideHost, overrideRemoteHost, } = options || {}; // TODO use it ?
|
|
3201
|
+
const { initFromRecrusiveContextResovle, overrideHost, overrideRemoteHost, onlyMigrationRun, onlyMigrationRevertToTimestamp, } = options || {}; // TODO use it ?
|
|
2900
3202
|
this.inited = true;
|
|
3203
|
+
// @ts-ignore
|
|
3204
|
+
this.onlyMigrationRun = onlyMigrationRun;
|
|
3205
|
+
// @ts-ignore
|
|
3206
|
+
this.onlyMigrationRevertToTimestamp = onlyMigrationRevertToTimestamp;
|
|
2901
3207
|
this.config = this.configFn(ENV$1);
|
|
3208
|
+
if (_$1.isObject(this.config.database)) {
|
|
3209
|
+
this.config.database = Models.DatabaseConfig.from(this.config.database).databaseConfigTypeORM;
|
|
3210
|
+
}
|
|
2902
3211
|
if (overrideHost && overrideRemoteHost) {
|
|
2903
3212
|
Helpers.throw(`[taon-config] You can't have overrideHost and overrideRemoteHost at the same time`);
|
|
2904
3213
|
}
|
|
@@ -2964,6 +3273,7 @@ class EndpointContext {
|
|
|
2964
3273
|
this.config.repositories = this.config.repositories || {};
|
|
2965
3274
|
this.config.providers = this.config.providers || {};
|
|
2966
3275
|
this.config.subscribers = this.config.subscribers || {};
|
|
3276
|
+
this.config.migrations = this.config.migrations || {};
|
|
2967
3277
|
this.config.entities = {
|
|
2968
3278
|
...(await this.getRecrusiveClassesfromContextsObj(Models.ClassType.ENTITY)),
|
|
2969
3279
|
...this.config.entities,
|
|
@@ -2984,6 +3294,10 @@ class EndpointContext {
|
|
|
2984
3294
|
...(await this.getRecrusiveClassesfromContextsObj(Models.ClassType.REPOSITORY)),
|
|
2985
3295
|
...this.config.repositories,
|
|
2986
3296
|
};
|
|
3297
|
+
this.config.migrations = {
|
|
3298
|
+
...(await this.getRecrusiveClassesfromContextsObj(Models.ClassType.MIGRATION)),
|
|
3299
|
+
...this.config.migrations,
|
|
3300
|
+
};
|
|
2987
3301
|
this.config.controllers = this.cloneClassesObjWithNewMetadata({
|
|
2988
3302
|
classesInput: this.config.controllers,
|
|
2989
3303
|
config: this.config,
|
|
@@ -3008,6 +3322,12 @@ class EndpointContext {
|
|
|
3008
3322
|
ctx: this,
|
|
3009
3323
|
classType: Models.ClassType.SUBSCRIBER,
|
|
3010
3324
|
});
|
|
3325
|
+
this.config.migrations = this.cloneClassesObjWithNewMetadata({
|
|
3326
|
+
classesInput: this.config.migrations,
|
|
3327
|
+
config: this.config,
|
|
3328
|
+
ctx: this,
|
|
3329
|
+
classType: Models.ClassType.MIGRATION,
|
|
3330
|
+
});
|
|
3011
3331
|
for (const classTypeName of this.injectableTypesfromContexts) {
|
|
3012
3332
|
this.classInstancesByNameObj[classTypeName] = {};
|
|
3013
3333
|
this.objWithClassesInstancesArr[classTypeName] = [];
|
|
@@ -3015,35 +3335,37 @@ class EndpointContext {
|
|
|
3015
3335
|
for (const classTypeName of this.injectableTypesfromContexts) {
|
|
3016
3336
|
await this.createInstances(this.config[Models.ClassTypeKey[classTypeName]], classTypeName);
|
|
3017
3337
|
}
|
|
3018
|
-
if (
|
|
3019
|
-
|
|
3020
|
-
|
|
3021
|
-
|
|
3022
|
-
|
|
3023
|
-
|
|
3024
|
-
|
|
3025
|
-
|
|
3026
|
-
|
|
3027
|
-
|
|
3028
|
-
|
|
3029
|
-
|
|
3030
|
-
|
|
3031
|
-
|
|
3032
|
-
|
|
3033
|
-
|
|
3034
|
-
|
|
3035
|
-
|
|
3036
|
-
|
|
3037
|
-
|
|
3038
|
-
|
|
3039
|
-
|
|
3040
|
-
|
|
3041
|
-
|
|
3042
|
-
|
|
3043
|
-
|
|
3044
|
-
|
|
3045
|
-
|
|
3046
|
-
|
|
3338
|
+
if (!this.isRunOrRevertOnlyMigrationAppStart) {
|
|
3339
|
+
if (this.mode === 'backend-frontend(tcp+udp)' && !this.config.abstract) {
|
|
3340
|
+
/* */
|
|
3341
|
+
/* */
|
|
3342
|
+
/* */
|
|
3343
|
+
/* */
|
|
3344
|
+
/* */
|
|
3345
|
+
/* */
|
|
3346
|
+
/* */
|
|
3347
|
+
/* */
|
|
3348
|
+
/* */
|
|
3349
|
+
/* */
|
|
3350
|
+
/* */
|
|
3351
|
+
/* */
|
|
3352
|
+
/* */
|
|
3353
|
+
/* */
|
|
3354
|
+
/* */
|
|
3355
|
+
/* */
|
|
3356
|
+
/* */
|
|
3357
|
+
/* */
|
|
3358
|
+
/* */
|
|
3359
|
+
}
|
|
3360
|
+
if (!this.config.abstract) {
|
|
3361
|
+
this.disabledRealtime = !!this.config.disabledRealtime;
|
|
3362
|
+
/* */
|
|
3363
|
+
/* */
|
|
3364
|
+
/* */
|
|
3365
|
+
/* */
|
|
3366
|
+
/* */
|
|
3367
|
+
this.realtime = new RealtimeCore(this);
|
|
3368
|
+
}
|
|
3047
3369
|
}
|
|
3048
3370
|
if (this.config.abstract) {
|
|
3049
3371
|
this.logFramework &&
|
|
@@ -3064,73 +3386,59 @@ class EndpointContext {
|
|
|
3064
3386
|
});
|
|
3065
3387
|
}
|
|
3066
3388
|
getAutoGeneratedConfig() {
|
|
3067
|
-
let databaseConfig;
|
|
3068
|
-
if (
|
|
3389
|
+
let databaseConfig = Models.DatabaseConfig.from({});
|
|
3390
|
+
if (UtilsOs.isRunningInDocker()) {
|
|
3069
3391
|
Helpers.info('Running in docker, using in mysql database');
|
|
3070
|
-
databaseConfig = {
|
|
3071
|
-
database: `
|
|
3392
|
+
databaseConfig = Models.DatabaseConfig.from({
|
|
3393
|
+
database: `db-${this.contextName}.sqlite`,
|
|
3072
3394
|
type: 'mysql',
|
|
3073
|
-
|
|
3074
|
-
synchronize: true,
|
|
3075
|
-
dropSchema: true,
|
|
3395
|
+
recreateMode: 'PRESERVE_DATA+MIGRATIONS',
|
|
3076
3396
|
logging: this.logDb,
|
|
3077
3397
|
databasePort: 3306,
|
|
3078
3398
|
databaseHost: 'localhost',
|
|
3079
3399
|
databaseUsername: 'root',
|
|
3080
3400
|
databasePassword: 'admin',
|
|
3081
|
-
};
|
|
3401
|
+
});
|
|
3082
3402
|
}
|
|
3083
3403
|
else {
|
|
3084
3404
|
this.logFramework &&
|
|
3085
3405
|
Helpers.info(`[taon][database] Automatically resolving database config for mode ${this.mode}`);
|
|
3086
3406
|
switch (this.mode) {
|
|
3087
3407
|
case 'backend-frontend(ipc-electron)':
|
|
3088
|
-
|
|
3089
|
-
location: `
|
|
3408
|
+
databaseConfig = Models.DatabaseConfig.from({
|
|
3409
|
+
location: `db-${this.contextName}.sqlite`,
|
|
3090
3410
|
type: 'sqljs',
|
|
3091
|
-
|
|
3092
|
-
synchronize: true,
|
|
3093
|
-
dropSchema: true,
|
|
3411
|
+
recreateMode: 'DROP_DB+MIGRATIONS',
|
|
3094
3412
|
logging: this.logDb,
|
|
3095
|
-
};
|
|
3413
|
+
});
|
|
3096
3414
|
break;
|
|
3097
3415
|
case 'backend-frontend(websql-electron)':
|
|
3098
3416
|
case 'backend-frontend(websql)':
|
|
3099
|
-
|
|
3100
|
-
|
|
3417
|
+
let keepWebsqlDbDataAfterReload = false;
|
|
3418
|
+
keepWebsqlDbDataAfterReload =
|
|
3419
|
+
TaonAdminService.Instance?.keepWebsqlDbDataAfterReload; // TODO @LAST
|
|
3420
|
+
databaseConfig = databaseConfig = Models.DatabaseConfig.from({
|
|
3421
|
+
location: `db-${this.contextName}.sqlite`,
|
|
3101
3422
|
type: 'sqljs',
|
|
3102
3423
|
useLocalForage: true, // !!window['localforage'], // TODO this need to be checked in runtime
|
|
3103
|
-
|
|
3104
|
-
|
|
3105
|
-
|
|
3424
|
+
recreateMode: keepWebsqlDbDataAfterReload
|
|
3425
|
+
? 'PRESERVE_DATA+MIGRATIONS'
|
|
3426
|
+
: 'DROP_DB+MIGRATIONS',
|
|
3106
3427
|
logging: this.logDb,
|
|
3107
|
-
};
|
|
3108
|
-
let keepWebsqlDbDataAfterReload = false;
|
|
3109
|
-
keepWebsqlDbDataAfterReload =
|
|
3110
|
-
TaonAdmin.Instance.keepWebsqlDbDataAfterReload;
|
|
3111
|
-
if (keepWebsqlDbDataAfterReload) {
|
|
3112
|
-
databaseConfig.dropSchema = false;
|
|
3113
|
-
delete databaseConfig.synchronize; // false is not auto synchonize - from what I understand
|
|
3114
|
-
}
|
|
3115
|
-
else {
|
|
3116
|
-
databaseConfig.dropSchema = true;
|
|
3117
|
-
databaseConfig.synchronize = true;
|
|
3118
|
-
}
|
|
3428
|
+
});
|
|
3119
3429
|
break;
|
|
3120
3430
|
case 'backend-frontend(tcp+udp)':
|
|
3121
|
-
databaseConfig = {
|
|
3122
|
-
database: `context-db-${
|
|
3123
|
-
location: `
|
|
3431
|
+
databaseConfig = Models.DatabaseConfig.from({
|
|
3432
|
+
database: `context-db-${this.contextName}`,
|
|
3433
|
+
location: `db-${this.contextName}.sqlite`,
|
|
3124
3434
|
type: 'sqljs',
|
|
3125
|
-
|
|
3126
|
-
synchronize: true,
|
|
3127
|
-
dropSchema: true,
|
|
3435
|
+
recreateMode: 'DROP_DB+MIGRATIONS',
|
|
3128
3436
|
logging: this.logDb,
|
|
3129
|
-
};
|
|
3437
|
+
});
|
|
3130
3438
|
break;
|
|
3131
3439
|
}
|
|
3132
3440
|
}
|
|
3133
|
-
return databaseConfig;
|
|
3441
|
+
return databaseConfig.databaseConfigTypeORM;
|
|
3134
3442
|
}
|
|
3135
3443
|
get ngZone() {
|
|
3136
3444
|
return EndpointContext.ngZone;
|
|
@@ -3290,6 +3598,8 @@ class EndpointContext {
|
|
|
3290
3598
|
return this.config.repositories;
|
|
3291
3599
|
case Models.ClassType.SUBSCRIBER:
|
|
3292
3600
|
return this.config.subscribers;
|
|
3601
|
+
case Models.ClassType.MIGRATION:
|
|
3602
|
+
return this.config.migrations;
|
|
3293
3603
|
}
|
|
3294
3604
|
}
|
|
3295
3605
|
isCLassType(classType, classFn) {
|
|
@@ -3328,7 +3638,7 @@ class EndpointContext {
|
|
|
3328
3638
|
}
|
|
3329
3639
|
}
|
|
3330
3640
|
async reinitControllers() {
|
|
3331
|
-
if (this.remoteHost) {
|
|
3641
|
+
if (this.remoteHost || Object.keys(this.config.migrations).length > 0) {
|
|
3332
3642
|
return;
|
|
3333
3643
|
}
|
|
3334
3644
|
const controllers = this.getClassesInstancesArrBy(Models.ClassType.CONTROLLER);
|
|
@@ -3350,6 +3660,7 @@ class EndpointContext {
|
|
|
3350
3660
|
Models.ClassType.REPOSITORY,
|
|
3351
3661
|
Models.ClassType.CONTROLLER,
|
|
3352
3662
|
Models.ClassType.ENTITY,
|
|
3663
|
+
Models.ClassType.MIGRATION,
|
|
3353
3664
|
]) {
|
|
3354
3665
|
for (const classFun of this.getClassFunByArr(classTypeName)) {
|
|
3355
3666
|
if (_$1.isFunction(classFun._)) {
|
|
@@ -3364,6 +3675,7 @@ class EndpointContext {
|
|
|
3364
3675
|
Models.ClassType.PROVIDER,
|
|
3365
3676
|
Models.ClassType.REPOSITORY,
|
|
3366
3677
|
Models.ClassType.CONTROLLER,
|
|
3678
|
+
Models.ClassType.MIGRATION,
|
|
3367
3679
|
]) {
|
|
3368
3680
|
for (const ctrl of this.getClassesInstancesArrBy(classTypeName)) {
|
|
3369
3681
|
if (_$1.isFunction(ctrl._)) {
|
|
@@ -3447,14 +3759,10 @@ class EndpointContext {
|
|
|
3447
3759
|
if (this.remoteHost) {
|
|
3448
3760
|
return;
|
|
3449
3761
|
}
|
|
3450
|
-
const entities =
|
|
3451
|
-
? this.config.override.entities
|
|
3452
|
-
: this.getClassFunByArr(Models.ClassType.ENTITY)).map(entityFn => {
|
|
3762
|
+
const entities = this.getClassFunByArr(Models.ClassType.ENTITY).map(entityFn => {
|
|
3453
3763
|
return ClassHelpers.getOrginalClass(entityFn);
|
|
3454
3764
|
});
|
|
3455
|
-
const subscribers = this.
|
|
3456
|
-
? this.config.override.subscribers
|
|
3457
|
-
: this.getClassFunByArr(Models.ClassType.SUBSCRIBER);
|
|
3765
|
+
const subscribers = this.getClassFunByArr(Models.ClassType.SUBSCRIBER);
|
|
3458
3766
|
const dataSourceDbConfig = _$1.isObject(this.databaseConfig)
|
|
3459
3767
|
? {
|
|
3460
3768
|
type: this.databaseConfig.type,
|
|
@@ -3466,9 +3774,15 @@ class EndpointContext {
|
|
|
3466
3774
|
useLocalForage: this.databaseConfig.useLocalForage,
|
|
3467
3775
|
entities,
|
|
3468
3776
|
subscribers,
|
|
3469
|
-
synchronize: this.
|
|
3470
|
-
|
|
3471
|
-
|
|
3777
|
+
synchronize: this.isRunOrRevertOnlyMigrationAppStart
|
|
3778
|
+
? false
|
|
3779
|
+
: this.databaseConfig.synchronize,
|
|
3780
|
+
autoSave: !_$1.isNil(this.databaseConfig.autoSave)
|
|
3781
|
+
? this.databaseConfig.autoSave
|
|
3782
|
+
: !UtilsOs.isRunningInDocker(), // in docker I am using mysql or posgress
|
|
3783
|
+
dropSchema: this.isRunOrRevertOnlyMigrationAppStart
|
|
3784
|
+
? false
|
|
3785
|
+
: this.databaseConfig.dropSchema,
|
|
3472
3786
|
logging: !!this.databaseConfig.logging,
|
|
3473
3787
|
location: this.databaseConfig.location,
|
|
3474
3788
|
}
|
|
@@ -3493,7 +3807,7 @@ class EndpointContext {
|
|
|
3493
3807
|
/* */
|
|
3494
3808
|
/* */
|
|
3495
3809
|
}
|
|
3496
|
-
(this.logDb || this.logFramework)
|
|
3810
|
+
if (this.logDb || this.logFramework) {
|
|
3497
3811
|
console.info(`
|
|
3498
3812
|
|
|
3499
3813
|
CONTECTION OK for ${this.contextName} - ${this.mode}
|
|
@@ -3501,13 +3815,18 @@ class EndpointContext {
|
|
|
3501
3815
|
[taon][typeorm] db prepration done.. db initialize=${this.connection?.isInitialized}
|
|
3502
3816
|
|
|
3503
3817
|
|
|
3504
|
-
`, dataSourceDbConfig);
|
|
3818
|
+
`, dataSourceDbConfig, { 'this.connection': !!this.connection });
|
|
3819
|
+
console.log(`Database file location: ${this.connection.options.database}`);
|
|
3820
|
+
}
|
|
3505
3821
|
}
|
|
3506
3822
|
else {
|
|
3507
3823
|
Helpers.info(`[taon][typeorm] Not initing db for mode ${this.mode}`);
|
|
3508
3824
|
}
|
|
3509
3825
|
}
|
|
3510
|
-
|
|
3826
|
+
initControllers() {
|
|
3827
|
+
if (this.isRunOrRevertOnlyMigrationAppStart) {
|
|
3828
|
+
return;
|
|
3829
|
+
}
|
|
3511
3830
|
const allControllers = this.getClassFunByArr(Models.ClassType.CONTROLLER);
|
|
3512
3831
|
for (const controllerClassFn of allControllers) {
|
|
3513
3832
|
controllerClassFn[Symbols.classMethodsNames] =
|
|
@@ -3578,7 +3897,7 @@ class EndpointContext {
|
|
|
3578
3897
|
}
|
|
3579
3898
|
}
|
|
3580
3899
|
writeActiveRoutes() {
|
|
3581
|
-
if (this.remoteHost) {
|
|
3900
|
+
if (this.remoteHost || this.isRunOrRevertOnlyMigrationAppStart) {
|
|
3582
3901
|
return;
|
|
3583
3902
|
}
|
|
3584
3903
|
const contexts = [this];
|
|
@@ -4291,6 +4610,9 @@ const createContext = (configFn) => {
|
|
|
4291
4610
|
get subscribers() {
|
|
4292
4611
|
return config.subscribers;
|
|
4293
4612
|
},
|
|
4613
|
+
get migrations() {
|
|
4614
|
+
return config.migrations;
|
|
4615
|
+
},
|
|
4294
4616
|
},
|
|
4295
4617
|
get contexts() {
|
|
4296
4618
|
return config.contexts;
|
|
@@ -4340,13 +4662,14 @@ const createContext = (configFn) => {
|
|
|
4340
4662
|
await endpointContextRef.initEntities();
|
|
4341
4663
|
await endpointContextRef.initSubscribers();
|
|
4342
4664
|
await endpointContextRef.initDatabaseConnection();
|
|
4343
|
-
endpointContextRef.
|
|
4665
|
+
await endpointContextRef.dbMigrations.ensureMigrationTableExists();
|
|
4666
|
+
endpointContextRef.initControllers();
|
|
4344
4667
|
endpointContextRef.startServer();
|
|
4345
4668
|
endpointContextRef.writeActiveRoutes();
|
|
4346
4669
|
await endpointContextRef.initClasses();
|
|
4347
4670
|
let keepWebsqlDbDataAfterReload = false;
|
|
4348
4671
|
keepWebsqlDbDataAfterReload =
|
|
4349
|
-
|
|
4672
|
+
TaonAdminService.Instance?.keepWebsqlDbDataAfterReload;
|
|
4350
4673
|
if (!Helpers.isNode && keepWebsqlDbDataAfterReload) {
|
|
4351
4674
|
Helpers.info(`[taon] Keep websql data after reload`);
|
|
4352
4675
|
}
|
|
@@ -4354,6 +4677,15 @@ const createContext = (configFn) => {
|
|
|
4354
4677
|
await endpointContextRef.reinitControllers();
|
|
4355
4678
|
}
|
|
4356
4679
|
///#region TODO this may be usefull but for now
|
|
4680
|
+
if (endpointContextRef.onlyMigrationRun) {
|
|
4681
|
+
await endpointContextRef.dbMigrations.runAllNotCompletedMigrations();
|
|
4682
|
+
}
|
|
4683
|
+
else if (endpointContextRef.onlyMigrationRevertToTimestamp) {
|
|
4684
|
+
await endpointContextRef.dbMigrations.revertMigrationToTimestamp(endpointContextRef.onlyMigrationRevertToTimestamp);
|
|
4685
|
+
}
|
|
4686
|
+
else {
|
|
4687
|
+
await endpointContextRef.dbMigrations.runAllNotCompletedMigrations();
|
|
4688
|
+
}
|
|
4357
4689
|
resolve(endpointContextRef);
|
|
4358
4690
|
});
|
|
4359
4691
|
});
|
|
@@ -4394,9 +4726,12 @@ var baseContext = /*#__PURE__*/Object.freeze({
|
|
|
4394
4726
|
BaseContext: BaseContext
|
|
4395
4727
|
});
|
|
4396
4728
|
|
|
4729
|
+
/**
|
|
4730
|
+
* Subscriber decorator
|
|
4731
|
+
*/
|
|
4397
4732
|
function TaonSubscriber(options) {
|
|
4398
4733
|
return function (constructor) {
|
|
4399
|
-
Reflect.defineMetadata(Symbols.metadata.options.
|
|
4734
|
+
Reflect.defineMetadata(Symbols.metadata.options.subscriber, options, constructor);
|
|
4400
4735
|
Reflect.defineMetadata(Symbols.metadata.className, options?.className || constructor.name, constructor);
|
|
4401
4736
|
ClassHelpers.setName(constructor, options?.className);
|
|
4402
4737
|
};
|
|
@@ -4411,133 +4746,133 @@ let BaseSubscriberForEntity = class BaseSubscriberForEntity extends BaseInjector
|
|
|
4411
4746
|
* Called after entity is loaded.
|
|
4412
4747
|
*/
|
|
4413
4748
|
afterLoad(entity) {
|
|
4414
|
-
this.
|
|
4749
|
+
this.ctx.logDb &&
|
|
4415
4750
|
console.log(`AFTER ENTITY LOADED: `, entity);
|
|
4416
4751
|
}
|
|
4417
4752
|
/**
|
|
4418
4753
|
* Called before query execution.
|
|
4419
4754
|
*/
|
|
4420
4755
|
beforeQuery(event) {
|
|
4421
|
-
this.
|
|
4756
|
+
this.ctx.logDb &&
|
|
4422
4757
|
console.log(`BEFORE QUERY: `, event.query);
|
|
4423
4758
|
}
|
|
4424
4759
|
/**
|
|
4425
4760
|
* Called after query execution.
|
|
4426
4761
|
*/
|
|
4427
4762
|
afterQuery(event) {
|
|
4428
|
-
this.
|
|
4763
|
+
this.ctx.logDb &&
|
|
4429
4764
|
console.log(`AFTER QUERY: `, event.query);
|
|
4430
4765
|
}
|
|
4431
4766
|
/**
|
|
4432
4767
|
* Called before entity insertion.
|
|
4433
4768
|
*/
|
|
4434
4769
|
beforeInsert(event) {
|
|
4435
|
-
this.
|
|
4770
|
+
this.ctx.logDb &&
|
|
4436
4771
|
console.log(`BEFORE ENTITY INSERTED: `, event.entity);
|
|
4437
4772
|
}
|
|
4438
4773
|
/**
|
|
4439
4774
|
* Called after entity insertion.
|
|
4440
4775
|
*/
|
|
4441
4776
|
afterInsert(event) {
|
|
4442
|
-
this.
|
|
4777
|
+
this.ctx.logDb &&
|
|
4443
4778
|
console.log(`AFTER ENTITY INSERTED: `, event.entity);
|
|
4444
4779
|
}
|
|
4445
4780
|
/**
|
|
4446
4781
|
* Called before entity update.
|
|
4447
4782
|
*/
|
|
4448
4783
|
beforeUpdate(event) {
|
|
4449
|
-
this.
|
|
4784
|
+
this.ctx.logDb &&
|
|
4450
4785
|
console.log(`BEFORE ENTITY UPDATED: `, event.entity);
|
|
4451
4786
|
}
|
|
4452
4787
|
/**
|
|
4453
4788
|
* Called after entity update.
|
|
4454
4789
|
*/
|
|
4455
4790
|
afterUpdate(event) {
|
|
4456
|
-
this.
|
|
4791
|
+
this.ctx.logDb &&
|
|
4457
4792
|
console.log(`AFTER ENTITY UPDATED: `, event.entity);
|
|
4458
4793
|
}
|
|
4459
4794
|
/**
|
|
4460
4795
|
* Called before entity removal.
|
|
4461
4796
|
*/
|
|
4462
4797
|
beforeRemove(event) {
|
|
4463
|
-
this.
|
|
4798
|
+
this.ctx.logDb &&
|
|
4464
4799
|
console.log(`BEFORE ENTITY WITH ID ${event.entityId} REMOVED: `, event.entity);
|
|
4465
4800
|
}
|
|
4466
4801
|
/**
|
|
4467
4802
|
* Called after entity removal.
|
|
4468
4803
|
*/
|
|
4469
4804
|
afterRemove(event) {
|
|
4470
|
-
this.
|
|
4805
|
+
this.ctx.logDb &&
|
|
4471
4806
|
console.log(`AFTER ENTITY WITH ID ${event.entityId} REMOVED: `, event.entity);
|
|
4472
4807
|
}
|
|
4473
4808
|
/**
|
|
4474
4809
|
* Called before entity removal.
|
|
4475
4810
|
*/
|
|
4476
4811
|
beforeSoftRemove(event) {
|
|
4477
|
-
this.
|
|
4812
|
+
this.ctx.logDb &&
|
|
4478
4813
|
console.log(`BEFORE ENTITY WITH ID ${event.entityId} SOFT REMOVED: `, event.entity);
|
|
4479
4814
|
}
|
|
4480
4815
|
/**
|
|
4481
4816
|
* Called after entity removal.
|
|
4482
4817
|
*/
|
|
4483
4818
|
afterSoftRemove(event) {
|
|
4484
|
-
this.
|
|
4819
|
+
this.ctx.logDb &&
|
|
4485
4820
|
console.log(`AFTER ENTITY WITH ID ${event.entityId} SOFT REMOVED: `, event.entity);
|
|
4486
4821
|
}
|
|
4487
4822
|
/**
|
|
4488
4823
|
* Called before entity recovery.
|
|
4489
4824
|
*/
|
|
4490
4825
|
beforeRecover(event) {
|
|
4491
|
-
this.
|
|
4826
|
+
this.ctx.logDb &&
|
|
4492
4827
|
console.log(`BEFORE ENTITY WITH ID ${event.entityId} RECOVERED: `, event.entity);
|
|
4493
4828
|
}
|
|
4494
4829
|
/**
|
|
4495
4830
|
* Called after entity recovery.
|
|
4496
4831
|
*/
|
|
4497
4832
|
afterRecover(event) {
|
|
4498
|
-
this.
|
|
4833
|
+
this.ctx.logDb &&
|
|
4499
4834
|
console.log(`AFTER ENTITY WITH ID ${event.entityId} RECOVERED: `, event.entity);
|
|
4500
4835
|
}
|
|
4501
4836
|
/**
|
|
4502
4837
|
* Called before transaction start.
|
|
4503
4838
|
*/
|
|
4504
4839
|
beforeTransactionStart(event) {
|
|
4505
|
-
this.
|
|
4840
|
+
this.ctx.logDb &&
|
|
4506
4841
|
console.log(`BEFORE TRANSACTION STARTED: `, event);
|
|
4507
4842
|
}
|
|
4508
4843
|
/**
|
|
4509
4844
|
* Called after transaction start.
|
|
4510
4845
|
*/
|
|
4511
4846
|
afterTransactionStart(event) {
|
|
4512
|
-
this.
|
|
4847
|
+
this.ctx.logDb &&
|
|
4513
4848
|
console.log(`AFTER TRANSACTION STARTED: `, event);
|
|
4514
4849
|
}
|
|
4515
4850
|
/**
|
|
4516
4851
|
* Called before transaction commit.
|
|
4517
4852
|
*/
|
|
4518
4853
|
beforeTransactionCommit(event) {
|
|
4519
|
-
this.
|
|
4854
|
+
this.ctx.logDb &&
|
|
4520
4855
|
console.log(`BEFORE TRANSACTION COMMITTED: `, event);
|
|
4521
4856
|
}
|
|
4522
4857
|
/**
|
|
4523
4858
|
* Called after transaction commit.
|
|
4524
4859
|
*/
|
|
4525
4860
|
afterTransactionCommit(event) {
|
|
4526
|
-
this.
|
|
4861
|
+
this.ctx.logDb &&
|
|
4527
4862
|
console.log(`AFTER TRANSACTION COMMITTED: `, event);
|
|
4528
4863
|
}
|
|
4529
4864
|
/**
|
|
4530
4865
|
* Called before transaction rollback.
|
|
4531
4866
|
*/
|
|
4532
4867
|
beforeTransactionRollback(event) {
|
|
4533
|
-
this.
|
|
4868
|
+
this.ctx.logDb &&
|
|
4534
4869
|
console.log(`BEFORE TRANSACTION ROLLBACK: `, event);
|
|
4535
4870
|
}
|
|
4536
4871
|
/**
|
|
4537
4872
|
* Called after transaction rollback.
|
|
4538
4873
|
*/
|
|
4539
4874
|
afterTransactionRollback(event) {
|
|
4540
|
-
this.
|
|
4875
|
+
this.ctx.logDb &&
|
|
4541
4876
|
console.log(`AFTER TRANSACTION ROLLBACK: `, event);
|
|
4542
4877
|
}
|
|
4543
4878
|
};
|
|
@@ -4549,6 +4884,26 @@ BaseSubscriberForEntity = __decorate([
|
|
|
4549
4884
|
;
|
|
4550
4885
|
({}); // @--end-of-file-for-module=taon lib/base-classes/base-subscriber-for-entity.ts
|
|
4551
4886
|
|
|
4887
|
+
class BaseMigration extends BaseInjector {
|
|
4888
|
+
/**
|
|
4889
|
+
* by default is READY to run
|
|
4890
|
+
*/
|
|
4891
|
+
isReadyToRun() {
|
|
4892
|
+
return true;
|
|
4893
|
+
}
|
|
4894
|
+
getDescription() {
|
|
4895
|
+
return _$1.startCase(ClassHelpers.getName(this));
|
|
4896
|
+
}
|
|
4897
|
+
async up(queryRunner) {
|
|
4898
|
+
console.log(`[BaseMigration] Running migration UP "${ClassHelpers.getName(this)}"`);
|
|
4899
|
+
}
|
|
4900
|
+
async down(queryRunner) {
|
|
4901
|
+
console.log(`[BaseMigration] Running migration DOWN "${ClassHelpers.getName(this)}"`);
|
|
4902
|
+
}
|
|
4903
|
+
}
|
|
4904
|
+
;
|
|
4905
|
+
({}); // @--end-of-file-for-module=taon lib/base-classes/base-migration.ts
|
|
4906
|
+
|
|
4552
4907
|
var Base;
|
|
4553
4908
|
(function (Base) {
|
|
4554
4909
|
Base.Controller = BaseController;
|
|
@@ -4559,11 +4914,15 @@ var Base;
|
|
|
4559
4914
|
Base.Class = BaseClass;
|
|
4560
4915
|
Base.Repository = BaseRepository;
|
|
4561
4916
|
Base.SubscriberForEntity = BaseSubscriberForEntity;
|
|
4917
|
+
Base.Migration = BaseMigration;
|
|
4562
4918
|
Base.Context = BaseContext;
|
|
4563
4919
|
})(Base || (Base = {}));
|
|
4564
4920
|
;
|
|
4565
4921
|
({}); // @--end-of-file-for-module=taon lib/base-classes/base.ts
|
|
4566
4922
|
|
|
4923
|
+
/**
|
|
4924
|
+
* Entity decorator
|
|
4925
|
+
*/
|
|
4567
4926
|
function TaonEntity(options) {
|
|
4568
4927
|
return function (constructor) {
|
|
4569
4928
|
options = options || {};
|
|
@@ -4582,6 +4941,9 @@ class TaonEntityOptions extends Models.DecoratorAbstractOpt {
|
|
|
4582
4941
|
;
|
|
4583
4942
|
({}); // @--end-of-file-for-module=taon lib/decorators/classes/entity-decorator.ts
|
|
4584
4943
|
|
|
4944
|
+
/**
|
|
4945
|
+
* Provider decorator
|
|
4946
|
+
*/
|
|
4585
4947
|
function TaonProvider(options) {
|
|
4586
4948
|
return function (constructor) {
|
|
4587
4949
|
Reflect.defineMetadata(Symbols.metadata.options.provider, options, constructor);
|
|
@@ -4594,6 +4956,21 @@ class TaonProviderOptions extends Models.DecoratorAbstractOpt {
|
|
|
4594
4956
|
;
|
|
4595
4957
|
({}); // @--end-of-file-for-module=taon lib/decorators/classes/provider-decorator.ts
|
|
4596
4958
|
|
|
4959
|
+
/**
|
|
4960
|
+
* Migration decorator
|
|
4961
|
+
*/
|
|
4962
|
+
function TaonMigration(options) {
|
|
4963
|
+
return function (constructor) {
|
|
4964
|
+
Reflect.defineMetadata(Symbols.metadata.options.migration, options, constructor);
|
|
4965
|
+
Reflect.defineMetadata(Symbols.metadata.className, options?.className || constructor.name, constructor);
|
|
4966
|
+
ClassHelpers.setName(constructor, options?.className);
|
|
4967
|
+
};
|
|
4968
|
+
}
|
|
4969
|
+
class TaonMigrationOptions extends Models.DecoratorAbstractOpt {
|
|
4970
|
+
}
|
|
4971
|
+
;
|
|
4972
|
+
({}); // @--end-of-file-for-module=taon lib/decorators/classes/migration-decorator.ts
|
|
4973
|
+
|
|
4597
4974
|
const inject = (entity) => {
|
|
4598
4975
|
return new Proxy({}, {
|
|
4599
4976
|
get: (_, propName) => {
|
|
@@ -5322,7 +5699,6 @@ class TaonTableComponent {
|
|
|
5322
5699
|
await this.retriveData();
|
|
5323
5700
|
}
|
|
5324
5701
|
async retriveData() {
|
|
5325
|
-
// @ts-ignore
|
|
5326
5702
|
}
|
|
5327
5703
|
expansionRow(e) {
|
|
5328
5704
|
this.expansionChange.next(e);
|
|
@@ -5331,7 +5707,7 @@ class TaonTableComponent {
|
|
|
5331
5707
|
log.i('context menu event', e);
|
|
5332
5708
|
}
|
|
5333
5709
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonTableComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
5334
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.1.5", type: TaonTableComponent, selector: "taon-table", inputs: { pageNumber: "pageNumber", pageSize: "pageSize", allowedColumns: "allowedColumns", entity: "entity", expansionTemplate: "expansionTemplate", rows: "rows", columns: "columns", pageSizeOptions: "pageSizeOptions" }, outputs: { expansionChange: "expansionChange", addingItem: "addingItem" }, viewQueries: [{ propertyName: "search", first: true, predicate: ["search"], descendants: true, static: true }], ngImport: i0, template: "<br />\n<columns-container>\n <column grow>\n <mat-form-field class=\"search-input\">\n <input matInput placeholder=\"Type to search table...\" #search />\n </mat-form-field>\n </column>\n <column [width]=\"80\">\n <button\n mat-fab\n [ngClass]=\"{ 'half-opacity': !search.value }\"\n class=\"undo-button\"\n color=\"secondary\"\n (click)=\"search.value = ''\">\n <mat-icon>close </mat-icon>\n </button>\n </column>\n\n <column [width]=\"80\">\n <button\n mat-fab\n (click)=\"addingItem.next()\"\n class=\"undo-button\"\n color=\"primary\">\n <mat-icon>add</mat-icon>\n </button>\n </column>\n</columns-container>\n\n<mtx-grid\n *ngIf=\"rows && columns\"\n [data]=\"rows\"\n [columns]=\"columns\"\n [expandable]=\"expandable\"\n [expansionTemplate]=\"expansionTemplate\"\n (expansionChange)=\"expansionRow($event)\"\n [length]=\"totalElements\"\n [loading]=\"isLoading\"\n [pageOnFront]=\"false\"\n [pageIndex]=\"pageNumber - 1\"\n [pageSize]=\"pageSize\"\n [pageSizeOptions]=\"pageSizeOptions\"\n [showPaginator]=\"showPaginator\"\n (page)=\"getNextPage($event)\">\n</mtx-grid>\n", styles: [":host{min-height:250px}.search-input{width:100%}.undo-button{margin-left:10px}.half-opacity{opacity:.2}\n"], dependencies: [{ kind: "directive", type:
|
|
5710
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.1.5", type: TaonTableComponent, selector: "taon-table", inputs: { pageNumber: "pageNumber", pageSize: "pageSize", allowedColumns: "allowedColumns", entity: "entity", expansionTemplate: "expansionTemplate", rows: "rows", columns: "columns", pageSizeOptions: "pageSizeOptions" }, outputs: { expansionChange: "expansionChange", addingItem: "addingItem" }, viewQueries: [{ propertyName: "search", first: true, predicate: ["search"], descendants: true, static: true }], ngImport: i0, template: "<br />\n<columns-container>\n <column grow>\n <mat-form-field class=\"search-input\">\n <input matInput placeholder=\"Type to search table...\" #search />\n </mat-form-field>\n </column>\n <column [width]=\"80\">\n <button\n mat-fab\n [ngClass]=\"{ 'half-opacity': !search.value }\"\n class=\"undo-button\"\n color=\"secondary\"\n (click)=\"search.value = ''\">\n <mat-icon>close </mat-icon>\n </button>\n </column>\n\n <column [width]=\"80\">\n <button\n mat-fab\n (click)=\"addingItem.next()\"\n class=\"undo-button\"\n color=\"primary\">\n <mat-icon>add</mat-icon>\n </button>\n </column>\n</columns-container>\n\n<mtx-grid\n *ngIf=\"rows && columns\"\n [data]=\"rows\"\n [columns]=\"columns\"\n [expandable]=\"expandable\"\n [expansionTemplate]=\"expansionTemplate\"\n (expansionChange)=\"expansionRow($event)\"\n [length]=\"totalElements\"\n [loading]=\"isLoading\"\n [pageOnFront]=\"false\"\n [pageIndex]=\"pageNumber - 1\"\n [pageSize]=\"pageSize\"\n [pageSizeOptions]=\"pageSizeOptions\"\n [showPaginator]=\"showPaginator\"\n (page)=\"getNextPage($event)\">\n</mtx-grid>\n", styles: [":host{min-height:250px}.search-input{width:100%}.undo-button{margin-left:10px}.half-opacity{opacity:.2}\n"], dependencies: [{ kind: "directive", type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i2$1.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "component", type: i3$1.MtxGrid, selector: "mtx-grid", inputs: ["displayedColumns", "columns", "data", "length", "loading", "trackBy", "columnResizable", "emptyValuePlaceholder", "pageOnFront", "showPaginator", "pageDisabled", "showFirstLastButtons", "pageIndex", "pageSize", "pageSizeOptions", "hidePageSize", "paginationTemplate", "sortOnFront", "sortActive", "sortDirection", "sortDisableClear", "sortDisabled", "sortStart", "rowHover", "rowStriped", "expandable", "expansionTemplate", "multiSelectable", "multiSelectionWithClick", "rowSelectable", "hideRowSelectionCheckbox", "disableRowClickSelection", "rowSelectionFormatter", "rowClassFormatter", "rowSelected", "cellSelectable", "showToolbar", "toolbarTitle", "toolbarTemplate", "columnHideable", "columnHideableChecked", "columnSortable", "columnPinnable", "columnPinOptions", "showColumnMenuButton", "columnMenuButtonText", "columnMenuButtonType", "columnMenuButtonColor", "columnMenuButtonClass", "columnMenuButtonIcon", "showColumnMenuHeader", "columnMenuHeaderText", "columnMenuHeaderTemplate", "showColumnMenuFooter", "columnMenuFooterText", "columnMenuFooterTemplate", "noResultText", "noResultTemplate", "headerTemplate", "headerExtraTemplate", "cellTemplate", "useContentRowTemplate", "useContentHeaderRowTemplate", "useContentFooterRowTemplate", "showSummary", "summaryTemplate", "showSidebar", "sidebarTemplate", "showStatusbar", "statusbarTemplate"], outputs: ["page", "sortChange", "rowClick", "rowContextMenu", "expansionChange", "rowSelectedChange", "cellSelectedChange", "columnChange"], exportAs: ["mtxGrid"] }, { kind: "directive", type: i4.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { kind: "component", type: i1$3.ColumnsComponent, selector: "columns-container" }, { kind: "component", type: i1$3.ColumnComponent, selector: "column", inputs: ["width"] }, { kind: "directive", type: i1$3.DirectiveGrow, selector: "[grow]" }, { kind: "component", type: i6.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: i7.MatFabButton, selector: "button[mat-fab]", inputs: ["extended"], exportAs: ["matButton"] }] }); }
|
|
5335
5711
|
}
|
|
5336
5712
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonTableComponent, decorators: [{
|
|
5337
5713
|
type: Component,
|
|
@@ -5411,36 +5787,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.5", ngImpor
|
|
|
5411
5787
|
;
|
|
5412
5788
|
({}); // @--end-of-file-for-module=taon lib/ui/taon-table/index.ts
|
|
5413
5789
|
|
|
5414
|
-
class TaonAdminService {
|
|
5415
|
-
/**
|
|
5416
|
-
* @deprecated
|
|
5417
|
-
*/
|
|
5418
|
-
disableScroll() {
|
|
5419
|
-
}
|
|
5420
|
-
constructor(cdr) {
|
|
5421
|
-
this.cdr = cdr;
|
|
5422
|
-
this.admin = window['taon'];
|
|
5423
|
-
}
|
|
5424
|
-
addTab(name, template) {
|
|
5425
|
-
this.admin.cmp.tabs.push({
|
|
5426
|
-
name,
|
|
5427
|
-
template,
|
|
5428
|
-
});
|
|
5429
|
-
}
|
|
5430
|
-
init(taonAdminModeConfigurationComponent) {
|
|
5431
|
-
this.taonAdminModeConfigurationComponent =
|
|
5432
|
-
taonAdminModeConfigurationComponent;
|
|
5433
|
-
}
|
|
5434
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminService, deps: [{ token: i0.ApplicationRef }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
5435
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminService, providedIn: 'root' }); }
|
|
5436
|
-
}
|
|
5437
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminService, decorators: [{
|
|
5438
|
-
type: Injectable,
|
|
5439
|
-
args: [{ providedIn: 'root' }]
|
|
5440
|
-
}], ctorParameters: () => [{ type: i0.ApplicationRef }] });
|
|
5441
|
-
;
|
|
5442
|
-
({}); // @--end-of-file-for-module=taon lib/ui/taon-admin-mode-configuration/taon-admin-control.service.ts
|
|
5443
|
-
|
|
5444
5790
|
class TaonAdminModeConfigurationComponent {
|
|
5445
5791
|
get opened() {
|
|
5446
5792
|
return !this.isIframe && this.admin.adminPanelIsOpen;
|
|
@@ -5455,13 +5801,12 @@ class TaonAdminModeConfigurationComponent {
|
|
|
5455
5801
|
}
|
|
5456
5802
|
this.admin.adminPanelIsOpen = v;
|
|
5457
5803
|
}
|
|
5458
|
-
constructor(breakpointsService) {
|
|
5804
|
+
constructor(breakpointsService, admin) {
|
|
5459
5805
|
this.breakpointsService = breakpointsService;
|
|
5806
|
+
this.admin = admin;
|
|
5460
5807
|
this.$destroy = new Subject();
|
|
5461
5808
|
this.cdr = inject$1(ChangeDetectorRef);
|
|
5462
5809
|
this.taonAdminService = inject$1(TaonAdminService);
|
|
5463
|
-
this.tabs = [];
|
|
5464
|
-
this.admin = window['taon'];
|
|
5465
5810
|
this.isWebSQLMode = Helpers.isWebSQL;
|
|
5466
5811
|
this.hideTaonToolsInProduction = ENV.hideTaonToolsInProduction && ENV.angularProd;
|
|
5467
5812
|
this.isIframe = window.location !== window.parent.location;
|
|
@@ -5480,7 +5825,6 @@ class TaonAdminModeConfigurationComponent {
|
|
|
5480
5825
|
this.dragPositionZero = { x: 0, y: 0 };
|
|
5481
5826
|
this.taonAdminModeConfigurationDataChanged = new EventEmitter();
|
|
5482
5827
|
this.taonAdminModeConfigurationData = {};
|
|
5483
|
-
this.admin.cmp = this;
|
|
5484
5828
|
this.breakpointsService
|
|
5485
5829
|
.listenTo()
|
|
5486
5830
|
.pipe(takeUntil(this.$destroy))
|
|
@@ -5488,14 +5832,6 @@ class TaonAdminModeConfigurationComponent {
|
|
|
5488
5832
|
// @ts-ignore
|
|
5489
5833
|
this.isDesktop = breakpoint === 'desktop';
|
|
5490
5834
|
});
|
|
5491
|
-
this.taonAdminService.init(this);
|
|
5492
|
-
}
|
|
5493
|
-
reloadTabs() {
|
|
5494
|
-
this.reloading = true;
|
|
5495
|
-
setTimeout(() => {
|
|
5496
|
-
this.reloading = false;
|
|
5497
|
-
console.log('reloading done');
|
|
5498
|
-
});
|
|
5499
5835
|
}
|
|
5500
5836
|
async ngOnInit() {
|
|
5501
5837
|
await Stor.awaitPendingOperatios();
|
|
@@ -5519,6 +5855,16 @@ class TaonAdminModeConfigurationComponent {
|
|
|
5519
5855
|
onResize(event) {
|
|
5520
5856
|
this.height = window.innerHeight;
|
|
5521
5857
|
}
|
|
5858
|
+
async reloadTabs() {
|
|
5859
|
+
return new Promise(resolve => {
|
|
5860
|
+
this.reloading = true;
|
|
5861
|
+
setTimeout(() => {
|
|
5862
|
+
this.reloading = false;
|
|
5863
|
+
console.log('reloading done');
|
|
5864
|
+
resolve();
|
|
5865
|
+
});
|
|
5866
|
+
});
|
|
5867
|
+
}
|
|
5522
5868
|
async toogle() {
|
|
5523
5869
|
this.opened = !this.opened;
|
|
5524
5870
|
}
|
|
@@ -5540,37 +5886,47 @@ class TaonAdminModeConfigurationComponent {
|
|
|
5540
5886
|
scrollTabs(event) {
|
|
5541
5887
|
return;
|
|
5542
5888
|
}
|
|
5543
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminModeConfigurationComponent, deps: [{ token: i1$3.BreakpointsService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
5544
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.1.5", type: TaonAdminModeConfigurationComponent, selector: "app-taon-admin-mode-configuration", inputs: { taonAdminModeConfigurationData: "taonAdminModeConfigurationData" }, outputs: { taonAdminModeConfigurationDataChanged: "taonAdminModeConfigurationDataChanged" }, host: { listeners: { "window:resize": "onResize($event)" } }, viewQueries: [{ propertyName: "tabGroup", first: true, predicate: ["tabGroup"], descendants: true }], ngImport: i0, template: "<!-- #region basic global components -->\n<taon-session-passcode\n *ngIf=\"showPasscode\"\n [passcode]=\"passcode\"\n [message]=\"message\" />\n<!-- <taon-progress-bar [isDesktop]=\"isDesktop\"></taon-progress-bar> -->\n<!-- <taon-notifications></taon-notifications> -->\n<button\n mat-fab\n class=\"fab-button\"\n color=\"accent\"\n aria-label=\"Taon Admin Mode\"\n *ngIf=\"\n !admin.draggablePopupMode &&\n isDesktop &&\n !isIframe &&\n !hideTaonToolsInProduction\n \"\n (click)=\"toogle()\">\n <mat-icon>build</mat-icon>\n</button>\n<!-- #endregion -->\n\n<!-- #region small hidden button -->\n<!-- <button class=\"admin-show-button\"\n *ngIf=\"!admin.draggablePopupMode && isDesktop\"\n (click)=\"toogle()\"> Admin </button> -->\n<!-- #endregion -->\n\n<ng-template #contentNoScroll>\n <ng-content> </ng-content>\n</ng-template>\n\n<ng-template #content>\n <ng-scrollbar>\n <ng-container [ngTemplateOutlet]=\"contentNoScroll\"></ng-container>\n </ng-scrollbar>\n</ng-template>\n\n<!-- #region admin tabs -->\n<ng-template #adminTabs>\n <div class=\"taon-header-admin-wrapper\">\n <columns-container\n class=\"taon-header-admin\"\n [ngClass]=\"{ 'draggable-column': admin.draggablePopupMode }\">\n <column width=\"200\" class=\"logo-header\">\n <img\n *ngIf=\"openedOnce\"\n src=\"assets/assets-for/taon/shared/logo-header-admin-mode.png\" />\n </column>\n\n <column grow>\n <!-- <span>Super Admin Mode</span> -->\n </column>\n\n <column\n width=\"40\"\n *ngIf=\"\n !admin.draggablePopupModeFullScreen && !admin.draggablePopupMode\n \">\n <button\n mat-icon-button\n *ngIf=\"admin.draggablePopupMode\"\n (click)=\"\n admin.draggablePopupMode = false;\n opened = false;\n wasOpenDraggablePopup = true\n \"\n class=\"admin-close-button\">\n <mat-icon>close </mat-icon>\n </button>\n\n <button\n mat-icon-button\n *ngIf=\"!admin.draggablePopupMode\"\n (click)=\"toogle()\"\n class=\"admin-close-button\">\n <mat-icon>close</mat-icon>\n </button>\n </column>\n\n <column width=\"40\">\n <button\n mat-icon-button\n *ngIf=\"!admin.draggablePopupModeFullScreen\"\n class=\"admin-close-button\"\n (click)=\"toogleFullScreen()\">\n <mat-icon>fullscreen</mat-icon>\n </button>\n <button\n mat-icon-button\n *ngIf=\"admin.draggablePopupModeFullScreen\"\n class=\"admin-close-button\"\n (click)=\"toogleFullScreen()\">\n <mat-icon>close_fullscreen</mat-icon>\n </button>\n </column>\n\n <column width=\"40\" *ngIf=\"!admin.draggablePopupModeFullScreen\">\n <button\n mat-icon-button\n *ngIf=\"!admin.draggablePopupMode\"\n (click)=\"admin.draggablePopupMode = true\"\n class=\"admin-close-button\">\n <mat-icon>launch</mat-icon>\n </button>\n\n <button\n mat-icon-button\n *ngIf=\"admin.draggablePopupMode\"\n (click)=\"admin.draggablePopupMode = false; resetDrag()\"\n class=\"admin-close-button\">\n <mat-icon style=\"transform: rotate(180deg)\">login</mat-icon>\n </button>\n </column>\n </columns-container>\n </div>\n\n <columns-container\n [ngClass]=\"{ 'draggable-column': admin.draggablePopupMode }\">\n <column grow>\n <mat-tab-group\n dynamicHeight\n (wheel)=\"scrollTabs($event)\"\n #tabGroup\n [selectedIndex]=\"selectedIndex\"\n (selectedIndexChange)=\"selectedIndex = $event\">\n <mat-tab label=\"DB/Cache\">\n <section>\n <mat-card>\n <mat-card-header>\n <mat-card-subtitle>WEBSQL MODE</mat-card-subtitle>\n </mat-card-header>\n <mat-card-content>\n <mat-checkbox\n [disabled]=\"!isWebSQLMode\"\n [ngModel]=\"admin.keepWebsqlDbDataAfterReload\"\n (change)=\"\n admin.setKeepWebsqlDbDataAfterReload($event.checked)\n \">\n Don't remove data when reloading\n </mat-checkbox>\n </mat-card-content>\n </mat-card>\n </section>\n <br />\n <taon-db-admin />\n </mat-tab>\n\n <mat-tab label=\"Files\" *ngIf=\"admin.enabledTabs.includes('files')\">\n <section>\n <mat-checkbox\n [ngModel]=\"admin.filesEditMode\"\n (change)=\"admin.setEditMode($event.checked)\"\n >Edit mode</mat-checkbox\n >\n </section>\n <!-- admin.filesEditMode: {{ admin.filesEditMode }} -->\n <!-- <taon-admin-edit-mode *ngIf=\"admin.filesEditMode\">\n </taon-admin-edit-mode> -->\n <br />\n <hr *ngIf=\"admin.filesEditMode\" />\n <!-- <section>\n <button mat-raised-button>[TODO] Clear Files from browser cache </button> <br>\n <button mat-raised-button>[TODO] Start files export (as zip) </button> <br>\n <button mat-raised-button>[TODO] Import whole database (from zip) </button><br>\n </section> -->\n </mat-tab>\n <mat-tab *ngFor=\"let tab of tabs\" label=\"{{ tab.name }}\">\n <div\n class=\"full-tabs\"\n [style.height.px]=\"height - 150\"\n *ngIf=\"!isIframe\">\n <ng-container *ngTemplateOutlet=\"tab.template\"></ng-container>\n </div>\n <ng-container *ngIf=\"isIframe\">\n <ng-container *ngTemplateOutlet=\"tab.template\"></ng-container>\n </ng-container>\n </mat-tab>\n\n <!-- <mat-tab label=\"Portal\">\n <section>\n <mat-checkbox>[TODO] Maintenance Mode for whole portal</mat-checkbox>\n\n <mat-expansion-panel>\n\n <mat-expansion-panel-header>\n [TODO] Active User: 80432\n </mat-expansion-panel-header>\n <section>\n <button mat-raised-button>[TODO] Send notification to users </button><br>\n <button mat-raised-button>[TODO] Send email to users </button><br>\n </section>\n </mat-expansion-panel>\n <mat-expansion-panel>\n <mat-expansion-panel-header>\n [TODO] Enable features\n </mat-expansion-panel-header>\n <mat-checkbox>[TODO] AB testing</mat-checkbox> <br>\n <mat-checkbox>\n [TODO] Newsletter email question popup\n </mat-checkbox> <br>\n <mat-checkbox>\n [TODO] Promotion popup\n </mat-checkbox> <br>\n </mat-expansion-panel>\n </section>\n </mat-tab>\n <mat-tab label=\"User\">\n Welcome in user managements\n </mat-tab>\n <mat-tab label=\"Translations\">\n Welcome in user managements\n </mat-tab> -->\n </mat-tab-group>\n </column>\n </columns-container>\n</ng-template>\n<!-- #endregion -->\n\n<!-- #region small/mobile draggable popup windows -->\n<div\n class=\"draggable-popup-mode-window\"\n *ngIf=\"\n admin.draggablePopupMode && !admin.draggablePopupModeFullScreen && !isIframe\n \"\n cdkDrag\n [cdkDragFreeDragPosition]=\"dragPosition\"\n (cdkDragEnded)=\"moved($event)\">\n <ng-scrollbar>\n <ng-container [ngTemplateOutlet]=\"adminTabs\"></ng-container>\n </ng-scrollbar>\n</div>\n<!-- #endregion -->\n\n<!-- #region fullscreen draggable popup window -->\n<div\n class=\"draggable-popup-mode-window-full\"\n *ngIf=\"\n admin.draggablePopupMode &&\n admin.draggablePopupModeFullScreen &&\n !isIframe &&\n !reloading\n \"\n cdkDrag\n [cdkDragFreeDragPosition]=\"dragPositionZero\">\n <ng-container [ngTemplateOutlet]=\"adminTabs\"></ng-container>\n</div>\n<!-- #endregion -->\n\n<!-- #region content when not in draggable (or fullscreen draggable) popup -->\n<div\n [style.height.px]=\"height\"\n *ngIf=\"\n (isIframe ||\n !isDesktop ||\n admin.draggablePopupMode ||\n admin.draggablePopupModeFullScreen) &&\n !reloading\n \"\n style=\"width: 100%; display: block\"\n class=\"content\">\n <ng-container\n [ngTemplateOutlet]=\"\n admin.scrollableEnabled ? content : contentNoScroll\n \"></ng-container>\n</div>\n<!-- #endregion -->\n\n<!-- #region draggable popup window -->\n<mat-drawer-container\n *ngIf=\"!admin.draggablePopupMode && isDesktop && !isIframe\"\n class=\"example-container\"\n [style.height.px]=\"height\"\n style=\"background-color: transparent\"\n (backdropClick)=\"opened = false\"\n [hasBackdrop]=\"false\">\n <mat-drawer #drawer style=\"width: 580px\" [opened]=\"opened\" [mode]=\"'side'\">\n <ng-container [ngTemplateOutlet]=\"adminTabs\"></ng-container>\n </mat-drawer>\n <mat-drawer-content style=\"overflow: hidden\">\n <ng-container\n *ngIf=\"!admin.draggablePopupMode && !reloading\"\n [ngTemplateOutlet]=\"\n admin.scrollableEnabled ? content : contentNoScroll\n \"></ng-container>\n </mat-drawer-content>\n</mat-drawer-container>\n<!-- #endregion -->\n", styles: ["section{display:block;padding:10px}section>*{margin-top:0!important;margin-bottom:10px!important}section>*:last-child{margin-bottom:0!important}:host{display:block}.draggable-column{display:block!important;width:100%!important}.admin-show-button{position:fixed;bottom:100px;left:-15px;z-index:2147483647;transform:rotate(90deg);border:0px;color:#fff;background:gray;opacity:.1;cursor:pointer}.admin-show-button:hover{opacity:1}.taon-ui-super-admin-mode{font-family:JosefinSans-Bold;text-align:right;margin-right:10px}mat-drawer{margin:0;background-color:#dcdcdc!important}.taon-header-admin-wrapper{overflow:hidden;width:100%;display:block}.taon-header-admin{background:#fff;box-shadow:0 -9px 6px 6px #000;height:47px}.taon-header-admin .logo-header img{height:18px;padding:8px;position:relative;float:left;top:7px;box-sizing:content-box;transform:scale(1.5);left:49px}.draggable-popup-mode-window{width:600px;height:500px;border:solid 1px #ccc;color:#000000de;cursor:move;justify-content:center;align-items:center;background:#fff;border-radius:4px;position:fixed;z-index:105;background-color:#dcdcdc!important;transition:box-shadow .2s cubic-bezier(0,0,.2,1);box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f}.draggable-popup-mode-window:active{box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.draggable-popup-mode-window-full{width:100%;height:100%;overflow:scroll;color:#000000de;justify-content:center;align-items:center;background:#fff;border-radius:4px;position:fixed;z-index:105;background-color:#dcdcdc!important}.admin-close-button{float:right}.fab-button{position:fixed;right:110px;bottom:100px;z-index:10;background-color:#dcdcdc;color:#8f8f8f}.full-tabs{padding:10px}.mat-drawer-container-full-screen{background-color:red}\n"], dependencies: [{ kind: "directive", type: i2$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: i1$3.ColumnsComponent, selector: "columns-container" }, { kind: "component", type: i1$3.ColumnComponent, selector: "column", inputs: ["width"] }, { kind: "directive", type: i1$3.DirectiveGrow, selector: "[grow]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i4$1.NgScrollbar, selector: "ng-scrollbar:not([externalViewport])", exportAs: ["ngScrollbar"] }, { kind: "directive", type: i5.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "component", type: i6$1.MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "component", type: i6$1.MatFabButton, selector: "button[mat-fab]", inputs: ["extended"], exportAs: ["matButton"] }, { kind: "component", type: i7.MatCard, selector: "mat-card", inputs: ["appearance"], exportAs: ["matCard"] }, { kind: "directive", type: i7.MatCardContent, selector: "mat-card-content" }, { kind: "component", type: i7.MatCardHeader, selector: "mat-card-header" }, { kind: "directive", type: i7.MatCardSubtitle, selector: "mat-card-subtitle, [mat-card-subtitle], [matCardSubtitle]" }, { kind: "component", type: i8.MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "component", type: i6.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: i10.MatDrawer, selector: "mat-drawer", inputs: ["position", "mode", "disableClose", "autoFocus", "opened"], outputs: ["openedChange", "opened", "openedStart", "closed", "closedStart", "positionChanged"], exportAs: ["matDrawer"] }, { kind: "component", type: i10.MatDrawerContainer, selector: "mat-drawer-container", inputs: ["autosize", "hasBackdrop"], outputs: ["backdropClick"], exportAs: ["matDrawerContainer"] }, { kind: "component", type: i10.MatDrawerContent, selector: "mat-drawer-content" }, { kind: "component", type: i11.MatTab, selector: "mat-tab", inputs: ["disabled", "label", "aria-label", "aria-labelledby", "labelClass", "bodyClass"], exportAs: ["matTab"] }, { kind: "component", type: i11.MatTabGroup, selector: "mat-tab-group", inputs: ["color", "fitInkBarToContent", "mat-stretch-tabs", "dynamicHeight", "selectedIndex", "headerPosition", "animationDuration", "contentTabIndex", "disablePagination", "disableRipple", "preserveContent", "backgroundColor", "aria-label", "aria-labelledby"], outputs: ["selectedIndexChange", "focusChange", "animationDone", "selectedTabChange"], exportAs: ["matTabGroup"] }, { kind: "component", type: TaonSessionPasscodeComponent, selector: "taon-session-passcode", inputs: ["passcode", "message"] }] }); }
|
|
5889
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminModeConfigurationComponent, deps: [{ token: i1$3.BreakpointsService }, { token: TaonAdminService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
5890
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.1.5", type: TaonAdminModeConfigurationComponent, isStandalone: true, selector: "taon-admin-mode-configuration", inputs: { taonAdminModeConfigurationData: "taonAdminModeConfigurationData" }, outputs: { taonAdminModeConfigurationDataChanged: "taonAdminModeConfigurationDataChanged" }, host: { listeners: { "window:resize": "onResize($event)" } }, viewQueries: [{ propertyName: "tabGroup", first: true, predicate: ["tabGroup"], descendants: true }], ngImport: i0, template: "<!-- #region basic global components -->\n<taon-session-passcode\n *ngIf=\"showPasscode\"\n [passcode]=\"passcode\"\n [message]=\"message\" />\n<!-- <taon-progress-bar [isDesktop]=\"isDesktop\"></taon-progress-bar> -->\n<!-- <taon-notifications></taon-notifications> -->\n<button\n mat-fab\n class=\"fab-button\"\n color=\"accent\"\n aria-label=\"Taon Admin Mode\"\n *ngIf=\"\n !admin.draggablePopupMode &&\n isDesktop &&\n !isIframe &&\n !hideTaonToolsInProduction\n \"\n (click)=\"toogle()\">\n <mat-icon>build</mat-icon>\n</button>\n<!-- #endregion -->\n\n<!-- #region small hidden button -->\n<!-- <button class=\"admin-show-button\"\n *ngIf=\"!admin.draggablePopupMode && isDesktop\"\n (click)=\"toogle()\"> Admin </button> -->\n<!-- #endregion -->\n\n<ng-template #contentNoScroll>\n <ng-content> </ng-content>\n</ng-template>\n\n<ng-template #content>\n <ng-scrollbar>\n <ng-container [ngTemplateOutlet]=\"contentNoScroll\"></ng-container>\n </ng-scrollbar>\n</ng-template>\n\n<!-- #region admin tabs -->\n<ng-template #adminTabs>\n <!-- #region admin tabs / header -->\n <div class=\"taon-header-admin-wrapper\">\n <columns-container\n class=\"taon-header-admin\"\n [ngClass]=\"{ 'draggable-column': admin.draggablePopupMode }\">\n <column\n width=\"200\"\n class=\"logo-header\">\n <img\n *ngIf=\"openedOnce\"\n src=\"assets/assets-for/taon/shared/logo-header-admin-mode.png\" />\n </column>\n\n <column grow>\n <!-- <span>Super Admin Mode</span> -->\n </column>\n\n <column\n width=\"40\"\n *ngIf=\"\n !admin.draggablePopupModeFullScreen && !admin.draggablePopupMode\n \">\n <button\n mat-icon-button\n *ngIf=\"admin.draggablePopupMode\"\n (click)=\"\n admin.draggablePopupMode = false;\n opened = false;\n wasOpenDraggablePopup = true\n \"\n class=\"admin-close-button\">\n <mat-icon>close </mat-icon>\n </button>\n\n <button\n mat-icon-button\n *ngIf=\"!admin.draggablePopupMode\"\n (click)=\"toogle()\"\n class=\"admin-close-button\">\n <mat-icon>close</mat-icon>\n </button>\n </column>\n\n <column width=\"40\">\n <button\n mat-icon-button\n *ngIf=\"!admin.draggablePopupModeFullScreen\"\n class=\"admin-close-button\"\n (click)=\"toogleFullScreen()\">\n <mat-icon>fullscreen</mat-icon>\n </button>\n <button\n mat-icon-button\n *ngIf=\"admin.draggablePopupModeFullScreen\"\n class=\"admin-close-button\"\n (click)=\"toogleFullScreen()\">\n <mat-icon>close_fullscreen</mat-icon>\n </button>\n </column>\n\n <column\n width=\"40\"\n *ngIf=\"!admin.draggablePopupModeFullScreen\">\n <button\n mat-icon-button\n *ngIf=\"!admin.draggablePopupMode\"\n (click)=\"admin.draggablePopupMode = true\"\n class=\"admin-close-button\">\n <mat-icon>launch</mat-icon>\n </button>\n\n <button\n mat-icon-button\n *ngIf=\"admin.draggablePopupMode\"\n (click)=\"admin.draggablePopupMode = false; resetDrag()\"\n class=\"admin-close-button\">\n <mat-icon style=\"transform: rotate(180deg)\">login</mat-icon>\n </button>\n </column>\n </columns-container>\n </div>\n <!-- #endregion -->\n\n <columns-container\n [ngClass]=\"{ 'draggable-column': admin.draggablePopupMode }\">\n <column grow>\n <mat-tab-group\n dynamicHeight\n (wheel)=\"scrollTabs($event)\"\n #tabGroup\n [selectedIndex]=\"selectedIndex\"\n (selectedIndexChange)=\"selectedIndex = $event\">\n <mat-tab label=\"DB/Cache\">\n <section>\n <mat-card>\n <mat-card-header>\n <mat-card-subtitle>WEBSQL MODE</mat-card-subtitle>\n </mat-card-header>\n <mat-card-content>\n <mat-checkbox\n [disabled]=\"!isWebSQLMode\"\n [ngModel]=\"admin.keepWebsqlDbDataAfterReload\"\n (change)=\"\n admin.setKeepWebsqlDbDataAfterReload($event.checked)\n \">\n Don't remove data when reloading\n </mat-checkbox>\n </mat-card-content>\n </mat-card>\n </section>\n <br />\n <taon-db-admin />\n </mat-tab>\n </mat-tab-group>\n </column>\n </columns-container>\n</ng-template>\n<!-- #endregion -->\n\n<!-- #region small/mobile draggable popup windows -->\n<div\n class=\"draggable-popup-mode-window\"\n *ngIf=\"\n admin.draggablePopupMode && !admin.draggablePopupModeFullScreen && !isIframe\n \"\n cdkDrag\n [cdkDragFreeDragPosition]=\"dragPosition\"\n (cdkDragEnded)=\"moved($event)\">\n <ng-scrollbar>\n <ng-container [ngTemplateOutlet]=\"adminTabs\"></ng-container>\n </ng-scrollbar>\n</div>\n<!-- #endregion -->\n\n<!-- #region fullscreen draggable popup window -->\n<div\n class=\"draggable-popup-mode-window-full\"\n *ngIf=\"\n admin.draggablePopupMode &&\n admin.draggablePopupModeFullScreen &&\n !isIframe &&\n !reloading\n \"\n cdkDrag\n [cdkDragFreeDragPosition]=\"dragPositionZero\">\n <ng-container [ngTemplateOutlet]=\"adminTabs\"></ng-container>\n</div>\n<!-- #endregion -->\n\n<!-- #region content when not in draggable (or fullscreen draggable) popup -->\n<div\n [style.height.px]=\"height\"\n *ngIf=\"\n (isIframe ||\n !isDesktop ||\n admin.draggablePopupMode ||\n admin.draggablePopupModeFullScreen) &&\n !reloading\n \"\n style=\"width: 100%; display: block\"\n class=\"content\">\n <ng-container\n [ngTemplateOutlet]=\"\n admin.scrollableEnabled ? content : contentNoScroll\n \"></ng-container>\n</div>\n<!-- #endregion -->\n\n<!-- #region draggable popup window -->\n<mat-drawer-container\n *ngIf=\"!admin.draggablePopupMode && isDesktop && !isIframe\"\n class=\"example-container\"\n [style.height.px]=\"height\"\n style=\"background-color: transparent\"\n (backdropClick)=\"opened = false\"\n [hasBackdrop]=\"false\">\n <mat-drawer\n #drawer\n style=\"width: 580px\"\n [opened]=\"opened\"\n [mode]=\"'side'\">\n <ng-container [ngTemplateOutlet]=\"adminTabs\"></ng-container>\n </mat-drawer>\n <mat-drawer-content style=\"overflow: hidden\">\n <ng-container\n *ngIf=\"!admin.draggablePopupMode && !reloading\"\n [ngTemplateOutlet]=\"\n admin.scrollableEnabled ? content : contentNoScroll\n \"></ng-container>\n </mat-drawer-content>\n</mat-drawer-container>\n<!-- #endregion -->\n", styles: ["section{display:block;padding:10px}section>*{margin-top:0!important;margin-bottom:10px!important}section>*:last-child{margin-bottom:0!important}:host{display:block}.draggable-column{display:block!important;width:100%!important}.admin-show-button{position:fixed;bottom:100px;left:-15px;z-index:2147483647;transform:rotate(90deg);border:0px;color:#fff;background:gray;opacity:.1;cursor:pointer}.admin-show-button:hover{opacity:1}.taon-ui-super-admin-mode{font-family:JosefinSans-Bold;text-align:right;margin-right:10px}mat-drawer{margin:0;background-color:#dcdcdc!important}.taon-header-admin-wrapper{overflow:hidden;width:100%;display:block}.taon-header-admin{background:#fff;box-shadow:0 -9px 6px 6px #000;height:47px}.taon-header-admin .logo-header img{height:18px;padding:8px;position:relative;float:left;top:7px;box-sizing:content-box;transform:scale(1.5);left:49px}.draggable-popup-mode-window{width:600px;height:500px;border:solid 1px #ccc;color:#000000de;cursor:move;justify-content:center;align-items:center;background:#fff;border-radius:4px;position:fixed;z-index:105;background-color:#dcdcdc!important;transition:box-shadow .2s cubic-bezier(0,0,.2,1);box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f}.draggable-popup-mode-window:active{box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.draggable-popup-mode-window-full{width:100%;height:100%;overflow:scroll;color:#000000de;justify-content:center;align-items:center;background:#fff;border-radius:4px;position:fixed;z-index:105;background-color:#dcdcdc!important}.admin-close-button{float:right}.fab-button{position:fixed;right:110px;bottom:100px;z-index:10;background-color:#dcdcdc;color:#8f8f8f}.full-tabs{padding:10px}.mat-drawer-container-full-screen{background-color:red}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: StaticColumnsModule }, { kind: "component", type: i1$3.ColumnsComponent, selector: "columns-container" }, { kind: "component", type: i1$3.ColumnComponent, selector: "column", inputs: ["width"] }, { kind: "directive", type: i1$3.DirectiveGrow, selector: "[grow]" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: NgScrollbarModule }, { kind: "component", type: i5.NgScrollbar, selector: "ng-scrollbar:not([externalViewport])", exportAs: ["ngScrollbar"] }, { kind: "ngmodule", type: TaonProgressBarModule }, { kind: "ngmodule", type: TaonNotificationsModule }, { kind: "ngmodule", type: TaonFullMaterialModule }, { kind: "directive", type: i6$1.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "component", type: i7.MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "component", type: i7.MatFabButton, selector: "button[mat-fab]", inputs: ["extended"], exportAs: ["matButton"] }, { kind: "component", type: i8.MatCard, selector: "mat-card", inputs: ["appearance"], exportAs: ["matCard"] }, { kind: "directive", type: i8.MatCardContent, selector: "mat-card-content" }, { kind: "component", type: i8.MatCardHeader, selector: "mat-card-header" }, { kind: "directive", type: i8.MatCardSubtitle, selector: "mat-card-subtitle, [mat-card-subtitle], [matCardSubtitle]" }, { kind: "component", type: i9.MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "component", type: i6.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: i11.MatDrawer, selector: "mat-drawer", inputs: ["position", "mode", "disableClose", "autoFocus", "opened"], outputs: ["openedChange", "opened", "openedStart", "closed", "closedStart", "positionChanged"], exportAs: ["matDrawer"] }, { kind: "component", type: i11.MatDrawerContainer, selector: "mat-drawer-container", inputs: ["autosize", "hasBackdrop"], outputs: ["backdropClick"], exportAs: ["matDrawerContainer"] }, { kind: "component", type: i11.MatDrawerContent, selector: "mat-drawer-content" }, { kind: "component", type: i12.MatTab, selector: "mat-tab", inputs: ["disabled", "label", "aria-label", "aria-labelledby", "labelClass", "bodyClass"], exportAs: ["matTab"] }, { kind: "component", type: i12.MatTabGroup, selector: "mat-tab-group", inputs: ["color", "fitInkBarToContent", "mat-stretch-tabs", "dynamicHeight", "selectedIndex", "headerPosition", "animationDuration", "contentTabIndex", "disablePagination", "disableRipple", "preserveContent", "backgroundColor", "aria-label", "aria-labelledby"], outputs: ["selectedIndexChange", "focusChange", "animationDone", "selectedTabChange"], exportAs: ["matTabGroup"] }, { kind: "component", type: // TODO import only partial things
|
|
5891
|
+
TaonSessionPasscodeComponent, selector: "taon-session-passcode", inputs: ["passcode", "message"] }] }); }
|
|
5545
5892
|
}
|
|
5546
5893
|
__decorate([
|
|
5547
|
-
Stor.property.in.localstorage
|
|
5894
|
+
(Stor.property.in.localstorage
|
|
5548
5895
|
.for(TaonAdminModeConfigurationComponent)
|
|
5549
|
-
.withDefaultValue(0),
|
|
5896
|
+
.withDefaultValue(0)),
|
|
5550
5897
|
__metadata("design:type", Number)
|
|
5551
5898
|
], TaonAdminModeConfigurationComponent.prototype, "dragPositionX", void 0);
|
|
5552
5899
|
__decorate([
|
|
5553
|
-
Stor.property.in.localstorage
|
|
5900
|
+
(Stor.property.in.localstorage
|
|
5554
5901
|
.for(TaonAdminModeConfigurationComponent)
|
|
5555
|
-
.withDefaultValue(0),
|
|
5902
|
+
.withDefaultValue(0)),
|
|
5556
5903
|
__metadata("design:type", Number)
|
|
5557
5904
|
], TaonAdminModeConfigurationComponent.prototype, "dragPositionY", void 0);
|
|
5558
5905
|
__decorate([
|
|
5559
|
-
Stor.property.in.localstorage
|
|
5906
|
+
(Stor.property.in.localstorage
|
|
5560
5907
|
.for(TaonAdminModeConfigurationComponent)
|
|
5561
|
-
.withDefaultValue(0),
|
|
5908
|
+
.withDefaultValue(0)),
|
|
5562
5909
|
__metadata("design:type", Number)
|
|
5563
5910
|
], TaonAdminModeConfigurationComponent.prototype, "selectedIndex", void 0);
|
|
5564
5911
|
__decorate([
|
|
5565
|
-
Stor.property.in.localstorage
|
|
5912
|
+
(Stor.property.in.localstorage
|
|
5566
5913
|
.for(TaonAdminModeConfigurationComponent)
|
|
5567
|
-
.withDefaultValue(false),
|
|
5914
|
+
.withDefaultValue(false)),
|
|
5568
5915
|
__metadata("design:type", Boolean)
|
|
5569
5916
|
], TaonAdminModeConfigurationComponent.prototype, "wasOpenDraggablePopup", void 0);
|
|
5570
5917
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminModeConfigurationComponent, decorators: [{
|
|
5571
5918
|
type: Component,
|
|
5572
|
-
args: [{ selector: 'app-taon-admin-mode-configuration', template: "<!-- #region basic global components -->\n<taon-session-passcode\n *ngIf=\"showPasscode\"\n [passcode]=\"passcode\"\n [message]=\"message\" />\n<!-- <taon-progress-bar [isDesktop]=\"isDesktop\"></taon-progress-bar> -->\n<!-- <taon-notifications></taon-notifications> -->\n<button\n mat-fab\n class=\"fab-button\"\n color=\"accent\"\n aria-label=\"Taon Admin Mode\"\n *ngIf=\"\n !admin.draggablePopupMode &&\n isDesktop &&\n !isIframe &&\n !hideTaonToolsInProduction\n \"\n (click)=\"toogle()\">\n <mat-icon>build</mat-icon>\n</button>\n<!-- #endregion -->\n\n<!-- #region small hidden button -->\n<!-- <button class=\"admin-show-button\"\n *ngIf=\"!admin.draggablePopupMode && isDesktop\"\n (click)=\"toogle()\"> Admin </button> -->\n<!-- #endregion -->\n\n<ng-template #contentNoScroll>\n <ng-content> </ng-content>\n</ng-template>\n\n<ng-template #content>\n <ng-scrollbar>\n <ng-container [ngTemplateOutlet]=\"contentNoScroll\"></ng-container>\n </ng-scrollbar>\n</ng-template>\n\n<!-- #region admin tabs -->\n<ng-template #adminTabs>\n <div class=\"taon-header-admin-wrapper\">\n <columns-container\n class=\"taon-header-admin\"\n [ngClass]=\"{ 'draggable-column': admin.draggablePopupMode }\">\n <column width=\"200\" class=\"logo-header\">\n <img\n *ngIf=\"openedOnce\"\n src=\"assets/assets-for/taon/shared/logo-header-admin-mode.png\" />\n </column>\n\n <column grow>\n <!-- <span>Super Admin Mode</span> -->\n </column>\n\n <column\n width=\"40\"\n *ngIf=\"\n !admin.draggablePopupModeFullScreen && !admin.draggablePopupMode\n \">\n <button\n mat-icon-button\n *ngIf=\"admin.draggablePopupMode\"\n (click)=\"\n admin.draggablePopupMode = false;\n opened = false;\n wasOpenDraggablePopup = true\n \"\n class=\"admin-close-button\">\n <mat-icon>close </mat-icon>\n </button>\n\n <button\n mat-icon-button\n *ngIf=\"!admin.draggablePopupMode\"\n (click)=\"toogle()\"\n class=\"admin-close-button\">\n <mat-icon>close</mat-icon>\n </button>\n </column>\n\n <column width=\"40\">\n <button\n mat-icon-button\n *ngIf=\"!admin.draggablePopupModeFullScreen\"\n class=\"admin-close-button\"\n (click)=\"toogleFullScreen()\">\n <mat-icon>fullscreen</mat-icon>\n </button>\n <button\n mat-icon-button\n *ngIf=\"admin.draggablePopupModeFullScreen\"\n class=\"admin-close-button\"\n (click)=\"toogleFullScreen()\">\n <mat-icon>close_fullscreen</mat-icon>\n </button>\n </column>\n\n <column width=\"40\" *ngIf=\"!admin.draggablePopupModeFullScreen\">\n <button\n mat-icon-button\n *ngIf=\"!admin.draggablePopupMode\"\n (click)=\"admin.draggablePopupMode = true\"\n class=\"admin-close-button\">\n <mat-icon>launch</mat-icon>\n </button>\n\n <button\n mat-icon-button\n *ngIf=\"admin.draggablePopupMode\"\n (click)=\"admin.draggablePopupMode = false; resetDrag()\"\n class=\"admin-close-button\">\n <mat-icon style=\"transform: rotate(180deg)\">login</mat-icon>\n </button>\n </column>\n </columns-container>\n </div>\n\n <columns-container\n [ngClass]=\"{ 'draggable-column': admin.draggablePopupMode }\">\n <column grow>\n <mat-tab-group\n dynamicHeight\n (wheel)=\"scrollTabs($event)\"\n #tabGroup\n [selectedIndex]=\"selectedIndex\"\n (selectedIndexChange)=\"selectedIndex = $event\">\n <mat-tab label=\"DB/Cache\">\n <section>\n <mat-card>\n <mat-card-header>\n <mat-card-subtitle>WEBSQL MODE</mat-card-subtitle>\n </mat-card-header>\n <mat-card-content>\n <mat-checkbox\n [disabled]=\"!isWebSQLMode\"\n [ngModel]=\"admin.keepWebsqlDbDataAfterReload\"\n (change)=\"\n admin.setKeepWebsqlDbDataAfterReload($event.checked)\n \">\n Don't remove data when reloading\n </mat-checkbox>\n </mat-card-content>\n </mat-card>\n </section>\n <br />\n <taon-db-admin />\n </mat-tab>\n\n <mat-tab label=\"Files\" *ngIf=\"admin.enabledTabs.includes('files')\">\n <section>\n <mat-checkbox\n [ngModel]=\"admin.filesEditMode\"\n (change)=\"admin.setEditMode($event.checked)\"\n >Edit mode</mat-checkbox\n >\n </section>\n <!-- admin.filesEditMode: {{ admin.filesEditMode }} -->\n <!-- <taon-admin-edit-mode *ngIf=\"admin.filesEditMode\">\n </taon-admin-edit-mode> -->\n <br />\n <hr *ngIf=\"admin.filesEditMode\" />\n <!-- <section>\n <button mat-raised-button>[TODO] Clear Files from browser cache </button> <br>\n <button mat-raised-button>[TODO] Start files export (as zip) </button> <br>\n <button mat-raised-button>[TODO] Import whole database (from zip) </button><br>\n </section> -->\n </mat-tab>\n <mat-tab *ngFor=\"let tab of tabs\" label=\"{{ tab.name }}\">\n <div\n class=\"full-tabs\"\n [style.height.px]=\"height - 150\"\n *ngIf=\"!isIframe\">\n <ng-container *ngTemplateOutlet=\"tab.template\"></ng-container>\n </div>\n <ng-container *ngIf=\"isIframe\">\n <ng-container *ngTemplateOutlet=\"tab.template\"></ng-container>\n </ng-container>\n </mat-tab>\n\n <!-- <mat-tab label=\"Portal\">\n <section>\n <mat-checkbox>[TODO] Maintenance Mode for whole portal</mat-checkbox>\n\n <mat-expansion-panel>\n\n <mat-expansion-panel-header>\n [TODO] Active User: 80432\n </mat-expansion-panel-header>\n <section>\n <button mat-raised-button>[TODO] Send notification to users </button><br>\n <button mat-raised-button>[TODO] Send email to users </button><br>\n </section>\n </mat-expansion-panel>\n <mat-expansion-panel>\n <mat-expansion-panel-header>\n [TODO] Enable features\n </mat-expansion-panel-header>\n <mat-checkbox>[TODO] AB testing</mat-checkbox> <br>\n <mat-checkbox>\n [TODO] Newsletter email question popup\n </mat-checkbox> <br>\n <mat-checkbox>\n [TODO] Promotion popup\n </mat-checkbox> <br>\n </mat-expansion-panel>\n </section>\n </mat-tab>\n <mat-tab label=\"User\">\n Welcome in user managements\n </mat-tab>\n <mat-tab label=\"Translations\">\n Welcome in user managements\n </mat-tab> -->\n </mat-tab-group>\n </column>\n </columns-container>\n</ng-template>\n<!-- #endregion -->\n\n<!-- #region small/mobile draggable popup windows -->\n<div\n class=\"draggable-popup-mode-window\"\n *ngIf=\"\n admin.draggablePopupMode && !admin.draggablePopupModeFullScreen && !isIframe\n \"\n cdkDrag\n [cdkDragFreeDragPosition]=\"dragPosition\"\n (cdkDragEnded)=\"moved($event)\">\n <ng-scrollbar>\n <ng-container [ngTemplateOutlet]=\"adminTabs\"></ng-container>\n </ng-scrollbar>\n</div>\n<!-- #endregion -->\n\n<!-- #region fullscreen draggable popup window -->\n<div\n class=\"draggable-popup-mode-window-full\"\n *ngIf=\"\n admin.draggablePopupMode &&\n admin.draggablePopupModeFullScreen &&\n !isIframe &&\n !reloading\n \"\n cdkDrag\n [cdkDragFreeDragPosition]=\"dragPositionZero\">\n <ng-container [ngTemplateOutlet]=\"adminTabs\"></ng-container>\n</div>\n<!-- #endregion -->\n\n<!-- #region content when not in draggable (or fullscreen draggable) popup -->\n<div\n [style.height.px]=\"height\"\n *ngIf=\"\n (isIframe ||\n !isDesktop ||\n admin.draggablePopupMode ||\n admin.draggablePopupModeFullScreen) &&\n !reloading\n \"\n style=\"width: 100%; display: block\"\n class=\"content\">\n <ng-container\n [ngTemplateOutlet]=\"\n admin.scrollableEnabled ? content : contentNoScroll\n \"></ng-container>\n</div>\n<!-- #endregion -->\n\n<!-- #region draggable popup window -->\n<mat-drawer-container\n *ngIf=\"!admin.draggablePopupMode && isDesktop && !isIframe\"\n class=\"example-container\"\n [style.height.px]=\"height\"\n style=\"background-color: transparent\"\n (backdropClick)=\"opened = false\"\n [hasBackdrop]=\"false\">\n <mat-drawer #drawer style=\"width: 580px\" [opened]=\"opened\" [mode]=\"'side'\">\n <ng-container [ngTemplateOutlet]=\"adminTabs\"></ng-container>\n </mat-drawer>\n <mat-drawer-content style=\"overflow: hidden\">\n <ng-container\n *ngIf=\"!admin.draggablePopupMode && !reloading\"\n [ngTemplateOutlet]=\"\n admin.scrollableEnabled ? content : contentNoScroll\n \"></ng-container>\n </mat-drawer-content>\n</mat-drawer-container>\n<!-- #endregion -->\n", styles: ["section{display:block;padding:10px}section>*{margin-top:0!important;margin-bottom:10px!important}section>*:last-child{margin-bottom:0!important}:host{display:block}.draggable-column{display:block!important;width:100%!important}.admin-show-button{position:fixed;bottom:100px;left:-15px;z-index:2147483647;transform:rotate(90deg);border:0px;color:#fff;background:gray;opacity:.1;cursor:pointer}.admin-show-button:hover{opacity:1}.taon-ui-super-admin-mode{font-family:JosefinSans-Bold;text-align:right;margin-right:10px}mat-drawer{margin:0;background-color:#dcdcdc!important}.taon-header-admin-wrapper{overflow:hidden;width:100%;display:block}.taon-header-admin{background:#fff;box-shadow:0 -9px 6px 6px #000;height:47px}.taon-header-admin .logo-header img{height:18px;padding:8px;position:relative;float:left;top:7px;box-sizing:content-box;transform:scale(1.5);left:49px}.draggable-popup-mode-window{width:600px;height:500px;border:solid 1px #ccc;color:#000000de;cursor:move;justify-content:center;align-items:center;background:#fff;border-radius:4px;position:fixed;z-index:105;background-color:#dcdcdc!important;transition:box-shadow .2s cubic-bezier(0,0,.2,1);box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f}.draggable-popup-mode-window:active{box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.draggable-popup-mode-window-full{width:100%;height:100%;overflow:scroll;color:#000000de;justify-content:center;align-items:center;background:#fff;border-radius:4px;position:fixed;z-index:105;background-color:#dcdcdc!important}.admin-close-button{float:right}.fab-button{position:fixed;right:110px;bottom:100px;z-index:10;background-color:#dcdcdc;color:#8f8f8f}.full-tabs{padding:10px}.mat-drawer-container-full-screen{background-color:red}\n"] }]
|
|
5573
|
-
|
|
5919
|
+
args: [{ selector: 'taon-admin-mode-configuration', standalone: true, imports: [
|
|
5920
|
+
CommonModule,
|
|
5921
|
+
StaticColumnsModule,
|
|
5922
|
+
FormsModule,
|
|
5923
|
+
NgScrollbarModule,
|
|
5924
|
+
TaonProgressBarModule,
|
|
5925
|
+
TaonNotificationsModule,
|
|
5926
|
+
TaonFullMaterialModule, // TODO import only partial things
|
|
5927
|
+
TaonSessionPasscodeComponent,
|
|
5928
|
+
], template: "<!-- #region basic global components -->\n<taon-session-passcode\n *ngIf=\"showPasscode\"\n [passcode]=\"passcode\"\n [message]=\"message\" />\n<!-- <taon-progress-bar [isDesktop]=\"isDesktop\"></taon-progress-bar> -->\n<!-- <taon-notifications></taon-notifications> -->\n<button\n mat-fab\n class=\"fab-button\"\n color=\"accent\"\n aria-label=\"Taon Admin Mode\"\n *ngIf=\"\n !admin.draggablePopupMode &&\n isDesktop &&\n !isIframe &&\n !hideTaonToolsInProduction\n \"\n (click)=\"toogle()\">\n <mat-icon>build</mat-icon>\n</button>\n<!-- #endregion -->\n\n<!-- #region small hidden button -->\n<!-- <button class=\"admin-show-button\"\n *ngIf=\"!admin.draggablePopupMode && isDesktop\"\n (click)=\"toogle()\"> Admin </button> -->\n<!-- #endregion -->\n\n<ng-template #contentNoScroll>\n <ng-content> </ng-content>\n</ng-template>\n\n<ng-template #content>\n <ng-scrollbar>\n <ng-container [ngTemplateOutlet]=\"contentNoScroll\"></ng-container>\n </ng-scrollbar>\n</ng-template>\n\n<!-- #region admin tabs -->\n<ng-template #adminTabs>\n <!-- #region admin tabs / header -->\n <div class=\"taon-header-admin-wrapper\">\n <columns-container\n class=\"taon-header-admin\"\n [ngClass]=\"{ 'draggable-column': admin.draggablePopupMode }\">\n <column\n width=\"200\"\n class=\"logo-header\">\n <img\n *ngIf=\"openedOnce\"\n src=\"assets/assets-for/taon/shared/logo-header-admin-mode.png\" />\n </column>\n\n <column grow>\n <!-- <span>Super Admin Mode</span> -->\n </column>\n\n <column\n width=\"40\"\n *ngIf=\"\n !admin.draggablePopupModeFullScreen && !admin.draggablePopupMode\n \">\n <button\n mat-icon-button\n *ngIf=\"admin.draggablePopupMode\"\n (click)=\"\n admin.draggablePopupMode = false;\n opened = false;\n wasOpenDraggablePopup = true\n \"\n class=\"admin-close-button\">\n <mat-icon>close </mat-icon>\n </button>\n\n <button\n mat-icon-button\n *ngIf=\"!admin.draggablePopupMode\"\n (click)=\"toogle()\"\n class=\"admin-close-button\">\n <mat-icon>close</mat-icon>\n </button>\n </column>\n\n <column width=\"40\">\n <button\n mat-icon-button\n *ngIf=\"!admin.draggablePopupModeFullScreen\"\n class=\"admin-close-button\"\n (click)=\"toogleFullScreen()\">\n <mat-icon>fullscreen</mat-icon>\n </button>\n <button\n mat-icon-button\n *ngIf=\"admin.draggablePopupModeFullScreen\"\n class=\"admin-close-button\"\n (click)=\"toogleFullScreen()\">\n <mat-icon>close_fullscreen</mat-icon>\n </button>\n </column>\n\n <column\n width=\"40\"\n *ngIf=\"!admin.draggablePopupModeFullScreen\">\n <button\n mat-icon-button\n *ngIf=\"!admin.draggablePopupMode\"\n (click)=\"admin.draggablePopupMode = true\"\n class=\"admin-close-button\">\n <mat-icon>launch</mat-icon>\n </button>\n\n <button\n mat-icon-button\n *ngIf=\"admin.draggablePopupMode\"\n (click)=\"admin.draggablePopupMode = false; resetDrag()\"\n class=\"admin-close-button\">\n <mat-icon style=\"transform: rotate(180deg)\">login</mat-icon>\n </button>\n </column>\n </columns-container>\n </div>\n <!-- #endregion -->\n\n <columns-container\n [ngClass]=\"{ 'draggable-column': admin.draggablePopupMode }\">\n <column grow>\n <mat-tab-group\n dynamicHeight\n (wheel)=\"scrollTabs($event)\"\n #tabGroup\n [selectedIndex]=\"selectedIndex\"\n (selectedIndexChange)=\"selectedIndex = $event\">\n <mat-tab label=\"DB/Cache\">\n <section>\n <mat-card>\n <mat-card-header>\n <mat-card-subtitle>WEBSQL MODE</mat-card-subtitle>\n </mat-card-header>\n <mat-card-content>\n <mat-checkbox\n [disabled]=\"!isWebSQLMode\"\n [ngModel]=\"admin.keepWebsqlDbDataAfterReload\"\n (change)=\"\n admin.setKeepWebsqlDbDataAfterReload($event.checked)\n \">\n Don't remove data when reloading\n </mat-checkbox>\n </mat-card-content>\n </mat-card>\n </section>\n <br />\n <taon-db-admin />\n </mat-tab>\n </mat-tab-group>\n </column>\n </columns-container>\n</ng-template>\n<!-- #endregion -->\n\n<!-- #region small/mobile draggable popup windows -->\n<div\n class=\"draggable-popup-mode-window\"\n *ngIf=\"\n admin.draggablePopupMode && !admin.draggablePopupModeFullScreen && !isIframe\n \"\n cdkDrag\n [cdkDragFreeDragPosition]=\"dragPosition\"\n (cdkDragEnded)=\"moved($event)\">\n <ng-scrollbar>\n <ng-container [ngTemplateOutlet]=\"adminTabs\"></ng-container>\n </ng-scrollbar>\n</div>\n<!-- #endregion -->\n\n<!-- #region fullscreen draggable popup window -->\n<div\n class=\"draggable-popup-mode-window-full\"\n *ngIf=\"\n admin.draggablePopupMode &&\n admin.draggablePopupModeFullScreen &&\n !isIframe &&\n !reloading\n \"\n cdkDrag\n [cdkDragFreeDragPosition]=\"dragPositionZero\">\n <ng-container [ngTemplateOutlet]=\"adminTabs\"></ng-container>\n</div>\n<!-- #endregion -->\n\n<!-- #region content when not in draggable (or fullscreen draggable) popup -->\n<div\n [style.height.px]=\"height\"\n *ngIf=\"\n (isIframe ||\n !isDesktop ||\n admin.draggablePopupMode ||\n admin.draggablePopupModeFullScreen) &&\n !reloading\n \"\n style=\"width: 100%; display: block\"\n class=\"content\">\n <ng-container\n [ngTemplateOutlet]=\"\n admin.scrollableEnabled ? content : contentNoScroll\n \"></ng-container>\n</div>\n<!-- #endregion -->\n\n<!-- #region draggable popup window -->\n<mat-drawer-container\n *ngIf=\"!admin.draggablePopupMode && isDesktop && !isIframe\"\n class=\"example-container\"\n [style.height.px]=\"height\"\n style=\"background-color: transparent\"\n (backdropClick)=\"opened = false\"\n [hasBackdrop]=\"false\">\n <mat-drawer\n #drawer\n style=\"width: 580px\"\n [opened]=\"opened\"\n [mode]=\"'side'\">\n <ng-container [ngTemplateOutlet]=\"adminTabs\"></ng-container>\n </mat-drawer>\n <mat-drawer-content style=\"overflow: hidden\">\n <ng-container\n *ngIf=\"!admin.draggablePopupMode && !reloading\"\n [ngTemplateOutlet]=\"\n admin.scrollableEnabled ? content : contentNoScroll\n \"></ng-container>\n </mat-drawer-content>\n</mat-drawer-container>\n<!-- #endregion -->\n", styles: ["section{display:block;padding:10px}section>*{margin-top:0!important;margin-bottom:10px!important}section>*:last-child{margin-bottom:0!important}:host{display:block}.draggable-column{display:block!important;width:100%!important}.admin-show-button{position:fixed;bottom:100px;left:-15px;z-index:2147483647;transform:rotate(90deg);border:0px;color:#fff;background:gray;opacity:.1;cursor:pointer}.admin-show-button:hover{opacity:1}.taon-ui-super-admin-mode{font-family:JosefinSans-Bold;text-align:right;margin-right:10px}mat-drawer{margin:0;background-color:#dcdcdc!important}.taon-header-admin-wrapper{overflow:hidden;width:100%;display:block}.taon-header-admin{background:#fff;box-shadow:0 -9px 6px 6px #000;height:47px}.taon-header-admin .logo-header img{height:18px;padding:8px;position:relative;float:left;top:7px;box-sizing:content-box;transform:scale(1.5);left:49px}.draggable-popup-mode-window{width:600px;height:500px;border:solid 1px #ccc;color:#000000de;cursor:move;justify-content:center;align-items:center;background:#fff;border-radius:4px;position:fixed;z-index:105;background-color:#dcdcdc!important;transition:box-shadow .2s cubic-bezier(0,0,.2,1);box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f}.draggable-popup-mode-window:active{box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.draggable-popup-mode-window-full{width:100%;height:100%;overflow:scroll;color:#000000de;justify-content:center;align-items:center;background:#fff;border-radius:4px;position:fixed;z-index:105;background-color:#dcdcdc!important}.admin-close-button{float:right}.fab-button{position:fixed;right:110px;bottom:100px;z-index:10;background-color:#dcdcdc;color:#8f8f8f}.full-tabs{padding:10px}.mat-drawer-container-full-screen{background-color:red}\n"] }]
|
|
5929
|
+
}], ctorParameters: () => [{ type: i1$3.BreakpointsService }, { type: TaonAdminService }], propDecorators: { tabGroup: [{
|
|
5574
5930
|
type: ViewChild,
|
|
5575
5931
|
args: ['tabGroup']
|
|
5576
5932
|
}], taonAdminModeConfigurationDataChanged: [{
|
|
@@ -5584,254 +5940,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.5", ngImpor
|
|
|
5584
5940
|
;
|
|
5585
5941
|
({}); // @--end-of-file-for-module=taon lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.component.ts
|
|
5586
5942
|
|
|
5587
|
-
class TaonAdminEditModeComponent {
|
|
5588
|
-
constructor(router) {
|
|
5589
|
-
this.router = router;
|
|
5590
|
-
this.inited$ = of(true);
|
|
5591
|
-
this.destroyed$ = new Subject();
|
|
5592
|
-
this.handlers = [];
|
|
5593
|
-
this.columns = [
|
|
5594
|
-
{
|
|
5595
|
-
header: 'ID',
|
|
5596
|
-
field: 'id',
|
|
5597
|
-
maxWidth: 100,
|
|
5598
|
-
showExpand: true,
|
|
5599
|
-
},
|
|
5600
|
-
{
|
|
5601
|
-
header: 'src',
|
|
5602
|
-
field: 'src',
|
|
5603
|
-
maxWidth: 250,
|
|
5604
|
-
},
|
|
5605
|
-
{
|
|
5606
|
-
header: 'Content Type',
|
|
5607
|
-
field: 'contentType',
|
|
5608
|
-
maxWidth: 120,
|
|
5609
|
-
},
|
|
5610
|
-
];
|
|
5611
|
-
this.taonAdminEditModeDataChanged = new EventEmitter();
|
|
5612
|
-
this.taonAdminEditModeData = {};
|
|
5613
|
-
}
|
|
5614
|
-
ngOnInit() {
|
|
5615
|
-
this.files = this.admin.currentFiles;
|
|
5616
|
-
this.handlers.push(this.admin.onEditMode$.subscribe(() => {
|
|
5617
|
-
this.refresFilesList();
|
|
5618
|
-
}));
|
|
5619
|
-
this.admin.onRegisterFile().pipe(takeUntil(this.destroyed$), tap(() => {
|
|
5620
|
-
this.refresFilesList();
|
|
5621
|
-
}));
|
|
5622
|
-
}
|
|
5623
|
-
ngOnDestroy() {
|
|
5624
|
-
this.handlers.forEach(h => h.unsubscribe());
|
|
5625
|
-
this.destroyed$.next(void 0);
|
|
5626
|
-
this.destroyed$.unsubscribe();
|
|
5627
|
-
}
|
|
5628
|
-
ngAfterViewInit() {
|
|
5629
|
-
//Called after ngAfterContentInit when the component's view has been initialized. Applies to components only.
|
|
5630
|
-
//Add 'implements AfterViewInit' to the class.
|
|
5631
|
-
setTimeout(() => {
|
|
5632
|
-
this.refresFilesList();
|
|
5633
|
-
}, 500);
|
|
5634
|
-
}
|
|
5635
|
-
expansionRow(e) {
|
|
5636
|
-
console.log(e);
|
|
5637
|
-
}
|
|
5638
|
-
refresFilesList() {
|
|
5639
|
-
this.files = this.admin.currentFiles;
|
|
5640
|
-
}
|
|
5641
|
-
searchFind(file) {
|
|
5642
|
-
if (!!this?.fileToSearch) {
|
|
5643
|
-
return file?.src?.search(this?.fileToSearch) !== -1;
|
|
5644
|
-
}
|
|
5645
|
-
return true;
|
|
5646
|
-
}
|
|
5647
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminEditModeComponent, deps: [{ token: i1$4.Router }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
5648
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.1.5", type: TaonAdminEditModeComponent, selector: "taon-admin-edit-mode", inputs: { taonAdminEditModeData: "taonAdminEditModeData" }, outputs: { taonAdminEditModeDataChanged: "taonAdminEditModeDataChanged" }, ngImport: i0, template: "<ng-template #expansionTpl let-row>\n hello from expansion {{ row.src }}\n</ng-template>\n\n<mat-card *ngIf=\"inited$ | async\">\n <div *ngIf=\"!admin.selectedFile\">Please select file from portal to edit</div>\n <taon-file\n *ngIf=\"admin.selectedFile\"\n class=\"file-inside-admin\"\n [insideAdmin]=\"true\"\n [file]=\"admin.selectedFile\"></taon-file>\n\n <hr />\n\n <mat-tab-group\n dynamicHeight\n [selectedIndex]=\"selectedTabIndex\"\n (selectedIndexChange)=\"selectedTabIndex = $event; refresFilesList()\">\n <mat-tab label=\"General\">\n <!-- <taon-file-general-opt\n [file]=\"admin.selectedFile\"></taon-file-general-opt> -->\n </mat-tab>\n <!-- <mat-tab label=\"CSS Editing\">\n <ace [mode]=\"'css'\"\n *ngIf=\"admin.selectedFile\"\n [(value)]=\"admin.selectedFile.css\"\n [theme]=\"'github'\"\n style=\"width: 100%; height: 300px;\"></ace>\n </mat-tab> -->\n\n <mat-tab label=\"Files Picker\">\n <!-- <taon-table\n [entity]=\"entity\"\n [allowedColumns]=\"['src', 'contentType']\"\n [columns]=\"columns\"\n [expansionTemplate]=\"expansionTpl\"\n (expansionChange)=\"expansionRow($event)\">\n </taon-table> -->\n </mat-tab>\n <mat-tab label=\"File Version History\">\n <!-- <taon-table\n [entity]=\"entity\"\n [allowedColumns]=\"['src', 'contentType']\"\n [columns]=\"columns\"\n [expansionTemplate]=\"expansionTpl\"\n (expansionChange)=\"expansionRow($event)\">\n </taon-table> -->\n </mat-tab>\n <mat-tab label=\"Current File\">\n <columns-container *ngIf=\"files.length > 0\">\n <column grow>\n <mat-form-field style=\"width: 100%\">\n <input\n matInput\n [(ngModel)]=\"fileToSearch\"\n (focus)=\"refresFilesList()\"\n placeholder=\"Search by name\" />\n </mat-form-field>\n </column>\n <column [width]=\"40\">\n <button\n mat-icon-button\n (click)=\"fileToSearch = ''; refresFilesList()\"\n *ngIf=\"fileToSearch && fileToSearch?.trim() !== ''\">\n <mat-icon>backspace</mat-icon>\n </button>\n </column>\n <!-- <column [width]=\"40\">\n <button mat-icon-button (click)=\"refresFilesList();\" >\n <mat-icon >refresh</mat-icon>\n </button>\n </column> -->\n </columns-container>\n <columns-container *ngIf=\"files.length == 0\">\n <section>\n <code\n >No <taon-file/> - s components detected on this page</code\n >\n </section>\n </columns-container>\n\n <div class=\"scrollable-files-list\" *ngIf=\"files.length > 0\">\n <ng-scrollbar>\n <!-- selected: \"{{ selectedFile?.src }}\" -->\n <!-- {{ filesSelection.selectedOptions | json }} -->\n <mat-selection-list\n [multiple]=\"false\"\n #filesToSelect\n (selectionChange)=\"\n admin.selectedFile = filesToSelect.selectedOptions.hasValue()\n ? filesToSelect.selectedOptions.selected[0].value\n : null\n \">\n <mat-list-option\n *ngFor=\"let file of files | filterBy: ['src'] : fileToSearch\"\n [value]=\"file\">\n <strong *ngIf=\"file?.src === admin.selectedFile?.src\">\n {{ file.src }}\n </strong>\n <span *ngIf=\"file?.src !== admin.selectedFile?.src\">\n {{ file.src }}\n </span>\n </mat-list-option>\n </mat-selection-list>\n </ng-scrollbar>\n </div>\n </mat-tab>\n </mat-tab-group>\n</mat-card>\n", styles: [":host{display:block}.scrollable-files-list{height:150px;background:#8080801c;display:block}\n"], dependencies: [{ kind: "directive", type: i2$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i1$3.ColumnsComponent, selector: "columns-container" }, { kind: "component", type: i1$3.ColumnComponent, selector: "column", inputs: ["width"] }, { kind: "directive", type: i1$3.DirectiveGrow, selector: "[grow]" }, { kind: "component", type: i4$1.NgScrollbar, selector: "ng-scrollbar:not([externalViewport])", exportAs: ["ngScrollbar"] }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i6$1.MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "component", type: i7.MatCard, selector: "mat-card", inputs: ["appearance"], exportAs: ["matCard"] }, { kind: "component", type: i6.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: i4.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { kind: "component", type: i2$2.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "component", type: i11$1.MatSelectionList, selector: "mat-selection-list", inputs: ["color", "compareWith", "multiple", "hideSingleSelectionIndicator", "disabled"], outputs: ["selectionChange"], exportAs: ["matSelectionList"] }, { kind: "component", type: i11$1.MatListOption, selector: "mat-list-option", inputs: ["togglePosition", "checkboxPosition", "color", "value", "selected"], outputs: ["selectedChange"], exportAs: ["matListOption"] }, { kind: "component", type: i11.MatTab, selector: "mat-tab", inputs: ["disabled", "label", "aria-label", "aria-labelledby", "labelClass", "bodyClass"], exportAs: ["matTab"] }, { kind: "component", type: i11.MatTabGroup, selector: "mat-tab-group", inputs: ["color", "fitInkBarToContent", "mat-stretch-tabs", "dynamicHeight", "selectedIndex", "headerPosition", "animationDuration", "contentTabIndex", "disablePagination", "disableRipple", "preserveContent", "backgroundColor", "aria-label", "aria-labelledby"], outputs: ["selectedIndexChange", "focusChange", "animationDone", "selectedTabChange"], exportAs: ["matTabGroup"] }, { kind: "pipe", type: i2$1.AsyncPipe, name: "async" }, { kind: "pipe", type: i13.FilterByPipe, name: "filterBy" }] }); }
|
|
5649
|
-
}
|
|
5650
|
-
__decorate([
|
|
5651
|
-
(Stor.property.in.localstorage
|
|
5652
|
-
.for(TaonAdminEditModeComponent)
|
|
5653
|
-
.withDefaultValue(0)),
|
|
5654
|
-
__metadata("design:type", Number)
|
|
5655
|
-
], TaonAdminEditModeComponent.prototype, "selectedTabIndex", void 0);
|
|
5656
|
-
__decorate([
|
|
5657
|
-
(Stor.property.in.localstorage
|
|
5658
|
-
.for(TaonAdminEditModeComponent)
|
|
5659
|
-
.withDefaultValue('')),
|
|
5660
|
-
__metadata("design:type", String)
|
|
5661
|
-
], TaonAdminEditModeComponent.prototype, "fileToSearch", void 0);
|
|
5662
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminEditModeComponent, decorators: [{
|
|
5663
|
-
type: Component,
|
|
5664
|
-
args: [{ selector: 'taon-admin-edit-mode', template: "<ng-template #expansionTpl let-row>\n hello from expansion {{ row.src }}\n</ng-template>\n\n<mat-card *ngIf=\"inited$ | async\">\n <div *ngIf=\"!admin.selectedFile\">Please select file from portal to edit</div>\n <taon-file\n *ngIf=\"admin.selectedFile\"\n class=\"file-inside-admin\"\n [insideAdmin]=\"true\"\n [file]=\"admin.selectedFile\"></taon-file>\n\n <hr />\n\n <mat-tab-group\n dynamicHeight\n [selectedIndex]=\"selectedTabIndex\"\n (selectedIndexChange)=\"selectedTabIndex = $event; refresFilesList()\">\n <mat-tab label=\"General\">\n <!-- <taon-file-general-opt\n [file]=\"admin.selectedFile\"></taon-file-general-opt> -->\n </mat-tab>\n <!-- <mat-tab label=\"CSS Editing\">\n <ace [mode]=\"'css'\"\n *ngIf=\"admin.selectedFile\"\n [(value)]=\"admin.selectedFile.css\"\n [theme]=\"'github'\"\n style=\"width: 100%; height: 300px;\"></ace>\n </mat-tab> -->\n\n <mat-tab label=\"Files Picker\">\n <!-- <taon-table\n [entity]=\"entity\"\n [allowedColumns]=\"['src', 'contentType']\"\n [columns]=\"columns\"\n [expansionTemplate]=\"expansionTpl\"\n (expansionChange)=\"expansionRow($event)\">\n </taon-table> -->\n </mat-tab>\n <mat-tab label=\"File Version History\">\n <!-- <taon-table\n [entity]=\"entity\"\n [allowedColumns]=\"['src', 'contentType']\"\n [columns]=\"columns\"\n [expansionTemplate]=\"expansionTpl\"\n (expansionChange)=\"expansionRow($event)\">\n </taon-table> -->\n </mat-tab>\n <mat-tab label=\"Current File\">\n <columns-container *ngIf=\"files.length > 0\">\n <column grow>\n <mat-form-field style=\"width: 100%\">\n <input\n matInput\n [(ngModel)]=\"fileToSearch\"\n (focus)=\"refresFilesList()\"\n placeholder=\"Search by name\" />\n </mat-form-field>\n </column>\n <column [width]=\"40\">\n <button\n mat-icon-button\n (click)=\"fileToSearch = ''; refresFilesList()\"\n *ngIf=\"fileToSearch && fileToSearch?.trim() !== ''\">\n <mat-icon>backspace</mat-icon>\n </button>\n </column>\n <!-- <column [width]=\"40\">\n <button mat-icon-button (click)=\"refresFilesList();\" >\n <mat-icon >refresh</mat-icon>\n </button>\n </column> -->\n </columns-container>\n <columns-container *ngIf=\"files.length == 0\">\n <section>\n <code\n >No <taon-file/> - s components detected on this page</code\n >\n </section>\n </columns-container>\n\n <div class=\"scrollable-files-list\" *ngIf=\"files.length > 0\">\n <ng-scrollbar>\n <!-- selected: \"{{ selectedFile?.src }}\" -->\n <!-- {{ filesSelection.selectedOptions | json }} -->\n <mat-selection-list\n [multiple]=\"false\"\n #filesToSelect\n (selectionChange)=\"\n admin.selectedFile = filesToSelect.selectedOptions.hasValue()\n ? filesToSelect.selectedOptions.selected[0].value\n : null\n \">\n <mat-list-option\n *ngFor=\"let file of files | filterBy: ['src'] : fileToSearch\"\n [value]=\"file\">\n <strong *ngIf=\"file?.src === admin.selectedFile?.src\">\n {{ file.src }}\n </strong>\n <span *ngIf=\"file?.src !== admin.selectedFile?.src\">\n {{ file.src }}\n </span>\n </mat-list-option>\n </mat-selection-list>\n </ng-scrollbar>\n </div>\n </mat-tab>\n </mat-tab-group>\n</mat-card>\n", styles: [":host{display:block}.scrollable-files-list{height:150px;background:#8080801c;display:block}\n"] }]
|
|
5665
|
-
}], ctorParameters: () => [{ type: i1$4.Router }], propDecorators: { taonAdminEditModeDataChanged: [{
|
|
5666
|
-
type: Output
|
|
5667
|
-
}], taonAdminEditModeData: [{
|
|
5668
|
-
type: Input
|
|
5669
|
-
}] } });
|
|
5670
|
-
;
|
|
5671
|
-
({}); // @--end-of-file-for-module=taon lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.component.ts
|
|
5672
|
-
|
|
5673
|
-
class TaonFileGeneralOptComponent {
|
|
5674
|
-
constructor() {
|
|
5675
|
-
this.height = 100;
|
|
5676
|
-
this.handlers = [];
|
|
5677
|
-
this.fieldsOrder = [];
|
|
5678
|
-
this.fields = [
|
|
5679
|
-
{
|
|
5680
|
-
key: 'width',
|
|
5681
|
-
},
|
|
5682
|
-
{
|
|
5683
|
-
key: 'height',
|
|
5684
|
-
},
|
|
5685
|
-
{
|
|
5686
|
-
key: 'display',
|
|
5687
|
-
},
|
|
5688
|
-
{
|
|
5689
|
-
key: 'widthUnit',
|
|
5690
|
-
},
|
|
5691
|
-
{
|
|
5692
|
-
key: 'heightUnit', // @ts-ignore
|
|
5693
|
-
},
|
|
5694
|
-
{
|
|
5695
|
-
key: 'action',
|
|
5696
|
-
type: 'action',
|
|
5697
|
-
templateOptions: {
|
|
5698
|
-
label: 'Reset',
|
|
5699
|
-
icon: 'cancel',
|
|
5700
|
-
raised: true,
|
|
5701
|
-
action: () => {
|
|
5702
|
-
console.log('reset');
|
|
5703
|
-
},
|
|
5704
|
-
},
|
|
5705
|
-
},
|
|
5706
|
-
].map(f => {
|
|
5707
|
-
f.className = 'formly-field-half-size';
|
|
5708
|
-
return f;
|
|
5709
|
-
});
|
|
5710
|
-
}
|
|
5711
|
-
ngOnInit() { }
|
|
5712
|
-
ngOnDestroy() {
|
|
5713
|
-
this.handlers.forEach(h => h.unsubscribe());
|
|
5714
|
-
}
|
|
5715
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonFileGeneralOptComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
5716
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.1.5", type: TaonFileGeneralOptComponent, selector: "taon-file-general-opt", inputs: { height: "height", file: "file" }, host: { properties: { "style.minHeight.px": "this.height" } }, ngImport: i0, template: "<!-- <taon-formly-form\n *ngIf=\"file\"\n [fields]=\"fields\"\n [fieldsOrder]=\"fieldsOrder\"\n [exclude]=\"['id']\"\n [(model)]=\"file.css\">\n</taon-formly-form> -->\n", styles: [":host{display:block}\n"] }); }
|
|
5717
|
-
}
|
|
5718
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonFileGeneralOptComponent, decorators: [{
|
|
5719
|
-
type: Component,
|
|
5720
|
-
args: [{ selector: 'taon-file-general-opt', template: "<!-- <taon-formly-form\n *ngIf=\"file\"\n [fields]=\"fields\"\n [fieldsOrder]=\"fieldsOrder\"\n [exclude]=\"['id']\"\n [(model)]=\"file.css\">\n</taon-formly-form> -->\n", styles: [":host{display:block}\n"] }]
|
|
5721
|
-
}], ctorParameters: () => [], propDecorators: { height: [{
|
|
5722
|
-
type: HostBinding,
|
|
5723
|
-
args: ['style.minHeight.px']
|
|
5724
|
-
}, {
|
|
5725
|
-
type: Input
|
|
5726
|
-
}], file: [{
|
|
5727
|
-
type: Input
|
|
5728
|
-
}] } });
|
|
5729
|
-
;
|
|
5730
|
-
({}); // @--end-of-file-for-module=taon lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.component.ts
|
|
5731
|
-
|
|
5732
|
-
class TaonFileGeneralOptModule {
|
|
5733
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonFileGeneralOptModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
5734
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.1.5", ngImport: i0, type: TaonFileGeneralOptModule, declarations: [TaonFileGeneralOptComponent], imports: [CommonModule, TaonFullMaterialModule], exports: [TaonFileGeneralOptComponent] }); }
|
|
5735
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonFileGeneralOptModule, imports: [CommonModule, TaonFullMaterialModule] }); }
|
|
5736
|
-
}
|
|
5737
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonFileGeneralOptModule, decorators: [{
|
|
5738
|
-
type: NgModule,
|
|
5739
|
-
args: [{
|
|
5740
|
-
imports: [CommonModule, TaonFullMaterialModule],
|
|
5741
|
-
declarations: [TaonFileGeneralOptComponent],
|
|
5742
|
-
exports: [TaonFileGeneralOptComponent],
|
|
5743
|
-
}]
|
|
5744
|
-
}] });
|
|
5745
|
-
;
|
|
5746
|
-
({}); // @--end-of-file-for-module=taon lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/taon-file-general-opt.module.ts
|
|
5747
|
-
|
|
5748
|
-
;
|
|
5749
|
-
({}); // @--end-of-file-for-module=taon lib/ui/taon-admin-mode-configuration/components/taon-file-general-opt/index.ts
|
|
5750
|
-
|
|
5751
|
-
class TaonAdminEditModeModule {
|
|
5752
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminEditModeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
5753
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminEditModeModule, declarations: [TaonAdminEditModeComponent], imports: [CommonModule,
|
|
5754
|
-
StaticColumnsModule,
|
|
5755
|
-
NgScrollbarModule,
|
|
5756
|
-
TaonFileGeneralOptModule,
|
|
5757
|
-
FormsModule,
|
|
5758
|
-
NgArrayPipesModule,
|
|
5759
|
-
TaonTableModule,
|
|
5760
|
-
TaonFullMaterialModule], exports: [TaonAdminEditModeComponent] }); }
|
|
5761
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminEditModeModule, imports: [CommonModule,
|
|
5762
|
-
StaticColumnsModule,
|
|
5763
|
-
NgScrollbarModule,
|
|
5764
|
-
TaonFileGeneralOptModule,
|
|
5765
|
-
FormsModule,
|
|
5766
|
-
NgArrayPipesModule,
|
|
5767
|
-
TaonTableModule,
|
|
5768
|
-
TaonFullMaterialModule] }); }
|
|
5769
|
-
}
|
|
5770
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminEditModeModule, decorators: [{
|
|
5771
|
-
type: NgModule,
|
|
5772
|
-
args: [{
|
|
5773
|
-
imports: [
|
|
5774
|
-
CommonModule,
|
|
5775
|
-
StaticColumnsModule,
|
|
5776
|
-
NgScrollbarModule,
|
|
5777
|
-
TaonFileGeneralOptModule,
|
|
5778
|
-
FormsModule,
|
|
5779
|
-
NgArrayPipesModule,
|
|
5780
|
-
TaonTableModule,
|
|
5781
|
-
TaonFullMaterialModule, // TODO import only partial things
|
|
5782
|
-
],
|
|
5783
|
-
declarations: [TaonAdminEditModeComponent],
|
|
5784
|
-
exports: [TaonAdminEditModeComponent],
|
|
5785
|
-
}]
|
|
5786
|
-
}] });
|
|
5787
|
-
;
|
|
5788
|
-
({}); // @--end-of-file-for-module=taon lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/taon-admin-edit-mode.module.ts
|
|
5789
|
-
|
|
5790
|
-
;
|
|
5791
|
-
({}); // @--end-of-file-for-module=taon lib/ui/taon-admin-mode-configuration/components/taon-admin-edit-mode/index.ts
|
|
5792
|
-
|
|
5793
|
-
class TaonAdminModeConfigurationModule {
|
|
5794
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminModeConfigurationModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
5795
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminModeConfigurationModule, declarations: [TaonAdminModeConfigurationComponent], imports: [CommonModule,
|
|
5796
|
-
StaticColumnsModule,
|
|
5797
|
-
FormsModule,
|
|
5798
|
-
NgScrollbarModule,
|
|
5799
|
-
TaonAdminEditModeModule,
|
|
5800
|
-
TaonProgressBarModule,
|
|
5801
|
-
TaonNotificationsModule,
|
|
5802
|
-
TaonFullMaterialModule, // TODO import only partial things
|
|
5803
|
-
TaonSessionPasscodeComponent], exports: [TaonAdminModeConfigurationComponent] }); }
|
|
5804
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminModeConfigurationModule, imports: [CommonModule,
|
|
5805
|
-
StaticColumnsModule,
|
|
5806
|
-
FormsModule,
|
|
5807
|
-
NgScrollbarModule,
|
|
5808
|
-
TaonAdminEditModeModule,
|
|
5809
|
-
TaonProgressBarModule,
|
|
5810
|
-
TaonNotificationsModule,
|
|
5811
|
-
TaonFullMaterialModule, // TODO import only partial things
|
|
5812
|
-
TaonSessionPasscodeComponent] }); }
|
|
5813
|
-
}
|
|
5814
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.5", ngImport: i0, type: TaonAdminModeConfigurationModule, decorators: [{
|
|
5815
|
-
type: NgModule,
|
|
5816
|
-
args: [{
|
|
5817
|
-
imports: [
|
|
5818
|
-
CommonModule,
|
|
5819
|
-
StaticColumnsModule,
|
|
5820
|
-
FormsModule,
|
|
5821
|
-
NgScrollbarModule,
|
|
5822
|
-
TaonAdminEditModeModule,
|
|
5823
|
-
TaonProgressBarModule,
|
|
5824
|
-
TaonNotificationsModule,
|
|
5825
|
-
TaonFullMaterialModule, // TODO import only partial things
|
|
5826
|
-
TaonSessionPasscodeComponent,
|
|
5827
|
-
],
|
|
5828
|
-
declarations: [TaonAdminModeConfigurationComponent],
|
|
5829
|
-
exports: [TaonAdminModeConfigurationComponent],
|
|
5830
|
-
}]
|
|
5831
|
-
}] });
|
|
5832
|
-
;
|
|
5833
|
-
({}); // @--end-of-file-for-module=taon lib/ui/taon-admin-mode-configuration/taon-admin-mode-configuration.module.ts
|
|
5834
|
-
|
|
5835
5943
|
;
|
|
5836
5944
|
({}); // @--end-of-file-for-module=taon lib/ui/taon-admin-mode-configuration/index.ts
|
|
5837
5945
|
|
|
@@ -5852,6 +5960,7 @@ var Taon;
|
|
|
5852
5960
|
Taon.Provider = TaonProvider;
|
|
5853
5961
|
Taon.Repository = TaonRepository;
|
|
5854
5962
|
Taon.Subscriber = TaonSubscriber;
|
|
5963
|
+
Taon.Migration = TaonMigration;
|
|
5855
5964
|
Taon.isBrowser = coreHelpers.Helpers.isBrowser;
|
|
5856
5965
|
Taon.isNode = coreHelpers.Helpers.isNode;
|
|
5857
5966
|
Taon.isWebSQL = coreHelpers.Helpers.isWebSQL;
|
|
@@ -5888,5 +5997,5 @@ var Taon;
|
|
|
5888
5997
|
* Generated bundle index. Do not edit.
|
|
5889
5998
|
*/
|
|
5890
5999
|
|
|
5891
|
-
export { BaseContext, BaseController, BaseEntity, BaseProvider, BaseRepository, ClassHelpers, Models, SafePipe, Taon, TaonAdminModeConfigurationComponent,
|
|
6000
|
+
export { BaseContext, BaseController, BaseEntity, BaseMigration, BaseProvider, BaseRepository, ClassHelpers, Models, SafePipe, Taon, TaonAdminModeConfigurationComponent, TaonFullMaterialModule, TaonGithubForkMeCornerComponent, TaonGithubForkMeCornerModule, TaonInjectHTMLDirective, TaonLongPress, TaonNotificationOptions, TaonNotificationsComponent, TaonNotificationsModule, TaonNotificationsService, TaonProgressBarComponent, TaonProgressBarModule, TaonSessionPasscodeComponent, TaonTableComponent, TaonTableModule, createContext, inject };
|
|
5892
6001
|
//# sourceMappingURL=taon.mjs.map
|