@sd-angular/core 1.3.201 → 1.3.203

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.
@@ -1227,11 +1227,11 @@
1227
1227
  this.cacheValues = {};
1228
1228
  _cacheObjValues.set(this, {});
1229
1229
  _initCellDef.set(this, function () {
1230
- var e_1, _10;
1230
+ var e_1, _8;
1231
1231
  _this.cellDef = {};
1232
1232
  try {
1233
- for (var _11 = __values(_this.sdCellDefs || []), _12 = _11.next(); !_12.done; _12 = _11.next()) {
1234
- var cellDef = _12.value;
1233
+ for (var _9 = __values(_this.sdCellDefs || []), _10 = _9.next(); !_10.done; _10 = _9.next()) {
1234
+ var cellDef = _10.value;
1235
1235
  if (cellDef.sdTableCellDef) {
1236
1236
  _this.cellDef[cellDef.sdTableCellDef] = cellDef;
1237
1237
  }
@@ -1240,35 +1240,35 @@
1240
1240
  catch (e_1_1) { e_1 = { error: e_1_1 }; }
1241
1241
  finally {
1242
1242
  try {
1243
- if (_12 && !_12.done && (_10 = _11.return)) _10.call(_11);
1243
+ if (_10 && !_10.done && (_8 = _9.return)) _8.call(_9);
1244
1244
  }
1245
1245
  finally { if (e_1) throw e_1.error; }
1246
1246
  }
1247
1247
  });
1248
1248
  _initFilterDef.set(this, function () {
1249
- var e_2, _10;
1249
+ var e_2, _8;
1250
1250
  _this.filterDefs = [];
1251
1251
  try {
1252
- for (var _11 = __values(_this.sdFilterDefs), _12 = _11.next(); !_12.done; _12 = _11.next()) {
1253
- var filterDef = _12.value;
1252
+ for (var _9 = __values(_this.sdFilterDefs), _10 = _9.next(); !_10.done; _10 = _9.next()) {
1253
+ var filterDef = _10.value;
1254
1254
  _this.filterDefs.push(filterDef);
1255
1255
  }
1256
1256
  }
1257
1257
  catch (e_2_1) { e_2 = { error: e_2_1 }; }
1258
1258
  finally {
1259
1259
  try {
1260
- if (_12 && !_12.done && (_10 = _11.return)) _10.call(_11);
1260
+ if (_10 && !_10.done && (_8 = _9.return)) _8.call(_9);
1261
1261
  }
1262
1262
  finally { if (e_2) throw e_2.error; }
1263
1263
  }
1264
1264
  });
1265
1265
  _initFooterDef.set(this, function () {
1266
- var e_3, _10;
1266
+ var e_3, _8;
1267
1267
  _this.footerDef = {};
1268
1268
  _this.hasFooter = false;
1269
1269
  try {
1270
- for (var _11 = __values(_this.sdFooterDefs), _12 = _11.next(); !_12.done; _12 = _11.next()) {
1271
- var footerDef = _12.value;
1270
+ for (var _9 = __values(_this.sdFooterDefs), _10 = _9.next(); !_10.done; _10 = _9.next()) {
1271
+ var footerDef = _10.value;
1272
1272
  if (footerDef.sdTableFooterDef) {
1273
1273
  _this.hasFooter = true;
1274
1274
  _this.footerDef[footerDef.sdTableFooterDef] = footerDef;
@@ -1278,14 +1278,14 @@
1278
1278
  catch (e_3_1) { e_3 = { error: e_3_1 }; }
1279
1279
  finally {
1280
1280
  try {
1281
- if (_12 && !_12.done && (_10 = _11.return)) _10.call(_11);
1281
+ if (_10 && !_10.done && (_8 = _9.return)) _8.call(_9);
1282
1282
  }
1283
1283
  finally { if (e_3) throw e_3.error; }
1284
1284
  }
1285
1285
  });
1286
1286
  _filterExportInfo.set(this, function (pageNumber, pageSize) {
1287
1287
  var _a, _b;
1288
- var _10 = _this.filterRegister.value.get(), columnOperator = _10.columnOperator, columnFilter = _10.columnFilter, externalFilter = _10.externalFilter, filterDef = _10.filterDef;
1288
+ var _8 = _this.filterRegister.value.get(), columnOperator = _8.columnOperator, columnFilter = _8.columnFilter, externalFilter = _8.externalFilter, filterDef = _8.filterDef;
1289
1289
  return {
1290
1290
  columnOperator: columnOperator || {},
1291
1291
  rawColumnFilter: columnFilter || {},
@@ -1299,7 +1299,7 @@
1299
1299
  };
1300
1300
  });
1301
1301
  _initConfiguration$1.set(this, function (option) {
1302
- var e_4, _10;
1302
+ var e_4, _8;
1303
1303
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7;
1304
1304
  // Init pagination
1305
1305
  option.paginate = {
@@ -1309,8 +1309,8 @@
1309
1309
  showFirstLastButtons: (_q = (_p = option === null || option === void 0 ? void 0 : option.paginate) === null || _p === void 0 ? void 0 : _p.showFirstLastButtons) !== null && _q !== void 0 ? _q : false,
1310
1310
  };
1311
1311
  try {
1312
- for (var _11 = __values(option.columns || []), _12 = _11.next(); !_12.done; _12 = _11.next()) {
1313
- var column = _12.value;
1312
+ for (var _9 = __values(option.columns || []), _10 = _9.next(); !_10.done; _10 = _9.next()) {
1313
+ var column = _10.value;
1314
1314
  if (((_s = (_r = column.filter) === null || _r === void 0 ? void 0 : _r.operator) === null || _s === void 0 ? void 0 : _s.enable) && !((_v = (_u = (_t = column.filter) === null || _t === void 0 ? void 0 : _t.operator) === null || _u === void 0 ? void 0 : _u.list) === null || _v === void 0 ? void 0 : _v.length)) {
1315
1315
  if (column.type === 'string') {
1316
1316
  column.filter.operator.list = ((_y = (_x = (_w = _this.tableConfiguration) === null || _w === void 0 ? void 0 : _w.filter) === null || _x === void 0 ? void 0 : _x.operator) === null || _y === void 0 ? void 0 : _y.defaultListString) || [];
@@ -1330,7 +1330,7 @@
1330
1330
  catch (e_4_1) { e_4 = { error: e_4_1 }; }
1331
1331
  finally {
1332
1332
  try {
1333
- if (_12 && !_12.done && (_10 = _11.return)) _10.call(_11);
1333
+ if (_10 && !_10.done && (_8 = _9.return)) _8.call(_9);
1334
1334
  }
1335
1335
  finally { if (e_4) throw e_4.error; }
1336
1336
  }
@@ -1369,7 +1369,7 @@
1369
1369
  var columns = _this.tableOption.columns;
1370
1370
  var rawColumnFilter = filterInfo.rawColumnFilter, orderBy = filterInfo.orderBy, orderDirection = filterInfo.orderDirection, pageSize = filterInfo.pageSize, pageNumber = filterInfo.pageNumber;
1371
1371
  var items = localItems.filter(function (tableItem) {
1372
- var e_5, _10;
1372
+ var e_5, _8;
1373
1373
  var _a, _b, _c, _d;
1374
1374
  var item = tableItem.data;
1375
1375
  try {
@@ -1450,7 +1450,7 @@
1450
1450
  catch (e_5_1) { e_5 = { error: e_5_1 }; }
1451
1451
  finally {
1452
1452
  try {
1453
- if (columns_1_1 && !columns_1_1.done && (_10 = columns_1.return)) _10.call(columns_1);
1453
+ if (columns_1_1 && !columns_1_1.done && (_8 = columns_1.return)) _8.call(columns_1);
1454
1454
  }
1455
1455
  finally { if (e_5) throw e_5.error; }
1456
1456
  }
@@ -1496,7 +1496,7 @@
1496
1496
  });
1497
1497
  _getFilter.set(this, function () {
1498
1498
  var _a, _b, _c, _d, _e, _f;
1499
- var _10 = _this.filterRegister.value.get(), columnOperator = _10.columnOperator, columnFilter = _10.columnFilter, externalFilter = _10.externalFilter, filterDef = _10.filterDef;
1499
+ var _8 = _this.filterRegister.value.get(), columnOperator = _8.columnOperator, columnFilter = _8.columnFilter, externalFilter = _8.externalFilter, filterDef = _8.filterDef;
1500
1500
  return {
1501
1501
  columnOperator: columnOperator || {},
1502
1502
  rawColumnFilter: columnFilter || {},
@@ -1511,10 +1511,10 @@
1511
1511
  _load.set(this, function (filterReq, force) {
1512
1512
  if (force === void 0) { force = true; }
1513
1513
  return __awaiter(_this, void 0, void 0, function () {
1514
- var items, data, _10, items, results, data, _11, _12;
1514
+ var items, data, _8, items, results, data, _9, _10;
1515
1515
  var _this = this;
1516
- return __generator(this, function (_13) {
1517
- switch (_13.label) {
1516
+ return __generator(this, function (_11) {
1517
+ switch (_11.label) {
1518
1518
  case 0:
1519
1519
  this.isLoading = true;
1520
1520
  this.ref.detectChanges();
@@ -1529,15 +1529,15 @@
1529
1529
  };
1530
1530
  })];
1531
1531
  case 1:
1532
- data = _13.sent();
1533
- _10 = {};
1532
+ data = _11.sent();
1533
+ _8 = {};
1534
1534
  return [4 /*yield*/, __classPrivateFieldGet(this, _format).call(this, data === null || data === void 0 ? void 0 : data.items, this.tableOption.columns).finally(function () {
1535
1535
  _this.isLoading = false;
1536
1536
  _this.ref.detectChanges();
1537
1537
  })];
1538
- case 2: return [2 /*return*/, (_10.items = _13.sent(),
1539
- _10.total = (data === null || data === void 0 ? void 0 : data.total) || 0,
1540
- _10)];
1538
+ case 2: return [2 /*return*/, (_8.items = _11.sent(),
1539
+ _8.total = (data === null || data === void 0 ? void 0 : data.total) || 0,
1540
+ _8)];
1541
1541
  case 3:
1542
1542
  if (!force) return [3 /*break*/, 8];
1543
1543
  items = this.tableOption.items;
@@ -1550,22 +1550,22 @@
1550
1550
  return [];
1551
1551
  })];
1552
1552
  case 4:
1553
- data = _13.sent();
1553
+ data = _11.sent();
1554
1554
  return [3 /*break*/, 6];
1555
1555
  case 5:
1556
1556
  data = results;
1557
- _13.label = 6;
1557
+ _11.label = 6;
1558
1558
  case 6:
1559
1559
  if (!Array.isArray(data)) {
1560
1560
  this.notifyService.notify.warning('Dữ liệu không phải là một mảng');
1561
1561
  data = [];
1562
1562
  }
1563
- _11 = __classPrivateFieldSet;
1564
- _12 = [this, _localItems];
1563
+ _9 = __classPrivateFieldSet;
1564
+ _10 = [this, _localItems];
1565
1565
  return [4 /*yield*/, __classPrivateFieldGet(this, _format).call(this, data, this.tableOption.columns)];
1566
1566
  case 7:
1567
- _11.apply(void 0, _12.concat([_13.sent()]));
1568
- _13.label = 8;
1567
+ _9.apply(void 0, _10.concat([_11.sent()]));
1568
+ _11.label = 8;
1569
1569
  case 8:
1570
1570
  this.isLoading = false;
1571
1571
  this.ref.detectChanges();
@@ -1576,15 +1576,15 @@
1576
1576
  });
1577
1577
  _render.set(this, function (args) { return __awaiter(_this, void 0, void 0, function () {
1578
1578
  var _a, _b, _c, _d;
1579
- return __generator(this, function (_10) {
1580
- switch (_10.label) {
1579
+ return __generator(this, function (_8) {
1580
+ switch (_8.label) {
1581
1581
  case 0:
1582
1582
  (_a = this.sdScroll) === null || _a === void 0 ? void 0 : _a.scrollTop();
1583
1583
  this.items = (args === null || args === void 0 ? void 0 : args.items) || [];
1584
1584
  this.total = (args === null || args === void 0 ? void 0 : args.total) || 0;
1585
1585
  return [4 /*yield*/, ((_d = (_c = (_b = this.tableOption) === null || _b === void 0 ? void 0 : _b.reload) === null || _c === void 0 ? void 0 : _c.onReload) === null || _d === void 0 ? void 0 : _d.call(_c, this.items))];
1586
1586
  case 1:
1587
- _10.sent();
1587
+ _8.sent();
1588
1588
  this.isSelectAll = this.items.every(function (e) { return e.meta.selector.isSelected; });
1589
1589
  __classPrivateFieldGet(this, _updateSelectedItems).call(this);
1590
1590
  return [2 /*return*/];
@@ -1595,13 +1595,13 @@
1595
1595
  if (force === void 0) { force = true; }
1596
1596
  return __awaiter(_this, void 0, void 0, function () {
1597
1597
  var _e, _f, data;
1598
- return __generator(this, function (_10) {
1599
- switch (_10.label) {
1598
+ return __generator(this, function (_8) {
1599
+ switch (_8.label) {
1600
1600
  case 0:
1601
1601
  (_f = (_e = this.tableFilter) === null || _e === void 0 ? void 0 : _e.updateFilter) === null || _f === void 0 ? void 0 : _f.call(_e);
1602
1602
  return [4 /*yield*/, __classPrivateFieldGet(this, _load).call(this, __classPrivateFieldGet(this, _getFilter).call(this), force)];
1603
1603
  case 1:
1604
- data = _10.sent();
1604
+ data = _8.sent();
1605
1605
  __classPrivateFieldGet(this, _render).call(this, data);
1606
1606
  return [2 /*return*/];
1607
1607
  }
@@ -1613,8 +1613,8 @@
1613
1613
  if (pageSize === void 0) { pageSize = 10000; }
1614
1614
  return __awaiter(_this, void 0, void 0, function () {
1615
1615
  var _g, _h, result, filterInfo, result, exportedItems, results;
1616
- return __generator(this, function (_10) {
1617
- switch (_10.label) {
1616
+ return __generator(this, function (_8) {
1617
+ switch (_8.label) {
1618
1618
  case 0:
1619
1619
  if (!((_g = this.tableOption.export) === null || _g === void 0 ? void 0 : _g.items)) return [3 /*break*/, 2];
1620
1620
  result = (_h = this.tableOption.export) === null || _h === void 0 ? void 0 : _h.items(__classPrivateFieldGet(this, _filterExportInfo).call(this, pageNumber, pageSize));
@@ -1628,13 +1628,13 @@
1628
1628
  result = result.toPromise();
1629
1629
  }
1630
1630
  return [4 /*yield*/, result];
1631
- case 1: return [2 /*return*/, _10.sent()];
1631
+ case 1: return [2 /*return*/, _8.sent()];
1632
1632
  case 2:
1633
1633
  filterInfo = __classPrivateFieldGet(this, _filterExportInfo).call(this, pageNumber, pageSize);
1634
1634
  if (!(this.tableOption.type === 'server')) return [3 /*break*/, 4];
1635
1635
  result = this.tableOption.items(filterInfo);
1636
1636
  return [4 /*yield*/, result];
1637
- case 3: return [2 /*return*/, _10.sent()];
1637
+ case 3: return [2 /*return*/, _8.sent()];
1638
1638
  case 4:
1639
1639
  exportedItems = [];
1640
1640
  if (!(typeof this.tableOption.items === 'function')) return [3 /*break*/, 8];
@@ -1642,15 +1642,15 @@
1642
1642
  if (!(results instanceof Promise)) return [3 /*break*/, 6];
1643
1643
  return [4 /*yield*/, results];
1644
1644
  case 5:
1645
- exportedItems = _10.sent();
1645
+ exportedItems = _8.sent();
1646
1646
  return [3 /*break*/, 7];
1647
1647
  case 6:
1648
1648
  exportedItems = results;
1649
- _10.label = 7;
1649
+ _8.label = 7;
1650
1650
  case 7: return [3 /*break*/, 9];
1651
1651
  case 8:
1652
1652
  exportedItems = this.tableOption.items;
1653
- _10.label = 9;
1653
+ _8.label = 9;
1654
1654
  case 9: return [2 /*return*/, __classPrivateFieldGet(this, _filterLocal).call(this, exportedItems, filterInfo)];
1655
1655
  }
1656
1656
  });
@@ -1677,13 +1677,13 @@
1677
1677
  return ((_b = (_a = _this.tableOption.export) === null || _a === void 0 ? void 0 : _a.columns) === null || _b === void 0 ? void 0 : _b.filter(function (e) { var _a; return !((_a = e.export) === null || _a === void 0 ? void 0 : _a.disabled); })) || [];
1678
1678
  });
1679
1679
  _onExport.set(this, function (isCSV) { return __awaiter(_this, void 0, void 0, function () {
1680
- var _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, columns_2, pageSize_1, batch, total_1, pageNumber_1, exportItems_1, items_1, promises_1, handleData, sheets, _10, _11, sheet, _12, _13, _14, e_6_1;
1681
- var e_6, _15;
1680
+ var _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, columns_2, pageSize_1, batch, total_1, pageNumber_1, exportItems_1, items_1, promises_1, handleData, sheets, _8, _9, sheet, _10, _11, _12, e_6_1;
1681
+ var e_6, _13;
1682
1682
  var _this = this;
1683
- return __generator(this, function (_16) {
1684
- switch (_16.label) {
1683
+ return __generator(this, function (_14) {
1684
+ switch (_14.label) {
1685
1685
  case 0:
1686
- _16.trys.push([0, , 18, 19]);
1686
+ _14.trys.push([0, , 18, 19]);
1687
1687
  columns_2 = __classPrivateFieldGet(this, _getExportColumns).call(this);
1688
1688
  pageSize_1 = ((_k = (_j = this.tableOption) === null || _j === void 0 ? void 0 : _j.export) === null || _k === void 0 ? void 0 : _k.maxItemsPerRequest) || 1000;
1689
1689
  batch = ((_m = (_l = this.tableOption) === null || _l === void 0 ? void 0 : _l.export) === null || _m === void 0 ? void 0 : _m.batch) || 1;
@@ -1695,13 +1695,13 @@
1695
1695
  promises_1 = [];
1696
1696
  handleData = function () { return __awaiter(_this, void 0, void 0, function () {
1697
1697
  var _u, results, results_1, results_1_1, result, results_2, totalPage, percent, allColumns, allExportedColumns, _loop_1, exportItems_2, exportItems_2_1, item, e_7_1;
1698
- var e_8, _10, e_7, _11;
1698
+ var e_8, _8, e_7, _9;
1699
1699
  var _this = this;
1700
- return __generator(this, function (_12) {
1701
- switch (_12.label) {
1700
+ return __generator(this, function (_10) {
1701
+ switch (_10.label) {
1702
1702
  case 0: return [4 /*yield*/, Promise.all(promises_1)];
1703
1703
  case 1:
1704
- results = _12.sent();
1704
+ results = _10.sent();
1705
1705
  promises_1 = [];
1706
1706
  exportItems_1 = [];
1707
1707
  try {
@@ -1719,7 +1719,7 @@
1719
1719
  catch (e_8_1) { e_8 = { error: e_8_1 }; }
1720
1720
  finally {
1721
1721
  try {
1722
- if (results_1_1 && !results_1_1.done && (_10 = results_1.return)) _10.call(results_1);
1722
+ if (results_1_1 && !results_1_1.done && (_8 = results_1.return)) _8.call(results_1);
1723
1723
  }
1724
1724
  finally { if (e_8) throw e_8.error; }
1725
1725
  }
@@ -1728,11 +1728,11 @@
1728
1728
  if (!(results_2 instanceof Promise)) return [3 /*break*/, 3];
1729
1729
  return [4 /*yield*/, results_2];
1730
1730
  case 2:
1731
- exportItems_1 = _12.sent();
1731
+ exportItems_1 = _10.sent();
1732
1732
  return [3 /*break*/, 4];
1733
1733
  case 3:
1734
1734
  exportItems_1 = results_2;
1735
- _12.label = 4;
1735
+ _10.label = 4;
1736
1736
  case 4:
1737
1737
  totalPage = total_1 / pageSize_1;
1738
1738
  percent = Math.round(((pageNumber_1 - 1) * 100.0) / totalPage);
@@ -1741,15 +1741,16 @@
1741
1741
  allExportedColumns = __classPrivateFieldGet(this, _allExportedColumns).call(this);
1742
1742
  _loop_1 = function (item) {
1743
1743
  var obj, handle, columns_3, columns_3_1, exportColumn, e_9_1;
1744
- var e_9, _10;
1745
- return __generator(this, function (_11) {
1746
- switch (_11.label) {
1744
+ var e_9, _8;
1745
+ return __generator(this, function (_9) {
1746
+ switch (_9.label) {
1747
1747
  case 0:
1748
1748
  obj = {};
1749
1749
  handle = function (exportColumn) { return __awaiter(_this, void 0, void 0, function () {
1750
- var _v, _w, _x, _y, _z, column, exportedColumn, transform, _10, _11, date, date, date;
1751
- return __generator(this, function (_12) {
1752
- switch (_12.label) {
1750
+ var _v, _w, _x, _y, _z, column, exportedColumn, transform, _8, _9, date, date, date, value, val, vals, vals;
1751
+ var _this = this;
1752
+ return __generator(this, function (_10) {
1753
+ switch (_10.label) {
1753
1754
  case 0:
1754
1755
  obj[exportColumn.field] = item[exportColumn.field];
1755
1756
  column = allColumns.find(function (e) { return e.field === exportColumn.field; });
@@ -1773,15 +1774,15 @@
1773
1774
  isExport: true,
1774
1775
  });
1775
1776
  if (!(transform instanceof Promise)) return [3 /*break*/, 2];
1776
- _10 = obj;
1777
- _11 = column.field;
1777
+ _8 = obj;
1778
+ _9 = column.field;
1778
1779
  return [4 /*yield*/, transform];
1779
1780
  case 1:
1780
- _10[_11] = _12.sent();
1781
+ _8[_9] = _10.sent();
1781
1782
  return [3 /*break*/, 3];
1782
1783
  case 2:
1783
1784
  obj[column.field] = transform;
1784
- _12.label = 3;
1785
+ _10.label = 3;
1785
1786
  case 3:
1786
1787
  obj[column.field] = (_v = obj[column.field]) !== null && _v !== void 0 ? _v : '';
1787
1788
  return [3 /*break*/, 5];
@@ -1818,41 +1819,48 @@
1818
1819
  obj[column.field] = Date.toFormat(date, 'HH:mm');
1819
1820
  }
1820
1821
  else if (column.type === 'values' || column.type === 'lazy-values') {
1821
- // Nếu là values thì lấy giá trị của value được chọn
1822
- obj[column.field] =
1823
- ((_z = (_y = __classPrivateFieldGet(this, _cacheObjValues)[column.field]) === null || _y === void 0 ? void 0 : _y[item[column.field]]) === null || _z === void 0 ? void 0 : _z[column.option.displayField]) || item[column.field];
1822
+ value = item[column.field];
1823
+ if (column.type === 'lazy-values' && typeof column.option.mapValue === 'function') {
1824
+ val = column.option.mapValue(value, item);
1825
+ vals = (Array.isArray(val) ? val : [val]).filter(function (e) { return !!(e === null || e === void 0 ? void 0 : e.toString()); });
1826
+ obj[column.field] = (_y = vals.map(function (val) { var _a, _b; return ((_b = (_a = __classPrivateFieldGet(_this, _cacheObjValues)[column.field]) === null || _a === void 0 ? void 0 : _a[val]) === null || _b === void 0 ? void 0 : _b[column.option.displayField]) || val; })) === null || _y === void 0 ? void 0 : _y.join(', ');
1827
+ }
1828
+ else {
1829
+ vals = (Array.isArray(value) ? value : [value]).filter(function (e) { return !!(e === null || e === void 0 ? void 0 : e.toString()); });
1830
+ obj[column.field] = (_z = vals.map(function (val) { var _a, _b; return ((_b = (_a = __classPrivateFieldGet(_this, _cacheObjValues)[column.field]) === null || _a === void 0 ? void 0 : _a[val]) === null || _b === void 0 ? void 0 : _b[column.option.displayField]) || val; })) === null || _z === void 0 ? void 0 : _z.join(', ');
1831
+ }
1824
1832
  }
1825
1833
  else {
1826
1834
  obj[column.field] = item[column.field];
1827
1835
  }
1828
- _12.label = 5;
1836
+ _10.label = 5;
1829
1837
  case 5: return [2 /*return*/];
1830
1838
  }
1831
1839
  });
1832
1840
  }); };
1833
- _11.label = 1;
1841
+ _9.label = 1;
1834
1842
  case 1:
1835
- _11.trys.push([1, 6, 7, 8]);
1843
+ _9.trys.push([1, 6, 7, 8]);
1836
1844
  columns_3 = (e_9 = void 0, __values(columns_2)), columns_3_1 = columns_3.next();
1837
- _11.label = 2;
1845
+ _9.label = 2;
1838
1846
  case 2:
1839
1847
  if (!!columns_3_1.done) return [3 /*break*/, 5];
1840
1848
  exportColumn = columns_3_1.value;
1841
1849
  return [4 /*yield*/, handle(exportColumn)];
1842
1850
  case 3:
1843
- _11.sent();
1844
- _11.label = 4;
1851
+ _9.sent();
1852
+ _9.label = 4;
1845
1853
  case 4:
1846
1854
  columns_3_1 = columns_3.next();
1847
1855
  return [3 /*break*/, 2];
1848
1856
  case 5: return [3 /*break*/, 8];
1849
1857
  case 6:
1850
- e_9_1 = _11.sent();
1858
+ e_9_1 = _9.sent();
1851
1859
  e_9 = { error: e_9_1 };
1852
1860
  return [3 /*break*/, 8];
1853
1861
  case 7:
1854
1862
  try {
1855
- if (columns_3_1 && !columns_3_1.done && (_10 = columns_3.return)) _10.call(columns_3);
1863
+ if (columns_3_1 && !columns_3_1.done && (_8 = columns_3.return)) _8.call(columns_3);
1856
1864
  }
1857
1865
  finally { if (e_9) throw e_9.error; }
1858
1866
  return [7 /*endfinally*/];
@@ -1862,29 +1870,29 @@
1862
1870
  }
1863
1871
  });
1864
1872
  };
1865
- _12.label = 5;
1873
+ _10.label = 5;
1866
1874
  case 5:
1867
- _12.trys.push([5, 10, 11, 12]);
1875
+ _10.trys.push([5, 10, 11, 12]);
1868
1876
  exportItems_2 = __values(exportItems_1), exportItems_2_1 = exportItems_2.next();
1869
- _12.label = 6;
1877
+ _10.label = 6;
1870
1878
  case 6:
1871
1879
  if (!!exportItems_2_1.done) return [3 /*break*/, 9];
1872
1880
  item = exportItems_2_1.value;
1873
1881
  return [5 /*yield**/, _loop_1(item)];
1874
1882
  case 7:
1875
- _12.sent();
1876
- _12.label = 8;
1883
+ _10.sent();
1884
+ _10.label = 8;
1877
1885
  case 8:
1878
1886
  exportItems_2_1 = exportItems_2.next();
1879
1887
  return [3 /*break*/, 6];
1880
1888
  case 9: return [3 /*break*/, 12];
1881
1889
  case 10:
1882
- e_7_1 = _12.sent();
1890
+ e_7_1 = _10.sent();
1883
1891
  e_7 = { error: e_7_1 };
1884
1892
  return [3 /*break*/, 12];
1885
1893
  case 11:
1886
1894
  try {
1887
- if (exportItems_2_1 && !exportItems_2_1.done && (_11 = exportItems_2.return)) _11.call(exportItems_2);
1895
+ if (exportItems_2_1 && !exportItems_2_1.done && (_9 = exportItems_2.return)) _9.call(exportItems_2);
1888
1896
  }
1889
1897
  finally { if (e_7) throw e_7.error; }
1890
1898
  return [7 /*endfinally*/];
@@ -1892,7 +1900,7 @@
1892
1900
  }
1893
1901
  });
1894
1902
  }); };
1895
- _16.label = 1;
1903
+ _14.label = 1;
1896
1904
  case 1:
1897
1905
  if (!(pageNumber_1 * pageSize_1 < total_1)) return [3 /*break*/, 3];
1898
1906
  promises_1.push(__classPrivateFieldGet(this, _exportedItems).call(this, pageNumber_1, pageSize_1));
@@ -1902,14 +1910,14 @@
1902
1910
  }
1903
1911
  return [4 /*yield*/, handleData()];
1904
1912
  case 2:
1905
- _16.sent();
1913
+ _14.sent();
1906
1914
  return [3 /*break*/, 1];
1907
1915
  case 3:
1908
1916
  if (!(promises_1.length > 0)) return [3 /*break*/, 5];
1909
1917
  return [4 /*yield*/, handleData()];
1910
1918
  case 4:
1911
- _16.sent();
1912
- _16.label = 5;
1919
+ _14.sent();
1920
+ _14.label = 5;
1913
1921
  case 5:
1914
1922
  if (!isCSV) return [3 /*break*/, 7];
1915
1923
  return [4 /*yield*/, this.exportService.exportCSV({
@@ -1918,19 +1926,19 @@
1918
1926
  fileName: (_p = (_o = this.tableOption) === null || _o === void 0 ? void 0 : _o.export) === null || _p === void 0 ? void 0 : _p.fileName,
1919
1927
  })];
1920
1928
  case 6:
1921
- _16.sent();
1929
+ _14.sent();
1922
1930
  return [2 /*return*/];
1923
1931
  case 7:
1924
1932
  sheets = [];
1925
1933
  if (!Array.isArray((_r = (_q = this.tableOption) === null || _q === void 0 ? void 0 : _q.export) === null || _r === void 0 ? void 0 : _r.sheets)) return [3 /*break*/, 16];
1926
- _16.label = 8;
1934
+ _14.label = 8;
1927
1935
  case 8:
1928
- _16.trys.push([8, 14, 15, 16]);
1929
- _10 = __values(this.tableOption.export.sheets), _11 = _10.next();
1930
- _16.label = 9;
1936
+ _14.trys.push([8, 14, 15, 16]);
1937
+ _8 = __values(this.tableOption.export.sheets), _9 = _8.next();
1938
+ _14.label = 9;
1931
1939
  case 9:
1932
- if (!!_11.done) return [3 /*break*/, 13];
1933
- sheet = _11.value;
1940
+ if (!!_9.done) return [3 /*break*/, 13];
1941
+ sheet = _9.value;
1934
1942
  if (!(sheet.name && sheet.items && sheet.fields)) return [3 /*break*/, 12];
1935
1943
  if (!Array.isArray(sheet.items)) return [3 /*break*/, 10];
1936
1944
  sheets.push({
@@ -1940,27 +1948,27 @@
1940
1948
  });
1941
1949
  return [3 /*break*/, 12];
1942
1950
  case 10:
1943
- _13 = (_12 = sheets).push;
1944
- _14 = {
1951
+ _11 = (_10 = sheets).push;
1952
+ _12 = {
1945
1953
  name: sheet.name
1946
1954
  };
1947
1955
  return [4 /*yield*/, sheet.items()];
1948
1956
  case 11:
1949
- _13.apply(_12, [(_14.items = _16.sent(),
1950
- _14.fields = sheet.fields,
1951
- _14)]);
1952
- _16.label = 12;
1957
+ _11.apply(_10, [(_12.items = _14.sent(),
1958
+ _12.fields = sheet.fields,
1959
+ _12)]);
1960
+ _14.label = 12;
1953
1961
  case 12:
1954
- _11 = _10.next();
1962
+ _9 = _8.next();
1955
1963
  return [3 /*break*/, 9];
1956
1964
  case 13: return [3 /*break*/, 16];
1957
1965
  case 14:
1958
- e_6_1 = _16.sent();
1966
+ e_6_1 = _14.sent();
1959
1967
  e_6 = { error: e_6_1 };
1960
1968
  return [3 /*break*/, 16];
1961
1969
  case 15:
1962
1970
  try {
1963
- if (_11 && !_11.done && (_15 = _10.return)) _15.call(_10);
1971
+ if (_9 && !_9.done && (_13 = _8.return)) _13.call(_8);
1964
1972
  }
1965
1973
  finally { if (e_6) throw e_6.error; }
1966
1974
  return [7 /*endfinally*/];
@@ -1971,7 +1979,7 @@
1971
1979
  sheets: sheets,
1972
1980
  })];
1973
1981
  case 17:
1974
- _16.sent();
1982
+ _14.sent();
1975
1983
  return [2 /*return*/];
1976
1984
  case 18:
1977
1985
  this.isExporting = false;
@@ -1999,7 +2007,7 @@
1999
2007
  });
2000
2008
  if (_this.configuration) {
2001
2009
  var columns_4 = __spread(gridColumns);
2002
- var _10 = _this.configuration, firstColumns = _10.firstColumns, secondColumns = _10.secondColumns;
2010
+ var _8 = _this.configuration, firstColumns = _8.firstColumns, secondColumns = _8.secondColumns;
2003
2011
  var displayColumns = __spread(firstColumns, secondColumns).reduce(function (first, next) {
2004
2012
  var column = _this.tableOption.columns.find(function (e) { return e.field === next.field; });
2005
2013
  if (!column) {
@@ -2034,7 +2042,7 @@
2034
2042
  };
2035
2043
  this.onExpand = function (rowData) { return __awaiter(_this, void 0, void 0, function () {
2036
2044
  var _0, _1, _2, _3, _4, data;
2037
- return __generator(this, function (_10) {
2045
+ return __generator(this, function (_8) {
2038
2046
  if ((_0 = this.tableOption.expand) === null || _0 === void 0 ? void 0 : _0.always) {
2039
2047
  return [2 /*return*/];
2040
2048
  }
@@ -2109,7 +2117,7 @@
2109
2117
  _this.filterRegister.value.remove();
2110
2118
  };
2111
2119
  this.setFilter = function (args) {
2112
- var _10 = args || {}, columnFilter = _10.columnFilter, externalFilter = _10.externalFilter, filterDef = _10.filterDef;
2120
+ var _8 = args || {}, columnFilter = _8.columnFilter, externalFilter = _8.externalFilter, filterDef = _8.filterDef;
2113
2121
  if (columnFilter) {
2114
2122
  _this.columnFilter = columnFilter;
2115
2123
  }
@@ -2122,9 +2130,9 @@
2122
2130
  this.detectChanges = function () { return _this.ref.detectChanges(); };
2123
2131
  _loadValues.set(this, function (columns) { return __awaiter(_this, void 0, void 0, function () {
2124
2132
  var promises, _loop_2, this_1, columns_5, columns_5_1, column, results, _loop_3, this_2, results_3, results_3_1, result;
2125
- var e_10, _10, e_11, _11;
2126
- return __generator(this, function (_12) {
2127
- switch (_12.label) {
2133
+ var e_10, _8, e_11, _9;
2134
+ return __generator(this, function (_10) {
2135
+ switch (_10.label) {
2128
2136
  case 0:
2129
2137
  promises = [];
2130
2138
  _loop_2 = function (column) {
@@ -2150,11 +2158,11 @@
2150
2158
  }
2151
2159
  else {
2152
2160
  this_1.cacheValues[column.field] = column.option.items.map(function (e) {
2153
- var _10;
2154
- return (_10 = {},
2155
- _10[column.option.valueField] = e === null || e === void 0 ? void 0 : e[column.option.valueField],
2156
- _10[column.option.displayField] = e === null || e === void 0 ? void 0 : e[column.option.displayField],
2157
- _10);
2161
+ var _8;
2162
+ return (_8 = {},
2163
+ _8[column.option.valueField] = e === null || e === void 0 ? void 0 : e[column.option.valueField],
2164
+ _8[column.option.displayField] = e === null || e === void 0 ? void 0 : e[column.option.displayField],
2165
+ _8);
2158
2166
  });
2159
2167
  __classPrivateFieldGet(this_1, _cacheObjValues)[column.field] = Array.toObject(this_1.cacheValues[column.field], column.option.valueField);
2160
2168
  }
@@ -2170,21 +2178,21 @@
2170
2178
  catch (e_10_1) { e_10 = { error: e_10_1 }; }
2171
2179
  finally {
2172
2180
  try {
2173
- if (columns_5_1 && !columns_5_1.done && (_10 = columns_5.return)) _10.call(columns_5);
2181
+ if (columns_5_1 && !columns_5_1.done && (_8 = columns_5.return)) _8.call(columns_5);
2174
2182
  }
2175
2183
  finally { if (e_10) throw e_10.error; }
2176
2184
  }
2177
2185
  if (!promises.length) return [3 /*break*/, 2];
2178
2186
  return [4 /*yield*/, Promise.all(promises)];
2179
2187
  case 1:
2180
- results = _12.sent();
2188
+ results = _10.sent();
2181
2189
  _loop_3 = function (result) {
2182
2190
  this_2.cacheValues[result.key] = result.data.map(function (e) {
2183
- var _10;
2184
- return (_10 = {},
2185
- _10[result.valueField] = e === null || e === void 0 ? void 0 : e[result.valueField],
2186
- _10[result.displayField] = e === null || e === void 0 ? void 0 : e[result.displayField],
2187
- _10);
2191
+ var _8;
2192
+ return (_8 = {},
2193
+ _8[result.valueField] = e === null || e === void 0 ? void 0 : e[result.valueField],
2194
+ _8[result.displayField] = e === null || e === void 0 ? void 0 : e[result.displayField],
2195
+ _8);
2188
2196
  });
2189
2197
  __classPrivateFieldGet(this_2, _cacheObjValues)[result.key] = Array.toObject(this_2.cacheValues[result.key], result.valueField);
2190
2198
  };
@@ -2198,32 +2206,32 @@
2198
2206
  catch (e_11_1) { e_11 = { error: e_11_1 }; }
2199
2207
  finally {
2200
2208
  try {
2201
- if (results_3_1 && !results_3_1.done && (_11 = results_3.return)) _11.call(results_3);
2209
+ if (results_3_1 && !results_3_1.done && (_9 = results_3.return)) _9.call(results_3);
2202
2210
  }
2203
2211
  finally { if (e_11) throw e_11.error; }
2204
2212
  }
2205
- _12.label = 2;
2213
+ _10.label = 2;
2206
2214
  case 2: return [2 /*return*/];
2207
2215
  }
2208
2216
  });
2209
2217
  }); });
2210
2218
  _format.set(this, function (rawItems, columns) { return __awaiter(_this, void 0, void 0, function () {
2211
- var _5, _6, _7, _8, _9, items, _loop_4, this_3, columns_6, columns_6_1, column, e_12_1;
2212
- var e_12, _10;
2219
+ var _5, _6, _7, items, _loop_4, this_3, columns_6, columns_6_1, column, e_12_1;
2220
+ var e_12, _8;
2213
2221
  var _this = this;
2214
- return __generator(this, function (_11) {
2215
- switch (_11.label) {
2222
+ return __generator(this, function (_9) {
2223
+ switch (_9.label) {
2216
2224
  case 0:
2217
2225
  items = rawItems.map(MapToSdTableItem);
2218
2226
  _loop_4 = function (column) {
2219
- var field, cellStyle, click, tooltip, htmlTemplate, transform, _10, views, mapValue_1, values_1, lazyItems, _loop_5, items_2, items_2_1, item, e_13_1;
2220
- var e_13, _11;
2221
- return __generator(this, function (_12) {
2222
- switch (_12.label) {
2227
+ var field, cellStyle, click, tooltip, htmlTemplate, transform, _8, views, mapValue_1, values_1, lazyItems, _loop_5, items_2, items_2_1, item, e_13_1;
2228
+ var e_13, _9;
2229
+ return __generator(this, function (_10) {
2230
+ switch (_10.label) {
2223
2231
  case 0:
2224
2232
  field = column.field, cellStyle = column.cellStyle, click = column.click, tooltip = column.tooltip, htmlTemplate = column.htmlTemplate, transform = column.transform;
2225
2233
  if (!(!transform && !htmlTemplate && column.type === 'lazy-values' && typeof column.option.views === 'function')) return [3 /*break*/, 2];
2226
- _10 = column.option, views = _10.views, mapValue_1 = _10.mapValue;
2234
+ _8 = column.option, views = _8.views, mapValue_1 = _8.mapValue;
2227
2235
  __classPrivateFieldGet(this_3, _cacheObjValues)[field] = __classPrivateFieldGet(this_3, _cacheObjValues)[field] || {};
2228
2236
  values_1 = items
2229
2237
  .map(function (item) {
@@ -2233,7 +2241,9 @@
2233
2241
  }
2234
2242
  return (_b = item.data) === null || _b === void 0 ? void 0 : _b[field];
2235
2243
  })
2236
- .filter(function (val) { return (!!val || val === 0) && !Object.keys(__classPrivateFieldGet(_this, _cacheObjValues)[field]).includes(val); })
2244
+ .filter(function (val) { return !!(val === null || val === void 0 ? void 0 : val.toString()); })
2245
+ .reduce(function (current, next) { return __spread(current, (Array.isArray(next) ? next : [next])); }, [])
2246
+ .filter(function (val) { return !Object.keys(__classPrivateFieldGet(_this, _cacheObjValues)[field]).includes(val); })
2237
2247
  .union();
2238
2248
  if (!values_1.length) return [3 /*break*/, 2];
2239
2249
  return [4 /*yield*/, views(values_1).catch(function (err) {
@@ -2241,22 +2251,22 @@
2241
2251
  return [];
2242
2252
  })];
2243
2253
  case 1:
2244
- lazyItems = (_12.sent())
2254
+ lazyItems = (_10.sent())
2245
2255
  .filter(function (item) { return values_1.includes(item === null || item === void 0 ? void 0 : item[column.option.valueField]); })
2246
2256
  .map(function (e) {
2247
- var _10;
2248
- return (_10 = {},
2249
- _10[column.option.valueField] = e === null || e === void 0 ? void 0 : e[column.option.valueField],
2250
- _10[column.option.displayField] = e === null || e === void 0 ? void 0 : e[column.option.displayField],
2251
- _10);
2257
+ var _8;
2258
+ return (_8 = {},
2259
+ _8[column.option.valueField] = e === null || e === void 0 ? void 0 : e[column.option.valueField],
2260
+ _8[column.option.displayField] = e === null || e === void 0 ? void 0 : e[column.option.displayField],
2261
+ _8);
2252
2262
  });
2253
2263
  Object.assign(__classPrivateFieldGet(this_3, _cacheObjValues)[field], Array.toObject(lazyItems, column.option.valueField) || {});
2254
- _12.label = 2;
2264
+ _10.label = 2;
2255
2265
  case 2:
2256
2266
  _loop_5 = function (item) {
2257
- var rowData, value, display, newValue, _10, date, time, option;
2258
- return __generator(this, function (_11) {
2259
- switch (_11.label) {
2267
+ var rowData, value, display, newValue, _8, date, time, val, vals, vals, option;
2268
+ return __generator(this, function (_9) {
2269
+ switch (_9.label) {
2260
2270
  case 0:
2261
2271
  rowData = item.data;
2262
2272
  value = rowData === null || rowData === void 0 ? void 0 : rowData[field];
@@ -2277,14 +2287,14 @@
2277
2287
  if (!(typeof transform === 'function')) return [3 /*break*/, 5];
2278
2288
  newValue = transform(value, rowData);
2279
2289
  if (!(newValue instanceof Promise)) return [3 /*break*/, 3];
2280
- _10 = display;
2290
+ _8 = display;
2281
2291
  return [4 /*yield*/, newValue];
2282
2292
  case 2:
2283
- _10.data = _11.sent();
2293
+ _8.data = _9.sent();
2284
2294
  return [3 /*break*/, 4];
2285
2295
  case 3:
2286
2296
  display.data = newValue;
2287
- _11.label = 4;
2297
+ _9.label = 4;
2288
2298
  case 4: return [3 /*break*/, 6];
2289
2299
  case 5:
2290
2300
  if (column.type === 'date' || column.type === 'datetime' || column.type === 'time') {
@@ -2308,10 +2318,13 @@
2308
2318
  }
2309
2319
  if (column.type === 'values' || column.type === 'lazy-values') {
2310
2320
  if (column.type === 'lazy-values' && typeof column.option.mapValue === 'function') {
2311
- display.data = ((_6 = (_5 = __classPrivateFieldGet(this_3, _cacheObjValues)[field]) === null || _5 === void 0 ? void 0 : _5[column.option.mapValue(value, rowData)]) === null || _6 === void 0 ? void 0 : _6[column.option.displayField]) || value;
2321
+ val = column.option.mapValue(value, rowData);
2322
+ vals = (Array.isArray(val) ? val : [val]).filter(function (e) { return !!(e === null || e === void 0 ? void 0 : e.toString()); });
2323
+ display.data = (_5 = vals.map(function (val) { var _a, _b; return ((_b = (_a = __classPrivateFieldGet(_this, _cacheObjValues)[field]) === null || _a === void 0 ? void 0 : _a[val]) === null || _b === void 0 ? void 0 : _b[column.option.displayField]) || val; })) === null || _5 === void 0 ? void 0 : _5.join(', ');
2312
2324
  }
2313
2325
  else {
2314
- display.data = ((_8 = (_7 = __classPrivateFieldGet(this_3, _cacheObjValues)[field]) === null || _7 === void 0 ? void 0 : _7[value]) === null || _8 === void 0 ? void 0 : _8[column.option.displayField]) || value;
2326
+ vals = (Array.isArray(value) ? value : [value]).filter(function (e) { return !!(e === null || e === void 0 ? void 0 : e.toString()); });
2327
+ display.data = (_6 = vals.map(function (val) { var _a, _b; return ((_b = (_a = __classPrivateFieldGet(_this, _cacheObjValues)[field]) === null || _a === void 0 ? void 0 : _a[val]) === null || _b === void 0 ? void 0 : _b[column.option.displayField]) || val; })) === null || _6 === void 0 ? void 0 : _6.join(', ');
2315
2328
  }
2316
2329
  }
2317
2330
  if (column.type === 'number' && Number.isNumber(value)) {
@@ -2331,7 +2344,7 @@
2331
2344
  display.badge = {
2332
2345
  type: !(column === null || column === void 0 ? void 0 : column.badgeType) ? 'icon' : column.badgeType,
2333
2346
  color: column.badge(value, rowData),
2334
- icon: (_9 = column.badgeIcon) === null || _9 === void 0 ? void 0 : _9.call(column, value, rowData),
2347
+ icon: (_7 = column.badgeIcon) === null || _7 === void 0 ? void 0 : _7.call(column, value, rowData),
2335
2348
  };
2336
2349
  }
2337
2350
  else if (column.type === 'bool') {
@@ -2341,34 +2354,34 @@
2341
2354
  icon: null,
2342
2355
  };
2343
2356
  }
2344
- _11.label = 6;
2357
+ _9.label = 6;
2345
2358
  case 6: return [2 /*return*/];
2346
2359
  }
2347
2360
  });
2348
2361
  };
2349
- _12.label = 3;
2362
+ _10.label = 3;
2350
2363
  case 3:
2351
- _12.trys.push([3, 8, 9, 10]);
2364
+ _10.trys.push([3, 8, 9, 10]);
2352
2365
  items_2 = (e_13 = void 0, __values(items)), items_2_1 = items_2.next();
2353
- _12.label = 4;
2366
+ _10.label = 4;
2354
2367
  case 4:
2355
2368
  if (!!items_2_1.done) return [3 /*break*/, 7];
2356
2369
  item = items_2_1.value;
2357
2370
  return [5 /*yield**/, _loop_5(item)];
2358
2371
  case 5:
2359
- _12.sent();
2360
- _12.label = 6;
2372
+ _10.sent();
2373
+ _10.label = 6;
2361
2374
  case 6:
2362
2375
  items_2_1 = items_2.next();
2363
2376
  return [3 /*break*/, 4];
2364
2377
  case 7: return [3 /*break*/, 10];
2365
2378
  case 8:
2366
- e_13_1 = _12.sent();
2379
+ e_13_1 = _10.sent();
2367
2380
  e_13 = { error: e_13_1 };
2368
2381
  return [3 /*break*/, 10];
2369
2382
  case 9:
2370
2383
  try {
2371
- if (items_2_1 && !items_2_1.done && (_11 = items_2.return)) _11.call(items_2);
2384
+ if (items_2_1 && !items_2_1.done && (_9 = items_2.return)) _9.call(items_2);
2372
2385
  }
2373
2386
  finally { if (e_13) throw e_13.error; }
2374
2387
  return [7 /*endfinally*/];
@@ -2377,29 +2390,29 @@
2377
2390
  });
2378
2391
  };
2379
2392
  this_3 = this;
2380
- _11.label = 1;
2393
+ _9.label = 1;
2381
2394
  case 1:
2382
- _11.trys.push([1, 6, 7, 8]);
2395
+ _9.trys.push([1, 6, 7, 8]);
2383
2396
  columns_6 = __values(columns), columns_6_1 = columns_6.next();
2384
- _11.label = 2;
2397
+ _9.label = 2;
2385
2398
  case 2:
2386
2399
  if (!!columns_6_1.done) return [3 /*break*/, 5];
2387
2400
  column = columns_6_1.value;
2388
2401
  return [5 /*yield**/, _loop_4(column)];
2389
2402
  case 3:
2390
- _11.sent();
2391
- _11.label = 4;
2403
+ _9.sent();
2404
+ _9.label = 4;
2392
2405
  case 4:
2393
2406
  columns_6_1 = columns_6.next();
2394
2407
  return [3 /*break*/, 2];
2395
2408
  case 5: return [3 /*break*/, 8];
2396
2409
  case 6:
2397
- e_12_1 = _11.sent();
2410
+ e_12_1 = _9.sent();
2398
2411
  e_12 = { error: e_12_1 };
2399
2412
  return [3 /*break*/, 8];
2400
2413
  case 7:
2401
2414
  try {
2402
- if (columns_6_1 && !columns_6_1.done && (_10 = columns_6.return)) _10.call(columns_6);
2415
+ if (columns_6_1 && !columns_6_1.done && (_8 = columns_6.return)) _8.call(columns_6);
2403
2416
  }
2404
2417
  finally { if (e_12) throw e_12.error; }
2405
2418
  return [7 /*endfinally*/];
@@ -2407,6 +2420,10 @@
2407
2420
  }
2408
2421
  });
2409
2422
  }); });
2423
+ this.onOperatorChange = function (column, operator) {
2424
+ var _a, _b, _c;
2425
+ (_c = (_b = (_a = _this.tableOption) === null || _a === void 0 ? void 0 : _a.filter) === null || _b === void 0 ? void 0 : _b.operatorChange) === null || _c === void 0 ? void 0 : _c.call(_b, column, operator);
2426
+ };
2410
2427
  this.trackBy = function (index, item) {
2411
2428
  return item.meta.id;
2412
2429
  };
@@ -2498,13 +2515,13 @@
2498
2515
  var _this = this;
2499
2516
  __classPrivateFieldGet(this, _subscription$1).add(__classPrivateFieldGet(this, _reload).pipe(operators.debounceTime(200), operators.switchMap(function (data) { return __awaiter(_this, void 0, void 0, function () {
2500
2517
  var filterInfo, result;
2501
- return __generator(this, function (_10) {
2502
- switch (_10.label) {
2518
+ return __generator(this, function (_8) {
2519
+ switch (_8.label) {
2503
2520
  case 0:
2504
2521
  filterInfo = __classPrivateFieldGet(this, _getFilter).call(this);
2505
2522
  return [4 /*yield*/, __classPrivateFieldGet(this, _load).call(this, filterInfo, !__classPrivateFieldGet(this, _loadCompleted) || data.force)];
2506
2523
  case 1:
2507
- result = _10.sent();
2524
+ result = _8.sent();
2508
2525
  __classPrivateFieldSet(this, _loadCompleted, true);
2509
2526
  return [2 /*return*/, result];
2510
2527
  }
@@ -2552,7 +2569,7 @@
2552
2569
  SdTable.decorators = [
2553
2570
  { type: core.Component, args: [{
2554
2571
  selector: 'sd-table',
2555
- template: "<ng-container *ngIf=\"configuration\">\r\n <sd-table-filter\r\n *ngIf=\"!tableOption.filter?.disabled && filterRegister\"\r\n [filterRegister]=\"filterRegister\"\r\n [filter]=\"tableOption?.filter\"\r\n [columns]=\"configuration.firstColumns\"\r\n [externalFilters]=\"tableOption?.filter?.externalFilters\"\r\n [filterDefs]=\"filterDefs\">\r\n </sd-table-filter>\r\n <ng-container *ngIf=\"items | sdGroup : tableOption; $implicit as groupedItems\">\r\n <div class=\"c-container\">\r\n <div class=\"c-loading\" *ngIf=\"isLoading\">\r\n <mat-spinner></mat-spinner>\r\n </div>\r\n <ng-container>\r\n <div\r\n class=\"c-table\"\r\n sdScroll\r\n [ngStyle]=\"{\r\n 'max-height': tableOption?.style?.maxHeight,\r\n 'min-height': tableOption?.style?.minHeight\r\n }\">\r\n <table mat-table [dataSource]=\"groupedItems\" [trackBy]=\"trackBy\" matSort [matSortDisabled]=\"!tableOption.sort?.enable\" multiTemplateDataRows>\r\n <ng-container matColumnDef=\"sdSubInformation\" sticky>\r\n <td class=\"p-0\" mat-cell *matCellDef=\"let item\" [attr.colspan]=\"configuration.displayedColumns.length\">\r\n <ng-container *ngIf=\"sdSubInformation?.templateRef\">\r\n <ng-container *ngIf=\"tableOption?.expand?.always; else useExpandCollapse\">\r\n <ng-container *ngTemplateOutlet=\"sdSubInformation.templateRef; context: { item: item }\"> </ng-container>\r\n </ng-container>\r\n <ng-template #useExpandCollapse>\r\n <div [@detailExpand]=\"item.isExpanded ? 'expanded' : 'collapsed'\">\r\n <ng-container *ngIf=\"item.isExpanded\">\r\n <ng-container *ngTemplateOutlet=\"sdSubInformation.templateRef; context: { item: item }\"> </ng-container>\r\n </ng-container>\r\n </div>\r\n </ng-template>\r\n </ng-container>\r\n </td>\r\n <td mat-footer-cell *matFooterCellDef></td>\r\n </ng-container>\r\n <ng-container matColumnDef=\"sdSubInformationAction\" stickyEnd>\r\n <th\r\n class=\"p-0\"\r\n mat-header-cell\r\n *matHeaderCellDef\r\n style=\"width: 1px\"\r\n [attr.rowspan]=\"configuration.multipleHeader ? 2 : 1\"></th>\r\n <td mat-cell *matCellDef=\"let element\">\r\n <button\r\n *ngIf=\"!element.isExpanding && !tableOption?.expand?.always\"\r\n mat-icon-button\r\n aria-label=\"Expand & Collapse\"\r\n (click)=\"onExpand(element)\">\r\n <mat-icon *ngIf=\"!element.isExpanded\">expand_more</mat-icon>\r\n <mat-icon *ngIf=\"element.isExpanded\">expand_less</mat-icon>\r\n </button>\r\n <div *ngIf=\"element.isExpanding\" class=\"lds-ring\">\r\n <div></div>\r\n <div></div>\r\n <div></div>\r\n <div></div>\r\n </div>\r\n </td>\r\n </ng-container>\r\n <ng-container matColumnDef=\"sdSelection\" sticky>\r\n <th\r\n class=\"text-center px-15\"\r\n mat-header-cell\r\n *matHeaderCellDef\r\n style=\"min-width: 50px; max-width: 50px\"\r\n [attr.rowspan]=\"configuration.multipleHeader ? 2 : 1\">\r\n <ng-container *ngIf=\"items | selectionVisibleSelectAll : tableOption?.selector | async\">\r\n <mat-checkbox\r\n *ngIf=\"!tableOption.selector?.single\"\r\n class=\"c-selection\"\r\n color=\"primary\"\r\n [(ngModel)]=\"isSelectAll\"\r\n (change)=\"onSelectAll()\">\r\n </mat-checkbox>\r\n </ng-container>\r\n </th>\r\n <td class=\"text-center px-15\" mat-cell *matCellDef=\"let item\" style=\"min-width: 50px; max-width: 50px\">\r\n <ng-container *ngIf=\"item | selectionVisible : tableOption?.selector\">\r\n <mat-checkbox\r\n class=\"c-selection\"\r\n color=\"primary\"\r\n [(ngModel)]=\"item.meta.selector.isSelected\"\r\n (change)=\"onSelect(item)\"\r\n [disabled]=\"selectedTableItems | selectionDisable : item : tableOption?.selector\">\r\n </mat-checkbox>\r\n </ng-container>\r\n </td>\r\n <td mat-footer-cell *matFooterCellDef></td>\r\n </ng-container>\r\n <ng-container matColumnDef=\"sdCommand\">\r\n <th\r\n class=\"px-8 py-8\"\r\n mat-header-cell\r\n *matHeaderCellDef\r\n style=\"width: 50px\"\r\n [attr.rowspan]=\"configuration.multipleHeader ? 2 : 1\"></th>\r\n <td class=\"px-8\" mat-cell *matCellDef=\"let item\">\r\n <sd-desktop-command [commands]=\"tableOption.commands\" [item]=\"item\"></sd-desktop-command>\r\n </td>\r\n <td mat-footer-cell *matFooterCellDef></td>\r\n </ng-container>\r\n <ng-container matColumnDef=\"sdGroup\">\r\n <th mat-header-cell *matHeaderCellDef class=\"px-8 py-8\" [attr.rowspan]=\"configuration.multipleHeader ? 2 : 1\"></th>\r\n <td class=\"p-0\" mat-cell *matCellDef=\"let item\" [attr.colspan]=\"!item?.sdGroup ? 1 : configuration.displayedColumns.length\">\r\n <div [innerHtml]=\"item?.sdGroup?.htmlTemplate | safeHtml\"></div>\r\n </td>\r\n <td mat-footer-cell *matFooterCellDef></td>\r\n </ng-container>\r\n <ng-container\r\n *ngFor=\"let column of configuration.firstColumns;\"\r\n [matColumnDef]=\"column.field\"\r\n [sticky]=\"configuration.fixedColumn[column.field]\">\r\n <th\r\n mat-header-cell\r\n *matHeaderCellDef\r\n class=\"px-8 py-8 c-th\"\r\n [ngStyle]=\"{ 'min-width': column.width }\"\r\n [attr.rowspan]=\"configuration.multipleHeader && column.type !== 'children-col' ? 2 : 1\"\r\n [attr.colspan]=\"column.type === 'children-col' ? column.children?.length : 1\">\r\n <div>\r\n <div\r\n aria-hidden=\"true\"\r\n mat-sort-header\r\n [disabled]=\"!column.sortable || column.type === 'children-col'\"\r\n [class.text-right]=\"column.align === 'right' || (!column.align && column.type === 'number')\"\r\n [class.text-center]=\"column.align === 'center'\"\r\n [innerHTML]=\"column.titleHtml || column.title\"></div>\r\n <sd-column-inline-filter\r\n *ngIf=\"!tableOption.filter?.disabled && !tableOption.filter?.hideInlineFilter && columnOperator\"\r\n [value]=\"columnFilter[column.field]\"\r\n [(inlineOperator)]=\"columnOperator[column.field]\"\r\n [columnFilter]=\"columnFilter\"\r\n [cacheValues]=\"cacheValues\"\r\n [column]=\"column\"\r\n (filterChange)=\"onFilterChange()\">\r\n </sd-column-inline-filter>\r\n </div>\r\n </th>\r\n <td class=\"c-td px-0\" mat-cell *matCellDef=\"let item\">\r\n <sd-desktop-cell\r\n class=\"d-block px-8\"\r\n *ngIf=\"!item?.sdGroup\"\r\n [value]=\"item[column.field]\"\r\n [column]=\"column\"\r\n [item]=\"item\"\r\n [cellDef]=\"cellDef\">\r\n </sd-desktop-cell>\r\n </td>\r\n <td mat-footer-cell *matFooterCellDef>\r\n <ng-container *ngIf=\"footerDef[column.field]\">\r\n <ng-container *ngTemplateOutlet=\"footerDef[column.field].templateRef; context: { items: items, column: column }\">\r\n </ng-container>\r\n </ng-container>\r\n </td>\r\n </ng-container>\r\n <ng-container *ngFor=\"let column of configuration.secondColumns\" [matColumnDef]=\"column.field\">\r\n <th mat-header-cell *matHeaderCellDef mat-sort-header class=\"c-th px-8\" [ngStyle]=\"{ 'min-width': column.width }\">\r\n <div>\r\n <div\r\n [class.text-right]=\"column.align === 'right' || (!column.align && column.type === 'number')\"\r\n [class.text-center]=\"column.align === 'center'\"\r\n [innerHTML]=\"column.titleHtml || column.title\"></div>\r\n <sd-column-inline-filter\r\n *ngIf=\"!tableOption.filter?.disabled && !tableOption.filter?.hideInlineFilter && columnOperator\"\r\n [value]=\"columnFilter[column.field]\"\r\n [(inlineOperator)]=\"columnOperator[column.field]\"\r\n [columnFilter]=\"columnFilter\"\r\n [cacheValues]=\"cacheValues\"\r\n [column]=\"column\"\r\n (filterChange)=\"onFilterChange()\">\r\n </sd-column-inline-filter>\r\n </div>\r\n </th>\r\n <td class=\"c-td px-0\" mat-cell *matCellDef=\"let item\">\r\n <sd-desktop-cell\r\n class=\"d-block px-8\"\r\n [value]=\"item[column.field]\"\r\n [column]=\"column\"\r\n [item]=\"item\"\r\n [cellDef]=\"cellDef\">\r\n </sd-desktop-cell>\r\n </td>\r\n <td mat-footer-cell *matFooterCellDef>\r\n <ng-container *ngIf=\"footerDef[column.field]\">\r\n <ng-container *ngTemplateOutlet=\"footerDef[column.field].templateRef; context: { items: items, column: column }\">\r\n </ng-container>\r\n </ng-container>\r\n </td>\r\n </ng-container>\r\n <tr class=\"c-first-header\" mat-header-row *matHeaderRowDef=\"configuration.firstHeaders; sticky: true\"></tr>\r\n <ng-container *ngIf=\"configuration.secondHeaders?.length\">\r\n <tr class=\"c-second-header\" mat-header-row *matHeaderRowDef=\"configuration.secondHeaders; sticky: true\"></tr>\r\n </ng-container>\r\n <tr\r\n mat-row\r\n *matRowDef=\"let row; columns: configuration.displayedColumns\"\r\n matRipple\r\n class=\"c-row\"\r\n [class.selected]=\"row.meta.selector.isSelected\"></tr>\r\n\r\n <tr mat-row *matRowDef=\"let row; columns: ['sdSubInformation']\" class=\"c-detail-row\"></tr>\r\n <ng-container *ngIf=\"hasFooter && configuration.displayedFooters?.length\">\r\n <tr mat-footer-row *matFooterRowDef=\"configuration.displayedFooters; sticky: true\"></tr>\r\n </ng-container>\r\n </table>\r\n </div>\r\n </ng-container>\r\n <div class=\"c-paginator\">\r\n <div class=\"c-action\">\r\n <sd-button\r\n *ngIf=\"tableOption.reload?.visible\"\r\n class=\"mr-8\"\r\n title=\"T\u1EA3i l\u1EA1i\"\r\n icon=\"refresh\"\r\n size=\"sm\"\r\n (action)=\"reload()\"\r\n [disabled]=\"!items?.length\"\r\n type=\"link\">\r\n </sd-button>\r\n <ng-container *ngIf=\"tableOption.export?.visible && items?.length\">\r\n <ng-container *ngIf=\"isExporting; else unExporting\">\r\n <sd-button class=\"mr-10\" [loading]=\"isExporting\" [title]=\"exportTitle | sdTranslate\" icon=\"get_app\" size=\"sm\" type=\"link\">\r\n </sd-button>\r\n </ng-container>\r\n <ng-template #unExporting>\r\n <sd-button class=\"mr-10\" [title]=\"exportTitle | sdTranslate\" icon=\"get_app\" size=\"sm\" [matMenuTriggerFor]=\"menu\" type=\"link\">\r\n </sd-button>\r\n </ng-template>\r\n <mat-menu #menu=\"matMenu\">\r\n <button mat-menu-item (click)=\"exportExcel()\" type=\"button\">\r\n <mat-icon fontSet=\"material-icons-outlined\">file_download</mat-icon>\r\n <span> Xu\u1EA5t excel</span>\r\n </button>\r\n <button mat-menu-item (click)=\"exportCSV()\" type=\"button\">\r\n <mat-icon fontSet=\"material-icons-outlined\">file_download</mat-icon>\r\n <span> Xu\u1EA5t CSV</span>\r\n </button>\r\n </mat-menu>\r\n </ng-container>\r\n <sd-button\r\n *ngIf=\"popupConfiguration\"\r\n class=\"mr-8\"\r\n [title]=\"'Configure' | sdTranslate\"\r\n icon=\"settings\"\r\n size=\"sm\"\r\n (action)=\"popupConfiguration.open()\"\r\n type=\"link\">\r\n </sd-button>\r\n </div>\r\n <mat-paginator\r\n [class.d-none]=\"tableOption.paginate?.hidden\"\r\n [length]=\"total\"\r\n [pageSize]=\"tableOption.paginate?.pageSize\"\r\n [pageSizeOptions]=\"tableOption.paginate?.pages\"\r\n [showFirstLastButtons]=\"tableOption.paginate?.showFirstLastButtons\"></mat-paginator>\r\n </div>\r\n </div>\r\n <sd-table-quick-action [tableOption]=\"tableOption\" [selectedTableItems]=\"selectedTableItems\" (clear)=\"onClearSelection(groupedItems)\">\r\n </sd-table-quick-action>\r\n <sd-popup-configuration *ngIf=\"tableOption?.key && tableOption.config?.visible\" [tableOption]=\"tableOption\"> </sd-popup-configuration>\r\n </ng-container>\r\n</ng-container>\r\n",
2572
+ template: "<ng-container *ngIf=\"configuration\">\r\n <sd-table-filter\r\n *ngIf=\"!tableOption.filter?.disabled && filterRegister\"\r\n [filterRegister]=\"filterRegister\"\r\n [filter]=\"tableOption?.filter\"\r\n [columns]=\"configuration.firstColumns\"\r\n [externalFilters]=\"tableOption?.filter?.externalFilters\"\r\n [filterDefs]=\"filterDefs\">\r\n </sd-table-filter>\r\n <ng-container *ngIf=\"items | sdGroup : tableOption; $implicit as groupedItems\">\r\n <div class=\"c-container\">\r\n <div class=\"c-loading\" *ngIf=\"isLoading\">\r\n <mat-spinner></mat-spinner>\r\n </div>\r\n <ng-container>\r\n <div\r\n class=\"c-table\"\r\n sdScroll\r\n [ngStyle]=\"{\r\n 'max-height': tableOption?.style?.maxHeight,\r\n 'min-height': tableOption?.style?.minHeight\r\n }\">\r\n <table mat-table [dataSource]=\"groupedItems\" [trackBy]=\"trackBy\" matSort [matSortDisabled]=\"!tableOption.sort?.enable\" multiTemplateDataRows>\r\n <ng-container matColumnDef=\"sdSubInformation\" sticky>\r\n <td class=\"p-0\" mat-cell *matCellDef=\"let item\" [attr.colspan]=\"configuration.displayedColumns.length\">\r\n <ng-container *ngIf=\"sdSubInformation?.templateRef\">\r\n <ng-container *ngIf=\"tableOption?.expand?.always; else useExpandCollapse\">\r\n <ng-container *ngTemplateOutlet=\"sdSubInformation.templateRef; context: { item: item }\"> </ng-container>\r\n </ng-container>\r\n <ng-template #useExpandCollapse>\r\n <div [@detailExpand]=\"item.isExpanded ? 'expanded' : 'collapsed'\">\r\n <ng-container *ngIf=\"item.isExpanded\">\r\n <ng-container *ngTemplateOutlet=\"sdSubInformation.templateRef; context: { item: item }\"> </ng-container>\r\n </ng-container>\r\n </div>\r\n </ng-template>\r\n </ng-container>\r\n </td>\r\n <td mat-footer-cell *matFooterCellDef></td>\r\n </ng-container>\r\n <ng-container matColumnDef=\"sdSubInformationAction\" stickyEnd>\r\n <th\r\n class=\"p-0\"\r\n mat-header-cell\r\n *matHeaderCellDef\r\n style=\"width: 1px\"\r\n [attr.rowspan]=\"configuration.multipleHeader ? 2 : 1\"></th>\r\n <td mat-cell *matCellDef=\"let element\">\r\n <button\r\n *ngIf=\"!element.isExpanding && !tableOption?.expand?.always\"\r\n mat-icon-button\r\n aria-label=\"Expand & Collapse\"\r\n (click)=\"onExpand(element)\">\r\n <mat-icon *ngIf=\"!element.isExpanded\">expand_more</mat-icon>\r\n <mat-icon *ngIf=\"element.isExpanded\">expand_less</mat-icon>\r\n </button>\r\n <div *ngIf=\"element.isExpanding\" class=\"lds-ring\">\r\n <div></div>\r\n <div></div>\r\n <div></div>\r\n <div></div>\r\n </div>\r\n </td>\r\n </ng-container>\r\n <ng-container matColumnDef=\"sdSelection\" sticky>\r\n <th\r\n class=\"text-center px-15\"\r\n mat-header-cell\r\n *matHeaderCellDef\r\n style=\"min-width: 50px; max-width: 50px\"\r\n [attr.rowspan]=\"configuration.multipleHeader ? 2 : 1\">\r\n <ng-container *ngIf=\"items | selectionVisibleSelectAll : tableOption?.selector | async\">\r\n <mat-checkbox\r\n *ngIf=\"!tableOption.selector?.single\"\r\n class=\"c-selection\"\r\n color=\"primary\"\r\n [(ngModel)]=\"isSelectAll\"\r\n (change)=\"onSelectAll()\">\r\n </mat-checkbox>\r\n </ng-container>\r\n </th>\r\n <td class=\"text-center px-15\" mat-cell *matCellDef=\"let item\" style=\"min-width: 50px; max-width: 50px\">\r\n <ng-container *ngIf=\"item | selectionVisible : tableOption?.selector\">\r\n <mat-checkbox\r\n class=\"c-selection\"\r\n color=\"primary\"\r\n [(ngModel)]=\"item.meta.selector.isSelected\"\r\n (change)=\"onSelect(item)\"\r\n [disabled]=\"selectedTableItems | selectionDisable : item : tableOption?.selector\">\r\n </mat-checkbox>\r\n </ng-container>\r\n </td>\r\n <td mat-footer-cell *matFooterCellDef></td>\r\n </ng-container>\r\n <ng-container matColumnDef=\"sdCommand\">\r\n <th\r\n class=\"px-8 py-8\"\r\n mat-header-cell\r\n *matHeaderCellDef\r\n style=\"width: 50px\"\r\n [attr.rowspan]=\"configuration.multipleHeader ? 2 : 1\"></th>\r\n <td class=\"px-8\" mat-cell *matCellDef=\"let item\">\r\n <sd-desktop-command [commands]=\"tableOption.commands\" [item]=\"item\"></sd-desktop-command>\r\n </td>\r\n <td mat-footer-cell *matFooterCellDef></td>\r\n </ng-container>\r\n <ng-container matColumnDef=\"sdGroup\">\r\n <th mat-header-cell *matHeaderCellDef class=\"px-8 py-8\" [attr.rowspan]=\"configuration.multipleHeader ? 2 : 1\"></th>\r\n <td class=\"p-0\" mat-cell *matCellDef=\"let item\" [attr.colspan]=\"!item?.sdGroup ? 1 : configuration.displayedColumns.length\">\r\n <div [innerHtml]=\"item?.sdGroup?.htmlTemplate | safeHtml\"></div>\r\n </td>\r\n <td mat-footer-cell *matFooterCellDef></td>\r\n </ng-container>\r\n <ng-container\r\n *ngFor=\"let column of configuration.firstColumns;\"\r\n [matColumnDef]=\"column.field\"\r\n [sticky]=\"configuration.fixedColumn[column.field]\">\r\n <th\r\n mat-header-cell\r\n *matHeaderCellDef\r\n class=\"px-8 py-8 c-th\"\r\n [ngStyle]=\"{ 'min-width': column.width }\"\r\n [attr.rowspan]=\"configuration.multipleHeader && column.type !== 'children-col' ? 2 : 1\"\r\n [attr.colspan]=\"column.type === 'children-col' ? column.children?.length : 1\">\r\n <div>\r\n <div\r\n aria-hidden=\"true\"\r\n mat-sort-header\r\n [disabled]=\"!column.sortable || column.type === 'children-col'\"\r\n [class.text-right]=\"column.align === 'right' || (!column.align && column.type === 'number')\"\r\n [class.text-center]=\"column.align === 'center'\"\r\n [innerHTML]=\"column.titleHtml || column.title\"></div>\r\n <sd-column-inline-filter\r\n *ngIf=\"!tableOption.filter?.disabled && !tableOption.filter?.hideInlineFilter && columnOperator\"\r\n [value]=\"columnFilter[column.field]\"\r\n [(inlineOperator)]=\"columnOperator[column.field]\"\r\n (operatorChange)=\"onOperatorChange(column, $event)\"\r\n [columnFilter]=\"columnFilter\"\r\n [cacheValues]=\"cacheValues\"\r\n [column]=\"column\"\r\n (filterChange)=\"onFilterChange()\">\r\n </sd-column-inline-filter>\r\n </div>\r\n </th>\r\n <td class=\"c-td px-0\" mat-cell *matCellDef=\"let item\">\r\n <sd-desktop-cell\r\n class=\"d-block px-8\"\r\n *ngIf=\"!item?.sdGroup\"\r\n [value]=\"item[column.field]\"\r\n [column]=\"column\"\r\n [item]=\"item\"\r\n [cellDef]=\"cellDef\">\r\n </sd-desktop-cell>\r\n </td>\r\n <td mat-footer-cell *matFooterCellDef>\r\n <ng-container *ngIf=\"footerDef[column.field]\">\r\n <ng-container *ngTemplateOutlet=\"footerDef[column.field].templateRef; context: { items: items, column: column }\">\r\n </ng-container>\r\n </ng-container>\r\n </td>\r\n </ng-container>\r\n <ng-container *ngFor=\"let column of configuration.secondColumns\" [matColumnDef]=\"column.field\">\r\n <th mat-header-cell *matHeaderCellDef mat-sort-header class=\"c-th px-8\" [ngStyle]=\"{ 'min-width': column.width }\">\r\n <div>\r\n <div\r\n [class.text-right]=\"column.align === 'right' || (!column.align && column.type === 'number')\"\r\n [class.text-center]=\"column.align === 'center'\"\r\n [innerHTML]=\"column.titleHtml || column.title\"></div>\r\n <sd-column-inline-filter\r\n *ngIf=\"!tableOption.filter?.disabled && !tableOption.filter?.hideInlineFilter && columnOperator\"\r\n [value]=\"columnFilter[column.field]\"\r\n [(inlineOperator)]=\"columnOperator[column.field]\"\r\n (operatorChange)=\"onOperatorChange(column, $event)\"\r\n [columnFilter]=\"columnFilter\"\r\n [cacheValues]=\"cacheValues\"\r\n [column]=\"column\"\r\n (filterChange)=\"onFilterChange()\">\r\n </sd-column-inline-filter>\r\n </div>\r\n </th>\r\n <td class=\"c-td px-0\" mat-cell *matCellDef=\"let item\">\r\n <sd-desktop-cell\r\n class=\"d-block px-8\"\r\n [value]=\"item[column.field]\"\r\n [column]=\"column\"\r\n [item]=\"item\"\r\n [cellDef]=\"cellDef\">\r\n </sd-desktop-cell>\r\n </td>\r\n <td mat-footer-cell *matFooterCellDef>\r\n <ng-container *ngIf=\"footerDef[column.field]\">\r\n <ng-container *ngTemplateOutlet=\"footerDef[column.field].templateRef; context: { items: items, column: column }\">\r\n </ng-container>\r\n </ng-container>\r\n </td>\r\n </ng-container>\r\n <tr class=\"c-first-header\" mat-header-row *matHeaderRowDef=\"configuration.firstHeaders; sticky: true\"></tr>\r\n <ng-container *ngIf=\"configuration.secondHeaders?.length\">\r\n <tr class=\"c-second-header\" mat-header-row *matHeaderRowDef=\"configuration.secondHeaders; sticky: true\"></tr>\r\n </ng-container>\r\n <tr\r\n mat-row\r\n *matRowDef=\"let row; columns: configuration.displayedColumns\"\r\n matRipple\r\n class=\"c-row\"\r\n [class.selected]=\"row.meta.selector.isSelected\"></tr>\r\n\r\n <tr mat-row *matRowDef=\"let row; columns: ['sdSubInformation']\" class=\"c-detail-row\"></tr>\r\n <ng-container *ngIf=\"hasFooter && configuration.displayedFooters?.length\">\r\n <tr mat-footer-row *matFooterRowDef=\"configuration.displayedFooters; sticky: true\"></tr>\r\n </ng-container>\r\n </table>\r\n </div>\r\n </ng-container>\r\n <div class=\"c-paginator\">\r\n <div class=\"c-action\">\r\n <sd-button\r\n *ngIf=\"tableOption.reload?.visible\"\r\n class=\"mr-8\"\r\n title=\"T\u1EA3i l\u1EA1i\"\r\n icon=\"refresh\"\r\n size=\"sm\"\r\n (action)=\"reload()\"\r\n [disabled]=\"!items?.length\"\r\n type=\"link\">\r\n </sd-button>\r\n <ng-container *ngIf=\"tableOption.export?.visible && items?.length\">\r\n <ng-container *ngIf=\"isExporting; else unExporting\">\r\n <sd-button class=\"mr-10\" [loading]=\"isExporting\" [title]=\"exportTitle | sdTranslate\" icon=\"get_app\" size=\"sm\" type=\"link\">\r\n </sd-button>\r\n </ng-container>\r\n <ng-template #unExporting>\r\n <sd-button class=\"mr-10\" [title]=\"exportTitle | sdTranslate\" icon=\"get_app\" size=\"sm\" [matMenuTriggerFor]=\"menu\" type=\"link\">\r\n </sd-button>\r\n </ng-template>\r\n <mat-menu #menu=\"matMenu\">\r\n <button mat-menu-item (click)=\"exportExcel()\" type=\"button\">\r\n <mat-icon fontSet=\"material-icons-outlined\">file_download</mat-icon>\r\n <span> Xu\u1EA5t excel</span>\r\n </button>\r\n <button mat-menu-item (click)=\"exportCSV()\" type=\"button\">\r\n <mat-icon fontSet=\"material-icons-outlined\">file_download</mat-icon>\r\n <span> Xu\u1EA5t CSV</span>\r\n </button>\r\n </mat-menu>\r\n </ng-container>\r\n <sd-button\r\n *ngIf=\"popupConfiguration\"\r\n class=\"mr-8\"\r\n [title]=\"'Configure' | sdTranslate\"\r\n icon=\"settings\"\r\n size=\"sm\"\r\n (action)=\"popupConfiguration.open()\"\r\n type=\"link\">\r\n </sd-button>\r\n </div>\r\n <mat-paginator\r\n [class.d-none]=\"tableOption.paginate?.hidden\"\r\n [length]=\"total\"\r\n [pageSize]=\"tableOption.paginate?.pageSize\"\r\n [pageSizeOptions]=\"tableOption.paginate?.pages\"\r\n [showFirstLastButtons]=\"tableOption.paginate?.showFirstLastButtons\"></mat-paginator>\r\n </div>\r\n </div>\r\n <sd-table-quick-action [tableOption]=\"tableOption\" [selectedTableItems]=\"selectedTableItems\" (clear)=\"onClearSelection(groupedItems)\">\r\n </sd-table-quick-action>\r\n <sd-popup-configuration *ngIf=\"tableOption?.key && tableOption.config?.visible\" [tableOption]=\"tableOption\"> </sd-popup-configuration>\r\n </ng-container>\r\n</ng-container>\r\n",
2556
2573
  changeDetection: core.ChangeDetectionStrategy.OnPush,
2557
2574
  animations: [
2558
2575
  animations.trigger('detailExpand', [
@@ -3262,6 +3279,7 @@
3262
3279
  this.inlineSymbol = 'filter_alt';
3263
3280
  _inlineOperator_1.set(this, void 0);
3264
3281
  this.inlineOperatorChange = new core.EventEmitter();
3282
+ this.operatorChange = new core.EventEmitter();
3265
3283
  this.columnFilter = {};
3266
3284
  this.operators = [];
3267
3285
  this.items = [];
@@ -3281,6 +3299,7 @@
3281
3299
  _this.inlineSymbol = 'filter_alt';
3282
3300
  }
3283
3301
  _this.inlineOperatorChange.emit(__classPrivateFieldGet(_this, _inlineOperator_1));
3302
+ _this.operatorChange.emit(__classPrivateFieldGet(_this, _inlineOperator_1));
3284
3303
  _this.ref.markForCheck();
3285
3304
  };
3286
3305
  }
@@ -3367,6 +3386,7 @@
3367
3386
  _value: [{ type: core.Input, args: ['value',] }],
3368
3387
  _inlineOperator: [{ type: core.Input, args: ['inlineOperator',] }],
3369
3388
  inlineOperatorChange: [{ type: core.Output }],
3389
+ operatorChange: [{ type: core.Output }],
3370
3390
  _columnFilter: [{ type: core.Input, args: ['columnFilter',] }],
3371
3391
  cacheValues: [{ type: core.Input }],
3372
3392
  _column: [{ type: core.Input, args: ['column',] }],