taon 19.0.4 → 19.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (181) hide show
  1. package/README.md +175 -175
  2. package/assets/shared/shared_folder_info.txt +1 -1
  3. package/bin/start.js +279 -279
  4. package/bin/taon +6 -6
  5. package/bin/taon-debug +5 -5
  6. package/bin/taon-debug-brk +5 -5
  7. package/browser/README.md +24 -24
  8. package/browser/fesm2022/taon.mjs +1313 -259
  9. package/browser/fesm2022/taon.mjs.map +1 -1
  10. package/browser/lib/base-classes/base-class.d.ts +1 -1
  11. package/browser/lib/base-classes/base-context.d.ts +6 -6
  12. package/browser/lib/base-classes/base-repository.d.ts +3 -2
  13. package/browser/lib/base-classes/base.d.ts +6 -6
  14. package/browser/lib/create-context.d.ts +12 -12
  15. package/browser/lib/index.d.ts +18 -18
  16. package/browser/lib/inject.d.ts +4 -1
  17. package/browser/lib/ui/taon-table/taon-table.component.d.ts +8 -7
  18. package/browser/package.json +1 -1
  19. package/cli.js.map +1 -1
  20. package/client/README.md +24 -24
  21. package/client/fesm2022/taon.mjs +1313 -259
  22. package/client/fesm2022/taon.mjs.map +1 -1
  23. package/client/lib/base-classes/base-class.d.ts +1 -1
  24. package/client/lib/base-classes/base-context.d.ts +6 -6
  25. package/client/lib/base-classes/base-repository.d.ts +3 -2
  26. package/client/lib/base-classes/base.d.ts +6 -6
  27. package/client/lib/create-context.d.ts +12 -12
  28. package/client/lib/index.d.ts +18 -18
  29. package/client/lib/inject.d.ts +4 -1
  30. package/client/lib/ui/taon-table/taon-table.component.d.ts +8 -7
  31. package/client/package.json +1 -1
  32. package/index.js.map +1 -1
  33. package/lib/base-classes/base-abstract-entity.js +2 -2
  34. package/lib/base-classes/base-abstract-entity.js.map +1 -1
  35. package/lib/base-classes/base-class.d.ts +1 -1
  36. package/lib/base-classes/base-class.js +13 -4
  37. package/lib/base-classes/base-class.js.map +1 -1
  38. package/lib/base-classes/base-context.d.ts +6 -6
  39. package/lib/base-classes/base-context.js.map +1 -1
  40. package/lib/base-classes/base-controller.js.map +1 -1
  41. package/lib/base-classes/base-crud-controller.js +6 -6
  42. package/lib/base-classes/base-crud-controller.js.map +1 -1
  43. package/lib/base-classes/base-entity.js +2 -2
  44. package/lib/base-classes/base-entity.js.map +1 -1
  45. package/lib/base-classes/base-injector.js +2 -2
  46. package/lib/base-classes/base-injector.js.map +1 -1
  47. package/lib/base-classes/base-migration.d.ts +1 -1
  48. package/lib/base-classes/base-migration.js +2 -2
  49. package/lib/base-classes/base-migration.js.map +1 -1
  50. package/lib/base-classes/base-provider.js.map +1 -1
  51. package/lib/base-classes/base-repository.d.ts +3 -2
  52. package/lib/base-classes/base-repository.js +14 -11
  53. package/lib/base-classes/base-repository.js.map +1 -1
  54. package/lib/base-classes/base-subscriber-for-entity.d.ts +1 -1
  55. package/lib/base-classes/base-subscriber-for-entity.js.map +1 -1
  56. package/lib/base-classes/base.d.ts +6 -6
  57. package/lib/base-classes/base.js.map +1 -1
  58. package/lib/build-info._auto-generated_.d.ts +2 -1
  59. package/lib/build-info._auto-generated_.js +3 -2
  60. package/lib/build-info._auto-generated_.js.map +1 -1
  61. package/lib/constants.js.map +1 -1
  62. package/lib/context-db-migrations.d.ts +1 -1
  63. package/lib/context-db-migrations.js +7 -7
  64. package/lib/context-db-migrations.js.map +1 -1
  65. package/lib/create-context.d.ts +12 -12
  66. package/lib/create-context.js +13 -13
  67. package/lib/create-context.js.map +1 -1
  68. package/lib/decorators/classes/controller-decorator.js.map +1 -1
  69. package/lib/decorators/classes/entity-decorator.d.ts +1 -1
  70. package/lib/decorators/classes/entity-decorator.js +8 -8
  71. package/lib/decorators/classes/entity-decorator.js.map +1 -1
  72. package/lib/decorators/classes/migration-decorator.js.map +1 -1
  73. package/lib/decorators/classes/provider-decorator.js.map +1 -1
  74. package/lib/decorators/classes/repository-decorator.js.map +1 -1
  75. package/lib/decorators/classes/subscriber-decorator.js.map +1 -1
  76. package/lib/decorators/http/http-decorators.d.ts +1 -1
  77. package/lib/decorators/http/http-decorators.js +2 -2
  78. package/lib/decorators/http/http-decorators.js.map +1 -1
  79. package/lib/decorators/http/http-methods-decorators.d.ts +1 -1
  80. package/lib/decorators/http/http-methods-decorators.js +2 -2
  81. package/lib/decorators/http/http-methods-decorators.js.map +1 -1
  82. package/lib/decorators/http/http-params-decorators.js.map +1 -1
  83. package/lib/dependency-injection/di-container.js.map +1 -1
  84. package/lib/endpoint-context.js +112 -112
  85. package/lib/endpoint-context.js.map +1 -1
  86. package/lib/entity-process.js +35 -35
  87. package/lib/entity-process.js.map +1 -1
  88. package/lib/env.js +2 -2
  89. package/lib/env.js.map +1 -1
  90. package/lib/formly/formly-group-wrapper-component.js.map +1 -1
  91. package/lib/formly/formly-repeat-component.js.map +1 -1
  92. package/lib/formly/formly.models.js.map +1 -1
  93. package/lib/formly/fromly.d.ts +1 -1
  94. package/lib/formly/fromly.js +26 -26
  95. package/lib/formly/fromly.js.map +1 -1
  96. package/lib/formly/type-from-entity.js +6 -6
  97. package/lib/formly/type-from-entity.js.map +1 -1
  98. package/lib/get-response-value.js +2 -2
  99. package/lib/get-response-value.js.map +1 -1
  100. package/lib/helpers/class-helpers.js +21 -21
  101. package/lib/helpers/class-helpers.js.map +1 -1
  102. package/lib/helpers/taon-helpers.js +4 -4
  103. package/lib/helpers/taon-helpers.js.map +1 -1
  104. package/lib/index._auto-generated_.js.map +1 -1
  105. package/lib/index.d.ts +18 -18
  106. package/lib/index.js +1 -1
  107. package/lib/index.js.map +1 -1
  108. package/lib/inject.js +0 -5
  109. package/lib/inject.js.map +1 -1
  110. package/lib/models.d.ts +1 -1
  111. package/lib/models.js +5 -5
  112. package/lib/models.js.map +1 -1
  113. package/lib/orm.d.ts +1 -1
  114. package/lib/orm.js +4 -4
  115. package/lib/orm.js.map +1 -1
  116. package/lib/realtime/realtime-client.js +3 -3
  117. package/lib/realtime/realtime-client.js.map +1 -1
  118. package/lib/realtime/realtime-core.js +3 -3
  119. package/lib/realtime/realtime-core.js.map +1 -1
  120. package/lib/realtime/realtime-server.js +7 -7
  121. package/lib/realtime/realtime-server.js.map +1 -1
  122. package/lib/realtime/realtime-strategy/index.js.map +1 -1
  123. package/lib/realtime/realtime-strategy/realtime-strategy-ipc.js.map +1 -1
  124. package/lib/realtime/realtime-strategy/realtime-strategy-mock.js.map +1 -1
  125. package/lib/realtime/realtime-strategy/realtime-strategy-socket-io.js.map +1 -1
  126. package/lib/realtime/realtime-strategy/realtime-strategy.js.map +1 -1
  127. package/lib/realtime/realtime-subs-manager.js +3 -3
  128. package/lib/realtime/realtime-subs-manager.js.map +1 -1
  129. package/lib/realtime/realtime.models.js.map +1 -1
  130. package/lib/storage.js +2 -2
  131. package/lib/storage.js.map +1 -1
  132. package/lib/symbols.js +7 -7
  133. package/lib/symbols.js.map +1 -1
  134. package/lib/ui/directives/index.js +2 -2
  135. package/lib/ui/directives/index.js.map +1 -1
  136. package/lib/ui/directives/view-mode.js.map +1 -1
  137. package/lib/ui/index.js +2 -2
  138. package/lib/ui/index.js.map +1 -1
  139. package/lib/ui/taon-admin-mode-configuration/index.js +2 -2
  140. package/lib/ui/taon-admin-mode-configuration/index.js.map +1 -1
  141. package/lib/ui/taon-admin-mode-configuration/taon-admin.models.js.map +1 -1
  142. package/lib/ui/taon-github-fork-me-corner/index.js +2 -2
  143. package/lib/ui/taon-github-fork-me-corner/index.js.map +1 -1
  144. package/lib/ui/taon-github-fork-me-ribbon/index.js +2 -2
  145. package/lib/ui/taon-github-fork-me-ribbon/index.js.map +1 -1
  146. package/lib/ui/taon-notifications/index.js.map +1 -1
  147. package/lib/ui/taon-notifications/taon-notifications.models.js +2 -2
  148. package/lib/ui/taon-notifications/taon-notifications.models.js.map +1 -1
  149. package/lib/ui/taon-progress-bar/index.js +2 -2
  150. package/lib/ui/taon-progress-bar/index.js.map +1 -1
  151. package/lib/ui/taon-session-passcode/index.js +2 -2
  152. package/lib/ui/taon-session-passcode/index.js.map +1 -1
  153. package/lib/ui/taon-table/index.js +2 -2
  154. package/lib/ui/taon-table/index.js.map +1 -1
  155. package/lib/ui/taon-table/taon-table.component.d.ts +7 -6
  156. package/lib/ui/taon.models.d.ts +1 -1
  157. package/lib/ui/taon.models.js.map +1 -1
  158. package/lib/validators.js +8 -8
  159. package/lib/validators.js.map +1 -1
  160. package/migrations/index.js.map +1 -1
  161. package/migrations/migrations_index._auto-generated_.js.map +1 -1
  162. package/old-app .js +1 -1
  163. package/old-app .js.map +1 -1
  164. package/package.json +1 -1
  165. package/playground.js.map +1 -1
  166. package/tmp-environment.json +5 -4
  167. package/websql/README.md +24 -24
  168. package/websql/fesm2022/taon.mjs +1609 -282
  169. package/websql/fesm2022/taon.mjs.map +1 -1
  170. package/websql/lib/base-classes/base-class.d.ts +1 -1
  171. package/websql/lib/base-classes/base-context.d.ts +6 -6
  172. package/websql/lib/base-classes/base-repository.d.ts +3 -2
  173. package/websql/lib/base-classes/base.d.ts +6 -6
  174. package/websql/lib/create-context.d.ts +12 -12
  175. package/websql/lib/index.d.ts +18 -18
  176. package/websql/lib/inject.d.ts +4 -1
  177. package/websql/lib/ui/taon-table/taon-table.component.d.ts +8 -7
  178. package/websql/package.json +1 -1
  179. package/browser/lib/storage.d.ts +0 -2
  180. package/client/lib/storage.d.ts +0 -2
  181. package/websql/lib/storage.d.ts +0 -2
