@futdevpro/nts-dynamo 1.5.53 → 1.5.54

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.
@@ -23,14 +23,14 @@ export declare class DynamoNTS_DataService<T extends Dynamo_Metadata> {
23
23
  dataDBService: DynamoNTS_DBService<T>;
24
24
  data: T;
25
25
  dataList: T[];
26
- issuer?: string;
26
+ issuer: string;
27
27
  depKey?: string;
28
28
  depDBServiceKey?: string;
29
29
  private depDataDBService;
30
30
  dataParams: DynamoNTS_DataParams;
31
31
  defaultErrorUserMsg: string;
32
32
  defaultValidationErrorUserMsg: string;
33
- constructor(data: T, dataParams: DynamoNTS_DataParams, issuer?: string);
33
+ constructor(data: T, dataParams: DynamoNTS_DataParams, issuer: string);
34
34
  /**
35
35
  * returns all data from database to service dataList
36
36
  */
@@ -39,7 +39,7 @@ export declare class DynamoNTS_DataService<T extends Dynamo_Metadata> {
39
39
  * @description
40
40
  * returns data from database by id
41
41
  * also if dontSetToService is false or not setted,
42
- * the data will be saved to the service
42
+ * the data will be saved to the service, even if its not found
43
43
  *
44
44
  * @remarks
45
45
  * If you need to get-save a data, if possible,
@@ -61,10 +61,123 @@ export declare class DynamoNTS_DataService<T extends Dynamo_Metadata> {
61
61
  * @param dependencyId
62
62
  */
63
63
  getDataListByDependencyId(dependencyId?: string): Promise<void>;
64
+ /**
65
+ *
66
+ * // findOne desc:
67
+ *
68
+ * Find the data first by any of its parameters,
69
+ * also if dontSetToService is false or not setted,
70
+ * the data will be saved to the service, even if non found
71
+ *
72
+ * @param filter if you can, use unique parameters for find!
73
+ *
74
+ * @example
75
+ * // by email:
76
+ * { email: email }
77
+ * //
78
+ * @example
79
+ * // or by id that is in list:
80
+ * { userIds: { $in: this.userId } }
81
+ * //
82
+ * @example
83
+ * // or by number or Date that is Greater Than AND Less Than:
84
+ * { points: { $gt: 2, $lt: 14 } }
85
+ * // further tools (syntax matches with $gt):
86
+ * $eq: // Matches values that are EQual to a specified value.
87
+ * $gte: // Matches values that are Greater Than OR Equal to a specified value.
88
+ * $lte: // Matches values that are Less Than or Equal to a specified value.
89
+ * $ne: // Matches all values that are Not Equal to a specified value.
90
+ * $nin: // Matches None of the values specified IN an array.
91
+ * //
92
+ * @returns {T} data: T
93
+ */
94
+ findData(findBy: any, dontSetToService?: boolean): Promise<T>;
95
+ /**
96
+ *
97
+ * // find desc:
98
+ *
99
+ * Find the data first by any of its parameters,
100
+ * also if dontSetToService is false or not setted,
101
+ * the data will be saved to the service, even if non found
102
+ *
103
+ * @param filter if you can, use unique parameters for find!
104
+ *
105
+ * @example
106
+ * // by email:
107
+ * { email: email }
108
+ * //
109
+ * @example
110
+ * // or by id that is in list:
111
+ * { userIds: { $in: this.userId } }
112
+ * //
113
+ * @example
114
+ * // or by number or Date that is Greater Than AND Less Than:
115
+ * { points: { $gt: 2, $lt: 14 } }
116
+ * // further tools (syntax matches with $gt):
117
+ * $eq: // Matches values that are EQual to a specified value.
118
+ * $gte: // Matches values that are Greater Than OR Equal to a specified value.
119
+ * $lte: // Matches values that are Less Than or Equal to a specified value.
120
+ * $ne: // Matches all values that are Not Equal to a specified value.
121
+ * $nin: // Matches None of the values specified IN an array.
122
+ * //
123
+ * @returns {T[]} dataList: T[]
124
+ */
125
+ findDatas(findBy: any, dontSetToService?: boolean): Promise<T[]>;
64
126
  /**
65
127
  * This function uses the dataDBService.updateOne function.
66
128
  * This uses updateBy if setted, or data._id if its setted or this.data[this.dependencyKey]
67
129
  * @param set
130
+ *
131
+ * // updateOne desc:
132
+ *
133
+ * Find the data first by any of its parameters, throws error if not found
134
+ * @param filter This uses the basic Mongoose updateOne.
135
+ * If you can, use unique parameters for find!
136
+ * @example
137
+ * // by email:
138
+ * { email: email }
139
+ * //
140
+ * @example
141
+ * // or by id that is in list:
142
+ * { userIds: { $in: this.userId } }
143
+ * //
144
+ * @example
145
+ * // or by number or Date that is Greater Than AND Less Than:
146
+ * { points: { $gt: 2, $lt: 14 } }
147
+ * // further tools (syntax matches with $gt):
148
+ * $eq: // Matches values that are EQual to a specified value.
149
+ * $gte: // Matches values that are Greater Than OR Equal to a specified value.
150
+ * $lte: // Matches values that are Less Than or Equal to a specified value.
151
+ * $ne: // Matches all values that are Not Equal to a specified value.
152
+ * $nin: // Matches None of the values specified IN an array.
153
+ * //
154
+ *
155
+ * @param update this uses the basic Mongoose updateOne
156
+ * @example
157
+ * // increase a specific value (here by 15):
158
+ * { $inc: { popularity: 15 } }
159
+ * //
160
+ * @example
161
+ * // or add element to a list:
162
+ * { $push: { reactions: this.newReaction }
163
+ * // or add multiple elements to a list
164
+ * { $push: { schedule: {$each: [ monday, tuesday, wednesday ] } } }
165
+ * //
166
+ * @example
167
+ * // or all at once
168
+ * {
169
+ * $inc: { popularity: this.newVote.amount },
170
+ * emailVerified: true,
171
+ * $push: { reactions: this.newReaction }
172
+ * }
173
+ * // further tools (syntax matches with $inc):
174
+ * $currentDate: // Sets the value of a field to current date, either as a Date or a Timestamp.
175
+ * $min: // Only updates the field if the specified value is less than the existing field value.
176
+ * $max: // Only updates the field if the specified value is greater than the existing field value.
177
+ * $mul: // Multiplies the value of the field by the specified amount.
178
+ * $rename: // Renames a field.
179
+ * $unset: // Removes the specified field from a document. (set: "" to value)
180
+ * //
68
181
  */
69
182
  updateData(set: {
70
183
  updateBy?: any;
@@ -74,6 +187,7 @@ export declare class DynamoNTS_DataService<T extends Dynamo_Metadata> {
74
187
  * modifies data if the data have ID and already exists in the DB,
75
188
  * creates new if the ID is not present or cant find in DB,
76
189
  * and if dependency data setted up, will check before creation,
190
+ *
77
191
  * @warning
78
192
  * but the proper way to update data, if you use update method instead,
79
193
  * this way, you can avoid data override errors
@@ -1 +1 @@
1
- {"version":3,"file":"dynamo-nts-data.service.d.ts","sourceRoot":"","sources":["../../src/_services/dynamo-nts-data.service.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,oBAAoB,EAA8C,MAAM,uBAAuB,CAAC;AAE1H,OAAO,EAAE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AC,IAAI,CAAC;IA0CrE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA6BG;IACG,QAAQ,CAAC,MAAM,EAAE,GAAG,EAAE,gBAAgB,CAAC,EAAE,OAAO,GAAG,OAAO,CAAC,CAAC,CAAC;IA0BnE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA6BG;IACG,SAAS,CAAC,MAAM,EAAE,GAAG,EAAE,gBAAgB,CAAC,EAAE,OAAO,GAAG,OAAO,CAAC,CAAC,EAAE,CAAC;IA0BtE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAuDG;IACG,UAAU,CAAC,GAAG,EAAE;QAAE,QAAQ,CAAC,EAAE,GAAG,CAAC;QAAC,MAAM,EAAE,GAAG,CAAA;KAAE,GAAG,OAAO,CAAC,IAAI,CAAC;IA6BrE;;;;;;;;;;OAUG;IACG,QAAQ,IAAI,OAAO,CAAC,IAAI,CAAC;IA0D/B;;OAEG;IACG,UAAU,IAAI,OAAO,CAAC,IAAI,CAAC;IAyBjC;;OAEG;IACG,eAAe,IAAI,OAAO,CAAC,IAAI,CAAC;IA6CtC;;OAEG;IACH,OAAO,CAAC,6BAA6B;IAUrC;;;OAGG;IACH,0BAA0B,IAAI,mBAAmB,CAAC,GAAG,CAAC;CAkBvD"}
@@ -31,7 +31,6 @@ class DynamoNTS_DataService {
31
31
  this.dataDBService = dynamo_nts_global_service_1.DynamoNTS_GlobalService.getDBService(dataParams);
32
32
  this.data = data;
33
33
  this.dataParams = dataParams;
34
- // this.dataModelParams = dataParams.modelParams;
35
34
  this.lookForDependencyDataSettings();
36
35
  this.issuer = issuer;
37
36
  }
@@ -41,7 +40,16 @@ class DynamoNTS_DataService {
41
40
  getAll() {
42
41
  return tslib_1.__awaiter(this, void 0, void 0, function* () {
43
42
  try {
44
- this.dataList = yield this.dataDBService.getAll();
43
+ this.dataList = yield this.dataDBService.getAll().catch(error => {
44
+ var _a;
45
+ if ((_a = error === null || error === void 0 ? void 0 : error.errorCodes) === null || _a === void 0 ? void 0 : _a.includes('NTS-DBS-GA1')) {
46
+ console.error(error);
47
+ return [];
48
+ }
49
+ else {
50
+ throw error;
51
+ }
52
+ });
45
53
  }
46
54
  catch (error) {
47
55
  throw new fsm_dynamo_1.Dynamo_Error({
@@ -59,7 +67,7 @@ class DynamoNTS_DataService {
59
67
  * @description
60
68
  * returns data from database by id
61
69
  * also if dontSetToService is false or not setted,
62
- * the data will be saved to the service
70
+ * the data will be saved to the service, even if its not found
63
71
  *
64
72
  * @remarks
65
73
  * If you need to get-save a data, if possible,
@@ -74,8 +82,17 @@ class DynamoNTS_DataService {
74
82
  return tslib_1.__awaiter(this, void 0, void 0, function* () {
75
83
  try {
76
84
  if (id || this.data._id) {
77
- let dataExists = yield this.dataDBService.getDataById(id ? id : this.data._id);
78
- if (!dontSetToService && dataExists) {
85
+ let dataExists = yield this.dataDBService.getDataById(id ? id : this.data._id).catch(error => {
86
+ var _a;
87
+ if ((_a = error === null || error === void 0 ? void 0 : error.errorCodes) === null || _a === void 0 ? void 0 : _a.includes('NTS-DBS-GI1')) {
88
+ console.error(error);
89
+ return null;
90
+ }
91
+ else {
92
+ throw error;
93
+ }
94
+ });
95
+ if (!dontSetToService) {
79
96
  this.data = dataExists;
80
97
  }
81
98
  return dataExists;
@@ -111,7 +128,16 @@ class DynamoNTS_DataService {
111
128
  try {
112
129
  if (this.depKey) {
113
130
  if (dependencyId || this.data[this.depKey]) {
114
- let dataExists = yield this.dataDBService.getDataByDependencyId(dependencyId ? dependencyId : this.data[this.depKey]);
131
+ let dataExists = yield this.dataDBService.getDataByDependencyId(dependencyId ? dependencyId : this.data[this.depKey]).catch(error => {
132
+ var _a;
133
+ if ((_a = error === null || error === void 0 ? void 0 : error.errorCodes) === null || _a === void 0 ? void 0 : _a.includes('NTS-DBS-GD2')) {
134
+ console.error(error);
135
+ return null;
136
+ }
137
+ else {
138
+ throw error;
139
+ }
140
+ });
115
141
  if (!dontSetToService && dataExists) {
116
142
  this.data = dataExists;
117
143
  }
@@ -158,7 +184,16 @@ class DynamoNTS_DataService {
158
184
  try {
159
185
  if (this.depKey) {
160
186
  if (dependencyId || this.data[this.depKey]) {
161
- this.dataList = yield this.dataDBService.getDataListByDependencyId(dependencyId ? dependencyId : this.data[this.depKey]);
187
+ this.dataList = yield this.dataDBService.getDataListByDependencyId(dependencyId ? dependencyId : this.data[this.depKey]).catch(error => {
188
+ var _a;
189
+ if ((_a = error === null || error === void 0 ? void 0 : error.errorCodes) === null || _a === void 0 ? void 0 : _a.includes('NTS-DBS-GLD2')) {
190
+ console.error(error);
191
+ return [];
192
+ }
193
+ else {
194
+ throw error;
195
+ }
196
+ });
162
197
  }
163
198
  else {
164
199
  throw new fsm_dynamo_1.Dynamo_Error({
@@ -192,10 +227,181 @@ class DynamoNTS_DataService {
192
227
  }
193
228
  });
194
229
  }
230
+ /**
231
+ *
232
+ * // findOne desc:
233
+ *
234
+ * Find the data first by any of its parameters,
235
+ * also if dontSetToService is false or not setted,
236
+ * the data will be saved to the service, even if non found
237
+ *
238
+ * @param filter if you can, use unique parameters for find!
239
+ *
240
+ * @example
241
+ * // by email:
242
+ * { email: email }
243
+ * //
244
+ * @example
245
+ * // or by id that is in list:
246
+ * { userIds: { $in: this.userId } }
247
+ * //
248
+ * @example
249
+ * // or by number or Date that is Greater Than AND Less Than:
250
+ * { points: { $gt: 2, $lt: 14 } }
251
+ * // further tools (syntax matches with $gt):
252
+ * $eq: // Matches values that are EQual to a specified value.
253
+ * $gte: // Matches values that are Greater Than OR Equal to a specified value.
254
+ * $lte: // Matches values that are Less Than or Equal to a specified value.
255
+ * $ne: // Matches all values that are Not Equal to a specified value.
256
+ * $nin: // Matches None of the values specified IN an array.
257
+ * //
258
+ * @returns {T} data: T
259
+ */
260
+ findData(findBy, dontSetToService) {
261
+ return tslib_1.__awaiter(this, void 0, void 0, function* () {
262
+ try {
263
+ const dataExists = yield this.dataDBService.findOne(findBy).catch(error => {
264
+ var _a;
265
+ if ((_a = error === null || error === void 0 ? void 0 : error.errorCodes) === null || _a === void 0 ? void 0 : _a.includes('NTS-DBS-FO1')) {
266
+ console.error(error);
267
+ return null;
268
+ }
269
+ else {
270
+ throw error;
271
+ }
272
+ });
273
+ if (!dontSetToService) {
274
+ this.data = dataExists;
275
+ }
276
+ return dataExists;
277
+ }
278
+ catch (error) {
279
+ throw new fsm_dynamo_1.Dynamo_Error({
280
+ status: 417,
281
+ errorCode: 'NTS-DS0-FD0',
282
+ addECToUserMsg: true,
283
+ message: `findData was unsuccessful (${this.dataParams.dataName})`,
284
+ userMessage: this.defaultErrorUserMsg,
285
+ error: error
286
+ });
287
+ }
288
+ });
289
+ }
290
+ /**
291
+ *
292
+ * // find desc:
293
+ *
294
+ * Find the data first by any of its parameters,
295
+ * also if dontSetToService is false or not setted,
296
+ * the data will be saved to the service, even if non found
297
+ *
298
+ * @param filter if you can, use unique parameters for find!
299
+ *
300
+ * @example
301
+ * // by email:
302
+ * { email: email }
303
+ * //
304
+ * @example
305
+ * // or by id that is in list:
306
+ * { userIds: { $in: this.userId } }
307
+ * //
308
+ * @example
309
+ * // or by number or Date that is Greater Than AND Less Than:
310
+ * { points: { $gt: 2, $lt: 14 } }
311
+ * // further tools (syntax matches with $gt):
312
+ * $eq: // Matches values that are EQual to a specified value.
313
+ * $gte: // Matches values that are Greater Than OR Equal to a specified value.
314
+ * $lte: // Matches values that are Less Than or Equal to a specified value.
315
+ * $ne: // Matches all values that are Not Equal to a specified value.
316
+ * $nin: // Matches None of the values specified IN an array.
317
+ * //
318
+ * @returns {T[]} dataList: T[]
319
+ */
320
+ findDatas(findBy, dontSetToService) {
321
+ return tslib_1.__awaiter(this, void 0, void 0, function* () {
322
+ try {
323
+ const dataListExists = yield this.dataDBService.find(findBy).catch(error => {
324
+ var _a;
325
+ if ((_a = error === null || error === void 0 ? void 0 : error.errorCodes) === null || _a === void 0 ? void 0 : _a.includes('NTS-DBS-F1')) {
326
+ console.error(error);
327
+ return [];
328
+ }
329
+ else {
330
+ throw error;
331
+ }
332
+ });
333
+ if (!dontSetToService) {
334
+ this.dataList = dataListExists;
335
+ }
336
+ return dataListExists;
337
+ }
338
+ catch (error) {
339
+ throw new fsm_dynamo_1.Dynamo_Error({
340
+ status: 417,
341
+ errorCode: 'NTS-DS0-FDS0',
342
+ addECToUserMsg: true,
343
+ message: `findDatas was unsuccessful (${this.dataParams.dataName})`,
344
+ userMessage: this.defaultErrorUserMsg,
345
+ error: error
346
+ });
347
+ }
348
+ });
349
+ }
195
350
  /**
196
351
  * This function uses the dataDBService.updateOne function.
197
352
  * This uses updateBy if setted, or data._id if its setted or this.data[this.dependencyKey]
198
353
  * @param set
354
+ *
355
+ * // updateOne desc:
356
+ *
357
+ * Find the data first by any of its parameters, throws error if not found
358
+ * @param filter This uses the basic Mongoose updateOne.
359
+ * If you can, use unique parameters for find!
360
+ * @example
361
+ * // by email:
362
+ * { email: email }
363
+ * //
364
+ * @example
365
+ * // or by id that is in list:
366
+ * { userIds: { $in: this.userId } }
367
+ * //
368
+ * @example
369
+ * // or by number or Date that is Greater Than AND Less Than:
370
+ * { points: { $gt: 2, $lt: 14 } }
371
+ * // further tools (syntax matches with $gt):
372
+ * $eq: // Matches values that are EQual to a specified value.
373
+ * $gte: // Matches values that are Greater Than OR Equal to a specified value.
374
+ * $lte: // Matches values that are Less Than or Equal to a specified value.
375
+ * $ne: // Matches all values that are Not Equal to a specified value.
376
+ * $nin: // Matches None of the values specified IN an array.
377
+ * //
378
+ *
379
+ * @param update this uses the basic Mongoose updateOne
380
+ * @example
381
+ * // increase a specific value (here by 15):
382
+ * { $inc: { popularity: 15 } }
383
+ * //
384
+ * @example
385
+ * // or add element to a list:
386
+ * { $push: { reactions: this.newReaction }
387
+ * // or add multiple elements to a list
388
+ * { $push: { schedule: {$each: [ monday, tuesday, wednesday ] } } }
389
+ * //
390
+ * @example
391
+ * // or all at once
392
+ * {
393
+ * $inc: { popularity: this.newVote.amount },
394
+ * emailVerified: true,
395
+ * $push: { reactions: this.newReaction }
396
+ * }
397
+ * // further tools (syntax matches with $inc):
398
+ * $currentDate: // Sets the value of a field to current date, either as a Date or a Timestamp.
399
+ * $min: // Only updates the field if the specified value is less than the existing field value.
400
+ * $max: // Only updates the field if the specified value is greater than the existing field value.
401
+ * $mul: // Multiplies the value of the field by the specified amount.
402
+ * $rename: // Renames a field.
403
+ * $unset: // Removes the specified field from a document. (set: "" to value)
404
+ * //
199
405
  */
200
406
  updateData(set) {
201
407
  return tslib_1.__awaiter(this, void 0, void 0, function* () {
@@ -235,6 +441,7 @@ class DynamoNTS_DataService {
235
441
  * modifies data if the data have ID and already exists in the DB,
236
442
  * creates new if the ID is not present or cant find in DB,
237
443
  * and if dependency data setted up, will check before creation,
444
+ *
238
445
  * @warning
239
446
  * but the proper way to update data, if you use update method instead,
240
447
  * this way, you can avoid data override errors
@@ -246,7 +453,7 @@ class DynamoNTS_DataService {
246
453
  try {
247
454
  if (this.data._id) {
248
455
  // check if already exists
249
- let dataExists = yield this.getDataById(null, true).catch(() => null);
456
+ const dataExists = yield this.getDataById(null, true);
250
457
  if (dataExists) {
251
458
  // if data exists do modify
252
459
  this.data = yield this.dataDBService.modifyData(this.data, this.issuer);
@@ -263,7 +470,16 @@ class DynamoNTS_DataService {
263
470
  userMessage: this.defaultErrorUserMsg
264
471
  });
265
472
  }
266
- let dependencyExists = yield this.getDependencyDataDBService().getDataById(this.data[this.depKey]);
473
+ let dependencyExists = yield this.getDependencyDataDBService().getDataById(this.data[this.depKey]).catch(error => {
474
+ var _a;
475
+ if ((_a = error === null || error === void 0 ? void 0 : error.errorCodes) === null || _a === void 0 ? void 0 : _a.includes('NTS-DBS-GI1')) {
476
+ console.error(error);
477
+ return null;
478
+ }
479
+ else {
480
+ throw error;
481
+ }
482
+ });
267
483
  if (!dependencyExists) {
268
484
  throw new fsm_dynamo_1.Dynamo_Error({
269
485
  status: 417,
@@ -1 +1 @@
1
- {"version":3,"file":"dynamo-nts-data.service.js","s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AE;gBACtC,IAAI,CAAC,eAAe,GAAG,eAAe,CAAC,kBAAkB,CAAC;aAC3D;SACF;IACH,CAAC;IAED;;;OAGG;IACH,0BAA0B;QACxB,IAAI,CAAC,IAAI,CAAC,eAAe,EAAE;YACzB,MAAM,IAAI,yBAAY,CAAC;gBACrB,MAAM,EAAE,GAAG;gBACX,SAAS,EAAE,eAAe;gBAC1B,cAAc,EAAE,IAAI;gBACpB,OAAO,EAAE,yEAAyE;gBAClF,WAAW,EAAE,IAAI,CAAC,mBAAmB;aACtC,CAAC,CAAC;SACJ;QAED,IAAI,IAAI,CAAC,gBAAgB,EAAE;YACzB,OAAO,IAAI,CAAC,gBAAgB,CAAC;SAC9B;aAAM;YACL,IAAI,CAAC,gBAAgB,GAAG,mDAAuB,CAAC,iBAAiB,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;YACxF,OAAO,IAAI,CAAC,gBAAgB,CAAC;SAC9B;IACH,CAAC;CACF;AA3XD,sDA2XC"}
1
+ {"version":3,"file":"dynamo-nts-data.service.js","sourceRoot":"","sources":["../../src/_services/dynamo-nts-data.service.ts"],"names":[],"mappings":";;;;AACA,sDAA0H;AAG1H,2EAAsE;AAGtE;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAa,qBAAqB;IAehC,YACE,IAAO,EACP,UAAgC,EAChC,MAAc;QAfhB,aAAQ,GAAQ,EAAE,CAAC;QASnB,wBAAmB,GAAG,0FAA0F,CAAC;QACjH,kCAA6B,GAAG,gGAAgG,CAAC;QAO/H,IAAI,CAAC,aAAa,GAAG,mDAAuB,CAAC,YAAY,CAAI,UAAU,CAAC,CAAC;QACzE,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;QACjB,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;QAC7B,IAAI,CAAC,6BAA6B,EAAE,CAAC;QACrC,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IAED;;OAEG;IACG,MAAM;;YACV,IAAI;gBACF,IAAI,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Ae,CAAC,GAAG,CAAC;YAClC,IAAI,eAAe,CAAC,kBAAkB,EAAE;gBACtC,IAAI,CAAC,eAAe,GAAG,eAAe,CAAC,kBAAkB,CAAC;aAC3D;SACF;IACH,CAAC;IAED;;;OAGG;IACH,0BAA0B;QACxB,IAAI,CAAC,IAAI,CAAC,eAAe,EAAE;YACzB,MAAM,IAAI,yBAAY,CAAC;gBACrB,MAAM,EAAE,GAAG;gBACX,SAAS,EAAE,eAAe;gBAC1B,cAAc,EAAE,IAAI;gBACpB,OAAO,EAAE,yEAAyE;gBAClF,WAAW,EAAE,IAAI,CAAC,mBAAmB;aACtC,CAAC,CAAC;SACJ;QAED,IAAI,IAAI,CAAC,gBAAgB,EAAE;YACzB,OAAO,IAAI,CAAC,gBAAgB,CAAC;SAC9B;aAAM;YACL,IAAI,CAAC,gBAAgB,GAAG,mDAAuB,CAAC,iBAAiB,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;YACxF,OAAO,IAAI,CAAC,gBAAgB,CAAC;SAC9B;IACH,CAAC;CACF;AAhkBD,sDAgkBC"}
@@ -28,25 +28,32 @@ export declare class DynamoNTS_DBService<T extends Dynamo_Metadata> {
28
28
  */
29
29
  modifyData(data: T, modifier: string): Promise<T>;
30
30
  /**
31
- * returns data by _id, throws error if not found
31
+ * returns data by _id,
32
+ * !!!: throws error if not found (errorCode on not found: NTS-DBS-GI1)
32
33
  * @param id id
33
34
  * @returns data
34
35
  */
35
36
  getDataById(id: string): Promise<T>;
36
37
  /**
37
- * get data by dependency data id, throws error if not found
38
+ * get data by dependency data id,
39
+ * !!!: throws error if not found (errorCode on not found: NTS-DBS-GD2)
40
+ *
38
41
  * @param dependencyId id
39
42
  * @returns data
40
43
  */
41
44
  getDataByDependencyId(dependencyId: string): Promise<T>;
42
45
  /**
43
- * get data by dependency data id, throws error if not found
46
+ * get data by dependency data id,
47
+ * !!!: throws error if not found (errorCode on not found: NTS-DBS-GLD2)
48
+ *
44
49
  * @param dependencyId id
45
50
  * @returns dataList
46
51
  */
47
52
  getDataListByDependencyId(dependencyId: string): Promise<T[]>;
48
53
  /**
49
- * get multiple data objects by a list of DependencyIDs, throws error if not found
54
+ * get multiple data objects by a list of DependencyIDs,
55
+ * !!!: throws error if not found (errorCode on not found: NTS-DBS-GLDS2)
56
+ *
50
57
  * @param ids ids
51
58
  * @returns dataList
52
59
  */
@@ -54,13 +61,16 @@ export declare class DynamoNTS_DBService<T extends Dynamo_Metadata> {
54
61
  /**
55
62
  * returns search result for searchBy object params
56
63
  * can use lists or xRange values for searchBy obj properties
64
+ *
57
65
  * @param searchBy filter
58
66
  * @param narrowByDependencyIds id
59
67
  * @returns dataList
60
68
  */
61
69
  searchData(searchBy: object, narrowByDependencyIds?: string[]): Promise<T[]>;
62
70
  /**
63
- * returns all data from database, throws error if not found
71
+ * returns all data from database,
72
+ * !!!: throws error if not found (errorCode on not found: NTS-DBS-GA1)
73
+ *
64
74
  * @returns dataList
65
75
  */
66
76
  getAll(): Promise<T[]>;
@@ -75,7 +85,9 @@ export declare class DynamoNTS_DBService<T extends Dynamo_Metadata> {
75
85
  */
76
86
  deleteDataByDependencyId(dependencyId: string): Promise<void>;
77
87
  /**
78
- * Find the data first by any of its parameters, throws error if not found
88
+ * Find the data first by any of its parameters,
89
+ * !!!: throws error if not found (errorCode on not found: NTS-DBS-FO1)
90
+ *
79
91
  * @param filter if you can, use unique parameters for find!
80
92
  *
81
93
  * @example
@@ -101,7 +113,9 @@ export declare class DynamoNTS_DBService<T extends Dynamo_Metadata> {
101
113
  findOne(filter: any): Promise<T>;
102
114
  /**
103
115
  * #MONGOOSE FUNCTION
104
- * Find the data first by any of its parameters, throws error if not found
116
+ * Find the data first by any of its parameters,
117
+ * !!!: throws error if not found (errorCode on not found: NTS-DBS-F1)
118
+ *
105
119
  * @param filter if you can, use unique parameters for find!
106
120
  *
107
121
  * @example
@@ -127,7 +141,8 @@ export declare class DynamoNTS_DBService<T extends Dynamo_Metadata> {
127
141
  find(filter: any): Promise<T[]>;
128
142
  /**
129
143
  * #MONGOOSE FUNCTION
130
- * Find the data first by any of its parameters, throws error if not found
144
+ * Find the data first by any of its parameters
145
+ *
131
146
  * @param filter if you can, use unique parameters for find!
132
147
  *
133
148
  * @example
@@ -161,6 +176,8 @@ export declare class DynamoNTS_DBService<T extends Dynamo_Metadata> {
161
176
  /**
162
177
  * #MONGOOSE FUNCTION
163
178
  * Find data by _id and update
179
+ * !!!: throws error if not found (errorCode on not found: )
180
+ *
164
181
  * @param id id
165
182
  * @param update update
166
183
  * @returns data
@@ -168,7 +185,8 @@ export declare class DynamoNTS_DBService<T extends Dynamo_Metadata> {
168
185
  findByIdAndUpdate(id: string, update: any, modifier: string): Promise<T>;
169
186
  /**
170
187
  * #MONGOOSE FUNCTION
171
- * Find the data first by any of its parameters, throws error if not found
188
+ * Find the data first by any of its parameters
189
+ *
172
190
  * @param filter This uses the basic Mongoose updateOne.
173
191
  * If you can, use unique parameters for find!
174
192
  * @example
@@ -221,6 +239,7 @@ export declare class DynamoNTS_DBService<T extends Dynamo_Metadata> {
221
239
  /**
222
240
  * #MONGOOSE FUNCTION
223
241
  * update one parameter by a specific
242
+ *
224
243
  * @param filter This uses the basic Mongoose updateMany.
225
244
  * @example
226
245
  * // by email:
@@ -1 +1 @@
1
- {"version":3,"file":"dynamo-nts-db.service.d.ts","sourceRoot":"","sources":["../../src/_services/dynamo-nts-db.service.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,QAAQ,MAAM,UAAU,CAAC;AAErC,OAAO,EAAE,eAAe,EAAE,oBAAoB,EAA8C,MAAM,uBAAuB,CAAC;AAE1H;;GAEG;AACH,qBAAa,mBAAmB,CAAC,CAAC,SAAS,eAAe;IAc/C,UAAU,EAAE,oBAAoB;IAbzC,SAAS,6DAA4D;IAErE,OAAO,CAAC,WAAW,CAAS;IAE5B,mBAAmB,SAA2F;IAE9G;;;;;OAKG;gBAEM,UAAU,EAAE,oBAAoB;IAKzC;;;;OAIG;IACG,UAAU,CAAC,I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