@futdevpro/nts-dynamo 1.9.44 → 1.9.45
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/build/_collections/global-settings.const.d.ts.map +1 -1
- package/build/_collections/global-settings.const.js +1 -0
- package/build/_collections/global-settings.const.js.map +1 -1
- package/build/_models/interfaces/global-settings.interface.d.ts +4 -0
- package/build/_models/interfaces/global-settings.interface.d.ts.map +1 -1
- package/build/_services/base/archive-data.service.d.ts +1 -1
- package/build/_services/base/archive-data.service.d.ts.map +1 -1
- package/build/_services/base/archive-data.service.js +1 -1
- package/build/_services/base/archive-data.service.js.map +1 -1
- package/build/_services/base/data.service.d.ts +5 -5
- package/build/_services/base/data.service.d.ts.map +1 -1
- package/build/_services/base/data.service.js +59 -11
- package/build/_services/base/data.service.js.map +1 -1
- package/build/_services/base/db.service.d.ts +7 -8
- package/build/_services/base/db.service.d.ts.map +1 -1
- package/build/_services/base/db.service.js +15 -4
- package/build/_services/base/db.service.js.map +1 -1
- package/build/index.d.ts +3 -5
- package/build/index.d.ts.map +1 -1
- package/build/index.js +3 -5
- package/build/index.js.map +1 -1
- package/package.json +3 -3
- package/src/_collections/global-settings.const.ts +2 -1
- package/src/_models/interfaces/global-settings.interface.ts +5 -0
- package/src/_services/base/archive-data.service.ts +7 -5
- package/src/_services/base/data.service.ts +119 -48
- package/src/_services/base/db.service.ts +35 -15
- package/src/index.ts +3 -5
- package/build/_models/types/db-filter.type.d.ts +0 -97
- package/build/_models/types/db-filter.type.d.ts.map +0 -1
- package/build/_models/types/db-filter.type.js +0 -3
- package/build/_models/types/db-filter.type.js.map +0 -1
- package/src/_models/types/db-filter.type.ts +0 -108
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"db-filter.type.js","sourceRoot":"","sources":["../../../src/_models/types/db-filter.type.ts"],"names":[],"mappings":""}
|
|
@@ -1,108 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
/**
|
|
3
|
-
* @example
|
|
4
|
-
* // by email:
|
|
5
|
-
* { email: email }
|
|
6
|
-
* //
|
|
7
|
-
* @example
|
|
8
|
-
* // or by id that is in list:
|
|
9
|
-
* { userIds: { $in: this.userId } }
|
|
10
|
-
* //
|
|
11
|
-
* @example
|
|
12
|
-
* // or by number or Date that is Greater Than AND Less Than:
|
|
13
|
-
* { points: { $gt: 2, $lt: 14 } }
|
|
14
|
-
* // further tools (syntax matches with $gt):
|
|
15
|
-
* $eq: // Matches values that are EQual to a specified value.
|
|
16
|
-
* $gte: // Matches values that are Greater Than OR Equal to a specified value.
|
|
17
|
-
* $lte: // Matches values that are Less Than or Equal to a specified value.
|
|
18
|
-
* $ne: // Matches all values that are Not Equal to a specified value.
|
|
19
|
-
* $nin: // Matches None of the values specified IN an array.
|
|
20
|
-
* //
|
|
21
|
-
* @returns {T} data: T
|
|
22
|
-
*/
|
|
23
|
-
export type DyNTS_DBFilter<T> =
|
|
24
|
-
DyNTS_DBFilterSimple<T> |
|
|
25
|
-
DyNTS_DBFilterOR<T> |
|
|
26
|
-
DyNTS_DBFilterNOR<T>;
|
|
27
|
-
|
|
28
|
-
/**
|
|
29
|
-
* A simple filter for a DynamoDB query.
|
|
30
|
-
*/
|
|
31
|
-
export type DyNTS_DBFilterSimple<T> = {
|
|
32
|
-
[K in keyof T]?: T[K] | DyNTS_DBFilterExpressions<T[K] | boolean>;
|
|
33
|
-
} & {
|
|
34
|
-
[path: string]: any;
|
|
35
|
-
};
|
|
36
|
-
|
|
37
|
-
export type DyNTS_DBFilterExpressions<T> = {
|
|
38
|
-
/**
|
|
39
|
-
* Matches values that are includes the value; This works only when T[K] is an array!
|
|
40
|
-
*/
|
|
41
|
-
$in?: any,
|
|
42
|
-
/**
|
|
43
|
-
* Matches values that are EQual to a specified value.
|
|
44
|
-
*/
|
|
45
|
-
$eq?: T,
|
|
46
|
-
/**
|
|
47
|
-
* Matches values that are Greater Than a specified value.
|
|
48
|
-
*/
|
|
49
|
-
$gt?: number | Date,
|
|
50
|
-
/**
|
|
51
|
-
* Matches values that are Greater Than OR Equal to a specified value.
|
|
52
|
-
*/
|
|
53
|
-
$gte?: number | Date,
|
|
54
|
-
/**
|
|
55
|
-
* Matches values that are Less Than a specified value.
|
|
56
|
-
*/
|
|
57
|
-
$lt?: number | Date,
|
|
58
|
-
/**
|
|
59
|
-
* Matches values that are Less Than or Equal to a specified value.
|
|
60
|
-
*/
|
|
61
|
-
$lte?: number | Date,
|
|
62
|
-
/**
|
|
63
|
-
* Matches all values that are Not Equal to a specified value.
|
|
64
|
-
*/
|
|
65
|
-
$ne?: T,
|
|
66
|
-
/**
|
|
67
|
-
* Matches None of the values specified IN an array.
|
|
68
|
-
*/
|
|
69
|
-
$nin?: T,
|
|
70
|
-
/**
|
|
71
|
-
* Inverts the effect of a query expression and returns documents that do not match the query expression.
|
|
72
|
-
*/
|
|
73
|
-
$not?: T | {
|
|
74
|
-
$regex?: RegExp | string,
|
|
75
|
-
},
|
|
76
|
-
/**
|
|
77
|
-
* Performs a regular expression on the field's value, and selects documents that match the regular expression.
|
|
78
|
-
*/
|
|
79
|
-
$exists?: boolean,
|
|
80
|
-
/**
|
|
81
|
-
* Selects documents if a field is of the specified type.
|
|
82
|
-
*/
|
|
83
|
-
$type?: string,
|
|
84
|
-
};
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
/**
|
|
88
|
-
* Joins query clauses with a logical AND returns all documents that match the conditions of both clauses.
|
|
89
|
-
*/
|
|
90
|
-
export type DyNTS_DBFilterNOR<T> = {
|
|
91
|
-
/**
|
|
92
|
-
* Joins query clauses with a logical NOR returns all documents that fail to match both clauses.
|
|
93
|
-
*/
|
|
94
|
-
$nor: DyNTS_DBFilterSimple<T>[];
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
/**
|
|
99
|
-
* Joins query clauses with a logical AND returns all documents that match the conditions of both clauses.
|
|
100
|
-
*/
|
|
101
|
-
export type DyNTS_DBFilterOR<T> = {
|
|
102
|
-
/**
|
|
103
|
-
* Joins query clauses with a logical OR returns all documents that match the conditions of either clause.
|
|
104
|
-
*/
|
|
105
|
-
$or: DyNTS_DBFilterSimple<T>[];
|
|
106
|
-
}
|
|
107
|
-
|
|
108
|
-
|