fantasy-ngzorro 1.2.20 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/fantasy-ngzorro.umd.js +757 -157
- package/bundles/fantasy-ngzorro.umd.js.map +1 -1
- package/bundles/fantasy-ngzorro.umd.min.js +2 -2
- package/bundles/fantasy-ngzorro.umd.min.js.map +1 -1
- package/esm2015/hd-form-lines/hd-form-lines.component.js +521 -15
- package/esm2015/hd-form-lines/hd-form-lines.service.js +12 -22
- package/esm2015/hd-table/hd-table.component.js +1 -3
- package/esm5/hd-form-lines/hd-form-lines.component.js +628 -15
- package/esm5/hd-form-lines/hd-form-lines.service.js +12 -22
- package/esm5/hd-table/hd-table.component.js +1 -3
- package/fantasy-ngzorro.metadata.json +1 -1
- package/fesm2015/fantasy-ngzorro.js +637 -144
- package/fesm2015/fantasy-ngzorro.js.map +1 -1
- package/fesm5/fantasy-ngzorro.js +759 -159
- package/fesm5/fantasy-ngzorro.js.map +1 -1
- package/hd-form-lines/hd-form-lines.component.d.ts +50 -3
- package/hd-form-lines/hd-form-lines.service.d.ts +10 -10
- package/package.json +1 -1
|
@@ -1486,14 +1486,144 @@
|
|
|
1486
1486
|
return HdSpaceModule;
|
|
1487
1487
|
}());
|
|
1488
1488
|
|
|
1489
|
+
/**
|
|
1490
|
+
* @fileoverview added by tsickle
|
|
1491
|
+
* @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
1492
|
+
*/
|
|
1493
|
+
// 控件列表
|
|
1494
|
+
var
|
|
1495
|
+
// 控件列表
|
|
1496
|
+
FormLine = /** @class */ (function () {
|
|
1497
|
+
function FormLine() {
|
|
1498
|
+
// 输入框的提示文件
|
|
1499
|
+
this.require = false; // 是否必填
|
|
1500
|
+
// 是否必填
|
|
1501
|
+
this.hide = false; // 是否为隐藏字段,仅用于填充表单的字段,不显示在页面上
|
|
1502
|
+
// 列对齐方式
|
|
1503
|
+
this.value = null; // 值 不传默认为null
|
|
1504
|
+
// 需要保留小数的列的位数
|
|
1505
|
+
this.inputNumber = new InputNumber(); // number组件的min、max、step
|
|
1506
|
+
// 不可输入状态
|
|
1507
|
+
this.showTime = false; // 日期选择器是否包含时间
|
|
1508
|
+
this.canSearch = false; // 指明hide 情况下的控件是否可以被搜索,默认false
|
|
1509
|
+
}
|
|
1510
|
+
return FormLine;
|
|
1511
|
+
}());
|
|
1512
|
+
if (false) {
|
|
1513
|
+
/** @type {?} */
|
|
1514
|
+
FormLine.prototype.type;
|
|
1515
|
+
/** @type {?} */
|
|
1516
|
+
FormLine.prototype.label;
|
|
1517
|
+
/** @type {?} */
|
|
1518
|
+
FormLine.prototype.name;
|
|
1519
|
+
/** @type {?} */
|
|
1520
|
+
FormLine.prototype.placeholder;
|
|
1521
|
+
/** @type {?} */
|
|
1522
|
+
FormLine.prototype.require;
|
|
1523
|
+
/** @type {?} */
|
|
1524
|
+
FormLine.prototype.hide;
|
|
1525
|
+
/** @type {?} */
|
|
1526
|
+
FormLine.prototype.align;
|
|
1527
|
+
/** @type {?} */
|
|
1528
|
+
FormLine.prototype.value;
|
|
1529
|
+
/** @type {?} */
|
|
1530
|
+
FormLine.prototype.isSelect;
|
|
1531
|
+
/** @type {?} */
|
|
1532
|
+
FormLine.prototype.selectOption;
|
|
1533
|
+
/** @type {?} */
|
|
1534
|
+
FormLine.prototype.explainOptionRight;
|
|
1535
|
+
/** @type {?} */
|
|
1536
|
+
FormLine.prototype.explainOption;
|
|
1537
|
+
/** @type {?} */
|
|
1538
|
+
FormLine.prototype.colorOption;
|
|
1539
|
+
/** @type {?} */
|
|
1540
|
+
FormLine.prototype.maxLength;
|
|
1541
|
+
/** @type {?} */
|
|
1542
|
+
FormLine.prototype.preserveNumber;
|
|
1543
|
+
/** @type {?} */
|
|
1544
|
+
FormLine.prototype.inputNumber;
|
|
1545
|
+
/** @type {?} */
|
|
1546
|
+
FormLine.prototype.onChangeEvent;
|
|
1547
|
+
/** @type {?} */
|
|
1548
|
+
FormLine.prototype.onSearchEvent;
|
|
1549
|
+
/** @type {?} */
|
|
1550
|
+
FormLine.prototype.defaultLabel;
|
|
1551
|
+
/** @type {?} */
|
|
1552
|
+
FormLine.prototype.hdDisabledDate;
|
|
1553
|
+
/** @type {?} */
|
|
1554
|
+
FormLine.prototype.disabled;
|
|
1555
|
+
/** @type {?} */
|
|
1556
|
+
FormLine.prototype.showTime;
|
|
1557
|
+
/** @type {?} */
|
|
1558
|
+
FormLine.prototype.style;
|
|
1559
|
+
/** @type {?} */
|
|
1560
|
+
FormLine.prototype.canSearch;
|
|
1561
|
+
/** @type {?} */
|
|
1562
|
+
FormLine.prototype.onChangeEventDebounceTime;
|
|
1563
|
+
/** @type {?} */
|
|
1564
|
+
FormLine.prototype.onSearchEventEventDebounceTime;
|
|
1565
|
+
}
|
|
1566
|
+
var ColorOption = /** @class */ (function () {
|
|
1567
|
+
function ColorOption() {
|
|
1568
|
+
}
|
|
1569
|
+
return ColorOption;
|
|
1570
|
+
}());
|
|
1571
|
+
if (false) {
|
|
1572
|
+
/** @type {?} */
|
|
1573
|
+
ColorOption.prototype.name;
|
|
1574
|
+
/** @type {?} */
|
|
1575
|
+
ColorOption.prototype.color;
|
|
1576
|
+
}
|
|
1577
|
+
var ExplainOption = /** @class */ (function () {
|
|
1578
|
+
function ExplainOption() {
|
|
1579
|
+
}
|
|
1580
|
+
return ExplainOption;
|
|
1581
|
+
}());
|
|
1582
|
+
if (false) {
|
|
1583
|
+
/** @type {?} */
|
|
1584
|
+
ExplainOption.prototype.show;
|
|
1585
|
+
/** @type {?} */
|
|
1586
|
+
ExplainOption.prototype.name;
|
|
1587
|
+
/** @type {?} */
|
|
1588
|
+
ExplainOption.prototype.color;
|
|
1589
|
+
}
|
|
1590
|
+
/** @enum {string} */
|
|
1591
|
+
var FormLineType = {
|
|
1592
|
+
Input: 'Input',
|
|
1593
|
+
Select: 'Select',
|
|
1594
|
+
Date: 'Date',
|
|
1595
|
+
DateRange: 'DateRange',
|
|
1596
|
+
TextArea: 'TextArea',
|
|
1597
|
+
InputNumber: 'InputNumber',
|
|
1598
|
+
MultipleSelect: 'MultipleSelect',
|
|
1599
|
+
ViewDom: 'ViewDom',
|
|
1600
|
+
Switch: 'Switch',
|
|
1601
|
+
Time: 'Time' // 时间选择器
|
|
1602
|
+
,
|
|
1603
|
+
};
|
|
1604
|
+
var HdFormLinesService = /** @class */ (function () {
|
|
1605
|
+
function HdFormLinesService() {
|
|
1606
|
+
}
|
|
1607
|
+
HdFormLinesService.decorators = [
|
|
1608
|
+
{ type: core.Injectable, args: [{
|
|
1609
|
+
providedIn: 'root'
|
|
1610
|
+
},] }
|
|
1611
|
+
];
|
|
1612
|
+
/** @nocollapse */
|
|
1613
|
+
HdFormLinesService.ctorParameters = function () { return []; };
|
|
1614
|
+
/** @nocollapse */ HdFormLinesService.ngInjectableDef = core.ɵɵdefineInjectable({ factory: function HdFormLinesService_Factory() { return new HdFormLinesService(); }, token: HdFormLinesService, providedIn: "root" });
|
|
1615
|
+
return HdFormLinesService;
|
|
1616
|
+
}());
|
|
1617
|
+
|
|
1489
1618
|
/**
|
|
1490
1619
|
* @fileoverview added by tsickle
|
|
1491
1620
|
* @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
1492
1621
|
*/
|
|
1493
1622
|
var HdFormLinesComponent = /** @class */ (function () {
|
|
1494
|
-
function HdFormLinesComponent(fb) {
|
|
1623
|
+
function HdFormLinesComponent(fb, cdr) {
|
|
1495
1624
|
var _this = this;
|
|
1496
1625
|
this.fb = fb;
|
|
1626
|
+
this.cdr = cdr;
|
|
1497
1627
|
this.tableLoading = false;
|
|
1498
1628
|
this.showSearch = false;
|
|
1499
1629
|
this.operateButtons = ['add', 'delete'];
|
|
@@ -1501,7 +1631,8 @@
|
|
|
1501
1631
|
this.changeEvent = new core.EventEmitter();
|
|
1502
1632
|
this.showDeleteConfirm = false;
|
|
1503
1633
|
this.paginationPageIndex = 1;
|
|
1504
|
-
|
|
1634
|
+
// TODO:这里暂时变成2条去处理,做完之后需要改成10
|
|
1635
|
+
this.paginationPageSize = 3;
|
|
1505
1636
|
// 合计区域
|
|
1506
1637
|
this.showTotal = false;
|
|
1507
1638
|
this.totalOption = [];
|
|
@@ -1520,6 +1651,13 @@
|
|
|
1520
1651
|
// 表单当前的状态
|
|
1521
1652
|
this.searchSubject = new rxjs.Subject();
|
|
1522
1653
|
this.debounceTimeout = 0; // 默认防抖时间
|
|
1654
|
+
// 当前页的dom二维数组
|
|
1655
|
+
this.collectDomList = [];
|
|
1656
|
+
// 当前聚焦的dom元素坐标
|
|
1657
|
+
this.activeDomX = null;
|
|
1658
|
+
this.activeDomY = null;
|
|
1659
|
+
this.activeDom = null;
|
|
1660
|
+
this.activeSelectedComponentOpen = false;
|
|
1523
1661
|
this.textWidthCache = {};
|
|
1524
1662
|
this.searchSubscription = this.searchSubject.pipe(operators.debounceTime(this.debounceTimeout)).subscribe((/**
|
|
1525
1663
|
* @param {?} __0
|
|
@@ -1533,13 +1671,533 @@
|
|
|
1533
1671
|
/**
|
|
1534
1672
|
* @return {?}
|
|
1535
1673
|
*/
|
|
1536
|
-
HdFormLinesComponent.prototype.ngOnInit = /**
|
|
1674
|
+
HdFormLinesComponent.prototype.ngOnInit = /**
|
|
1675
|
+
* @return {?}
|
|
1676
|
+
*/
|
|
1677
|
+
function () {
|
|
1678
|
+
// 缓存一下总的表单数据
|
|
1679
|
+
this.storeFormLinesData = this.formLinesData;
|
|
1680
|
+
this.init();
|
|
1681
|
+
};
|
|
1682
|
+
/**
|
|
1683
|
+
* @return {?}
|
|
1684
|
+
*/
|
|
1685
|
+
HdFormLinesComponent.prototype.ngAfterViewInit = /**
|
|
1686
|
+
* @return {?}
|
|
1687
|
+
*/
|
|
1688
|
+
function () {
|
|
1689
|
+
this.collectDomData();
|
|
1690
|
+
};
|
|
1691
|
+
Object.defineProperty(HdFormLinesComponent.prototype, "formLinesLength", {
|
|
1692
|
+
get: /**
|
|
1693
|
+
* @return {?}
|
|
1694
|
+
*/
|
|
1695
|
+
function () {
|
|
1696
|
+
return this.linesFormArray.controls.length;
|
|
1697
|
+
},
|
|
1698
|
+
enumerable: true,
|
|
1699
|
+
configurable: true
|
|
1700
|
+
});
|
|
1701
|
+
/**
|
|
1702
|
+
* @return {?}
|
|
1703
|
+
*/
|
|
1704
|
+
HdFormLinesComponent.prototype.collectDomData = /**
|
|
1705
|
+
* @return {?}
|
|
1706
|
+
*/
|
|
1707
|
+
function () {
|
|
1708
|
+
this.collectDomList = [];
|
|
1709
|
+
/** @type {?} */
|
|
1710
|
+
var pageDomList = this.formInputDomList.toArray();
|
|
1711
|
+
// Step 1: 获取当前页的数据量
|
|
1712
|
+
/** @type {?} */
|
|
1713
|
+
var startIndex = (this.paginationPageIndex - 1) * this.paginationPageSize;
|
|
1714
|
+
/** @type {?} */
|
|
1715
|
+
var endIndex = this.paginationPageIndex * this.paginationPageSize;
|
|
1716
|
+
/** @type {?} */
|
|
1717
|
+
var adjustedEndIndex = endIndex > this.formLinesLength ? this.formLinesLength : endIndex;
|
|
1718
|
+
/** @type {?} */
|
|
1719
|
+
var pageLinesLength = adjustedEndIndex - startIndex;
|
|
1720
|
+
/** @type {?} */
|
|
1721
|
+
var interval = pageDomList.length / pageLinesLength;
|
|
1722
|
+
// Step 2: 拆分formInputDomList
|
|
1723
|
+
for (var i = 0; i < pageLinesLength; i++) {
|
|
1724
|
+
this.collectDomList.push(pageDomList.splice(0, interval));
|
|
1725
|
+
}
|
|
1726
|
+
// 关闭所有NzInputNumberComponent的键盘上下箭头触发+-的功能
|
|
1727
|
+
for (var i = 0; i < this.collectDomList.length; i++) {
|
|
1728
|
+
for (var j = 0; j < this.collectDomList[i].length; j++) {
|
|
1729
|
+
/** @type {?} */
|
|
1730
|
+
var dom = this.collectDomList[i][j];
|
|
1731
|
+
if (dom instanceof ngZorroAntd.NzInputNumberComponent) {
|
|
1732
|
+
dom.down = (/**
|
|
1733
|
+
* @return {?}
|
|
1734
|
+
*/
|
|
1735
|
+
function () { });
|
|
1736
|
+
dom.up = (/**
|
|
1737
|
+
* @return {?}
|
|
1738
|
+
*/
|
|
1739
|
+
function () { });
|
|
1740
|
+
}
|
|
1741
|
+
}
|
|
1742
|
+
}
|
|
1743
|
+
};
|
|
1744
|
+
// 聚焦下一个dom
|
|
1745
|
+
// 聚焦下一个dom
|
|
1746
|
+
/**
|
|
1747
|
+
* @param {?} x
|
|
1748
|
+
* @param {?} y
|
|
1749
|
+
* @return {?}
|
|
1750
|
+
*/
|
|
1751
|
+
HdFormLinesComponent.prototype.jumpToNextInput =
|
|
1752
|
+
// 聚焦下一个dom
|
|
1753
|
+
/**
|
|
1754
|
+
* @param {?} x
|
|
1755
|
+
* @param {?} y
|
|
1756
|
+
* @return {?}
|
|
1757
|
+
*/
|
|
1758
|
+
function (x, y) {
|
|
1759
|
+
if (x === null || y === null || !this.collectDomList || this.collectDomList.length === 0) {
|
|
1760
|
+
return;
|
|
1761
|
+
}
|
|
1762
|
+
// 如果是最后一个可输入元素,新增行
|
|
1763
|
+
if (x === this.collectDomList.length - 1 && y === this.collectDomList[0].length - 1) {
|
|
1764
|
+
this.addNewLineAndFocus();
|
|
1765
|
+
}
|
|
1766
|
+
else {
|
|
1767
|
+
if (y === this.collectDomList[0].length - 1) {
|
|
1768
|
+
// 如果是最后一列,则跳转到下一行第一个输入框
|
|
1769
|
+
this.focusDom(x + 1, 0, 'right');
|
|
1770
|
+
}
|
|
1771
|
+
else {
|
|
1772
|
+
// 如果不是最后一列,则跳转到当前行下一个输入框
|
|
1773
|
+
this.focusDom(x, y + 1, 'right');
|
|
1774
|
+
}
|
|
1775
|
+
}
|
|
1776
|
+
};
|
|
1777
|
+
/**
|
|
1778
|
+
* 增加新行并且聚焦到第一个元素,
|
|
1779
|
+
* 这里要注意,如果存在翻页情况,需要处理
|
|
1780
|
+
*/
|
|
1781
|
+
/**
|
|
1782
|
+
* 增加新行并且聚焦到第一个元素,
|
|
1783
|
+
* 这里要注意,如果存在翻页情况,需要处理
|
|
1784
|
+
* @return {?}
|
|
1785
|
+
*/
|
|
1786
|
+
HdFormLinesComponent.prototype.addNewLineAndFocus = /**
|
|
1787
|
+
* 增加新行并且聚焦到第一个元素,
|
|
1788
|
+
* 这里要注意,如果存在翻页情况,需要处理
|
|
1789
|
+
* @return {?}
|
|
1790
|
+
*/
|
|
1791
|
+
function () {
|
|
1792
|
+
var _this = this;
|
|
1793
|
+
// 当前行为当前页最后一行的时候,判断下一页是否有数据
|
|
1794
|
+
// 1、如果有:翻页+聚焦第一行第一个元素
|
|
1795
|
+
// 2、如果没有:新增行+翻页+聚焦第一行第一个元素
|
|
1796
|
+
if (this.activeDomX === this.paginationPageSize - 1) {
|
|
1797
|
+
// 判断下一页是否有数据
|
|
1798
|
+
if (this.paginationPageIndex < Math.ceil(this.formLinesLength / this.paginationPageSize)) {
|
|
1799
|
+
// 翻页+聚焦第一行第一个元素
|
|
1800
|
+
this.paginationPageIndex++;
|
|
1801
|
+
setTimeout((/**
|
|
1802
|
+
* @return {?}
|
|
1803
|
+
*/
|
|
1804
|
+
function () {
|
|
1805
|
+
_this.collectDomData();
|
|
1806
|
+
_this.focusDom(0, 0, 'right');
|
|
1807
|
+
}), 0);
|
|
1808
|
+
}
|
|
1809
|
+
else {
|
|
1810
|
+
// 新增行+翻页+聚焦第一行第一个元素
|
|
1811
|
+
this.addFormLine();
|
|
1812
|
+
this.paginationPageIndex++;
|
|
1813
|
+
setTimeout((/**
|
|
1814
|
+
* @return {?}
|
|
1815
|
+
*/
|
|
1816
|
+
function () {
|
|
1817
|
+
_this.collectDomData();
|
|
1818
|
+
_this.focusDom(0, 0);
|
|
1819
|
+
}), 0);
|
|
1820
|
+
}
|
|
1821
|
+
}
|
|
1822
|
+
else {
|
|
1823
|
+
this.addFormLine();
|
|
1824
|
+
}
|
|
1825
|
+
};
|
|
1826
|
+
// 聚焦到上一个dom
|
|
1827
|
+
// 聚焦到上一个dom
|
|
1828
|
+
/**
|
|
1829
|
+
* @param {?} x
|
|
1830
|
+
* @param {?} y
|
|
1831
|
+
* @return {?}
|
|
1832
|
+
*/
|
|
1833
|
+
HdFormLinesComponent.prototype.jumpToPrevInput =
|
|
1834
|
+
// 聚焦到上一个dom
|
|
1835
|
+
/**
|
|
1836
|
+
* @param {?} x
|
|
1837
|
+
* @param {?} y
|
|
1838
|
+
* @return {?}
|
|
1839
|
+
*/
|
|
1840
|
+
function (x, y) {
|
|
1841
|
+
var _this = this;
|
|
1842
|
+
if (x === null || y === null || !this.collectDomList || this.collectDomList.length === 0) {
|
|
1843
|
+
return;
|
|
1844
|
+
}
|
|
1845
|
+
if (x === 0 && y === 0) {
|
|
1846
|
+
// 如果是第一个可输入元素, 判断是否有上一页, 如果有,则翻页+聚焦到上一页最后一个元素
|
|
1847
|
+
if (this.paginationPageIndex > 1) {
|
|
1848
|
+
// 翻页+聚焦到上一页最后一个元素
|
|
1849
|
+
this.paginationPageIndex--;
|
|
1850
|
+
setTimeout((/**
|
|
1851
|
+
* @return {?}
|
|
1852
|
+
*/
|
|
1853
|
+
function () {
|
|
1854
|
+
_this.collectDomData();
|
|
1855
|
+
_this.focusDom(_this.collectDomList.length - 1, _this.collectDomList[0].length - 1);
|
|
1856
|
+
}), 0);
|
|
1857
|
+
}
|
|
1858
|
+
return;
|
|
1859
|
+
}
|
|
1860
|
+
else {
|
|
1861
|
+
if (y === 0) {
|
|
1862
|
+
// 如果是第一列,则跳转到上一行最后一个输入框
|
|
1863
|
+
this.focusDom(x - 1, this.collectDomList[0].length - 1, 'left');
|
|
1864
|
+
}
|
|
1865
|
+
else {
|
|
1866
|
+
// 如果不是第一列,则跳转到当前行上一个输入框
|
|
1867
|
+
this.focusDom(x, y - 1, 'left');
|
|
1868
|
+
}
|
|
1869
|
+
}
|
|
1870
|
+
};
|
|
1871
|
+
/**
|
|
1872
|
+
* 聚焦到某个dom
|
|
1873
|
+
* @param x 坐标x
|
|
1874
|
+
* @param y 坐标y
|
|
1875
|
+
* @param jumpDirection 跳转方向
|
|
1876
|
+
*/
|
|
1877
|
+
/**
|
|
1878
|
+
* 聚焦到某个dom
|
|
1879
|
+
* @param {?} x 坐标x
|
|
1880
|
+
* @param {?} y 坐标y
|
|
1881
|
+
* @param {?=} jumpDirection 跳转方向
|
|
1882
|
+
* @return {?}
|
|
1883
|
+
*/
|
|
1884
|
+
HdFormLinesComponent.prototype.focusDom = /**
|
|
1885
|
+
* 聚焦到某个dom
|
|
1886
|
+
* @param {?} x 坐标x
|
|
1887
|
+
* @param {?} y 坐标y
|
|
1888
|
+
* @param {?=} jumpDirection 跳转方向
|
|
1889
|
+
* @return {?}
|
|
1890
|
+
*/
|
|
1891
|
+
function (x, y, jumpDirection) {
|
|
1892
|
+
if (jumpDirection === void 0) { jumpDirection = 'right'; }
|
|
1893
|
+
if (x === null || y === null || !this.collectDomList || this.collectDomList.length === 0) {
|
|
1894
|
+
return;
|
|
1895
|
+
}
|
|
1896
|
+
// 先清除一下当前的焦点
|
|
1897
|
+
this.cleanFocusDom(this.activeDomX, this.activeDomY);
|
|
1898
|
+
if (this.collectDomList[x] && this.collectDomList[x][y]) {
|
|
1899
|
+
/** @type {?} */
|
|
1900
|
+
var dom_1 = this.collectDomList[x][y];
|
|
1901
|
+
// 需要判断下一个focus的dom是否是禁用状态,如果是禁用状态需要跳过
|
|
1902
|
+
if (dom_1 instanceof ngZorroAntd.NzSelectComponent) {
|
|
1903
|
+
if (dom_1.nzDisabled) {
|
|
1904
|
+
if (jumpDirection === 'right') {
|
|
1905
|
+
this.jumpToNextInput(x, y);
|
|
1906
|
+
}
|
|
1907
|
+
else if (jumpDirection === 'left') {
|
|
1908
|
+
this.jumpToPrevInput(x, y);
|
|
1909
|
+
}
|
|
1910
|
+
return;
|
|
1911
|
+
}
|
|
1912
|
+
dom_1.nzSelectTopControlComponent.inputElement.nativeElement.scrollIntoView({ behavior: 'smooth', block: 'center', inline: 'center' });
|
|
1913
|
+
// 这里多选框需要额外处理下,因为向下的时候会触发内部Input的聚焦,把下一个dom的focus放到宏任务中,延迟处理。
|
|
1914
|
+
if (dom_1.nzSelectService.mode === 'multiple') {
|
|
1915
|
+
setTimeout((/**
|
|
1916
|
+
* @return {?}
|
|
1917
|
+
*/
|
|
1918
|
+
function () {
|
|
1919
|
+
dom_1.focus();
|
|
1920
|
+
}), 0);
|
|
1921
|
+
}
|
|
1922
|
+
else {
|
|
1923
|
+
dom_1.focus();
|
|
1924
|
+
}
|
|
1925
|
+
}
|
|
1926
|
+
else if (dom_1 instanceof ngZorroAntd.NzInputNumberComponent) {
|
|
1927
|
+
if (dom_1.nzDisabled) {
|
|
1928
|
+
if (jumpDirection === 'right') {
|
|
1929
|
+
this.jumpToNextInput(x, y);
|
|
1930
|
+
}
|
|
1931
|
+
else if (jumpDirection === 'left') {
|
|
1932
|
+
this.jumpToPrevInput(x, y);
|
|
1933
|
+
}
|
|
1934
|
+
return;
|
|
1935
|
+
}
|
|
1936
|
+
/** @type {?} */
|
|
1937
|
+
var inputDom_1 = document.getElementById(dom_1.nzId);
|
|
1938
|
+
inputDom_1.focus();
|
|
1939
|
+
inputDom_1.scrollIntoView({ behavior: 'smooth', block: 'center', inline: 'center' });
|
|
1940
|
+
setTimeout((/**
|
|
1941
|
+
* @return {?}
|
|
1942
|
+
*/
|
|
1943
|
+
function () {
|
|
1944
|
+
inputDom_1.select();
|
|
1945
|
+
}), 0);
|
|
1946
|
+
}
|
|
1947
|
+
else if (dom_1 instanceof core.ElementRef) {
|
|
1948
|
+
if (dom_1.nativeElement.disabled) {
|
|
1949
|
+
if (jumpDirection === 'right') {
|
|
1950
|
+
this.jumpToNextInput(x, y);
|
|
1951
|
+
}
|
|
1952
|
+
else if (jumpDirection === 'left') {
|
|
1953
|
+
this.jumpToPrevInput(x, y);
|
|
1954
|
+
}
|
|
1955
|
+
return;
|
|
1956
|
+
}
|
|
1957
|
+
dom_1.nativeElement.focus();
|
|
1958
|
+
dom_1.nativeElement.scrollIntoView({ behavior: 'smooth', block: 'center', inline: 'center' });
|
|
1959
|
+
setTimeout((/**
|
|
1960
|
+
* @return {?}
|
|
1961
|
+
*/
|
|
1962
|
+
function () {
|
|
1963
|
+
dom_1.nativeElement.select();
|
|
1964
|
+
}), 0);
|
|
1965
|
+
}
|
|
1966
|
+
else if (dom_1 instanceof ngZorroAntd.NzDatePickerComponent || dom_1 instanceof ngZorroAntd.NzRangePickerComponent || dom_1 instanceof ngZorroAntd.NzTimePickerComponent) {
|
|
1967
|
+
// TODO:在ngzorro8.5.x版本,时间相关的选择器没有暴露出open方法,暂时先不处理。(10.x及以上版本提供了open方法)
|
|
1968
|
+
if (jumpDirection === 'right') {
|
|
1969
|
+
this.jumpToNextInput(x, y);
|
|
1970
|
+
}
|
|
1971
|
+
else if (jumpDirection === 'left') {
|
|
1972
|
+
this.jumpToPrevInput(x, y);
|
|
1973
|
+
}
|
|
1974
|
+
return;
|
|
1975
|
+
}
|
|
1976
|
+
this.setActiveDom(x, y);
|
|
1977
|
+
}
|
|
1978
|
+
else {
|
|
1979
|
+
// 没有dom的场景下,需要判断是左还是右,
|
|
1980
|
+
}
|
|
1981
|
+
};
|
|
1982
|
+
/**
|
|
1983
|
+
* @param {?} x
|
|
1984
|
+
* @param {?} y
|
|
1985
|
+
* @return {?}
|
|
1986
|
+
*/
|
|
1987
|
+
HdFormLinesComponent.prototype.cleanFocusDom = /**
|
|
1988
|
+
* @param {?} x
|
|
1989
|
+
* @param {?} y
|
|
1990
|
+
* @return {?}
|
|
1991
|
+
*/
|
|
1992
|
+
function (x, y) {
|
|
1993
|
+
if (x === null || y === null || !this.collectDomList || this.collectDomList.length === 0) {
|
|
1994
|
+
return;
|
|
1995
|
+
}
|
|
1996
|
+
if (this.collectDomList[x] && this.collectDomList[x][y]) {
|
|
1997
|
+
/** @type {?} */
|
|
1998
|
+
var dom = this.collectDomList[x][y];
|
|
1999
|
+
if (dom instanceof ngZorroAntd.NzSelectComponent) {
|
|
2000
|
+
dom.blur();
|
|
2001
|
+
dom.nzOpen = false;
|
|
2002
|
+
}
|
|
2003
|
+
else if (dom instanceof ngZorroAntd.NzInputNumberComponent) {
|
|
2004
|
+
dom.nzOpen = false;
|
|
2005
|
+
dom.blur();
|
|
2006
|
+
}
|
|
2007
|
+
else if (dom instanceof core.ElementRef) {
|
|
2008
|
+
dom.nativeElement.blur();
|
|
2009
|
+
}
|
|
2010
|
+
else { }
|
|
2011
|
+
}
|
|
2012
|
+
};
|
|
2013
|
+
/**
|
|
2014
|
+
* @param {?} x
|
|
2015
|
+
* @param {?} y
|
|
2016
|
+
* @return {?}
|
|
2017
|
+
*/
|
|
2018
|
+
HdFormLinesComponent.prototype.setActiveDom = /**
|
|
2019
|
+
* @param {?} x
|
|
2020
|
+
* @param {?} y
|
|
2021
|
+
* @return {?}
|
|
2022
|
+
*/
|
|
2023
|
+
function (x, y) {
|
|
2024
|
+
this.activeDomX = x;
|
|
2025
|
+
this.activeDomY = y;
|
|
2026
|
+
this.activeDom = this.collectDomList[this.activeDomX][this.activeDomY];
|
|
2027
|
+
if (this.activeDom instanceof ngZorroAntd.NzSelectComponent) {
|
|
2028
|
+
this.activeSelectedComponentOpen = this.activeDom.open;
|
|
2029
|
+
}
|
|
2030
|
+
};
|
|
2031
|
+
/**
|
|
2032
|
+
* 根据行号和列号名称获取当前聚焦的dom位置
|
|
2033
|
+
* @param rowNumber 行号
|
|
2034
|
+
* @param colNumber 列号
|
|
2035
|
+
*/
|
|
2036
|
+
/**
|
|
2037
|
+
* 根据行号和列号名称获取当前聚焦的dom位置
|
|
2038
|
+
* @param {?} rowNumber 行号
|
|
2039
|
+
* @param {?} colNumber 列号
|
|
2040
|
+
* @return {?}
|
|
2041
|
+
*/
|
|
2042
|
+
HdFormLinesComponent.prototype.setActiveDomInFormLines = /**
|
|
2043
|
+
* 根据行号和列号名称获取当前聚焦的dom位置
|
|
2044
|
+
* @param {?} rowNumber 行号
|
|
2045
|
+
* @param {?} colNumber 列号
|
|
2046
|
+
* @return {?}
|
|
2047
|
+
*/
|
|
2048
|
+
function (rowNumber, colNumber) {
|
|
2049
|
+
this.activeDomX = rowNumber;
|
|
2050
|
+
this.activeDomY = this.getDomIndex(colNumber, this.formLines);
|
|
2051
|
+
this.setActiveDom(this.activeDomX, this.activeDomY);
|
|
2052
|
+
};
|
|
2053
|
+
/**
|
|
2054
|
+
* 键盘点击事件
|
|
2055
|
+
* @param event 键盘事件
|
|
2056
|
+
* @returns
|
|
2057
|
+
*/
|
|
2058
|
+
/**
|
|
2059
|
+
* 键盘点击事件
|
|
2060
|
+
* @param {?} event 键盘事件
|
|
2061
|
+
* @return {?}
|
|
2062
|
+
*/
|
|
2063
|
+
HdFormLinesComponent.prototype.onKeyDown = /**
|
|
2064
|
+
* 键盘点击事件
|
|
2065
|
+
* @param {?} event 键盘事件
|
|
2066
|
+
* @return {?}
|
|
2067
|
+
*/
|
|
2068
|
+
function (event) {
|
|
2069
|
+
var _this = this;
|
|
2070
|
+
if (this.activeDomX === null || this.activeDomY === null) {
|
|
2071
|
+
return;
|
|
2072
|
+
}
|
|
2073
|
+
switch (event.key) {
|
|
2074
|
+
case 'ArrowUp':
|
|
2075
|
+
if (this.activeDom instanceof ngZorroAntd.NzSelectComponent && this.activeSelectedComponentOpen) {
|
|
2076
|
+
return;
|
|
2077
|
+
}
|
|
2078
|
+
if (this.activeDomX !== 0) {
|
|
2079
|
+
this.focusDom(this.activeDomX - 1, this.activeDomY);
|
|
2080
|
+
}
|
|
2081
|
+
break;
|
|
2082
|
+
case 'ArrowDown':
|
|
2083
|
+
// 判断是否在最后一行,如果在最后一行,直接+行翻页
|
|
2084
|
+
if (this.activeDom instanceof ngZorroAntd.NzSelectComponent && this.activeSelectedComponentOpen) {
|
|
2085
|
+
return;
|
|
2086
|
+
}
|
|
2087
|
+
if (this.activeDomX !== this.collectDomList.length - 1) {
|
|
2088
|
+
this.focusDom(this.activeDomX + 1, this.activeDomY);
|
|
2089
|
+
}
|
|
2090
|
+
break;
|
|
2091
|
+
case 'ArrowLeft':
|
|
2092
|
+
this.jumpToPrevInput(this.activeDomX, this.activeDomY);
|
|
2093
|
+
break;
|
|
2094
|
+
case 'ArrowRight':
|
|
2095
|
+
this.jumpToNextInput(this.activeDomX, this.activeDomY);
|
|
2096
|
+
break;
|
|
2097
|
+
case 'Enter':
|
|
2098
|
+
if (this.activeDom instanceof ngZorroAntd.NzSelectComponent) {
|
|
2099
|
+
this.activeSelectedComponentOpen = this.activeDom.open;
|
|
2100
|
+
if (this.activeSelectedComponentOpen === false) {
|
|
2101
|
+
this.focusDom(this.activeDomX, this.activeDomY);
|
|
2102
|
+
}
|
|
2103
|
+
break;
|
|
2104
|
+
}
|
|
2105
|
+
if (this.activeDomX === this.collectDomList.length - 1) {
|
|
2106
|
+
this.addNewLineAndFocus();
|
|
2107
|
+
}
|
|
2108
|
+
break;
|
|
2109
|
+
case 'Escape':
|
|
2110
|
+
if (this.activeDom instanceof ngZorroAntd.NzSelectComponent) {
|
|
2111
|
+
/** @type {?} */
|
|
2112
|
+
var nowActiveDom_1 = (/** @type {?} */ (this.activeDom));
|
|
2113
|
+
setTimeout((/**
|
|
2114
|
+
* @return {?}
|
|
2115
|
+
*/
|
|
2116
|
+
function () {
|
|
2117
|
+
_this.activeSelectedComponentOpen = nowActiveDom_1.open;
|
|
2118
|
+
if (_this.activeSelectedComponentOpen === false) {
|
|
2119
|
+
if (nowActiveDom_1.nzSelectService.mode === 'multiple') {
|
|
2120
|
+
setTimeout((/**
|
|
2121
|
+
* @return {?}
|
|
2122
|
+
*/
|
|
2123
|
+
function () {
|
|
2124
|
+
_this.focusDom(_this.activeDomX, _this.activeDomY);
|
|
2125
|
+
}), 0);
|
|
2126
|
+
}
|
|
2127
|
+
else {
|
|
2128
|
+
_this.focusDom(_this.activeDomX, _this.activeDomY);
|
|
2129
|
+
}
|
|
2130
|
+
}
|
|
2131
|
+
}), 0);
|
|
2132
|
+
}
|
|
2133
|
+
break;
|
|
2134
|
+
default:
|
|
2135
|
+
// 如果当前聚焦的是选择框,且键入0-9a-zA-Z,则弹出
|
|
2136
|
+
if (this.activeDom instanceof ngZorroAntd.NzSelectComponent && this.activeSelectedComponentOpen === false && /^[0-9a-zA-Z]$/.test(event.key)) {
|
|
2137
|
+
/** @type {?} */
|
|
2138
|
+
var dom = this.activeDom;
|
|
2139
|
+
dom.nzOpen = true;
|
|
2140
|
+
this.activeSelectedComponentOpen = true;
|
|
2141
|
+
// // TODO:这里暂时注释,不能直接带入键入值,这样会导致输入中文的时候带入英文字符,不符合预期
|
|
2142
|
+
// dom.nzSelectTopControlComponent.inputValue = event.key;
|
|
2143
|
+
// // 获取 input 元素
|
|
2144
|
+
// const inputElement = dom.nzSelectTopControlComponent.inputElement.nativeElement;
|
|
2145
|
+
// setTimeout(() => {
|
|
2146
|
+
// // 触发输入事件,以确保 Angular 检测到值的变化
|
|
2147
|
+
// const eventInput = new Event('input', { bubbles: true });
|
|
2148
|
+
// inputElement.dispatchEvent(eventInput);
|
|
2149
|
+
// }, 0);
|
|
2150
|
+
}
|
|
2151
|
+
break;
|
|
2152
|
+
}
|
|
2153
|
+
};
|
|
2154
|
+
/**
|
|
2155
|
+
* 根据在初始dom下标和数据集 获取在collectDomList中的下标
|
|
2156
|
+
* @param index 初始下标
|
|
2157
|
+
* @param list 数据集
|
|
2158
|
+
* @returns
|
|
2159
|
+
*/
|
|
2160
|
+
/**
|
|
2161
|
+
* 根据在初始dom下标和数据集 获取在collectDomList中的下标
|
|
2162
|
+
* @private
|
|
2163
|
+
* @param {?} index 初始下标
|
|
2164
|
+
* @param {?} list 数据集
|
|
2165
|
+
* @return {?}
|
|
2166
|
+
*/
|
|
2167
|
+
HdFormLinesComponent.prototype.getDomIndex = /**
|
|
2168
|
+
* 根据在初始dom下标和数据集 获取在collectDomList中的下标
|
|
2169
|
+
* @private
|
|
2170
|
+
* @param {?} index 初始下标
|
|
2171
|
+
* @param {?} list 数据集
|
|
2172
|
+
* @return {?}
|
|
2173
|
+
*/
|
|
2174
|
+
function (index, list) {
|
|
2175
|
+
/** @type {?} */
|
|
2176
|
+
var typeList = ['Input', 'Select', 'Date', 'DateRange', 'TextArea', 'InputNumber', 'MultipleSelect'];
|
|
2177
|
+
/** @type {?} */
|
|
2178
|
+
var filterList = [];
|
|
2179
|
+
for (var i = 0; i < list.length; i++) {
|
|
2180
|
+
if (i === index) {
|
|
2181
|
+
return filterList.length;
|
|
2182
|
+
}
|
|
2183
|
+
if (typeList.includes(list[i].type)) {
|
|
2184
|
+
filterList.push(list[i]);
|
|
2185
|
+
}
|
|
2186
|
+
}
|
|
2187
|
+
return null;
|
|
2188
|
+
};
|
|
2189
|
+
// TODO:待删
|
|
2190
|
+
// TODO:待删
|
|
2191
|
+
/**
|
|
2192
|
+
* @return {?}
|
|
2193
|
+
*/
|
|
2194
|
+
HdFormLinesComponent.prototype.testPage =
|
|
2195
|
+
// TODO:待删
|
|
2196
|
+
/**
|
|
1537
2197
|
* @return {?}
|
|
1538
2198
|
*/
|
|
1539
2199
|
function () {
|
|
1540
|
-
|
|
1541
|
-
this.storeFormLinesData = this.formLinesData;
|
|
1542
|
-
this.init();
|
|
2200
|
+
this.paginationPageIndex++;
|
|
1543
2201
|
};
|
|
1544
2202
|
Object.defineProperty(HdFormLinesComponent.prototype, "linesFormArray", {
|
|
1545
2203
|
get: /**
|
|
@@ -1682,14 +2340,18 @@
|
|
|
1682
2340
|
* @param {?} value
|
|
1683
2341
|
* @return {?}
|
|
1684
2342
|
*/
|
|
1685
|
-
function (value) {
|
|
2343
|
+
function (value) {
|
|
2344
|
+
_this.triggerEvent(item.onChangeEvent, value, formGroupTmp);
|
|
2345
|
+
}));
|
|
1686
2346
|
}
|
|
1687
2347
|
else {
|
|
1688
2348
|
formGroupTmp.get(item.name).valueChanges.subscribe((/**
|
|
1689
2349
|
* @param {?} value
|
|
1690
2350
|
* @return {?}
|
|
1691
2351
|
*/
|
|
1692
|
-
function (value) {
|
|
2352
|
+
function (value) {
|
|
2353
|
+
_this.triggerEvent(item.onChangeEvent, value, formGroupTmp);
|
|
2354
|
+
}));
|
|
1693
2355
|
}
|
|
1694
2356
|
}
|
|
1695
2357
|
}));
|
|
@@ -1962,9 +2624,10 @@
|
|
|
1962
2624
|
var formGroupSubmit = this.fb.group(formGroupObj);
|
|
1963
2625
|
this.formLines.forEach((/**
|
|
1964
2626
|
* @param {?} item
|
|
2627
|
+
* @param {?} innerIndex
|
|
1965
2628
|
* @return {?}
|
|
1966
2629
|
*/
|
|
1967
|
-
function (item) {
|
|
2630
|
+
function (item, innerIndex) {
|
|
1968
2631
|
if (item.onChangeEvent) {
|
|
1969
2632
|
if (item.onChangeEvent) {
|
|
1970
2633
|
if (item.onChangeEventDebounceTime) {
|
|
@@ -1972,14 +2635,24 @@
|
|
|
1972
2635
|
* @param {?} value
|
|
1973
2636
|
* @return {?}
|
|
1974
2637
|
*/
|
|
1975
|
-
function (value) {
|
|
2638
|
+
function (value) {
|
|
2639
|
+
if (item.type === FormLineType.Select && value !== null) {
|
|
2640
|
+
_this.jumpToNextInput(_this.activeDomX, _this.activeDomY);
|
|
2641
|
+
}
|
|
2642
|
+
_this.triggerEvent(item.onChangeEvent, value, formGroupSubmit);
|
|
2643
|
+
}));
|
|
1976
2644
|
}
|
|
1977
2645
|
else {
|
|
1978
2646
|
formGroupSubmit.get(item.name).valueChanges.subscribe((/**
|
|
1979
2647
|
* @param {?} value
|
|
1980
2648
|
* @return {?}
|
|
1981
2649
|
*/
|
|
1982
|
-
function (value) {
|
|
2650
|
+
function (value) {
|
|
2651
|
+
if (item.type === FormLineType.Select && value !== null) {
|
|
2652
|
+
_this.jumpToNextInput(_this.activeDomX, _this.activeDomY);
|
|
2653
|
+
}
|
|
2654
|
+
_this.triggerEvent(item.onChangeEvent, value, formGroupSubmit);
|
|
2655
|
+
}));
|
|
1983
2656
|
}
|
|
1984
2657
|
}
|
|
1985
2658
|
}
|
|
@@ -2019,9 +2692,10 @@
|
|
|
2019
2692
|
var _this = this;
|
|
2020
2693
|
this.formLinesData.forEach((/**
|
|
2021
2694
|
* @param {?} formLinesDataItem
|
|
2695
|
+
* @param {?} index
|
|
2022
2696
|
* @return {?}
|
|
2023
2697
|
*/
|
|
2024
|
-
function (formLinesDataItem) {
|
|
2698
|
+
function (formLinesDataItem, index) {
|
|
2025
2699
|
/** @type {?} */
|
|
2026
2700
|
var formGroupObj = {};
|
|
2027
2701
|
_this.formLines.forEach((/**
|
|
@@ -2040,9 +2714,10 @@
|
|
|
2040
2714
|
var formGroupTmp = _this.fb.group(formGroupObj);
|
|
2041
2715
|
_this.formLines.forEach((/**
|
|
2042
2716
|
* @param {?} item
|
|
2717
|
+
* @param {?} innerIndex
|
|
2043
2718
|
* @return {?}
|
|
2044
2719
|
*/
|
|
2045
|
-
function (item) {
|
|
2720
|
+
function (item, innerIndex) {
|
|
2046
2721
|
if (item.onChangeEvent) {
|
|
2047
2722
|
if (item.onChangeEventDebounceTime) {
|
|
2048
2723
|
formGroupTmp.get(item.name).valueChanges.pipe(operators.debounceTime(item.onChangeEventDebounceTime)).subscribe((/**
|
|
@@ -2050,6 +2725,9 @@
|
|
|
2050
2725
|
* @return {?}
|
|
2051
2726
|
*/
|
|
2052
2727
|
function (value) {
|
|
2728
|
+
if (item.type === FormLineType.Select && value !== null) {
|
|
2729
|
+
_this.jumpToNextInput(_this.activeDomX, _this.activeDomY);
|
|
2730
|
+
}
|
|
2053
2731
|
_this.triggerEvent(item.onChangeEvent, value, formGroupTmp);
|
|
2054
2732
|
}));
|
|
2055
2733
|
}
|
|
@@ -2059,6 +2737,9 @@
|
|
|
2059
2737
|
* @return {?}
|
|
2060
2738
|
*/
|
|
2061
2739
|
function (value) {
|
|
2740
|
+
if (item.type === FormLineType.Select && value !== null) {
|
|
2741
|
+
_this.jumpToNextInput(_this.activeDomX, _this.activeDomY);
|
|
2742
|
+
}
|
|
2062
2743
|
_this.triggerEvent(item.onChangeEvent, value, formGroupTmp);
|
|
2063
2744
|
}));
|
|
2064
2745
|
}
|
|
@@ -2078,8 +2759,23 @@
|
|
|
2078
2759
|
* @return {?}
|
|
2079
2760
|
*/
|
|
2080
2761
|
function (index) {
|
|
2762
|
+
var _this = this;
|
|
2081
2763
|
this.linesFormArray.insert(index || this.linesFormArray.controls.length, this.newLineItem());
|
|
2082
2764
|
this.calculateLineNumber();
|
|
2765
|
+
setTimeout((/**
|
|
2766
|
+
* @return {?}
|
|
2767
|
+
*/
|
|
2768
|
+
function () {
|
|
2769
|
+
_this.collectDomData();
|
|
2770
|
+
if (index !== null && index !== undefined) {
|
|
2771
|
+
_this.activeDomX = index;
|
|
2772
|
+
}
|
|
2773
|
+
else {
|
|
2774
|
+
_this.activeDomX = _this.collectDomList.length - 1;
|
|
2775
|
+
}
|
|
2776
|
+
_this.activeDomY = 0;
|
|
2777
|
+
_this.focusDom(_this.activeDomX, _this.activeDomY);
|
|
2778
|
+
}), 0);
|
|
2083
2779
|
};
|
|
2084
2780
|
/**
|
|
2085
2781
|
* @param {?} index
|
|
@@ -2090,6 +2786,7 @@
|
|
|
2090
2786
|
* @return {?}
|
|
2091
2787
|
*/
|
|
2092
2788
|
function (index) {
|
|
2789
|
+
var _this = this;
|
|
2093
2790
|
this.linesFormArray.removeAt(index - 1);
|
|
2094
2791
|
if (!this.isFilterData && this.linesFormArray.controls && this.linesFormArray.controls.length === 0) {
|
|
2095
2792
|
this.addFormLine();
|
|
@@ -2101,6 +2798,12 @@
|
|
|
2101
2798
|
}
|
|
2102
2799
|
this.calculateLineNumber();
|
|
2103
2800
|
}
|
|
2801
|
+
setTimeout((/**
|
|
2802
|
+
* @return {?}
|
|
2803
|
+
*/
|
|
2804
|
+
function () {
|
|
2805
|
+
_this.collectDomData();
|
|
2806
|
+
}), 0);
|
|
2104
2807
|
};
|
|
2105
2808
|
/**
|
|
2106
2809
|
* @param {?} event
|
|
@@ -2111,7 +2814,14 @@
|
|
|
2111
2814
|
* @return {?}
|
|
2112
2815
|
*/
|
|
2113
2816
|
function (event) {
|
|
2817
|
+
var _this = this;
|
|
2114
2818
|
this.paginationPageIndex = event;
|
|
2819
|
+
setTimeout((/**
|
|
2820
|
+
* @return {?}
|
|
2821
|
+
*/
|
|
2822
|
+
function () {
|
|
2823
|
+
_this.collectDomData();
|
|
2824
|
+
}), 0);
|
|
2115
2825
|
};
|
|
2116
2826
|
/**
|
|
2117
2827
|
* @param {?} event
|
|
@@ -2122,7 +2832,14 @@
|
|
|
2122
2832
|
* @return {?}
|
|
2123
2833
|
*/
|
|
2124
2834
|
function (event) {
|
|
2835
|
+
var _this = this;
|
|
2125
2836
|
this.paginationPageSize = event;
|
|
2837
|
+
setTimeout((/**
|
|
2838
|
+
* @return {?}
|
|
2839
|
+
*/
|
|
2840
|
+
function () {
|
|
2841
|
+
_this.collectDomData();
|
|
2842
|
+
}), 0);
|
|
2126
2843
|
};
|
|
2127
2844
|
/**
|
|
2128
2845
|
* @private
|
|
@@ -2342,16 +3059,21 @@
|
|
|
2342
3059
|
};
|
|
2343
3060
|
/**
|
|
2344
3061
|
* @param {?} id
|
|
3062
|
+
* @param {?} rowNumber
|
|
3063
|
+
* @param {?} colNumber
|
|
2345
3064
|
* @return {?}
|
|
2346
3065
|
*/
|
|
2347
3066
|
HdFormLinesComponent.prototype.selectValue = /**
|
|
2348
3067
|
* @param {?} id
|
|
3068
|
+
* @param {?} rowNumber
|
|
3069
|
+
* @param {?} colNumber
|
|
2349
3070
|
* @return {?}
|
|
2350
3071
|
*/
|
|
2351
|
-
function (id) {
|
|
3072
|
+
function (id, rowNumber, colNumber) {
|
|
2352
3073
|
/** @type {?} */
|
|
2353
3074
|
var inputDom = document.querySelector(id);
|
|
2354
3075
|
inputDom.select();
|
|
3076
|
+
this.setActiveDomInFormLines(rowNumber, colNumber);
|
|
2355
3077
|
};
|
|
2356
3078
|
/**
|
|
2357
3079
|
* @param {?} text
|
|
@@ -2404,15 +3126,17 @@
|
|
|
2404
3126
|
HdFormLinesComponent.decorators = [
|
|
2405
3127
|
{ type: core.Component, args: [{
|
|
2406
3128
|
selector: 'hd-form-lines',
|
|
2407
|
-
template: "<hd-button-group *ngIf=\"showForm && showSearch\">\n <ng-template #buttonGroupLeft>\n <nz-input-group [nzSuffix]=\"suffixIconSearch\">\n <input type=\"text\" nz-input (keyup.enter)=\"searchLines()\" placeholder=\"\u8BF7\u8F93\u5165\u5185\u5BB9\u641C\u7D22\" style=\"width: 300px;\"\n [(ngModel)]=\"filterStr\" />\n </nz-input-group>\n <ng-template #suffixIconSearch>\n <i nz-icon nzType=\"search\" (click)=\"searchLines()\"></i>\n </ng-template>\n </ng-template>\n</hd-button-group>\n<hd-space background=\"transparent\" type=\"row\" size=\"16\"></hd-space>\n<form *ngIf=\"showForm\" nz-form [formGroup]=\"validateHdFormLines\"\n class=\"ant-advanced-search-form hd-formLines-container\">\n <nz-table nzTemplateMode [nzFrontPagination]=\"false\" [nzLoading]=\"tableLoading\" [nzScroll]=\"scroll\">\n <thead>\n <tr>\n <th nzWidth=\"58px\" nzLeft=\"0px\">\u5E8F\u53F7</th>\n <ng-container *ngFor=\"let item of formLines\">\n <th *ngIf=\"!item.hide\" [nzAlign]=\"item.align ? item.align : 'left'\">\n <span *ngIf=\"item.require\" style=\"color: red;\">*</span>{{item.label}}\n </th>\n </ng-container>\n <th style=\"width: 80px\" nzRight=\"0\">\u64CD\u4F5C</th>\n </tr>\n </thead>\n <tbody>\n <ng-container\n *ngFor=\"let line of linesFormArray.controls.slice((paginationPageIndex - 1) * paginationPageSize, (paginationPageIndex - 1) * paginationPageSize + paginationPageSize);index as dataIndex\"\n formArrayName=\"lines\">\n <tr [formGroup]=\"line\">\n <td nzWidth=\"58px\" nzLeft=\"0px\">\n {{line.get('lineIndex').value}}\n </td>\n <ng-container *ngFor=\"let formItem of formLines\">\n <td *ngIf=\"!formItem.hide\" [nzAlign]=\"formItem.align ? formItem.align : 'left'\">\n <nz-form-item>\n <nz-form-control [nzErrorTip]=\"formItem.label + '\u4E0D\u80FD\u4E3A\u7A7A'\">\n <ng-container [ngSwitch]=\"formItem.type\">\n <ng-container *ngSwitchCase=\"0\">\n <nz-input-group [nzSuffix]=\"inputCleanTemplate\">\n <input [ngStyle]=\"getStyle(line, formItem, '100px')\" nz-input\n [ngStyle]=\"{'color': formItem?.colorOption?.name ? line.get(formItem.colorOption.name ).value : null}\"\n [id]=\"'input-' + formItem.name + line.get('lineIndex').value\"\n (click)=\"formItem.isSelect ? selectValue('#input-' + formItem.name + line.get('lineIndex').value) : null\"\n [maxlength]=\"formItem.maxLength || null\"\n [placeholder]=\"formItem.placeholder ? formItem.placeholder : '\u8BF7\u8F93\u5165' + formItem.label\"\n [formControlName]=\"formItem.name\" />\n </nz-input-group>\n <ng-template #inputCleanTemplate>\n <i nz-icon nz-tooltip class=\"ant-input-clear-icon\" nzTheme=\"fill\" nzType=\"close-circle\"\n *ngIf=\"line.get(formItem.name).value && !line.get(formItem.name).disabled\"\n (click)=\"inputClean(formItem ,line)\"></i>\n </ng-template>\n </ng-container>\n <ng-container *ngSwitchCase=\"1\">\n <nz-select nzDropdownClassName=\"hd-select-table\"\n *ngIf=\"formItem.selectOption.tableColumns;else nomarlSelectTemplate\"\n [nzShowSearch]=\"formItem.selectOption.hdShowSearch != null ? formItem.selectOption.hdShowSearch : true\"\n [nzAllowClear]=\"formItem.selectOption.hdAllowClear != null ? formItem.selectOption.hdAllowClear : true\"\n [nzServerSearch]=\"formItem.selectOption.hdServerSearch || false\"\n [nzDropdownMatchSelectWidth]=\"formItem.selectOption.hdDropdownMatchSelectWidth ? formItem.selectOption.hdDropdownMatchSelectWidth : false\"\n [nzPlaceHolder]=\"formItem.placeholder ? formItem.placeholder : '\u8BF7\u9009\u62E9' + formItem.label\"\n [formControlName]=\"formItem.name\"\n (nzOnSearch)=\"onSearchEvent(formItem.onSearchEvent || null, $event, line, formItem.onSearchEventEventDebounceTime)\"\n [ngStyle]=\"getStyle(line, formItem, '200px')\">\n <nz-option nzCustomContent nzDisabled>\n <div class=\"hd-option-header\"\n *ngIf=\"(formItem.selectOption?.selectList?.length > 0 || line.get(formItem.selectOption.selectListName)?.value?.length > 0);else emptyTemplate\">\n <div class=\"hd-option-header-column\"\n *ngFor=\"let selectOptionTableColumn of formItem.selectOption.tableColumns;index as index \"\n [ngStyle]=\"{'width': selectOptionTableColumn?.width ? (selectOptionTableColumn.width + ((index === 0 && !selectOptionTableColumn.label) ? 12 : 0) + 'px') : 'unset'}\">\n {{selectOptionTableColumn.label}}\n </div>\n </div>\n <ng-template #emptyTemplate>\n <div class=\"hd-select-empty\">\n <img\n src=\"data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNjRweCIgaGVpZ2h0PSI0MXB4IiB2aWV3Qm94PSIwIDAgNjQgNDEiIHZlcnNpb249IjEuMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayI+CiAgICA8IS0tIEdlbmVyYXRvcjogU2tldGNoIDUyLjUgKDY3NDY5KSAtIGh0dHA6Ly93d3cuYm9oZW1pYW5jb2RpbmcuY29tL3NrZXRjaCAtLT4KICAgIDxnIHN0cm9rZT0ibm9uZSIgc3Ryb2tlLXdpZHRoPSIxIiBmaWxsPSJub25lIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiPgogICAgICAgIDxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKC00NzIuMDAwMDAwLCAtMTMzNS4wMDAwMDApIj4KICAgICAgICAgICAgPGcgIHRyYW5zZm9ybT0idHJhbnNsYXRlKDY0LjAwMDAwMCwgMTExNC4wMDAwMDApIj4KICAgICAgICAgICAgICAgIDxnICB0cmFuc2Zvcm09InRyYW5zbGF0ZSg0MC4wMDAwMDAsIDc4LjAwMDAwMCkiPgogICAgICAgICAgICAgICAgICAgIDxnICB0cmFuc2Zvcm09InRyYW5zbGF0ZSgzNjguMDAwMDAwLCAxNDQuMDAwMDAwKSI+CiAgICAgICAgICAgICAgICAgICAgICAgIDxnID4KICAgICAgICAgICAgICAgICAgICAgICAgICAgIDxlbGxpcHNlICBmaWxsPSIjRjVGNUY1IiBjeD0iMzIiIGN5PSIzMyIgcng9IjMyIiByeT0iNyI+PC9lbGxpcHNlPgogICAgICAgICAgICAgICAgICAgICAgICAgICAgPGcgICB0cmFuc2Zvcm09InRyYW5zbGF0ZSg5LjAwMDAwMCwgMC4wMDAwMDApIiBmaWxsLXJ1bGU9Im5vbnplcm8iIHN0cm9rZT0iI0Q5RDlEOSI+CiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPHBhdGggZD0iTTQ2LDEyLjc2MDU2MDQgTDM1Ljg1NDMwNDcsMS4yNTczOTYzMyBDMzUuMzY3NDQxNCwwLjQ3MzgyNjYwNSAzNC42NTU4Nzg5LDAgMzMuOTA2NzYxNywwIEwxMi4wOTMyMzgzLDAgQzExLjM0NDEyMTEsMCAxMC42MzI1NTg2LDAuNDczOTUwMjU1IDEwLjE0NTY5NTMsMS4yNTczOTYzMyBMMi42MTQ3OTcyN2UtMTIsMTIuNzYwNTYwNCBMMCwyMiBMNDYsMjIgTDQ2LDEyLjc2MDU2MDQgWiIgID48L3BhdGg+CiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPHBhdGggZD0iTTMyLjYxMzI4MTMsMTUuOTMxNSBDMzIuNjEzMjgxMywxNC4zMjU4NTExIDMzLjYwNjk1MzEsMTMuMDAwMjM0IDM0LjgzOTY5OTIsMTMgTDQ2LDEzIEw0NiwzMS4xMzcxMjc3IEM0NiwzMy4yNTg5NTc0IDQ0LjY3OTM4NjcsMzUgNDMuMDUwNDI5NywzNSBMMi45NDk1NzAzMSwzNSBDMS4zMjA1MjM0NCwzNSAwLDMzLjI1ODg0MDQgMCwzMS4xMzcxMjc3IEwwLDEzIEwxMS4xNjAzMDA4LDEzIEMxMi4zOTMwNDY5LDEzIDEzLjM4NjcxODgsMTQuMzIyODA4NSAxMy4zODY3MTg4LDE1LjkyODQ1NzQgTDEzLjM4NjcxODgsMTUuOTQ5NjM4MyBDMTMuMzg2NzE4OCwxNy41NTUyODcyIDE0LjM5MTcxMDksMTguODUxMTgwOSAxNS42MjQ0NTcsMTguODUxMTgwOSBMMzAuMzc1NTQzLDE4Ljg1MTE4MDkgQzMxLjYwODI4OTEsMTguODUxMTgwOSAzMi42MTMyODEzLDE3LjU0MzM1MTEgMzIuNjEzMjgxMywxNS45Mzc3MDIxIEwzMi42MTMyODEzLDE1LjkzMTUgWiIgIGZpbGw9IiNGQUZBRkEiPjwvcGF0aD4KICAgICAgICAgICAgICAgICAgICAgICAgICAgIDwvZz4KICAgICAgICAgICAgICAgICAgICAgICAgPC9nPgogICAgICAgICAgICAgICAgICAgIDwvZz4KICAgICAgICAgICAgICAgIDwvZz4KICAgICAgICAgICAgPC9nPgogICAgICAgIDwvZz4KICAgIDwvZz4KPC9zdmc+\"\n alt=\"empty\">\n <p class=\"ant-empty-description\">\u6682\u65E0\u6570\u636E</p>\n </div>\n </ng-template>\n </nz-option>\n\n <nz-option nzCustomContent\n *ngFor=\"let selectItem of (formItem.selectOption.selectList || line.get(formItem.selectOption.selectListName).value)\"\n [nzValue]=\"selectItem[formItem.selectOption.value]\" [nzLabel]=\"formItem.selectOption.showLabelAndValue ? '['+ selectItem[formItem.selectOption.value] +']' +\n selectItem[formItem.selectOption.label] : selectItem[formItem.selectOption.label]\">\n <div class=\"hd-option-line\">\n <div *ngFor=\"let selectOptionTableColumn of formItem.selectOption.tableColumns\"\n [ngStyle]=\"{'width': selectOptionTableColumn?.width ? selectOptionTableColumn.width + 'px' : 'unset'}\">\n <ng-container *ngIf=\"selectOptionTableColumn.icons;else notPictureTemplate\">\n <ng-container *ngFor=\"let icon of selectOptionTableColumn.icons\">\n <img *ngIf=\"icon.iconName === 'hd-recommend-star' && selectItem[icon.fieldName]\"\n src=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAVpJREFUOE+l07FLQkEcB/Dv7713Zg1GQ0SgW9AmTYVp1BRUokZBEI1u/QVBUBD1D0Rt0dQaPYmotXza1tKQzQ1Fk0iDHr5vPEOTUpO88e77+9zvjjtBh8HTOb8e0hu0eN8Xzz22ikonoGzHdgXcAVB16S75U/mbn/m2AK+mglqbBUAGvCIRuVCJ7HLXQCUTPQOxXi8Q4FolnYWuAH0+HaEpjrdxAyC3VSq33xKgPTWiYYUai8IjUCabw4Zw1XWNF2+OZrXoi+cLImBth4odfQAw0elCW6zdKvU2/wVkYs8ggzBlRqrcI/DrrK1wQ7DWAIToV8lsqGxHDwTY6qYbA1jpCVAux3oBSirhDPYCOL6kE/s/QB77UrnNJoDDVkCN6pI+BJH+6xINQdpKOCf1d/AEYBxgUUQC5PcLbPMDXy1lhGXx7r0G6ExklpBwI0xh2w7ID+UzL71iL/MJdzuZdDL/kXcAAAAASUVORK5CYII=\"\n style=\"width: 16px;height: 16px;\">\n <img *ngIf=\"icon.iconName === 'hd-img-star' && selectItem[icon.fieldName]\"\n src=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAyhJREFUWEe1ll1o1XYYxp8nPUmUihdCV3bAirvYzUC80Xpy3KwTZNR2CdOhDkTBwe6G32XzwqpjE3Qt4pUKZQqDyQZNTp1uY8yCJG0F2d2+LlWOOkShovQkaV45lcJpTdOTHJubBPI+z/Pj//H+/0TGR66uf8sPoz8A/Kstkp38YORxFitmEVU1vm1cBPlp9ZuQXtX0jmfxygQgvxSWBRWlDECvhgrwQFuqLufG4TAtRCaAwCl+IcDXtWEi2KFb7pUFBxCBEpSMMsDWGWEiNzXLe2/BASp2cTuJH+KCRMJ3dGvsrzQQqafAtw0XpBEfIhc00/tswQD8QWM1FP45d4A8V9XJN9k5Nl4vRKoR8G3jMshdyebRPs0cOftaAaRUbAsRrRRRhuczFsF/lPATNQrL3Hr7/nz1lGvvtkwGUSEC8gLkWfMGkAfQMp9J0n8ByhS5J+QDVr+BshBlUu6q3d5v9G3jIcg3GgnJqp2C853iCIB1WU0a1F2iOO2tPnK3CLQ1aJZKLpCfddPrmtoF8uuqZn9iyfcEzVQumYtlQDO9vS8PsprHd4xvAR7I7FuHUIBvdNP9crr0lT7g24U+UNlfh1f6Esrn2ofeuVphbCPyneJuAN+lT0jokZCduum9cobM2Qn9krEGEa6+hi36jEC3aro34vASW3FoG9si8sdGRoKCY6rlnpjLIxGgYhunSPY0AiAiP+mW93EmAN8ujoJobwgAuKOb7orUAHKjY1EwHjwFkGsEoKpVJ6WVH3n/p1oDwVBhk0TK742GV/UKYOZMt5QKoGIbX5E8mgwg4wCbADQn1c1uPvP2gWqB7xjDADck7OwBVan0QFFyQaj2A9wxV60A13XT7Uw1Ar5TlDiBQP6hRHs0a3Ss9n8wuK4jYtN5Em/H6B5ppht7r4jvhEOFtYiUGQEAnhDoV033ZNJwB45xRAS9IBfX1qnhRD7uhhQLENiFQ0Ll9LSBCM7olnu43gUpTjEfiPSB3D6tUQRbcpZ7bbZHLEBYKnRFogxV505rmjzIrtG/6w2fMS0l430RHAVoULBZtdybdQFkCcuqSXUtzxqSpHsBfmUdgJhaiDQAAAAASUVORK5CYII=\"\n style=\"width: 16px;height: 16px;\">\n </ng-container>\n </ng-container>\n <ng-template #notPictureTemplate>\n <ng-container\n *ngIf=\"!isTextOverflow(selectOptionTableColumn.render ? selectOptionTableColumn.render(selectItem) : selectItem[selectOptionTableColumn.name], selectOptionTableColumn.width);else overflowTemplate\">\n <div>{{ judgeColEmpty(selectOptionTableColumn.render ?\n selectOptionTableColumn.render(selectItem) :\n selectItem[selectOptionTableColumn.name])}}</div>\n </ng-container>\n <ng-template #overflowTemplate>\n <div class=\"hd-option-overflow\" nz-tooltip\n [nzTooltipTitle]=\"selectOptionTableColumn.render ? selectOptionTableColumn.render(selectItem) : selectItem[selectOptionTableColumn.name]\">\n {{\n judgeColEmpty(selectOptionTableColumn.render ?\n selectOptionTableColumn.render(selectItem) :\n selectItem[selectOptionTableColumn.name])}}</div>\n </ng-template>\n </ng-template>\n </div>\n </div>\n </nz-option>\n <nz-option\n *ngIf=\"formItem.selectOption.label && line.get(formItem.name) && line.get(formItem.selectOption.label)?.value && line.get(formItem.selectOption.value)?.value\"\n [nzLabel]=\"(formItem.selectOption.value === 'code' || formItem.selectOption.value === 'productCode' || formItem.selectOption.hdShowItemCode) ? ('['+ line.get(formItem.selectOption.value).value + ']' + line.get(formItem.selectOption.label).value) : line.get(formItem.selectOption.label).value\"\n [nzValue]=\"line.get(formItem.selectOption.value).value\" nzHide></nz-option>\n </nz-select>\n <ng-template #nomarlSelectTemplate>\n <nz-select\n [nzShowSearch]=\"formItem.selectOption.hdShowSearch != null ? formItem.selectOption.hdShowSearch : true\"\n [nzAllowClear]=\"formItem.selectOption.hdAllowClear != null ? formItem.selectOption.hdAllowClear : true\"\n [nzServerSearch]=\"formItem.selectOption.hdServerSearch || false\"\n [nzDropdownMatchSelectWidth]=\"formItem.selectOption.hdDropdownMatchSelectWidth ? formItem.selectOption.hdDropdownMatchSelectWidth : false\"\n [nzPlaceHolder]=\"formItem.placeholder ? formItem.placeholder : '\u8BF7\u9009\u62E9' + formItem.label\"\n [formControlName]=\"formItem.name\"\n (nzOnSearch)=\"onSearchEvent(formItem.onSearchEvent || null, $event, line, formItem.onSearchEventEventDebounceTime)\"\n [ngStyle]=\"getStyle(line, formItem, '200px')\">\n <nz-option\n *ngFor=\"let selectItem of (formItem.selectOption.selectList || line.get(formItem.selectOption.selectListName).value)\"\n [nzValue]=\"selectItem[formItem.selectOption.value]\" [nzLabel]=\"formItem.selectOption.showLabelAndValue ? '['+ selectItem[formItem.selectOption.value] +']' +\n selectItem[formItem.selectOption.label] : selectItem[formItem.selectOption.label]\">\n </nz-option>\n <nz-option\n *ngIf=\"formItem.selectOption.label && line.get(formItem.name) && line.get(formItem.selectOption.label)?.value && line.get(formItem.selectOption.value)?.value\"\n [nzLabel]=\"(formItem.selectOption.value === 'code' || formItem.selectOption.value === 'productCode' || formItem.selectOption.hdShowItemCode) ? ('['+ line.get(formItem.selectOption.value).value + ']' + line.get(formItem.selectOption.label).value) : line.get(formItem.selectOption.label).value\"\n [nzValue]=\"line.get(formItem.selectOption.value).value\" nzHide></nz-option>\n </nz-select>\n </ng-template>\n\n </ng-container>\n <ng-container *ngSwitchCase=\"2\">\n <nz-date-picker *ngIf=\"formItem.showTime\"\n [nzPlaceHolder]=\"formItem.placeholder ? formItem.placeholder : '\u8BF7\u9009\u62E9' + formItem.label\"\n [formControlName]=\"formItem.name\" [nzDisabledDate]=\"formItem.hdDisabledDate\" nzShowTime\n nzFormat=\"yyyy-MM-dd HH:mm:ss\">\n </nz-date-picker>\n <nz-date-picker *ngIf=\"!formItem.showTime\"\n [nzPlaceHolder]=\"formItem.placeholder ? formItem.placeholder : '\u8BF7\u9009\u62E9' + formItem.label\"\n [formControlName]=\"formItem.name\" [nzDisabledDate]=\"formItem.hdDisabledDate\">\n </nz-date-picker>\n </ng-container>\n <ng-container *ngSwitchCase=\"3\">\n <nz-range-picker [nzPlaceHolder]=\"['\u5F00\u59CB\u65E5\u671F','\u7ED3\u675F\u65E5\u671F']\" [formControlName]=\"formItem.name\">\n </nz-range-picker>\n </ng-container>\n <ng-container *ngSwitchCase=\"4\">\n <textarea\n [ngStyle]=\"{'color': formItem?.colorOption?.name ? line.get(formItem.colorOption.name).value : null}\"\n [placeholder]=\"formItem.placeholder ? formItem.placeholder : '\u8BF7\u8F93\u5165' + formItem.label\"\n [maxlength]=\"formItem.maxLength || null\" rows=\"4\" nz-input\n [maxlength]=\"formItem.maxLength || null\" [formControlName]=\"formItem.name\"></textarea>\n </ng-container>\n <ng-container *ngSwitchCase=\"5\">\n <div style=\"display: flex;align-items: center;\">\n <nz-input-number [ngStyle]=\"getStyle(line, formItem, '100px')\"\n [maxlength]=\"formItem.maxLength || null\" [formControlName]=\"formItem.name\"\n [nzMin]=\"formItem?.inputNumber?.min || 0\" [nzMax]=\"formItem?.inputNumber?.max || 99999999\"\n [nzStep]=\"formItem?.inputNumber?.step || 1\"\n [nzPrecision]=\"formItem?.inputNumber?.precision || 2\"\n [nzPlaceHolder]=\"formItem.placeholder ? formItem.placeholder : '\u8BF7\u8F93\u5165' + formItem.label\"\n [nzId]=\"'inputNumber-' + formItem.name + line.get('lineIndex').value\"\n (click)=\"formItem.isSelect ? selectValue('#inputNumber-' + formItem.name + line.get('lineIndex').value) : null\">\n </nz-input-number>\n <div *ngIf=\"formItem?.explainOptionRight?.show\"\n [style.color]=\"formItem?.explainOptionRight?.color ? formItem.explainOptionRight.color : null\">\n {{line.get(formItem.explainOptionRight.name).value}}</div>\n </div>\n </ng-container>\n <ng-container *ngSwitchCase=\"6\">\n <nz-select nzMode=\"multiple\" [nzServerSearch]=\"formItem.selectOption.hdServerSearch || false\"\n [nzDropdownMatchSelectWidth]=\"formItem.selectOption.hdDropdownMatchSelectWidth ? formItem.selectOption.hdDropdownMatchSelectWidth : false\"\n [nzShowSearch]=\"formItem.selectOption.hdShowSearch != null ? formItem.selectOption.hdShowSearch : true\"\n [nzAllowClear]=\"formItem.selectOption.hdAllowClear != null ? formItem.selectOption.hdAllowClear : true\"\n [nzPlaceHolder]=\"formItem.placeholder ? formItem.placeholder : '\u8BF7\u9009\u62E9' + formItem.label\"\n [formControlName]=\"formItem.name\" [ngStyle]=\"getStyle(line, formItem, '200px')\"\n (nzOnSearch)=\"onSearchEvent(formItem.onSearchEvent || null, $event, line, formItem.onSearchEventEventDebounceTime)\">\n <nz-option *ngFor=\"let selectItem of formItem.selectOption.selectList\"\n [nzValue]=\"selectItem[formItem.selectOption.value]\" [nzLabel]=\"formItem.selectOption.showLabelAndValue ? '['+ selectItem[formItem.selectOption.value] +']' +\n selectItem[formItem.selectOption.label] : selectItem[formItem.selectOption.label]\"></nz-option>\n <ng-container\n *ngIf=\"formItem.selectOption.label && line.get(formItem.name) && line.get(formItem.selectOption.label)?.value && line.get(formItem.selectOption.value)?.value\">\n <nz-option *ngFor=\"let option of line.get(formItem.selectOption.value).value;index as i\"\n [nzLabel]=\"line.get(formItem.selectOption.label).value[i]\" [nzValue]=\"option\" nzHide>\n </nz-option>\n </ng-container>\n </nz-select>\n </ng-container>\n <ng-container *ngSwitchCase=\"7\">\n {{(formItem.preserveNumber && line.get(formItem.name).value) ?\n LodashRound(line.get(formItem.name).value,formItem.preserveNumber).toFixed(formItem.preserveNumber)\n : line.get(formItem.name).value}}\n </ng-container>\n <ng-container *ngSwitchCase=\"8\">\n <nz-switch [formControlName]=\"formItem.name\"></nz-switch>\n </ng-container>\n <ng-container *ngSwitchCase=\"9\">\n <nz-time-picker [formControlName]=\"formItem.name\"></nz-time-picker>\n </ng-container>\n </ng-container>\n </nz-form-control>\n </nz-form-item>\n <div *ngIf=\"formItem?.explainOption?.show\"\n [style.color]=\"formItem?.explainOption?.color ? formItem.explainOption.color : null\">\n {{line.get(formItem.explainOption.name).value}}</div>\n </td>\n </ng-container>\n <td style=\"width: 80px\" nzRight=\"0\">\n <span class=\"common-btn-group\">\n <a *ngIf=\"operateButtons.includes('add')\" (click)=\"addFormLine(line.get('lineIndex').value)\">\u6DFB\u52A0</a>\n <a class=\"common-danger-btn\" *ngIf=\"operateButtons.includes('delete') && !showDeleteConfirm\"\n (click)=\"deleteFormLine(line.get('lineIndex').value)\">\u5220\u9664</a>\n <a class=\"common-danger-btn\" *ngIf=\"operateButtons.includes('delete') && showDeleteConfirm\" nz-popconfirm\n nzPopconfirmTitle=\"\u786E\u8BA4\u8981\u5220\u9664\u8BE5\u884C\u5417?\" nzPopconfirmPlacement=\"bottom\"\n (nzOnConfirm)=\"deleteFormLine(line.get('lineIndex').value)\">\u5220\u9664</a>\n </span>\n </td>\n </tr>\n </ng-container>\n <!-- \u5408\u8BA1\u533A\u57DF -->\n <tr *ngIf=\"showTotal\" class=\"hd-table-total\">\n <td>\u5408\u8BA1</td>\n <ng-container *ngFor=\"let totalOption of totalOptionList\">\n <td [nzAlign]=\"totalOption.align ? totalOption.align : 'left'\">{{ (totalOption.value || totalOption.value ===\n 0) ? (((totalOption.value % 1 === 0) && !totalOption.showDecimal ) ? totalOption.value :\n LodashRound(totalOption.value,2).toFixed(2)) : '' }} </td>\n </ng-container>\n </tr>\n </tbody>\n </nz-table>\n <nz-list\n *ngIf=\"linesFormArray.controls.slice((paginationPageIndex - 1) * paginationPageSize, (paginationPageIndex - 1) * paginationPageSize + paginationPageSize).length === 0\"\n [nzDataSource]=\"[]\"></nz-list>\n <ng-container>\n <hd-space background=\"transparent\" type=\"row\" size=\"16\"></hd-space>\n <nz-pagination [nzSize]=\"'small'\" style=\"text-align: right;\" [nzPageIndex]=\"paginationPageIndex\"\n [nzPageSize]=\"paginationPageSize\" [nzPageSizeOptions]=\"[10, 20, 30, 40, 50]\"\n [nzTotal]=\"linesFormArray.controls.length\" nzShowSizeChanger (nzPageIndexChange)=\"pageIndexChange($event)\"\n (nzPageSizeChange)=\"pageSizeChange($event)\" [nzShowTotal]=\"totalTemplate\"></nz-pagination>\n <ng-template #totalTemplate let-total>\u5171 {{linesFormArray.controls.length}} \u6761\u6570\u636E</ng-template>\n </ng-container>\n</form>",
|
|
3129
|
+
template: "<hd-button-group *ngIf=\"showForm && showSearch\">\n <ng-template #buttonGroupLeft>\n <nz-input-group [nzSuffix]=\"suffixIconSearch\">\n <input type=\"text\" nz-input (keyup.enter)=\"searchLines()\" placeholder=\"\u8BF7\u8F93\u5165\u5185\u5BB9\u641C\u7D22\" style=\"width: 300px;\"\n [(ngModel)]=\"filterStr\" />\n </nz-input-group>\n <ng-template #suffixIconSearch>\n <i nz-icon nzType=\"search\" (click)=\"searchLines()\"></i>\n </ng-template>\n </ng-template>\n</hd-button-group>\n<!-- TODO: \u6D4B\u8BD5\u6309\u94AE\u7EC4 -->\n<hd-button-group>\n <ng-template #buttonGroupLeft>\n <hd-button type=\"primary\" (clickAction)=\"testPage()\">\u6D4B\u8BD5\u7FFB\u9875\u6309\u94AE</hd-button>\n <hd-button type=\"primary\" (clickAction)=\"focusDom(0, 0)\">\u6D4B\u8BD5\u805A\u7126\u9009\u62E9\u6846</hd-button>\n <hd-button type=\"primary\" (clickAction)=\"focusDom(0, 2)\">\u6D4B\u8BD5\u805A\u7126\u666E\u901A\u9009\u62E9\u6846</hd-button>\n <hd-button type=\"primary\" (clickAction)=\"focusDom(0, 3)\">\u6D4B\u8BD5\u805A\u7126\u591A\u9879\u9009\u62E9\u6846</hd-button>\n <hd-button type=\"primary\" (clickAction)=\"focusDom(0, 4)\">\u6D4B\u8BD5\u805A\u7126\u7981\u7528\u8F93\u5165\u6846</hd-button>\n <hd-button type=\"primary\" (clickAction)=\"focusDom(0, 7)\">\u6D4B\u8BD5\u805A\u7126\u6570\u5B57\u8F93\u5165\u6846</hd-button>\n <hd-button type=\"primary\" (clickAction)=\"jumpToNextInput(0, 1)\">\u6D4B\u8BD5\u805A\u7126\u4E0B\u4E00\u4E2A</hd-button>\n </ng-template>\n</hd-button-group>\n\n<hd-space background=\"transparent\" type=\"row\" size=\"16\"></hd-space>\n<form *ngIf=\"showForm\" nz-form [formGroup]=\"validateHdFormLines\" class=\"ant-advanced-search-form hd-formLines-container\"\n (keydown)=\"onKeyDown($event)\">\n <nz-table nzTemplateMode [nzFrontPagination]=\"false\" [nzLoading]=\"tableLoading\" [nzScroll]=\"scroll\">\n <thead>\n <tr>\n <th nzWidth=\"58px\" nzLeft=\"0px\">\u5E8F\u53F7</th>\n <ng-container *ngFor=\"let item of formLines\">\n <th *ngIf=\"!item.hide\" [nzAlign]=\"item.align ? item.align : 'left'\">\n <span *ngIf=\"item.require\" style=\"color: red;\">*</span>{{item.label}}\n </th>\n </ng-container>\n <th style=\"width: 80px\" nzRight=\"0\">\u64CD\u4F5C</th>\n </tr>\n </thead>\n <tbody>\n <ng-container\n *ngFor=\"let line of linesFormArray.controls.slice((paginationPageIndex - 1) * paginationPageSize, (paginationPageIndex - 1) * paginationPageSize + paginationPageSize);index as dataIndex\"\n formArrayName=\"lines\">\n <tr [formGroup]=\"line\">\n <td nzWidth=\"58px\" nzLeft=\"0px\">\n {{line.get('lineIndex').value}}\n </td>\n <ng-container *ngFor=\"let formItem of formLines; index as innerIndex\">\n <td *ngIf=\"!formItem.hide\" [nzAlign]=\"formItem.align ? formItem.align : 'left'\">\n <nz-form-item>\n <nz-form-control [nzErrorTip]=\"formItem.label + '\u4E0D\u80FD\u4E3A\u7A7A'\">\n <ng-container [ngSwitch]=\"formItem.type\">\n <ng-container *ngSwitchCase=\"'Input'\">\n <nz-input-group [nzSuffix]=\"inputCleanTemplate\">\n <input #formInputDom (click)=\"setActiveDomInFormLines(dataIndex , innerIndex)\"\n [ngStyle]=\"getStyle(line, formItem, '100px')\" nz-input\n [ngStyle]=\"{'color': formItem?.colorOption?.name ? line.get(formItem.colorOption.name ).value : null}\"\n [id]=\"'input-' + formItem.name + line.get('lineIndex').value\"\n (click)=\"formItem.isSelect ? selectValue('#input-' + formItem.name + line.get('lineIndex').value, dataIndex , innerIndex) : null\"\n [maxlength]=\"formItem.maxLength || null\"\n [placeholder]=\"formItem.placeholder ? formItem.placeholder : '\u8BF7\u8F93\u5165' + formItem.label\"\n [formControlName]=\"formItem.name\" />\n </nz-input-group>\n <ng-template #inputCleanTemplate>\n <i nz-icon nz-tooltip class=\"ant-input-clear-icon\" nzTheme=\"fill\" nzType=\"close-circle\"\n *ngIf=\"line.get(formItem.name).value && !line.get(formItem.name).disabled\"\n (click)=\"inputClean(formItem ,line)\"></i>\n </ng-template>\n </ng-container>\n <ng-container *ngSwitchCase=\"'Select'\">\n <nz-select #formInputDom (click)=\"setActiveDomInFormLines(dataIndex , innerIndex)\"\n nzDropdownClassName=\"hd-select-table\"\n *ngIf=\"formItem.selectOption.tableColumns;else nomarlSelectTemplate\"\n [nzShowSearch]=\"formItem.selectOption.hdShowSearch != null ? formItem.selectOption.hdShowSearch : true\"\n [nzAllowClear]=\"formItem.selectOption.hdAllowClear != null ? formItem.selectOption.hdAllowClear : true\"\n [nzServerSearch]=\"formItem.selectOption.hdServerSearch || false\"\n [nzDropdownMatchSelectWidth]=\"formItem.selectOption.hdDropdownMatchSelectWidth ? formItem.selectOption.hdDropdownMatchSelectWidth : false\"\n [nzPlaceHolder]=\"formItem.placeholder ? formItem.placeholder : '\u8BF7\u9009\u62E9' + formItem.label\"\n [formControlName]=\"formItem.name\"\n (nzOnSearch)=\"onSearchEvent(formItem.onSearchEvent || null, $event, line, formItem.onSearchEventEventDebounceTime)\"\n [ngStyle]=\"getStyle(line, formItem, '200px')\">\n <nz-option nzCustomContent nzDisabled>\n <div class=\"hd-option-header\"\n *ngIf=\"(formItem.selectOption?.selectList?.length > 0 || line.get(formItem.selectOption.selectListName)?.value?.length > 0);else emptyTemplate\">\n <div class=\"hd-option-header-column\"\n *ngFor=\"let selectOptionTableColumn of formItem.selectOption.tableColumns;index as index \"\n [ngStyle]=\"{'width': selectOptionTableColumn?.width ? (selectOptionTableColumn.width + ((index === 0 && !selectOptionTableColumn.label) ? 12 : 0) + 'px') : 'unset'}\">\n {{selectOptionTableColumn.label}}\n </div>\n </div>\n <ng-template #emptyTemplate>\n <div class=\"hd-select-empty\">\n <img\n src=\"data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNjRweCIgaGVpZ2h0PSI0MXB4IiB2aWV3Qm94PSIwIDAgNjQgNDEiIHZlcnNpb249IjEuMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayI+CiAgICA8IS0tIEdlbmVyYXRvcjogU2tldGNoIDUyLjUgKDY3NDY5KSAtIGh0dHA6Ly93d3cuYm9oZW1pYW5jb2RpbmcuY29tL3NrZXRjaCAtLT4KICAgIDxnIHN0cm9rZT0ibm9uZSIgc3Ryb2tlLXdpZHRoPSIxIiBmaWxsPSJub25lIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiPgogICAgICAgIDxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKC00NzIuMDAwMDAwLCAtMTMzNS4wMDAwMDApIj4KICAgICAgICAgICAgPGcgIHRyYW5zZm9ybT0idHJhbnNsYXRlKDY0LjAwMDAwMCwgMTExNC4wMDAwMDApIj4KICAgICAgICAgICAgICAgIDxnICB0cmFuc2Zvcm09InRyYW5zbGF0ZSg0MC4wMDAwMDAsIDc4LjAwMDAwMCkiPgogICAgICAgICAgICAgICAgICAgIDxnICB0cmFuc2Zvcm09InRyYW5zbGF0ZSgzNjguMDAwMDAwLCAxNDQuMDAwMDAwKSI+CiAgICAgICAgICAgICAgICAgICAgICAgIDxnID4KICAgICAgICAgICAgICAgICAgICAgICAgICAgIDxlbGxpcHNlICBmaWxsPSIjRjVGNUY1IiBjeD0iMzIiIGN5PSIzMyIgcng9IjMyIiByeT0iNyI+PC9lbGxpcHNlPgogICAgICAgICAgICAgICAgICAgICAgICAgICAgPGcgICB0cmFuc2Zvcm09InRyYW5zbGF0ZSg5LjAwMDAwMCwgMC4wMDAwMDApIiBmaWxsLXJ1bGU9Im5vbnplcm8iIHN0cm9rZT0iI0Q5RDlEOSI+CiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPHBhdGggZD0iTTQ2LDEyLjc2MDU2MDQgTDM1Ljg1NDMwNDcsMS4yNTczOTYzMyBDMzUuMzY3NDQxNCwwLjQ3MzgyNjYwNSAzNC42NTU4Nzg5LDAgMzMuOTA2NzYxNywwIEwxMi4wOTMyMzgzLDAgQzExLjM0NDEyMTEsMCAxMC42MzI1NTg2LDAuNDczOTUwMjU1IDEwLjE0NTY5NTMsMS4yNTczOTYzMyBMMi42MTQ3OTcyN2UtMTIsMTIuNzYwNTYwNCBMMCwyMiBMNDYsMjIgTDQ2LDEyLjc2MDU2MDQgWiIgID48L3BhdGg+CiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPHBhdGggZD0iTTMyLjYxMzI4MTMsMTUuOTMxNSBDMzIuNjEzMjgxMywxNC4zMjU4NTExIDMzLjYwNjk1MzEsMTMuMDAwMjM0IDM0LjgzOTY5OTIsMTMgTDQ2LDEzIEw0NiwzMS4xMzcxMjc3IEM0NiwzMy4yNTg5NTc0IDQ0LjY3OTM4NjcsMzUgNDMuMDUwNDI5NywzNSBMMi45NDk1NzAzMSwzNSBDMS4zMjA1MjM0NCwzNSAwLDMzLjI1ODg0MDQgMCwzMS4xMzcxMjc3IEwwLDEzIEwxMS4xNjAzMDA4LDEzIEMxMi4zOTMwNDY5LDEzIDEzLjM4NjcxODgsMTQuMzIyODA4NSAxMy4zODY3MTg4LDE1LjkyODQ1NzQgTDEzLjM4NjcxODgsMTUuOTQ5NjM4MyBDMTMuMzg2NzE4OCwxNy41NTUyODcyIDE0LjM5MTcxMDksMTguODUxMTgwOSAxNS42MjQ0NTcsMTguODUxMTgwOSBMMzAuMzc1NTQzLDE4Ljg1MTE4MDkgQzMxLjYwODI4OTEsMTguODUxMTgwOSAzMi42MTMyODEzLDE3LjU0MzM1MTEgMzIuNjEzMjgxMywxNS45Mzc3MDIxIEwzMi42MTMyODEzLDE1LjkzMTUgWiIgIGZpbGw9IiNGQUZBRkEiPjwvcGF0aD4KICAgICAgICAgICAgICAgICAgICAgICAgICAgIDwvZz4KICAgICAgICAgICAgICAgICAgICAgICAgPC9nPgogICAgICAgICAgICAgICAgICAgIDwvZz4KICAgICAgICAgICAgICAgIDwvZz4KICAgICAgICAgICAgPC9nPgogICAgICAgIDwvZz4KICAgIDwvZz4KPC9zdmc+\"\n alt=\"empty\">\n <p class=\"ant-empty-description\">\u6682\u65E0\u6570\u636E</p>\n </div>\n </ng-template>\n </nz-option>\n\n <nz-option nzCustomContent\n *ngFor=\"let selectItem of (formItem.selectOption.selectList || line.get(formItem.selectOption.selectListName).value)\"\n [nzValue]=\"selectItem[formItem.selectOption.value]\" [nzLabel]=\"formItem.selectOption.showLabelAndValue ? '['+ selectItem[formItem.selectOption.value] +']' +\n selectItem[formItem.selectOption.label] : selectItem[formItem.selectOption.label]\">\n <div class=\"hd-option-line\">\n <div *ngFor=\"let selectOptionTableColumn of formItem.selectOption.tableColumns\"\n [ngStyle]=\"{'width': selectOptionTableColumn?.width ? selectOptionTableColumn.width + 'px' : 'unset'}\">\n <ng-container *ngIf=\"selectOptionTableColumn.icons;else notPictureTemplate\">\n <ng-container *ngFor=\"let icon of selectOptionTableColumn.icons\">\n <img *ngIf=\"icon.iconName === 'hd-recommend-star' && selectItem[icon.fieldName]\"\n src=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAVpJREFUOE+l07FLQkEcB/Dv7713Zg1GQ0SgW9AmTYVp1BRUokZBEI1u/QVBUBD1D0Rt0dQaPYmotXza1tKQzQ1Fk0iDHr5vPEOTUpO88e77+9zvjjtBh8HTOb8e0hu0eN8Xzz22ikonoGzHdgXcAVB16S75U/mbn/m2AK+mglqbBUAGvCIRuVCJ7HLXQCUTPQOxXi8Q4FolnYWuAH0+HaEpjrdxAyC3VSq33xKgPTWiYYUai8IjUCabw4Zw1XWNF2+OZrXoi+cLImBth4odfQAw0elCW6zdKvU2/wVkYs8ggzBlRqrcI/DrrK1wQ7DWAIToV8lsqGxHDwTY6qYbA1jpCVAux3oBSirhDPYCOL6kE/s/QB77UrnNJoDDVkCN6pI+BJH+6xINQdpKOCf1d/AEYBxgUUQC5PcLbPMDXy1lhGXx7r0G6ExklpBwI0xh2w7ID+UzL71iL/MJdzuZdDL/kXcAAAAASUVORK5CYII=\"\n style=\"width: 16px;height: 16px;\">\n <img *ngIf=\"icon.iconName === 'hd-img-star' && selectItem[icon.fieldName]\"\n src=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAyhJREFUWEe1ll1o1XYYxp8nPUmUihdCV3bAirvYzUC80Xpy3KwTZNR2CdOhDkTBwe6G32XzwqpjE3Qt4pUKZQqDyQZNTp1uY8yCJG0F2d2+LlWOOkShovQkaV45lcJpTdOTHJubBPI+z/Pj//H+/0TGR66uf8sPoz8A/Kstkp38YORxFitmEVU1vm1cBPlp9ZuQXtX0jmfxygQgvxSWBRWlDECvhgrwQFuqLufG4TAtRCaAwCl+IcDXtWEi2KFb7pUFBxCBEpSMMsDWGWEiNzXLe2/BASp2cTuJH+KCRMJ3dGvsrzQQqafAtw0XpBEfIhc00/tswQD8QWM1FP45d4A8V9XJN9k5Nl4vRKoR8G3jMshdyebRPs0cOftaAaRUbAsRrRRRhuczFsF/lPATNQrL3Hr7/nz1lGvvtkwGUSEC8gLkWfMGkAfQMp9J0n8ByhS5J+QDVr+BshBlUu6q3d5v9G3jIcg3GgnJqp2C853iCIB1WU0a1F2iOO2tPnK3CLQ1aJZKLpCfddPrmtoF8uuqZn9iyfcEzVQumYtlQDO9vS8PsprHd4xvAR7I7FuHUIBvdNP9crr0lT7g24U+UNlfh1f6Esrn2ofeuVphbCPyneJuAN+lT0jokZCduum9cobM2Qn9krEGEa6+hi36jEC3aro34vASW3FoG9si8sdGRoKCY6rlnpjLIxGgYhunSPY0AiAiP+mW93EmAN8ujoJobwgAuKOb7orUAHKjY1EwHjwFkGsEoKpVJ6WVH3n/p1oDwVBhk0TK742GV/UKYOZMt5QKoGIbX5E8mgwg4wCbADQn1c1uPvP2gWqB7xjDADck7OwBVan0QFFyQaj2A9wxV60A13XT7Uw1Ar5TlDiBQP6hRHs0a3Ss9n8wuK4jYtN5Em/H6B5ppht7r4jvhEOFtYiUGQEAnhDoV033ZNJwB45xRAS9IBfX1qnhRD7uhhQLENiFQ0Ll9LSBCM7olnu43gUpTjEfiPSB3D6tUQRbcpZ7bbZHLEBYKnRFogxV505rmjzIrtG/6w2fMS0l430RHAVoULBZtdybdQFkCcuqSXUtzxqSpHsBfmUdgJhaiDQAAAAASUVORK5CYII=\"\n style=\"width: 16px;height: 16px;\">\n </ng-container>\n </ng-container>\n <ng-template #notPictureTemplate>\n <ng-container\n *ngIf=\"!isTextOverflow(selectOptionTableColumn.render ? selectOptionTableColumn.render(selectItem) : selectItem[selectOptionTableColumn.name], selectOptionTableColumn.width);else overflowTemplate\">\n <div>{{ judgeColEmpty(selectOptionTableColumn.render ?\n selectOptionTableColumn.render(selectItem) :\n selectItem[selectOptionTableColumn.name])}}</div>\n </ng-container>\n <ng-template #overflowTemplate>\n <div class=\"hd-option-overflow\" nz-tooltip\n [nzTooltipTitle]=\"selectOptionTableColumn.render ? selectOptionTableColumn.render(selectItem) : selectItem[selectOptionTableColumn.name]\">\n {{\n judgeColEmpty(selectOptionTableColumn.render ?\n selectOptionTableColumn.render(selectItem) :\n selectItem[selectOptionTableColumn.name])}}</div>\n </ng-template>\n </ng-template>\n </div>\n </div>\n </nz-option>\n <nz-option\n *ngIf=\"formItem.selectOption.label && line.get(formItem.name) && line.get(formItem.selectOption.label)?.value && line.get(formItem.selectOption.value)?.value\"\n [nzLabel]=\"(formItem.selectOption.value === 'code' || formItem.selectOption.value === 'productCode' || formItem.selectOption.hdShowItemCode) ? ('['+ line.get(formItem.selectOption.value).value + ']' + line.get(formItem.selectOption.label).value) : line.get(formItem.selectOption.label).value\"\n [nzValue]=\"line.get(formItem.selectOption.value).value\" nzHide></nz-option>\n </nz-select>\n <ng-template #nomarlSelectTemplate>\n <nz-select #formInputDom (click)=\"setActiveDomInFormLines(dataIndex , innerIndex)\"\n [nzShowSearch]=\"formItem.selectOption.hdShowSearch != null ? formItem.selectOption.hdShowSearch : true\"\n [nzAllowClear]=\"formItem.selectOption.hdAllowClear != null ? formItem.selectOption.hdAllowClear : true\"\n [nzServerSearch]=\"formItem.selectOption.hdServerSearch || false\"\n [nzDropdownMatchSelectWidth]=\"formItem.selectOption.hdDropdownMatchSelectWidth ? formItem.selectOption.hdDropdownMatchSelectWidth : false\"\n [nzPlaceHolder]=\"formItem.placeholder ? formItem.placeholder : '\u8BF7\u9009\u62E9' + formItem.label\"\n [formControlName]=\"formItem.name\"\n (nzOnSearch)=\"onSearchEvent(formItem.onSearchEvent || null, $event, line, formItem.onSearchEventEventDebounceTime)\"\n [ngStyle]=\"getStyle(line, formItem, '200px')\">\n <nz-option\n *ngFor=\"let selectItem of (formItem.selectOption.selectList || line.get(formItem.selectOption.selectListName).value)\"\n [nzValue]=\"selectItem[formItem.selectOption.value]\" [nzLabel]=\"formItem.selectOption.showLabelAndValue ? '['+ selectItem[formItem.selectOption.value] +']' +\n selectItem[formItem.selectOption.label] : selectItem[formItem.selectOption.label]\">\n </nz-option>\n <nz-option\n *ngIf=\"formItem.selectOption.label && line.get(formItem.name) && line.get(formItem.selectOption.label)?.value && line.get(formItem.selectOption.value)?.value\"\n [nzLabel]=\"(formItem.selectOption.value === 'code' || formItem.selectOption.value === 'productCode' || formItem.selectOption.hdShowItemCode) ? ('['+ line.get(formItem.selectOption.value).value + ']' + line.get(formItem.selectOption.label).value) : line.get(formItem.selectOption.label).value\"\n [nzValue]=\"line.get(formItem.selectOption.value).value\" nzHide></nz-option>\n </nz-select>\n </ng-template>\n\n </ng-container>\n <ng-container *ngSwitchCase=\"'Date'\">\n <nz-date-picker #formInputDom (click)=\"setActiveDomInFormLines(dataIndex , innerIndex)\"\n *ngIf=\"formItem.showTime\" [ngStyle]=\"getStyle(line, formItem, '150px')\"\n [nzPlaceHolder]=\"formItem.placeholder ? formItem.placeholder : '\u8BF7\u9009\u62E9' + formItem.label\"\n [formControlName]=\"formItem.name\" [nzDisabledDate]=\"formItem.hdDisabledDate\" nzShowTime\n nzFormat=\"yyyy-MM-dd HH:mm:ss\">\n </nz-date-picker>\n <nz-date-picker #formInputDom *ngIf=\"!formItem.showTime\"\n [ngStyle]=\"getStyle(line, formItem, '150px')\"\n (click)=\"setActiveDomInFormLines(dataIndex , innerIndex)\"\n [nzPlaceHolder]=\"formItem.placeholder ? formItem.placeholder : '\u8BF7\u9009\u62E9' + formItem.label\"\n [formControlName]=\"formItem.name\" [nzDisabledDate]=\"formItem.hdDisabledDate\">\n </nz-date-picker>\n </ng-container>\n <ng-container *ngSwitchCase=\"'DateRange'\">\n <nz-range-picker #formInputDom [ngStyle]=\"getStyle(line, formItem, '200px')\"\n (click)=\"setActiveDomInFormLines(dataIndex , innerIndex)\" [nzPlaceHolder]=\"['\u5F00\u59CB\u65E5\u671F','\u7ED3\u675F\u65E5\u671F']\"\n [formControlName]=\"formItem.name\">\n </nz-range-picker>\n </ng-container>\n <ng-container *ngSwitchCase=\"'TextArea'\">\n <textarea #formInputDom (click)=\"setActiveDomInFormLines(dataIndex , innerIndex)\"\n [ngStyle]=\"{'color': formItem?.colorOption?.name ? line.get(formItem.colorOption.name).value : null}\"\n [placeholder]=\"formItem.placeholder ? formItem.placeholder : '\u8BF7\u8F93\u5165' + formItem.label\"\n [maxlength]=\"formItem.maxLength || null\" rows=\"4\" nz-input\n [maxlength]=\"formItem.maxLength || null\" [formControlName]=\"formItem.name\"></textarea>\n </ng-container>\n <ng-container *ngSwitchCase=\"'InputNumber'\">\n <div style=\"display: flex;align-items: center;\">\n <nz-input-number #formInputDom [ngStyle]=\"getStyle(line, formItem, '100px')\"\n [maxlength]=\"formItem.maxLength || null\" [formControlName]=\"formItem.name\"\n [nzMin]=\"formItem?.inputNumber?.min || 0\" [nzMax]=\"formItem?.inputNumber?.max || 99999999\"\n [nzStep]=\"formItem?.inputNumber?.step || 1\"\n [nzPrecision]=\"formItem?.inputNumber?.precision || 2\"\n [nzPlaceHolder]=\"formItem.placeholder ? formItem.placeholder : '\u8BF7\u8F93\u5165' + formItem.label\"\n [nzId]=\"'inputNumber-' + formItem.name + line.get('lineIndex').value\"\n (click)=\"formItem.isSelect ? selectValue('#inputNumber-' + formItem.name + line.get('lineIndex').value, dataIndex , innerIndex) : setActiveDomInFormLines(dataIndex , innerIndex)\">\n </nz-input-number>\n <div *ngIf=\"formItem?.explainOptionRight?.show\"\n [style.color]=\"formItem?.explainOptionRight?.color ? formItem.explainOptionRight.color : null\">\n {{line.get(formItem.explainOptionRight.name).value}}</div>\n </div>\n </ng-container>\n <ng-container *ngSwitchCase=\"'MultipleSelect'\">\n <nz-select #formInputDom (click)=\"setActiveDomInFormLines(dataIndex , innerIndex)\"\n nzMode=\"multiple\" [nzServerSearch]=\"formItem.selectOption.hdServerSearch || false\"\n [nzDropdownMatchSelectWidth]=\"formItem.selectOption.hdDropdownMatchSelectWidth ? formItem.selectOption.hdDropdownMatchSelectWidth : false\"\n [nzShowSearch]=\"formItem.selectOption.hdShowSearch != null ? formItem.selectOption.hdShowSearch : true\"\n [nzAllowClear]=\"formItem.selectOption.hdAllowClear != null ? formItem.selectOption.hdAllowClear : true\"\n [nzPlaceHolder]=\"formItem.placeholder ? formItem.placeholder : '\u8BF7\u9009\u62E9' + formItem.label\"\n [formControlName]=\"formItem.name\" [ngStyle]=\"getStyle(line, formItem, '200px')\"\n (nzOnSearch)=\"onSearchEvent(formItem.onSearchEvent || null, $event, line, formItem.onSearchEventEventDebounceTime)\">\n <nz-option *ngFor=\"let selectItem of formItem.selectOption.selectList\"\n [nzValue]=\"selectItem[formItem.selectOption.value]\" [nzLabel]=\"formItem.selectOption.showLabelAndValue ? '['+ selectItem[formItem.selectOption.value] +']' +\n selectItem[formItem.selectOption.label] : selectItem[formItem.selectOption.label]\"></nz-option>\n <ng-container\n *ngIf=\"formItem.selectOption.label && line.get(formItem.name) && line.get(formItem.selectOption.label)?.value && line.get(formItem.selectOption.value)?.value\">\n <nz-option *ngFor=\"let option of line.get(formItem.selectOption.value).value;index as i\"\n [nzLabel]=\"line.get(formItem.selectOption.label).value[i]\" [nzValue]=\"option\" nzHide>\n </nz-option>\n </ng-container>\n </nz-select>\n </ng-container>\n <ng-container *ngSwitchCase=\"'ViewDom'\">\n {{(formItem.preserveNumber && line.get(formItem.name).value) ?\n LodashRound(line.get(formItem.name).value,formItem.preserveNumber).toFixed(formItem.preserveNumber)\n : line.get(formItem.name).value}}\n </ng-container>\n <ng-container *ngSwitchCase=\"'Switch'\">\n <nz-switch (click)=\"setActiveDomInFormLines(dataIndex , innerIndex)\"\n [formControlName]=\"formItem.name\"></nz-switch>\n </ng-container>\n <ng-container *ngSwitchCase=\"'Time' \">\n <nz-time-picker #formInputDom [ngStyle]=\"getStyle(line, formItem, '200px')\"\n (click)=\"setActiveDomInFormLines(dataIndex , innerIndex)\"\n [formControlName]=\"formItem.name\"></nz-time-picker>\n </ng-container>\n </ng-container>\n </nz-form-control>\n </nz-form-item>\n <div *ngIf=\"formItem?.explainOption?.show\"\n [style.color]=\"formItem?.explainOption?.color ? formItem.explainOption.color : null\">\n {{line.get(formItem.explainOption.name).value}}</div>\n </td>\n </ng-container>\n <td style=\"width: 80px\" nzRight=\"0\">\n <span class=\"common-btn-group\">\n <a *ngIf=\"operateButtons.includes('add')\" (click)=\"addFormLine(line.get('lineIndex').value)\">\u6DFB\u52A0</a>\n <a class=\"common-danger-btn\" *ngIf=\"operateButtons.includes('delete') && !showDeleteConfirm\"\n (click)=\"deleteFormLine(line.get('lineIndex').value)\">\u5220\u9664</a>\n <a class=\"common-danger-btn\" *ngIf=\"operateButtons.includes('delete') && showDeleteConfirm\" nz-popconfirm\n nzPopconfirmTitle=\"\u786E\u8BA4\u8981\u5220\u9664\u8BE5\u884C\u5417?\" nzPopconfirmPlacement=\"bottom\"\n (nzOnConfirm)=\"deleteFormLine(line.get('lineIndex').value)\">\u5220\u9664</a>\n </span>\n </td>\n </tr>\n </ng-container>\n <!-- \u5408\u8BA1\u533A\u57DF -->\n <tr *ngIf=\"showTotal\" class=\"hd-table-total\">\n <td>\u5408\u8BA1</td>\n <ng-container *ngFor=\"let totalOption of totalOptionList\">\n <td [nzAlign]=\"totalOption.align ? totalOption.align : 'left'\">{{ (totalOption.value || totalOption.value ===\n 0) ? (((totalOption.value % 1 === 0) && !totalOption.showDecimal ) ? totalOption.value :\n LodashRound(totalOption.value,2).toFixed(2)) : '' }} </td>\n </ng-container>\n </tr>\n </tbody>\n </nz-table>\n <nz-list\n *ngIf=\"linesFormArray.controls.slice((paginationPageIndex - 1) * paginationPageSize, (paginationPageIndex - 1) * paginationPageSize + paginationPageSize).length === 0\"\n [nzDataSource]=\"[]\"></nz-list>\n <ng-container>\n <hd-space background=\"transparent\" type=\"row\" size=\"16\"></hd-space>\n <nz-pagination [nzSize]=\"'small'\" style=\"text-align: right;\" [nzPageIndex]=\"paginationPageIndex\"\n [nzPageSize]=\"paginationPageSize\" [nzPageSizeOptions]=\"[2, 10, 20, 30, 40, 50]\"\n [nzTotal]=\"linesFormArray.controls.length\" nzShowSizeChanger (nzPageIndexChange)=\"pageIndexChange($event)\"\n (nzPageSizeChange)=\"pageSizeChange($event)\" [nzShowTotal]=\"totalTemplate\"></nz-pagination>\n <ng-template #totalTemplate let-total>\u5171 {{linesFormArray.controls.length}} \u6761\u6570\u636E</ng-template>\n </ng-container>\n</form>",
|
|
2408
3130
|
styles: ["::ng-deep .common-btn-group>a{font-size:12px;font-weight:400;color:#12a34f!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}::ng-deep .ant-form-item-label>label{color:#4b504e}::ng-deep .ant-input-number-input{height:28px}::ng-deep .ant-input-number{height:28px}textarea.ant-input{height:auto;min-height:28px}::ng-deep .ant-select-selection--multiple{min-height:28px}::ng-deep .ant-select-selection__rendered>ul>li{height:22px!important;margin-top:3px!important;line-height:22px!important}::ng-deep .ant-advanced-search-form .ant-form-item{margin-bottom:0!important}::ng-deep .ant-select-selection--single{height:28px!important}::ng-deep .ant-input{height:28px}::ng-deep .ant-input[disabled]:hover{border-color:#d9d9d9!important}::ng-deep .ant-select-selection__rendered{line-height:28px!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}:host ::ng-deep th{background:#f5f8f6!important;font-weight:700!important;white-space:nowrap;font-size:12px;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:12px;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-time-picker{width:100%}.hd-formLines-container ::ng-deep td{padding:1.5px 8px!important}.hd-formLines-container .ant-table-tbody>tr>td,.hd-formLines-container ::ng-deep .ant-table-thead>tr>th{padding:16px 8px}.hd-formLines-container ::ng-deep .hd-table-total>td{border:0!important}.hd-formLines-container .ant-input-number{width:100%}::ng-deep .hd-select-table .ant-select-dropdown-menu-item-disabled{background:#f5f8f6!important;border-bottom:1px solid #e8e8e8;position:-webkit-sticky;position:sticky;top:0;z-index:10;padding:0}::ng-deep .hd-select-table .ant-select-dropdown-menu-item-disabled:hover{background:#f5f8f6!important}.hd-option-header{display:flex;align-items:center;color:rgba(0,0,0,.85);background:#f5f8f6}.hd-option-header-column{padding:5px 0}.hd-option-line{display:flex;align-items:center}.hd-option-overflow{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.hd-select-empty{display:flex;align-items:center;flex-direction:column;padding:20px 0;background:#fff}::ng-deep .ant-empty-small{background:#fff!important;padding:8px 0;margin:0}"]
|
|
2409
3131
|
}] }
|
|
2410
3132
|
];
|
|
2411
3133
|
/** @nocollapse */
|
|
2412
3134
|
HdFormLinesComponent.ctorParameters = function () { return [
|
|
2413
|
-
{ type: forms.FormBuilder }
|
|
3135
|
+
{ type: forms.FormBuilder },
|
|
3136
|
+
{ type: core.ChangeDetectorRef }
|
|
2414
3137
|
]; };
|
|
2415
3138
|
HdFormLinesComponent.propDecorators = {
|
|
3139
|
+
formInputDomList: [{ type: core.ViewChildren, args: ['formInputDom',] }],
|
|
2416
3140
|
tableLoading: [{ type: core.Input }],
|
|
2417
3141
|
showSearch: [{ type: core.Input }],
|
|
2418
3142
|
formLines: [{ type: core.Input }],
|
|
@@ -2444,6 +3168,8 @@
|
|
|
2444
3168
|
return HdFormLinesComponent;
|
|
2445
3169
|
}());
|
|
2446
3170
|
if (false) {
|
|
3171
|
+
/** @type {?} */
|
|
3172
|
+
HdFormLinesComponent.prototype.formInputDomList;
|
|
2447
3173
|
/** @type {?} */
|
|
2448
3174
|
HdFormLinesComponent.prototype.tableLoading;
|
|
2449
3175
|
/** @type {?} */
|
|
@@ -2507,6 +3233,16 @@
|
|
|
2507
3233
|
* @private
|
|
2508
3234
|
*/
|
|
2509
3235
|
HdFormLinesComponent.prototype.searchSubscription;
|
|
3236
|
+
/** @type {?} */
|
|
3237
|
+
HdFormLinesComponent.prototype.collectDomList;
|
|
3238
|
+
/** @type {?} */
|
|
3239
|
+
HdFormLinesComponent.prototype.activeDomX;
|
|
3240
|
+
/** @type {?} */
|
|
3241
|
+
HdFormLinesComponent.prototype.activeDomY;
|
|
3242
|
+
/** @type {?} */
|
|
3243
|
+
HdFormLinesComponent.prototype.activeDom;
|
|
3244
|
+
/** @type {?} */
|
|
3245
|
+
HdFormLinesComponent.prototype.activeSelectedComponentOpen;
|
|
2510
3246
|
/**
|
|
2511
3247
|
* @type {?}
|
|
2512
3248
|
* @private
|
|
@@ -2517,6 +3253,11 @@
|
|
|
2517
3253
|
* @private
|
|
2518
3254
|
*/
|
|
2519
3255
|
HdFormLinesComponent.prototype.fb;
|
|
3256
|
+
/**
|
|
3257
|
+
* @type {?}
|
|
3258
|
+
* @private
|
|
3259
|
+
*/
|
|
3260
|
+
HdFormLinesComponent.prototype.cdr;
|
|
2520
3261
|
}
|
|
2521
3262
|
|
|
2522
3263
|
/**
|
|
@@ -3867,8 +4608,6 @@
|
|
|
3867
4608
|
*/
|
|
3868
4609
|
function () {
|
|
3869
4610
|
var _this = this;
|
|
3870
|
-
console.log('local', location);
|
|
3871
|
-
console.log('window', window);
|
|
3872
4611
|
this.localtionTmp = location.pathname;
|
|
3873
4612
|
if (this.localtionTmp) {
|
|
3874
4613
|
this.localtionTmp = this.localtionTmp.replace(/\//g, "_");
|
|
@@ -5149,145 +5888,6 @@
|
|
|
5149
5888
|
return HdFilterService;
|
|
5150
5889
|
}());
|
|
5151
5890
|
|
|
5152
|
-
/**
|
|
5153
|
-
* @fileoverview added by tsickle
|
|
5154
|
-
* @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
5155
|
-
*/
|
|
5156
|
-
// 控件列表
|
|
5157
|
-
var
|
|
5158
|
-
// 控件列表
|
|
5159
|
-
FormLine = /** @class */ (function () {
|
|
5160
|
-
function FormLine() {
|
|
5161
|
-
// 输入框的提示文件
|
|
5162
|
-
this.require = false; // 是否必填
|
|
5163
|
-
// 是否必填
|
|
5164
|
-
this.hide = false; // 是否为隐藏字段,仅用于填充表单的字段,不显示在页面上
|
|
5165
|
-
// 列对齐方式
|
|
5166
|
-
this.value = null; // 值 不传默认为null
|
|
5167
|
-
// 需要保留小数的列的位数
|
|
5168
|
-
this.inputNumber = new InputNumber(); // number组件的min、max、step
|
|
5169
|
-
// 不可输入状态
|
|
5170
|
-
this.showTime = false; // 日期选择器是否包含时间
|
|
5171
|
-
this.canSearch = false; // 指明hide 情况下的控件是否可以被搜索,默认false
|
|
5172
|
-
}
|
|
5173
|
-
return FormLine;
|
|
5174
|
-
}());
|
|
5175
|
-
if (false) {
|
|
5176
|
-
/** @type {?} */
|
|
5177
|
-
FormLine.prototype.type;
|
|
5178
|
-
/** @type {?} */
|
|
5179
|
-
FormLine.prototype.label;
|
|
5180
|
-
/** @type {?} */
|
|
5181
|
-
FormLine.prototype.name;
|
|
5182
|
-
/** @type {?} */
|
|
5183
|
-
FormLine.prototype.placeholder;
|
|
5184
|
-
/** @type {?} */
|
|
5185
|
-
FormLine.prototype.require;
|
|
5186
|
-
/** @type {?} */
|
|
5187
|
-
FormLine.prototype.hide;
|
|
5188
|
-
/** @type {?} */
|
|
5189
|
-
FormLine.prototype.align;
|
|
5190
|
-
/** @type {?} */
|
|
5191
|
-
FormLine.prototype.value;
|
|
5192
|
-
/** @type {?} */
|
|
5193
|
-
FormLine.prototype.isSelect;
|
|
5194
|
-
/** @type {?} */
|
|
5195
|
-
FormLine.prototype.selectOption;
|
|
5196
|
-
/** @type {?} */
|
|
5197
|
-
FormLine.prototype.explainOptionRight;
|
|
5198
|
-
/** @type {?} */
|
|
5199
|
-
FormLine.prototype.explainOption;
|
|
5200
|
-
/** @type {?} */
|
|
5201
|
-
FormLine.prototype.colorOption;
|
|
5202
|
-
/** @type {?} */
|
|
5203
|
-
FormLine.prototype.maxLength;
|
|
5204
|
-
/** @type {?} */
|
|
5205
|
-
FormLine.prototype.preserveNumber;
|
|
5206
|
-
/** @type {?} */
|
|
5207
|
-
FormLine.prototype.inputNumber;
|
|
5208
|
-
/** @type {?} */
|
|
5209
|
-
FormLine.prototype.onChangeEvent;
|
|
5210
|
-
/** @type {?} */
|
|
5211
|
-
FormLine.prototype.onSearchEvent;
|
|
5212
|
-
/** @type {?} */
|
|
5213
|
-
FormLine.prototype.defaultLabel;
|
|
5214
|
-
/** @type {?} */
|
|
5215
|
-
FormLine.prototype.hdDisabledDate;
|
|
5216
|
-
/** @type {?} */
|
|
5217
|
-
FormLine.prototype.disabled;
|
|
5218
|
-
/** @type {?} */
|
|
5219
|
-
FormLine.prototype.showTime;
|
|
5220
|
-
/** @type {?} */
|
|
5221
|
-
FormLine.prototype.style;
|
|
5222
|
-
/** @type {?} */
|
|
5223
|
-
FormLine.prototype.canSearch;
|
|
5224
|
-
/** @type {?} */
|
|
5225
|
-
FormLine.prototype.onChangeEventDebounceTime;
|
|
5226
|
-
/** @type {?} */
|
|
5227
|
-
FormLine.prototype.onSearchEventEventDebounceTime;
|
|
5228
|
-
}
|
|
5229
|
-
var ColorOption = /** @class */ (function () {
|
|
5230
|
-
function ColorOption() {
|
|
5231
|
-
}
|
|
5232
|
-
return ColorOption;
|
|
5233
|
-
}());
|
|
5234
|
-
if (false) {
|
|
5235
|
-
/** @type {?} */
|
|
5236
|
-
ColorOption.prototype.name;
|
|
5237
|
-
/** @type {?} */
|
|
5238
|
-
ColorOption.prototype.color;
|
|
5239
|
-
}
|
|
5240
|
-
var ExplainOption = /** @class */ (function () {
|
|
5241
|
-
function ExplainOption() {
|
|
5242
|
-
}
|
|
5243
|
-
return ExplainOption;
|
|
5244
|
-
}());
|
|
5245
|
-
if (false) {
|
|
5246
|
-
/** @type {?} */
|
|
5247
|
-
ExplainOption.prototype.show;
|
|
5248
|
-
/** @type {?} */
|
|
5249
|
-
ExplainOption.prototype.name;
|
|
5250
|
-
/** @type {?} */
|
|
5251
|
-
ExplainOption.prototype.color;
|
|
5252
|
-
}
|
|
5253
|
-
/** @enum {number} */
|
|
5254
|
-
var FormLineType = {
|
|
5255
|
-
Input: 0,
|
|
5256
|
-
Select: 1,
|
|
5257
|
-
Date: 2,
|
|
5258
|
-
DateRange: 3,
|
|
5259
|
-
TextArea: 4,
|
|
5260
|
-
InputNumber: 5,
|
|
5261
|
-
MultipleSelect: 6,
|
|
5262
|
-
ViewDom: 7,
|
|
5263
|
-
Switch: 8,
|
|
5264
|
-
Time: 9 // 时间选择器
|
|
5265
|
-
,
|
|
5266
|
-
};
|
|
5267
|
-
FormLineType[FormLineType.Input] = 'Input';
|
|
5268
|
-
FormLineType[FormLineType.Select] = 'Select';
|
|
5269
|
-
FormLineType[FormLineType.Date] = 'Date';
|
|
5270
|
-
FormLineType[FormLineType.DateRange] = 'DateRange';
|
|
5271
|
-
FormLineType[FormLineType.TextArea] = 'TextArea';
|
|
5272
|
-
FormLineType[FormLineType.InputNumber] = 'InputNumber';
|
|
5273
|
-
FormLineType[FormLineType.MultipleSelect] = 'MultipleSelect';
|
|
5274
|
-
FormLineType[FormLineType.ViewDom] = 'ViewDom';
|
|
5275
|
-
FormLineType[FormLineType.Switch] = 'Switch';
|
|
5276
|
-
FormLineType[FormLineType.Time] = 'Time';
|
|
5277
|
-
var HdFormLinesService = /** @class */ (function () {
|
|
5278
|
-
function HdFormLinesService() {
|
|
5279
|
-
}
|
|
5280
|
-
HdFormLinesService.decorators = [
|
|
5281
|
-
{ type: core.Injectable, args: [{
|
|
5282
|
-
providedIn: 'root'
|
|
5283
|
-
},] }
|
|
5284
|
-
];
|
|
5285
|
-
/** @nocollapse */
|
|
5286
|
-
HdFormLinesService.ctorParameters = function () { return []; };
|
|
5287
|
-
/** @nocollapse */ HdFormLinesService.ngInjectableDef = core.ɵɵdefineInjectable({ factory: function HdFormLinesService_Factory() { return new HdFormLinesService(); }, token: HdFormLinesService, providedIn: "root" });
|
|
5288
|
-
return HdFormLinesService;
|
|
5289
|
-
}());
|
|
5290
|
-
|
|
5291
5891
|
/**
|
|
5292
5892
|
* @fileoverview added by tsickle
|
|
5293
5893
|
* @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|