ng-prime-tools 1.0.30 → 1.0.32
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 +4 -0
- package/esm2022/lib/models/button.model.mjs +1 -1
- package/esm2022/lib/pt-advanced-prime-table/date-utility.service.mjs +43 -0
- package/esm2022/lib/pt-advanced-prime-table/pt-advanced-prime-table.component.mjs +107 -39
- package/esm2022/lib/pt-advanced-prime-table/pt-advanced-prime-table.module.mjs +7 -3
- package/esm2022/lib/pt-advanced-prime-table/public-api.mjs +2 -1
- package/esm2022/lib/pt-button/pt-button.component.mjs +44 -16
- package/esm2022/lib/pt-dialog/pt-dialog.component.mjs +164 -129
- package/fesm2022/ng-prime-tools.mjs +424 -250
- package/fesm2022/ng-prime-tools.mjs.map +1 -1
- package/lib/models/button.model.d.ts +1 -0
- package/lib/models/button.model.d.ts.map +1 -1
- package/lib/pt-advanced-prime-table/date-utility.service.d.ts +8 -0
- package/lib/pt-advanced-prime-table/date-utility.service.d.ts.map +1 -0
- package/lib/pt-advanced-prime-table/pt-advanced-prime-table.component.d.ts +17 -3
- package/lib/pt-advanced-prime-table/pt-advanced-prime-table.component.d.ts.map +1 -1
- package/lib/pt-advanced-prime-table/pt-advanced-prime-table.module.d.ts +2 -1
- package/lib/pt-advanced-prime-table/pt-advanced-prime-table.module.d.ts.map +1 -1
- package/lib/pt-advanced-prime-table/public-api.d.ts +1 -0
- package/lib/pt-advanced-prime-table/public-api.d.ts.map +1 -1
- package/lib/pt-button/pt-button.component.d.ts +7 -1
- package/lib/pt-button/pt-button.component.d.ts.map +1 -1
- package/lib/pt-dialog/pt-dialog.component.d.ts +18 -1
- package/lib/pt-dialog/pt-dialog.component.d.ts.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -636,6 +636,10 @@ export class FormBuilderTesterComponent implements OnInit {
|
|
|
636
636
|
|
|
637
637
|
## Changelog
|
|
638
638
|
|
|
639
|
+
### Version 1.0.31 - Release Date: 16/04/2025
|
|
640
|
+
|
|
641
|
+
- pt-advanced-table : Fixing the filters with asynchronous data and composed types.
|
|
642
|
+
|
|
639
643
|
### Version 1.0.30 - Release Date: 10/04/2025
|
|
640
644
|
|
|
641
645
|
- fixing the disabling btn in pt-login
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export {};
|
|
2
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYnV0dG9uLm1vZGVsLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvbmctcHJpbWUtdG9vbHMvc3JjL2xpYi9tb2RlbHMvYnV0dG9uLm1vZGVsLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiIiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgeyBTZXZlcml0eUVudW0gfSBmcm9tICcuLi9lbnVtcyc7XG5cbmV4cG9ydCBpbnRlcmZhY2UgQnV0dG9uTW9kZWwge1xuICBsYWJlbD86IHN0cmluZztcbiAgaWNvbj86IHN0cmluZztcbiAgaWNvblBvcz86ICdsZWZ0JyB8ICdyaWdodCc7XG4gIGRpc2FibGVkPzogYm9vbGVhbjtcbiAgc3R5bGVDbGFzcz86IHN0cmluZztcbiAgbG9hZGluZz86IGJvb2xlYW47XG4gIHR5cGU/OiAnYnV0dG9uJyB8ICdzdWJtaXQnIHwgJ3Jlc2V0JztcbiAgd2lkdGg/OiBzdHJpbmc7XG4gIGhlaWdodD86IHN0cmluZztcbiAgZm9udENvbG9yPzogc3RyaW5nO1xuICBiYWNrZ3JvdW5kQ29sb3I/
|
|
2
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYnV0dG9uLm1vZGVsLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvbmctcHJpbWUtdG9vbHMvc3JjL2xpYi9tb2RlbHMvYnV0dG9uLm1vZGVsLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiIiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgeyBTZXZlcml0eUVudW0gfSBmcm9tICcuLi9lbnVtcyc7XG5cbmV4cG9ydCBpbnRlcmZhY2UgQnV0dG9uTW9kZWwge1xuICBsYWJlbD86IHN0cmluZztcbiAgaWNvbj86IHN0cmluZztcbiAgaWNvblBvcz86ICdsZWZ0JyB8ICdyaWdodCc7XG4gIGRpc2FibGVkPzogYm9vbGVhbjtcbiAgc3R5bGVDbGFzcz86IHN0cmluZztcbiAgbG9hZGluZz86IGJvb2xlYW47XG4gIHR5cGU/OiAnYnV0dG9uJyB8ICdzdWJtaXQnIHwgJ3Jlc2V0JztcbiAgd2lkdGg/OiBzdHJpbmc7XG4gIGhlaWdodD86IHN0cmluZztcbiAgZm9udENvbG9yPzogc3RyaW5nO1xuICBiYWNrZ3JvdW5kQ29sb3I/OiBzdHJpbmc7XG4gIGJvcmRlckNvbG9yPzogc3RyaW5nO1xuICBzZXZlcml0eT86IFNldmVyaXR5RW51bTtcbiAgb3V0bGluZWQ/OiBib29sZWFuO1xufVxuIl19
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { Injectable } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export class DateUtilityService {
|
|
4
|
+
// Converts a date string (dd/mm/yyyy) to a Date object
|
|
5
|
+
convertToDate(dateString) {
|
|
6
|
+
if (dateString) {
|
|
7
|
+
const parts = dateString.split('/');
|
|
8
|
+
if (parts.length === 3) {
|
|
9
|
+
const day = parseInt(parts[0], 10);
|
|
10
|
+
const month = parseInt(parts[1], 10) - 1; // Month is 0-based
|
|
11
|
+
const year = parseInt(parts[2], 10);
|
|
12
|
+
const date = new Date(year, month, day);
|
|
13
|
+
return isNaN(date.getTime()) ? null : date;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
return null;
|
|
17
|
+
}
|
|
18
|
+
// Method to transform the data based on column type
|
|
19
|
+
transformDateFields(data, columns) {
|
|
20
|
+
return data.map((item) => {
|
|
21
|
+
const transformedItem = { ...item };
|
|
22
|
+
columns.forEach((col) => {
|
|
23
|
+
if (col.code &&
|
|
24
|
+
col.type === 'DATE' && // Make sure it's a date column
|
|
25
|
+
transformedItem[col.code]) {
|
|
26
|
+
transformedItem[col.code] =
|
|
27
|
+
this.convertToDate(transformedItem[col.code]) ||
|
|
28
|
+
transformedItem[col.code];
|
|
29
|
+
}
|
|
30
|
+
});
|
|
31
|
+
return transformedItem;
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: DateUtilityService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
35
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: DateUtilityService, providedIn: 'root' }); }
|
|
36
|
+
}
|
|
37
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: DateUtilityService, decorators: [{
|
|
38
|
+
type: Injectable,
|
|
39
|
+
args: [{
|
|
40
|
+
providedIn: 'root',
|
|
41
|
+
}]
|
|
42
|
+
}] });
|
|
43
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGF0ZS11dGlsaXR5LnNlcnZpY2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9uZy1wcmltZS10b29scy9zcmMvbGliL3B0LWFkdmFuY2VkLXByaW1lLXRhYmxlL2RhdGUtdXRpbGl0eS5zZXJ2aWNlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxVQUFVLEVB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