@futdevpro/fsm-dynamo 1.5.47 → 1.5.50
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +12 -1
- package/src/_collections/_tools/dynamo-log.ts +43 -9
- package/src/_collections/_tools/dynamo-regions.ts +9 -9
- package/src/_constants/index.ts +1 -0
- package/src/_constants/module-settings/custom-data-module-settings.ts +10 -0
- package/src/_constants/module-settings/test-module-settings.ts +3 -4
- package/src/_constants/module-settings/usage-module-settings.ts +2 -2
- package/src/_enums/basic-property-type.enum.ts +9 -0
- package/src/_models/control-models/dynamo-daily-usage-data.ts +3 -2
- package/src/_models/control-models/{dynamo-nts-data-params.ts → dynamo-data-params.ts} +10 -5
- package/src/_models/control-models/{dynamo-nts-data-property-params.ts → dynamo-data-property-params.ts} +11 -10
- package/src/_models/control-models/dynamo-error.ts +1 -1
- package/src/_models/control-models/dynamo-range-value.ts +15 -0
- package/src/_models/control-models/{dynamo-nts-module-settings.ts → dynamo-route-settings.ts} +1 -1
- package/src/_models/control-models/dynamo-usage-action.ts +3 -2
- package/src/_models/control-models/dynamo-usage-data.ts +3 -2
- package/src/_models/data-models/dynamo-custom-data.ts +6 -5
- package/src/_models/data-models/dynamo-metadata.ts +7 -3
- package/src/_models/data-models/dynamo-usage-session.ts +10 -18
- package/src/_models/index.ts +4 -3
- package/src/_modules/custom-data-module.index.ts +6 -0
- package/src/_modules/data-modules.index.ts +2 -2
- package/src/_modules/test-module.index.ts +0 -1
- package/lib/_collections/_constants/country-codes-ISO-3166.json +0 -3239
- package/lib/_collections/_constants/country-divisions-ISO-3166-all-list.json +0 -19036
- package/lib/_collections/_constants/country-iso.d.ts +0 -67
- package/lib/_collections/_constants/country-iso.d.ts.map +0 -1
- package/lib/_collections/_constants/country-iso.js +0 -47
- package/lib/_collections/_constants/country-iso.js.map +0 -1
- package/lib/_collections/_constants/country-phone-code.d.ts +0 -6
- package/lib/_collections/_constants/country-phone-code.d.ts.map +0 -1
- package/lib/_collections/_constants/country-phone-code.js +0 -3
- package/lib/_collections/_constants/country-phone-code.js.map +0 -1
- package/lib/_collections/_constants/country-phone-codes.json +0 -1202
- package/lib/_collections/_constants/country-sub-divisions-ISO-3166.json +0 -4994
- package/lib/_collections/_tools/dynamo-location.d.ts +0 -6
- package/lib/_collections/_tools/dynamo-location.d.ts.map +0 -1
- package/lib/_collections/_tools/dynamo-location.js +0 -40
- package/lib/_collections/_tools/dynamo-location.js.map +0 -1
- package/lib/_collections/_tools/dynamo-log.d.ts +0 -11
- package/lib/_collections/_tools/dynamo-log.d.ts.map +0 -1
- package/lib/_collections/_tools/dynamo-log.js +0 -59
- package/lib/_collections/_tools/dynamo-log.js.map +0 -1
- package/lib/_collections/_tools/dynamo-random.d.ts +0 -8
- package/lib/_collections/_tools/dynamo-random.d.ts.map +0 -1
- package/lib/_collections/_tools/dynamo-random.js +0 -60
- package/lib/_collections/_tools/dynamo-random.js.map +0 -1
- package/lib/_collections/_tools/dynamo-regions.d.ts +0 -16
- package/lib/_collections/_tools/dynamo-regions.d.ts.map +0 -1
- package/lib/_collections/_tools/dynamo-regions.js +0 -68
- package/lib/_collections/_tools/dynamo-regions.js.map +0 -1
- package/lib/_collections/_tools/dynamo-round-list.d.ts +0 -8
- package/lib/_collections/_tools/dynamo-round-list.d.ts.map +0 -1
- package/lib/_collections/_tools/dynamo-round-list.js +0 -39
- package/lib/_collections/_tools/dynamo-round-list.js.map +0 -1
- package/lib/_collections/_tools/dynamo-shared.service.d.ts +0 -73
- package/lib/_collections/_tools/dynamo-shared.service.d.ts.map +0 -1
- package/lib/_collections/_tools/dynamo-shared.service.js +0 -151
- package/lib/_collections/_tools/dynamo-shared.service.js.map +0 -1
- package/lib/_collections/_tools/dynamo-time.d.ts +0 -12
- package/lib/_collections/_tools/dynamo-time.d.ts.map +0 -1
- package/lib/_collections/_tools/dynamo-time.js +0 -41
- package/lib/_collections/_tools/dynamo-time.js.map +0 -1
- package/lib/_collections/_tools/dynamo-trigonometry.d.ts +0 -43
- package/lib/_collections/_tools/dynamo-trigonometry.d.ts.map +0 -1
- package/lib/_collections/_tools/dynamo-trigonometry.js +0 -62
- package/lib/_collections/_tools/dynamo-trigonometry.js.map +0 -1
- package/lib/_collections/_tools/location.d.ts +0 -6
- package/lib/_collections/_tools/location.d.ts.map +0 -1
- package/lib/_collections/_tools/location.js +0 -40
- package/lib/_collections/_tools/location.js.map +0 -1
- package/lib/_collections/_tools/log.d.ts +0 -10
- package/lib/_collections/_tools/log.d.ts.map +0 -1
- package/lib/_collections/_tools/log.js +0 -53
- package/lib/_collections/_tools/log.js.map +0 -1
- package/lib/_collections/_tools/random.d.ts +0 -8
- package/lib/_collections/_tools/random.d.ts.map +0 -1
- package/lib/_collections/_tools/random.js +0 -60
- package/lib/_collections/_tools/random.js.map +0 -1
- package/lib/_collections/_tools/region-translator.d.ts +0 -12
- package/lib/_collections/_tools/region-translator.d.ts.map +0 -1
- package/lib/_collections/_tools/region-translator.js +0 -48
- package/lib/_collections/_tools/region-translator.js.map +0 -1
- package/lib/_collections/_tools/round-list.d.ts +0 -8
- package/lib/_collections/_tools/round-list.d.ts.map +0 -1
- package/lib/_collections/_tools/round-list.js +0 -39
- package/lib/_collections/_tools/round-list.js.map +0 -1
- package/lib/_collections/_tools/time.d.ts +0 -12
- package/lib/_collections/_tools/time.d.ts.map +0 -1
- package/lib/_collections/_tools/time.js +0 -41
- package/lib/_collections/_tools/time.js.map +0 -1
- package/lib/_collections/_tools/trigonometry.d.ts +0 -43
- package/lib/_collections/_tools/trigonometry.d.ts.map +0 -1
- package/lib/_collections/_tools/trigonometry.js +0 -62
- package/lib/_collections/_tools/trigonometry.js.map +0 -1
- package/lib/_collections/_tools/utilities.d.ts +0 -32
- package/lib/_collections/_tools/utilities.d.ts.map +0 -1
- package/lib/_collections/_tools/utilities.js +0 -71
- package/lib/_collections/_tools/utilities.js.map +0 -1
- package/lib/_collections/_tools/vector.d.ts +0 -38
- package/lib/_collections/_tools/vector.d.ts.map +0 -1
- package/lib/_collections/_tools/vector.js +0 -107
- package/lib/_collections/_tools/vector.js.map +0 -1
- package/lib/_collections/dynamo-shared.service.d.ts +0 -87
- package/lib/_collections/dynamo-shared.service.d.ts.map +0 -1
- package/lib/_collections/dynamo-shared.service.js +0 -261
- package/lib/_collections/dynamo-shared.service.js.map +0 -1
- package/lib/_collections/index.d.ts +0 -11
- package/lib/_collections/index.d.ts.map +0 -1
- package/lib/_collections/index.js +0 -15
- package/lib/_collections/index.js.map +0 -1
- package/lib/_constants/index.d.ts +0 -4
- package/lib/_constants/index.d.ts.map +0 -1
- package/lib/_constants/index.js +0 -9
- package/lib/_constants/index.js.map +0 -1
- package/lib/_constants/module-settings/test-module-settings.d.ts +0 -3
- package/lib/_constants/module-settings/test-module-settings.d.ts.map +0 -1
- package/lib/_constants/module-settings/test-module-settings.js +0 -16
- package/lib/_constants/module-settings/test-module-settings.js.map +0 -1
- package/lib/_constants/module-settings/usage-module-settings.d.ts +0 -3
- package/lib/_constants/module-settings/usage-module-settings.d.ts.map +0 -1
- package/lib/_constants/module-settings/usage-module-settings.js +0 -13
- package/lib/_constants/module-settings/usage-module-settings.js.map +0 -1
- package/lib/_constants/times.d.ts +0 -8
- package/lib/_constants/times.d.ts.map +0 -1
- package/lib/_constants/times.js +0 -11
- package/lib/_constants/times.js.map +0 -1
- package/lib/_enums/data-model-type.enum.d.ts +0 -6
- package/lib/_enums/data-model-type.enum.d.ts.map +0 -1
- package/lib/_enums/data-model-type.enum.js +0 -10
- package/lib/_enums/data-model-type.enum.js.map +0 -1
- package/lib/_enums/index.d.ts +0 -3
- package/lib/_enums/index.d.ts.map +0 -1
- package/lib/_enums/index.js +0 -7
- package/lib/_enums/index.js.map +0 -1
- package/lib/_enums/log-style.enum.d.ts +0 -26
- package/lib/_enums/log-style.enum.d.ts.map +0 -1
- package/lib/_enums/log-style.enum.js +0 -30
- package/lib/_enums/log-style.enum.js.map +0 -1
- package/lib/_enums/region.enum.d.ts +0 -8
- package/lib/_enums/region.enum.d.ts.map +0 -1
- package/lib/_enums/region.enum.js +0 -12
- package/lib/_enums/region.enum.js.map +0 -1
- package/lib/_enums/sub-region.enum.d.ts +0 -20
- package/lib/_enums/sub-region.enum.d.ts.map +0 -1
- package/lib/_enums/sub-region.enum.js +0 -24
- package/lib/_enums/sub-region.enum.js.map +0 -1
- package/lib/_models/control-models/country-division.d.ts +0 -6
- package/lib/_models/control-models/country-division.d.ts.map +0 -1
- package/lib/_models/control-models/country-division.js +0 -3
- package/lib/_models/control-models/country-division.js.map +0 -1
- package/lib/_models/control-models/country-iso.d.ts +0 -19
- package/lib/_models/control-models/country-iso.d.ts.map +0 -1
- package/lib/_models/control-models/country-iso.js +0 -3
- package/lib/_models/control-models/country-iso.js.map +0 -1
- package/lib/_models/control-models/country-phone-code.d.ts +0 -6
- package/lib/_models/control-models/country-phone-code.d.ts.map +0 -1
- package/lib/_models/control-models/country-phone-code.js +0 -3
- package/lib/_models/control-models/country-phone-code.js.map +0 -1
- package/lib/_models/control-models/daily-usage-data.d.ts +0 -18
- package/lib/_models/control-models/daily-usage-data.d.ts.map +0 -1
- package/lib/_models/control-models/daily-usage-data.js +0 -22
- package/lib/_models/control-models/daily-usage-data.js.map +0 -1
- package/lib/_models/control-models/division-collection.d.ts +0 -9
- package/lib/_models/control-models/division-collection.d.ts.map +0 -1
- package/lib/_models/control-models/division-collection.js +0 -3
- package/lib/_models/control-models/division-collection.js.map +0 -1
- package/lib/_models/control-models/division-region-data.d.ts +0 -45
- package/lib/_models/control-models/division-region-data.d.ts.map +0 -1
- package/lib/_models/control-models/division-region-data.js +0 -46
- package/lib/_models/control-models/division-region-data.js.map +0 -1
- package/lib/_models/control-models/dynamo-daily-usage-data.d.ts +0 -18
- package/lib/_models/control-models/dynamo-daily-usage-data.d.ts.map +0 -1
- package/lib/_models/control-models/dynamo-daily-usage-data.js +0 -22
- package/lib/_models/control-models/dynamo-daily-usage-data.js.map +0 -1
- package/lib/_models/control-models/dynamo-error.d.ts +0 -263
- package/lib/_models/control-models/dynamo-error.d.ts.map +0 -1
- package/lib/_models/control-models/dynamo-error.js +0 -114
- package/lib/_models/control-models/dynamo-error.js.map +0 -1
- package/lib/_models/control-models/dynamo-module-settings.d.ts +0 -7
- package/lib/_models/control-models/dynamo-module-settings.d.ts.map +0 -1
- package/lib/_models/control-models/dynamo-module-settings.js +0 -3
- package/lib/_models/control-models/dynamo-module-settings.js.map +0 -1
- package/lib/_models/control-models/dynamo-nts-data-params.d.ts +0 -14
- package/lib/_models/control-models/dynamo-nts-data-params.d.ts.map +0 -1
- package/lib/_models/control-models/dynamo-nts-data-params.js +0 -19
- package/lib/_models/control-models/dynamo-nts-data-params.js.map +0 -1
- package/lib/_models/control-models/dynamo-nts-data-property-params.d.ts +0 -45
- package/lib/_models/control-models/dynamo-nts-data-property-params.d.ts.map +0 -1
- package/lib/_models/control-models/dynamo-nts-data-property-params.js +0 -61
- package/lib/_models/control-models/dynamo-nts-data-property-params.js.map +0 -1
- package/lib/_models/control-models/dynamo-nts-error.d.ts +0 -19
- package/lib/_models/control-models/dynamo-nts-error.d.ts.map +0 -1
- package/lib/_models/control-models/dynamo-nts-error.js +0 -190
- package/lib/_models/control-models/dynamo-nts-error.js.map +0 -1
- package/lib/_models/control-models/dynamo-nts-module-settings.d.ts +0 -7
- package/lib/_models/control-models/dynamo-nts-module-settings.d.ts.map +0 -1
- package/lib/_models/control-models/dynamo-nts-module-settings.js +0 -3
- package/lib/_models/control-models/dynamo-nts-module-settings.js.map +0 -1
- package/lib/_models/control-models/dynamo-poll.d.ts +0 -31
- package/lib/_models/control-models/dynamo-poll.d.ts.map +0 -1
- package/lib/_models/control-models/dynamo-poll.js +0 -90
- package/lib/_models/control-models/dynamo-poll.js.map +0 -1
- package/lib/_models/control-models/dynamo-usage-action.d.ts +0 -9
- package/lib/_models/control-models/dynamo-usage-action.d.ts.map +0 -1
- package/lib/_models/control-models/dynamo-usage-action.js +0 -13
- package/lib/_models/control-models/dynamo-usage-action.js.map +0 -1
- package/lib/_models/control-models/dynamo-usage-data.d.ts +0 -14
- package/lib/_models/control-models/dynamo-usage-data.d.ts.map +0 -1
- package/lib/_models/control-models/dynamo-usage-data.js +0 -16
- package/lib/_models/control-models/dynamo-usage-data.js.map +0 -1
- package/lib/_models/control-models/dynamobe-data-params.d.ts +0 -14
- package/lib/_models/control-models/dynamobe-data-params.d.ts.map +0 -1
- package/lib/_models/control-models/dynamobe-data-params.js +0 -19
- package/lib/_models/control-models/dynamobe-data-params.js.map +0 -1
- package/lib/_models/control-models/dynamobe-data-property-params.d.ts +0 -28
- package/lib/_models/control-models/dynamobe-data-property-params.d.ts.map +0 -1
- package/lib/_models/control-models/dynamobe-data-property-params.js +0 -57
- package/lib/_models/control-models/dynamobe-data-property-params.js.map +0 -1
- package/lib/_models/control-models/dynamobe-error.d.ts +0 -19
- package/lib/_models/control-models/dynamobe-error.d.ts.map +0 -1
- package/lib/_models/control-models/dynamobe-error.js +0 -188
- package/lib/_models/control-models/dynamobe-error.js.map +0 -1
- package/lib/_models/control-models/geo-ip-location.d.ts +0 -26
- package/lib/_models/control-models/geo-ip-location.d.ts.map +0 -1
- package/lib/_models/control-models/geo-ip-location.js +0 -3
- package/lib/_models/control-models/geo-ip-location.js.map +0 -1
- package/lib/_models/control-models/location-coordinates.d.ts +0 -5
- package/lib/_models/control-models/location-coordinates.d.ts.map +0 -1
- package/lib/_models/control-models/location-coordinates.js +0 -3
- package/lib/_models/control-models/location-coordinates.js.map +0 -1
- package/lib/_models/control-models/random-weight.d.ts +0 -5
- package/lib/_models/control-models/random-weight.d.ts.map +0 -1
- package/lib/_models/control-models/random-weight.js +0 -3
- package/lib/_models/control-models/random-weight.js.map +0 -1
- package/lib/_models/control-models/subdivision-collection.d.ts +0 -9
- package/lib/_models/control-models/subdivision-collection.d.ts.map +0 -1
- package/lib/_models/control-models/subdivision-collection.js +0 -3
- package/lib/_models/control-models/subdivision-collection.js.map +0 -1
- package/lib/_models/control-models/subdivision-region-data.d.ts +0 -45
- package/lib/_models/control-models/subdivision-region-data.d.ts.map +0 -1
- package/lib/_models/control-models/subdivision-region-data.js +0 -46
- package/lib/_models/control-models/subdivision-region-data.js.map +0 -1
- package/lib/_models/control-models/usage-action.d.ts +0 -9
- package/lib/_models/control-models/usage-action.d.ts.map +0 -1
- package/lib/_models/control-models/usage-action.js +0 -13
- package/lib/_models/control-models/usage-action.js.map +0 -1
- package/lib/_models/control-models/usage-data.d.ts +0 -14
- package/lib/_models/control-models/usage-data.d.ts.map +0 -1
- package/lib/_models/control-models/usage-data.js +0 -16
- package/lib/_models/control-models/usage-data.js.map +0 -1
- package/lib/_models/data-models/custom-data.d.ts +0 -16
- package/lib/_models/data-models/custom-data.d.ts.map +0 -1
- package/lib/_models/data-models/custom-data.js +0 -28
- package/lib/_models/data-models/custom-data.js.map +0 -1
- package/lib/_models/data-models/dynamo-custom-data.d.ts +0 -16
- package/lib/_models/data-models/dynamo-custom-data.d.ts.map +0 -1
- package/lib/_models/data-models/dynamo-custom-data.js +0 -28
- package/lib/_models/data-models/dynamo-custom-data.js.map +0 -1
- package/lib/_models/data-models/dynamo-metadata.d.ts +0 -17
- package/lib/_models/data-models/dynamo-metadata.d.ts.map +0 -1
- package/lib/_models/data-models/dynamo-metadata.js +0 -17
- package/lib/_models/data-models/dynamo-metadata.js.map +0 -1
- package/lib/_models/data-models/dynamo-usage-session.d.ts +0 -34
- package/lib/_models/data-models/dynamo-usage-session.d.ts.map +0 -1
- package/lib/_models/data-models/dynamo-usage-session.js +0 -53
- package/lib/_models/data-models/dynamo-usage-session.js.map +0 -1
- package/lib/_models/data-models/metadata.d.ts +0 -17
- package/lib/_models/data-models/metadata.d.ts.map +0 -1
- package/lib/_models/data-models/metadata.js +0 -17
- package/lib/_models/data-models/metadata.js.map +0 -1
- package/lib/_models/data-models/usage-session.d.ts +0 -34
- package/lib/_models/data-models/usage-session.d.ts.map +0 -1
- package/lib/_models/data-models/usage-session.js +0 -53
- package/lib/_models/data-models/usage-session.js.map +0 -1
- package/lib/_models/index.d.ts +0 -19
- package/lib/_models/index.d.ts.map +0 -1
- package/lib/_models/index.js +0 -25
- package/lib/_models/index.js.map +0 -1
- package/lib/_modules/data-models.index.d.ts +0 -3
- package/lib/_modules/data-models.index.d.ts.map +0 -1
- package/lib/_modules/data-models.index.js +0 -7
- package/lib/_modules/data-models.index.js.map +0 -1
- package/lib/_modules/data-module.index.d.ts +0 -5
- package/lib/_modules/data-module.index.d.ts.map +0 -1
- package/lib/_modules/data-module.index.js +0 -9
- package/lib/_modules/data-module.index.js.map +0 -1
- package/lib/_modules/data-modules.index.d.ts +0 -6
- package/lib/_modules/data-modules.index.d.ts.map +0 -1
- package/lib/_modules/data-modules.index.js +0 -10
- package/lib/_modules/data-modules.index.js.map +0 -1
- package/lib/_modules/error-module.index.d.ts +0 -2
- package/lib/_modules/error-module.index.d.ts.map +0 -1
- package/lib/_modules/error-module.index.js +0 -6
- package/lib/_modules/error-module.index.js.map +0 -1
- package/lib/_modules/shared-service.index.d.ts +0 -8
- package/lib/_modules/shared-service.index.d.ts.map +0 -1
- package/lib/_modules/shared-service.index.js +0 -12
- package/lib/_modules/shared-service.index.js.map +0 -1
- package/lib/_modules/test-module.index.d.ts +0 -3
- package/lib/_modules/test-module.index.d.ts.map +0 -1
- package/lib/_modules/test-module.index.js +0 -7
- package/lib/_modules/test-module.index.js.map +0 -1
- package/lib/_modules/usage-module.index.d.ts +0 -6
- package/lib/_modules/usage-module.index.d.ts.map +0 -1
- package/lib/_modules/usage-module.index.js +0 -10
- package/lib/_modules/usage-module.index.js.map +0 -1
- package/lib/data-models.d.ts +0 -3
- package/lib/data-models.d.ts.map +0 -1
- package/lib/data-models.js +0 -7
- package/lib/data-models.js.map +0 -1
- package/lib/index.d.ts +0 -5
- package/lib/index.d.ts.map +0 -1
- package/lib/index.js +0 -12
- package/lib/index.js.map +0 -1
- package/lib/tsconfig.tsbuildinfo +0 -3104
package/package.json
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@futdevpro/fsm-dynamo",
|
|
3
|
-
"version": "01.05.
|
|
3
|
+
"version": "01.05.50",
|
|
4
4
|
"description": "Dynamic NodeTS (NodeJS-Typescript), MongoDB Backend System Framework by Future Development Ltd.",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"test": "echo \"Error: no test specified\" && exit 1",
|
|
7
|
+
|
|
8
|
+
"deploy": "npm run build",
|
|
7
9
|
|
|
8
10
|
"build": "npm run install-n-build",
|
|
9
11
|
"install-n-build": "npm i",
|
|
@@ -54,6 +56,12 @@
|
|
|
54
56
|
"types": "./lib/_modules/test-module.index.d.ts",
|
|
55
57
|
"typings": "./lib/_modules/test-module.index.d.ts"
|
|
56
58
|
},
|
|
59
|
+
"./custom-data-module": {
|
|
60
|
+
"default": "./lib/_modules/custom-data-module.index.js",
|
|
61
|
+
"module": "./lib/_modules/custom-data-module.index.js",
|
|
62
|
+
"types": "./lib/_modules/custom-data-module.index.d.ts",
|
|
63
|
+
"typings": "./lib/_modules/custom-data-module.index.d.ts"
|
|
64
|
+
},
|
|
57
65
|
"./usage-module": {
|
|
58
66
|
"default": "./lib/_modules/usage-module.index.js",
|
|
59
67
|
"module": "./lib/_modules/usage-module.index.js",
|
|
@@ -87,6 +95,9 @@
|
|
|
87
95
|
"test-module": [
|
|
88
96
|
"lib/_modules/test-module.index.d.ts"
|
|
89
97
|
],
|
|
98
|
+
"custom-data-module": [
|
|
99
|
+
"lib/_modules/custom-data-module.index.d.ts"
|
|
100
|
+
],
|
|
90
101
|
"usage-module": [
|
|
91
102
|
"lib/_modules/usage-module.index.d.ts"
|
|
92
103
|
],
|
|
@@ -2,19 +2,18 @@
|
|
|
2
2
|
import { LogStyle } from '../../_enums/log-style.enum';
|
|
3
3
|
|
|
4
4
|
export class Dynamo_Log {
|
|
5
|
-
|
|
6
|
-
static setLogStyle(styles: LogStyle[]): void {
|
|
5
|
+
static setStyle(styles: LogStyle[]): void {
|
|
7
6
|
let styleSets = '';
|
|
8
7
|
styles.forEach((style: LogStyle) => {
|
|
9
8
|
styleSets += style;
|
|
10
9
|
});
|
|
11
10
|
console.log(styleSets);
|
|
12
11
|
}
|
|
13
|
-
static
|
|
12
|
+
static resetStyle(): void {
|
|
14
13
|
console.log(LogStyle.reset);
|
|
15
14
|
}
|
|
16
15
|
|
|
17
|
-
static
|
|
16
|
+
static addStyle(input: string, styles: LogStyle[], dontReset?: boolean): string {
|
|
18
17
|
let result = '';
|
|
19
18
|
styles.forEach((style: LogStyle) => {
|
|
20
19
|
result += style;
|
|
@@ -26,29 +25,53 @@ export class Dynamo_Log {
|
|
|
26
25
|
return result;
|
|
27
26
|
}
|
|
28
27
|
|
|
29
|
-
static
|
|
28
|
+
static success(message: string, ...optionalParams: any[]): void {
|
|
30
29
|
if (0 < optionalParams.length) {
|
|
31
|
-
console.
|
|
30
|
+
console.log(`${LogStyle.green}${LogStyle.bright}${message}`, ...optionalParams, LogStyle.reset);
|
|
32
31
|
} else {
|
|
33
|
-
console.
|
|
32
|
+
console.log(`${LogStyle.green}${LogStyle.bright}${message}${LogStyle.reset}`);
|
|
34
33
|
}
|
|
35
34
|
}
|
|
35
|
+
/**
|
|
36
|
+
* @deprecated use Dynamo_Log.success instead
|
|
37
|
+
*/
|
|
38
|
+
static logSuccess(message: string, ...optionalParams: any[]) {
|
|
39
|
+
this.success(message, ...optionalParams);
|
|
40
|
+
}
|
|
36
41
|
|
|
37
|
-
static
|
|
42
|
+
static error(message: string, ...optionalParams: any[]): void {
|
|
38
43
|
if (0 < optionalParams.length) {
|
|
39
44
|
console.error(`${LogStyle.red}${LogStyle.bright}${message}`, ...optionalParams, LogStyle.reset);
|
|
40
45
|
} else {
|
|
41
46
|
console.error(`${LogStyle.red}${LogStyle.bright}${message}${LogStyle.reset}`);
|
|
42
47
|
}
|
|
43
48
|
}
|
|
49
|
+
/**
|
|
50
|
+
* @deprecated use Dynamo_Log.error instead
|
|
51
|
+
*/
|
|
52
|
+
static logError(message: string, ...optionalParams: any[]) {
|
|
53
|
+
this.error(message, ...optionalParams);
|
|
54
|
+
}
|
|
44
55
|
|
|
45
|
-
static
|
|
56
|
+
static warn(message: string, ...optionalParams: any[]): void {
|
|
46
57
|
if (0 < optionalParams.length) {
|
|
47
58
|
console.warn(`${LogStyle.yellow}${LogStyle.bright}${message}`, ...optionalParams, LogStyle.reset);
|
|
48
59
|
} else {
|
|
49
60
|
console.warn(`${LogStyle.yellow}${LogStyle.bright}${message}${LogStyle.reset}`);
|
|
50
61
|
}
|
|
51
62
|
}
|
|
63
|
+
/**
|
|
64
|
+
* @deprecated use Dynamo_Log.warn instead
|
|
65
|
+
*/
|
|
66
|
+
static warning(message: string, ...optionalParams: any[]) {
|
|
67
|
+
this.warn(message, ...optionalParams);
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* @deprecated use Dynamo_Log.warn instead
|
|
71
|
+
*/
|
|
72
|
+
static logWarning(message: string, ...optionalParams: any[]) {
|
|
73
|
+
this.warn(message, ...optionalParams);
|
|
74
|
+
}
|
|
52
75
|
|
|
53
76
|
static removeLogStyles(message: string): string {
|
|
54
77
|
for (let styleKey of Object(LogStyle)) {
|
|
@@ -56,5 +79,16 @@ export class Dynamo_Log {
|
|
|
56
79
|
}
|
|
57
80
|
return message;
|
|
58
81
|
}
|
|
82
|
+
|
|
83
|
+
static silenceLogs(): void {
|
|
84
|
+
console.log = () => {};
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
static silenceConsole(): void {
|
|
88
|
+
console.log = () => {};
|
|
89
|
+
console.warn = () => {};
|
|
90
|
+
console.error = () => {};
|
|
91
|
+
}
|
|
59
92
|
}
|
|
93
|
+
export class D_Log implements Dynamo_Log {};
|
|
60
94
|
|
|
@@ -33,33 +33,33 @@ export class Dynamo_Regions {
|
|
|
33
33
|
return result;
|
|
34
34
|
}
|
|
35
35
|
|
|
36
|
-
static
|
|
37
|
-
const country: CountryISO = this.ISOs.find(iso => iso.iso2 ==
|
|
36
|
+
static isoToCountryIso(iso2: string): CountryISO {
|
|
37
|
+
const country: CountryISO = this.ISOs.find(iso => iso.iso2 == iso2);
|
|
38
38
|
if (!country) {
|
|
39
39
|
throw new Dynamo_Error({
|
|
40
|
-
message: `Cannot find ISO-3166 code for this: ${
|
|
40
|
+
message: `Cannot find ISO-3166 code for this: ${iso2}`
|
|
41
41
|
});
|
|
42
42
|
} else {
|
|
43
43
|
return country;
|
|
44
44
|
}
|
|
45
45
|
}
|
|
46
46
|
|
|
47
|
-
static
|
|
48
|
-
const region: Region = this.ISOs.find(iso => iso.iso2 ==
|
|
47
|
+
static isoToRegion(iso2: string): Region {
|
|
48
|
+
const region: Region = this.ISOs.find(iso => iso.iso2 == iso2).region;
|
|
49
49
|
if (!region) {
|
|
50
50
|
throw new Dynamo_Error({
|
|
51
|
-
message: `Cannot find ISO-3166 code for this: ${
|
|
51
|
+
message: `Cannot find ISO-3166 code for this: ${iso2}`
|
|
52
52
|
});
|
|
53
53
|
} else {
|
|
54
54
|
return region;
|
|
55
55
|
}
|
|
56
56
|
}
|
|
57
57
|
|
|
58
|
-
static
|
|
59
|
-
const phoneCode: CountryPhoneCode = this.phoneCodes.find(code => code.iso ==
|
|
58
|
+
static isoToPhoneCode(iso2: string): CountryPhoneCode {
|
|
59
|
+
const phoneCode: CountryPhoneCode = this.phoneCodes.find(code => code.iso == iso2);
|
|
60
60
|
if (!phoneCode) {
|
|
61
61
|
throw new Dynamo_Error({
|
|
62
|
-
message: `Cannot find ISO-3166 code for this: ${
|
|
62
|
+
message: `Cannot find ISO-3166 code for this: ${iso2}`
|
|
63
63
|
});
|
|
64
64
|
} else {
|
|
65
65
|
return phoneCode;
|
package/src/_constants/index.ts
CHANGED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
|
|
2
|
+
import { Dynamo_RouteSettings } from '../../_models/control-models/dynamo-route-settings';
|
|
3
|
+
|
|
4
|
+
export const customDataModuleSettings: Dynamo_RouteSettings = {
|
|
5
|
+
mainRoute: '/custom',
|
|
6
|
+
endPoints: {
|
|
7
|
+
getCustomData: '/get/:customId',
|
|
8
|
+
modifyCustomData: '/post',
|
|
9
|
+
}
|
|
10
|
+
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
|
|
2
|
-
import {
|
|
2
|
+
import { Dynamo_RouteSettings } from '../../_models/control-models/dynamo-route-settings';
|
|
3
3
|
|
|
4
|
-
export const testModuleSettings:
|
|
4
|
+
export const testModuleSettings: Dynamo_RouteSettings = {
|
|
5
5
|
mainRoute: '/test',
|
|
6
6
|
endPoints: {
|
|
7
7
|
testGet: '/test-get',
|
|
@@ -9,7 +9,6 @@ export const testModuleSettings: DynamoNTS_ModuleSettings = {
|
|
|
9
9
|
testPut: '/test-put',
|
|
10
10
|
testPatch: '/test-patch',
|
|
11
11
|
testDelete: '/test-delete',
|
|
12
|
-
|
|
13
|
-
modifyCustomData: '/custom/post'
|
|
12
|
+
getServerStatus: '/server-status',
|
|
14
13
|
}
|
|
15
14
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
|
|
2
|
-
import {
|
|
2
|
+
import { Dynamo_RouteSettings } from '../../_models/control-models/dynamo-route-settings';
|
|
3
3
|
|
|
4
|
-
export const usageModuleSettings:
|
|
4
|
+
export const usageModuleSettings: Dynamo_RouteSettings = {
|
|
5
5
|
mainRoute: '/usage',
|
|
6
6
|
endPoints: {
|
|
7
7
|
newSession: '/new-session',
|
|
@@ -22,13 +22,14 @@ export class Dynamo_DailyUsageData {
|
|
|
22
22
|
}
|
|
23
23
|
) {
|
|
24
24
|
if (set) {
|
|
25
|
-
this
|
|
25
|
+
Object.assign(this, set)
|
|
26
|
+
/* this.date = set.date;
|
|
26
27
|
this.totalVisitTime = set.totalVisitTime ? set.totalVisitTime : 0;
|
|
27
28
|
this.averageVisitTime = set.averageVisitTime ? set.averageVisitTime : 0;
|
|
28
29
|
this.visitorsHun = set.visitorsHun ? set.visitorsHun : 0;
|
|
29
30
|
this.visitorsElse = set.visitorsElse ? set.visitorsElse : 0;
|
|
30
31
|
|
|
31
|
-
this.visitations = set.visitations ? set.visitations : [];
|
|
32
|
+
this.visitations = set.visitations ? set.visitations : []; */
|
|
32
33
|
}
|
|
33
34
|
}
|
|
34
35
|
}
|
|
@@ -1,18 +1,22 @@
|
|
|
1
1
|
|
|
2
2
|
import { DataModelType } from '../../_enums';
|
|
3
|
-
import {
|
|
3
|
+
import { Dynamo_DataPropertyParams } from './dynamo-data-property-params';
|
|
4
4
|
|
|
5
|
-
export class
|
|
5
|
+
export class Dynamo_DataParams {
|
|
6
6
|
dataName: string;
|
|
7
7
|
modelType?: DataModelType;
|
|
8
8
|
dbName: string;
|
|
9
|
-
modelParams:
|
|
9
|
+
modelParams: Dynamo_DataPropertyParams[] = [];
|
|
10
|
+
|
|
11
|
+
/** format info */
|
|
12
|
+
logicalBreakpoints?: number[] = [];
|
|
10
13
|
|
|
11
14
|
constructor(
|
|
12
15
|
set: {
|
|
13
16
|
dataName: string,
|
|
14
17
|
modelType?: DataModelType,
|
|
15
|
-
modelParams
|
|
18
|
+
modelParams?: Dynamo_DataPropertyParams[],
|
|
19
|
+
logicalBreakpoints?: number[],
|
|
16
20
|
}
|
|
17
21
|
) {
|
|
18
22
|
this.dataName = set.dataName;
|
|
@@ -22,6 +26,7 @@ export class DynamoNTS_DataParams {
|
|
|
22
26
|
this.modelType = DataModelType.dataModel;
|
|
23
27
|
this.dbName = set.dataName.charAt(0).toUpperCase() + set.dataName.slice(1);
|
|
24
28
|
}
|
|
25
|
-
this.modelParams = set.modelParams
|
|
29
|
+
this.modelParams = set.modelParams ?? [];
|
|
30
|
+
this.logicalBreakpoints = set.logicalBreakpoints ?? [];
|
|
26
31
|
}
|
|
27
32
|
}
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
+
import { BasicPropertyType } from '../../_enums/basic-property-type.enum';
|
|
1
2
|
|
|
2
3
|
/**
|
|
3
4
|
* This will be used for setting up db. DataServices also uses this to prehook tools, as db service and dependency db service.
|
|
4
5
|
*/
|
|
5
|
-
export class
|
|
6
|
+
export class Dynamo_DataPropertyParams {
|
|
6
7
|
key?: string;
|
|
7
|
-
type?:
|
|
8
|
+
type?: BasicPropertyType | string;
|
|
8
9
|
|
|
9
10
|
unique?: boolean;
|
|
10
11
|
required?: boolean;
|
|
@@ -23,14 +24,14 @@ export class DynamoNTS_DataPropertyParams {
|
|
|
23
24
|
minlength?: number;
|
|
24
25
|
maxlength?: number;
|
|
25
26
|
|
|
26
|
-
subObjectParams?:
|
|
27
|
+
subObjectParams?: Dynamo_DataPropertyParams[] = [];
|
|
27
28
|
|
|
28
29
|
additionalValidators?: ((data: any) => void)[];
|
|
29
30
|
|
|
30
31
|
constructor(
|
|
31
32
|
set: {
|
|
32
33
|
key: string,
|
|
33
|
-
type:
|
|
34
|
+
type: BasicPropertyType | string,
|
|
34
35
|
|
|
35
36
|
unique?: boolean,
|
|
36
37
|
required?: boolean,
|
|
@@ -49,7 +50,7 @@ export class DynamoNTS_DataPropertyParams {
|
|
|
49
50
|
minlength?: number,
|
|
50
51
|
maxlength?: number,
|
|
51
52
|
|
|
52
|
-
subObjectParams?:
|
|
53
|
+
subObjectParams?: Dynamo_DataPropertyParams[],
|
|
53
54
|
|
|
54
55
|
additionalValidators?: ((data: any) => void)[],
|
|
55
56
|
}
|
|
@@ -83,15 +84,15 @@ export class DynamoNTS_DataPropertyParams {
|
|
|
83
84
|
// tslint:disable-next-line: ban-types
|
|
84
85
|
getBEType?(): String | Number | Boolean | Object | Function | Array<any> | Date {
|
|
85
86
|
switch (this.type) {
|
|
86
|
-
case
|
|
87
|
+
case BasicPropertyType.string:
|
|
87
88
|
return String;
|
|
88
|
-
case
|
|
89
|
+
case BasicPropertyType.number:
|
|
89
90
|
return Number;
|
|
90
|
-
case
|
|
91
|
+
case BasicPropertyType.boolean:
|
|
91
92
|
return Boolean;
|
|
92
|
-
case
|
|
93
|
+
case BasicPropertyType.date:
|
|
93
94
|
return Date;
|
|
94
|
-
case
|
|
95
|
+
case BasicPropertyType.object:
|
|
95
96
|
default:
|
|
96
97
|
if (this.type?.includes('[]')) {
|
|
97
98
|
return Array;
|
|
@@ -141,7 +141,7 @@ export class Dynamo_Error {
|
|
|
141
141
|
}
|
|
142
142
|
} catch (error) {
|
|
143
143
|
console.error('Internal Dynamo ERROR: Failed to create Dynamo_Error...', error, set);
|
|
144
|
-
throw new Error('Internal Dynamo ERROR: Failed to create Dynamo_Error...');
|
|
144
|
+
/* throw new Error('Internal Dynamo ERROR: Failed to create Dynamo_Error...'); */
|
|
145
145
|
}
|
|
146
146
|
}
|
|
147
147
|
}
|
|
@@ -16,10 +16,11 @@ export class Dynamo_UsageData {
|
|
|
16
16
|
}
|
|
17
17
|
) {
|
|
18
18
|
if (set) {
|
|
19
|
-
this
|
|
19
|
+
Object.assign(this, set)
|
|
20
|
+
/* this.page = set.page;
|
|
20
21
|
this.opened = set.opened;
|
|
21
22
|
this.timeSpentOnPage = set.timeSpentOnPage;
|
|
22
|
-
this.actions = set.actions ? set.actions : [];
|
|
23
|
+
this.actions = set.actions ? set.actions : []; */
|
|
23
24
|
}
|
|
24
25
|
}
|
|
25
26
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
import {
|
|
2
|
+
import { Dynamo_DataParams } from '../control-models/dynamo-data-params';
|
|
3
3
|
import { Dynamo_Metadata } from './dynamo-metadata';
|
|
4
4
|
|
|
5
5
|
export class Dynamo_CustomData extends Dynamo_Metadata {
|
|
@@ -18,21 +18,22 @@ export class Dynamo_CustomData extends Dynamo_Metadata {
|
|
|
18
18
|
__lastModifiedBy?: string,
|
|
19
19
|
}
|
|
20
20
|
) {
|
|
21
|
-
super({
|
|
21
|
+
super(set/* {
|
|
22
22
|
_id: set?._id,
|
|
23
23
|
__v: set?.__v,
|
|
24
24
|
__created: set?.__created,
|
|
25
25
|
__createdBy: set?.__createdBy,
|
|
26
26
|
__lastModified: set?.__lastModified,
|
|
27
27
|
__lastModifiedBy: set?.__lastModifiedBy,
|
|
28
|
-
})
|
|
28
|
+
} */)
|
|
29
29
|
if (set) {
|
|
30
|
-
this
|
|
30
|
+
Object.assign(this, set);
|
|
31
|
+
/* this.data = set.data; */
|
|
31
32
|
}
|
|
32
33
|
}
|
|
33
34
|
}
|
|
34
35
|
|
|
35
|
-
export const customDataModelParams = new
|
|
36
|
+
export const customDataModelParams = new Dynamo_DataParams({
|
|
36
37
|
dataName: 'customData',
|
|
37
38
|
modelParams: [
|
|
38
39
|
{ key: 'data', type: 'string', required: true },
|
|
@@ -21,13 +21,17 @@ export class Dynamo_Metadata {
|
|
|
21
21
|
} | Dynamo_Metadata
|
|
22
22
|
){
|
|
23
23
|
if (set) {
|
|
24
|
-
|
|
24
|
+
if (!set._id && set._id !== undefined) {
|
|
25
|
+
delete set._id;
|
|
26
|
+
}
|
|
25
27
|
|
|
26
|
-
this
|
|
28
|
+
Object.assign(this, set);
|
|
29
|
+
|
|
30
|
+
/* this.__created = set.__created;
|
|
27
31
|
this.__createdBy = set.__createdBy;
|
|
28
32
|
this.__lastModified = set.__lastModified;
|
|
29
33
|
this.__lastModifiedBy = set.__lastModifiedBy;
|
|
30
|
-
this.__v = set.__v;
|
|
34
|
+
this.__v = set.__v; */
|
|
31
35
|
}
|
|
32
36
|
}
|
|
33
37
|
}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import { GeoIpLocation } from '../control-models/geo-ip-location';
|
|
3
3
|
import { Dynamo_Metadata } from './dynamo-metadata';
|
|
4
4
|
import { Dynamo_UsageData } from '../control-models/dynamo-usage-data';
|
|
5
|
-
import {
|
|
5
|
+
import { Dynamo_DataParams } from '../control-models/dynamo-data-params';
|
|
6
6
|
|
|
7
7
|
export class Dynamo_UsageSession extends Dynamo_Metadata {
|
|
8
8
|
date?: string;
|
|
@@ -12,7 +12,7 @@ export class Dynamo_UsageSession extends Dynamo_Metadata {
|
|
|
12
12
|
issuer?: string;
|
|
13
13
|
locationData?: GeoIpLocation;
|
|
14
14
|
|
|
15
|
-
usageData?: Dynamo_UsageData[];
|
|
15
|
+
usageData?: Dynamo_UsageData[] = [];
|
|
16
16
|
totalSessionTime?: number;
|
|
17
17
|
loggedInAs?: string;
|
|
18
18
|
|
|
@@ -36,23 +36,15 @@ export class Dynamo_UsageSession extends Dynamo_Metadata {
|
|
|
36
36
|
__lastModified?: Date,
|
|
37
37
|
__lastModifiedBy?: string,
|
|
38
38
|
__v?: number
|
|
39
|
-
}
|
|
39
|
+
} | Dynamo_UsageSession
|
|
40
40
|
) {
|
|
41
|
-
super(
|
|
42
|
-
_id: set?._id,
|
|
43
|
-
__created: set?.__created,
|
|
44
|
-
__createdBy: set?.__createdBy,
|
|
45
|
-
__lastModified: set?.__lastModified,
|
|
46
|
-
__lastModifiedBy: set?.__lastModifiedBy,
|
|
47
|
-
__v: set?.__v,
|
|
48
|
-
});
|
|
41
|
+
super(set);
|
|
49
42
|
if (set) {
|
|
50
|
-
if (set.date) {
|
|
51
|
-
|
|
52
|
-
} else if (set.sessionStart) {
|
|
53
|
-
this.date = set.sessionStart.toISOString().substring(0, 10);
|
|
43
|
+
if (!set.date && set.sessionStart) {
|
|
44
|
+
set.date = set.sessionStart.toISOString().substring(0, 10);
|
|
54
45
|
}
|
|
55
|
-
this
|
|
46
|
+
Object.assign(this, set);
|
|
47
|
+
/* this.sessionStart = set.sessionStart;
|
|
56
48
|
this.sessionEnd = set.sessionEnd;
|
|
57
49
|
this.address = set.address;
|
|
58
50
|
this.issuer = set.issuer;
|
|
@@ -60,12 +52,12 @@ export class Dynamo_UsageSession extends Dynamo_Metadata {
|
|
|
60
52
|
|
|
61
53
|
this.usageData = set.usageData ? set.usageData : [];
|
|
62
54
|
this.totalSessionTime = set.totalSessionTime;
|
|
63
|
-
this.loggedInAs = set.loggedInAs;
|
|
55
|
+
this.loggedInAs = set.loggedInAs; */
|
|
64
56
|
}
|
|
65
57
|
}
|
|
66
58
|
}
|
|
67
59
|
|
|
68
|
-
export const usageSessionModelParams = new
|
|
60
|
+
export const usageSessionModelParams = new Dynamo_DataParams({
|
|
69
61
|
dataName: 'usageSession',
|
|
70
62
|
modelParams: [
|
|
71
63
|
{ key: 'date', type: 'string',
|
package/src/_models/index.ts
CHANGED
|
@@ -5,10 +5,11 @@ export * from './control-models/country-iso';
|
|
|
5
5
|
export * from './control-models/country-phone-code';
|
|
6
6
|
export * from './control-models/dynamo-daily-usage-data';
|
|
7
7
|
export * from './control-models/dynamo-error';
|
|
8
|
-
export * from './control-models/dynamo-
|
|
9
|
-
export * from './control-models/dynamo-
|
|
10
|
-
export * from './control-models/dynamo-
|
|
8
|
+
export * from './control-models/dynamo-data-params';
|
|
9
|
+
export * from './control-models/dynamo-data-property-params';
|
|
10
|
+
export * from './control-models/dynamo-route-settings';
|
|
11
11
|
export * from './control-models/dynamo-poll';
|
|
12
|
+
export * from './control-models/dynamo-range-value';
|
|
12
13
|
export * from './control-models/dynamo-usage-action';
|
|
13
14
|
export * from './control-models/dynamo-usage-data';
|
|
14
15
|
export * from './control-models/geo-ip-location';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
|
|
2
2
|
// DATA MODULE
|
|
3
3
|
export * from '../_models/data-models/dynamo-metadata';
|
|
4
|
-
export * from '../_models/control-models/dynamo-
|
|
5
|
-
export * from '../_models/control-models/dynamo-
|
|
4
|
+
export * from '../_models/control-models/dynamo-data-params';
|
|
5
|
+
export * from '../_models/control-models/dynamo-data-property-params';
|
|
6
6
|
export * from '../_models/control-models/dynamo-error';
|
|
7
7
|
export * from '../_enums/data-model-type.enum';
|
|
8
8
|
|