@cdmx/wappler_ag_grid 0.5.6 → 0.5.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/app_connect/components.hjson +8 -0
- package/dmx-ag-grid.js +6 -2
- package/package.json +1 -1
|
@@ -438,6 +438,14 @@
|
|
|
438
438
|
"defaultValue": false,
|
|
439
439
|
"help": "Hides the ID Field in Grid"
|
|
440
440
|
},
|
|
441
|
+
{
|
|
442
|
+
"name": "numericColumnAlign",
|
|
443
|
+
"attribute": "dmx-bind:numeric_column_align",
|
|
444
|
+
"title": "Right Align Numeric Columns",
|
|
445
|
+
"type": "boolean",
|
|
446
|
+
"defaultValue": false,
|
|
447
|
+
"help": "Align numeric columns to the right."
|
|
448
|
+
},
|
|
441
449
|
{
|
|
442
450
|
"name": "rowClickEvent",
|
|
443
451
|
"attribute": "dmx-bind:row_click_event",
|
package/dmx-ag-grid.js
CHANGED
|
@@ -38,6 +38,7 @@ dmx.Component('ag-grid', {
|
|
|
38
38
|
suppress_scroll_on_new_data: { type: Boolean, default: false },
|
|
39
39
|
suppress_property_names_check: { type: Boolean, default: false },
|
|
40
40
|
hide_id_field: { type: Boolean, default: false },
|
|
41
|
+
numeric_column_align: { type: Boolean, default: false },
|
|
41
42
|
enable_rtl: { type: Boolean, default: false },
|
|
42
43
|
locale_text: { type: String, default: null },
|
|
43
44
|
date_locale: { type: String, default: 'en-IN' },
|
|
@@ -421,7 +422,6 @@ dmx.Component('ag-grid', {
|
|
|
421
422
|
}
|
|
422
423
|
}
|
|
423
424
|
if (options.amount_fields && options.amount_fields.includes(key)) {
|
|
424
|
-
console.log(parseFloat(value))
|
|
425
425
|
return parseFloat(value)
|
|
426
426
|
}
|
|
427
427
|
|
|
@@ -538,9 +538,12 @@ dmx.Component('ag-grid', {
|
|
|
538
538
|
let minWidth;
|
|
539
539
|
let hide;
|
|
540
540
|
let colId;
|
|
541
|
-
|
|
541
|
+
|
|
542
542
|
if (dataType === 'number') {
|
|
543
543
|
filter = 'agNumberColumnFilter';
|
|
544
|
+
if (options.numeric_column_align){
|
|
545
|
+
type = 'numericColumn';
|
|
546
|
+
}
|
|
544
547
|
if (options.amount_fields && options.amount_fields.includes(key)) {
|
|
545
548
|
valueFormatter = function (params) {
|
|
546
549
|
if (params.value != null) {
|
|
@@ -696,6 +699,7 @@ dmx.Component('ag-grid', {
|
|
|
696
699
|
valueGetter: valueGetter,
|
|
697
700
|
minWidth: minWidth,
|
|
698
701
|
hide: hide,
|
|
702
|
+
type: type,
|
|
699
703
|
sortable: sortable,
|
|
700
704
|
filterValueGetter: filterValueGetter,
|
|
701
705
|
filterParams: filterParams,
|