@@ -4,8 +4,8 @@ exports.EndpointContext = void 0;
4
4
  /* eslint-disable @typescript-eslint/typedef */
5
5
  //#region imports
6
6
  //#region @websql
7
- const taon_typeorm_1 = require("taon-typeorm");
8
- const taon_typeorm_2 = require("taon-typeorm");
7
+ const lib_1 = require("taon-typeorm/lib");
8
+ const lib_2 = require("taon-typeorm/lib");
9
9
  //#endregion
10
10
  //#region @backend
11
11
  const express = require("express");
@@ -16,25 +16,25 @@ const cookieParser = require("cookie-parser");
16
16
  const methodOverride = require("method-override");
17
17
  const fileUpload = require("express-fileupload");
18
18
  const url_1 = require("url");
19
- const tnp_core_1 = require("tnp-core");
19
+ const lib_3 = require("tnp-core/lib");
20
20
  //#endregion
21
21
  /* */
22
22
  /* */
23
- const tnp_core_2 = require("tnp-core");
24
- const tnp_core_3 = require("tnp-core");
23
+ const lib_4 = require("tnp-core/lib");
24
+ const lib_5 = require("tnp-core/lib");
25
25
  const models_1 = require("./models");
26
26
  const class_helpers_1 = require("./helpers/class-helpers");
27
27
  const symbols_1 = require("./symbols");
28
- const tnp_core_4 = require("tnp-core");
28
+ const lib_6 = require("tnp-core/lib");
29
29
  const di_container_1 = require("./dependency-injection/di-container");
30
30
  const taon_helpers_1 = require("./helpers/taon-helpers");
31
- const ng2_rest_1 = require("ng2-rest");
32
- const json10_1 = require("json10");
31
+ const lib_7 = require("ng2-rest/lib");
32
+ const lib_8 = require("json10/lib");
33
33
  const rxjs_1 = require("rxjs");
34
34
  const entity_process_1 = require("./entity-process");
35
35
  const get_response_value_1 = require("./get-response-value");
36
36
  const axios_1 = require("axios");
37
- const taon_typeorm_3 = require("taon-typeorm");
37
+ const lib_9 = require("taon-typeorm/lib");
38
38
  const env_1 = require("./env");
39
39
  const realtime_core_1 = require("./realtime/realtime-core");
40
40
  const context_db_migrations_1 = require("./context-db-migrations");
