fantasy-ngzorro 2.2.13 → 2.2.15

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.
@@ -1478,6 +1478,29 @@
1478
1478
  }
1479
1479
  return max;
1480
1480
  }
1481
+ /**
1482
+ * 用于判断是否需要 scroll.x 的视口宽。
1483
+ * 有纵向滚动条时 clientWidth 会少一截,若直接拿去比列宽,会「竖滚条导致误开横滚」;
1484
+ * 这里用 offsetWidth(含滚动条槽)作为屏幕可展示宽度。
1485
+ * @param {?} nzTable
1486
+ * @param {?=} hostClass
1487
+ * @return {?}
1488
+ */
1489
+ function getTableScrollXViewportWidth(nzTable, hostClass) {
1490
+ if (hostClass === void 0) { hostClass = "hd-table-container"; }
1491
+ if (!nzTable || !nzTable.tableMainElement) {
1492
+ return 0;
1493
+ }
1494
+ /** @type {?} */
1495
+ var tableMain = (/** @type {?} */ (nzTable.tableMainElement.nativeElement));
1496
+ /** @type {?} */
1497
+ var scrollBody = ((/** @type {?} */ (tableMain.querySelector("cdk-virtual-scroll-viewport.ant-table-body")))) ||
1498
+ ((/** @type {?} */ (tableMain.querySelector(".ant-table-body"))));
1499
+ if (scrollBody && scrollBody.offsetWidth > 0) {
1500
+ return scrollBody.offsetWidth;
1501
+ }
1502
+ return getTableViewportWidth(nzTable, hostClass);
1503
+ }
1481
1504
  /**
1482
1505
  * 无数据或列宽未超出容器时不启用横向 scroll
1483
1506
  * @param {?} nzTable
@@ -1497,9 +1520,10 @@
1497
1520
  return null;
1498
1521
  }
1499
1522
  /** @type {?} */
1500
- var viewportWidth = getTableViewportWidth(nzTable);
1523
+ var viewportWidth = getTableScrollXViewportWidth(nzTable);
1501
1524
  if (viewportWidth > 0) {
1502
- return width > viewportWidth ? { x: Math.ceil(width) + "px" } : null;
1525
+ // 允许 1px 误差,避免亚像素导致误开横滚
1526
+ return width > viewportWidth + 1 ? { x: Math.ceil(width) + "px" } : null;
1503
1527
  }
1504
1528
  if (typeof window !== "undefined" && width > window.innerWidth - 32) {
1505
1529
  return { x: Math.ceil(width) + "px" };
@@ -10545,19 +10569,6 @@
10545
10569
  /** @type {?} */
10546
10570
  OperateBtn.prototype.permission;
10547
10571
  }
