@qrvey/utils 1.1.4 → 1.1.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +693 -665
- package/dist/cjs/filters/adapters/FDToFlatUI.js +2 -1
- package/dist/cjs/filters/adapters/FDToUI.js +2 -1
- package/dist/cjs/filters/adapters/UIToFlatUI.js +2 -1
- package/dist/cjs/filters/adapters/UIToOldLogic.js +2 -1
- package/dist/cjs/filters/adapters/adaptFilterValues.d.ts +8 -0
- package/dist/cjs/filters/adapters/adaptFilterValues.js +18 -0
- package/dist/cjs/filters/adapters/flatUIToFD.js +2 -1
- package/dist/cjs/filters/adapters/flatUIToUI.js +2 -1
- package/dist/cjs/filters/adapters/logicToFlatUI.js +0 -3
- package/dist/cjs/filters/helpers/common/getFilterColumnLabel.js +1 -1
- package/dist/cjs/filters/helpers/common/getFiltersByParams.js +1 -1
- package/dist/cjs/filters/helpers/common/mergeFilters.js +12 -12
- package/dist/cjs/filters/interfaces/common/IFSValueRelativeDate.d.ts +1 -1
- package/dist/cjs/qrvey/getPropertyLabel.js +1 -1
- package/dist/filters/adapters/FDToFlatUI.js +2 -1
- package/dist/filters/adapters/FDToUI.js +2 -1
- package/dist/filters/adapters/UIToFlatUI.js +2 -1
- package/dist/filters/adapters/UIToOldLogic.js +2 -1
- package/dist/filters/adapters/adaptFilterValues.d.ts +8 -0
- package/dist/filters/adapters/adaptFilterValues.js +14 -0
- package/dist/filters/adapters/flatUIToFD.js +2 -1
- package/dist/filters/adapters/flatUIToUI.js +2 -1
- package/dist/filters/adapters/logicToFlatUI.js +0 -3
- package/dist/filters/helpers/common/getFilterColumnLabel.js +2 -2
- package/dist/filters/helpers/common/getFiltersByParams.js +1 -1
- package/dist/filters/helpers/common/mergeFilters.js +12 -12
- package/dist/filters/interfaces/common/IFSValueRelativeDate.d.ts +1 -1
- package/dist/qrvey/getPropertyLabel.js +1 -1
- package/package.json +1 -1
- package/src/filters/adapters/FDToFlatUI.ts +2 -1
- package/src/filters/adapters/FDToUI.ts +2 -0
- package/src/filters/adapters/UIToFlatUI.ts +2 -1
- package/src/filters/adapters/UIToOldLogic.ts +2 -1
- package/src/filters/adapters/adaptFilterValues.ts +17 -0
- package/src/filters/adapters/flatUIToFD.ts +2 -1
- package/src/filters/adapters/flatUIToUI.ts +2 -1
- package/src/filters/adapters/logicToFlatUI.ts +0 -3
- package/src/filters/helpers/common/getFilterColumnLabel.ts +2 -2
- package/src/filters/helpers/common/getFiltersByParams.ts +1 -1
- package/src/filters/helpers/common/mergeFilters.ts +12 -12
- package/src/filters/interfaces/common/IFSValueRelativeDate.ts +1 -1
- package/src/qrvey/getPropertyLabel.ts +1 -1
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# [@qrvey/utils](https://bitbucket.org/qrvey/qrvey_utils/wiki/Home) *1.1.
|
|
1
|
+
# [@qrvey/utils](https://bitbucket.org/qrvey/qrvey_utils/wiki/Home) *1.1.8*
|
|
2
2
|
|
|
3
3
|
> Helper, Utils for all Qrvey Projects
|
|
4
4
|
|
|
@@ -107,12 +107,12 @@ Get a text and evaluate if it matchs with a token box label.
|
|
|
107
107
|
|
|
108
108
|
|
|
109
109
|
|
|
110
|
-
### dist/
|
|
110
|
+
### dist/date/range/getDateRange.js
|
|
111
111
|
|
|
112
112
|
|
|
113
|
-
####
|
|
113
|
+
#### getDateRange(value, dateGroupLabel, withTime)
|
|
114
114
|
|
|
115
|
-
|
|
115
|
+
Get date range object from a string date value
|
|
116
116
|
|
|
117
117
|
|
|
118
118
|
|
|
@@ -121,32 +121,58 @@ Generates a Flattened UI filter structure from Filter Data structure.
|
|
|
121
121
|
|
|
122
122
|
| Name | Type | Description | |
|
|
123
123
|
| ---- | ---- | ----------- | -------- |
|
|
124
|
-
|
|
|
125
|
-
|
|
|
124
|
+
| value | `String` | string date value | |
|
|
125
|
+
| dateGroupLabel | `String` | could be 'YEAR', 'QUARTER', 'MONTH' or 'DAY'. Deafult is 'DAY' | |
|
|
126
|
+
| withTime | `Boolean` | determines if the date range will include time. Default is true | |
|
|
127
|
+
|
|
128
|
+
|
|
129
|
+
|
|
130
|
+
|
|
131
|
+
##### Examples
|
|
126
132
|
|
|
133
|
+
```javascript
|
|
134
|
+
// 1) Year:
|
|
135
|
+
getDateRange('2020', 'YEAR');
|
|
136
|
+
// Will return:
|
|
137
|
+
{
|
|
138
|
+
from: '01/01/2020 00:00:00',
|
|
139
|
+
to: '12/31/2020 23:59:59'
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
// 2) Quarter:
|
|
143
|
+
getDateRange('Q3 2020', 'QUARTER');
|
|
144
|
+
// Will return:
|
|
145
|
+
{
|
|
146
|
+
from: '07/01/2020 00:00:00',
|
|
147
|
+
to: '09/30/2020 23:59:59'
|
|
148
|
+
}
|
|
127
149
|
|
|
150
|
+
// 3) Month:
|
|
151
|
+
getDateRange('Oct 2020', 'MONTH');
|
|
152
|
+
// Will return:
|
|
153
|
+
{
|
|
154
|
+
from: '10/01/2020 00:00:00',
|
|
155
|
+
to: '10/31/2020 23:59:59'
|
|
156
|
+
}
|
|
157
|
+
```
|
|
128
158
|
|
|
129
159
|
|
|
130
160
|
##### Returns
|
|
131
161
|
|
|
132
162
|
|
|
133
|
-
-
|
|
163
|
+
- `Object` an object with the date range with two string date properties: from and to
|
|
134
164
|
|
|
135
165
|
|
|
136
166
|
|
|
137
|
-
#### FD21ToFlatUI(scopes, datasetsInfo)
|
|
138
167
|
|
|
139
|
-
|
|
168
|
+
### dist/date/relative/Adapter.js
|
|
140
169
|
|
|
141
170
|
|
|
171
|
+
#### value()
|
|
142
172
|
|
|
173
|
+
Resolves statement and returns statement value
|
|
143
174
|
|
|
144
|
-
##### Parameters
|
|
145
175
|
|
|
146
|
-
| Name | Type | Description | |
|
|
147
|
-
| ---- | ---- | ----------- | -------- |
|
|
148
|
-
| scopes | | The filter scope section | |
|
|
149
|
-
| datasetsInfo | | Collection of datasets information | |
|
|
150
176
|
|
|
151
177
|
|
|
152
178
|
|
|
@@ -154,49 +180,47 @@ Generates a Filter Builder Structure from the Filter Data structure v2.1
|
|
|
154
180
|
##### Returns
|
|
155
181
|
|
|
156
182
|
|
|
157
|
-
-
|
|
183
|
+
- `AbsoluteRange` `string`
|
|
158
184
|
|
|
159
185
|
|
|
160
186
|
|
|
187
|
+
#### valueAsAnchor()
|
|
161
188
|
|
|
162
|
-
|
|
189
|
+
Resolves statement as an anchor
|
|
163
190
|
|
|
164
191
|
|
|
165
|
-
#### FDToLogic(filterData)
|
|
166
192
|
|
|
167
|
-
Generates a Filter Logic structure from Filter Data structure.
|
|
168
193
|
|
|
169
194
|
|
|
170
195
|
|
|
196
|
+
##### Returns
|
|
171
197
|
|
|
172
|
-
##### Parameters
|
|
173
198
|
|
|
174
|
-
|
|
175
|
-
| ---- | ---- | ----------- | -------- |
|
|
176
|
-
| filterData | | The filter data object. | |
|
|
199
|
+
- `string`
|
|
177
200
|
|
|
178
201
|
|
|
179
202
|
|
|
203
|
+
#### _statementToRange() *private method*
|
|
180
204
|
|
|
181
|
-
|
|
205
|
+
Convert verbal statement to range value
|
|
182
206
|
|
|
183
207
|
|
|
184
|
-
- a filter logic array
|
|
185
208
|
|
|
186
209
|
|
|
187
210
|
|
|
188
|
-
#### getLogicBodyFromFD21(filterData)
|
|
189
211
|
|
|
190
|
-
|
|
212
|
+
##### Returns
|
|
191
213
|
|
|
192
214
|
|
|
215
|
+
- `AbsoluteRange`
|
|
193
216
|
|
|
194
217
|
|
|
195
|
-
##### Parameters
|
|
196
218
|
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
219
|
+
#### _resolveAsThis() *private method*
|
|
220
|
+
|
|
221
|
+
Apply 'this' cursor logic to statement
|
|
222
|
+
|
|
223
|
+
|
|
200
224
|
|
|
201
225
|
|
|
202
226
|
|
|
@@ -204,27 +228,31 @@ Gets the logic body
|
|
|
204
228
|
##### Returns
|
|
205
229
|
|
|
206
230
|
|
|
207
|
-
-
|
|
231
|
+
- `AbsoluteStatement`
|
|
208
232
|
|
|
209
233
|
|
|
210
234
|
|
|
235
|
+
#### _resolveAsTheLast() *private method*
|
|
211
236
|
|
|
212
|
-
|
|
237
|
+
Apply 'the last' cursor logic to statement
|
|
213
238
|
|
|
214
239
|
|
|
215
|
-
#### FDToUI(filterData, datasetsInfo)
|
|
216
240
|
|
|
217
|
-
Generates a UI filter structure from Filter Data structure.
|
|
218
241
|
|
|
219
242
|
|
|
220
243
|
|
|
244
|
+
##### Returns
|
|
245
|
+
|
|
246
|
+
|
|
247
|
+
- `AbsoluteStatement`
|
|
248
|
+
|
|
249
|
+
|
|
250
|
+
|
|
251
|
+
#### _resolveAsTheNext() *private method*
|
|
252
|
+
|
|
253
|
+
Apply 'the next' cursor logic to statement
|
|
221
254
|
|
|
222
|
-
##### Parameters
|
|
223
255
|
|
|
224
|
-
| Name | Type | Description | |
|
|
225
|
-
| ---- | ---- | ----------- | -------- |
|
|
226
|
-
| filterData | | The filter data object. | |
|
|
227
|
-
| datasetsInfo | | Collection of datasets information | |
|
|
228
256
|
|
|
229
257
|
|
|
230
258
|
|
|
@@ -232,13 +260,13 @@ Generates a UI filter structure from Filter Data structure.
|
|
|
232
260
|
##### Returns
|
|
233
261
|
|
|
234
262
|
|
|
235
|
-
-
|
|
263
|
+
- `AbsoluteStatement`
|
|
236
264
|
|
|
237
265
|
|
|
238
266
|
|
|
239
|
-
####
|
|
267
|
+
#### replaceNowToken(value, now)
|
|
240
268
|
|
|
241
|
-
|
|
269
|
+
Replace '@now' token inside a string
|
|
242
270
|
|
|
243
271
|
|
|
244
272
|
|
|
@@ -247,10 +275,8 @@ Generates a UI filter Structure from the Filter Data structure v2.1
|
|
|
247
275
|
|
|
248
276
|
| Name | Type | Description | |
|
|
249
277
|
| ---- | ---- | ----------- | -------- |
|
|
250
|
-
|
|
|
251
|
-
|
|
|
252
|
-
| version | | The version of the filter structure | |
|
|
253
|
-
| datasetsInfo | | Collection of datasets information | |
|
|
278
|
+
| value | `string` | | |
|
|
279
|
+
| now | `Date` | | |
|
|
254
280
|
|
|
255
281
|
|
|
256
282
|
|
|
@@ -258,17 +284,13 @@ Generates a UI filter Structure from the Filter Data structure v2.1
|
|
|
258
284
|
##### Returns
|
|
259
285
|
|
|
260
286
|
|
|
261
|
-
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
287
|
+
- `string`
|
|
265
288
|
|
|
266
|
-
### dist/filters/adapters/UIToFD.js
|
|
267
289
|
|
|
268
290
|
|
|
269
|
-
####
|
|
291
|
+
#### convertRelativeToAbsolute(args)
|
|
270
292
|
|
|
271
|
-
|
|
293
|
+
Returns a range object (date) from a group of statement params
|
|
272
294
|
|
|
273
295
|
|
|
274
296
|
|
|
@@ -277,21 +299,45 @@ Generates a Filter Data Structure structure from UI Filter Data structure.
|
|
|
277
299
|
|
|
278
300
|
| Name | Type | Description | |
|
|
279
301
|
| ---- | ---- | ----------- | -------- |
|
|
280
|
-
|
|
|
302
|
+
| args | `RelativeToAbsoluteStruct` | | |
|
|
281
303
|
|
|
282
304
|
|
|
283
305
|
|
|
284
306
|
|
|
307
|
+
##### Examples
|
|
308
|
+
|
|
309
|
+
```javascript
|
|
310
|
+
pivot = '2021-03-03T12:30:40'
|
|
311
|
+
unit = month
|
|
312
|
+
steps = 2
|
|
313
|
+
setTo = END
|
|
314
|
+
resolverAsCalendar: true
|
|
315
|
+
=> Returns '2021-05-31T23:59:59'
|
|
316
|
+
```
|
|
317
|
+
```javascript
|
|
318
|
+
pivot = '2021-03-03T12:30:40'
|
|
319
|
+
unit = month
|
|
320
|
+
steps = -2
|
|
321
|
+
setTo = START
|
|
322
|
+
resolverAsCalendar: false
|
|
323
|
+
=> Returns '2021-01-03T00:00:00'
|
|
324
|
+
```
|
|
325
|
+
|
|
326
|
+
|
|
285
327
|
##### Returns
|
|
286
328
|
|
|
287
329
|
|
|
288
|
-
-
|
|
330
|
+
- `string`
|
|
289
331
|
|
|
290
332
|
|
|
291
333
|
|
|
292
|
-
#### UI21ToFD(uFilterData, version)
|
|
293
334
|
|
|
294
|
-
|
|
335
|
+
### dist/date/relative/relative.js
|
|
336
|
+
|
|
337
|
+
|
|
338
|
+
#### resolveRelative(statements, clock)
|
|
339
|
+
|
|
340
|
+
Resolve a list of relative statements according to operator
|
|
295
341
|
|
|
296
342
|
|
|
297
343
|
|
|
@@ -300,26 +346,44 @@ Builds the Fitler Data structure from UI filter data
|
|
|
300
346
|
|
|
301
347
|
| Name | Type | Description | |
|
|
302
348
|
| ---- | ---- | ----------- | -------- |
|
|
303
|
-
|
|
|
304
|
-
|
|
|
349
|
+
| statements | `Array.<RelativeStatement>` `Array.<string>` | - Raw statements/values | |
|
|
350
|
+
| clock | `Date` | - Clock/time reference for relative date resolution | |
|
|
351
|
+
|
|
352
|
+
|
|
305
353
|
|
|
306
354
|
|
|
355
|
+
##### Examples
|
|
356
|
+
|
|
357
|
+
```javascript
|
|
358
|
+
Input:
|
|
359
|
+
{
|
|
360
|
+
"cursor": "the_next",
|
|
361
|
+
"unit": "year",
|
|
362
|
+
"number": 1,
|
|
363
|
+
"includeCurrent": false,
|
|
364
|
+
"isCalendarDate": false,
|
|
365
|
+
"anchor": "03/05/2021"
|
|
366
|
+
}
|
|
367
|
+
|
|
368
|
+
Output:
|
|
369
|
+
{ gte: "03/06/2021 00:00:00", lte: "03/05/2022 23:59:59" }
|
|
370
|
+
```
|
|
307
371
|
|
|
308
372
|
|
|
309
373
|
##### Returns
|
|
310
374
|
|
|
311
375
|
|
|
312
|
-
-
|
|
376
|
+
- `Array.<AbsoluteRange>` `Array.<string>`
|
|
313
377
|
|
|
314
378
|
|
|
315
379
|
|
|
316
380
|
|
|
317
|
-
### dist/filters/adapters/
|
|
381
|
+
### dist/filters/adapters/FDToFlatUI.js
|
|
318
382
|
|
|
319
383
|
|
|
320
|
-
####
|
|
384
|
+
#### FDToFlatUI(filterData, datasetsInfo)
|
|
321
385
|
|
|
322
|
-
Generates a Flattened UI filter structure from
|
|
386
|
+
Generates a Flattened UI filter structure from Filter Data structure.
|
|
323
387
|
|
|
324
388
|
|
|
325
389
|
|
|
@@ -328,8 +392,8 @@ Generates a Flattened UI filter structure from UI Filter Data structure.
|
|
|
328
392
|
|
|
329
393
|
| Name | Type | Description | |
|
|
330
394
|
| ---- | ---- | ----------- | -------- |
|
|
331
|
-
| filterData | | The
|
|
332
|
-
| datasetsInfo | | Collection of datasets information
|
|
395
|
+
| filterData | | The filter data object. | |
|
|
396
|
+
| datasetsInfo | | Collection of datasets information | |
|
|
333
397
|
|
|
334
398
|
|
|
335
399
|
|
|
@@ -341,9 +405,9 @@ Generates a Flattened UI filter structure from UI Filter Data structure.
|
|
|
341
405
|
|
|
342
406
|
|
|
343
407
|
|
|
344
|
-
####
|
|
408
|
+
#### FD21ToFlatUI(scopes, datasetsInfo)
|
|
345
409
|
|
|
346
|
-
Generates a
|
|
410
|
+
Generates a Filter Builder Structure from the Filter Data structure v2.1
|
|
347
411
|
|
|
348
412
|
|
|
349
413
|
|
|
@@ -353,6 +417,7 @@ Generates a Flattened UI Filter Structure from the UI Filter Data structure v2.1
|
|
|
353
417
|
| Name | Type | Description | |
|
|
354
418
|
| ---- | ---- | ----------- | -------- |
|
|
355
419
|
| scopes | | The filter scope section | |
|
|
420
|
+
| datasetsInfo | | Collection of datasets information | |
|
|
356
421
|
|
|
357
422
|
|
|
358
423
|
|
|
@@ -365,13 +430,12 @@ Generates a Flattened UI Filter Structure from the UI Filter Data structure v2.1
|
|
|
365
430
|
|
|
366
431
|
|
|
367
432
|
|
|
368
|
-
### dist/filters/adapters/
|
|
433
|
+
### dist/filters/adapters/FDToLogic.js
|
|
369
434
|
|
|
370
435
|
|
|
371
|
-
####
|
|
436
|
+
#### FDToLogic(filterData)
|
|
372
437
|
|
|
373
|
-
|
|
374
|
-
Get the new property base on the old date grouping properties
|
|
438
|
+
Generates a Filter Logic structure from Filter Data structure.
|
|
375
439
|
|
|
376
440
|
|
|
377
441
|
|
|
@@ -380,7 +444,7 @@ Get the new property base on the old date grouping properties
|
|
|
380
444
|
|
|
381
445
|
| Name | Type | Description | |
|
|
382
446
|
| ---- | ---- | ----------- | -------- |
|
|
383
|
-
|
|
|
447
|
+
| filterData | | The filter data object. | |
|
|
384
448
|
|
|
385
449
|
|
|
386
450
|
|
|
@@ -388,17 +452,13 @@ Get the new property base on the old date grouping properties
|
|
|
388
452
|
##### Returns
|
|
389
453
|
|
|
390
454
|
|
|
391
|
-
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
455
|
+
- a filter logic array
|
|
395
456
|
|
|
396
|
-
### dist/filters/adapters/adaptFilterData.js
|
|
397
457
|
|
|
398
458
|
|
|
399
|
-
####
|
|
459
|
+
#### getLogicBodyFromFD21(filterData)
|
|
400
460
|
|
|
401
|
-
|
|
461
|
+
Gets the logic body
|
|
402
462
|
|
|
403
463
|
|
|
404
464
|
|
|
@@ -407,9 +467,7 @@ Checks and adapts the v2.0 Filter Data Structure to the v2.1
|
|
|
407
467
|
|
|
408
468
|
| Name | Type | Description | |
|
|
409
469
|
| ---- | ---- | ----------- | -------- |
|
|
410
|
-
| filterData | | The filter data
|
|
411
|
-
| getUIFilterData | | Flag to get a Filter Data (False) or the UI Filter Data (True) | |
|
|
412
|
-
| datasetsInfo | | Collection of datasets information. If getUIFilterData is true, the datasetsInfo should be mandatory | |
|
|
470
|
+
| filterData | | The filter data object | |
|
|
413
471
|
|
|
414
472
|
|
|
415
473
|
|
|
@@ -417,17 +475,17 @@ Checks and adapts the v2.0 Filter Data Structure to the v2.1
|
|
|
417
475
|
##### Returns
|
|
418
476
|
|
|
419
477
|
|
|
420
|
-
-
|
|
478
|
+
- a filter logic array
|
|
421
479
|
|
|
422
480
|
|
|
423
481
|
|
|
424
482
|
|
|
425
|
-
### dist/filters/adapters/
|
|
483
|
+
### dist/filters/adapters/FDToUI.js
|
|
426
484
|
|
|
427
485
|
|
|
428
|
-
####
|
|
486
|
+
#### FDToUI(filterData, datasetsInfo)
|
|
429
487
|
|
|
430
|
-
Generates a filter
|
|
488
|
+
Generates a UI filter structure from Filter Data structure.
|
|
431
489
|
|
|
432
490
|
|
|
433
491
|
|
|
@@ -436,8 +494,8 @@ Generates a filter data structure from the flatttened UI filters.
|
|
|
436
494
|
|
|
437
495
|
| Name | Type | Description | |
|
|
438
496
|
| ---- | ---- | ----------- | -------- |
|
|
439
|
-
|
|
|
440
|
-
|
|
|
497
|
+
| filterData | | The filter data object. | |
|
|
498
|
+
| datasetsInfo | | Collection of datasets information | |
|
|
441
499
|
|
|
442
500
|
|
|
443
501
|
|
|
@@ -445,14 +503,13 @@ Generates a filter data structure from the flatttened UI filters.
|
|
|
445
503
|
##### Returns
|
|
446
504
|
|
|
447
505
|
|
|
448
|
-
- a
|
|
506
|
+
- a UI Filters structure
|
|
449
507
|
|
|
450
508
|
|
|
451
509
|
|
|
452
|
-
####
|
|
510
|
+
#### FD21ToUI(scopes, section, version, datasetsInfo)
|
|
453
511
|
|
|
454
|
-
|
|
455
|
-
Also, adds and organizes filters by datasets
|
|
512
|
+
Generates a UI filter Structure from the Filter Data structure v2.1
|
|
456
513
|
|
|
457
514
|
|
|
458
515
|
|
|
@@ -461,7 +518,10 @@ Also, adds and organizes filters by datasets
|
|
|
461
518
|
|
|
462
519
|
| Name | Type | Description | |
|
|
463
520
|
| ---- | ---- | ----------- | -------- |
|
|
464
|
-
|
|
|
521
|
+
| scopes | | The filter scope section | |
|
|
522
|
+
| section | | The filter section. | |
|
|
523
|
+
| version | | The version of the filter structure | |
|
|
524
|
+
| datasetsInfo | | Collection of datasets information | |
|
|
465
525
|
|
|
466
526
|
|
|
467
527
|
|
|
@@ -469,13 +529,17 @@ Also, adds and organizes filters by datasets
|
|
|
469
529
|
##### Returns
|
|
470
530
|
|
|
471
531
|
|
|
472
|
-
-
|
|
532
|
+
- a UI filter Structure
|
|
473
533
|
|
|
474
534
|
|
|
475
535
|
|
|
476
|
-
#### buildScope(uFilter)
|
|
477
536
|
|
|
478
|
-
|
|
537
|
+
### dist/filters/adapters/UIToFD.js
|
|
538
|
+
|
|
539
|
+
|
|
540
|
+
#### UIToFD(filterData)
|
|
541
|
+
|
|
542
|
+
Generates a Filter Data Structure structure from UI Filter Data structure.
|
|
479
543
|
|
|
480
544
|
|
|
481
545
|
|
|
@@ -484,7 +548,242 @@ Gets an scope structure for the filter data
|
|
|
484
548
|
|
|
485
549
|
| Name | Type | Description | |
|
|
486
550
|
| ---- | ---- | ----------- | -------- |
|
|
487
|
-
|
|
|
551
|
+
| filterData | | The UI filter data object. | |
|
|
552
|
+
|
|
553
|
+
|
|
554
|
+
|
|
555
|
+
|
|
556
|
+
##### Returns
|
|
557
|
+
|
|
558
|
+
|
|
559
|
+
- a Filter Data structure
|
|
560
|
+
|
|
561
|
+
|
|
562
|
+
|
|
563
|
+
#### UI21ToFD(uFilterData, version)
|
|
564
|
+
|
|
565
|
+
Builds the Fitler Data structure from UI filter data
|
|
566
|
+
|
|
567
|
+
|
|
568
|
+
|
|
569
|
+
|
|
570
|
+
##### Parameters
|
|
571
|
+
|
|
572
|
+
| Name | Type | Description | |
|
|
573
|
+
| ---- | ---- | ----------- | -------- |
|
|
574
|
+
| uFilterData | | The UI filter Data object | |
|
|
575
|
+
| version | | the version of the structure | |
|
|
576
|
+
|
|
577
|
+
|
|
578
|
+
|
|
579
|
+
|
|
580
|
+
##### Returns
|
|
581
|
+
|
|
582
|
+
|
|
583
|
+
-
|
|
584
|
+
|
|
585
|
+
|
|
586
|
+
|
|
587
|
+
|
|
588
|
+
### dist/filters/adapters/UIToFlatUI.js
|
|
589
|
+
|
|
590
|
+
|
|
591
|
+
#### UIToFlatUI(filterData, datasetsInfo)
|
|
592
|
+
|
|
593
|
+
Generates a Flattened UI filter structure from UI Filter Data structure.
|
|
594
|
+
|
|
595
|
+
|
|
596
|
+
|
|
597
|
+
|
|
598
|
+
##### Parameters
|
|
599
|
+
|
|
600
|
+
| Name | Type | Description | |
|
|
601
|
+
| ---- | ---- | ----------- | -------- |
|
|
602
|
+
| filterData | | The UI filter data object. | |
|
|
603
|
+
| datasetsInfo | | Collection of datasets information. Optional for updating the datasets info | |
|
|
604
|
+
|
|
605
|
+
|
|
606
|
+
|
|
607
|
+
|
|
608
|
+
##### Returns
|
|
609
|
+
|
|
610
|
+
|
|
611
|
+
- a flattened UI filters array
|
|
612
|
+
|
|
613
|
+
|
|
614
|
+
|
|
615
|
+
#### UI21ToFlatUI(scopes)
|
|
616
|
+
|
|
617
|
+
Generates a Flattened UI Filter Structure from the UI Filter Data structure v2.1
|
|
618
|
+
|
|
619
|
+
|
|
620
|
+
|
|
621
|
+
|
|
622
|
+
##### Parameters
|
|
623
|
+
|
|
624
|
+
| Name | Type | Description | |
|
|
625
|
+
| ---- | ---- | ----------- | -------- |
|
|
626
|
+
| scopes | | The filter scope section | |
|
|
627
|
+
|
|
628
|
+
|
|
629
|
+
|
|
630
|
+
|
|
631
|
+
##### Returns
|
|
632
|
+
|
|
633
|
+
|
|
634
|
+
- a flattened UI filters array
|
|
635
|
+
|
|
636
|
+
|
|
637
|
+
|
|
638
|
+
|
|
639
|
+
### dist/filters/adapters/adaptDateGroupingProperty.js
|
|
640
|
+
|
|
641
|
+
|
|
642
|
+
#### adaptDateGroupingProperty(property)
|
|
643
|
+
|
|
644
|
+
[TODO: For 2022, eliminate this adapter]
|
|
645
|
+
Get the new property base on the old date grouping properties
|
|
646
|
+
|
|
647
|
+
|
|
648
|
+
|
|
649
|
+
|
|
650
|
+
##### Parameters
|
|
651
|
+
|
|
652
|
+
| Name | Type | Description | |
|
|
653
|
+
| ---- | ---- | ----------- | -------- |
|
|
654
|
+
| property | | | |
|
|
655
|
+
|
|
656
|
+
|
|
657
|
+
|
|
658
|
+
|
|
659
|
+
##### Returns
|
|
660
|
+
|
|
661
|
+
|
|
662
|
+
-
|
|
663
|
+
|
|
664
|
+
|
|
665
|
+
|
|
666
|
+
|
|
667
|
+
### dist/filters/adapters/adaptFilterData.js
|
|
668
|
+
|
|
669
|
+
|
|
670
|
+
#### adaptFilterData(filterData, getUIFilterData, datasetsInfo)
|
|
671
|
+
|
|
672
|
+
Checks and adapts the v2.0 Filter Data Structure to the v2.1
|
|
673
|
+
|
|
674
|
+
|
|
675
|
+
|
|
676
|
+
|
|
677
|
+
##### Parameters
|
|
678
|
+
|
|
679
|
+
| Name | Type | Description | |
|
|
680
|
+
| ---- | ---- | ----------- | -------- |
|
|
681
|
+
| filterData | | The filter data structure. Accepts both v2.1 or v2.0 | |
|
|
682
|
+
| getUIFilterData | | Flag to get a Filter Data (False) or the UI Filter Data (True) | |
|
|
683
|
+
| datasetsInfo | | Collection of datasets information. If getUIFilterData is true, the datasetsInfo should be mandatory | |
|
|
684
|
+
|
|
685
|
+
|
|
686
|
+
|
|
687
|
+
|
|
688
|
+
##### Returns
|
|
689
|
+
|
|
690
|
+
|
|
691
|
+
- A new filter data structure v2.1
|
|
692
|
+
|
|
693
|
+
|
|
694
|
+
|
|
695
|
+
|
|
696
|
+
### dist/filters/adapters/adaptFilterValues.js
|
|
697
|
+
|
|
698
|
+
|
|
699
|
+
#### adaptFilterValues(filter)
|
|
700
|
+
|
|
701
|
+
[TODO: For 2022, eliminate this adapter]
|
|
702
|
+
Gets an adapted filter value array. Validates the enabled property and sets
|
|
703
|
+
|
|
704
|
+
|
|
705
|
+
|
|
706
|
+
|
|
707
|
+
##### Parameters
|
|
708
|
+
|
|
709
|
+
| Name | Type | Description | |
|
|
710
|
+
| ---- | ---- | ----------- | -------- |
|
|
711
|
+
| filter | | The filter | |
|
|
712
|
+
|
|
713
|
+
|
|
714
|
+
|
|
715
|
+
|
|
716
|
+
##### Returns
|
|
717
|
+
|
|
718
|
+
|
|
719
|
+
- A new value array with the filled properties.
|
|
720
|
+
|
|
721
|
+
|
|
722
|
+
|
|
723
|
+
|
|
724
|
+
### dist/filters/adapters/flatUIToFD.js
|
|
725
|
+
|
|
726
|
+
|
|
727
|
+
#### flatUIToFD(uFilters, version)
|
|
728
|
+
|
|
729
|
+
Generates a filter data structure from the flatttened UI filters.
|
|
730
|
+
|
|
731
|
+
|
|
732
|
+
|
|
733
|
+
|
|
734
|
+
##### Parameters
|
|
735
|
+
|
|
736
|
+
| Name | Type | Description | |
|
|
737
|
+
| ---- | ---- | ----------- | -------- |
|
|
738
|
+
| uFilters | | Array of flattened filters from UI | |
|
|
739
|
+
| version | | Tag for the version of the filter data structure | |
|
|
740
|
+
|
|
741
|
+
|
|
742
|
+
|
|
743
|
+
|
|
744
|
+
##### Returns
|
|
745
|
+
|
|
746
|
+
|
|
747
|
+
- a Filter Data.
|
|
748
|
+
|
|
749
|
+
|
|
750
|
+
|
|
751
|
+
#### buildScopes(fbFilters)
|
|
752
|
+
|
|
753
|
+
Gets an array of scopes structure for the filter data. The scopes is organized by scope types and scope IDs
|
|
754
|
+
Also, adds and organizes filters by datasets
|
|
755
|
+
|
|
756
|
+
|
|
757
|
+
|
|
758
|
+
|
|
759
|
+
##### Parameters
|
|
760
|
+
|
|
761
|
+
| Name | Type | Description | |
|
|
762
|
+
| ---- | ---- | ----------- | -------- |
|
|
763
|
+
| fbFilters | | Array of flat filters from UI | |
|
|
764
|
+
|
|
765
|
+
|
|
766
|
+
|
|
767
|
+
|
|
768
|
+
##### Returns
|
|
769
|
+
|
|
770
|
+
|
|
771
|
+
- an array of scopes structure.
|
|
772
|
+
|
|
773
|
+
|
|
774
|
+
|
|
775
|
+
#### buildScope(uFilter)
|
|
776
|
+
|
|
777
|
+
Gets an scope structure for the filter data
|
|
778
|
+
|
|
779
|
+
|
|
780
|
+
|
|
781
|
+
|
|
782
|
+
##### Parameters
|
|
783
|
+
|
|
784
|
+
| Name | Type | Description | |
|
|
785
|
+
| ---- | ---- | ----------- | -------- |
|
|
786
|
+
| uFilter | | UI structure filter | |
|
|
488
787
|
|
|
489
788
|
|
|
490
789
|
|
|
@@ -1040,12 +1339,12 @@ Gets the Scopes IDS for the Available Scope function by any config
|
|
|
1040
1339
|
|
|
1041
1340
|
|
|
1042
1341
|
|
|
1043
|
-
### dist/
|
|
1342
|
+
### dist/general/function/debounce.js
|
|
1044
1343
|
|
|
1045
1344
|
|
|
1046
|
-
####
|
|
1345
|
+
#### debounce(fn, time)
|
|
1047
1346
|
|
|
1048
|
-
|
|
1347
|
+
Delays invoking _fn_ until after _time_ milliseconds have elapsed since the last time the debounced function was invoked.
|
|
1049
1348
|
|
|
1050
1349
|
|
|
1051
1350
|
|
|
@@ -1054,176 +1353,26 @@ Get date range object from a string date value
|
|
|
1054
1353
|
|
|
1055
1354
|
| Name | Type | Description | |
|
|
1056
1355
|
| ---- | ---- | ----------- | -------- |
|
|
1057
|
-
|
|
|
1058
|
-
|
|
|
1059
|
-
| withTime | `Boolean` | determines if the date range will include time. Default is true | |
|
|
1356
|
+
| fn | `Function` | original Function | |
|
|
1357
|
+
| time | `Number` | default 500ms | |
|
|
1060
1358
|
|
|
1061
1359
|
|
|
1062
1360
|
|
|
1063
1361
|
|
|
1064
|
-
#####
|
|
1065
|
-
|
|
1066
|
-
```javascript
|
|
1067
|
-
// 1) Year:
|
|
1068
|
-
getDateRange('2020', 'YEAR');
|
|
1069
|
-
// Will return:
|
|
1070
|
-
{
|
|
1071
|
-
from: '01/01/2020 00:00:00',
|
|
1072
|
-
to: '12/31/2020 23:59:59'
|
|
1073
|
-
}
|
|
1074
|
-
|
|
1075
|
-
// 2) Quarter:
|
|
1076
|
-
getDateRange('Q3 2020', 'QUARTER');
|
|
1077
|
-
// Will return:
|
|
1078
|
-
{
|
|
1079
|
-
from: '07/01/2020 00:00:00',
|
|
1080
|
-
to: '09/30/2020 23:59:59'
|
|
1081
|
-
}
|
|
1082
|
-
|
|
1083
|
-
// 3) Month:
|
|
1084
|
-
getDateRange('Oct 2020', 'MONTH');
|
|
1085
|
-
// Will return:
|
|
1086
|
-
{
|
|
1087
|
-
from: '10/01/2020 00:00:00',
|
|
1088
|
-
to: '10/31/2020 23:59:59'
|
|
1089
|
-
}
|
|
1090
|
-
```
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
##### Returns
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
- `Object` an object with the date range with two string date properties: from and to
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
### dist/date/relative/Adapter.js
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
#### value()
|
|
1105
|
-
|
|
1106
|
-
Resolves statement and returns statement value
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
##### Returns
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
- `AbsoluteRange` `string`
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
#### valueAsAnchor()
|
|
1121
|
-
|
|
1122
|
-
Resolves statement as an anchor
|
|
1123
|
-
|
|
1124
|
-
|
|
1125
|
-
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
|
|
1129
|
-
##### Returns
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
- `string`
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
#### _statementToRange() *private method*
|
|
1137
|
-
|
|
1138
|
-
Convert verbal statement to range value
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
##### Returns
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
- `AbsoluteRange`
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
#### _resolveAsThis() *private method*
|
|
1153
|
-
|
|
1154
|
-
Apply 'this' cursor logic to statement
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
|
|
1160
|
-
|
|
1161
|
-
##### Returns
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
- `AbsoluteStatement`
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
#### _resolveAsTheLast() *private method*
|
|
1169
|
-
|
|
1170
|
-
Apply 'the last' cursor logic to statement
|
|
1171
|
-
|
|
1172
|
-
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
##### Returns
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
- `AbsoluteStatement`
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
#### _resolveAsTheNext() *private method*
|
|
1185
|
-
|
|
1186
|
-
Apply 'the next' cursor logic to statement
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
##### Returns
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
- `AbsoluteStatement`
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
#### replaceNowToken(value, now)
|
|
1201
|
-
|
|
1202
|
-
Replace '@now' token inside a string
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
##### Parameters
|
|
1208
|
-
|
|
1209
|
-
| Name | Type | Description | |
|
|
1210
|
-
| ---- | ---- | ----------- | -------- |
|
|
1211
|
-
| value | `string` | | |
|
|
1212
|
-
| now | `Date` | | |
|
|
1213
|
-
|
|
1362
|
+
##### Returns
|
|
1214
1363
|
|
|
1215
1364
|
|
|
1365
|
+
- `Function` debounced functions
|
|
1216
1366
|
|
|
1217
|
-
##### Returns
|
|
1218
1367
|
|
|
1219
1368
|
|
|
1220
|
-
- `string`
|
|
1221
1369
|
|
|
1370
|
+
### dist/general/function/throttled.js
|
|
1222
1371
|
|
|
1223
1372
|
|
|
1224
|
-
####
|
|
1373
|
+
#### throttled(fn, time)
|
|
1225
1374
|
|
|
1226
|
-
|
|
1375
|
+
Make sure to only invokes _fn_ at most once per every _time_ milliseconds
|
|
1227
1376
|
|
|
1228
1377
|
|
|
1229
1378
|
|
|
@@ -1232,45 +1381,26 @@ Returns a range object (date) from a group of statement params
|
|
|
1232
1381
|
|
|
1233
1382
|
| Name | Type | Description | |
|
|
1234
1383
|
| ---- | ---- | ----------- | -------- |
|
|
1235
|
-
|
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1384
|
+
| fn | `Function` | original Function | |
|
|
1385
|
+
| time | `Number` | default 500ms | |
|
|
1239
1386
|
|
|
1240
|
-
##### Examples
|
|
1241
1387
|
|
|
1242
|
-
```javascript
|
|
1243
|
-
pivot = '2021-03-03T12:30:40'
|
|
1244
|
-
unit = month
|
|
1245
|
-
steps = 2
|
|
1246
|
-
setTo = END
|
|
1247
|
-
resolverAsCalendar: true
|
|
1248
|
-
=> Returns '2021-05-31T23:59:59'
|
|
1249
|
-
```
|
|
1250
|
-
```javascript
|
|
1251
|
-
pivot = '2021-03-03T12:30:40'
|
|
1252
|
-
unit = month
|
|
1253
|
-
steps = -2
|
|
1254
|
-
setTo = START
|
|
1255
|
-
resolverAsCalendar: false
|
|
1256
|
-
=> Returns '2021-01-03T00:00:00'
|
|
1257
|
-
```
|
|
1258
1388
|
|
|
1259
1389
|
|
|
1260
1390
|
##### Returns
|
|
1261
1391
|
|
|
1262
1392
|
|
|
1263
|
-
- `
|
|
1393
|
+
- `Function` throttled function
|
|
1264
1394
|
|
|
1265
1395
|
|
|
1266
1396
|
|
|
1267
1397
|
|
|
1268
|
-
### dist/
|
|
1398
|
+
### dist/general/mix/getTag.js
|
|
1269
1399
|
|
|
1270
1400
|
|
|
1271
|
-
####
|
|
1401
|
+
#### getTag(value)
|
|
1272
1402
|
|
|
1273
|
-
|
|
1403
|
+
Gets the `toStringTag` of `value`.
|
|
1274
1404
|
|
|
1275
1405
|
|
|
1276
1406
|
|
|
@@ -1279,44 +1409,25 @@ Resolve a list of relative statements according to operator
|
|
|
1279
1409
|
|
|
1280
1410
|
| Name | Type | Description | |
|
|
1281
1411
|
| ---- | ---- | ----------- | -------- |
|
|
1282
|
-
|
|
|
1283
|
-
| clock | `Date` | - Clock/time reference for relative date resolution | |
|
|
1284
|
-
|
|
1412
|
+
| value | | The value to query. | |
|
|
1285
1413
|
|
|
1286
1414
|
|
|
1287
1415
|
|
|
1288
|
-
##### Examples
|
|
1289
|
-
|
|
1290
|
-
```javascript
|
|
1291
|
-
Input:
|
|
1292
|
-
{
|
|
1293
|
-
"cursor": "the_next",
|
|
1294
|
-
"unit": "year",
|
|
1295
|
-
"number": 1,
|
|
1296
|
-
"includeCurrent": false,
|
|
1297
|
-
"isCalendarDate": false,
|
|
1298
|
-
"anchor": "03/05/2021"
|
|
1299
|
-
}
|
|
1300
|
-
|
|
1301
|
-
Output:
|
|
1302
|
-
{ gte: "03/06/2021 00:00:00", lte: "03/05/2022 23:59:59" }
|
|
1303
|
-
```
|
|
1304
|
-
|
|
1305
1416
|
|
|
1306
1417
|
##### Returns
|
|
1307
1418
|
|
|
1308
1419
|
|
|
1309
|
-
- `
|
|
1420
|
+
- `string` Returns the `toStringTag`.
|
|
1310
1421
|
|
|
1311
1422
|
|
|
1312
1423
|
|
|
1313
1424
|
|
|
1314
|
-
### dist/general/
|
|
1425
|
+
### dist/general/mix/importScripts.js
|
|
1315
1426
|
|
|
1316
1427
|
|
|
1317
|
-
####
|
|
1428
|
+
#### importScripts(scripts)
|
|
1318
1429
|
|
|
1319
|
-
|
|
1430
|
+
Import a set of external Scripts given the URL in both serie and cascade way
|
|
1320
1431
|
|
|
1321
1432
|
|
|
1322
1433
|
|
|
@@ -1325,56 +1436,54 @@ Inmutable Array Item deletion
|
|
|
1325
1436
|
|
|
1326
1437
|
| Name | Type | Description | |
|
|
1327
1438
|
| ---- | ---- | ----------- | -------- |
|
|
1328
|
-
|
|
|
1329
|
-
|
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
##### Returns
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
- a new Array or the given parameter when is empty or not an array
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
### dist/general/array/flattenDeep.js
|
|
1343
|
-
|
|
1344
|
-
|
|
1345
|
-
#### flattenDeep(arr)
|
|
1439
|
+
| scripts | `Array.<String>` `Array.<Object>` | can be an array of string or an array of object with the follow structure: | |
|
|
1440
|
+
| scripts.url | `String` | CDN URL | |
|
|
1441
|
+
| scripts.namespace | `String` `Function` | (Optional) if is a String, that name is evaluated on Window[namespace] object otherwise the Function is invoked expecting a Thrutly value | |
|
|
1442
|
+
| scripts.type | `String` | (Optional) it could be `module` of `text/javascript`. Default `text/javascript` | |
|
|
1443
|
+
| scripts.noModule | `Boolean` | (Optional) add `momodule` attribute to script tag. Default `false` | |
|
|
1444
|
+
| scripts.dependencies | `Array.<Object>` | an array with the same structure to load in cascade mode | |
|
|
1346
1445
|
|
|
1347
|
-
Flat deeply an array
|
|
1348
1446
|
|
|
1349
1447
|
|
|
1350
1448
|
|
|
1449
|
+
##### Examples
|
|
1351
1450
|
|
|
1352
|
-
|
|
1451
|
+
```javascript
|
|
1452
|
+
// 1) Simple script (paralell loading)
|
|
1453
|
+
importScripts(['http://myscript.js', 'http://another.js']);
|
|
1353
1454
|
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
|
|
1455
|
+
// 2) Loading `.js` and `.esm.js` script (parallel loading)
|
|
1456
|
+
importScripts([
|
|
1457
|
+
{ url: 'http://myscript.esm.js', type: 'module' },
|
|
1458
|
+
{ url: 'http://myscript.js', noModule: true }
|
|
1459
|
+
]);
|
|
1357
1460
|
|
|
1461
|
+
// 3) import dependent scripts (cascade)
|
|
1462
|
+
importScripts([
|
|
1463
|
+
{ url: 'http://myscript.js', dependencies: ['http://myscript.plugin.js'] }
|
|
1464
|
+
]);
|
|
1358
1465
|
|
|
1466
|
+
// 4) mix
|
|
1467
|
+
importScripts([
|
|
1468
|
+
{ url: 'http://myscript.js', dependencies: ['http://myscript.plugin.js'] },
|
|
1469
|
+
{ url: 'http://another.esm.js', type: 'module' },
|
|
1470
|
+
{ url: 'http://another.js', noModule: true },
|
|
1471
|
+
'http://simplescript.js'
|
|
1472
|
+
]);
|
|
1473
|
+
```
|
|
1359
1474
|
|
|
1360
1475
|
|
|
1361
1476
|
##### Returns
|
|
1362
1477
|
|
|
1363
1478
|
|
|
1364
|
-
-
|
|
1365
|
-
|
|
1366
|
-
|
|
1479
|
+
- `Promise` Promise when all script have been loaded
|
|
1367
1480
|
|
|
1368
1481
|
|
|
1369
|
-
### dist/general/array/filterNestedTree.js
|
|
1370
1482
|
|
|
1483
|
+
#### loadScript(url, type, noModule)
|
|
1371
1484
|
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
Filters a nested tree array by a custom condition on the last child node
|
|
1375
|
-
- If the given arguments are not valid, the function returns the first argument.
|
|
1376
|
-
- If the childArrKey is not matched in the object, the condition tries to resolve the filter anyway and returns an empty array.
|
|
1377
|
-
- If the condition is not fulfilled, the function returns a filtered array, probably a empty array inside of the child array
|
|
1485
|
+
Creates the script element and appends to document.head
|
|
1486
|
+
return a Promise that is resolved when the script is loaded
|
|
1378
1487
|
|
|
1379
1488
|
|
|
1380
1489
|
|
|
@@ -1383,9 +1492,9 @@ Filters a nested tree array by a custom condition on the last child node
|
|
|
1383
1492
|
|
|
1384
1493
|
| Name | Type | Description | |
|
|
1385
1494
|
| ---- | ---- | ----------- | -------- |
|
|
1386
|
-
|
|
|
1387
|
-
|
|
|
1388
|
-
|
|
|
1495
|
+
| url | `String` | Cdn Url | |
|
|
1496
|
+
| type | `String` | (Optional) it could be `module` of `text/javascript`. Default `text/javascript` | |
|
|
1497
|
+
| noModule | `boolean` | (Optional) add `momodule` attribute to script tag. Default `false` | |
|
|
1389
1498
|
|
|
1390
1499
|
|
|
1391
1500
|
|
|
@@ -1393,17 +1502,17 @@ Filters a nested tree array by a custom condition on the last child node
|
|
|
1393
1502
|
##### Returns
|
|
1394
1503
|
|
|
1395
1504
|
|
|
1396
|
-
-
|
|
1505
|
+
- `Void`
|
|
1397
1506
|
|
|
1398
1507
|
|
|
1399
1508
|
|
|
1400
1509
|
|
|
1401
|
-
### dist/general/
|
|
1510
|
+
### dist/general/mix/isEmpty.js
|
|
1402
1511
|
|
|
1403
1512
|
|
|
1404
|
-
####
|
|
1513
|
+
#### isEmpty(variable, includeFalsy)
|
|
1405
1514
|
|
|
1406
|
-
|
|
1515
|
+
Validates if the given argument is empty
|
|
1407
1516
|
|
|
1408
1517
|
|
|
1409
1518
|
|
|
@@ -1412,8 +1521,8 @@ Gets the first index from the array by a callback condition
|
|
|
1412
1521
|
|
|
1413
1522
|
| Name | Type | Description | |
|
|
1414
1523
|
| ---- | ---- | ----------- | -------- |
|
|
1415
|
-
|
|
|
1416
|
-
|
|
|
1524
|
+
| variable | | the given variable | |
|
|
1525
|
+
| includeFalsy | | flag to determine include the falsy variables into the validation | |
|
|
1417
1526
|
|
|
1418
1527
|
|
|
1419
1528
|
|
|
@@ -1421,17 +1530,18 @@ Gets the first index from the array by a callback condition
|
|
|
1421
1530
|
##### Returns
|
|
1422
1531
|
|
|
1423
1532
|
|
|
1424
|
-
-
|
|
1533
|
+
- true: the given argument is empty; false: is not.
|
|
1425
1534
|
|
|
1426
1535
|
|
|
1427
1536
|
|
|
1428
1537
|
|
|
1429
|
-
### dist/general/
|
|
1538
|
+
### dist/general/mix/isNull.js
|
|
1430
1539
|
|
|
1431
1540
|
|
|
1432
|
-
####
|
|
1541
|
+
#### isNull(arg)
|
|
1433
1542
|
|
|
1434
|
-
|
|
1543
|
+
return if a given variable is either `null` or `undefined`
|
|
1544
|
+
useful to avoid falsify validating Number Zero (0)
|
|
1435
1545
|
|
|
1436
1546
|
|
|
1437
1547
|
|
|
@@ -1440,8 +1550,7 @@ Gets the last index from the array by a callback condition
|
|
|
1440
1550
|
|
|
1441
1551
|
| Name | Type | Description | |
|
|
1442
1552
|
| ---- | ---- | ----------- | -------- |
|
|
1443
|
-
|
|
|
1444
|
-
| callback | | function callback | |
|
|
1553
|
+
| arg | `any` | | |
|
|
1445
1554
|
|
|
1446
1555
|
|
|
1447
1556
|
|
|
@@ -1449,17 +1558,19 @@ Gets the last index from the array by a callback condition
|
|
|
1449
1558
|
##### Returns
|
|
1450
1559
|
|
|
1451
1560
|
|
|
1452
|
-
-
|
|
1561
|
+
- `Boolean`
|
|
1453
1562
|
|
|
1454
1563
|
|
|
1455
1564
|
|
|
1456
1565
|
|
|
1457
|
-
### dist/general/
|
|
1566
|
+
### dist/general/mix/size.js
|
|
1458
1567
|
|
|
1459
1568
|
|
|
1460
|
-
####
|
|
1569
|
+
#### size(obj)
|
|
1461
1570
|
|
|
1462
|
-
|
|
1571
|
+
Gets the length of the given array.
|
|
1572
|
+
- Useful for Object, Array and string type.
|
|
1573
|
+
- For `null` or `undefined` or else argument the returned value will be 0.
|
|
1463
1574
|
|
|
1464
1575
|
|
|
1465
1576
|
|
|
@@ -1468,8 +1579,7 @@ Delays invoking _fn_ until after _time_ milliseconds have elapsed since the last
|
|
|
1468
1579
|
|
|
1469
1580
|
| Name | Type | Description | |
|
|
1470
1581
|
| ---- | ---- | ----------- | -------- |
|
|
1471
|
-
|
|
|
1472
|
-
| time | `Number` | default 500ms | |
|
|
1582
|
+
| obj | `Any` | Any object-type variable | |
|
|
1473
1583
|
|
|
1474
1584
|
|
|
1475
1585
|
|
|
@@ -1477,17 +1587,19 @@ Delays invoking _fn_ until after _time_ milliseconds have elapsed since the last
|
|
|
1477
1587
|
##### Returns
|
|
1478
1588
|
|
|
1479
1589
|
|
|
1480
|
-
- `
|
|
1590
|
+
- `Number` the size of the given variable
|
|
1481
1591
|
|
|
1482
1592
|
|
|
1483
1593
|
|
|
1484
1594
|
|
|
1485
|
-
### dist/general/
|
|
1595
|
+
### dist/general/mix/randomId.js
|
|
1486
1596
|
|
|
1487
1597
|
|
|
1488
|
-
####
|
|
1598
|
+
#### randomId(length, exclude)
|
|
1489
1599
|
|
|
1490
|
-
|
|
1600
|
+
Creates a random string
|
|
1601
|
+
- If the first given argument is different than a length number, the variable is replaced by a default number
|
|
1602
|
+
- If the optional second given argument is passed the random string is permutated.
|
|
1491
1603
|
|
|
1492
1604
|
|
|
1493
1605
|
|
|
@@ -1496,8 +1608,8 @@ Make sure to only invokes _fn_ at most once per every _time_ milliseconds
|
|
|
1496
1608
|
|
|
1497
1609
|
| Name | Type | Description | |
|
|
1498
1610
|
| ---- | ---- | ----------- | -------- |
|
|
1499
|
-
|
|
|
1500
|
-
|
|
|
1611
|
+
| length | `Number` | size of the generated string. Default 8 | |
|
|
1612
|
+
| exclude | `Array` | collection of strings that is going to be excluded of the random string. | |
|
|
1501
1613
|
|
|
1502
1614
|
|
|
1503
1615
|
|
|
@@ -1505,17 +1617,18 @@ Make sure to only invokes _fn_ at most once per every _time_ milliseconds
|
|
|
1505
1617
|
##### Returns
|
|
1506
1618
|
|
|
1507
1619
|
|
|
1508
|
-
- `
|
|
1620
|
+
- `String` Random string
|
|
1509
1621
|
|
|
1510
1622
|
|
|
1511
1623
|
|
|
1512
1624
|
|
|
1513
|
-
### dist/general/
|
|
1625
|
+
### dist/general/object/cloneDeep.js
|
|
1514
1626
|
|
|
1515
1627
|
|
|
1516
|
-
####
|
|
1628
|
+
#### cloneDeep(obj)
|
|
1517
1629
|
|
|
1518
|
-
|
|
1630
|
+
A simple Deep Cloning function. Valid only for primivite values and object with primitive values.
|
|
1631
|
+
Not to use this function with inner objects and functions
|
|
1519
1632
|
|
|
1520
1633
|
|
|
1521
1634
|
|
|
@@ -1524,7 +1637,7 @@ Gets the `toStringTag` of `value`.
|
|
|
1524
1637
|
|
|
1525
1638
|
| Name | Type | Description | |
|
|
1526
1639
|
| ---- | ---- | ----------- | -------- |
|
|
1527
|
-
|
|
|
1640
|
+
| obj | | The object | |
|
|
1528
1641
|
|
|
1529
1642
|
|
|
1530
1643
|
|
|
@@ -1532,17 +1645,21 @@ Gets the `toStringTag` of `value`.
|
|
|
1532
1645
|
##### Returns
|
|
1533
1646
|
|
|
1534
1647
|
|
|
1535
|
-
-
|
|
1648
|
+
- The new reference object or the given object if the parsing is incorrect or empty
|
|
1536
1649
|
|
|
1537
1650
|
|
|
1538
1651
|
|
|
1539
1652
|
|
|
1540
|
-
### dist/general/
|
|
1653
|
+
### dist/general/object/get.js
|
|
1541
1654
|
|
|
1542
1655
|
|
|
1543
|
-
####
|
|
1656
|
+
#### _get(baseObject, path, defaultValue)
|
|
1544
1657
|
|
|
1545
|
-
|
|
1658
|
+
Like lodash _.get.
|
|
1659
|
+
Gets the value at path of object. If the resolved value is undefined, the defaultValue is returned in its place.
|
|
1660
|
+
|
|
1661
|
+
Empty arrays and empty objects are returned but the defaultValue is not
|
|
1662
|
+
Undefined and null values will return the defaultValue.
|
|
1546
1663
|
|
|
1547
1664
|
|
|
1548
1665
|
|
|
@@ -1551,12 +1668,9 @@ Import a set of external Scripts given the URL in both serie and cascade way
|
|
|
1551
1668
|
|
|
1552
1669
|
| Name | Type | Description | |
|
|
1553
1670
|
| ---- | ---- | ----------- | -------- |
|
|
1554
|
-
|
|
|
1555
|
-
|
|
|
1556
|
-
|
|
|
1557
|
-
| scripts.type | `String` | (Optional) it could be `module` of `text/javascript`. Default `text/javascript` | |
|
|
1558
|
-
| scripts.noModule | `Boolean` | (Optional) add `momodule` attribute to script tag. Default `false` | |
|
|
1559
|
-
| scripts.dependencies | `Array.<Object>` | an array with the same structure to load in cascade mode | |
|
|
1671
|
+
| baseObject | | The object to query | |
|
|
1672
|
+
| path | | The string path or collection of string paths of the property to get. | |
|
|
1673
|
+
| defaultValue | | The value returned for undefined resolved values. | |
|
|
1560
1674
|
|
|
1561
1675
|
|
|
1562
1676
|
|
|
@@ -1564,41 +1678,41 @@ Import a set of external Scripts given the URL in both serie and cascade way
|
|
|
1564
1678
|
##### Examples
|
|
1565
1679
|
|
|
1566
1680
|
```javascript
|
|
1567
|
-
//
|
|
1568
|
-
|
|
1681
|
+
// returns 'Hello'
|
|
1682
|
+
_get({ item1: 'Hello', item2: 'World' }, 'item1')
|
|
1683
|
+
```
|
|
1684
|
+
```javascript
|
|
1685
|
+
// returns 'A simple Hello'
|
|
1686
|
+
_get({ item1: 'Hello', item2: 'World' }, 'item3', 'A simple Hello')
|
|
1687
|
+
```
|
|
1688
|
+
```javascript
|
|
1689
|
+
// returns 'Hello Again'
|
|
1690
|
+
_get({ item1: { item11: 'Hello Again' }, item2: {} }, 'item1.item11')
|
|
1691
|
+
```
|
|
1692
|
+
```javascript
|
|
1693
|
+
// returns 'Hello 2'
|
|
1694
|
+
_get({ item1: ['Hello 1', 'Hello 2' }, item2: [] }, 'item1[1]')
|
|
1695
|
+
```
|
|
1696
|
+
```javascript
|
|
1697
|
+
// returns 'Hello Again'
|
|
1698
|
+
_get({ item1: { item11: 'Hello Again' }, item2: {} }, ['item1', 'item11'])
|
|
1699
|
+
```
|
|
1569
1700
|
|
|
1570
|
-
// 2) Loading `.js` and `.esm.js` script (parallel loading)
|
|
1571
|
-
importScripts([
|
|
1572
|
-
{ url: 'http://myscript.esm.js', type: 'module' },
|
|
1573
|
-
{ url: 'http://myscript.js', noModule: true }
|
|
1574
|
-
]);
|
|
1575
1701
|
|
|
1576
|
-
|
|
1577
|
-
importScripts([
|
|
1578
|
-
{ url: 'http://myscript.js', dependencies: ['http://myscript.plugin.js'] }
|
|
1579
|
-
]);
|
|
1702
|
+
##### Returns
|
|
1580
1703
|
|
|
1581
|
-
// 4) mix
|
|
1582
|
-
importScripts([
|
|
1583
|
-
{ url: 'http://myscript.js', dependencies: ['http://myscript.plugin.js'] },
|
|
1584
|
-
{ url: 'http://another.esm.js', type: 'module' },
|
|
1585
|
-
{ url: 'http://another.js', noModule: true },
|
|
1586
|
-
'http://simplescript.js'
|
|
1587
|
-
]);
|
|
1588
|
-
```
|
|
1589
1704
|
|
|
1705
|
+
- the resolved value.
|
|
1590
1706
|
|
|
1591
|
-
##### Returns
|
|
1592
1707
|
|
|
1593
1708
|
|
|
1594
|
-
- `Promise` Promise when all script have been loaded
|
|
1595
1709
|
|
|
1710
|
+
### dist/general/object/hasProperty.js
|
|
1596
1711
|
|
|
1597
1712
|
|
|
1598
|
-
####
|
|
1713
|
+
#### _hasProperty(obj, property)
|
|
1599
1714
|
|
|
1600
|
-
|
|
1601
|
-
return a Promise that is resolved when the script is loaded
|
|
1715
|
+
Use the hasOwnProperty in order to verify if the given property exists in the object.
|
|
1602
1716
|
|
|
1603
1717
|
|
|
1604
1718
|
|
|
@@ -1607,28 +1721,38 @@ return a Promise that is resolved when the script is loaded
|
|
|
1607
1721
|
|
|
1608
1722
|
| Name | Type | Description | |
|
|
1609
1723
|
| ---- | ---- | ----------- | -------- |
|
|
1610
|
-
|
|
|
1611
|
-
|
|
|
1612
|
-
|
|
1724
|
+
| obj | `object` | an object | |
|
|
1725
|
+
| property | `string` | String to verify if exists in the object as property | |
|
|
1726
|
+
|
|
1727
|
+
|
|
1728
|
+
|
|
1729
|
+
|
|
1730
|
+
##### Examples
|
|
1613
1731
|
|
|
1732
|
+
```javascript
|
|
1733
|
+
const prop = 'prop2'
|
|
1734
|
+
const obj1 = { prop1: 'hello', prop2: 'world'}
|
|
1735
|
+
_hasProperty(ob1, prop1) // true
|
|
1614
1736
|
|
|
1737
|
+
const obj2 = { prop1: 'hello world' }
|
|
1738
|
+
_hasProperty(ob1, prop2) // false
|
|
1739
|
+
```
|
|
1615
1740
|
|
|
1616
1741
|
|
|
1617
1742
|
##### Returns
|
|
1618
1743
|
|
|
1619
1744
|
|
|
1620
|
-
-
|
|
1745
|
+
- True if the object has the given property; otherwise, false.
|
|
1621
1746
|
|
|
1622
1747
|
|
|
1623
1748
|
|
|
1624
1749
|
|
|
1625
|
-
### dist/general/
|
|
1750
|
+
### dist/general/object/isObject.js
|
|
1626
1751
|
|
|
1627
1752
|
|
|
1628
|
-
####
|
|
1753
|
+
#### isObject(obj)
|
|
1629
1754
|
|
|
1630
|
-
|
|
1631
|
-
useful to avoid falsify validating Number Zero (0)
|
|
1755
|
+
Checks if the given argument is an object type
|
|
1632
1756
|
|
|
1633
1757
|
|
|
1634
1758
|
|
|
@@ -1637,7 +1761,7 @@ useful to avoid falsify validating Number Zero (0)
|
|
|
1637
1761
|
|
|
1638
1762
|
| Name | Type | Description | |
|
|
1639
1763
|
| ---- | ---- | ----------- | -------- |
|
|
1640
|
-
|
|
|
1764
|
+
| obj | | the variable to check | |
|
|
1641
1765
|
|
|
1642
1766
|
|
|
1643
1767
|
|
|
@@ -1645,17 +1769,18 @@ useful to avoid falsify validating Number Zero (0)
|
|
|
1645
1769
|
##### Returns
|
|
1646
1770
|
|
|
1647
1771
|
|
|
1648
|
-
-
|
|
1772
|
+
- True: It is an object; False: It is not.
|
|
1649
1773
|
|
|
1650
1774
|
|
|
1651
1775
|
|
|
1652
1776
|
|
|
1653
|
-
### dist/general/
|
|
1777
|
+
### dist/general/object/mapValues.js
|
|
1654
1778
|
|
|
1655
1779
|
|
|
1656
|
-
####
|
|
1780
|
+
#### mapValues(baseObject, iteratee)
|
|
1657
1781
|
|
|
1658
|
-
|
|
1782
|
+
Invoke iteratee (function) for each object key-value pair
|
|
1783
|
+
and return a mapped object
|
|
1659
1784
|
|
|
1660
1785
|
|
|
1661
1786
|
|
|
@@ -1664,8 +1789,8 @@ Validates if the given argument is empty
|
|
|
1664
1789
|
|
|
1665
1790
|
| Name | Type | Description | |
|
|
1666
1791
|
| ---- | ---- | ----------- | -------- |
|
|
1667
|
-
|
|
|
1668
|
-
|
|
|
1792
|
+
| baseObject | `Object` | Base object. | |
|
|
1793
|
+
| iteratee | `Function` | The executed per iteration. | |
|
|
1669
1794
|
|
|
1670
1795
|
|
|
1671
1796
|
|
|
@@ -1673,19 +1798,17 @@ Validates if the given argument is empty
|
|
|
1673
1798
|
##### Returns
|
|
1674
1799
|
|
|
1675
1800
|
|
|
1676
|
-
-
|
|
1801
|
+
- `Object` New mapped object.
|
|
1677
1802
|
|
|
1678
1803
|
|
|
1679
1804
|
|
|
1680
1805
|
|
|
1681
|
-
### dist/general/
|
|
1806
|
+
### dist/general/object/objectCopy.js
|
|
1682
1807
|
|
|
1683
1808
|
|
|
1684
|
-
####
|
|
1809
|
+
#### objectCopy(entity, cache)
|
|
1685
1810
|
|
|
1686
|
-
|
|
1687
|
-
- If the first given argument is different than a length number, the variable is replaced by a default number
|
|
1688
|
-
- If the optional second given argument is passed the random string is permutated.
|
|
1811
|
+
Created a new reference of the given argument
|
|
1689
1812
|
|
|
1690
1813
|
|
|
1691
1814
|
|
|
@@ -1694,8 +1817,8 @@ Creates a random string
|
|
|
1694
1817
|
|
|
1695
1818
|
| Name | Type | Description | |
|
|
1696
1819
|
| ---- | ---- | ----------- | -------- |
|
|
1697
|
-
|
|
|
1698
|
-
|
|
|
1820
|
+
| entity | | The variable to be copied | |
|
|
1821
|
+
| cache | | | |
|
|
1699
1822
|
|
|
1700
1823
|
|
|
1701
1824
|
|
|
@@ -1703,19 +1826,17 @@ Creates a random string
|
|
|
1703
1826
|
##### Returns
|
|
1704
1827
|
|
|
1705
1828
|
|
|
1706
|
-
-
|
|
1829
|
+
- A new reference of the given argument
|
|
1707
1830
|
|
|
1708
1831
|
|
|
1709
1832
|
|
|
1710
1833
|
|
|
1711
|
-
### dist/general/
|
|
1834
|
+
### dist/general/object/omit.js
|
|
1712
1835
|
|
|
1713
1836
|
|
|
1714
|
-
####
|
|
1837
|
+
#### omit(obj, props)
|
|
1715
1838
|
|
|
1716
|
-
|
|
1717
|
-
- Useful for Object, Array and string type.
|
|
1718
|
-
- For `null` or `undefined` or else argument the returned value will be 0.
|
|
1839
|
+
return a nwe Object excluding attributes in _props_ list
|
|
1719
1840
|
|
|
1720
1841
|
|
|
1721
1842
|
|
|
@@ -1724,7 +1845,8 @@ Gets the length of the given array.
|
|
|
1724
1845
|
|
|
1725
1846
|
| Name | Type | Description | |
|
|
1726
1847
|
| ---- | ---- | ----------- | -------- |
|
|
1727
|
-
| obj | `
|
|
1848
|
+
| obj | `Object` | base object | |
|
|
1849
|
+
| props | `Array.<String>` | list of attribute to exclude | |
|
|
1728
1850
|
|
|
1729
1851
|
|
|
1730
1852
|
|
|
@@ -1732,17 +1854,17 @@ Gets the length of the given array.
|
|
|
1732
1854
|
##### Returns
|
|
1733
1855
|
|
|
1734
1856
|
|
|
1735
|
-
- `
|
|
1857
|
+
- `Object` clean object
|
|
1736
1858
|
|
|
1737
1859
|
|
|
1738
1860
|
|
|
1739
1861
|
|
|
1740
|
-
### dist/general/
|
|
1862
|
+
### dist/general/object/pick.js
|
|
1741
1863
|
|
|
1742
1864
|
|
|
1743
|
-
####
|
|
1865
|
+
#### pick(baseObject, keys)
|
|
1744
1866
|
|
|
1745
|
-
|
|
1867
|
+
return a new object just with attributes in _keys_ list
|
|
1746
1868
|
|
|
1747
1869
|
|
|
1748
1870
|
|
|
@@ -1751,7 +1873,8 @@ Upper case the first letter of a given text
|
|
|
1751
1873
|
|
|
1752
1874
|
| Name | Type | Description | |
|
|
1753
1875
|
| ---- | ---- | ----------- | -------- |
|
|
1754
|
-
|
|
|
1876
|
+
| baseObject | `Object` | base object | |
|
|
1877
|
+
| keys | `Array.<String>` | list of attributes to preserve | |
|
|
1755
1878
|
|
|
1756
1879
|
|
|
1757
1880
|
|
|
@@ -1759,18 +1882,17 @@ Upper case the first letter of a given text
|
|
|
1759
1882
|
##### Returns
|
|
1760
1883
|
|
|
1761
1884
|
|
|
1762
|
-
- `
|
|
1885
|
+
- `Object` new object just with desired attributes
|
|
1763
1886
|
|
|
1764
1887
|
|
|
1765
1888
|
|
|
1766
1889
|
|
|
1767
|
-
### dist/general/
|
|
1890
|
+
### dist/general/string/capitalize.js
|
|
1768
1891
|
|
|
1769
1892
|
|
|
1770
|
-
####
|
|
1893
|
+
#### capitalize(text)
|
|
1771
1894
|
|
|
1772
|
-
|
|
1773
|
-
Not to use this function with inner objects and functions
|
|
1895
|
+
Upper case the first letter of a given text
|
|
1774
1896
|
|
|
1775
1897
|
|
|
1776
1898
|
|
|
@@ -1779,7 +1901,7 @@ Not to use this function with inner objects and functions
|
|
|
1779
1901
|
|
|
1780
1902
|
| Name | Type | Description | |
|
|
1781
1903
|
| ---- | ---- | ----------- | -------- |
|
|
1782
|
-
|
|
|
1904
|
+
| text | `String` | | |
|
|
1783
1905
|
|
|
1784
1906
|
|
|
1785
1907
|
|
|
@@ -1787,32 +1909,21 @@ Not to use this function with inner objects and functions
|
|
|
1787
1909
|
##### Returns
|
|
1788
1910
|
|
|
1789
1911
|
|
|
1790
|
-
-
|
|
1791
|
-
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
### dist/general/object/get.js
|
|
1912
|
+
- `String` a capitalized text
|
|
1796
1913
|
|
|
1797
1914
|
|
|
1798
|
-
#### _get(baseObject, path, defaultValue)
|
|
1799
1915
|
|
|
1800
|
-
Like lodash _.get.
|
|
1801
|
-
Gets the value at path of object. If the resolved value is undefined, the defaultValue is returned in its place.
|
|
1802
1916
|
|
|
1803
|
-
|
|
1804
|
-
Undefined and null values will return the defaultValue.
|
|
1917
|
+
### dist/stencil/decorators/Config.js
|
|
1805
1918
|
|
|
1806
1919
|
|
|
1920
|
+
#### Config()
|
|
1807
1921
|
|
|
1922
|
+
Stencil.js - Prop Decorator
|
|
1923
|
+
Get and Parse the Widget Configuration Object and also provide the ability to get properties in different case styles such as: lower, upper, camel and pascal
|
|
1924
|
+
But for this, is required ask for a property in `snake_case` style
|
|
1808
1925
|
|
|
1809
|
-
##### Parameters
|
|
1810
1926
|
|
|
1811
|
-
| Name | Type | Description | |
|
|
1812
|
-
| ---- | ---- | ----------- | -------- |
|
|
1813
|
-
| baseObject | | The object to query | |
|
|
1814
|
-
| path | | The string path or collection of string paths of the property to get. | |
|
|
1815
|
-
| defaultValue | | The value returned for undefined resolved values. | |
|
|
1816
1927
|
|
|
1817
1928
|
|
|
1818
1929
|
|
|
@@ -1820,81 +1931,52 @@ Undefined and null values will return the defaultValue.
|
|
|
1820
1931
|
##### Examples
|
|
1821
1932
|
|
|
1822
1933
|
```javascript
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
|
|
1827
|
-
|
|
1828
|
-
_get({ item1: 'Hello', item2: 'World' }, 'item3', 'A simple Hello')
|
|
1829
|
-
```
|
|
1830
|
-
```javascript
|
|
1831
|
-
// returns 'Hello Again'
|
|
1832
|
-
_get({ item1: { item11: 'Hello Again' }, item2: {} }, 'item1.item11')
|
|
1833
|
-
```
|
|
1834
|
-
```javascript
|
|
1835
|
-
// returns 'Hello 2'
|
|
1836
|
-
_get({ item1: ['Hello 1', 'Hello 2' }, item2: [] }, 'item1[1]')
|
|
1837
|
-
```
|
|
1838
|
-
```javascript
|
|
1839
|
-
// returns 'Hello Again'
|
|
1840
|
-
_get({ item1: { item11: 'Hello Again' }, item2: {} }, ['item1', 'item11'])
|
|
1934
|
+
\ @Config() @Prop() settings;
|
|
1935
|
+
|
|
1936
|
+
someMethod() {
|
|
1937
|
+
this.settings.snake_case //it search for: obj.snake_case || obj.snakeCase || obj.SnakeCase || obj.snakecase || obj.SNAKECASE
|
|
1938
|
+
}
|
|
1841
1939
|
```
|
|
1842
1940
|
|
|
1843
1941
|
|
|
1844
1942
|
##### Returns
|
|
1845
1943
|
|
|
1846
1944
|
|
|
1847
|
-
-
|
|
1848
|
-
|
|
1849
|
-
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
### dist/general/object/hasProperty.js
|
|
1853
|
-
|
|
1854
|
-
|
|
1855
|
-
#### _hasProperty(obj, property)
|
|
1856
|
-
|
|
1857
|
-
Use the hasOwnProperty in order to verify if the given property exists in the object.
|
|
1945
|
+
- `Void`
|
|
1858
1946
|
|
|
1859
1947
|
|
|
1860
1948
|
|
|
1861
1949
|
|
|
1862
|
-
|
|
1950
|
+
### dist/stencil/util/createRef.js
|
|
1863
1951
|
|
|
1864
|
-
| Name | Type | Description | |
|
|
1865
|
-
| ---- | ---- | ----------- | -------- |
|
|
1866
|
-
| obj | `object` | an object | |
|
|
1867
|
-
| property | `string` | String to verify if exists in the object as property | |
|
|
1868
1952
|
|
|
1953
|
+
#### createRef()
|
|
1869
1954
|
|
|
1955
|
+
lit implementation of React createRef (https://reactjs.org/docs/refs-and-the-dom.html)
|
|
1870
1956
|
|
|
1871
1957
|
|
|
1872
|
-
##### Examples
|
|
1873
1958
|
|
|
1874
|
-
```javascript
|
|
1875
|
-
const prop = 'prop2'
|
|
1876
|
-
const obj1 = { prop1: 'hello', prop2: 'world'}
|
|
1877
|
-
_hasProperty(ob1, prop1) // true
|
|
1878
1959
|
|
|
1879
|
-
const obj2 = { prop1: 'hello world' }
|
|
1880
|
-
_hasProperty(ob1, prop2) // false
|
|
1881
|
-
```
|
|
1882
1960
|
|
|
1883
1961
|
|
|
1884
1962
|
##### Returns
|
|
1885
1963
|
|
|
1886
1964
|
|
|
1887
|
-
-
|
|
1965
|
+
- function - Function to use in ref prop in html elements
|
|
1888
1966
|
|
|
1889
1967
|
|
|
1890
1968
|
|
|
1891
1969
|
|
|
1892
|
-
### dist/
|
|
1970
|
+
### dist/stencil/util/getConfig.js
|
|
1893
1971
|
|
|
1894
1972
|
|
|
1895
|
-
####
|
|
1973
|
+
#### getConfig(cfg)
|
|
1896
1974
|
|
|
1897
|
-
|
|
1975
|
+
verify the Config object type and try to return a parsed Object
|
|
1976
|
+
- In case _cfg_ is a string, first try to make a JSON parse in other case
|
|
1977
|
+
try to find this string as a variable on Windows object
|
|
1978
|
+
- If _cfg_ is a fuction, tis is invoked and parsed
|
|
1979
|
+
- Finally, if is an object, _cfg_ is inmediatly returned
|
|
1898
1980
|
|
|
1899
1981
|
|
|
1900
1982
|
|
|
@@ -1903,7 +1985,7 @@ Checks if the given argument is an object type
|
|
|
1903
1985
|
|
|
1904
1986
|
| Name | Type | Description | |
|
|
1905
1987
|
| ---- | ---- | ----------- | -------- |
|
|
1906
|
-
|
|
|
1988
|
+
| cfg | | | |
|
|
1907
1989
|
|
|
1908
1990
|
|
|
1909
1991
|
|
|
@@ -1911,18 +1993,17 @@ Checks if the given argument is an object type
|
|
|
1911
1993
|
##### Returns
|
|
1912
1994
|
|
|
1913
1995
|
|
|
1914
|
-
-
|
|
1996
|
+
- `Void`
|
|
1915
1997
|
|
|
1916
1998
|
|
|
1917
1999
|
|
|
1918
2000
|
|
|
1919
|
-
### dist/general/
|
|
2001
|
+
### dist/general/array/delete.js
|
|
1920
2002
|
|
|
1921
2003
|
|
|
1922
|
-
####
|
|
2004
|
+
#### ArrayDelete(array, index)
|
|
1923
2005
|
|
|
1924
|
-
|
|
1925
|
-
and return a mapped object
|
|
2006
|
+
Inmutable Array Item deletion
|
|
1926
2007
|
|
|
1927
2008
|
|
|
1928
2009
|
|
|
@@ -1931,8 +2012,8 @@ and return a mapped object
|
|
|
1931
2012
|
|
|
1932
2013
|
| Name | Type | Description | |
|
|
1933
2014
|
| ---- | ---- | ----------- | -------- |
|
|
1934
|
-
|
|
|
1935
|
-
|
|
|
2015
|
+
| array | `Array` | a collection of items to delete | |
|
|
2016
|
+
| index | `Number` | the position of the item to delete | |
|
|
1936
2017
|
|
|
1937
2018
|
|
|
1938
2019
|
|
|
@@ -1940,17 +2021,20 @@ and return a mapped object
|
|
|
1940
2021
|
##### Returns
|
|
1941
2022
|
|
|
1942
2023
|
|
|
1943
|
-
-
|
|
2024
|
+
- a new Array or the given parameter when is empty or not an array
|
|
1944
2025
|
|
|
1945
2026
|
|
|
1946
2027
|
|
|
1947
2028
|
|
|
1948
|
-
### dist/general/
|
|
2029
|
+
### dist/general/array/filterNestedTree.js
|
|
1949
2030
|
|
|
1950
2031
|
|
|
1951
|
-
####
|
|
2032
|
+
#### filterNestedTree(arr, childArrKey, condition)
|
|
1952
2033
|
|
|
1953
|
-
|
|
2034
|
+
Filters a nested tree array by a custom condition on the last child node
|
|
2035
|
+
- If the given arguments are not valid, the function returns the first argument.
|
|
2036
|
+
- If the childArrKey is not matched in the object, the condition tries to resolve the filter anyway and returns an empty array.
|
|
2037
|
+
- If the condition is not fulfilled, the function returns a filtered array, probably a empty array inside of the child array
|
|
1954
2038
|
|
|
1955
2039
|
|
|
1956
2040
|
|
|
@@ -1959,8 +2043,9 @@ Created a new reference of the given argument
|
|
|
1959
2043
|
|
|
1960
2044
|
| Name | Type | Description | |
|
|
1961
2045
|
| ---- | ---- | ----------- | -------- |
|
|
1962
|
-
|
|
|
1963
|
-
|
|
|
2046
|
+
| arr | | nested tree array | |
|
|
2047
|
+
| childArrKey | | property representing the children array on the nested tree | |
|
|
2048
|
+
| condition | | function callback that determines if the filter is applied on the last child node of the nested tree | |
|
|
1964
2049
|
|
|
1965
2050
|
|
|
1966
2051
|
|
|
@@ -1968,17 +2053,17 @@ Created a new reference of the given argument
|
|
|
1968
2053
|
##### Returns
|
|
1969
2054
|
|
|
1970
2055
|
|
|
1971
|
-
-
|
|
2056
|
+
- array filtered
|
|
1972
2057
|
|
|
1973
2058
|
|
|
1974
2059
|
|
|
1975
2060
|
|
|
1976
|
-
### dist/general/
|
|
2061
|
+
### dist/general/array/flattenDeep.js
|
|
1977
2062
|
|
|
1978
2063
|
|
|
1979
|
-
####
|
|
2064
|
+
#### flattenDeep(arr)
|
|
1980
2065
|
|
|
1981
|
-
|
|
2066
|
+
Flat deeply an array
|
|
1982
2067
|
|
|
1983
2068
|
|
|
1984
2069
|
|
|
@@ -1987,8 +2072,7 @@ return a nwe Object excluding attributes in _props_ list
|
|
|
1987
2072
|
|
|
1988
2073
|
| Name | Type | Description | |
|
|
1989
2074
|
| ---- | ---- | ----------- | -------- |
|
|
1990
|
-
|
|
|
1991
|
-
| props | `Array.<String>` | list of attribute to exclude | |
|
|
2075
|
+
| arr | | Array to flat deeply | |
|
|
1992
2076
|
|
|
1993
2077
|
|
|
1994
2078
|
|
|
@@ -1996,17 +2080,17 @@ return a nwe Object excluding attributes in _props_ list
|
|
|
1996
2080
|
##### Returns
|
|
1997
2081
|
|
|
1998
2082
|
|
|
1999
|
-
-
|
|
2083
|
+
- flatten array
|
|
2000
2084
|
|
|
2001
2085
|
|
|
2002
2086
|
|
|
2003
2087
|
|
|
2004
|
-
### dist/general/
|
|
2088
|
+
### dist/general/array/getFirstIndexFromArray.js
|
|
2005
2089
|
|
|
2006
2090
|
|
|
2007
|
-
####
|
|
2091
|
+
#### getFirstIndexFromArray(array, callback)
|
|
2008
2092
|
|
|
2009
|
-
|
|
2093
|
+
Gets the first index from the array by a callback condition
|
|
2010
2094
|
|
|
2011
2095
|
|
|
2012
2096
|
|
|
@@ -2015,8 +2099,8 @@ return a new object just with attributes in _keys_ list
|
|
|
2015
2099
|
|
|
2016
2100
|
| Name | Type | Description | |
|
|
2017
2101
|
| ---- | ---- | ----------- | -------- |
|
|
2018
|
-
|
|
|
2019
|
-
|
|
|
2102
|
+
| array | | | |
|
|
2103
|
+
| callback | | function callback | |
|
|
2020
2104
|
|
|
2021
2105
|
|
|
2022
2106
|
|
|
@@ -2024,74 +2108,72 @@ return a new object just with attributes in _keys_ list
|
|
|
2024
2108
|
##### Returns
|
|
2025
2109
|
|
|
2026
2110
|
|
|
2027
|
-
-
|
|
2028
|
-
|
|
2111
|
+
- the first index of the array. -1 when the condition is not satisfied
|
|
2029
2112
|
|
|
2030
2113
|
|
|
2031
2114
|
|
|
2032
|
-
### dist/stencil/decorators/Config.js
|
|
2033
2115
|
|
|
2116
|
+
### dist/general/array/getLastIndexFromArray.js
|
|
2034
2117
|
|
|
2035
|
-
#### Config()
|
|
2036
2118
|
|
|
2037
|
-
|
|
2038
|
-
Get and Parse the Widget Configuration Object and also provide the ability to get properties in different case styles such as: lower, upper, camel and pascal
|
|
2039
|
-
But for this, is required ask for a property in `snake_case` style
|
|
2119
|
+
#### getLastIndexFromArray(array, callback)
|
|
2040
2120
|
|
|
2121
|
+
Gets the last index from the array by a callback condition
|
|
2041
2122
|
|
|
2042
2123
|
|
|
2043
2124
|
|
|
2044
2125
|
|
|
2126
|
+
##### Parameters
|
|
2045
2127
|
|
|
2046
|
-
|
|
2128
|
+
| Name | Type | Description | |
|
|
2129
|
+
| ---- | ---- | ----------- | -------- |
|
|
2130
|
+
| array | | | |
|
|
2131
|
+
| callback | | function callback | |
|
|
2047
2132
|
|
|
2048
|
-
```javascript
|
|
2049
|
-
\ @Config() @Prop() settings;
|
|
2050
2133
|
|
|
2051
|
-
someMethod() {
|
|
2052
|
-
this.settings.snake_case //it search for: obj.snake_case || obj.snakeCase || obj.SnakeCase || obj.snakecase || obj.SNAKECASE
|
|
2053
|
-
}
|
|
2054
|
-
```
|
|
2055
2134
|
|
|
2056
2135
|
|
|
2057
2136
|
##### Returns
|
|
2058
2137
|
|
|
2059
2138
|
|
|
2060
|
-
-
|
|
2139
|
+
- the last index of the array. -1 when the condition is not satisfied
|
|
2061
2140
|
|
|
2062
2141
|
|
|
2063
2142
|
|
|
2064
2143
|
|
|
2065
|
-
### dist/
|
|
2144
|
+
### dist/typescript/decorators/Debounce.js
|
|
2066
2145
|
|
|
2067
2146
|
|
|
2068
|
-
####
|
|
2147
|
+
#### Debounce(time)
|
|
2148
|
+
|
|
2149
|
+
(Method Decorator) Debounce Class Method
|
|
2069
2150
|
|
|
2070
|
-
lit implementation of React createRef (https://reactjs.org/docs/refs-and-the-dom.html)
|
|
2071
2151
|
|
|
2072
2152
|
|
|
2073
2153
|
|
|
2154
|
+
##### Parameters
|
|
2155
|
+
|
|
2156
|
+
| Name | Type | Description | |
|
|
2157
|
+
| ---- | ---- | ----------- | -------- |
|
|
2158
|
+
| time | | (optional) deafult 500 | |
|
|
2159
|
+
|
|
2074
2160
|
|
|
2075
2161
|
|
|
2076
2162
|
|
|
2077
2163
|
##### Returns
|
|
2078
2164
|
|
|
2079
2165
|
|
|
2080
|
-
-
|
|
2166
|
+
- `Void`
|
|
2081
2167
|
|
|
2082
2168
|
|
|
2083
2169
|
|
|
2084
2170
|
|
|
2085
|
-
### dist/
|
|
2171
|
+
### dist/typescript/decorators/Throttled.js
|
|
2086
2172
|
|
|
2087
2173
|
|
|
2088
|
-
####
|
|
2174
|
+
#### Throttled(time)
|
|
2089
2175
|
|
|
2090
|
-
|
|
2091
|
-
- In case _cfg_ is a string, first try to make a JSON parse in other case
|
|
2092
|
-
try to find this string as a variable on Windows object
|
|
2093
|
-
- If _cfg_ is a fuction, tis is invoked and parsed
|
|
2094
|
-
- Finally, if is an object, _cfg_ is inmediatly returned
|
|
2176
|
+
(Method Decorator) Throttled Class Method
|
|
2095
2177
|
|
|
2096
2178
|
|
|
2097
2179
|
|
|
@@ -2100,7 +2182,7 @@ try to find this string as a variable on Windows object
|
|
|
2100
2182
|
|
|
2101
2183
|
| Name | Type | Description | |
|
|
2102
2184
|
| ---- | ---- | ----------- | -------- |
|
|
2103
|
-
|
|
|
2185
|
+
| time | | (optional) deafult 500 | |
|
|
2104
2186
|
|
|
2105
2187
|
|
|
2106
2188
|
|
|
@@ -2113,12 +2195,12 @@ try to find this string as a variable on Windows object
|
|
|
2113
2195
|
|
|
2114
2196
|
|
|
2115
2197
|
|
|
2116
|
-
### dist/
|
|
2198
|
+
### dist/date/relative/helpers/formatStatement.js
|
|
2117
2199
|
|
|
2118
2200
|
|
|
2119
|
-
####
|
|
2201
|
+
#### formatStatement(statement)
|
|
2120
2202
|
|
|
2121
|
-
|
|
2203
|
+
Build a proper relative date statement type
|
|
2122
2204
|
|
|
2123
2205
|
|
|
2124
2206
|
|
|
@@ -2127,7 +2209,7 @@ try to find this string as a variable on Windows object
|
|
|
2127
2209
|
|
|
2128
2210
|
| Name | Type | Description | |
|
|
2129
2211
|
| ---- | ---- | ----------- | -------- |
|
|
2130
|
-
|
|
|
2212
|
+
| statement | `RelativeStatement` | | |
|
|
2131
2213
|
|
|
2132
2214
|
|
|
2133
2215
|
|
|
@@ -2135,17 +2217,17 @@ try to find this string as a variable on Windows object
|
|
|
2135
2217
|
##### Returns
|
|
2136
2218
|
|
|
2137
2219
|
|
|
2138
|
-
- `
|
|
2220
|
+
- `RelativeStatement`
|
|
2139
2221
|
|
|
2140
2222
|
|
|
2141
2223
|
|
|
2142
2224
|
|
|
2143
|
-
### dist/
|
|
2225
|
+
### dist/date/relative/helpers/getStatementCase.js
|
|
2144
2226
|
|
|
2145
2227
|
|
|
2146
|
-
####
|
|
2228
|
+
#### getStatementCase(includeCurrent, isCalendarDate)
|
|
2147
2229
|
|
|
2148
|
-
|
|
2230
|
+
Returns a number/constant that identifies a relative date case
|
|
2149
2231
|
|
|
2150
2232
|
|
|
2151
2233
|
|
|
@@ -2154,7 +2236,8 @@ try to find this string as a variable on Windows object
|
|
|
2154
2236
|
|
|
2155
2237
|
| Name | Type | Description | |
|
|
2156
2238
|
| ---- | ---- | ----------- | -------- |
|
|
2157
|
-
|
|
|
2239
|
+
| includeCurrent | `boolean` | | |
|
|
2240
|
+
| isCalendarDate | `boolean` | | |
|
|
2158
2241
|
|
|
2159
2242
|
|
|
2160
2243
|
|
|
@@ -2162,17 +2245,17 @@ try to find this string as a variable on Windows object
|
|
|
2162
2245
|
##### Returns
|
|
2163
2246
|
|
|
2164
2247
|
|
|
2165
|
-
- `
|
|
2248
|
+
- `number`
|
|
2166
2249
|
|
|
2167
2250
|
|
|
2168
2251
|
|
|
2169
2252
|
|
|
2170
|
-
### dist/
|
|
2253
|
+
### dist/date/relative/helpers/parseDate.js
|
|
2171
2254
|
|
|
2172
2255
|
|
|
2173
|
-
####
|
|
2256
|
+
#### parseDate(date)
|
|
2174
2257
|
|
|
2175
|
-
|
|
2258
|
+
Parses a string date and returns a dayjs date
|
|
2176
2259
|
|
|
2177
2260
|
|
|
2178
2261
|
|
|
@@ -2181,7 +2264,7 @@ Returns a filter builder config object by a any given config
|
|
|
2181
2264
|
|
|
2182
2265
|
| Name | Type | Description | |
|
|
2183
2266
|
| ---- | ---- | ----------- | -------- |
|
|
2184
|
-
|
|
|
2267
|
+
| date | `string` `Dayjs` `Date` | | |
|
|
2185
2268
|
|
|
2186
2269
|
|
|
2187
2270
|
|
|
@@ -2189,7 +2272,7 @@ Returns a filter builder config object by a any given config
|
|
|
2189
2272
|
##### Returns
|
|
2190
2273
|
|
|
2191
2274
|
|
|
2192
|
-
-
|
|
2275
|
+
- `Dayjs` A dayjs date
|
|
2193
2276
|
|
|
2194
2277
|
|
|
2195
2278
|
|
|
@@ -2490,12 +2573,12 @@ Gets filters from the logic by the scopes hierarchy.
|
|
|
2490
2573
|
|
|
2491
2574
|
|
|
2492
2575
|
|
|
2493
|
-
### dist/filters/helpers/
|
|
2576
|
+
### dist/filters/helpers/builder/getFilterBuilderGeneralConfig.js
|
|
2494
2577
|
|
|
2495
2578
|
|
|
2496
|
-
####
|
|
2579
|
+
#### getFilterBuilderGeneralConfig(config)
|
|
2497
2580
|
|
|
2498
|
-
|
|
2581
|
+
Returns a filter builder config object by a any given config
|
|
2499
2582
|
|
|
2500
2583
|
|
|
2501
2584
|
|
|
@@ -2504,8 +2587,7 @@ Determines if the filter column and property is a distinct group dates type
|
|
|
2504
2587
|
|
|
2505
2588
|
| Name | Type | Description | |
|
|
2506
2589
|
| ---- | ---- | ----------- | -------- |
|
|
2507
|
-
|
|
|
2508
|
-
| property | | The filter property | |
|
|
2590
|
+
| config | | any config object | |
|
|
2509
2591
|
|
|
2510
2592
|
|
|
2511
2593
|
|
|
@@ -2513,7 +2595,7 @@ Determines if the filter column and property is a distinct group dates type
|
|
|
2513
2595
|
##### Returns
|
|
2514
2596
|
|
|
2515
2597
|
|
|
2516
|
-
-
|
|
2598
|
+
- The filter builder config object
|
|
2517
2599
|
|
|
2518
2600
|
|
|
2519
2601
|
|
|
@@ -2546,6 +2628,34 @@ Validates if both filters are the same
|
|
|
2546
2628
|
|
|
2547
2629
|
|
|
2548
2630
|
|
|
2631
|
+
### dist/filters/helpers/common/arePropertiesDateP.js
|
|
2632
|
+
|
|
2633
|
+
|
|
2634
|
+
#### arePropertiesDateP(column, property)
|
|
2635
|
+
|
|
2636
|
+
Determines if the filter column and property is a distinct group dates type
|
|
2637
|
+
|
|
2638
|
+
|
|
2639
|
+
|
|
2640
|
+
|
|
2641
|
+
##### Parameters
|
|
2642
|
+
|
|
2643
|
+
| Name | Type | Description | |
|
|
2644
|
+
| ---- | ---- | ----------- | -------- |
|
|
2645
|
+
| column | | The filter column | |
|
|
2646
|
+
| property | | The filter property | |
|
|
2647
|
+
|
|
2648
|
+
|
|
2649
|
+
|
|
2650
|
+
|
|
2651
|
+
##### Returns
|
|
2652
|
+
|
|
2653
|
+
|
|
2654
|
+
- True if the given property is included from distinct group dates type
|
|
2655
|
+
|
|
2656
|
+
|
|
2657
|
+
|
|
2658
|
+
|
|
2549
2659
|
### dist/filters/helpers/common/excludeFiltersByAggregateColumn.js
|
|
2550
2660
|
|
|
2551
2661
|
|
|
@@ -3537,86 +3647,4 @@ Resolves conditions between UI flattened filter and given parameters
|
|
|
3537
3647
|
|
|
3538
3648
|
|
|
3539
3649
|
|
|
3540
|
-
### dist/date/relative/helpers/formatStatement.js
|
|
3541
|
-
|
|
3542
|
-
|
|
3543
|
-
#### formatStatement(statement)
|
|
3544
|
-
|
|
3545
|
-
Build a proper relative date statement type
|
|
3546
|
-
|
|
3547
|
-
|
|
3548
|
-
|
|
3549
|
-
|
|
3550
|
-
##### Parameters
|
|
3551
|
-
|
|
3552
|
-
| Name | Type | Description | |
|
|
3553
|
-
| ---- | ---- | ----------- | -------- |
|
|
3554
|
-
| statement | `RelativeStatement` | | |
|
|
3555
|
-
|
|
3556
|
-
|
|
3557
|
-
|
|
3558
|
-
|
|
3559
|
-
##### Returns
|
|
3560
|
-
|
|
3561
|
-
|
|
3562
|
-
- `RelativeStatement`
|
|
3563
|
-
|
|
3564
|
-
|
|
3565
|
-
|
|
3566
|
-
|
|
3567
|
-
### dist/date/relative/helpers/getStatementCase.js
|
|
3568
|
-
|
|
3569
|
-
|
|
3570
|
-
#### getStatementCase(includeCurrent, isCalendarDate)
|
|
3571
|
-
|
|
3572
|
-
Returns a number/constant that identifies a relative date case
|
|
3573
|
-
|
|
3574
|
-
|
|
3575
|
-
|
|
3576
|
-
|
|
3577
|
-
##### Parameters
|
|
3578
|
-
|
|
3579
|
-
| Name | Type | Description | |
|
|
3580
|
-
| ---- | ---- | ----------- | -------- |
|
|
3581
|
-
| includeCurrent | `boolean` | | |
|
|
3582
|
-
| isCalendarDate | `boolean` | | |
|
|
3583
|
-
|
|
3584
|
-
|
|
3585
|
-
|
|
3586
|
-
|
|
3587
|
-
##### Returns
|
|
3588
|
-
|
|
3589
|
-
|
|
3590
|
-
- `number`
|
|
3591
|
-
|
|
3592
|
-
|
|
3593
|
-
|
|
3594
|
-
|
|
3595
|
-
### dist/date/relative/helpers/parseDate.js
|
|
3596
|
-
|
|
3597
|
-
|
|
3598
|
-
#### parseDate(date)
|
|
3599
|
-
|
|
3600
|
-
Parses a string date and returns a dayjs date
|
|
3601
|
-
|
|
3602
|
-
|
|
3603
|
-
|
|
3604
|
-
|
|
3605
|
-
##### Parameters
|
|
3606
|
-
|
|
3607
|
-
| Name | Type | Description | |
|
|
3608
|
-
| ---- | ---- | ----------- | -------- |
|
|
3609
|
-
| date | `string` `Dayjs` `Date` | | |
|
|
3610
|
-
|
|
3611
|
-
|
|
3612
|
-
|
|
3613
|
-
|
|
3614
|
-
##### Returns
|
|
3615
|
-
|
|
3616
|
-
|
|
3617
|
-
- `Dayjs` A dayjs date
|
|
3618
|
-
|
|
3619
|
-
|
|
3620
|
-
|
|
3621
|
-
|
|
3622
3650
|
*Documentation generated with [doxdox](https://github.com/neogeek/doxdox).*
|