@@ -144,31 +144,31 @@ class EndpointContext {
144
144
  //#endregion
145
145
  //#region fields / logs
146
146
  get logHttp() {
147
- if (tnp_core_4._.isObject(this.config?.logs)) {
147
+ if (lib_6._.isObject(this.config?.logs)) {
148
148
  return !!this.config.logs.http;
149
149
  }
150
150
  return this.config?.logs === true;
151
151
  }
152
152
  get logRealtime() {
153
- if (tnp_core_4._.isObject(this.config?.logs)) {
153
+ if (lib_6._.isObject(this.config?.logs)) {
154
154
  return !!this.config.logs.realtime;
155
155
  }
156
156
  return this.config?.logs === true;
157
157
  }
158
158
  get logFramework() {
159
- if (tnp_core_4._.isObject(this.config?.logs)) {
159
+ if (lib_6._.isObject(this.config?.logs)) {
160
160
  return !!this.config.logs.framework;
161
161
  }
162
162
  return this.config?.logs === true;
163
163
  }
164
164
  get logDb() {
165
- if (tnp_core_4._.isObject(this.config?.logs)) {
165
+ if (lib_6._.isObject(this.config?.logs)) {
166
166
  return !!this.config.logs.db;
167
167
  }
168
168
  return this.config?.logs === true;
169
169
  }
170
170
  get logMigrations() {
171
- if (tnp_core_4._.isObject(this.config?.logs)) {
171
+ if (lib_6._.isObject(this.config?.logs)) {
172
172
  return !!this.config.logs.migrations;
173
173
  }
174
174
  return this.config?.logs === true;
@@ -190,16 +190,16 @@ class EndpointContext {
190
190
  // @ts-ignore
191
191
  this.onlyMigrationRevertToTimestamp = onlyMigrationRevertToTimestamp;
192
192
  this.config = this.configFn(env_1.ENV);
193
- if (tnp_core_4._.isObject(this.config.database)) {
193
+ if (lib_6._.isObject(this.config.database)) {
194
194
  this.config.database = models_1.Models.DatabaseConfig.from(this.config.database).databaseConfigTypeORM;
195
195
  }
196
196
  if (overrideHost && overrideRemoteHost) {
197
- tnp_core_4.Helpers.throw(`[taon-config] You can't have overrideHost and overrideRemoteHost at the same time`);
197
+ lib_6.Helpers.throw(`[taon-config] You can't have overrideHost and overrideRemoteHost at the same time`);
198
198
  }
199
- this.config.host = !tnp_core_4._.isUndefined(overrideHost)
199
+ this.config.host = !lib_6._.isUndefined(overrideHost)
200
200
  ? overrideHost
201
201
  : this.config.host;
202
- this.config.remoteHost = !tnp_core_4._.isUndefined(overrideRemoteHost)
202
+ this.config.remoteHost = !lib_6._.isUndefined(overrideRemoteHost)
203
203
  ? overrideRemoteHost
204
204
  : this.config.remoteHost;
205
205
  this.config.host = this.host === null ? void 0 : this.host;
@@ -208,19 +208,19 @@ class EndpointContext {
208
208
  if (this.config.host &&
209
209
  !this.config.host.startsWith('http://') &&
210
210
  !this.config.host.startsWith('https://')) {
211
- tnp_core_4.Helpers.throw(`[taon-config] Your 'host' must start with http:// or https://`);
211
+ lib_6.Helpers.throw(`[taon-config] Your 'host' must start with http:// or https://`);
212
212
  }
213
- if (tnp_core_4._.isUndefined(this.config.useIpcWhenElectron)) {
213
+ if (lib_6._.isUndefined(this.config.useIpcWhenElectron)) {
214
214
  this.config.useIpcWhenElectron = true;
215
215
  }
216
216
  if (this.config.remoteHost &&
217
217
  !this.config.remoteHost.startsWith('http://') &&
218
218
  !this.config.remoteHost.startsWith('https://')) {
219
- tnp_core_4.Helpers.throw(`[taon-config] Your 'remoteHost' must start with http:// or https://`);
219
+ lib_6.Helpers.throw(`[taon-config] Your 'remoteHost' must start with http:// or https://`);
220
220
  }
221
221
  //#region resolve if skipping writing server routes
222
222
  //@ts-expect-error overriding readonly
223
- this.skipWritingServerRoutes = tnp_core_4._.isBoolean(this.config.skipWritingServerRoutes)
223
+ this.skipWritingServerRoutes = lib_6._.isBoolean(this.config.skipWritingServerRoutes)
224
224
  ? this.config.skipWritingServerRoutes
225
225
  : false;
226
226
  //#endregion
@@ -232,12 +232,12 @@ class EndpointContext {
232
232
  }
233
233
  if (this.config.remoteHost) {
234
234
  if (this.config.host) {
235
- tnp_core_4.Helpers.throw(`[taon] You can't have remoteHost and host at the same time`);
235
+ lib_6.Helpers.throw(`[taon] You can't have remoteHost and host at the same time`);
236
236
  }
237
237
  this.mode = 'remote-backend(tcp+udp)';
238
238
  }
239
- if (this.config.useIpcWhenElectron && tnp_core_4.Helpers.isElectron) {
240
- if (tnp_core_4.Helpers.isWebSQL) {
239
+ if (this.config.useIpcWhenElectron && lib_6.Helpers.isElectron) {
240
+ if (lib_6.Helpers.isWebSQL) {
241
241
  this.mode = 'backend-frontend(websql-electron)';
242
242
  }
243
243
  else {
@@ -245,7 +245,7 @@ class EndpointContext {
245
245
  }
246
246
  }
247
247
  if (!this.mode && !this.config.abstract) {
248
- tnp_core_4.Helpers.error(`[taon] Context "${this.contextName}": You need to provide host or remoteHost or useIpcWhenElectron`, false, true);
248
+ lib_6.Helpers.error(`[taon] Context "${this.contextName}": You need to provide host or remoteHost or useIpcWhenElectron`, false, true);
249
249
  //#region @backend
250
250
  process.exit(1);
251
251
  //#endregion
@@ -255,13 +255,13 @@ class EndpointContext {
255
255
  if (this.config.database === true) {
256
256
  this.databaseConfig = this.getAutoGeneratedConfig();
257
257
  }
258
- else if (tnp_core_4._.isObject(this.config.database)) {
259
- this.databaseConfig = tnp_core_4._.merge(this.getAutoGeneratedConfig(), tnp_core_4._.cloneDeep(this.config.database));
258
+ else if (lib_6._.isObject(this.config.database)) {
259
+ this.databaseConfig = lib_6._.merge(this.getAutoGeneratedConfig(), lib_6._.cloneDeep(this.config.database));
260
260
  }
261
261
  //#endregion
262
262
  //#region resolve session
263
263
  if (this.config.session) {
264
- this.session = tnp_core_4._.cloneDeep(this.config.session);
264
+ this.session = lib_6._.cloneDeep(this.config.session);
265
265
  const oneHour = 1000 * 60 * 60 * 1; // 24;
266
266
  if (!this.session.cookieMaxAge) {
267
267
  this.session.cookieMaxAge = oneHour;
@@ -353,11 +353,11 @@ class EndpointContext {
353
353
  this.expressApp = express();
354
354
  this.initMiddlewares();
355
355
  this.serverTcpUdp = this.isHttpServer
356
- ? new tnp_core_1.https.Server({
356
+ ? new lib_3.https.Server({
357
357
  key: this.config.https?.key,
358
358
  cert: this.config.https?.cert,
359
359
  }, this.expressApp)
360
- : new tnp_core_1.http.Server(this.expressApp);
360
+ : new lib_3.http.Server(this.expressApp);
361
361
  this.publicAssets.forEach(asset => {
362
362
  this.expressApp.use(asset.serverPath, express.static(asset.locationOnDisk));
363
363
  });
@@ -368,7 +368,7 @@ class EndpointContext {
368
368
  if (!this.config.abstract) {
369
369
  this.disabledRealtime = !!this.config.disabledRealtime;
370
370
  //#region @backend
371
- if (tnp_core_4.Helpers.isRunningIn.cliMode()) {
371
+ if (lib_6.Helpers.isRunningIn.cliMode()) {
372
372
  // TODO for now...
373
373
  this.disabledRealtime = true;
374
374
  }
@@ -381,16 +381,16 @@ class EndpointContext {
381
381
  // console.log({ ref })
382
382
  if (this.config.abstract) {
383
383
  this.logFramework &&
384
- tnp_core_4.Helpers.info(`[taon] Create abstract context: ${this.config.contextName}`);
384
+ lib_6.Helpers.info(`[taon] Create abstract context: ${this.config.contextName}`);
385
385
  }
386
386
  else {
387
387
  if (this.config.remoteHost) {
388
388
  this.logFramework &&
389
- tnp_core_4.Helpers.info(`[taon] Create context for remote host: ${this.config.remoteHost}`);
389
+ lib_6.Helpers.info(`[taon] Create context for remote host: ${this.config.remoteHost}`);
390
390
  }
391
391
  else {
392
392
  this.logFramework &&
393
- tnp_core_4.Helpers.info(`[taon] Create context for host: ${this.config.host}`);
393
+ lib_6.Helpers.info(`[taon] Create context for host: ${this.config.host}`);
394
394
  }
395
395
  }
396
396
  //#endregion
@@ -404,8 +404,8 @@ class EndpointContext {
404
404
  getAutoGeneratedConfig() {
405
405
  //#region @websqlFunc
406
406
  let databaseConfig = models_1.Models.DatabaseConfig.from({});
407
- if (tnp_core_2.UtilsOs.isRunningInDocker()) {
408
- tnp_core_4.Helpers.info('Running in docker, using in mysql database');
407
+ if (lib_4.UtilsOs.isRunningInDocker()) {
408
+ lib_6.Helpers.info('Running in docker, using in mysql database');
409
409
  // TODO auto resolve database config in docker
410
410
  databaseConfig = models_1.Models.DatabaseConfig.from({
411
411
  database: `db-${this.contextName}.sqlite`,
@@ -420,7 +420,7 @@ class EndpointContext {
420
420
  }
421
421
  else {
422
422
  this.logFramework &&
423
- tnp_core_4.Helpers.info(`[taon][database] Automatically resolving database config for mode ${this.mode}`);
423
+ lib_6.Helpers.info(`[taon][database] Automatically resolving database config for mode ${this.mode}`);
424
424
  switch (this.mode) {
425
425
  //#region resolve database config for mode backend-frontend(tcp+udp)
426
426
  case 'backend-frontend(ipc-electron)':
@@ -483,7 +483,7 @@ class EndpointContext {
483
483
  if (this.mode === 'backend-frontend(tcp+udp)') {
484
484
  // this.displayRoutes(this.expressApp);
485
485
  this.serverTcpUdp.listen(Number(this.uri.port), () => {
486
- tnp_core_4.Helpers.log(`[taon][express-server]listening on port: ${this.uri.port}, hostname: ${this.uri.pathname},
486
+ lib_6.Helpers.log(`[taon][express-server]listening on port: ${this.uri.port}, hostname: ${this.uri.pathname},
487
487
  address: ${this.uri.protocol}//localhost:${this.uri.port}${this.uri.pathname}
488
488
  env: ${this.expressApp.settings.env}
489
489
  `);
@@ -491,7 +491,7 @@ class EndpointContext {
491
491
  }
492
492
  else {
493
493
  this.logFramework &&
494
- tnp_core_4.Helpers.info('Ipc communication enable instead tcp/upd');
494
+ lib_6.Helpers.info('Ipc communication enable instead tcp/upd');
495
495
  }
496
496
  //#endregion
497
497
  }
@@ -604,7 +604,7 @@ class EndpointContext {
604
604
  for (const key of Object.keys(classesInput || {})) {
605
605
  const BaseClass = classesInput[key];
606
606
  if (!BaseClass) {
607
- tnp_core_4.Helpers.error(`Class ${key} is not defined in context ${ctx.contextName}
607
+ lib_6.Helpers.error(`Class ${key} is not defined in context ${ctx.contextName}
608
608
 
609
609
  Please check if you have correct import in context file
610
610
 
@@ -739,7 +739,7 @@ class EndpointContext {
739
739
  //#endregion
740
740
  //#region methods & getters / check if context initialized
741
741
  checkIfContextInitialized() {
742
- if (tnp_core_4._.isUndefined(this.config)) {
742
+ if (lib_6._.isUndefined(this.config)) {
743
743
  throw new Error(`Please check if your context has been initialized.
744
744
 
745
745
  // ...
@@ -825,8 +825,8 @@ class EndpointContext {
825
825
  const controllers = this.getClassesInstancesArrBy(models_1.Models.ClassType.CONTROLLER);
826
826
  // console.log('CONTROLLERS TO REINIT', controllers);
827
827
  for (const ctrl of controllers) {
828
- if (tnp_core_4._.isFunction(ctrl.initExampleDbData)) {
829
- await tnp_core_4.Helpers.runSyncOrAsync({
828
+ if (lib_6._.isFunction(ctrl.initExampleDbData)) {
829
+ await lib_6.Helpers.runSyncOrAsync({
830
830
  functionFn: ctrl.initExampleDbData,
831
831
  context: ctrl,
832
832
  });
@@ -852,8 +852,8 @@ class EndpointContext {
852
852
  // `[taon] REINITING _ CLASS FN ${classTypeName} ${this.contextName} STARTED`,
853
853
  // );
854
854
  for (const classFun of this.getClassFunByArr(classTypeName)) {
855
- if (tnp_core_4._.isFunction(classFun._)) {
856
- await tnp_core_4.Helpers.runSyncOrAsync({
855
+ if (lib_6._.isFunction(classFun._)) {
856
+ await lib_6.Helpers.runSyncOrAsync({
857
857
  functionFn: classFun._,
858
858
  context: classFun,
859
859
  });
@@ -881,8 +881,8 @@ class EndpointContext {
881
881
  // `[taon] REINITING _ INS FN ${classTypeName} ${this.contextName} STARTED`,
882
882
  // );
883
883
  for (const ctrl of this.getClassesInstancesArrBy(classTypeName)) {
884
- if (tnp_core_4._.isFunction(ctrl._)) {
885
- await tnp_core_4.Helpers.runSyncOrAsync({
884
+ if (lib_6._.isFunction(ctrl._)) {
885
+ await lib_6.Helpers.runSyncOrAsync({
886
886
  functionFn: ctrl._,
887
887
  context: ctrl,
888
888
  });
@@ -967,7 +967,7 @@ class EndpointContext {
967
967
  const options = Reflect.getMetadata(symbols_1.Symbols.metadata.options.subscriber, subscriberClassFn);
968
968
  // console.log('subscriber options', options);
969
969
  // const nameForSubscriber = ClassHelpers.getName(subscriber);
970
- (0, taon_typeorm_1.EventSubscriber)()(subscriberClassFn);
970
+ (0, lib_1.EventSubscriber)()(subscriberClassFn);
971
971
  }
972
972
  //#endregion
973
973
  }
@@ -981,15 +981,15 @@ class EndpointContext {
981
981
  const entities = this.getClassFunByArr(models_1.Models.ClassType.ENTITY);
982
982
  for (const entity of entities) {
983
983
  const options = Reflect.getMetadata(symbols_1.Symbols.metadata.options.entity, entity);
984
- const createTable = tnp_core_4._.isUndefined(options.createTable)
984
+ const createTable = lib_6._.isUndefined(options.createTable)
985
985
  ? true
986
986
  : options.createTable;
987
987
  const nameForEntity = class_helpers_1.ClassHelpers.getName(entity);
988
- if (tnp_core_4._.isUndefined(options.createTable) ? true : options.createTable) {
988
+ if (lib_6._.isUndefined(options.createTable) ? true : options.createTable) {
989
989
  this.logDb &&
990
990
  console.info(`[taon][typeorm] create table for entity "${nameForEntity}" ? '${createTable}'`);
991
991
  // console.log('TypeormEntity', { TypeormEntity });
992
- (0, taon_typeorm_2.Entity)(nameForEntity)(entity);
992
+ (0, lib_2.Entity)(nameForEntity)(entity);
993
993
  }
994
994
  else {
995
995
  this.logDb &&
@@ -1028,7 +1028,7 @@ class EndpointContext {
1028
1028
  return class_helpers_1.ClassHelpers.getOrginalClass(entityFn);
1029
1029
  });
1030
1030
  const subscribers = this.getClassFunByArr(models_1.Models.ClassType.SUBSCRIBER);
1031
- const dataSourceDbConfig = tnp_core_4._.isObject(this.databaseConfig)
1031
+ const dataSourceDbConfig = lib_6._.isObject(this.databaseConfig)
1032
1032
  ? {
1033
1033
  type: this.databaseConfig.type,
1034
1034
  port: this.databaseConfig.databasePort,
@@ -1043,9 +1043,9 @@ class EndpointContext {
1043
1043
  synchronize: this.isRunOrRevertOnlyMigrationAppStart
1044
1044
  ? false
1045
1045
  : this.databaseConfig.synchronize,
1046
- autoSave: !tnp_core_4._.isNil(this.databaseConfig.autoSave)
1046
+ autoSave: !lib_6._.isNil(this.databaseConfig.autoSave)
1047
1047
  ? this.databaseConfig.autoSave
1048
- : !tnp_core_2.UtilsOs.isRunningInDocker(), // in docker I am using mysql or posgress
1048
+ : !lib_4.UtilsOs.isRunningInDocker(), // in docker I am using mysql or posgress
1049
1049
  dropSchema: this.isRunOrRevertOnlyMigrationAppStart
1050
1050
  ? false
1051
1051
  : this.databaseConfig.dropSchema,
@@ -1059,9 +1059,9 @@ class EndpointContext {
1059
1059
  if (this.modeAllowsDatabaseCreation && this.databaseConfig) {
1060
1060
  this.logDb &&
1061
1061
  this.logFramework &&
1062
- tnp_core_4.Helpers.info('[taon][database] prepare typeorm connection...');
1062
+ lib_6.Helpers.info('[taon][database] prepare typeorm connection...');
1063
1063
  try {
1064
- const connection = new taon_typeorm_3.DataSource(dataSourceDbConfig);
1064
+ const connection = new lib_9.DataSource(dataSourceDbConfig);
1065
1065
  this.connection = connection;
1066
1066
  await this.connection.initialize();
1067
1067
  }
@@ -1096,7 +1096,7 @@ class EndpointContext {
1096
1096
  // debugger;
1097
1097
  }
1098
1098
  else {
1099
- tnp_core_4.Helpers.info(`[taon][typeorm] Not initing db for mode ${this.mode}`);
1099
+ lib_6.Helpers.info(`[taon][typeorm] Not initing db for mode ${this.mode}`);
1100
1100
  }
1101
1101
  //#endregion
1102
1102
  }
@@ -1114,7 +1114,7 @@ class EndpointContext {
1114
1114
  const configs = class_helpers_1.ClassHelpers.getControllerConfigs(controllerClassFn);
1115
1115
  // console.log(`Class config for ${ClassHelpers.getName(controllerClassFn)}`, configs)
1116
1116
  const classConfig = configs[0];
1117
- const parentscalculatedPath = tnp_core_4._.slice(configs, 1)
1117
+ const parentscalculatedPath = lib_6._.slice(configs, 1)
1118
1118
  .reverse()
1119
1119
  .map(bc => {
1120
1120
  if (taon_helpers_1.TaonHelpers.isGoodPath(bc.path)) {
@@ -1132,13 +1132,13 @@ class EndpointContext {
1132
1132
  .replace(/\/\//g, '/')
1133
1133
  .split('/')
1134
1134
  .reduce((acc, bc) => {
1135
- return tnp_core_4._.last(acc) === bc ? acc : [...acc, bc];
1135
+ return lib_6._.last(acc) === bc ? acc : [...acc, bc];
1136
1136
  }, [])
1137
1137
  .join('/');
1138
1138
  }
1139
- tnp_core_4._.slice(configs, 1).forEach(bc => {
1139
+ lib_6._.slice(configs, 1).forEach(bc => {
1140
1140
  const alreadyIs = classConfig.methods;
1141
- const toMerge = tnp_core_4._.cloneDeep(bc.methods);
1141
+ const toMerge = lib_6._.cloneDeep(bc.methods);
1142
1142
  for (const key in toMerge) {
1143
1143
  if (toMerge.hasOwnProperty(key) && !alreadyIs[key]) {
1144
1144
  const element = toMerge[key];
@@ -1147,7 +1147,7 @@ class EndpointContext {
1147
1147
  }
1148
1148
  });
1149
1149
  //#region @backend
1150
- if (!tnp_core_4.Helpers.isRunningIn.cliMode()) {
1150
+ if (!lib_6.Helpers.isRunningIn.cliMode()) {
1151
1151
  //#endregion
1152
1152
  this.logHttp &&
1153
1153
  console.groupCollapsed(`[taon][express-server] routes [${classConfig.className}]`);
@@ -1163,7 +1163,7 @@ class EndpointContext {
1163
1163
  ? `/${methodConfig.path?.replace(/\//, '')}`
1164
1164
  : taon_helpers_1.TaonHelpers.getExpressPath(classConfig, methodConfig);
1165
1165
  // console.log({ expressPath })
1166
- if (tnp_core_4.Helpers.isNode || tnp_core_4.Helpers.isWebSQL) {
1166
+ if (lib_6.Helpers.isNode || lib_6.Helpers.isWebSQL) {
1167
1167
  //#region @websql
1168
1168
  const { routePath, method } = this.initServer(type, methodConfig, classConfig, expressPath, controllerClassFn);
1169
1169
  this.activeRoutes.push({
@@ -1172,7 +1172,7 @@ class EndpointContext {
1172
1172
  });
1173
1173
  //#endregion
1174
1174
  }
1175
- const shouldInitClient = tnp_core_4.Helpers.isBrowser || this.remoteHost || tnp_core_4.Helpers.isWebSQL;
1175
+ const shouldInitClient = lib_6.Helpers.isBrowser || this.remoteHost || lib_6.Helpers.isWebSQL;
1176
1176
  // console.log('shouldInitClient', shouldInitClient);
1177
1177
  if (shouldInitClient) {
1178
1178
  // console.log(
@@ -1186,7 +1186,7 @@ class EndpointContext {
1186
1186
  }
1187
1187
  });
1188
1188
  //#region @backend
1189
- if (!tnp_core_4.Helpers.isRunningIn.cliMode()) {
1189
+ if (!lib_6.Helpers.isRunningIn.cliMode()) {
1190
1190
  //#endregion
1191
1191
  this.logHttp && console.groupEnd();
1192
1192
  //#region @backend
@@ -1204,11 +1204,11 @@ class EndpointContext {
1204
1204
  }
1205
1205
  const contexts = [this];
1206
1206
  //#region @websql
1207
- const troutes = tnp_core_2.Utils.uniqArray(this.activeRoutes.map(f => {
1207
+ const troutes = lib_4.Utils.uniqArray(this.activeRoutes.map(f => {
1208
1208
  return `${f.method} ${f.routePath}`;
1209
1209
  })).map(f => {
1210
1210
  const [method, routePath] = f.split(' ');
1211
- return (`\n### ${tnp_core_4._.startCase(tnp_core_4._.last(routePath.split('/')))}\n` +
1211
+ return (`\n### ${lib_6._.startCase(lib_6._.last(routePath.split('/')))}\n` +
1212
1212
  taon_helpers_1.TaonHelpers.fillUpTo(method.toUpperCase() + ' ', 10) +
1213
1213
  this.uri.href.replace(/\/$/, '') +
1214
1214
  routePath);
@@ -1219,7 +1219,7 @@ class EndpointContext {
1219
1219
  ...['', `# ROUTES FOR HOST ${this.uri.href} `],
1220
1220
  ...troutes,
1221
1221
  ].join('\n');
1222
- const fileName = (0, tnp_core_3.crossPlatformPath)([
1222
+ const fileName = (0, lib_5.crossPlatformPath)([
1223
1223
  //#region @backend
1224
1224
  process.cwd(),
1225
1225
  //#endregion
@@ -1228,7 +1228,7 @@ class EndpointContext {
1228
1228
  this.logFramework && console.log(`[taon] routes file: ${fileName} `);
1229
1229
  // Helpers.log(JSON.stringify(routes, null, 4))
1230
1230
  //#region @backend
1231
- tnp_core_4.Helpers.writeFile(fileName, routes);
1231
+ lib_6.Helpers.writeFile(fileName, routes);
1232
1232
  //#endregion
1233
1233
  //#endregion
1234
1234
  }
@@ -1259,7 +1259,7 @@ class EndpointContext {
1259
1259
  app.use(methodOverride());
1260
1260
  app.use(cookieParser());
1261
1261
  if (this.session) {
1262
- tnp_core_4.Helpers.info('[taon][express-server] session enabled for this context ' +
1262
+ lib_6.Helpers.info('[taon][express-server] session enabled for this context ' +
1263
1263
  this.contextName);
1264
1264
  const { cookieMaxAge } = this.session;
1265
1265
  const frontendHost = this.config.frontendHost;
@@ -1285,7 +1285,7 @@ class EndpointContext {
1285
1285
  else {
1286
1286
  // if(this.config?.serverLogs) {
1287
1287
  this.logHttp &&
1288
- tnp_core_4.Helpers.info(`[taon][express-server] session not enabled for this context '${this.contextName}'`);
1288
+ lib_6.Helpers.info(`[taon][express-server] session not enabled for this context '${this.contextName}'`);
1289
1289
  // }
1290
1290
  app.use(cors({
1291
1291
  // origin: "http://localhost:5555",
@@ -1366,10 +1366,10 @@ class EndpointContext {
1366
1366
  expressPath = expressPath.replace(/\/\//g, '/');
1367
1367
  // console.log(`BACKEND: expressPath: ${ expressPath } `)
1368
1368
  //#endregion
1369
- if (tnp_core_4.Helpers.isElectron) {
1369
+ if (lib_6.Helpers.isElectron) {
1370
1370
  //#region @backend
1371
1371
  const ipcKeyName = taon_helpers_1.TaonHelpers.ipcKeyNameRequest(target, methodConfig, expressPath);
1372
- tnp_core_4.Helpers.ipcMain.on(ipcKeyName, async (event, paramsFromBrowser) => {
1372
+ lib_6.Helpers.ipcMain.on(ipcKeyName, async (event, paramsFromBrowser) => {
1373
1373
  const responseJsonData = await getResult(paramsFromBrowser, void 0, void 0);
1374
1374
  event.sender.send(taon_helpers_1.TaonHelpers.ipcKeyNameResponse(target, methodConfig, expressPath), responseJsonData);
1375
1375
  });
@@ -1382,7 +1382,7 @@ class EndpointContext {
1382
1382
  if (!this.remoteHost) {
1383
1383
  //#region apply dummy websql express routers
1384
1384
  //#region @websql
1385
- if (tnp_core_4.Helpers.isWebSQL) {
1385
+ if (lib_6.Helpers.isWebSQL) {
1386
1386
  if (!this.expressApp[type.toLowerCase()]) {
1387
1387
  this.expressApp[type.toLowerCase()] = () => { };
1388
1388
  }
@@ -1415,7 +1415,7 @@ class EndpointContext {
1415
1415
  if (req.headers[symbols_1.Symbols.old.MAPPING_CONFIG_HEADER_BODY_PARAMS]) {
1416
1416
  try {
1417
1417
  const entity = JSON.parse(req.headers[symbols_1.Symbols.old.MAPPING_CONFIG_HEADER_BODY_PARAMS]);
1418
- tBody = ng2_rest_1.Mapping.encode(tBody, entity);
1418
+ tBody = lib_7.Mapping.encode(tBody, entity);
1419
1419
  }
1420
1420
  catch (e) { }
1421
1421
  }
@@ -1423,7 +1423,7 @@ class EndpointContext {
1423
1423
  Object.keys(tBody).forEach(paramName => {
1424
1424
  try {
1425
1425
  const entityForParam = JSON.parse(req.headers[`${symbols_1.Symbols.old.MAPPING_CONFIG_HEADER_BODY_PARAMS}${paramName} `]);
1426
- tBody[paramName] = ng2_rest_1.Mapping.encode(tBody[paramName], entityForParam);
1426
+ tBody[paramName] = lib_7.Mapping.encode(tBody[paramName], entityForParam);
1427
1427
  }
1428
1428
  catch (e) { }
1429
1429
  });
@@ -1433,7 +1433,7 @@ class EndpointContext {
1433
1433
  if (req.headers[symbols_1.Symbols.old.MAPPING_CONFIG_HEADER_QUERY_PARAMS]) {
1434
1434
  try {
1435
1435
  const entity = JSON.parse(req.headers[symbols_1.Symbols.old.MAPPING_CONFIG_HEADER_QUERY_PARAMS]);
1436
- tQuery = taon_helpers_1.TaonHelpers.parseJSONwithStringJSONs(ng2_rest_1.Mapping.encode(tQuery, entity));
1436
+ tQuery = taon_helpers_1.TaonHelpers.parseJSONwithStringJSONs(lib_7.Mapping.encode(tQuery, entity));
1437
1437
  }
1438
1438
  catch (e) { }
1439
1439
  }
@@ -1442,14 +1442,14 @@ class EndpointContext {
1442
1442
  try {
1443
1443
  const entityForParam = JSON.parse(req.headers[`${symbols_1.Symbols.old.MAPPING_CONFIG_HEADER_QUERY_PARAMS}${queryParamName} `]);
1444
1444
  let beforeTransofrm = tQuery[queryParamName];
1445
- if (tnp_core_4._.isString(beforeTransofrm)) {
1445
+ if (lib_6._.isString(beforeTransofrm)) {
1446
1446
  try {
1447
1447
  const paresed = taon_helpers_1.TaonHelpers.tryTransformParam(beforeTransofrm);
1448
1448
  beforeTransofrm = paresed;
1449
1449
  }
1450
1450
  catch (e) { }
1451
1451
  }
1452
- const afterEncoding = ng2_rest_1.Mapping.encode(beforeTransofrm, entityForParam);
1452
+ const afterEncoding = lib_7.Mapping.encode(beforeTransofrm, entityForParam);
1453
1453
  tQuery[queryParamName] =
1454
1454
  taon_helpers_1.TaonHelpers.parseJSONwithStringJSONs(afterEncoding);
1455
1455
  }
@@ -1504,7 +1504,7 @@ class EndpointContext {
1504
1504
  res.end(file);
1505
1505
  //#endregion
1506
1506
  }
1507
- else if (tnp_core_4._.isString(result) &&
1507
+ else if (lib_6._.isString(result) &&
1508
1508
  methodConfig.responseType ===
1509
1509
  'blob') {
1510
1510
  // console.log('BASE64')
@@ -1531,8 +1531,8 @@ class EndpointContext {
1531
1531
  }
1532
1532
  catch (error) {
1533
1533
  //#region process error
1534
- if (tnp_core_4._.isString(error)) {
1535
- res.status(400).send(json10_1.JSON10.stringify({
1534
+ if (lib_6._.isString(error)) {
1535
+ res.status(400).send(lib_8.JSON10.stringify({
1536
1536
  message: `
1537
1537
  Error inside: ${req.path}
1538
1538
 
@@ -1542,22 +1542,22 @@ class EndpointContext {
1542
1542
  }));
1543
1543
  }
1544
1544
  else if (error instanceof models_1.Models.Http.Errors) {
1545
- tnp_core_4.Helpers.error(error, true, false);
1545
+ lib_6.Helpers.error(error, true, false);
1546
1546
  const err = error;
1547
- res.status(400).send(json10_1.JSON10.stringify(err));
1547
+ res.status(400).send(lib_8.JSON10.stringify(err));
1548
1548
  }
1549
1549
  else if (error instanceof Error) {
1550
1550
  const err = error;
1551
- tnp_core_4.Helpers.error(error, true, false);
1552
- res.status(400).send(json10_1.JSON10.stringify({
1551
+ lib_6.Helpers.error(error, true, false);
1552
+ res.status(400).send(lib_8.JSON10.stringify({
1553
1553
  stack: err.stack,
1554
1554
  message: err.message,
1555
1555
  }));
1556
1556
  }
1557
1557
  else {
1558
- tnp_core_4.Helpers.log(error);
1559
- tnp_core_4.Helpers.error(`[Taon] Bad result isomorphic method: ${error} `, true, false);
1560
- res.status(400).send(json10_1.JSON10.stringify(error));
1558
+ lib_6.Helpers.log(error);
1559
+ lib_6.Helpers.error(`[Taon] Bad result isomorphic method: ${error} `, true, false);
1560
+ res.status(400).send(lib_8.JSON10.stringify(error));
1561
1561
  }
1562
1562
  //#endregion
1563
1563
  }
@@ -1583,36 +1583,36 @@ class EndpointContext {
1583
1583
  // console.log('INITING', methodConfig); // TODO inject in static
1584
1584
  //#region resolve storage
1585
1585
  let storage;
1586
- if (tnp_core_4.Helpers.isBrowser) {
1586
+ if (lib_6.Helpers.isBrowser) {
1587
1587
  storage = window;
1588
1588
  }
1589
1589
  //#region @backend
1590
- if (tnp_core_4.Helpers.isNode) {
1590
+ if (lib_6.Helpers.isNode) {
1591
1591
  storage = global;
1592
1592
  }
1593
1593
  //#endregion
1594
1594
  //#endregion
1595
1595
  const orgMethods = target.prototype[methodConfig.methodName];
1596
1596
  //#region handle electron ipc request
1597
- if (tnp_core_4.Helpers.isElectron) {
1597
+ if (lib_6.Helpers.isElectron) {
1598
1598
  target.prototype[methodConfig.methodName] = function (...args) {
1599
1599
  const received = new Promise(async (resolve, reject) => {
1600
1600
  const headers = {};
1601
1601
  const { request, response } = taon_helpers_1.TaonHelpers.websqlMocks(headers);
1602
- tnp_core_4.Helpers.ipcRenderer.once(taon_helpers_1.TaonHelpers.ipcKeyNameResponse(target, methodConfig, expressPath), (event, responseData) => {
1602
+ lib_6.Helpers.ipcRenderer.once(taon_helpers_1.TaonHelpers.ipcKeyNameResponse(target, methodConfig, expressPath), (event, responseData) => {
1603
1603
  let res = responseData;
1604
1604
  console.log({ responseData });
1605
1605
  try {
1606
1606
  const body = res;
1607
- res = new ng2_rest_1.Models.HttpResponse({
1607
+ res = new lib_7.Models.HttpResponse({
1608
1608
  body: void 0,
1609
1609
  isArray: void 0,
1610
1610
  method: methodConfig.type,
1611
1611
  url: `${ctx.uri.origin}${'' // TODO express path
1612
1612
  }${methodConfig.path} `,
1613
- }, tnp_core_4.Helpers.isBlob(body) || tnp_core_4._.isString(body)
1613
+ }, lib_6.Helpers.isBlob(body) || lib_6._.isString(body)
1614
1614
  ? body
1615
- : JSON.stringify(body), ng2_rest_1.RestHeaders.from(headers), void 0, () => body);
1615
+ : JSON.stringify(body), lib_7.RestHeaders.from(headers), void 0, () => body);
1616
1616
  resolve(res);
1617
1617
  }
1618
1618
  catch (error) {
@@ -1620,7 +1620,7 @@ class EndpointContext {
1620
1620
  reject(error);
1621
1621
  }
1622
1622
  });
1623
- tnp_core_4.Helpers.ipcRenderer.send(taon_helpers_1.TaonHelpers.ipcKeyNameRequest(target, methodConfig, expressPath), args);
1623
+ lib_6.Helpers.ipcRenderer.send(taon_helpers_1.TaonHelpers.ipcKeyNameRequest(target, methodConfig, expressPath), args);
1624
1624
  });
1625
1625
  received['observable'] = (0, rxjs_1.from)(received);
1626
1626
  return {
@@ -1788,25 +1788,25 @@ class EndpointContext {
1788
1788
  if (!endpoints[ctx.uri.href][expressPath]) {
1789
1789
  let headers = {};
1790
1790
  if (methodConfig.contentType && !methodConfig.responseType) {
1791
- rest = ng2_rest_1.Resource.create(ctx.uri.href, expressPath, symbols_1.Symbols.old.MAPPING_CONFIG_HEADER, symbols_1.Symbols.old.CIRCURAL_OBJECTS_MAP_BODY, ng2_rest_1.RestHeaders.from({
1791
+ rest = lib_7.Resource.create(ctx.uri.href, expressPath, symbols_1.Symbols.old.MAPPING_CONFIG_HEADER, symbols_1.Symbols.old.CIRCURAL_OBJECTS_MAP_BODY, lib_7.RestHeaders.from({
1792
1792
  'Content-Type': methodConfig.contentType,
1793
1793
  Accept: methodConfig.contentType,
1794
1794
  }));
1795
1795
  }
1796
1796
  else if (methodConfig.contentType && methodConfig.responseType) {
1797
- rest = ng2_rest_1.Resource.create(ctx.uri.href, expressPath, symbols_1.Symbols.old.MAPPING_CONFIG_HEADER, symbols_1.Symbols.old.CIRCURAL_OBJECTS_MAP_BODY, ng2_rest_1.RestHeaders.from({
1797
+ rest = lib_7.Resource.create(ctx.uri.href, expressPath, symbols_1.Symbols.old.MAPPING_CONFIG_HEADER, symbols_1.Symbols.old.CIRCURAL_OBJECTS_MAP_BODY, lib_7.RestHeaders.from({
1798
1798
  'Content-Type': methodConfig.contentType,
1799
1799
  Accept: methodConfig.contentType,
1800
1800
  responsetypeaxios: methodConfig.responseType,
1801
1801
  }));
1802
1802
  }
1803
1803
  else if (!methodConfig.contentType && methodConfig.responseType) {
1804
- rest = ng2_rest_1.Resource.create(ctx.uri.href, expressPath, symbols_1.Symbols.old.MAPPING_CONFIG_HEADER, symbols_1.Symbols.old.CIRCURAL_OBJECTS_MAP_BODY, ng2_rest_1.RestHeaders.from({
1804
+ rest = lib_7.Resource.create(ctx.uri.href, expressPath, symbols_1.Symbols.old.MAPPING_CONFIG_HEADER, symbols_1.Symbols.old.CIRCURAL_OBJECTS_MAP_BODY, lib_7.RestHeaders.from({
1805
1805
  responsetypeaxios: methodConfig.responseType,
1806
1806
  }));
1807
1807
  }
1808
1808
  else {
1809
- rest = ng2_rest_1.Resource.create(ctx.uri.href, expressPath, symbols_1.Symbols.old.MAPPING_CONFIG_HEADER, symbols_1.Symbols.old.CIRCURAL_OBJECTS_MAP_BODY);
1809
+ rest = lib_7.Resource.create(ctx.uri.href, expressPath, symbols_1.Symbols.old.MAPPING_CONFIG_HEADER, symbols_1.Symbols.old.CIRCURAL_OBJECTS_MAP_BODY);
1810
1810
  }
1811
1811
  endpoints[ctx.uri.href][expressPath] = rest;
1812
1812
  }
@@ -1832,18 +1832,18 @@ class EndpointContext {
1832
1832
  }
1833
1833
  if (currentParam.paramType === 'Query') {
1834
1834
  if (currentParam.paramName) {
1835
- const mapping = ng2_rest_1.Mapping.decode(param, !ctx.isProductionMode);
1835
+ const mapping = lib_7.Mapping.decode(param, !ctx.isProductionMode);
1836
1836
  if (mapping) {
1837
1837
  rest.headers.set(`${symbols_1.Symbols.old.MAPPING_CONFIG_HEADER_QUERY_PARAMS}${currentParam.paramName} `, JSON.stringify(mapping));
1838
1838
  }
1839
1839
  queryParams[currentParam.paramName] = param;
1840
1840
  }
1841
1841
  else {
1842
- const mapping = ng2_rest_1.Mapping.decode(param, !ctx.isProductionMode);
1842
+ const mapping = lib_7.Mapping.decode(param, !ctx.isProductionMode);
1843
1843
  if (mapping) {
1844
1844
  rest.headers.set(symbols_1.Symbols.old.MAPPING_CONFIG_HEADER_QUERY_PARAMS, JSON.stringify(mapping));
1845
1845
  }
1846
- queryParams = tnp_core_4._.cloneDeep(param);
1846
+ queryParams = lib_6._.cloneDeep(param);
1847
1847
  }
1848
1848
  }
1849
1849
  if (currentParam.paramType === 'Header') {
@@ -1863,7 +1863,7 @@ class EndpointContext {
1863
1863
  }
1864
1864
  }
1865
1865
  if (currentParam.paramType === 'Cookie') {
1866
- ng2_rest_1.Resource.Cookies.write(currentParam.paramName, param, currentParam.expireInSeconds);
1866
+ lib_7.Resource.Cookies.write(currentParam.paramName, param, currentParam.expireInSeconds);
1867
1867
  }
1868
1868
  if (currentParam.paramType === 'Body') {
1869
1869
  if (currentParam.paramName) {
@@ -1880,14 +1880,14 @@ instead
1880
1880
  // ...
1881
1881
  `);
1882
1882
  }
1883
- const mapping = ng2_rest_1.Mapping.decode(param, !ctx.isProductionMode);
1883
+ const mapping = lib_7.Mapping.decode(param, !ctx.isProductionMode);
1884
1884
  if (mapping) {
1885
1885
  rest.headers.set(`${symbols_1.Symbols.old.MAPPING_CONFIG_HEADER_BODY_PARAMS}${currentParam.paramName} `, JSON.stringify(mapping));
1886
1886
  }
1887
1887
  bodyObject[currentParam.paramName] = param;
1888
1888
  }
1889
1889
  else {
1890
- const mapping = ng2_rest_1.Mapping.decode(param, !ctx.isProductionMode);
1890
+ const mapping = lib_7.Mapping.decode(param, !ctx.isProductionMode);
1891
1891
  if (mapping) {
1892
1892
  rest.headers.set(symbols_1.Symbols.old.MAPPING_CONFIG_HEADER_BODY_PARAMS, JSON.stringify(mapping));
1893
1893
  }
@@ -1898,17 +1898,17 @@ instead
1898
1898
  if (typeof bodyObject === 'object' &&
1899
1899
  class_helpers_1.ClassHelpers.getName(bodyObject) !== 'FormData') {
1900
1900
  let circuralFromItem = [];
1901
- bodyObject = json10_1.JSON10.parse(json10_1.JSON10.stringify(bodyObject, void 0, void 0, circs => {
1901
+ bodyObject = lib_8.JSON10.parse(lib_8.JSON10.stringify(bodyObject, void 0, void 0, circs => {
1902
1902
  circuralFromItem = circs;
1903
1903
  }));
1904
- rest.headers.set(symbols_1.Symbols.old.CIRCURAL_OBJECTS_MAP_BODY, json10_1.JSON10.stringify(circuralFromItem));
1904
+ rest.headers.set(symbols_1.Symbols.old.CIRCURAL_OBJECTS_MAP_BODY, lib_8.JSON10.stringify(circuralFromItem));
1905
1905
  }
1906
1906
  if (typeof queryParams === 'object') {
1907
1907
  let circuralFromQueryParams = [];
1908
- queryParams = json10_1.JSON10.parse(json10_1.JSON10.stringify(queryParams, void 0, void 0, circs => {
1908
+ queryParams = lib_8.JSON10.parse(lib_8.JSON10.stringify(queryParams, void 0, void 0, circs => {
1909
1909
  circuralFromQueryParams = circs;
1910
1910
  }));
1911
- rest.headers.set(symbols_1.Symbols.old.CIRCURAL_OBJECTS_MAP_QUERY_PARAM, json10_1.JSON10.stringify(circuralFromQueryParams));
1911
+ rest.headers.set(symbols_1.Symbols.old.CIRCURAL_OBJECTS_MAP_QUERY_PARAM, lib_8.JSON10.stringify(circuralFromQueryParams));
1912
1912
  }
1913
1913
  //#endregion
1914
1914
  const httpResultObj = {