@churchillliving/se-ui-toolkit 6.53.251 → 6.53.252

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.
@@ -2538,9 +2538,9 @@
2538
2538
  GridService.prototype.getAllowSaveRowlist = function (rowsData, columns) {
2539
2539
  var _this = this;
2540
2540
  if (rowsData === void 0) { rowsData = []; }
2541
+ rowsData = this.setDataFields(rowsData);
2541
2542
  columns.forEach(function (column) {
2542
2543
  if (column.allowSave === false) {
2543
- rowsData = _this.setDataFields(rowsData);
2544
2544
  rowsData.forEach(function (row) {
2545
2545
  var _a;
2546
2546
  var obj = Object.keys(row);
@@ -2555,17 +2555,28 @@
2555
2555
  row = _this.setRowValue(row);
2556
2556
  });
2557
2557
  }
2558
+ else if (column.formatter && column.type === exports.EGridColumnType.BOOLEAN) {
2559
+ rowsData.forEach(function (row) {
2560
+ if (column.formatter === 'char') {
2561
+ row[column.field.toLowerCase()] = row[column.field.toLowerCase()] === true ? 'Y' : 'N';
2562
+ }
2563
+ else if (column.formatter === 'numeric') {
2564
+ row[column.field.toLowerCase()] = row[column.field.toLowerCase()] === true ? '1' : '0';
2565
+ }
2566
+ });
2567
+ }
2558
2568
  });
2559
2569
  return rowsData;
2560
2570
  };
2561
2571
  // get allowSave true || undefine row
2562
2572
  GridService.prototype.getAllowSaveRow = function (rowInfo, columns) {
2563
- var _this = this;
2564
2573
  if (rowInfo === void 0) { rowInfo = {}; }
2565
2574
  var row = Object.assign({}, rowInfo);
2575
+ row = objConvertToLower(row);
2576
+ console.log('rowsss: ', row);
2577
+ row = this.setRowValue(row);
2566
2578
  columns.forEach(function (column) {
2567
2579
  if (column.allowSave == false) {
2568
- row = _this.setRowValue(row);
2569
2580
  var keys = Object.keys(row);
2570
2581
  keys.forEach(function (x) {
2571
2582
  if (x.includes('_obj') && typeof row[x] === 'object') {
@@ -2577,8 +2588,15 @@
2577
2588
  delete row[key];
2578
2589
  }
2579
2590
  }
2591
+ else if (column.formatter && column.type === exports.EGridColumnType.BOOLEAN) {
2592
+ if (column.formatter === 'char') {
2593
+ row[column.field.toLowerCase()] = row[column.field.toLowerCase()] === true ? 'Y' : 'N';
2594
+ }
2595
+ else if (column.formatter === 'numeric') {
2596
+ row[column.field.toLowerCase()] = row[column.field.toLowerCase()] === true ? '1' : '0';
2597
+ }
2598
+ }
2580
2599
  });
2581
- row = this.setRowValue(row);
2582
2600
  return row;
2583
2601
  };
2584
2602
  // add simple grid column without