10548
- var HdTableTotalOption = /** @class */ (function () {
10549
- function HdTableTotalOption() {
10550
- }
10551
- return HdTableTotalOption;
10552
- }());
10553
- if (false) {
10554
- /** @type {?} */
10555
- HdTableTotalOption.prototype.columnNumber;
10556
- /** @type {?} */
10557
- HdTableTotalOption.prototype.insertIndex;
10558
- /** @type {?} */
10559
- HdTableTotalOption.prototype.insertName;
10560
- }
10561
10572
  var TableCacheOption = /** @class */ (function () {
10562
10573
  function TableCacheOption() {
10563
10574
  this.colWidths = new Map(); // name -> width
@@ -10609,8 +10620,9 @@
10609
10620
  * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
10610
10621
  */
10611
10622
  var HdTableComponent = /** @class */ (function () {
10612
- function HdTableComponent(cdr, commonSessionService) {
10623
+ function HdTableComponent(hostEl, cdr, commonSessionService) {
10613
10624
  var _this = this;
10625
+ this.hostEl = hostEl;
10614
10626
  this.cdr = cdr;
10615
10627
  this.commonSessionService = commonSessionService;
10616
10628
  this.tableCols = [];
@@ -10618,7 +10630,7 @@
10618
10630
  this.showOperateColWarpButton = false;
10619
10631
  this.virtualScroll = true;
10620
10632
  this.selectField = "billNumber";
10621
- // 合计区域
10633
+ // 合计区域(类型与 hd-detail-lines 的 TotalOption 一致)
10622
10634
  this.showTableTotal = false;
10623
10635
  this.sortEvent = new core.EventEmitter();
10624
10636
  this.selectEvent = new core.EventEmitter();
@@ -10683,8 +10695,9 @@
10683
10695
  * 记录当前是否处于虚拟滚动模式,用于切换 pageSize 时重建表格
10684
10696
  */
10685
10697
  this.virtualScrollActive = null;
10698
+ /** 可见列总宽,用于判断是否需要横向滚动 */
10686
10699
  /**
10687
- * 可见列总宽,用于判断是否需要横向滚动
10700
+ * 列宽合计(含勾选/序号),footer 表宽与横向 scroll 共用
10688
10701
  */
10689
10702
  this.tableColWidthTotal = 0;
10690
10703
  /**
@@ -10696,6 +10709,24 @@
10696
10709
  */
10697
10710
  this.currentSortKey = null;
10698
10711
  this.currentSortValue = null;
10712
+ this.totalFooterScrollBoundBody = null;
10713
+ this.totalFooterScrollHandler = null;
10714
+ this.totalFooterSyncRetry = 0;
10715
+ /**
10716
+ * 表体有竖滚条时合计 footer 才预留右侧滚动条槽
10717
+ */
10718
+ this.totalFooterNeedYGutter = false;
10719
+ /**
10720
+ * 视口/容器尺寸变化时重算 scroll.x 与合计对齐
10721
+ */
10722
+ this.viewportResizeTimer = null;
10723
+ this.boundOnViewportResize = null;
10724
+ this.hostResizeObserver = null;
10725
+ /**
10726
+ * 序号列固定宽(含 padding,可容纳 6 位如 199995)。
10727
+ * 不锁死时表体会随位数变宽(1→~64px,199995→~67px),合计行对不齐。
10728
+ */
10729
+ this.lineNumberColWidth = 72;
10699
10730
  this.trackByRow = (/**
10700
10731
  * @param {?} index
10701
10732
  * @param {?} data
@@ -10775,6 +10806,16 @@
10775
10806
  storeName: "hd-fscm-store",
10776
10807
  });
10777
10808
  }
10809
+ /**
10810
+ * @return {?}
10811
+ */
10812
+ HdTableComponent.prototype.ngOnDestroy = /**
10813
+ * @return {?}
10814
+ */
10815
+ function () {
10816
+ this.unbindTotalFooterScrollSync();
10817
+ this.unbindViewportResizeSync();
10818
+ };
10778
10819
  /**
10779
10820
  * @return {?}
10780
10821
  */
@@ -10800,6 +10841,7 @@
10800
10841
  userCode: "dev",
10801
10842
  };
10802
10843
  }
10844
+ this.bindViewportResizeSync();
10803
10845
  this.deleteHideItem();
10804
10846
  if (!this.tableCols || this.tableCols.length === 0) {
10805
10847
  return;
@@ -10831,6 +10873,13 @@
10831
10873
  */
10832
10874
  function (changes) {
10833
10875
  var _this = this;
10876
+ if (changes["tableData"] ||
10877
+ changes["tableTotalOption"] ||
10878
+ changes["showTableTotal"] ||
10879
+ changes["columnsNumber"] ||
10880
+ changes["tableCols"]) {
10881
+ this.calculateTableTotal();
10882
+ }
10834
10883
  if (changes &&
10835
10884
  changes["tableData"] &&
10836
10885
  changes["tableData"]["currentValue"] &&
@@ -11096,6 +11145,83 @@
11096
11145
  function (col) {
11097
11146
  return col.fixed === "left" ? (col.fixedWidth || 0) + "px" : null;
11098
11147
  };
11148
+ Object.defineProperty(HdTableComponent.prototype, "lineNumberLeft", {
11149
+ /** 开启合计时序号列的 left(勾选列占 40px) */
11150
+ get: /**
11151
+ * 开启合计时序号列的 left(勾选列占 40px)
11152
+ * @return {?}
11153
+ */
11154
+ function () {
11155
+ return this.showSelected ? "40px" : "0px";
11156
+ },
11157
+ enumerable: true,
11158
+ configurable: true
11159
+ });
11160
+ Object.defineProperty(HdTableComponent.prototype, "lineNumberColWidthPx", {
11161
+ get: /**
11162
+ * @return {?}
11163
+ */
11164
+ function () {
11165
+ return this.lineNumberColWidth + "px";
11166
+ },
11167
+ enumerable: true,
11168
+ configurable: true
11169
+ });
11170
+ Object.defineProperty(HdTableComponent.prototype, "isTotalFooterFluid", {
11171
+ /**
11172
+ * 列总宽未超出容器:无横向 scroll,表体列会被撑满,合计走 fluid(width:100%)。
11173
+ * 列总宽超出:有 scroll.x,合计走固定表宽 + 横滚同步。
11174
+ */
11175
+ get: /**
11176
+ * 列总宽未超出容器:无横向 scroll,表体列会被撑满,合计走 fluid(width:100%)。
11177
+ * 列总宽超出:有 scroll.x,合计走固定表宽 + 横滚同步。
11178
+ * @return {?}
11179
+ */
11180
+ function () {
11181
+ return !(this.scroll && this.scroll.x);
11182
+ },
11183
+ enumerable: true,
11184
+ configurable: true
11185
+ });
11186
+ Object.defineProperty(HdTableComponent.prototype, "totalFooterTableWidth", {
11187
+ /** fluid → 100%;固定 → scroll.x(与表体同一套横向宽度) */
11188
+ get: /**
11189
+ * fluid → 100%;固定 → scroll.x(与表体同一套横向宽度)
11190
+ * @return {?}
11191
+ */
11192
+ function () {
11193
+ if (this.isTotalFooterFluid) {
11194
+ return "100%";
11195
+ }
11196
+ return this.scroll && this.scroll.x
11197
+ ? String(this.scroll.x)
11198
+ : this.tableColWidthTotal > 0
11199
+ ? this.tableColWidthTotal + "px"
11200
+ : "100%";
11201
+ },
11202
+ enumerable: true,
11203
+ configurable: true
11204
+ });
11205
+ /** 当前页行号(跨页连续,从 1 开始) */
11206
+ /**
11207
+ * 当前页行号(跨页连续,从 1 开始)
11208
+ * @param {?} index
11209
+ * @return {?}
11210
+ */
11211
+ HdTableComponent.prototype.getLineNumber = /**
11212
+ * 当前页行号(跨页连续,从 1 开始)
11213
+ * @param {?} index
11214
+ * @return {?}
11215
+ */
11216
+ function (index) {
11217
+ /** @type {?} */
11218
+ var page = Number(this.tablePageIndex) > 0 ? Number(this.tablePageIndex) : 1;
11219
+ /** @type {?} */
11220
+ var size = Number(this.tablePageSize) > 0 ? Number(this.tablePageSize) : 0;
11221
+ /** @type {?} */
11222
+ var rowIndex = Number(index) >= 0 ? Number(index) : 0;
11223
+ return (page - 1) * size + rowIndex + 1;
11224
+ };
11099
11225
  /**
11100
11226
  * @return {?}
11101
11227
  */
@@ -11956,6 +12082,7 @@
11956
12082
  * @return {?}
11957
12083
  */
11958
12084
  function (_a, col) {
12085
+ var _this = this;
11959
12086
  var width = _a.width;
11960
12087
  this.normalizeTableCacheOption();
11961
12088
  /** @type {?} */
@@ -11977,6 +12104,10 @@
11977
12104
  }));
11978
12105
  this.dealScroll();
11979
12106
  this.cdr.markForCheck();
12107
+ setTimeout((/**
12108
+ * @return {?}
12109
+ */
12110
+ function () { return _this.syncTotalFooterWithBody(); }));
11980
12111
  };
11981
12112
  /**
11982
12113
  * @return {?}
@@ -12113,31 +12244,27 @@
12113
12244
  this.tableData.content &&
12114
12245
  this.tableData.content.length);
12115
12246
  };
12116
- /** 列总宽超出外层容器才启用横向 scroll(不能用 table 自身宽度,会被 scroll.x 撑宽) */
12117
12247
  /**
12118
- * 列总宽超出外层容器才启用横向 scroll(不能用 table 自身宽度,会被 scroll.x 撑宽)
12248
+ * 列总宽超出外层容器才启用横向 scroll。
12249
+ * 以 dealScroll 累计的声明列宽为准,不用 DOM 自然测宽(内容不截断会偏大,导致列能放下也开横滚)。
12250
+ */
12251
+ /**
12252
+ * 列总宽超出外层容器才启用横向 scroll。
12253
+ * 以 dealScroll 累计的声明列宽为准,不用 DOM 自然测宽(内容不截断会偏大,导致列能放下也开横滚)。
12119
12254
  * @private
12120
12255
  * @param {?} colWidth
12121
12256
  * @return {?}
12122
12257
  */
12123
12258
  HdTableComponent.prototype.resolveScrollX = /**
12124
- * 列总宽超出外层容器才启用横向 scroll(不能用 table 自身宽度,会被 scroll.x 撑宽)
12259
+ * 列总宽超出外层容器才启用横向 scroll。
12260
+ * 以 dealScroll 累计的声明列宽为准,不用 DOM 自然测宽(内容不截断会偏大,导致列能放下也开横滚)。
12125
12261
  * @private
12126
12262
  * @param {?} colWidth
12127
12263
  * @return {?}
12128
12264
  */
12129
12265
  function (colWidth) {
12130
12266
  /** @type {?} */
12131
- var width = colWidth;
12132
- if (this.nzTableComponent) {
12133
- /** @type {?} */
12134
- var measured = measureTableColWidth(this.nzTableComponent);
12135
- if (measured > width) {
12136
- width = measured;
12137
- }
12138
- }
12139
- /** @type {?} */
12140
- var autoScroll = resolveAutoTableScroll(this.nzTableComponent, this.hasTableData(), width);
12267
+ var autoScroll = resolveAutoTableScroll(this.nzTableComponent, this.hasTableData(), colWidth);
12141
12268
  return autoScroll ? autoScroll.x : null;
12142
12269
  };
12143
12270
  /** 表格渲染后按实际容器宽度校正横向 scroll(只改 x,避免触发表头结构变化) */
@@ -12160,6 +12287,10 @@
12160
12287
  if (this.scroll &&
12161
12288
  this.scroll.x === scrollX &&
12162
12289
  this.scroll.y === currentY) {
12290
+ setTimeout((/**
12291
+ * @return {?}
12292
+ */
12293
+ function () { return _this.syncTotalFooterWithBody(); }));
12163
12294
  return;
12164
12295
  }
12165
12296
  // 保持 y 不变,防止运行中拆/合 header 导致横向同步失效
@@ -12170,32 +12301,308 @@
12170
12301
  */
12171
12302
  function () { return _this.syncHeaderBodyScrollLeft(); }));
12172
12303
  };
12173
- /** 手动把表体横向滚动同步到表头(兜底 ng-zorro 监听丢失的情况) */
12304
+ /** 手动把表体横向滚动同步到表头 / 合计 footer(兜底 ng-zorro 监听丢失的情况) */
12174
12305
  /**
12175
- * 手动把表体横向滚动同步到表头(兜底 ng-zorro 监听丢失的情况)
12306
+ * 手动把表体横向滚动同步到表头 / 合计 footer(兜底 ng-zorro 监听丢失的情况)
12176
12307
  * @private
12177
12308
  * @return {?}
12178
12309
  */
12179
12310
  HdTableComponent.prototype.syncHeaderBodyScrollLeft = /**
12180
- * 手动把表体横向滚动同步到表头(兜底 ng-zorro 监听丢失的情况)
12311
+ * 手动把表体横向滚动同步到表头 / 合计 footer(兜底 ng-zorro 监听丢失的情况)
12181
12312
  * @private
12182
12313
  * @return {?}
12183
12314
  */
12184
12315
  function () {
12185
- if (!this.nzTableComponent || !this.scroll || !this.scroll.x) {
12316
+ if (!this.nzTableComponent) {
12186
12317
  return;
12187
12318
  }
12188
12319
  /** @type {?} */
12189
12320
  var header = (/** @type {?} */ (((/** @type {?} */ (this.nzTableComponent))).tableHeaderNativeElement));
12190
12321
  /** @type {?} */
12191
- var body = (/** @type {?} */ (((/** @type {?} */ (this.nzTableComponent))).mixTableBodyNativeElement));
12192
- if (!header || !body) {
12322
+ var body = this.getTableBodyScrollEl();
12323
+ if (this.scroll && this.scroll.x && header && body) {
12324
+ if (header.scrollLeft !== body.scrollLeft) {
12325
+ header.scrollLeft = body.scrollLeft;
12326
+ }
12327
+ }
12328
+ this.syncTotalFooterWithBody();
12329
+ };
12330
+ /** 取表体横向滚动容器(虚拟滚动优先 viewport) */
12331
+ /**
12332
+ * 取表体横向滚动容器(虚拟滚动优先 viewport)
12333
+ * @private
12334
+ * @return {?}
12335
+ */
12336
+ HdTableComponent.prototype.getTableBodyScrollEl = /**
12337
+ * 取表体横向滚动容器(虚拟滚动优先 viewport)
12338
+ * @private
12339
+ * @return {?}
12340
+ */
12341
+ function () {
12342
+ if (!this.nzTableComponent) {
12343
+ return null;
12344
+ }
12345
+ /** @type {?} */
12346
+ var mix = (/** @type {?} */ (((/** @type {?} */ (this.nzTableComponent))).mixTableBodyNativeElement));
12347
+ if (mix) {
12348
+ return mix;
12349
+ }
12350
+ /** @type {?} */
12351
+ var host = this.hostEl && ((/** @type {?} */ (this.hostEl.nativeElement)));
12352
+ if (!host) {
12353
+ return null;
12354
+ }
12355
+ return (((/** @type {?} */ (host.querySelector("cdk-virtual-scroll-viewport.ant-table-body")))) ||
12356
+ ((/** @type {?} */ (host.querySelector(".ant-table-body")))) ||
12357
+ null);
12358
+ };
12359
+ /**
12360
+ * @private
12361
+ * @return {?}
12362
+ */
12363
+ HdTableComponent.prototype.getTotalFooterScrollEl = /**
12364
+ * @private
12365
+ * @return {?}
12366
+ */
12367
+ function () {
12368
+ /** @type {?} */
12369
+ var host = this.hostEl && ((/** @type {?} */ (this.hostEl.nativeElement)));
12370
+ return host
12371
+ ? ((/** @type {?} */ (host.querySelector(".hd-table-total-footer"))))
12372
+ : null;
12373
+ };
12374
+ /** 表体是否出现纵向滚动条(含滚动条槽宽) */
12375
+ /**
12376
+ * 表体是否出现纵向滚动条(含滚动条槽宽)
12377
+ * @private
12378
+ * @param {?} body
12379
+ * @return {?}
12380
+ */
12381
+ HdTableComponent.prototype.bodyHasVerticalScrollbar = /**
12382
+ * 表体是否出现纵向滚动条(含滚动条槽宽)
12383
+ * @private
12384
+ * @param {?} body
12385
+ * @return {?}
12386
+ */
12387
+ function (body) {
12388
+ if (!body) {
12389
+ return false;
12390
+ }
12391
+ return (body.scrollHeight > body.clientHeight + 1 ||
12392
+ body.offsetWidth - body.clientWidth > 1);
12393
+ };
12394
+ /**
12395
+ * 合计 footer 与表体联动:
12396
+ * - fluid(列未撑满):不横滚、不测宽,表宽 100% 与表体同比例拉伸;
12397
+ * - fixed(有 scroll.x):同步 scrollLeft;
12398
+ * - 仅当表体有竖滚条时预留右侧槽,行少无竖滚时不占位。
12399
+ */
12400
+ /**
12401
+ * 合计 footer 与表体联动:
12402
+ * - fluid(列未撑满):不横滚、不测宽,表宽 100% 与表体同比例拉伸;
12403
+ * - fixed(有 scroll.x):同步 scrollLeft;
12404
+ * - 仅当表体有竖滚条时预留右侧槽,行少无竖滚时不占位。
12405
+ * @private
12406
+ * @return {?}
12407
+ */
12408
+ HdTableComponent.prototype.syncTotalFooterWithBody = /**
12409
+ * 合计 footer 与表体联动:
12410
+ * - fluid(列未撑满):不横滚、不测宽,表宽 100% 与表体同比例拉伸;
12411
+ * - fixed(有 scroll.x):同步 scrollLeft;
12412
+ * - 仅当表体有竖滚条时预留右侧槽,行少无竖滚时不占位。
12413
+ * @private
12414
+ * @return {?}
12415
+ */
12416
+ function () {
12417
+ var _this = this;
12418
+ if (!this.showTableTotal) {
12419
+ this.unbindTotalFooterScrollSync();
12420
+ if (this.totalFooterNeedYGutter) {
12421
+ this.totalFooterNeedYGutter = false;
12422
+ this.cdr.markForCheck();
12423
+ }
12193
12424
  return;
12194
12425
  }
12195
- if (header.scrollLeft !== body.scrollLeft) {
12196
- header.scrollLeft = body.scrollLeft;
12426
+ /** @type {?} */
12427
+ var footer = this.getTotalFooterScrollEl();
12428
+ /** @type {?} */
12429
+ var body = this.getTableBodyScrollEl();
12430
+ if (!footer) {
12431
+ if (this.totalFooterSyncRetry < 10) {
12432
+ this.totalFooterSyncRetry++;
12433
+ setTimeout((/**
12434
+ * @return {?}
12435
+ */
12436
+ function () { return _this.syncTotalFooterWithBody(); }), 50);
12437
+ }
12438
+ return;
12439
+ }
12440
+ this.totalFooterSyncRetry = 0;
12441
+ /** @type {?} */
12442
+ var needYGutter = !!(body && this.bodyHasVerticalScrollbar(body));
12443
+ if (this.totalFooterNeedYGutter !== needYGutter) {
12444
+ this.totalFooterNeedYGutter = needYGutter;
12445
+ this.cdr.markForCheck();
12446
+ }
12447
+ if (this.isTotalFooterFluid) {
12448
+ this.unbindTotalFooterScrollSync();
12449
+ footer.scrollLeft = 0;
12450
+ return;
12451
+ }
12452
+ if (body) {
12453
+ this.syncTotalFooterScrollLeft(body.scrollLeft);
12454
+ this.bindTotalFooterScrollSync(body);
12197
12455
  }
12198
12456
  };
12457
+ /**
12458
+ * @private
12459
+ * @param {?} scrollLeft
12460
+ * @return {?}
12461
+ */
12462
+ HdTableComponent.prototype.syncTotalFooterScrollLeft = /**
12463
+ * @private
12464
+ * @param {?} scrollLeft
12465
+ * @return {?}
12466
+ */
12467
+ function (scrollLeft) {
12468
+ /** @type {?} */
12469
+ var footer = this.getTotalFooterScrollEl();
12470
+ if (footer && footer.scrollLeft !== scrollLeft) {
12471
+ footer.scrollLeft = scrollLeft;
12472
+ }
12473
+ };
12474
+ /**
12475
+ * @private
12476
+ * @param {?} body
12477
+ * @return {?}
12478
+ */
12479
+ HdTableComponent.prototype.bindTotalFooterScrollSync = /**
12480
+ * @private
12481
+ * @param {?} body
12482
+ * @return {?}
12483
+ */
12484
+ function (body) {
12485
+ var _this = this;
12486
+ if (!this.showTableTotal || !body || this.isTotalFooterFluid) {
12487
+ return;
12488
+ }
12489
+ if (this.totalFooterScrollBoundBody === body &&
12490
+ this.totalFooterScrollHandler) {
12491
+ return;
12492
+ }
12493
+ this.unbindTotalFooterScrollSync();
12494
+ this.totalFooterScrollBoundBody = body;
12495
+ this.totalFooterScrollHandler = (/**
12496
+ * @return {?}
12497
+ */
12498
+ function () {
12499
+ _this.syncTotalFooterScrollLeft(body.scrollLeft);
12500
+ });
12501
+ body.addEventListener("scroll", this.totalFooterScrollHandler, (/** @type {?} */ ({
12502
+ passive: true,
12503
+ })));
12504
+ };
12505
+ /**
12506
+ * @private
12507
+ * @return {?}
12508
+ */
12509
+ HdTableComponent.prototype.unbindTotalFooterScrollSync = /**
12510
+ * @private
12511
+ * @return {?}
12512
+ */
12513
+ function () {
12514
+ if (this.totalFooterScrollBoundBody && this.totalFooterScrollHandler) {
12515
+ this.totalFooterScrollBoundBody.removeEventListener("scroll", this.totalFooterScrollHandler);
12516
+ }
12517
+ this.totalFooterScrollBoundBody = null;
12518
+ this.totalFooterScrollHandler = null;
12519
+ };
12520
+ /**
12521
+ * 监听窗口 / 容器宽度变化:重新判定 scroll.x(fluid↔fixed)与合计右侧竖滚槽,
12522
+ * 避免拉宽/缩窄屏幕后合计行宽与表体错位。
12523
+ */
12524
+ /**
12525
+ * 监听窗口 / 容器宽度变化:重新判定 scroll.x(fluid↔fixed)与合计右侧竖滚槽,
12526
+ * 避免拉宽/缩窄屏幕后合计行宽与表体错位。
12527
+ * @private
12528
+ * @return {?}
12529
+ */
12530
+ HdTableComponent.prototype.bindViewportResizeSync = /**
12531
+ * 监听窗口 / 容器宽度变化:重新判定 scroll.x(fluid↔fixed)与合计右侧竖滚槽,
12532
+ * 避免拉宽/缩窄屏幕后合计行宽与表体错位。
12533
+ * @private
12534
+ * @return {?}
12535
+ */
12536
+ function () {
12537
+ var _this = this;
12538
+ this.boundOnViewportResize = (/**
12539
+ * @return {?}
12540
+ */
12541
+ function () { return _this.scheduleViewportScrollSync(); });
12542
+ if (typeof window !== "undefined") {
12543
+ window.addEventListener("resize", this.boundOnViewportResize);
12544
+ }
12545
+ /** @type {?} */
12546
+ var RO = typeof window !== "undefined" ? ((/** @type {?} */ (window))).ResizeObserver : null;
12547
+ if (RO && this.hostEl && this.hostEl.nativeElement) {
12548
+ this.hostResizeObserver = new RO((/**
12549
+ * @return {?}
12550
+ */
12551
+ function () { return _this.scheduleViewportScrollSync(); }));
12552
+ this.hostResizeObserver.observe(this.hostEl.nativeElement);
12553
+ }
12554
+ };
12555
+ /**
12556
+ * @private
12557
+ * @return {?}
12558
+ */
12559
+ HdTableComponent.prototype.unbindViewportResizeSync = /**
12560
+ * @private
12561
+ * @return {?}
12562
+ */
12563
+ function () {
12564
+ if (this.boundOnViewportResize && typeof window !== "undefined") {
12565
+ window.removeEventListener("resize", this.boundOnViewportResize);
12566
+ }
12567
+ this.boundOnViewportResize = null;
12568
+ if (this.hostResizeObserver) {
12569
+ this.hostResizeObserver.disconnect();
12570
+ this.hostResizeObserver = null;
12571
+ }
12572
+ if (this.viewportResizeTimer != null) {
12573
+ clearTimeout(this.viewportResizeTimer);
12574
+ this.viewportResizeTimer = null;
12575
+ }
12576
+ };
12577
+ /**
12578
+ * @private
12579
+ * @return {?}
12580
+ */
12581
+ HdTableComponent.prototype.scheduleViewportScrollSync = /**
12582
+ * @private
12583
+ * @return {?}
12584
+ */
12585
+ function () {
12586
+ var _this = this;
12587
+ if (this.viewportResizeTimer != null) {
12588
+ clearTimeout(this.viewportResizeTimer);
12589
+ }
12590
+ this.viewportResizeTimer = setTimeout((/**
12591
+ * @return {?}
12592
+ */
12593
+ function () {
12594
+ _this.viewportResizeTimer = null;
12595
+ if (!_this.tableCols || !_this.tableCols.length) {
12596
+ return;
12597
+ }
12598
+ _this.syncHorizontalScroll();
12599
+ // 等表体布局稳定后再校合计竖滚槽 / 横滚同步
12600
+ setTimeout((/**
12601
+ * @return {?}
12602
+ */
12603
+ function () { return _this.syncTotalFooterWithBody(); }), 50);
12604
+ }), 100);
12605
+ };
12199
12606
  /**
12200
12607
  * @return {?}
12201
12608
  */
@@ -12208,6 +12615,9 @@
12208
12615
  if (this.showSelected) {
12209
12616
  colWidth += 40;
12210
12617
  }
12618
+ if (this.showTableTotal) {
12619
+ colWidth += this.lineNumberColWidth; // 序号列(固定宽,不随位数变化)
12620
+ }
12211
12621
  this.tableCols.forEach((/**
12212
12622
  * @param {?} item
12213
12623
  * @return {?}
@@ -12326,6 +12736,194 @@
12326
12736
  this.tableSearchEvent.emit(reset);
12327
12737
  }
12328
12738
  };
12739
+ /**
12740
+ * 底部合计:与 hd-detail-lines 相同,使用 TotalOption(insertIndex / insertValue)。
12741
+ * 开启后强制展示序号列,「合计」落在序号列下;
12742
+ * insertIndex 从 1 起对应可见数据列;未传 insertValue 时按该列 name 对 content 求和。
12743
+ */
12744
+ /**
12745
+ * 底部合计:与 hd-detail-lines 相同,使用 TotalOption(insertIndex / insertValue)。
12746
+ * 开启后强制展示序号列,「合计」落在序号列下;
12747
+ * insertIndex 从 1 起对应可见数据列;未传 insertValue 时按该列 name 对 content 求和。
12748
+ * @return {?}
12749
+ */
12750
+ HdTableComponent.prototype.calculateTableTotal = /**
12751
+ * 底部合计:与 hd-detail-lines 相同,使用 TotalOption(insertIndex / insertValue)。
12752
+ * 开启后强制展示序号列,「合计」落在序号列下;
12753
+ * insertIndex 从 1 起对应可见数据列;未传 insertValue 时按该列 name 对 content 求和。
12754
+ * @return {?}
12755
+ */
12756
+ function () {
12757
+ var _this = this;
12758
+ if (!this.showTableTotal ||
12759
+ !this.tableTotalOption ||
12760
+ !this.tableTotalOption.length) {
12761
+ this.tableTotalOptionList = [];
12762
+ return;
12763
+ }
12764
+ /** @type {?} */
12765
+ var visibleCols = (this.tableCols || []).filter((/**
12766
+ * @param {?} c
12767
+ * @return {?}
12768
+ */
12769
+ function (c) { return c && c.isShow !== false; }));
12770
+ // columnsNumber 含序号列(与 detail-lines 一致),数据槽位数 = columnsNumber - 1
12771
+ /** @type {?} */
12772
+ var configured = Number(this.columnsNumber);
12773
+ /** @type {?} */
12774
+ var columnNumber = configured > 1
12775
+ ? configured - 1
12776
+ : configured === 1
12777
+ ? 1
12778
+ : visibleCols.length;
12779
+ if (!columnNumber || columnNumber < 1) {
12780
+ this.tableTotalOptionList = [];
12781
+ return;
12782
+ }
12783
+ this.tableTotalOptionList = new Array(columnNumber).fill("");
12784
+ /** @type {?} */
12785
+ var content = this.tableData && this.tableData.content ? this.tableData.content : [];
12786
+ this.tableTotalOption.forEach((/**
12787
+ * @param {?} item
12788
+ * @return {?}
12789
+ */
12790
+ function (item) {
12791
+ if (item == null || !item.insertIndex || item.insertIndex < 1) {
12792
+ return;
12793
+ }
12794
+ /** @type {?} */
12795
+ var value = item.insertValue;
12796
+ // 未传 insertValue 时:按 insertIndex 对应可见列 name 自动求和
12797
+ if (value == null || value === "") {
12798
+ /** @type {?} */
12799
+ var col = visibleCols[item.insertIndex - 1];
12800
+ /** @type {?} */
12801
+ var field_1 = col && typeof col.name === "string" ? col.name : null;
12802
+ if (!field_1) {
12803
+ return;
12804
+ }
12805
+ /** @type {?} */
12806
+ var sum_1 = 0;
12807
+ /** @type {?} */
12808
+ var hasValue_1 = false;
12809
+ content.forEach((/**
12810
+ * @param {?} row
12811
+ * @return {?}
12812
+ */
12813
+ function (row) {
12814
+ /** @type {?} */
12815
+ var raw = row ? row[field_1] : null;
12816
+ if (raw == null || raw === "") {
12817
+ return;
12818
+ }
12819
+ /** @type {?} */
12820
+ var num = Number(raw);
12821
+ if (!isNaN(num)) {
12822
+ sum_1 += num;
12823
+ hasValue_1 = true;
12824
+ }
12825
+ }));
12826
+ if (!hasValue_1) {
12827
+ return;
12828
+ }
12829
+ value = sum_1;
12830
+ }
12831
+ /** @type {?} */
12832
+ var colAtIndex = visibleCols[item.insertIndex - 1];
12833
+ _this.tableTotalOptionList[item.insertIndex - 1] = {
12834
+ value: value,
12835
+ align: item.align || (colAtIndex && colAtIndex.align) || "left",
12836
+ showDecimal: item.showDecimal || false,
12837
+ preserveNumber: item.preserveNumber != null ? item.preserveNumber : 2,
12838
+ isHide: item.isHide || false,
12839
+ };
12840
+ }));
12841
+ };
12842
+ /**
12843
+ * @private
12844
+ * @param {?} col
12845
+ * @param {?} colIndex
12846
+ * @return {?}
12847
+ */
12848
+ HdTableComponent.prototype.getTableTotalCellMeta = /**
12849
+ * @private
12850
+ * @param {?} col
12851
+ * @param {?} colIndex
12852
+ * @return {?}
12853
+ */
12854
+ function (col, colIndex) {
12855
+ if (!col || !this.tableTotalOptionList || !this.tableTotalOptionList.length) {
12856
+ return null;
12857
+ }
12858
+ /** @type {?} */
12859
+ var visibleIndex = -1;
12860
+ for (var i = 0; i <= colIndex; i++) {
12861
+ /** @type {?} */
12862
+ var c = this.tableCols[i];
12863
+ if (c && c.isShow !== false) {
12864
+ visibleIndex++;
12865
+ }
12866
+ }
12867
+ if (visibleIndex < 0 || visibleIndex >= this.tableTotalOptionList.length) {
12868
+ return null;
12869
+ }
12870
+ /** @type {?} */
12871
+ var meta = this.tableTotalOptionList[visibleIndex];
12872
+ return meta && typeof meta === "object" ? meta : null;
12873
+ };
12874
+ /** 合计单元格展示文案(对齐 detail-lines 小数规则) */
12875
+ /**
12876
+ * 合计单元格展示文案(对齐 detail-lines 小数规则)
12877
+ * @param {?} col
12878
+ * @param {?} colIndex
12879
+ * @return {?}
12880
+ */
12881
+ HdTableComponent.prototype.getTableTotalCellValue = /**
12882
+ * 合计单元格展示文案(对齐 detail-lines 小数规则)
12883
+ * @param {?} col
12884
+ * @param {?} colIndex
12885
+ * @return {?}
12886
+ */
12887
+ function (col, colIndex) {
12888
+ /** @type {?} */
12889
+ var meta = this.getTableTotalCellMeta(col, colIndex);
12890
+ if (!meta || meta.isHide) {
12891
+ return "";
12892
+ }
12893
+ /** @type {?} */
12894
+ var value = meta.value;
12895
+ if (!(value || value === 0)) {
12896
+ return "";
12897
+ }
12898
+ /** @type {?} */
12899
+ var preserve = meta.preserveNumber != null ? Number(meta.preserveNumber) : 2;
12900
+ if (value % 1 === 0 && !meta.showDecimal) {
12901
+ return value;
12902
+ }
12903
+ /** @type {?} */
12904
+ var factor = Math.pow(10, preserve);
12905
+ return (Math.round(Number(value) * factor) / factor).toFixed(preserve);
12906
+ };
12907
+ /**
12908
+ * @param {?} col
12909
+ * @param {?} colIndex
12910
+ * @return {?}
12911
+ */
12912
+ HdTableComponent.prototype.getTableTotalCellAlign = /**
12913
+ * @param {?} col
12914
+ * @param {?} colIndex
12915
+ * @return {?}
12916
+ */
12917
+ function (col, colIndex) {
12918
+ /** @type {?} */
12919
+ var meta = this.getTableTotalCellMeta(col, colIndex);
12920
+ /** @type {?} */
12921
+ var align = (meta && meta.align) || (col && col.align) || "left";
12922
+ if (align === "right" || align === "center" || align === "left") {
12923
+ return align;
12924
+ }
12925
+ return "left";
12926
+ };
12329
12927
  /** 底部「共 n 条」:非分页/前端分页用 content.length,服务端分页用 totalElements */
12330
12928
  /**
12331
12929
  * 底部「共 n 条」:非分页/前端分页用 content.length,服务端分页用 totalElements
@@ -12935,13 +13533,14 @@
12935
13533
  HdTableComponent.decorators = [
12936
13534
  { type: core.Component, args: [{
12937
13535
  selector: "hd-table",
12938
- template: "<ng-container>\n <hd-button-group>\n <ng-template #buttonGroupLeft>\n <ng-container *ngTemplateOutlet=\"tableLeftButton\"></ng-container>\n <hd-button *ngIf=\"showOperateColWarpButton\" type=\"default\" (click)=\"toggleShowDetail()\">{{showDetail ?\n '\u7F29\u7565\u663E\u793A': '\u5C55\u5F00\u663E\u793A'}}</hd-button>\n </ng-template>\n <ng-template #buttonGroupRight>\n <ng-container *ngTemplateOutlet=\"tableRightButton\"></ng-container>\n <span class=\"hd-table-col-settings\" nz-dropdown nzTrigger=\"click\" [nzDropdownMenu]=\"menu\"\n [nzVisible]=\"isDropdownVisible\" (click)=\"confirmDropdown()\" title=\"\u5217\u8BBE\u7F6E\">\n <svg class=\"hd-table-col-settings-icon\" width=\"14\" height=\"14\" viewBox=\"0 0 14 14\" fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\" aria-hidden=\"true\">\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\"\n d=\"M4.92031 1.80756C5.02551 1.42884 5.37033 1.16675 5.76339 1.16675H8.23667C8.62973 1.16675 8.97455 1.42884 9.07975 1.80756L9.37802 2.88133L10.4571 2.60273C10.8377 2.50448 11.2371 2.67206 11.4336 3.01245L12.6703 5.15438C12.8668 5.49478 12.8122 5.92445 12.5369 6.20491L11.7561 7.00008L12.5369 7.79525C12.8122 8.07572 12.8668 8.50539 12.6703 8.84579L11.4336 10.9877C11.2371 11.3281 10.8377 11.4957 10.4571 11.3974L9.37802 11.1188L9.07975 12.1926C8.97455 12.5713 8.62973 12.8334 8.23667 12.8334H5.76339C5.37033 12.8334 5.02551 12.5713 4.92031 12.1926L4.62206 11.1189L3.54315 11.3974C3.16258 11.4957 2.76318 11.3281 2.56666 10.9877L1.33001 8.84579C1.13349 8.50539 1.18806 8.07572 1.46343 7.79525L2.24419 7.00008L1.46344 6.20491C1.18806 5.92445 1.13349 5.49478 1.33002 5.15438L2.56666 3.01245C2.76319 2.67206 3.16258 2.50448 3.54316 2.60273L4.62206 2.88127L4.92031 1.80756ZM4.54541 10.843L4.54552 10.8433L4.54541 10.843ZM5.98508 2.33341L5.66952 3.46945C5.54185 3.92906 5.06958 4.20173 4.60771 4.08249L3.46618 3.78778L2.45122 5.54572L3.2773 6.38705C3.6115 6.72742 3.6115 7.27275 3.2773 7.61312L2.45122 8.45444L3.46617 10.2124L4.60771 9.91768C5.06958 9.79844 5.54185 10.0711 5.66952 10.5307L5.98508 11.6667H8.01498L8.33056 10.5307C8.45823 10.071 8.9305 9.79838 9.39237 9.91762L10.5341 10.2124L11.5491 8.45444L10.723 7.61312C10.3888 7.27275 10.3888 6.72742 10.723 6.38705L11.5491 5.54572L10.5341 3.78778L9.39237 4.08254C8.9305 4.20178 8.45823 3.92912 8.33056 3.46951L8.01498 2.33341H5.98508ZM7.00003 5.83342C6.3557 5.83342 5.83337 6.35575 5.83337 7.00008C5.83337 7.64441 6.3557 8.16675 7.00003 8.16675C7.64436 8.16675 8.1667 7.64441 8.1667 7.00008C8.1667 6.35575 7.64436 5.83342 7.00003 5.83342ZM4.6667 7.00008C4.6667 5.71142 5.71137 4.66675 7.00003 4.66675C8.2887 4.66675 9.33337 5.71142 9.33337 7.00008C9.33337 8.28875 8.2887 9.33342 7.00003 9.33342C5.71137 9.33342 4.6667 8.28875 4.6667 7.00008Z\"\n fill=\"currentColor\" />\n </svg>\n </span>\n <nz-dropdown-menu #menu=\"nzDropdownMenu\">\n <div class=\"hd-table-col-settings-dropdown\">\n <div class=\"hd-table-col-settings-list\">\n <div *ngIf=\"showListNodes && nowListNodes.length > 0\" nz-menu style=\"padding: 5px 10px;\">\n <nz-tree *ngIf=\"showListNodes\" [nzData]=\"nowListNodes\" nzCheckable nzDraggable nzBlockNode\n nzShowExpand=\"false\" (nzCheckBoxChange)=\"checkAction($event)\" [nzBeforeDrop]=\"beforeDrop\"\n [nzTreeTemplate]=\"nzTreeTemplate\">\n </nz-tree>\n <ng-template #nzTreeTemplate let-node>\n <span\n class=\"ng-tns-c31-110 draggable ng-star-inserted ant-tree-node-content-wrapper ant-tree-node-content-wrapper-close\"\n [title]=\"node.key\" draggable=\"true\" aria-grabbed=\"true\">\n <span class=\"ant-tree-title\">\n <div class=\"hd-table-tree-node\">\n <span>{{node.key}}</span>\n <div *ngIf=\"!node.origin.disabled\" class=\"hd-table-tree-node-img\">\n <i nz-icon nzType=\"caret-up\" nzTheme=\"outline\"></i>\n <i nz-icon nzType=\"caret-down\" nzTheme=\"outline\"></i>\n </div>\n </div>\n </span>\n </span>\n </ng-template>\n </div>\n <div *ngIf=\"showListNodes && hideListNodes.length > 0\" nz-menu style=\"padding: 5px 10px;\">\n <nz-tree *ngIf=\"showListNodes\" [nzData]=\"hideListNodes\" nzCheckable nzShowExpand=\"false\"\n (nzCheckBoxChange)=\"checkAction($event)\">\n </nz-tree>\n </div>\n </div>\n <div class=\"hd-table-col-settings-footer\">\n <hd-button style=\"margin-right: 4px;\" type=\"default\" size=\"small\" (clickAction)=\"cancelDropdown()\">\u53D6\u6D88\n </hd-button>\n <hd-button type=\"primary\" size=\"small\" (clickAction)=\"submitGrids()\">\u5B8C\u6210</hd-button>\n </div>\n </div>\n </nz-dropdown-menu>\n </ng-template>\n </hd-button-group>\n <hd-space type=\"row\" size=\"12\"></hd-space>\n <ng-container *ngTemplateOutlet=\"tableTotal\"></ng-container>\n <hd-space *ngIf=\"tableTotal\" type=\"row\" size=\"12\"></hd-space>\n <nz-table *ngIf=\"showTable\" #hdTable class=\"hd-table-container\" [class.hd-table--virtual]=\"useVirtualScroll\"\n [class.hd-table--scroll-y]=\"!!(scroll && scroll.y)\" [class.hd-table--scroll-x]=\"!!(scroll && scroll.x)\"\n [nzScroll]=\"scroll\"\n [nzShowPagination]=\"pagination\" [nzShowSizeChanger]=\"pagination\" [nzShowQuickJumper]=\"pagination\"\n [nzFrontPagination]=\"useFrontPagination\" nzSize=\"middle\" [nzData]=\"tableData.content\"\n [nzTotal]=\"getTableTotalCount()\" [(nzPageIndex)]=\"tablePageIndex\" [nzLoading]=\"tableLoading\"\n [nzPageSizeOptions]=\"[ 10, 50, 100, 200, 500, 1000 ]\" [(nzPageSize)]=\"tablePageSize\"\n (nzPageSizeChange)=\"pagination ? search(true) : null\"\n (nzPageIndexChange)=\"pagination ? search(false) : null\"\n (nzCurrentPageDataChange)=\"showSelected ? currentPageDataChange($event) : null\"\n [nzShowTotal]=\"tableTotalTemplate\" [nzVirtualScroll]=\"useVirtualScroll\" [nzVirtualItemSize]=\"useVirtualScroll ? effectiveVirtualItemSize : 0\"\n [nzVirtualForTrackBy]=\"virtualTrackByRow\">\n <thead (nzSortChange)=\"sort($event)\" nzSingleSort>\n <tr>\n <th nzWidth=\"40px\" nzLeft=\"0px\" *ngIf=\"showSelected\" nzShowCheckbox [(nzChecked)]=\"isAllDisplayDataChecked\"\n [nzIndeterminate]=\"isIndeterminate\" (nzCheckedChange)=\"checkAll($event)\"></th>\n <ng-container *ngFor=\"let col of tableCols\">\n <th *ngIf=\"col.isShow\" [nzWidth]=\"col.width + 'px'\" [nzAlign]=\"col.align\"\n [nzLeft]=\"getLeftSticky(col)\"\n [nzRight]=\"getRightSticky(col)\" nz-resizable nzBounds=\"window\" nzPreview\n (nzResizeEnd)=\"onResize($event, col)\" [nzShowSort]=\"col.canSort\" [nzSortKey]=\"col.name\"\n [nzSort]=\"getColSort(col)\">\n <ng-container *ngIf=\"getTitleParts(col) as titleParts; else plainTitle\">\n <span class=\"hd-table-title-with-bar\">{{ titleParts[0] }}<i class=\"hd-table-row-no-bar\"></i>{{ titleParts[1] }}</span>\n </ng-container>\n <ng-template #plainTitle>{{ col.title }}</ng-template>\n <nz-resize-handle nzDirection=\"right\">\n <div class=\"resize-trigger\"></div>\n </nz-resize-handle>\n </th>\n </ng-container>\n </tr>\n </thead>\n <tbody>\n <ng-template *ngIf=\"useVirtualScroll\" nz-virtual-scroll let-data let-index=\"index\">\n <tr class=\"hd-table-virtual-row\" [class.hd-table-row-invalid]=\"isInvalidRow(data)\">\n <ng-container *ngTemplateOutlet=\"tableCells; context: { $implicit: data, index: index }\"></ng-container>\n </tr>\n </ng-template>\n <ng-container *ngIf=\"!useVirtualScroll\">\n <tr *ngFor=\"let data of hdTable.data; trackBy: trackByRow; index as i\"\n [class.hd-table-row-invalid]=\"isInvalidRow(data)\">\n <ng-container *ngTemplateOutlet=\"tableCells; context: { $implicit: data, index: i }\"></ng-container>\n </tr>\n </ng-container>\n </tbody>\n <tfoot *ngIf=\"showTableTotal\">\n <tr class=\"hd-table-total\">\n <td>\u5408\u8BA1</td>\n <ng-container *ngFor=\"let tableTotalOption of tableTotalOptionList\">\n <td>{{ tableTotalOption }}</td>\n </ng-container>\n </tr>\n </tfoot>\n <ng-template #tableTotalTemplate>\n \u5171 {{ getTableTotalCount() }} \u6761\u6570\u636E\n </ng-template>\n </nz-table>\n</ng-container>\n\n<ng-template #tableCells let-data let-index=\"index\">\n <td nzLeft=\"0px\" *ngIf=\"showSelected\" nzShowCheckbox [nzChecked]=\"mapOfCheckedId[data[selectField]]\"\n [nzDisabled]=\"isSelectDisabled(data)\" (nzCheckedChange)=\"refreshStatus($event, data)\"></td>\n <ng-container *ngFor=\"let col of tableCols; trackBy: trackByCol\">\n <td *ngIf=\"col.isShow\" [ngStyle]=\"{'max-width': col.width + 'px'}\" [nzAlign]=\"col.align\"\n [nzLeft]=\"getLeftSticky(col)\"\n [nzRight]=\"getRightSticky(col)\"\n [ngClass]=\"(col.canWarp && showDetail) ? 'common-td-wrap' : ''\">\n <ng-container *ngIf=\"col.title === '\u64CD\u4F5C';else notOperateTemplate\">\n <div class=\"common-btn-group\">\n <ng-container *ngFor=\"let btn of col.btnList\">\n <ng-container *ngIf=\"!needShowConfirm(btn, data);else showConfirmTemplate\">\n <a *ngIf=\"btn.permission ? btn.permission(data) : true\"\n [class]=\"isDangerBtn(btn, data) ? 'common-danger-btn': ''\"\n (click)=\"triggerEvent(btn.click || null, data)\">{{ getBtnName(btn, data) }}</a>\n </ng-container>\n <ng-template #showConfirmTemplate>\n <a *ngIf=\"btn.permission ? btn.permission(data) : true\"\n [class]=\"isDangerBtn(btn, data) ? 'common-danger-btn': ''\" nz-popconfirm\n [nzPopconfirmTitle]=\"'\u786E\u8BA4\u8981' + getBtnName(btn, data) + '\u5417?'\"\n (nzOnConfirm)=\"triggerEvent(btn.click || null, data)\">{{\n getBtnName(btn, data) }}</a>\n </ng-template>\n </ng-container>\n </div>\n </ng-container>\n <ng-template #notOperateTemplate>\n <ng-container *ngIf=\"hasInlineEdit(col); else displayCellTpl\">\n <div class=\"hd-table-cell-edit\">\n <ng-container [ngSwitch]=\"col.editType\">\n <input *ngSwitchCase=\"'input'\" nz-input class=\"hd-table-cell-edit-control\"\n [placeholder]=\"col.placeholder || ''\"\n [disabled]=\"isEditDisabled(col, data)\"\n [ngModel]=\"data[col.name]\"\n (ngModelChange)=\"onCellChange(col, data, $event)\" />\n <nz-input-number *ngSwitchCase=\"'inputNumber'\" class=\"hd-table-cell-edit-control\"\n [nzPlaceHolder]=\"col.placeholder || ''\"\n [nzDisabled]=\"isEditDisabled(col, data)\"\n [nzMin]=\"getInputNumberProp(col, 'min', 0)\"\n [nzMax]=\"getInputNumberProp(col, 'max', 99999999)\"\n [nzStep]=\"getInputNumberProp(col, 'step', 1)\"\n [nzPrecision]=\"getInputNumberProp(col, 'precision', 4)\"\n [ngModel]=\"data[col.name]\"\n (ngModelChange)=\"onCellChange(col, data, $event)\">\n </nz-input-number>\n <nz-select *ngSwitchCase=\"'select'\" class=\"hd-table-cell-edit-control\"\n [nzPlaceHolder]=\"col.placeholder || '\u8BF7\u9009\u62E9'\"\n [nzDisabled]=\"isEditDisabled(col, data)\"\n [nzAllowClear]=\"col.selectOption && col.selectOption.hdAllowClear !== false\"\n [nzShowSearch]=\"!col.selectOption || col.selectOption.hdShowSearch !== false\"\n [ngModel]=\"data[col.name]\"\n (ngModelChange)=\"onSelectChange(col, data, $event)\">\n <nz-option *ngFor=\"let selectItem of getSelectList(col, data)\"\n [nzValue]=\"selectItem[col.selectOption.value]\"\n [nzLabel]=\"getSelectOptionLabel(col, selectItem)\">\n </nz-option>\n </nz-select>\n </ng-container>\n </div>\n </ng-container>\n <ng-template #displayCellTpl>\n <div [class.hd-table-cell-with-actions]=\"col.btnList && col.btnList.length\">\n <div class=\"hd-table-cell-value\"\n [class.hd-table-cell-value--rowno]=\"hasRowNo(col)\"\n [class.hd-table-cell-value--edit]=\"isEditable(col, data)\">\n <ng-container *ngIf=\"col.name === 'state' || col.isState;else otherTemplate\">\n <hd-status [status]=\"data[getStateField(col)]\">\n <ng-container *ngIf=\"(data | hdTableCell:col) as cell\">\n <span *ngIf=\"cell.overflow && !(col.canWarp && showDetail)\" class=\"hd-table-cell-ellipsis\" nz-tooltip\n [nzTooltipTitle]=\"cell.title\">{{ cell.display }}</span>\n <span *ngIf=\"!cell.overflow || (col.canWarp && showDetail)\">{{ cell.display }}</span>\n </ng-container>\n </hd-status>\n </ng-container>\n <ng-template #otherTemplate>\n <ng-container *ngIf=\"col.click && (!col.canClick || col.canClick(data));else noClickTemplate\">\n <ng-container *ngIf=\"(data | hdTableCell:col) as cell\">\n <a *ngIf=\"cell.overflow && !(col.canWarp && showDetail)\" class=\"hd-table-cell-ellipsis\" nz-tooltip\n [nzTooltipTitle]=\"cell.title\"\n [ngStyle]=\"{'color': getLinkCellColor(col, data, cell.isEmpty)}\"\n (click)=\"triggerEvent(col.click || null, data)\">{{ cell.display }}</a>\n <a *ngIf=\"!cell.overflow || (col.canWarp && showDetail)\"\n [ngStyle]=\"{'color': getLinkCellColor(col, data, cell.isEmpty)}\"\n (click)=\"triggerEvent(col.click || null, data)\">{{ cell.display }}</a>\n </ng-container>\n </ng-container>\n <ng-template #noClickTemplate>\n <ng-container *ngIf=\"(data | hdTableCell:col) as cell\">\n <span *ngIf=\"cell.overflow && !(col.canWarp && showDetail)\" class=\"hd-table-cell-ellipsis\" nz-tooltip\n [nzTooltipTitle]=\"cell.title\"\n [ngStyle]=\"{'color': getPlainCellColor(col, data)}\">{{ cell.display }}</span>\n <span *ngIf=\"!cell.overflow || (col.canWarp && showDetail)\"\n [ngStyle]=\"{'color': getPlainCellColor(col, data)}\">{{ cell.display }}</span>\n </ng-container>\n </ng-template>\n </ng-template>\n <span class=\"hd-table-row-no\" *ngIf=\"hasRowNo(col) && getRowNoText(col, data, index)\">\n <i class=\"hd-table-row-no-bar\"></i>{{ getRowNoText(col, data, index) }}\n </span>\n <a *ngIf=\"isEditable(col, data)\" class=\"hd-table-edit-icon\" href=\"javascript:;\" title=\"\u7F16\u8F91\"\n (click)=\"onEditClick($event, col, data)\">\n <svg width=\"14\" height=\"14\" viewBox=\"0 0 14 14\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"\n aria-hidden=\"true\">\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\"\n d=\"M8.10797 1.42626C8.44968 1.08456 9.0037 1.08456 9.34541 1.42626L10.9746 3.05542C11.3163 3.39713 11.3163 3.95115 10.9746 4.29286L5.01002 10.2574C4.87077 10.3967 4.68863 10.4849 4.49305 10.5078L2.72936 10.7142C2.18281 10.7782 1.71357 10.3278 1.7551 9.77914L1.89441 7.93871C1.9102 7.73007 2.00024 7.53399 2.14819 7.38604L8.10797 1.42626ZM7.67304 3.51111L8.88972 4.72779L9.94337 3.67414L8.72669 2.45746L7.67304 3.51111ZM8.06477 5.55274L6.84808 4.33606L3.04959 8.13456L2.94515 9.51434L4.25672 9.36079L8.06477 5.55274ZM12.25 12.8333L1.75 12.8333V11.6666L12.25 11.6666V12.8333Z\"\n fill=\"currentColor\" />\n </svg>\n </a>\n </div>\n <div class=\"common-btn-group hd-table-cell-actions\" *ngIf=\"col.btnList && col.btnList.length\">\n <ng-container *ngFor=\"let btn of col.btnList\">\n <ng-container *ngIf=\"!needShowConfirm(btn, data);else cellActionConfirmTpl\">\n <a *ngIf=\"btn.permission ? btn.permission(data) : true\"\n [class]=\"isDangerBtn(btn, data) ? 'common-danger-btn': ''\"\n (click)=\"triggerEvent(btn.click || null, data)\">{{ getBtnName(btn, data) }}</a>\n </ng-container>\n <ng-template #cellActionConfirmTpl>\n <a *ngIf=\"btn.permission ? btn.permission(data) : true\"\n [class]=\"isDangerBtn(btn, data) ? 'common-danger-btn': ''\" nz-popconfirm\n [nzPopconfirmTitle]=\"'\u786E\u8BA4\u8981' + getBtnName(btn, data) + '\u5417?'\"\n (nzOnConfirm)=\"triggerEvent(btn.click || null, data)\">{{\n getBtnName(btn, data) }}</a>\n </ng-template>\n </ng-container>\n </div>\n </div>\n </ng-template>\n </ng-template>\n </td>\n </ng-container>\n</ng-template>\n",
13536
+ template: "<ng-container>\n <hd-button-group>\n <ng-template #buttonGroupLeft>\n <ng-container *ngTemplateOutlet=\"tableLeftButton\"></ng-container>\n <hd-button *ngIf=\"showOperateColWarpButton\" type=\"default\" (click)=\"toggleShowDetail()\">{{showDetail ?\n '\u7F29\u7565\u663E\u793A': '\u5C55\u5F00\u663E\u793A'}}</hd-button>\n </ng-template>\n <ng-template #buttonGroupRight>\n <ng-container *ngTemplateOutlet=\"tableRightButton\"></ng-container>\n <span class=\"hd-table-col-settings\" nz-dropdown nzTrigger=\"click\" [nzDropdownMenu]=\"menu\"\n [nzVisible]=\"isDropdownVisible\" (click)=\"confirmDropdown()\" title=\"\u5217\u8BBE\u7F6E\">\n <svg class=\"hd-table-col-settings-icon\" width=\"14\" height=\"14\" viewBox=\"0 0 14 14\" fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\" aria-hidden=\"true\">\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\"\n d=\"M4.92031 1.80756C5.02551 1.42884 5.37033 1.16675 5.76339 1.16675H8.23667C8.62973 1.16675 8.97455 1.42884 9.07975 1.80756L9.37802 2.88133L10.4571 2.60273C10.8377 2.50448 11.2371 2.67206 11.4336 3.01245L12.6703 5.15438C12.8668 5.49478 12.8122 5.92445 12.5369 6.20491L11.7561 7.00008L12.5369 7.79525C12.8122 8.07572 12.8668 8.50539 12.6703 8.84579L11.4336 10.9877C11.2371 11.3281 10.8377 11.4957 10.4571 11.3974L9.37802 11.1188L9.07975 12.1926C8.97455 12.5713 8.62973 12.8334 8.23667 12.8334H5.76339C5.37033 12.8334 5.02551 12.5713 4.92031 12.1926L4.62206 11.1189L3.54315 11.3974C3.16258 11.4957 2.76318 11.3281 2.56666 10.9877L1.33001 8.84579C1.13349 8.50539 1.18806 8.07572 1.46343 7.79525L2.24419 7.00008L1.46344 6.20491C1.18806 5.92445 1.13349 5.49478 1.33002 5.15438L2.56666 3.01245C2.76319 2.67206 3.16258 2.50448 3.54316 2.60273L4.62206 2.88127L4.92031 1.80756ZM4.54541 10.843L4.54552 10.8433L4.54541 10.843ZM5.98508 2.33341L5.66952 3.46945C5.54185 3.92906 5.06958 4.20173 4.60771 4.08249L3.46618 3.78778L2.45122 5.54572L3.2773 6.38705C3.6115 6.72742 3.6115 7.27275 3.2773 7.61312L2.45122 8.45444L3.46617 10.2124L4.60771 9.91768C5.06958 9.79844 5.54185 10.0711 5.66952 10.5307L5.98508 11.6667H8.01498L8.33056 10.5307C8.45823 10.071 8.9305 9.79838 9.39237 9.91762L10.5341 10.2124L11.5491 8.45444L10.723 7.61312C10.3888 7.27275 10.3888 6.72742 10.723 6.38705L11.5491 5.54572L10.5341 3.78778L9.39237 4.08254C8.9305 4.20178 8.45823 3.92912 8.33056 3.46951L8.01498 2.33341H5.98508ZM7.00003 5.83342C6.3557 5.83342 5.83337 6.35575 5.83337 7.00008C5.83337 7.64441 6.3557 8.16675 7.00003 8.16675C7.64436 8.16675 8.1667 7.64441 8.1667 7.00008C8.1667 6.35575 7.64436 5.83342 7.00003 5.83342ZM4.6667 7.00008C4.6667 5.71142 5.71137 4.66675 7.00003 4.66675C8.2887 4.66675 9.33337 5.71142 9.33337 7.00008C9.33337 8.28875 8.2887 9.33342 7.00003 9.33342C5.71137 9.33342 4.6667 8.28875 4.6667 7.00008Z\"\n fill=\"currentColor\" />\n </svg>\n </span>\n <nz-dropdown-menu #menu=\"nzDropdownMenu\">\n <div class=\"hd-table-col-settings-dropdown\">\n <div class=\"hd-table-col-settings-list\">\n <div *ngIf=\"showListNodes && nowListNodes.length > 0\" nz-menu style=\"padding: 5px 10px;\">\n <nz-tree *ngIf=\"showListNodes\" [nzData]=\"nowListNodes\" nzCheckable nzDraggable nzBlockNode\n nzShowExpand=\"false\" (nzCheckBoxChange)=\"checkAction($event)\" [nzBeforeDrop]=\"beforeDrop\"\n [nzTreeTemplate]=\"nzTreeTemplate\">\n </nz-tree>\n <ng-template #nzTreeTemplate let-node>\n <span\n class=\"ng-tns-c31-110 draggable ng-star-inserted ant-tree-node-content-wrapper ant-tree-node-content-wrapper-close\"\n [title]=\"node.key\" draggable=\"true\" aria-grabbed=\"true\">\n <span class=\"ant-tree-title\">\n <div class=\"hd-table-tree-node\">\n <span>{{node.key}}</span>\n <div *ngIf=\"!node.origin.disabled\" class=\"hd-table-tree-node-img\">\n <i nz-icon nzType=\"caret-up\" nzTheme=\"outline\"></i>\n <i nz-icon nzType=\"caret-down\" nzTheme=\"outline\"></i>\n </div>\n </div>\n </span>\n </span>\n </ng-template>\n </div>\n <div *ngIf=\"showListNodes && hideListNodes.length > 0\" nz-menu style=\"padding: 5px 10px;\">\n <nz-tree *ngIf=\"showListNodes\" [nzData]=\"hideListNodes\" nzCheckable nzShowExpand=\"false\"\n (nzCheckBoxChange)=\"checkAction($event)\">\n </nz-tree>\n </div>\n </div>\n <div class=\"hd-table-col-settings-footer\">\n <hd-button style=\"margin-right: 4px;\" type=\"default\" size=\"small\" (clickAction)=\"cancelDropdown()\">\u53D6\u6D88\n </hd-button>\n <hd-button type=\"primary\" size=\"small\" (clickAction)=\"submitGrids()\">\u5B8C\u6210</hd-button>\n </div>\n </div>\n </nz-dropdown-menu>\n </ng-template>\n </hd-button-group>\n <hd-space type=\"row\" size=\"12\"></hd-space>\n <ng-container *ngTemplateOutlet=\"tableTotal\"></ng-container>\n <hd-space *ngIf=\"tableTotal\" type=\"row\" size=\"12\"></hd-space>\n <nz-table *ngIf=\"showTable\" #hdTable class=\"hd-table-container\" [class.hd-table--virtual]=\"useVirtualScroll\"\n [class.hd-table--scroll-y]=\"!!(scroll && scroll.y)\" [class.hd-table--scroll-x]=\"!!(scroll && scroll.x)\"\n [class.hd-table--has-total]=\"showTableTotal\"\n [nzScroll]=\"scroll\"\n [nzShowPagination]=\"pagination\" [nzShowSizeChanger]=\"pagination\" [nzShowQuickJumper]=\"pagination\"\n [nzFrontPagination]=\"useFrontPagination\" nzSize=\"middle\" [nzData]=\"tableData.content\"\n [nzTotal]=\"getTableTotalCount()\" [(nzPageIndex)]=\"tablePageIndex\" [nzLoading]=\"tableLoading\"\n [nzPageSizeOptions]=\"[ 10, 50, 100, 200, 500, 1000 ]\" [(nzPageSize)]=\"tablePageSize\"\n (nzPageSizeChange)=\"pagination ? search(true) : null\"\n (nzPageIndexChange)=\"pagination ? search(false) : null\"\n (nzCurrentPageDataChange)=\"showSelected ? currentPageDataChange($event) : null\"\n [nzShowTotal]=\"tableTotalTemplate\" [nzFooter]=\"showTableTotal ? tableTotalFooter : null\"\n [nzVirtualScroll]=\"useVirtualScroll\" [nzVirtualItemSize]=\"useVirtualScroll ? effectiveVirtualItemSize : 0\"\n [nzVirtualForTrackBy]=\"virtualTrackByRow\">\n <thead (nzSortChange)=\"sort($event)\" nzSingleSort>\n <tr>\n <th nzWidth=\"40px\" nzLeft=\"0px\" *ngIf=\"showSelected\" nzShowCheckbox [(nzChecked)]=\"isAllDisplayDataChecked\"\n [nzIndeterminate]=\"isIndeterminate\" (nzCheckedChange)=\"checkAll($event)\"></th>\n <th class=\"hd-table-line-no-col\" [nzWidth]=\"lineNumberColWidthPx\" [nzLeft]=\"lineNumberLeft\"\n *ngIf=\"showTableTotal\">\u5E8F\u53F7</th>\n <ng-container *ngFor=\"let col of tableCols\">\n <th *ngIf=\"col.isShow\" [nzWidth]=\"col.width + 'px'\" [nzAlign]=\"col.align\"\n [nzLeft]=\"getLeftSticky(col)\"\n [nzRight]=\"getRightSticky(col)\" nz-resizable nzBounds=\"window\" nzPreview\n (nzResizeEnd)=\"onResize($event, col)\" [nzShowSort]=\"col.canSort\" [nzSortKey]=\"col.name\"\n [nzSort]=\"getColSort(col)\">\n <ng-container *ngIf=\"getTitleParts(col) as titleParts; else plainTitle\">\n <span class=\"hd-table-title-with-bar\">{{ titleParts[0] }}<i class=\"hd-table-row-no-bar\"></i>{{ titleParts[1] }}</span>\n </ng-container>\n <ng-template #plainTitle>{{ col.title }}</ng-template>\n <nz-resize-handle nzDirection=\"right\">\n <div class=\"resize-trigger\"></div>\n </nz-resize-handle>\n </th>\n </ng-container>\n </tr>\n </thead>\n <tbody>\n <ng-template *ngIf=\"useVirtualScroll\" nz-virtual-scroll let-data let-index=\"index\">\n <tr class=\"hd-table-virtual-row\" [class.hd-table-row-invalid]=\"isInvalidRow(data)\">\n <ng-container *ngTemplateOutlet=\"tableCells; context: { $implicit: data, index: index }\"></ng-container>\n </tr>\n </ng-template>\n <ng-container *ngIf=\"!useVirtualScroll\">\n <tr *ngFor=\"let data of hdTable.data; trackBy: trackByRow; index as i\"\n [class.hd-table-row-invalid]=\"isInvalidRow(data)\">\n <ng-container *ngTemplateOutlet=\"tableCells; context: { $implicit: data, index: i }\"></ng-container>\n </tr>\n </ng-container>\n </tbody>\n <ng-template #tableTotalTemplate>\n \u5171 {{ getTableTotalCount() }} \u6761\u6570\u636E\n </ng-template>\n <ng-template #tableTotalFooter>\n <!--\n \u5217\u603B\u5BBD < \u5BB9\u5668\uFF1Afluid\uFF0C\u8868\u5BBD 100%\uFF0C\u4E0E\u8868\u4F53\u540C\u6BD4\u4F8B\u88AB\u6491\u5F00\uFF0C\u4E0D\u518D\u6309\u58F0\u660E px \u9501\u6B7B\uFF1B\n \u5217\u603B\u5BBD > \u5BB9\u5668\uFF1Afixed\uFF0C\u8868\u5BBD = scroll.x\uFF0C\u6A2A\u6EDA\u4E0E\u8868\u4F53\u540C\u6B65\u3002\n -->\n <div class=\"hd-table-total-footer\"\n [class.hd-table-total-footer--fluid]=\"isTotalFooterFluid\"\n [class.hd-table-total-footer--y-gutter]=\"totalFooterNeedYGutter\">\n <table class=\"hd-table-total-footer-table\" [style.width]=\"totalFooterTableWidth\">\n <colgroup>\n <!-- \u52FE\u9009/\u5E8F\u53F7\u9501\u5BBD\uFF0C\u4E0D\u53C2\u4E0E\u5747\u644A -->\n <col *ngIf=\"showSelected\" style=\"width: 40px; min-width: 40px; max-width: 40px;\" />\n <col *ngIf=\"showTableTotal\"\n [style.width.px]=\"lineNumberColWidth\"\n [style.min-width.px]=\"lineNumberColWidth\"\n [style.max-width.px]=\"lineNumberColWidth\" />\n <ng-container *ngFor=\"let col of tableCols; trackBy: trackByCol\">\n <col *ngIf=\"col.isShow\" [style.width.px]=\"col.width\" />\n </ng-container>\n </colgroup>\n <tr class=\"hd-table-total\">\n <td *ngIf=\"showSelected\" class=\"hd-table-total-footer-cell hd-table-total-footer-select\"\n [class.hd-table-total-footer-sticky-left]=\"!isTotalFooterFluid\"\n style=\"left: 0;\">&nbsp;</td>\n <td class=\"hd-table-total-footer-cell hd-table-total-footer-line-no\"\n [class.hd-table-total-footer-sticky-left]=\"!isTotalFooterFluid\"\n [style.left]=\"!isTotalFooterFluid ? lineNumberLeft : null\">\u5408\u8BA1</td>\n <ng-container *ngFor=\"let col of tableCols; let colIndex = index; trackBy: trackByCol\">\n <td *ngIf=\"col.isShow\" class=\"hd-table-total-footer-cell\"\n [class.hd-table-total-footer-sticky-left]=\"!isTotalFooterFluid && col.fixed === 'left'\"\n [class.hd-table-total-footer-sticky-right]=\"!isTotalFooterFluid && col.fixed === 'right'\"\n [class.hd-table-total-align-left]=\"getTableTotalCellAlign(col, colIndex) === 'left'\"\n [class.hd-table-total-align-center]=\"getTableTotalCellAlign(col, colIndex) === 'center'\"\n [class.hd-table-total-align-right]=\"getTableTotalCellAlign(col, colIndex) === 'right'\"\n [style.left]=\"!isTotalFooterFluid && col.fixed === 'left' ? (col.fixedWidth || 0) + 'px' : null\"\n [style.right]=\"!isTotalFooterFluid && col.fixed === 'right' ? (col.fixedRightWidth || 0) + 'px' : null\"\n [ngStyle]=\"{'text-align': getTableTotalCellAlign(col, colIndex)}\">\n {{ getTableTotalCellValue(col, colIndex) }}\n </td>\n </ng-container>\n </tr>\n </table>\n </div>\n </ng-template>\n </nz-table>\n</ng-container>\n\n<ng-template #tableCells let-data let-index=\"index\">\n <td nzWidth=\"40px\" nzLeft=\"0px\" *ngIf=\"showSelected\" nzShowCheckbox [nzChecked]=\"mapOfCheckedId[data[selectField]]\"\n [nzDisabled]=\"isSelectDisabled(data)\" (nzCheckedChange)=\"refreshStatus($event, data)\"></td>\n <td class=\"hd-table-line-no-col\" [nzWidth]=\"lineNumberColWidthPx\" [nzLeft]=\"lineNumberLeft\"\n *ngIf=\"showTableTotal\">{{ getLineNumber(index) }}</td>\n <ng-container *ngFor=\"let col of tableCols; trackBy: trackByCol\">\n <td *ngIf=\"col.isShow\" [ngStyle]=\"{'max-width': col.width + 'px'}\" [nzAlign]=\"col.align\"\n [nzLeft]=\"getLeftSticky(col)\"\n [nzRight]=\"getRightSticky(col)\"\n [ngClass]=\"(col.canWarp && showDetail) ? 'common-td-wrap' : ''\">\n <ng-container *ngIf=\"col.title === '\u64CD\u4F5C';else notOperateTemplate\">\n <div class=\"common-btn-group\">\n <ng-container *ngFor=\"let btn of col.btnList\">\n <ng-container *ngIf=\"!needShowConfirm(btn, data);else showConfirmTemplate\">\n <a *ngIf=\"btn.permission ? btn.permission(data) : true\"\n [class]=\"isDangerBtn(btn, data) ? 'common-danger-btn': ''\"\n (click)=\"triggerEvent(btn.click || null, data)\">{{ getBtnName(btn, data) }}</a>\n </ng-container>\n <ng-template #showConfirmTemplate>\n <a *ngIf=\"btn.permission ? btn.permission(data) : true\"\n [class]=\"isDangerBtn(btn, data) ? 'common-danger-btn': ''\" nz-popconfirm\n [nzPopconfirmTitle]=\"'\u786E\u8BA4\u8981' + getBtnName(btn, data) + '\u5417?'\"\n (nzOnConfirm)=\"triggerEvent(btn.click || null, data)\">{{\n getBtnName(btn, data) }}</a>\n </ng-template>\n </ng-container>\n </div>\n </ng-container>\n <ng-template #notOperateTemplate>\n <ng-container *ngIf=\"hasInlineEdit(col); else displayCellTpl\">\n <div class=\"hd-table-cell-edit\">\n <ng-container [ngSwitch]=\"col.editType\">\n <input *ngSwitchCase=\"'input'\" nz-input class=\"hd-table-cell-edit-control\"\n [placeholder]=\"col.placeholder || ''\"\n [disabled]=\"isEditDisabled(col, data)\"\n [ngModel]=\"data[col.name]\"\n (ngModelChange)=\"onCellChange(col, data, $event)\" />\n <nz-input-number *ngSwitchCase=\"'inputNumber'\" class=\"hd-table-cell-edit-control\"\n [nzPlaceHolder]=\"col.placeholder || ''\"\n [nzDisabled]=\"isEditDisabled(col, data)\"\n [nzMin]=\"getInputNumberProp(col, 'min', 0)\"\n [nzMax]=\"getInputNumberProp(col, 'max', 99999999)\"\n [nzStep]=\"getInputNumberProp(col, 'step', 1)\"\n [nzPrecision]=\"getInputNumberProp(col, 'precision', 4)\"\n [ngModel]=\"data[col.name]\"\n (ngModelChange)=\"onCellChange(col, data, $event)\">\n </nz-input-number>\n <nz-select *ngSwitchCase=\"'select'\" class=\"hd-table-cell-edit-control\"\n [nzPlaceHolder]=\"col.placeholder || '\u8BF7\u9009\u62E9'\"\n [nzDisabled]=\"isEditDisabled(col, data)\"\n [nzAllowClear]=\"col.selectOption && col.selectOption.hdAllowClear !== false\"\n [nzShowSearch]=\"!col.selectOption || col.selectOption.hdShowSearch !== false\"\n [ngModel]=\"data[col.name]\"\n (ngModelChange)=\"onSelectChange(col, data, $event)\">\n <nz-option *ngFor=\"let selectItem of getSelectList(col, data)\"\n [nzValue]=\"selectItem[col.selectOption.value]\"\n [nzLabel]=\"getSelectOptionLabel(col, selectItem)\">\n </nz-option>\n </nz-select>\n </ng-container>\n </div>\n </ng-container>\n <ng-template #displayCellTpl>\n <div [class.hd-table-cell-with-actions]=\"col.btnList && col.btnList.length\">\n <div class=\"hd-table-cell-value\"\n [class.hd-table-cell-value--rowno]=\"hasRowNo(col)\"\n [class.hd-table-cell-value--edit]=\"isEditable(col, data)\">\n <ng-container *ngIf=\"col.name === 'state' || col.isState;else otherTemplate\">\n <hd-status [status]=\"data[getStateField(col)]\">\n <ng-container *ngIf=\"(data | hdTableCell:col) as cell\">\n <span *ngIf=\"cell.overflow && !(col.canWarp && showDetail)\" class=\"hd-table-cell-ellipsis\" nz-tooltip\n [nzTooltipTitle]=\"cell.title\">{{ cell.display }}</span>\n <span *ngIf=\"!cell.overflow || (col.canWarp && showDetail)\">{{ cell.display }}</span>\n </ng-container>\n </hd-status>\n </ng-container>\n <ng-template #otherTemplate>\n <ng-container *ngIf=\"col.click && (!col.canClick || col.canClick(data));else noClickTemplate\">\n <ng-container *ngIf=\"(data | hdTableCell:col) as cell\">\n <a *ngIf=\"cell.overflow && !(col.canWarp && showDetail)\" class=\"hd-table-cell-ellipsis\" nz-tooltip\n [nzTooltipTitle]=\"cell.title\"\n [ngStyle]=\"{'color': getLinkCellColor(col, data, cell.isEmpty)}\"\n (click)=\"triggerEvent(col.click || null, data)\">{{ cell.display }}</a>\n <a *ngIf=\"!cell.overflow || (col.canWarp && showDetail)\"\n [ngStyle]=\"{'color': getLinkCellColor(col, data, cell.isEmpty)}\"\n (click)=\"triggerEvent(col.click || null, data)\">{{ cell.display }}</a>\n </ng-container>\n </ng-container>\n <ng-template #noClickTemplate>\n <ng-container *ngIf=\"(data | hdTableCell:col) as cell\">\n <span *ngIf=\"cell.overflow && !(col.canWarp && showDetail)\" class=\"hd-table-cell-ellipsis\" nz-tooltip\n [nzTooltipTitle]=\"cell.title\"\n [ngStyle]=\"{'color': getPlainCellColor(col, data)}\">{{ cell.display }}</span>\n <span *ngIf=\"!cell.overflow || (col.canWarp && showDetail)\"\n [ngStyle]=\"{'color': getPlainCellColor(col, data)}\">{{ cell.display }}</span>\n </ng-container>\n </ng-template>\n </ng-template>\n <span class=\"hd-table-row-no\" *ngIf=\"hasRowNo(col) && getRowNoText(col, data, index)\">\n <i class=\"hd-table-row-no-bar\"></i>{{ getRowNoText(col, data, index) }}\n </span>\n <a *ngIf=\"isEditable(col, data)\" class=\"hd-table-edit-icon\" href=\"javascript:;\" title=\"\u7F16\u8F91\"\n (click)=\"onEditClick($event, col, data)\">\n <svg width=\"14\" height=\"14\" viewBox=\"0 0 14 14\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"\n aria-hidden=\"true\">\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\"\n d=\"M8.10797 1.42626C8.44968 1.08456 9.0037 1.08456 9.34541 1.42626L10.9746 3.05542C11.3163 3.39713 11.3163 3.95115 10.9746 4.29286L5.01002 10.2574C4.87077 10.3967 4.68863 10.4849 4.49305 10.5078L2.72936 10.7142C2.18281 10.7782 1.71357 10.3278 1.7551 9.77914L1.89441 7.93871C1.9102 7.73007 2.00024 7.53399 2.14819 7.38604L8.10797 1.42626ZM7.67304 3.51111L8.88972 4.72779L9.94337 3.67414L8.72669 2.45746L7.67304 3.51111ZM8.06477 5.55274L6.84808 4.33606L3.04959 8.13456L2.94515 9.51434L4.25672 9.36079L8.06477 5.55274ZM12.25 12.8333L1.75 12.8333V11.6666L12.25 11.6666V12.8333Z\"\n fill=\"currentColor\" />\n </svg>\n </a>\n </div>\n <div class=\"common-btn-group hd-table-cell-actions\" *ngIf=\"col.btnList && col.btnList.length\">\n <ng-container *ngFor=\"let btn of col.btnList\">\n <ng-container *ngIf=\"!needShowConfirm(btn, data);else cellActionConfirmTpl\">\n <a *ngIf=\"btn.permission ? btn.permission(data) : true\"\n [class]=\"isDangerBtn(btn, data) ? 'common-danger-btn': ''\"\n (click)=\"triggerEvent(btn.click || null, data)\">{{ getBtnName(btn, data) }}</a>\n </ng-container>\n <ng-template #cellActionConfirmTpl>\n <a *ngIf=\"btn.permission ? btn.permission(data) : true\"\n [class]=\"isDangerBtn(btn, data) ? 'common-danger-btn': ''\" nz-popconfirm\n [nzPopconfirmTitle]=\"'\u786E\u8BA4\u8981' + getBtnName(btn, data) + '\u5417?'\"\n (nzOnConfirm)=\"triggerEvent(btn.click || null, data)\">{{\n getBtnName(btn, data) }}</a>\n </ng-template>\n </ng-container>\n </div>\n </div>\n </ng-template>\n </ng-template>\n </td>\n </ng-container>\n</ng-template>\n",
12939
13537
  changeDetection: core.ChangeDetectionStrategy.OnPush,
12940
- styles: ["::ng-deep .common-btn-group>a{font-size:14px;font-weight:400;color:#20b95d!important;white-space:nowrap}::ng-deep .common-btn-group .common-danger-btn:hover{color:#f05b24!important}::ng-deep .common-btn-group>a:hover{color:#20bd62!important}::ng-deep .common-btn-group>a:not(:last-child)::after{content:'';margin:0 2px}::ng-deep .common-billNumber>a{color:#3b77e3}button{box-shadow:unset;text-shadow:unset;padding:0 6px!important}::ng-deep .ant-form-item-label>label{color:#4b504e;font-size:14px}::ng-deep .ant-input-number-input{height:32px}::ng-deep .ant-input-number{height:32px}textarea.ant-input{height:auto;min-height:32px}::ng-deep .ant-select-selection--multiple{min-height:32px}::ng-deep .ant-select-selection__rendered>ul>li{height:26px!important;margin-top:3px!important;line-height:26px!important}::ng-deep .ant-advanced-search-form .ant-form-item{margin-bottom:0!important}::ng-deep .ant-select-selection--single{height:32px!important}::ng-deep .ant-input{height:32px}::ng-deep .ant-input[disabled]:hover{border-color:#d9d9d9!important}::ng-deep .ant-select-selection__rendered{line-height:32px!important}::ng-deep .ant-calendar-range-picker-input{text-align:left!important}::ng-deep .ant-calendar-picker{width:100%!important}::ng-deep .ant-row{margin-right:0!important;margin-left:0!important}::ng-deep .ant-col-6{padding-left:12px;padding-right:12px}::ng-deep .ant-col-12{padding-left:12px;padding-right:12px}::ng-deep .ant-col-18{padding-left:12px;padding-right:12px}::ng-deep .ant-col-24{padding-left:12px;padding-right:12px}::ng-deep .ant-alert-info{background-color:#f5f8f6;border:1px solid #cfe3d4}::ng-deep .hd-table-container .ant-table-td-left-sticky,::ng-deep .hd-table-container .ant-table-td-right-sticky,::ng-deep .hd-table-container .ant-table-th-left-sticky,::ng-deep .hd-table-container .ant-table-th-right-sticky{z-index:2;transform:translateZ(0)}::ng-deep .hd-table-container .ant-table-thead>tr>th.ant-table-th-left-sticky,::ng-deep .hd-table-container .ant-table-thead>tr>th.ant-table-th-right-sticky{background:#f5f8f6!important}::ng-deep .hd-table-container .ant-table-tbody>tr>td.ant-table-td-left-sticky,::ng-deep .hd-table-container .ant-table-tbody>tr>td.ant-table-td-right-sticky{background:#fff}::ng-deep .hd-table-container .ant-table-tbody>tr.ant-table-row-hover>td.ant-table-td-left-sticky,::ng-deep .hd-table-container .ant-table-tbody>tr.ant-table-row-hover>td.ant-table-td-right-sticky,::ng-deep .hd-table-container .ant-table-tbody>tr:hover>td.ant-table-td-left-sticky,::ng-deep .hd-table-container .ant-table-tbody>tr:hover>td.ant-table-td-right-sticky{background:#ecf8f1!important}::ng-deep .hd-table-container .ant-table-scroll-position-left .ant-table-td-right-sticky,::ng-deep .hd-table-container .ant-table-scroll-position-left .ant-table-th-right-sticky,::ng-deep .hd-table-container .ant-table-scroll-position-middle .ant-table-td-right-sticky,::ng-deep .hd-table-container .ant-table-scroll-position-middle .ant-table-th-right-sticky,::ng-deep .hd-table-container .ant-table-scroll-position-right .ant-table-td-right-sticky,::ng-deep .hd-table-container .ant-table-scroll-position-right .ant-table-th-right-sticky{box-shadow:none!important}::ng-deep .hd-table-container .ant-table-fixed-right{right:0!important}:host ::ng-deep th{background:#f5f8f6!important;font-weight:700!important;white-space:nowrap;font-size:14px;font-family:PingFangSC-Medium,PingFang SC;color:#2a3634;padding:8px!important;box-sizing:border-box}:host ::ng-deep td{font-weight:400;font-style:normal;font-size:14px;color:#2a3634;text-align:left;white-space:nowrap;padding:8px!important;box-sizing:border-box}::ng-deep .ant-pagination-options{display:inline-flex;align-items:center}::ng-deep .ant-pagination-options .ant-select,::ng-deep .ant-pagination-options .ant-select-selection--single{min-width:100px}::ng-deep .ant-pagination-options-size-changer.ant-select{min-width:100px}::ng-deep .ant-time-picker{width:100%}::ng-deep .cdk-overlay-pane .hd-cascader-menus.ant-cascader-menus>.ant-cascader-menu:only-child{width:-webkit-max-content!important;width:-moz-max-content!important;width:max-content!important;min-width:var(--hd-cascader-menu-min-width,auto);max-width:560px}::ng-deep .cdk-overlay-pane .hd-cascader-menus.ant-cascader-menus>.ant-cascader-menu:only-child .ant-cascader-menu-item{white-space:nowrap}.ant-input-number-disabled,.ant-input[disabled],.ant-select-disabled{color:#4b504e}.nz-resizable-preview{position:absolute;top:0;left:0;z-index:8;border:1px dashed #d1d1d1}.nz-resizable-handle{position:absolute;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;z-index:9}.nz-resizable-handle-top{width:100%;height:10px;top:-5px;left:0}.nz-resizable-handle-right{height:100%}.nz-resizable-handle-bottom{width:100%;height:10px;bottom:-5px;left:0}.nz-resizable-handle-left{width:10px;height:100%;top:0;left:-5px}.nz-resizable-handle-topRight{width:20px;height:20px;top:-5px;right:-5px;z-index:10}.nz-resizable-handle-bottomRight{width:20px;height:20px;right:-5px;bottom:-5px;z-index:10}.nz-resizable-handle-bottomLeft{width:20px;height:20px;bottom:-5px;left:-5px;z-index:10}.nz-resizable-handle-topLeft{width:20px;height:20px;top:-5px;left:-5px;z-index:10}.nz-resizable:not(.nz-resizable-resizing) .nz-resizable-handle-bottom,.nz-resizable:not(.nz-resizable-resizing) .nz-resizable-handle-top{cursor:row-resize}.nz-resizable:not(.nz-resizable-resizing) .nz-resizable-handle-left,.nz-resizable:not(.nz-resizable-resizing) .nz-resizable-handle-right{cursor:col-resize}.nz-resizable:not(.nz-resizable-resizing) .nz-resizable-handle-bottomRight,.nz-resizable:not(.nz-resizable-resizing) .nz-resizable-handle-topLeft{cursor:nwse-resize}.nz-resizable:not(.nz-resizable-resizing) .nz-resizable-handle-bottomLeft,.nz-resizable:not(.nz-resizable-resizing) .nz-resizable-handle-topRight{cursor:nesw-resize}.hd-table-col-settings{display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;width:32px;height:32px;padding:0;margin-left:12px;cursor:pointer;color:#2a3634;background:0 0;border:1px solid #e5e6eb;border-radius:4px;vertical-align:middle;flex-shrink:0}.hd-table-col-settings:hover{color:#20b95d;background:#f5f8f6;border-color:#20b95d}.hd-table-col-settings .hd-table-col-settings-icon{display:block;width:14px;height:14px;flex-shrink:0}.hd-table-cell-with-actions{display:inline-flex;flex-wrap:wrap;align-items:center;-moz-column-gap:12px;column-gap:12px;row-gap:6px;max-width:100%}.hd-table-cell-with-actions .hd-table-cell-value{min-width:0}.hd-table-cell-with-actions .hd-table-cell-actions{flex-shrink:0}.hd-table-col-settings-dropdown{background:#fff;border:1px solid #e5e6eb;border-radius:4px;box-shadow:0 6px 16px rgba(0,0,0,.08),0 3px 6px rgba(0,0,0,.06);overflow:hidden}.hd-table-col-settings-list{max-height:400px;overflow-y:auto}.hd-table-col-settings-footer{text-align:right;background:#fff;padding:4px;border-top:1px solid #f0f0f0}.hd-table-container ::ng-deep .ant-pagination-options-quick-jumper input{border-radius:2px;border:1px solid #d9d9d9}.hd-table-container ::ng-deep .ant-pagination-options .ant-select-selection{border-radius:2px}.hd-table-container ::ng-deep .ant-table-thead>tr>th{border-bottom:1px solid #ecf1ed;white-space:nowrap;text-overflow:ellipsis}.hd-table-container ::ng-deep .ant-table-tbody>tr>td{border-bottom:1px solid #ecf1ed;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.hd-table-container .hd-table-cell-value--edit,.hd-table-container .hd-table-cell-value--rowno{display:inline-flex;align-items:center;min-width:0}.hd-table-container .hd-table-cell-value--edit>a:not(.hd-table-edit-icon),.hd-table-container .hd-table-cell-value--edit>hd-status,.hd-table-container .hd-table-cell-value--edit>span:not(.hd-table-row-no),.hd-table-container .hd-table-cell-value--rowno>a:not(.hd-table-edit-icon),.hd-table-container .hd-table-cell-value--rowno>hd-status,.hd-table-container .hd-table-cell-value--rowno>span:not(.hd-table-row-no){min-width:0}.hd-table-container .hd-table-row-no{display:inline-flex;flex-shrink:0;align-items:center;margin-left:4px;color:#1d1f29;font-size:14px;line-height:22px}.hd-table-container .hd-table-row-no-bar{display:inline-block;flex:0 0 auto;align-self:center;width:1px;height:14px;margin-right:4px;background:#1d1f29;vertical-align:middle}.hd-table-container .hd-table-edit-icon{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;margin-left:2px;width:14px;height:14px;color:#20b95d;line-height:1;cursor:pointer}.hd-table-container .hd-table-edit-icon:hover{color:#20bd62}.hd-table-container .hd-table-edit-icon svg{display:block;width:14px;height:14px}.hd-table-container .hd-table-title-with-bar{display:inline-flex;align-items:center}.hd-table-container .hd-table-title-with-bar .hd-table-row-no-bar{width:1px;height:14px;margin:0 4px;align-self:center}.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid.ant-table-row-hover>td,.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid.ant-table-row-hover>td.ant-table-td-left-sticky,.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid.ant-table-row-hover>td.ant-table-td-right-sticky,.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid:hover>td,.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid:hover>td.ant-table-td-left-sticky,.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid:hover>td.ant-table-td-right-sticky,.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid>td,.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid>td.ant-table-td-left-sticky,.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid>td.ant-table-td-right-sticky{background:#f7f8fa!important;color:#868a9c!important}.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid .common-btn-group>a{color:#20b95d!important}.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid .common-btn-group>a:hover{color:#20bd62!important}.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid .common-btn-group .common-danger-btn:hover{color:#f05b24!important}.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid .hd-table-cell-value>a{color:#20b95d}.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid .common-billNumber>a{color:#3b77e3}.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid .hd-status-text{color:#868a9c!important}.hd-table-container ::ng-deep .hd-table-total>td{border:0!important}.hd-table-container ::ng-deep cdk-virtual-scroll-viewport.ant-table-body .hd-table-virtual-row>td{box-sizing:border-box}.hd-table-container.hd-table--scroll-x ::ng-deep .ant-table-body>table,.hd-table-container.hd-table--scroll-x ::ng-deep .ant-table-header>table,.hd-table-container.hd-table--scroll-x ::ng-deep .cdk-virtual-scroll-content-wrapper>table{table-layout:fixed}.hd-table-container:not(.hd-table--scroll-y):not(.hd-table--scroll-x) ::ng-deep .ant-table-body{max-height:none!important;overflow-y:visible!important}::ng-deep .ant-dropdown-menu{border-radius:0}::ng-deep .ant-dropdown{margin-top:8px!important}.common-td-wrap{white-space:normal!important;word-break:break-all}.hd-table-cell-ellipsis{display:block;max-width:100%;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.nz-resizable-preview{border-width:0 1px 0 0}.resize-trigger{width:10px;height:15px;position:relative;top:calc((100% - 15px)/ 2)}.resize-trigger::after{position:absolute;top:calc((100% - 15px)/ 2);left:0;background:#d5d5d5;content:'';width:1px;height:15px;z-index:1}.nz-resizable-handle-right{position:absolute;width:10px;top:0;right:-5px;z-index:inherit}::ng-deep .ant-table-th-right-sticky .nz-resizable-handle-right{right:0}.hd-table-tree-node{display:inline-flex;align-items:center;padding-right:10px}.hd-table-tree-node .hd-table-tree-node-img{display:flex;flex-direction:column;position:absolute;right:0;margin-top:-2.5px}.hd-table-tree-node .hd-table-tree-node-img i{opacity:.3}.hd-table-tree-node .hd-table-tree-node-img i:last-child{margin-top:-5px}img{width:20px;height:20px}.ant-table-th-left-sticky{z-index:2}::ng-deep .ant-table-thead>tr>th .ant-table-header-column .ant-table-column-sorters>:not(.ant-table-column-sorter){position:unset}.hd-table-cell-edit{width:100%;min-width:0}.hd-table-cell-edit-control{width:100%!important}::ng-deep .hd-table-cell-edit .ant-input,::ng-deep .hd-table-cell-edit .ant-input-number,::ng-deep .hd-table-cell-edit .ant-select{width:100%}::ng-deep .hd-table-cell-edit .ant-input,::ng-deep .hd-table-cell-edit .ant-input-number,::ng-deep .hd-table-cell-edit .ant-select-selection{height:32px}::ng-deep .hd-table-cell-edit .ant-input-number-input{height:30px}::ng-deep .hd-table-cell-edit .ant-select-selection__rendered{line-height:30px}"]
13538
+ styles: ["::ng-deep .common-btn-group>a{font-size:14px;font-weight:400;color:#20b95d!important;white-space:nowrap}::ng-deep .common-btn-group .common-danger-btn:hover{color:#f05b24!important}::ng-deep .common-btn-group>a:hover{color:#20bd62!important}::ng-deep .common-btn-group>a:not(:last-child)::after{content:'';margin:0 2px}::ng-deep .common-billNumber>a{color:#3b77e3}button{box-shadow:unset;text-shadow:unset;padding:0 6px!important}::ng-deep .ant-form-item-label>label{color:#4b504e;font-size:14px}::ng-deep .ant-input-number-input{height:32px}::ng-deep .ant-input-number{height:32px}textarea.ant-input{height:auto;min-height:32px}::ng-deep .ant-select-selection--multiple{min-height:32px}::ng-deep .ant-select-selection__rendered>ul>li{height:26px!important;margin-top:3px!important;line-height:26px!important}::ng-deep .ant-advanced-search-form .ant-form-item{margin-bottom:0!important}::ng-deep .ant-select-selection--single{height:32px!important}::ng-deep .ant-input{height:32px}::ng-deep .ant-input[disabled]:hover{border-color:#d9d9d9!important}::ng-deep .ant-select-selection__rendered{line-height:32px!important}::ng-deep .ant-calendar-range-picker-input{text-align:left!important}::ng-deep .ant-calendar-picker{width:100%!important}::ng-deep .ant-row{margin-right:0!important;margin-left:0!important}::ng-deep .ant-col-6{padding-left:12px;padding-right:12px}::ng-deep .ant-col-12{padding-left:12px;padding-right:12px}::ng-deep .ant-col-18{padding-left:12px;padding-right:12px}::ng-deep .ant-col-24{padding-left:12px;padding-right:12px}::ng-deep .ant-alert-info{background-color:#f5f8f6;border:1px solid #cfe3d4}::ng-deep .hd-table-container .ant-table-td-left-sticky,::ng-deep .hd-table-container .ant-table-td-right-sticky,::ng-deep .hd-table-container .ant-table-th-left-sticky,::ng-deep .hd-table-container .ant-table-th-right-sticky{z-index:2;transform:translateZ(0)}::ng-deep .hd-table-container .ant-table-thead>tr>th.ant-table-th-left-sticky,::ng-deep .hd-table-container .ant-table-thead>tr>th.ant-table-th-right-sticky{background:#f5f8f6!important}::ng-deep .hd-table-container .ant-table-tbody>tr>td.ant-table-td-left-sticky,::ng-deep .hd-table-container .ant-table-tbody>tr>td.ant-table-td-right-sticky{background:#fff}::ng-deep .hd-table-container .ant-table-tbody>tr.ant-table-row-hover>td.ant-table-td-left-sticky,::ng-deep .hd-table-container .ant-table-tbody>tr.ant-table-row-hover>td.ant-table-td-right-sticky,::ng-deep .hd-table-container .ant-table-tbody>tr:hover>td.ant-table-td-left-sticky,::ng-deep .hd-table-container .ant-table-tbody>tr:hover>td.ant-table-td-right-sticky{background:#ecf8f1!important}::ng-deep .hd-table-container .ant-table-scroll-position-left .ant-table-td-right-sticky,::ng-deep .hd-table-container .ant-table-scroll-position-left .ant-table-th-right-sticky,::ng-deep .hd-table-container .ant-table-scroll-position-middle .ant-table-td-right-sticky,::ng-deep .hd-table-container .ant-table-scroll-position-middle .ant-table-th-right-sticky,::ng-deep .hd-table-container .ant-table-scroll-position-right .ant-table-td-right-sticky,::ng-deep .hd-table-container .ant-table-scroll-position-right .ant-table-th-right-sticky{box-shadow:none!important}::ng-deep .hd-table-container .ant-table-fixed-right{right:0!important}:host ::ng-deep th{background:#f5f8f6!important;font-weight:700!important;white-space:nowrap;font-size:14px;font-family:PingFangSC-Medium,PingFang SC;color:#2a3634;padding:8px!important;box-sizing:border-box}:host ::ng-deep td{font-weight:400;font-style:normal;font-size:14px;color:#2a3634;text-align:left;white-space:nowrap;padding:8px!important;box-sizing:border-box}::ng-deep .ant-pagination-options{display:inline-flex;align-items:center}::ng-deep .ant-pagination-options .ant-select,::ng-deep .ant-pagination-options .ant-select-selection--single{min-width:100px}::ng-deep .ant-pagination-options-size-changer.ant-select{min-width:100px}::ng-deep .ant-time-picker{width:100%}::ng-deep .cdk-overlay-pane .hd-cascader-menus.ant-cascader-menus>.ant-cascader-menu:only-child{width:-webkit-max-content!important;width:-moz-max-content!important;width:max-content!important;min-width:var(--hd-cascader-menu-min-width,auto);max-width:560px}::ng-deep .cdk-overlay-pane .hd-cascader-menus.ant-cascader-menus>.ant-cascader-menu:only-child .ant-cascader-menu-item{white-space:nowrap}.ant-input-number-disabled,.ant-input[disabled],.ant-select-disabled{color:#4b504e}.nz-resizable-preview{position:absolute;top:0;left:0;z-index:8;border:1px dashed #d1d1d1}.nz-resizable-handle{position:absolute;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;z-index:9}.nz-resizable-handle-top{width:100%;height:10px;top:-5px;left:0}.nz-resizable-handle-right{height:100%}.nz-resizable-handle-bottom{width:100%;height:10px;bottom:-5px;left:0}.nz-resizable-handle-left{width:10px;height:100%;top:0;left:-5px}.nz-resizable-handle-topRight{width:20px;height:20px;top:-5px;right:-5px;z-index:10}.nz-resizable-handle-bottomRight{width:20px;height:20px;right:-5px;bottom:-5px;z-index:10}.nz-resizable-handle-bottomLeft{width:20px;height:20px;bottom:-5px;left:-5px;z-index:10}.nz-resizable-handle-topLeft{width:20px;height:20px;top:-5px;left:-5px;z-index:10}.nz-resizable:not(.nz-resizable-resizing) .nz-resizable-handle-bottom,.nz-resizable:not(.nz-resizable-resizing) .nz-resizable-handle-top{cursor:row-resize}.nz-resizable:not(.nz-resizable-resizing) .nz-resizable-handle-left,.nz-resizable:not(.nz-resizable-resizing) .nz-resizable-handle-right{cursor:col-resize}.nz-resizable:not(.nz-resizable-resizing) .nz-resizable-handle-bottomRight,.nz-resizable:not(.nz-resizable-resizing) .nz-resizable-handle-topLeft{cursor:nwse-resize}.nz-resizable:not(.nz-resizable-resizing) .nz-resizable-handle-bottomLeft,.nz-resizable:not(.nz-resizable-resizing) .nz-resizable-handle-topRight{cursor:nesw-resize}.hd-table-col-settings{display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;width:32px;height:32px;padding:0;margin-left:12px;cursor:pointer;color:#2a3634;background:0 0;border:1px solid #e5e6eb;border-radius:4px;vertical-align:middle;flex-shrink:0}.hd-table-col-settings:hover{color:#20b95d;background:#f5f8f6;border-color:#20b95d}.hd-table-col-settings .hd-table-col-settings-icon{display:block;width:14px;height:14px;flex-shrink:0}.hd-table-cell-with-actions{display:inline-flex;flex-wrap:wrap;align-items:center;-moz-column-gap:12px;column-gap:12px;row-gap:6px;max-width:100%}.hd-table-cell-with-actions .hd-table-cell-value{min-width:0}.hd-table-cell-with-actions .hd-table-cell-actions{flex-shrink:0}.hd-table-col-settings-dropdown{background:#fff;border:1px solid #e5e6eb;border-radius:4px;box-shadow:0 6px 16px rgba(0,0,0,.08),0 3px 6px rgba(0,0,0,.06);overflow:hidden}.hd-table-col-settings-list{max-height:400px;overflow-y:auto}.hd-table-col-settings-footer{text-align:right;background:#fff;padding:4px;border-top:1px solid #f0f0f0}.hd-table-container ::ng-deep .ant-pagination-options-quick-jumper input{border-radius:2px;border:1px solid #d9d9d9}.hd-table-container ::ng-deep .ant-pagination-options .ant-select-selection{border-radius:2px}.hd-table-container ::ng-deep .ant-table-thead>tr>th{border-bottom:1px solid #ecf1ed;white-space:nowrap;text-overflow:ellipsis}.hd-table-container ::ng-deep .ant-table-tbody>tr>td{border-bottom:1px solid #ecf1ed;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.hd-table-container ::ng-deep .ant-table-tbody>tr>td.hd-table-line-no-col,.hd-table-container ::ng-deep .ant-table-thead>tr>th.hd-table-line-no-col{width:72px!important;min-width:72px!important;max-width:72px!important;box-sizing:border-box}.hd-table-container .hd-table-cell-value--edit,.hd-table-container .hd-table-cell-value--rowno{display:inline-flex;align-items:center;min-width:0}.hd-table-container .hd-table-cell-value--edit>a:not(.hd-table-edit-icon),.hd-table-container .hd-table-cell-value--edit>hd-status,.hd-table-container .hd-table-cell-value--edit>span:not(.hd-table-row-no),.hd-table-container .hd-table-cell-value--rowno>a:not(.hd-table-edit-icon),.hd-table-container .hd-table-cell-value--rowno>hd-status,.hd-table-container .hd-table-cell-value--rowno>span:not(.hd-table-row-no){min-width:0}.hd-table-container .hd-table-row-no{display:inline-flex;flex-shrink:0;align-items:center;margin-left:4px;color:#1d1f29;font-size:14px;line-height:22px}.hd-table-container .hd-table-row-no-bar{display:inline-block;flex:0 0 auto;align-self:center;width:1px;height:14px;margin-right:4px;background:#1d1f29;vertical-align:middle}.hd-table-container .hd-table-edit-icon{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;margin-left:2px;width:14px;height:14px;color:#20b95d;line-height:1;cursor:pointer}.hd-table-container .hd-table-edit-icon:hover{color:#20bd62}.hd-table-container .hd-table-edit-icon svg{display:block;width:14px;height:14px}.hd-table-container .hd-table-title-with-bar{display:inline-flex;align-items:center}.hd-table-container .hd-table-title-with-bar .hd-table-row-no-bar{width:1px;height:14px;margin:0 4px;align-self:center}.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid.ant-table-row-hover>td,.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid.ant-table-row-hover>td.ant-table-td-left-sticky,.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid.ant-table-row-hover>td.ant-table-td-right-sticky,.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid:hover>td,.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid:hover>td.ant-table-td-left-sticky,.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid:hover>td.ant-table-td-right-sticky,.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid>td,.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid>td.ant-table-td-left-sticky,.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid>td.ant-table-td-right-sticky{background:#f7f8fa!important;color:#868a9c!important}.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid .common-btn-group>a{color:#20b95d!important}.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid .common-btn-group>a:hover{color:#20bd62!important}.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid .common-btn-group .common-danger-btn:hover{color:#f05b24!important}.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid .hd-table-cell-value>a{color:#20b95d}.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid .common-billNumber>a{color:#3b77e3}.hd-table-container ::ng-deep .ant-table-tbody>tr.hd-table-row-invalid .hd-status-text{color:#868a9c!important}.hd-table-container ::ng-deep cdk-virtual-scroll-viewport.ant-table-body .hd-table-virtual-row>td{box-sizing:border-box}.hd-table-container.hd-table--scroll-x ::ng-deep .ant-table-body>table,.hd-table-container.hd-table--scroll-x ::ng-deep .ant-table-header>table,.hd-table-container.hd-table--scroll-x ::ng-deep .cdk-virtual-scroll-content-wrapper>table{table-layout:fixed}.hd-table-container:not(.hd-table--scroll-y):not(.hd-table--scroll-x) ::ng-deep .ant-table-body{max-height:none!important;overflow-y:visible!important}.hd-table-container.hd-table--has-total ::ng-deep .ant-table-footer{padding:0;overflow:hidden;background:#fafafa;border-top:1px solid #e8e8e8}.hd-table-total-footer{width:100%;box-sizing:border-box;overflow-x:auto;overflow-y:hidden;background:#fafafa;scrollbar-width:thin;scrollbar-color:transparent transparent}.hd-table-total-footer::-webkit-scrollbar{width:12px;height:0}.hd-table-total-footer::-webkit-scrollbar-track{background:0 0}.hd-table-total-footer::-webkit-scrollbar-thumb{background:padding-box;border:4px solid transparent}.hd-table-total-footer::-webkit-scrollbar-corner{background:0 0}.hd-table-total-footer.hd-table-total-footer--y-gutter{overflow-y:scroll}.hd-table-total-footer.hd-table-total-footer--fluid{overflow-x:hidden}.hd-table-total-footer-table{table-layout:fixed;border-collapse:separate;border-spacing:0}.hd-table-total-footer-cell{padding:12px 8px;font-weight:500;background:#fafafa;box-sizing:border-box;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;border-bottom:0}.hd-table-total-footer-cell.hd-table-total-align-left{text-align:left!important}.hd-table-total-footer-cell.hd-table-total-align-center{text-align:center!important}.hd-table-total-footer-cell.hd-table-total-align-right{text-align:right!important}.hd-table-total-footer-select{width:40px;min-width:40px;max-width:40px;padding-left:8px;padding-right:8px;text-align:center}.hd-table-total-footer-line-no{width:72px;min-width:72px;max-width:72px}.hd-table-total-footer-sticky-left,.hd-table-total-footer-sticky-right{position:-webkit-sticky;position:sticky;z-index:2;background:#fafafa}::ng-deep .ant-dropdown-menu{border-radius:0}::ng-deep .ant-dropdown{margin-top:8px!important}.common-td-wrap{white-space:normal!important;word-break:break-all}.hd-table-cell-ellipsis{display:block;max-width:100%;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.nz-resizable-preview{border-width:0 1px 0 0}.resize-trigger{width:10px;height:15px;position:relative;top:calc((100% - 15px)/ 2)}.resize-trigger::after{position:absolute;top:calc((100% - 15px)/ 2);left:0;background:#d5d5d5;content:'';width:1px;height:15px;z-index:1}.nz-resizable-handle-right{position:absolute;width:10px;top:0;right:-5px;z-index:inherit}::ng-deep .ant-table-th-right-sticky .nz-resizable-handle-right{right:0}.hd-table-tree-node{display:inline-flex;align-items:center;padding-right:10px}.hd-table-tree-node .hd-table-tree-node-img{display:flex;flex-direction:column;position:absolute;right:0;margin-top:-2.5px}.hd-table-tree-node .hd-table-tree-node-img i{opacity:.3}.hd-table-tree-node .hd-table-tree-node-img i:last-child{margin-top:-5px}img{width:20px;height:20px}.ant-table-th-left-sticky{z-index:2}::ng-deep .ant-table-thead>tr>th .ant-table-header-column .ant-table-column-sorters>:not(.ant-table-column-sorter){position:unset}.hd-table-cell-edit{width:100%;min-width:0}.hd-table-cell-edit-control{width:100%!important}::ng-deep .hd-table-cell-edit .ant-input,::ng-deep .hd-table-cell-edit .ant-input-number,::ng-deep .hd-table-cell-edit .ant-select{width:100%}::ng-deep .hd-table-cell-edit .ant-input,::ng-deep .hd-table-cell-edit .ant-input-number,::ng-deep .hd-table-cell-edit .ant-select-selection{height:32px}::ng-deep .hd-table-cell-edit .ant-input-number-input{height:30px}::ng-deep .hd-table-cell-edit .ant-select-selection__rendered{line-height:30px}"]
12941
13539
  }] }
12942
13540
  ];
12943
13541
  /** @nocollapse */
12944
13542
  HdTableComponent.ctorParameters = function () { return [
13543
+ { type: core.ElementRef },
12945
13544
  { type: core.ChangeDetectorRef },
12946
13545
  { type: CommonSessionService }
12947
13546
  ]; };
@@ -12958,6 +13557,7 @@
12958
13557
  rowInvalidField: [{ type: core.Input }],
12959
13558
  showTableTotal: [{ type: core.Input }],
12960
13559
  tableTotalOption: [{ type: core.Input }],
13560
+ columnsNumber: [{ type: core.Input }],
12961
13561
  sortEvent: [{ type: core.Output }],
12962
13562
  selectEvent: [{ type: core.Output }],
12963
13563
  tableSearchEvent: [{ type: core.Output }],
@@ -13039,6 +13639,12 @@
13039
13639
  HdTableComponent.prototype.showTableTotal;
13040
13640
  /** @type {?} */
13041
13641
  HdTableComponent.prototype.tableTotalOption;
13642
+ /**
13643
+ * 合计列总数(含序号列,与 hd-detail-lines 一致);
13644
+ * 不传则按当前可见数据列数 + 1(序号)推算。
13645
+ * @type {?}
13646
+ */
13647
+ HdTableComponent.prototype.columnsNumber;
13042
13648
  /** @type {?} */
13043
13649
  HdTableComponent.prototype.sortEvent;
13044
13650
  /** @type {?} */
@@ -13149,9 +13755,8 @@
13149
13755
  */
13150
13756
  HdTableComponent.prototype.virtualScrollActive;
13151
13757
  /**
13152
- * 可见列总宽,用于判断是否需要横向滚动
13758
+ * 列宽合计(含勾选/序号),footer 表宽与横向 scroll 共用
13153
13759
  * @type {?}
13154
- * @private
13155
13760
  */
13156
13761
  HdTableComponent.prototype.tableColWidthTotal;
13157
13762
  /**
@@ -13173,6 +13778,48 @@
13173
13778
  HdTableComponent.prototype.currentSortValue;
13174
13779
  /** @type {?} */
13175
13780
  HdTableComponent.prototype.nzTableComponent;
13781
+ /**
13782
+ * @type {?}
13783
+ * @private
13784
+ */
13785
+ HdTableComponent.prototype.totalFooterScrollBoundBody;
13786
+ /**
13787
+ * @type {?}
13788
+ * @private
13789
+ */
13790
+ HdTableComponent.prototype.totalFooterScrollHandler;
13791
+ /**
13792
+ * @type {?}
13793
+ * @private
13794
+ */
13795
+ HdTableComponent.prototype.totalFooterSyncRetry;
13796
+ /**
13797
+ * 表体有竖滚条时合计 footer 才预留右侧滚动条槽
13798
+ * @type {?}
13799
+ */
13800
+ HdTableComponent.prototype.totalFooterNeedYGutter;
13801
+ /**
13802
+ * 视口/容器尺寸变化时重算 scroll.x 与合计对齐
13803
+ * @type {?}
13804
+ * @private
13805
+ */
13806
+ HdTableComponent.prototype.viewportResizeTimer;
13807
+ /**
13808
+ * @type {?}
13809
+ * @private
13810
+ */
13811
+ HdTableComponent.prototype.boundOnViewportResize;
13812
+ /**
13813
+ * @type {?}
13814
+ * @private
13815
+ */
13816
+ HdTableComponent.prototype.hostResizeObserver;
13817
+ /**
13818
+ * 序号列固定宽(含 padding,可容纳 6 位如 199995)。
13819
+ * 不锁死时表体会随位数变宽(1→~64px,199995→~67px),合计行对不齐。
13820
+ * @type {?}
13821
+ */
13822
+ HdTableComponent.prototype.lineNumberColWidth;
13176
13823
  /** @type {?} */
13177
13824
  HdTableComponent.prototype.trackByRow;
13178
13825
  /**
@@ -13184,6 +13831,11 @@
13184
13831
  HdTableComponent.prototype.trackByCol;
13185
13832
  /** @type {?} */
13186
13833
  HdTableComponent.prototype.beforeDrop;
13834
+ /**
13835
+ * @type {?}
13836
+ * @private
13837
+ */
13838
+ HdTableComponent.prototype.hostEl;
13187
13839
  /**
13188
13840
  * @type {?}
13189
13841
  * @private
@@ -13853,7 +14505,10 @@
13853
14505
  if (false) {
13854
14506
  /** @type {?} */
13855
14507
  TotalOption.prototype.insertIndex;
13856
- /** @type {?} */
14508
+ /**
14509
+ * 合计值;hd-table 可不传,按 insertIndex 对应列对 content 自动求和
14510
+ * @type {?}
14511
+ */
13857
14512
  TotalOption.prototype.insertValue;
13858
14513
  /** @type {?} */
13859
14514
  TotalOption.prototype.align;
@@ -14214,7 +14869,6 @@
14214
14869
  exports.HdOverlayCleanupService = HdOverlayCleanupService;
14215
14870
  exports.HdTableCellChange = HdTableCellChange;
14216
14871
  exports.HdTableColumn = HdTableColumn;
14217
- exports.HdTableTotalOption = HdTableTotalOption;
14218
14872
  exports.InputNumber = InputNumber;
14219
14873
  exports.OperateBtn = OperateBtn;
14220
14874
  exports.Page = Page;