vxe-table 4.7.3 → 4.7.5
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/es/colgroup/index.js +1 -1
- package/es/column/index.js +1 -1
- package/es/grid/index.js +1 -1
- package/es/grid/src/grid.js +1 -1
- package/es/style.css +1 -1
- package/es/style.min.css +1 -1
- package/es/table/index.js +1 -1
- package/es/table/module/custom/hook.js +19 -3
- package/es/table/module/custom/panel.js +264 -160
- package/es/table/module/edit/hook.js +1 -1
- package/es/table/module/export/export-panel.js +1 -1
- package/es/table/module/export/hook.js +1 -1
- package/es/table/module/export/import-panel.js +1 -1
- package/es/table/module/filter/hook.js +1 -1
- package/es/table/module/filter/panel.js +1 -1
- package/es/table/module/menu/hook.js +1 -1
- package/es/table/module/validator/hook.js +1 -1
- package/es/table/render/index.js +1 -1
- package/es/table/src/body.js +1 -1
- package/es/table/src/cell.js +1 -1
- package/es/table/src/columnInfo.js +3 -1
- package/es/table/src/props.js +1 -1
- package/es/table/src/table.js +9 -3
- package/es/table/style.css +69 -9
- package/es/table/style.min.css +1 -1
- package/es/toolbar/index.js +1 -1
- package/es/toolbar/src/toolbar.js +2 -2
- package/es/ui/index.js +4 -2
- package/es/vxe-table/style.css +69 -9
- package/es/vxe-table/style.min.css +1 -1
- package/lib/colgroup/index.js +4 -4
- package/lib/colgroup/index.min.js +1 -1
- package/lib/column/index.js +4 -4
- package/lib/column/index.min.js +1 -1
- package/lib/grid/index.js +3 -3
- package/lib/grid/index.min.js +1 -1
- package/lib/grid/src/grid.js +20 -20
- package/lib/grid/src/grid.min.js +1 -1
- package/lib/index.umd.js +864 -737
- package/lib/index.umd.min.js +1 -1
- package/lib/style.css +1 -1
- package/lib/style.min.css +1 -1
- package/lib/table/index.js +3 -3
- package/lib/table/index.min.js +1 -1
- package/lib/table/module/custom/hook.js +25 -4
- package/lib/table/module/custom/hook.min.js +1 -1
- package/lib/table/module/custom/panel.js +178 -84
- package/lib/table/module/custom/panel.min.js +1 -1
- package/lib/table/module/edit/hook.js +2 -2
- package/lib/table/module/edit/hook.min.js +1 -1
- package/lib/table/module/export/export-panel.js +2 -2
- package/lib/table/module/export/export-panel.min.js +1 -1
- package/lib/table/module/export/hook.js +20 -20
- package/lib/table/module/export/hook.min.js +1 -1
- package/lib/table/module/export/import-panel.js +2 -2
- package/lib/table/module/export/import-panel.min.js +1 -1
- package/lib/table/module/filter/hook.js +2 -2
- package/lib/table/module/filter/hook.min.js +1 -1
- package/lib/table/module/filter/panel.js +2 -2
- package/lib/table/module/filter/panel.min.js +1 -1
- package/lib/table/module/menu/hook.js +2 -2
- package/lib/table/module/menu/hook.min.js +1 -1
- package/lib/table/module/validator/hook.js +2 -2
- package/lib/table/module/validator/hook.min.js +1 -1
- package/lib/table/render/index.js +2 -2
- package/lib/table/render/index.min.js +1 -1
- package/lib/table/src/body.js +2 -2
- package/lib/table/src/body.min.js +1 -1
- package/lib/table/src/cell.js +2 -2
- package/lib/table/src/cell.min.js +1 -1
- package/lib/table/src/columnInfo.js +4 -2
- package/lib/table/src/columnInfo.min.js +1 -1
- package/lib/table/src/props.js +2 -2
- package/lib/table/src/props.min.js +1 -1
- package/lib/table/src/table.js +15 -6
- package/lib/table/src/table.min.js +1 -1
- package/lib/table/style/style.css +69 -9
- package/lib/table/style/style.min.css +1 -1
- package/lib/toolbar/index.js +3 -3
- package/lib/toolbar/index.min.js +1 -1
- package/lib/toolbar/src/toolbar.js +3 -3
- package/lib/toolbar/src/toolbar.min.js +1 -1
- package/lib/ui/index.js +4 -2
- package/lib/ui/index.min.js +1 -1
- package/lib/vxe-table/style/style.css +69 -9
- package/lib/vxe-table/style/style.min.css +1 -1
- package/package.json +2 -2
- package/packages/colgroup/index.ts +1 -1
- package/packages/column/index.ts +1 -1
- package/packages/grid/index.ts +1 -1
- package/packages/grid/src/grid.ts +1 -1
- package/packages/table/index.ts +1 -1
- package/packages/table/module/custom/hook.ts +20 -4
- package/packages/table/module/custom/panel.ts +273 -166
- package/packages/table/module/edit/hook.ts +1 -1
- package/packages/table/module/export/export-panel.ts +1 -1
- package/packages/table/module/export/hook.ts +1 -1
- package/packages/table/module/export/import-panel.ts +1 -1
- package/packages/table/module/filter/hook.ts +1 -1
- package/packages/table/module/filter/panel.ts +1 -1
- package/packages/table/module/menu/hook.ts +1 -1
- package/packages/table/module/validator/hook.ts +1 -1
- package/packages/table/render/index.ts +1 -1
- package/packages/table/src/body.ts +1 -1
- package/packages/table/src/cell.ts +1 -1
- package/packages/table/src/columnInfo.ts +5 -1
- package/packages/table/src/props.ts +1 -1
- package/packages/table/src/table.ts +9 -3
- package/packages/toolbar/index.ts +1 -1
- package/packages/toolbar/src/toolbar.ts +2 -2
- package/packages/ui/index.ts +2 -0
- package/styles/components/table-module/custom.scss +78 -4
package/lib/index.umd.js
CHANGED
|
@@ -1690,25 +1690,25 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
1690
1690
|
VxeUI: function() { return /* reexport */ external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI; },
|
|
1691
1691
|
_t: function() { return /* reexport */ _t; },
|
|
1692
1692
|
clipboard: function() { return /* reexport */ clipboard; },
|
|
1693
|
-
commands: function() { return /* reexport */
|
|
1693
|
+
commands: function() { return /* reexport */ commands; },
|
|
1694
1694
|
config: function() { return /* reexport */ config; },
|
|
1695
1695
|
"default": function() { return /* binding */ entry_lib; },
|
|
1696
1696
|
drawer: function() { return /* reexport */ drawer; },
|
|
1697
|
-
formats: function() { return /* reexport */
|
|
1698
|
-
getConfig: function() { return /* reexport */
|
|
1699
|
-
getI18n: function() { return /* reexport */
|
|
1700
|
-
getIcon: function() { return /* reexport */
|
|
1697
|
+
formats: function() { return /* reexport */ formats; },
|
|
1698
|
+
getConfig: function() { return /* reexport */ getConfig; },
|
|
1699
|
+
getI18n: function() { return /* reexport */ getI18n; },
|
|
1700
|
+
getIcon: function() { return /* reexport */ getIcon; },
|
|
1701
1701
|
getTheme: function() { return /* reexport */ getTheme; },
|
|
1702
|
-
globalEvents: function() { return /* reexport */
|
|
1703
|
-
globalResize: function() { return /* reexport */
|
|
1704
|
-
hooks: function() { return /* reexport */
|
|
1702
|
+
globalEvents: function() { return /* reexport */ globalEvents; },
|
|
1703
|
+
globalResize: function() { return /* reexport */ globalResize; },
|
|
1704
|
+
hooks: function() { return /* reexport */ hooks; },
|
|
1705
1705
|
install: function() { return /* reexport */ install; },
|
|
1706
|
-
interceptor: function() { return /* reexport */
|
|
1707
|
-
log: function() { return /* reexport */
|
|
1708
|
-
menus: function() { return /* reexport */
|
|
1706
|
+
interceptor: function() { return /* reexport */ interceptor; },
|
|
1707
|
+
log: function() { return /* reexport */ log; },
|
|
1708
|
+
menus: function() { return /* reexport */ menus; },
|
|
1709
1709
|
modal: function() { return /* reexport */ modal; },
|
|
1710
1710
|
readFile: function() { return /* reexport */ readFile; },
|
|
1711
|
-
renderer: function() { return /* reexport */
|
|
1711
|
+
renderer: function() { return /* reexport */ renderer; },
|
|
1712
1712
|
saveFile: function() { return /* reexport */ saveFile; },
|
|
1713
1713
|
setConfig: function() { return /* reexport */ setConfig; },
|
|
1714
1714
|
setI18n: function() { return /* reexport */ setI18n; },
|
|
@@ -1718,7 +1718,7 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
1718
1718
|
setup: function() { return /* reexport */ setup; },
|
|
1719
1719
|
t: function() { return /* reexport */ t; },
|
|
1720
1720
|
use: function() { return /* reexport */ use; },
|
|
1721
|
-
validators: function() { return /* reexport */
|
|
1721
|
+
validators: function() { return /* reexport */ validators; }
|
|
1722
1722
|
});
|
|
1723
1723
|
|
|
1724
1724
|
// NAMESPACE OBJECT: ./packages/components.ts
|
|
@@ -1739,24 +1739,24 @@ __webpack_require__.d(components_namespaceObject, {
|
|
|
1739
1739
|
VxeUI: function() { return external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI; },
|
|
1740
1740
|
_t: function() { return _t; },
|
|
1741
1741
|
clipboard: function() { return clipboard; },
|
|
1742
|
-
commands: function() { return
|
|
1742
|
+
commands: function() { return commands; },
|
|
1743
1743
|
config: function() { return config; },
|
|
1744
1744
|
drawer: function() { return drawer; },
|
|
1745
|
-
formats: function() { return
|
|
1746
|
-
getConfig: function() { return
|
|
1747
|
-
getI18n: function() { return
|
|
1748
|
-
getIcon: function() { return
|
|
1745
|
+
formats: function() { return formats; },
|
|
1746
|
+
getConfig: function() { return getConfig; },
|
|
1747
|
+
getI18n: function() { return getI18n; },
|
|
1748
|
+
getIcon: function() { return getIcon; },
|
|
1749
1749
|
getTheme: function() { return getTheme; },
|
|
1750
|
-
globalEvents: function() { return
|
|
1751
|
-
globalResize: function() { return
|
|
1752
|
-
hooks: function() { return
|
|
1750
|
+
globalEvents: function() { return globalEvents; },
|
|
1751
|
+
globalResize: function() { return globalResize; },
|
|
1752
|
+
hooks: function() { return hooks; },
|
|
1753
1753
|
install: function() { return install; },
|
|
1754
|
-
interceptor: function() { return
|
|
1755
|
-
log: function() { return
|
|
1756
|
-
menus: function() { return
|
|
1754
|
+
interceptor: function() { return interceptor; },
|
|
1755
|
+
log: function() { return log; },
|
|
1756
|
+
menus: function() { return menus; },
|
|
1757
1757
|
modal: function() { return modal; },
|
|
1758
1758
|
readFile: function() { return readFile; },
|
|
1759
|
-
renderer: function() { return
|
|
1759
|
+
renderer: function() { return renderer; },
|
|
1760
1760
|
saveFile: function() { return saveFile; },
|
|
1761
1761
|
setConfig: function() { return setConfig; },
|
|
1762
1762
|
setI18n: function() { return setI18n; },
|
|
@@ -1766,7 +1766,7 @@ __webpack_require__.d(components_namespaceObject, {
|
|
|
1766
1766
|
setup: function() { return setup; },
|
|
1767
1767
|
t: function() { return t; },
|
|
1768
1768
|
use: function() { return use; },
|
|
1769
|
-
validators: function() { return
|
|
1769
|
+
validators: function() { return validators; }
|
|
1770
1770
|
});
|
|
1771
1771
|
|
|
1772
1772
|
;// CONCATENATED MODULE: ./node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js
|
|
@@ -1789,78 +1789,360 @@ if (typeof window !== 'undefined') {
|
|
|
1789
1789
|
// EXTERNAL MODULE: external {"root":"VxeUI","commonjs":"vxe-pc-ui","commonjs2":"vxe-pc-ui","amd":"vxe-pc-ui"}
|
|
1790
1790
|
var external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_ = __webpack_require__(2847);
|
|
1791
1791
|
var external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_default = /*#__PURE__*/__webpack_require__.n(external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_);
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
|
|
1808
|
-
|
|
1809
|
-
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
|
|
1813
|
-
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
|
|
1819
|
-
|
|
1820
|
-
|
|
1821
|
-
|
|
1822
|
-
|
|
1792
|
+
;// CONCATENATED MODULE: ./packages/ui/index.ts
|
|
1793
|
+
|
|
1794
|
+
external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.version = "4.7.5";
|
|
1795
|
+
external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.tableVersion = "4.7.5";
|
|
1796
|
+
external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.setConfig({
|
|
1797
|
+
emptyCell: ' ',
|
|
1798
|
+
table: {
|
|
1799
|
+
fit: true,
|
|
1800
|
+
showHeader: true,
|
|
1801
|
+
animat: true,
|
|
1802
|
+
delayHover: 250,
|
|
1803
|
+
autoResize: true,
|
|
1804
|
+
minHeight: 144,
|
|
1805
|
+
// keepSource: false,
|
|
1806
|
+
// showOverflow: null,
|
|
1807
|
+
// showHeaderOverflow: null,
|
|
1808
|
+
// showFooterOverflow: null,
|
|
1809
|
+
// resizeInterval: 500,
|
|
1810
|
+
// size: null,
|
|
1811
|
+
// zIndex: null,
|
|
1812
|
+
// stripe: false,
|
|
1813
|
+
// border: false,
|
|
1814
|
+
// round: false,
|
|
1815
|
+
// emptyText: '暂无数据',
|
|
1816
|
+
// emptyRender: {
|
|
1817
|
+
// name: ''
|
|
1818
|
+
// },
|
|
1819
|
+
// rowConfig: {
|
|
1820
|
+
// keyField: '_X_ROW_KEY' // 行数据的唯一主键字段名
|
|
1821
|
+
// },
|
|
1822
|
+
resizeConfig: {
|
|
1823
|
+
refreshDelay: 250
|
|
1824
|
+
},
|
|
1825
|
+
radioConfig: {
|
|
1826
|
+
// trigger: 'default'
|
|
1827
|
+
strict: true
|
|
1828
|
+
},
|
|
1829
|
+
checkboxConfig: {
|
|
1830
|
+
// trigger: 'default',
|
|
1831
|
+
strict: true
|
|
1832
|
+
},
|
|
1833
|
+
tooltipConfig: {
|
|
1834
|
+
enterable: true
|
|
1835
|
+
},
|
|
1836
|
+
validConfig: {
|
|
1837
|
+
showMessage: true,
|
|
1838
|
+
autoClear: true,
|
|
1839
|
+
autoPos: true,
|
|
1840
|
+
message: 'inline',
|
|
1841
|
+
msgMode: 'single'
|
|
1842
|
+
},
|
|
1843
|
+
columnConfig: {
|
|
1844
|
+
maxFixedSize: 4
|
|
1845
|
+
},
|
|
1846
|
+
// menuConfig: {
|
|
1847
|
+
// visibleMethod () {}
|
|
1848
|
+
// },
|
|
1849
|
+
customConfig: {
|
|
1850
|
+
allowFixed: true,
|
|
1851
|
+
allowSort: true,
|
|
1852
|
+
showFooter: true
|
|
1853
|
+
// storage: false,
|
|
1854
|
+
// checkMethod () {}
|
|
1855
|
+
},
|
|
1856
|
+
sortConfig: {
|
|
1857
|
+
// remote: false,
|
|
1858
|
+
// trigger: 'default',
|
|
1859
|
+
// orders: ['asc', 'desc', null],
|
|
1860
|
+
// sortMethod: null,
|
|
1861
|
+
showIcon: true,
|
|
1862
|
+
iconLayout: 'vertical'
|
|
1863
|
+
},
|
|
1864
|
+
filterConfig: {
|
|
1865
|
+
// remote: false,
|
|
1866
|
+
// filterMethod: null,
|
|
1867
|
+
showIcon: true
|
|
1868
|
+
},
|
|
1869
|
+
treeConfig: {
|
|
1870
|
+
rowField: 'id',
|
|
1871
|
+
parentField: 'parentId',
|
|
1872
|
+
childrenField: 'children',
|
|
1873
|
+
hasChildField: 'hasChild',
|
|
1874
|
+
mapChildrenField: '_X_ROW_CHILD',
|
|
1875
|
+
indent: 20,
|
|
1876
|
+
showIcon: true
|
|
1877
|
+
},
|
|
1878
|
+
expandConfig: {
|
|
1879
|
+
// trigger: 'default',
|
|
1880
|
+
showIcon: true
|
|
1881
|
+
},
|
|
1882
|
+
editConfig: {
|
|
1883
|
+
// mode: 'cell',
|
|
1884
|
+
showIcon: true,
|
|
1885
|
+
showAsterisk: true
|
|
1886
|
+
},
|
|
1887
|
+
importConfig: {
|
|
1888
|
+
_typeMaps: {
|
|
1889
|
+
csv: 1,
|
|
1890
|
+
html: 1,
|
|
1891
|
+
xml: 1,
|
|
1892
|
+
txt: 1
|
|
1893
|
+
},
|
|
1894
|
+
modes: ['insert', 'covering']
|
|
1895
|
+
},
|
|
1896
|
+
exportConfig: {
|
|
1897
|
+
_typeMaps: {
|
|
1898
|
+
csv: 1,
|
|
1899
|
+
html: 1,
|
|
1900
|
+
xml: 1,
|
|
1901
|
+
txt: 1
|
|
1902
|
+
},
|
|
1903
|
+
modes: ['current', 'selected']
|
|
1904
|
+
},
|
|
1905
|
+
printConfig: {
|
|
1906
|
+
modes: ['current', 'selected']
|
|
1907
|
+
},
|
|
1908
|
+
mouseConfig: {
|
|
1909
|
+
extension: true
|
|
1910
|
+
},
|
|
1911
|
+
keyboardConfig: {
|
|
1912
|
+
isEsc: true
|
|
1913
|
+
},
|
|
1914
|
+
areaConfig: {
|
|
1915
|
+
autoClear: true,
|
|
1916
|
+
selectCellByHeader: true
|
|
1917
|
+
},
|
|
1918
|
+
clipConfig: {
|
|
1919
|
+
isCopy: true,
|
|
1920
|
+
isCut: true,
|
|
1921
|
+
isPaste: true
|
|
1922
|
+
},
|
|
1923
|
+
fnrConfig: {
|
|
1924
|
+
isFind: true,
|
|
1925
|
+
isReplace: true
|
|
1926
|
+
},
|
|
1927
|
+
scrollX: {
|
|
1928
|
+
// enabled: false,
|
|
1929
|
+
gt: 60
|
|
1930
|
+
// oSize: 0
|
|
1931
|
+
},
|
|
1932
|
+
scrollY: {
|
|
1933
|
+
// enabled: false,
|
|
1934
|
+
gt: 100
|
|
1935
|
+
// oSize: 0
|
|
1823
1936
|
}
|
|
1824
|
-
}
|
|
1825
|
-
|
|
1826
|
-
}
|
|
1827
|
-
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1937
|
+
},
|
|
1938
|
+
// export: {
|
|
1939
|
+
// types: {}
|
|
1940
|
+
// },
|
|
1941
|
+
grid: {
|
|
1942
|
+
// size: null,
|
|
1943
|
+
// zoomConfig: {
|
|
1944
|
+
// escRestore: true
|
|
1945
|
+
// },
|
|
1946
|
+
formConfig: {
|
|
1947
|
+
enabled: true
|
|
1948
|
+
},
|
|
1949
|
+
pagerConfig: {
|
|
1950
|
+
enabled: true
|
|
1951
|
+
// perfect: false
|
|
1952
|
+
},
|
|
1953
|
+
toolbarConfig: {
|
|
1954
|
+
enabled: true
|
|
1955
|
+
// perfect: false
|
|
1956
|
+
},
|
|
1957
|
+
proxyConfig: {
|
|
1958
|
+
enabled: true,
|
|
1959
|
+
autoLoad: true,
|
|
1960
|
+
message: true,
|
|
1961
|
+
props: {
|
|
1962
|
+
list: null,
|
|
1963
|
+
result: 'result',
|
|
1964
|
+
total: 'page.total',
|
|
1965
|
+
message: 'message'
|
|
1838
1966
|
}
|
|
1967
|
+
// beforeItem: null,
|
|
1968
|
+
// beforeColumn: null,
|
|
1969
|
+
// beforeQuery: null,
|
|
1970
|
+
// afterQuery: null,
|
|
1971
|
+
// beforeDelete: null,
|
|
1972
|
+
// afterDelete: null,
|
|
1973
|
+
// beforeSave: null,
|
|
1974
|
+
// afterSave: null
|
|
1839
1975
|
}
|
|
1976
|
+
},
|
|
1977
|
+
toolbar: {
|
|
1978
|
+
// size: null,
|
|
1979
|
+
// import: {
|
|
1980
|
+
// mode: 'covering'
|
|
1981
|
+
// },
|
|
1982
|
+
// export: {
|
|
1983
|
+
// types: ['csv', 'html', 'xml', 'txt']
|
|
1984
|
+
// },
|
|
1985
|
+
// buttons: []
|
|
1840
1986
|
}
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
|
|
1847
|
-
|
|
1848
|
-
|
|
1849
|
-
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
|
|
1853
|
-
|
|
1854
|
-
|
|
1855
|
-
|
|
1856
|
-
|
|
1857
|
-
|
|
1858
|
-
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1987
|
+
});
|
|
1988
|
+
const iconPrefix = 'vxe-icon-';
|
|
1989
|
+
external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.setIcon({
|
|
1990
|
+
// table
|
|
1991
|
+
TABLE_SORT_ASC: iconPrefix + 'caret-up',
|
|
1992
|
+
TABLE_SORT_DESC: iconPrefix + 'caret-down',
|
|
1993
|
+
TABLE_FILTER_NONE: iconPrefix + 'funnel',
|
|
1994
|
+
TABLE_FILTER_MATCH: iconPrefix + 'funnel',
|
|
1995
|
+
TABLE_EDIT: iconPrefix + 'edit',
|
|
1996
|
+
TABLE_TITLE_PREFIX: iconPrefix + 'question-circle-fill',
|
|
1997
|
+
TABLE_TITLE_SUFFIX: iconPrefix + 'question-circle-fill',
|
|
1998
|
+
TABLE_TREE_LOADED: iconPrefix + 'spinner roll',
|
|
1999
|
+
TABLE_TREE_OPEN: iconPrefix + 'caret-right rotate90',
|
|
2000
|
+
TABLE_TREE_CLOSE: iconPrefix + 'caret-right',
|
|
2001
|
+
TABLE_EXPAND_LOADED: iconPrefix + 'spinner roll',
|
|
2002
|
+
TABLE_EXPAND_OPEN: iconPrefix + 'arrow-right rotate90',
|
|
2003
|
+
TABLE_EXPAND_CLOSE: iconPrefix + 'arrow-right',
|
|
2004
|
+
TABLE_CHECKBOX_CHECKED: iconPrefix + 'checkbox-checked-fill',
|
|
2005
|
+
TABLE_CHECKBOX_UNCHECKED: iconPrefix + 'checkbox-unchecked',
|
|
2006
|
+
TABLE_CHECKBOX_INDETERMINATE: iconPrefix + 'checkbox-indeterminate-fill',
|
|
2007
|
+
TABLE_RADIO_CHECKED: iconPrefix + 'radio-checked-fill',
|
|
2008
|
+
TABLE_RADIO_UNCHECKED: iconPrefix + 'radio-unchecked',
|
|
2009
|
+
TABLE_CUSTOM_SORT: iconPrefix + 'drag-handle',
|
|
2010
|
+
// toolbar
|
|
2011
|
+
TOOLBAR_TOOLS_REFRESH: iconPrefix + 'repeat',
|
|
2012
|
+
TOOLBAR_TOOLS_REFRESH_LOADING: iconPrefix + 'repeat roll',
|
|
2013
|
+
TOOLBAR_TOOLS_IMPORT: iconPrefix + 'upload',
|
|
2014
|
+
TOOLBAR_TOOLS_EXPORT: iconPrefix + 'download',
|
|
2015
|
+
TOOLBAR_TOOLS_PRINT: iconPrefix + 'print',
|
|
2016
|
+
TOOLBAR_TOOLS_FULLSCREEN: iconPrefix + 'fullscreen',
|
|
2017
|
+
TOOLBAR_TOOLS_MINIMIZE: iconPrefix + 'minimize',
|
|
2018
|
+
TOOLBAR_TOOLS_CUSTOM: iconPrefix + 'custom-column',
|
|
2019
|
+
TOOLBAR_TOOLS_FIXED_LEFT: iconPrefix + 'fixed-left',
|
|
2020
|
+
TOOLBAR_TOOLS_FIXED_LEFT_ACTIVE: iconPrefix + 'fixed-left-fill',
|
|
2021
|
+
TOOLBAR_TOOLS_FIXED_RIGHT: iconPrefix + 'fixed-right',
|
|
2022
|
+
TOOLBAR_TOOLS_FIXED_RIGHT_ACTIVE: iconPrefix + 'fixed-right-fill'
|
|
2023
|
+
});
|
|
2024
|
+
const setTheme = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.setTheme;
|
|
2025
|
+
const getTheme = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.getTheme;
|
|
2026
|
+
const setConfig = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.setConfig;
|
|
2027
|
+
const getConfig = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.getConfig;
|
|
2028
|
+
const setIcon = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.setIcon;
|
|
2029
|
+
const getIcon = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.getIcon;
|
|
2030
|
+
const setLanguage = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.setLanguage;
|
|
2031
|
+
const setI18n = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.setI18n;
|
|
2032
|
+
const getI18n = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.getI18n;
|
|
2033
|
+
const globalEvents = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.globalEvents;
|
|
2034
|
+
const globalResize = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.globalResize;
|
|
2035
|
+
const renderer = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.renderer;
|
|
2036
|
+
const validators = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.validators;
|
|
2037
|
+
const menus = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.menus;
|
|
2038
|
+
const formats = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.formats;
|
|
2039
|
+
const commands = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.commands;
|
|
2040
|
+
const interceptor = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.interceptor;
|
|
2041
|
+
const clipboard = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.clipboard;
|
|
2042
|
+
const log = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.log;
|
|
2043
|
+
const hooks = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.hooks;
|
|
2044
|
+
const use = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.use;
|
|
2045
|
+
/**
|
|
2046
|
+
* 已废弃
|
|
2047
|
+
* @deprecated
|
|
2048
|
+
*/
|
|
2049
|
+
const setup = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.setup;
|
|
2050
|
+
/**
|
|
2051
|
+
* 已废弃
|
|
2052
|
+
* @deprecated
|
|
2053
|
+
*/
|
|
2054
|
+
const config = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.config;
|
|
2055
|
+
/**
|
|
2056
|
+
* 已废弃
|
|
2057
|
+
* @deprecated
|
|
2058
|
+
*/
|
|
2059
|
+
const t = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.t;
|
|
2060
|
+
/**
|
|
2061
|
+
* 已废弃
|
|
2062
|
+
* @deprecated
|
|
2063
|
+
*/
|
|
2064
|
+
const _t = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI._t;
|
|
2065
|
+
/**
|
|
2066
|
+
* 已废弃,兼容老版本
|
|
2067
|
+
* @deprecated
|
|
2068
|
+
*/
|
|
2069
|
+
const VXETable = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI;
|
|
2070
|
+
const saveFile = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.readFile;
|
|
2071
|
+
const readFile = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.readFile;
|
|
2072
|
+
|
|
2073
|
+
/* harmony default export */ var ui = ((/* unused pure expression or super */ null && (VxeUI)));
|
|
2074
|
+
// EXTERNAL MODULE: external {"commonjs":"vue","commonjs2":"vue","root":"Vue"}
|
|
2075
|
+
var external_commonjs_vue_commonjs2_vue_root_Vue_ = __webpack_require__(9274);
|
|
2076
|
+
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.push.js
|
|
2077
|
+
var es_array_push = __webpack_require__(4114);
|
|
2078
|
+
// EXTERNAL MODULE: external {"root":"XEUtils","commonjs":"xe-utils","commonjs2":"xe-utils","amd":"xe-utils"}
|
|
2079
|
+
var external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_ = __webpack_require__(8871);
|
|
2080
|
+
var external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default = /*#__PURE__*/__webpack_require__.n(external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_);
|
|
2081
|
+
;// CONCATENATED MODULE: ./node_modules/dom-zindex/es/index.esm.js
|
|
2082
|
+
var storeEl = null;
|
|
2083
|
+
var storeId = 'z-index-manage';
|
|
2084
|
+
var storeMainKey = 'm';
|
|
2085
|
+
var storeSubKey = 's';
|
|
2086
|
+
var storeData = {
|
|
2087
|
+
m: 1000,
|
|
2088
|
+
s: 1000
|
|
2089
|
+
};
|
|
2090
|
+
function isDocument() {
|
|
2091
|
+
return typeof document !== 'undefined';
|
|
2092
|
+
}
|
|
2093
|
+
function getDomMaxZIndex() {
|
|
2094
|
+
var max = 0;
|
|
2095
|
+
if (isDocument()) {
|
|
2096
|
+
var allElem = document.body.getElementsByTagName('*');
|
|
2097
|
+
for (var i = 0; i < allElem.length; i++) {
|
|
2098
|
+
var elem = allElem[i];
|
|
2099
|
+
if (elem && elem.style && elem.nodeType === 1) {
|
|
2100
|
+
var zIndex = elem.style.zIndex;
|
|
2101
|
+
if (zIndex && /^\d+$/.test(zIndex)) {
|
|
2102
|
+
max = Math.max(max, Number(zIndex));
|
|
2103
|
+
}
|
|
2104
|
+
}
|
|
2105
|
+
}
|
|
2106
|
+
}
|
|
2107
|
+
return max;
|
|
2108
|
+
}
|
|
2109
|
+
function getDom() {
|
|
2110
|
+
if (!storeEl) {
|
|
2111
|
+
if (isDocument()) {
|
|
2112
|
+
storeEl = document.getElementById(storeId);
|
|
2113
|
+
if (!storeEl) {
|
|
2114
|
+
storeEl = document.createElement('div');
|
|
2115
|
+
storeEl.id = storeId;
|
|
2116
|
+
storeEl.style.display = 'none';
|
|
2117
|
+
document.body.appendChild(storeEl);
|
|
2118
|
+
setCurrent(storeData.m);
|
|
2119
|
+
setSubCurrent(storeData.s);
|
|
2120
|
+
}
|
|
2121
|
+
}
|
|
2122
|
+
}
|
|
2123
|
+
return storeEl;
|
|
2124
|
+
}
|
|
2125
|
+
function createSetHandle(key) {
|
|
2126
|
+
return function (value) {
|
|
2127
|
+
if (value) {
|
|
2128
|
+
value = Number(value);
|
|
2129
|
+
storeData[key] = value;
|
|
2130
|
+
var doc = getDom();
|
|
2131
|
+
if (doc) {
|
|
2132
|
+
if (doc.dataset) {
|
|
2133
|
+
doc.dataset[key] = value + '';
|
|
2134
|
+
} else {
|
|
2135
|
+
doc.setAttribute('data-' + key, value + '');
|
|
2136
|
+
}
|
|
2137
|
+
}
|
|
2138
|
+
}
|
|
2139
|
+
return storeData[key];
|
|
2140
|
+
};
|
|
2141
|
+
}
|
|
2142
|
+
var setCurrent = createSetHandle(storeMainKey);
|
|
2143
|
+
function createGetHandle(key, nextMethod) {
|
|
2144
|
+
return function getCurrent(currZindex) {
|
|
2145
|
+
var zIndex;
|
|
1864
2146
|
var doc = getDom();
|
|
1865
2147
|
if (doc) {
|
|
1866
2148
|
var domVal = doc.dataset ? doc.dataset[key] : doc.getAttribute('data-' + key);
|
|
@@ -1957,9 +2239,9 @@ function eqEmptyValue(cellValue) {
|
|
|
1957
2239
|
|
|
1958
2240
|
|
|
1959
2241
|
const {
|
|
1960
|
-
getI18n,
|
|
1961
|
-
formats,
|
|
1962
|
-
log
|
|
2242
|
+
getI18n: columnInfo_getI18n,
|
|
2243
|
+
formats: columnInfo_formats,
|
|
2244
|
+
log: columnInfo_log
|
|
1963
2245
|
} = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI;
|
|
1964
2246
|
class ColumnInfo {
|
|
1965
2247
|
/* eslint-disable @typescript-eslint/no-use-before-define */
|
|
@@ -1975,16 +2257,16 @@ class ColumnInfo {
|
|
|
1975
2257
|
if (true) {
|
|
1976
2258
|
const types = ['seq', 'checkbox', 'radio', 'expand', 'html'];
|
|
1977
2259
|
if (_vm.type && types.indexOf(_vm.type) === -1) {
|
|
1978
|
-
|
|
2260
|
+
columnInfo_log.warn('vxe.error.errProp', [`type=${_vm.type}`, types.join(', ')]);
|
|
1979
2261
|
}
|
|
1980
2262
|
if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isBoolean(_vm.cellRender) || _vm.cellRender && !external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isObject(_vm.cellRender)) {
|
|
1981
|
-
|
|
2263
|
+
columnInfo_log.warn('vxe.error.errProp', [`column.cell-render=${_vm.cellRender}`, 'column.cell-render={}']);
|
|
1982
2264
|
}
|
|
1983
2265
|
if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isBoolean(_vm.editRender) || _vm.editRender && !external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isObject(_vm.editRender)) {
|
|
1984
|
-
|
|
2266
|
+
columnInfo_log.warn('vxe.error.errProp', [`column.edit-render=${_vm.editRender}`, 'column.edit-render={}']);
|
|
1985
2267
|
}
|
|
1986
2268
|
if (_vm.cellRender && _vm.editRender) {
|
|
1987
|
-
|
|
2269
|
+
columnInfo_log.warn('vxe.error.errConflicts', ['column.cell-render', 'column.edit-render']);
|
|
1988
2270
|
}
|
|
1989
2271
|
if (_vm.type === 'expand') {
|
|
1990
2272
|
const {
|
|
@@ -1998,19 +2280,19 @@ class ColumnInfo {
|
|
|
1998
2280
|
} = $xeTable.getComputeMaps();
|
|
1999
2281
|
const treeOpts = computeTreeOpts.value;
|
|
2000
2282
|
if (treeConfig && (treeOpts.showLine || treeOpts.line)) {
|
|
2001
|
-
|
|
2283
|
+
columnInfo_log.err('vxe.error.errConflicts', ['tree-config.showLine', 'column.type=expand']);
|
|
2002
2284
|
}
|
|
2003
2285
|
}
|
|
2004
2286
|
if (formatter) {
|
|
2005
2287
|
if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isString(formatter)) {
|
|
2006
|
-
const gFormatOpts =
|
|
2288
|
+
const gFormatOpts = columnInfo_formats.get(formatter) || (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default())[formatter];
|
|
2007
2289
|
if (!gFormatOpts || !external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(gFormatOpts.cellFormatMethod)) {
|
|
2008
|
-
|
|
2290
|
+
columnInfo_log.err('vxe.error.notFormats', [formatter]);
|
|
2009
2291
|
}
|
|
2010
2292
|
} else if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(formatter)) {
|
|
2011
|
-
const gFormatOpts =
|
|
2293
|
+
const gFormatOpts = columnInfo_formats.get(formatter[0]) || (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default())[formatter[0]];
|
|
2012
2294
|
if (!gFormatOpts || !external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(gFormatOpts.cellFormatMethod)) {
|
|
2013
|
-
|
|
2295
|
+
columnInfo_log.err('vxe.error.notFormats', [formatter[0]]);
|
|
2014
2296
|
}
|
|
2015
2297
|
}
|
|
2016
2298
|
}
|
|
@@ -2081,6 +2363,8 @@ class ColumnInfo {
|
|
|
2081
2363
|
// 列排序
|
|
2082
2364
|
sortNumber: 0,
|
|
2083
2365
|
renderSortNumber: 0,
|
|
2366
|
+
renderFixed: '',
|
|
2367
|
+
renderVisible: false,
|
|
2084
2368
|
renderWidth: 0,
|
|
2085
2369
|
renderHeight: 0,
|
|
2086
2370
|
resizeWidth: 0,
|
|
@@ -2108,7 +2392,7 @@ class ColumnInfo {
|
|
|
2108
2392
|
}
|
|
2109
2393
|
}
|
|
2110
2394
|
getTitle() {
|
|
2111
|
-
return getFuncText(this.title || (this.type === 'seq' ?
|
|
2395
|
+
return getFuncText(this.title || (this.type === 'seq' ? columnInfo_getI18n('vxe.table.seqTitle') : ''));
|
|
2112
2396
|
}
|
|
2113
2397
|
getKey() {
|
|
2114
2398
|
return this.field || (this.type ? `type=${this.type}` : null);
|
|
@@ -2793,8 +3077,8 @@ function getSlotVNs(vns) {
|
|
|
2793
3077
|
|
|
2794
3078
|
const {
|
|
2795
3079
|
getI18n: cell_getI18n,
|
|
2796
|
-
getIcon,
|
|
2797
|
-
renderer
|
|
3080
|
+
getIcon: cell_getIcon,
|
|
3081
|
+
renderer: cell_renderer
|
|
2798
3082
|
} = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI;
|
|
2799
3083
|
function renderTitlePrefixIcon(params) {
|
|
2800
3084
|
const {
|
|
@@ -2803,7 +3087,7 @@ function renderTitlePrefixIcon(params) {
|
|
|
2803
3087
|
} = params;
|
|
2804
3088
|
const titlePrefix = column.titlePrefix || column.titleHelp;
|
|
2805
3089
|
return titlePrefix ? [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
2806
|
-
class: ['vxe-cell-title-prefix-icon', titlePrefix.icon ||
|
|
3090
|
+
class: ['vxe-cell-title-prefix-icon', titlePrefix.icon || cell_getIcon().TABLE_TITLE_PREFIX],
|
|
2807
3091
|
onMouseenter(evnt) {
|
|
2808
3092
|
$table.triggerHeaderTitleEvent(evnt, titlePrefix, params);
|
|
2809
3093
|
},
|
|
@@ -2819,7 +3103,7 @@ function renderTitleSuffixIcon(params) {
|
|
|
2819
3103
|
} = params;
|
|
2820
3104
|
const titleSuffix = column.titleSuffix;
|
|
2821
3105
|
return titleSuffix ? [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
2822
|
-
class: ['vxe-cell-title-suffix-icon', titleSuffix.icon ||
|
|
3106
|
+
class: ['vxe-cell-title-suffix-icon', titleSuffix.icon || cell_getIcon().TABLE_TITLE_SUFFIX],
|
|
2823
3107
|
onMouseenter(evnt) {
|
|
2824
3108
|
$table.triggerHeaderTitleEvent(evnt, titleSuffix, params);
|
|
2825
3109
|
},
|
|
@@ -2903,7 +3187,7 @@ function getFooterContent(params) {
|
|
|
2903
3187
|
return $table.callSlot(footerSlot, params);
|
|
2904
3188
|
}
|
|
2905
3189
|
if (renderOpts) {
|
|
2906
|
-
const compConf =
|
|
3190
|
+
const compConf = cell_renderer.get(renderOpts.name);
|
|
2907
3191
|
if (compConf && compConf.renderFooter) {
|
|
2908
3192
|
return getSlotVNs(compConf.renderFooter(renderOpts, params));
|
|
2909
3193
|
}
|
|
@@ -3008,7 +3292,7 @@ const Cell = {
|
|
|
3008
3292
|
return renderTitleContent(params, $table.callSlot(headerSlot, params));
|
|
3009
3293
|
}
|
|
3010
3294
|
if (renderOpts) {
|
|
3011
|
-
const compConf =
|
|
3295
|
+
const compConf = cell_renderer.get(renderOpts.name);
|
|
3012
3296
|
if (compConf && compConf.renderHeader) {
|
|
3013
3297
|
return renderTitleContent(params, getSlotVNs(compConf.renderHeader(renderOpts, params)));
|
|
3014
3298
|
}
|
|
@@ -3036,7 +3320,7 @@ const Cell = {
|
|
|
3036
3320
|
}
|
|
3037
3321
|
if (renderOpts) {
|
|
3038
3322
|
const funName = editRender ? 'renderCell' : 'renderDefault';
|
|
3039
|
-
const compConf =
|
|
3323
|
+
const compConf = cell_renderer.get(renderOpts.name);
|
|
3040
3324
|
const compFn = compConf ? compConf[funName] : null;
|
|
3041
3325
|
if (compFn) {
|
|
3042
3326
|
return getSlotVNs(compFn(renderOpts, Object.assign({
|
|
@@ -3134,7 +3418,7 @@ const Cell = {
|
|
|
3134
3418
|
class: 'vxe-tree--btn-wrapper',
|
|
3135
3419
|
...ons
|
|
3136
3420
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
3137
|
-
class: ['vxe-tree--node-btn', isLazyLoaded ? iconLoaded ||
|
|
3421
|
+
class: ['vxe-tree--node-btn', isLazyLoaded ? iconLoaded || cell_getIcon().TABLE_TREE_LOADED : isAceived ? iconOpen || cell_getIcon().TABLE_TREE_OPEN : iconClose || cell_getIcon().TABLE_TREE_CLOSE]
|
|
3138
3422
|
})])] : null, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
3139
3423
|
class: 'vxe-tree-cell'
|
|
3140
3424
|
}, cellVNodes)])];
|
|
@@ -3263,7 +3547,7 @@ const Cell = {
|
|
|
3263
3547
|
const radioVNs = [];
|
|
3264
3548
|
if (isVisible) {
|
|
3265
3549
|
radioVNs.push((0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
3266
|
-
class: ['vxe-radio--icon', isChecked ?
|
|
3550
|
+
class: ['vxe-radio--icon', isChecked ? cell_getIcon().TABLE_RADIO_CHECKED : cell_getIcon().TABLE_RADIO_UNCHECKED]
|
|
3267
3551
|
}));
|
|
3268
3552
|
}
|
|
3269
3553
|
if (defaultSlot || labelField) {
|
|
@@ -3344,7 +3628,7 @@ const Cell = {
|
|
|
3344
3628
|
title: cell_getI18n('vxe.table.allTitle'),
|
|
3345
3629
|
...ons
|
|
3346
3630
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
3347
|
-
class: ['vxe-checkbox--icon', isAllCheckboxIndeterminate ?
|
|
3631
|
+
class: ['vxe-checkbox--icon', isAllCheckboxIndeterminate ? cell_getIcon().TABLE_CHECKBOX_INDETERMINATE : isAllCheckboxSelected ? cell_getIcon().TABLE_CHECKBOX_CHECKED : cell_getIcon().TABLE_CHECKBOX_UNCHECKED]
|
|
3348
3632
|
})].concat(titleSlot || headerTitle ? [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
3349
3633
|
class: 'vxe-checkbox--label'
|
|
3350
3634
|
}, titleSlot ? $table.callSlot(titleSlot, checkboxParams) : headerTitle)] : []))]);
|
|
@@ -3421,7 +3705,7 @@ const Cell = {
|
|
|
3421
3705
|
const checkVNs = [];
|
|
3422
3706
|
if (isVisible) {
|
|
3423
3707
|
checkVNs.push((0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
3424
|
-
class: ['vxe-checkbox--icon', indeterminate ?
|
|
3708
|
+
class: ['vxe-checkbox--icon', indeterminate ? cell_getIcon().TABLE_CHECKBOX_INDETERMINATE : isChecked ? cell_getIcon().TABLE_CHECKBOX_CHECKED : cell_getIcon().TABLE_CHECKBOX_UNCHECKED]
|
|
3425
3709
|
}));
|
|
3426
3710
|
}
|
|
3427
3711
|
if (defaultSlot || labelField) {
|
|
@@ -3515,7 +3799,7 @@ const Cell = {
|
|
|
3515
3799
|
const checkVNs = [];
|
|
3516
3800
|
if (isVisible) {
|
|
3517
3801
|
checkVNs.push((0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
3518
|
-
class: ['vxe-checkbox--icon', isIndeterminate ?
|
|
3802
|
+
class: ['vxe-checkbox--icon', isIndeterminate ? cell_getIcon().TABLE_CHECKBOX_INDETERMINATE : isChecked ? cell_getIcon().TABLE_CHECKBOX_CHECKED : cell_getIcon().TABLE_CHECKBOX_UNCHECKED]
|
|
3519
3803
|
}));
|
|
3520
3804
|
if (defaultSlot || labelField) {
|
|
3521
3805
|
checkVNs.push((0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
@@ -3592,7 +3876,7 @@ const Cell = {
|
|
|
3592
3876
|
$table.triggerRowExpandEvent(evnt, params);
|
|
3593
3877
|
}
|
|
3594
3878
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
3595
|
-
class: ['vxe-table--expand-btn', isLazyLoaded ? iconLoaded ||
|
|
3879
|
+
class: ['vxe-table--expand-btn', isLazyLoaded ? iconLoaded || cell_getIcon().TABLE_EXPAND_LOADED : isAceived ? iconOpen || cell_getIcon().TABLE_EXPAND_OPEN : iconClose || cell_getIcon().TABLE_EXPAND_CLOSE]
|
|
3596
3880
|
})]) : null, defaultSlot || labelField ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
3597
3881
|
class: 'vxe-table--expand-label'
|
|
3598
3882
|
}, defaultSlot ? $table.callSlot(defaultSlot, params) : external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().get(row, labelField)) : null];
|
|
@@ -3611,7 +3895,7 @@ const Cell = {
|
|
|
3611
3895
|
return $table.callSlot(contentSlot, params);
|
|
3612
3896
|
}
|
|
3613
3897
|
if (contentRender) {
|
|
3614
|
-
const compConf =
|
|
3898
|
+
const compConf = cell_renderer.get(contentRender.name);
|
|
3615
3899
|
if (compConf && compConf.renderExpand) {
|
|
3616
3900
|
return getSlotVNs(compConf.renderExpand(contentRender, params));
|
|
3617
3901
|
}
|
|
@@ -3675,7 +3959,7 @@ const Cell = {
|
|
|
3675
3959
|
return [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
3676
3960
|
class: ['vxe-cell--sort', `vxe-cell--sort-${iconLayout}-layout`]
|
|
3677
3961
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
3678
|
-
class: ['vxe-sort--asc-btn', iconAsc ||
|
|
3962
|
+
class: ['vxe-sort--asc-btn', iconAsc || cell_getIcon().TABLE_SORT_ASC, {
|
|
3679
3963
|
'sort--active': order === 'asc'
|
|
3680
3964
|
}],
|
|
3681
3965
|
title: cell_getI18n('vxe.table.sortAsc'),
|
|
@@ -3684,7 +3968,7 @@ const Cell = {
|
|
|
3684
3968
|
$table.triggerSortEvent(evnt, column, 'asc');
|
|
3685
3969
|
}
|
|
3686
3970
|
}), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
3687
|
-
class: ['vxe-sort--desc-btn', iconDesc ||
|
|
3971
|
+
class: ['vxe-sort--desc-btn', iconDesc || cell_getIcon().TABLE_SORT_DESC, {
|
|
3688
3972
|
'sort--active': order === 'desc'
|
|
3689
3973
|
}],
|
|
3690
3974
|
title: cell_getI18n('vxe.table.sortDesc'),
|
|
@@ -3728,7 +4012,7 @@ const Cell = {
|
|
|
3728
4012
|
'is--active': filterStore.visible && filterStore.column === column
|
|
3729
4013
|
}]
|
|
3730
4014
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
3731
|
-
class: ['vxe-filter--btn', hasFilter ? iconMatch ||
|
|
4015
|
+
class: ['vxe-filter--btn', hasFilter ? iconMatch || cell_getIcon().TABLE_FILTER_MATCH : iconNone || cell_getIcon().TABLE_FILTER_NONE],
|
|
3732
4016
|
title: cell_getI18n('vxe.table.filter'),
|
|
3733
4017
|
onClick(evnt) {
|
|
3734
4018
|
if ($table.triggerFilterEvent) {
|
|
@@ -3771,7 +4055,7 @@ const Cell = {
|
|
|
3771
4055
|
return (isEnableConf(editConfig) ? [isRequired && editOpts.showAsterisk ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
3772
4056
|
class: 'vxe-cell--required-icon'
|
|
3773
4057
|
}) : null, isEnableConf(editRender) && editOpts.showIcon ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
3774
|
-
class: ['vxe-cell--edit-icon', editOpts.icon ||
|
|
4058
|
+
class: ['vxe-cell--edit-icon', editOpts.icon || cell_getIcon().TABLE_EDIT]
|
|
3775
4059
|
}) : null] : []).concat(Cell.renderDefaultHeader(params)).concat(sortable ? Cell.renderSortIcon(params) : []).concat(filters ? Cell.renderFilterIcon(params) : []);
|
|
3776
4060
|
},
|
|
3777
4061
|
// 行格编辑模式
|
|
@@ -3832,7 +4116,7 @@ const Cell = {
|
|
|
3832
4116
|
} = column;
|
|
3833
4117
|
const defaultSlot = slots ? slots.default : null;
|
|
3834
4118
|
const editSlot = slots ? slots.edit : null;
|
|
3835
|
-
const compConf =
|
|
4119
|
+
const compConf = cell_renderer.get(editRender.name);
|
|
3836
4120
|
if (isEdit) {
|
|
3837
4121
|
if (editSlot) {
|
|
3838
4122
|
return $table.callSlot(editSlot, params);
|
|
@@ -5855,7 +6139,7 @@ function mergeFooterMethod(mergeFooterList, _rowIndex, _columnIndex) {
|
|
|
5855
6139
|
;// CONCATENATED MODULE: ./packages/table/src/props.ts
|
|
5856
6140
|
|
|
5857
6141
|
const {
|
|
5858
|
-
getConfig
|
|
6142
|
+
getConfig: props_getConfig
|
|
5859
6143
|
} = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI;
|
|
5860
6144
|
/* harmony default export */ var props = ({
|
|
5861
6145
|
/** 基本属性 */
|
|
@@ -5867,81 +6151,81 @@ const {
|
|
|
5867
6151
|
// 表格的最小高度
|
|
5868
6152
|
minHeight: {
|
|
5869
6153
|
type: [Number, String],
|
|
5870
|
-
default: () =>
|
|
6154
|
+
default: () => props_getConfig().table.minHeight
|
|
5871
6155
|
},
|
|
5872
6156
|
// 表格的最大高度
|
|
5873
6157
|
maxHeight: [Number, String],
|
|
5874
6158
|
// 已废弃,被 column-config.resizable 替换
|
|
5875
6159
|
resizable: {
|
|
5876
6160
|
type: Boolean,
|
|
5877
|
-
default: () =>
|
|
6161
|
+
default: () => props_getConfig().table.resizable
|
|
5878
6162
|
},
|
|
5879
6163
|
// 是否带有斑马纹
|
|
5880
6164
|
stripe: {
|
|
5881
6165
|
type: Boolean,
|
|
5882
|
-
default: () =>
|
|
6166
|
+
default: () => props_getConfig().table.stripe
|
|
5883
6167
|
},
|
|
5884
6168
|
// 是否带有边框
|
|
5885
6169
|
border: {
|
|
5886
6170
|
type: [Boolean, String],
|
|
5887
|
-
default: () =>
|
|
6171
|
+
default: () => props_getConfig().table.border
|
|
5888
6172
|
},
|
|
5889
6173
|
// 是否圆角边框
|
|
5890
6174
|
round: {
|
|
5891
6175
|
type: Boolean,
|
|
5892
|
-
default: () =>
|
|
6176
|
+
default: () => props_getConfig().table.round
|
|
5893
6177
|
},
|
|
5894
6178
|
// 表格的尺寸
|
|
5895
6179
|
size: {
|
|
5896
6180
|
type: String,
|
|
5897
|
-
default: () =>
|
|
6181
|
+
default: () => props_getConfig().table.size || props_getConfig().size
|
|
5898
6182
|
},
|
|
5899
6183
|
// 列的宽度是否自撑开(可能会被废弃的参数,不要使用)
|
|
5900
6184
|
fit: {
|
|
5901
6185
|
type: Boolean,
|
|
5902
|
-
default: () =>
|
|
6186
|
+
default: () => props_getConfig().table.fit
|
|
5903
6187
|
},
|
|
5904
6188
|
// 表格是否加载中
|
|
5905
6189
|
loading: Boolean,
|
|
5906
6190
|
// 所有的列对其方式
|
|
5907
6191
|
align: {
|
|
5908
6192
|
type: String,
|
|
5909
|
-
default: () =>
|
|
6193
|
+
default: () => props_getConfig().table.align
|
|
5910
6194
|
},
|
|
5911
6195
|
// 所有的表头列的对齐方式
|
|
5912
6196
|
headerAlign: {
|
|
5913
6197
|
type: String,
|
|
5914
|
-
default: () =>
|
|
6198
|
+
default: () => props_getConfig().table.headerAlign
|
|
5915
6199
|
},
|
|
5916
6200
|
// 所有的表尾列的对齐方式
|
|
5917
6201
|
footerAlign: {
|
|
5918
6202
|
type: String,
|
|
5919
|
-
default: () =>
|
|
6203
|
+
default: () => props_getConfig().table.footerAlign
|
|
5920
6204
|
},
|
|
5921
6205
|
// 是否显示表头
|
|
5922
6206
|
showHeader: {
|
|
5923
6207
|
type: Boolean,
|
|
5924
|
-
default: () =>
|
|
6208
|
+
default: () => props_getConfig().table.showHeader
|
|
5925
6209
|
},
|
|
5926
6210
|
// (即将废弃)是否要高亮当前选中行
|
|
5927
6211
|
highlightCurrentRow: {
|
|
5928
6212
|
type: Boolean,
|
|
5929
|
-
default: () =>
|
|
6213
|
+
default: () => props_getConfig().table.highlightCurrentRow
|
|
5930
6214
|
},
|
|
5931
6215
|
// (即将废弃)鼠标移到行是否要高亮显示
|
|
5932
6216
|
highlightHoverRow: {
|
|
5933
6217
|
type: Boolean,
|
|
5934
|
-
default: () =>
|
|
6218
|
+
default: () => props_getConfig().table.highlightHoverRow
|
|
5935
6219
|
},
|
|
5936
6220
|
// (即将废弃)是否要高亮当前选中列
|
|
5937
6221
|
highlightCurrentColumn: {
|
|
5938
6222
|
type: Boolean,
|
|
5939
|
-
default: () =>
|
|
6223
|
+
default: () => props_getConfig().table.highlightCurrentColumn
|
|
5940
6224
|
},
|
|
5941
6225
|
// (即将废弃)鼠标移到列是否要高亮显示
|
|
5942
6226
|
highlightHoverColumn: {
|
|
5943
6227
|
type: Boolean,
|
|
5944
|
-
default: () =>
|
|
6228
|
+
default: () => props_getConfig().table.highlightHoverColumn
|
|
5945
6229
|
},
|
|
5946
6230
|
// (即将废弃)激活单元格编辑时是否高亮显示
|
|
5947
6231
|
highlightCell: Boolean,
|
|
@@ -5986,17 +6270,17 @@ const {
|
|
|
5986
6270
|
// 设置所有内容过长时显示为省略号
|
|
5987
6271
|
showOverflow: {
|
|
5988
6272
|
type: [Boolean, String],
|
|
5989
|
-
default: () =>
|
|
6273
|
+
default: () => props_getConfig().table.showOverflow
|
|
5990
6274
|
},
|
|
5991
6275
|
// 设置表头所有内容过长时显示为省略号
|
|
5992
6276
|
showHeaderOverflow: {
|
|
5993
6277
|
type: [Boolean, String],
|
|
5994
|
-
default: () =>
|
|
6278
|
+
default: () => props_getConfig().table.showHeaderOverflow
|
|
5995
6279
|
},
|
|
5996
6280
|
// 设置表尾所有内容过长时显示为省略号
|
|
5997
6281
|
showFooterOverflow: {
|
|
5998
6282
|
type: [Boolean, String],
|
|
5999
|
-
default: () =>
|
|
6283
|
+
default: () => props_getConfig().table.showFooterOverflow
|
|
6000
6284
|
},
|
|
6001
6285
|
/** 高级属性 */
|
|
6002
6286
|
// (即将废弃)columnKey 已废弃,被 column-config.useKey 替换
|
|
@@ -6006,21 +6290,21 @@ const {
|
|
|
6006
6290
|
// (即将废弃)rowId 已废弃,被 row-config.keyField 替换
|
|
6007
6291
|
rowId: {
|
|
6008
6292
|
type: String,
|
|
6009
|
-
default: () =>
|
|
6293
|
+
default: () => props_getConfig().table.rowId
|
|
6010
6294
|
},
|
|
6011
6295
|
zIndex: Number,
|
|
6012
6296
|
emptyText: {
|
|
6013
6297
|
type: String,
|
|
6014
|
-
default: () =>
|
|
6298
|
+
default: () => props_getConfig().table.emptyText
|
|
6015
6299
|
},
|
|
6016
6300
|
keepSource: {
|
|
6017
6301
|
type: Boolean,
|
|
6018
|
-
default: () =>
|
|
6302
|
+
default: () => props_getConfig().table.keepSource
|
|
6019
6303
|
},
|
|
6020
6304
|
// 是否自动监听父容器变化去更新响应式表格宽高
|
|
6021
6305
|
autoResize: {
|
|
6022
6306
|
type: Boolean,
|
|
6023
|
-
default: () =>
|
|
6307
|
+
default: () => props_getConfig().table.autoResize
|
|
6024
6308
|
},
|
|
6025
6309
|
// 是否自动根据状态属性去更新响应式表格宽高
|
|
6026
6310
|
syncResize: [Boolean, String, Number],
|
|
@@ -6085,12 +6369,12 @@ const {
|
|
|
6085
6369
|
// (即将废弃)优化相关
|
|
6086
6370
|
animat: {
|
|
6087
6371
|
type: Boolean,
|
|
6088
|
-
default: () =>
|
|
6372
|
+
default: () => props_getConfig().table.animat
|
|
6089
6373
|
},
|
|
6090
6374
|
// (可能会被废弃的参数,不要使用)
|
|
6091
6375
|
delayHover: {
|
|
6092
6376
|
type: Number,
|
|
6093
|
-
default: () =>
|
|
6377
|
+
default: () => props_getConfig().table.delayHover
|
|
6094
6378
|
},
|
|
6095
6379
|
// 额外的参数
|
|
6096
6380
|
params: Object
|
|
@@ -6119,6 +6403,7 @@ const {
|
|
|
6119
6403
|
setup(props) {
|
|
6120
6404
|
const $xeTable = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.inject)('$xeTable', {});
|
|
6121
6405
|
const {
|
|
6406
|
+
props: tableProps,
|
|
6122
6407
|
reactData
|
|
6123
6408
|
} = $xeTable;
|
|
6124
6409
|
const {
|
|
@@ -6145,25 +6430,78 @@ const {
|
|
|
6145
6430
|
customStore.activeWrapper = false;
|
|
6146
6431
|
setTimeout(() => {
|
|
6147
6432
|
if (!customStore.activeBtn && !customStore.activeWrapper) {
|
|
6148
|
-
$xeTable.
|
|
6433
|
+
$xeTable.customCloseEvent(evnt);
|
|
6149
6434
|
}
|
|
6150
6435
|
}, 300);
|
|
6151
6436
|
};
|
|
6437
|
+
const getStoreData = () => {
|
|
6438
|
+
return {};
|
|
6439
|
+
};
|
|
6440
|
+
const handleSaveStore = type => {
|
|
6441
|
+
const {
|
|
6442
|
+
id
|
|
6443
|
+
} = tableProps;
|
|
6444
|
+
const customOpts = computeCustomOpts.value;
|
|
6445
|
+
const {
|
|
6446
|
+
storage,
|
|
6447
|
+
updateStore
|
|
6448
|
+
} = customOpts;
|
|
6449
|
+
if (storage && id && updateStore) {
|
|
6450
|
+
updateStore({
|
|
6451
|
+
id,
|
|
6452
|
+
type,
|
|
6453
|
+
storeData: getStoreData()
|
|
6454
|
+
});
|
|
6455
|
+
}
|
|
6456
|
+
};
|
|
6152
6457
|
const confirmCustomEvent = evnt => {
|
|
6153
|
-
|
|
6458
|
+
const {
|
|
6459
|
+
customColumnList
|
|
6460
|
+
} = reactData;
|
|
6461
|
+
customColumnList.forEach((column, index) => {
|
|
6462
|
+
const sortIndex = index + 1;
|
|
6463
|
+
column.renderSortNumber = sortIndex;
|
|
6464
|
+
column.fixed = column.renderFixed;
|
|
6465
|
+
column.visible = column.renderVisible;
|
|
6466
|
+
});
|
|
6154
6467
|
$xeTable.closeCustom();
|
|
6155
6468
|
$xeTable.emitCustomEvent('confirm', evnt);
|
|
6469
|
+
handleSaveStore('confirm');
|
|
6156
6470
|
};
|
|
6157
6471
|
const cancelCustomEvent = evnt => {
|
|
6472
|
+
const {
|
|
6473
|
+
customStore
|
|
6474
|
+
} = props;
|
|
6475
|
+
const {
|
|
6476
|
+
customColumnList
|
|
6477
|
+
} = reactData;
|
|
6478
|
+
const {
|
|
6479
|
+
oldSortMaps,
|
|
6480
|
+
oldFixedMaps,
|
|
6481
|
+
oldVisibleMaps
|
|
6482
|
+
} = customStore;
|
|
6483
|
+
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eachTree(customColumnList, column => {
|
|
6484
|
+
const colid = column.getKey();
|
|
6485
|
+
const visible = !!oldVisibleMaps[colid];
|
|
6486
|
+
const fixed = oldFixedMaps[colid] || '';
|
|
6487
|
+
column.renderVisible = visible;
|
|
6488
|
+
column.visible = visible;
|
|
6489
|
+
column.renderFixed = fixed;
|
|
6490
|
+
column.fixed = fixed;
|
|
6491
|
+
column.renderSortNumber = oldSortMaps[colid] || 0;
|
|
6492
|
+
}, {
|
|
6493
|
+
children: 'children'
|
|
6494
|
+
});
|
|
6158
6495
|
$xeTable.closeCustom();
|
|
6159
6496
|
$xeTable.emitCustomEvent('cancel', evnt);
|
|
6160
6497
|
};
|
|
6161
|
-
const
|
|
6498
|
+
const handleResetCustomEvent = evnt => {
|
|
6162
6499
|
$xeTable.resetColumn(true);
|
|
6163
6500
|
$xeTable.closeCustom();
|
|
6164
6501
|
$xeTable.emitCustomEvent('reset', evnt);
|
|
6502
|
+
handleSaveStore('confirm');
|
|
6165
6503
|
};
|
|
6166
|
-
const
|
|
6504
|
+
const resetCustomEvent = evnt => {
|
|
6167
6505
|
if (external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.modal) {
|
|
6168
6506
|
external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.modal.confirm({
|
|
6169
6507
|
content: panel_getI18n('vxe.custom.cstmConfirmRestore'),
|
|
@@ -6171,11 +6509,11 @@ const {
|
|
|
6171
6509
|
escClosable: true
|
|
6172
6510
|
}).then(type => {
|
|
6173
6511
|
if (type === 'confirm') {
|
|
6174
|
-
|
|
6512
|
+
handleResetCustomEvent(evnt);
|
|
6175
6513
|
}
|
|
6176
6514
|
});
|
|
6177
6515
|
} else {
|
|
6178
|
-
|
|
6516
|
+
handleResetCustomEvent(evnt);
|
|
6179
6517
|
}
|
|
6180
6518
|
};
|
|
6181
6519
|
const handleOptionCheck = column => {
|
|
@@ -6188,17 +6526,17 @@ const {
|
|
|
6188
6526
|
parent
|
|
6189
6527
|
} = matchObj;
|
|
6190
6528
|
if (parent.children && parent.children.length) {
|
|
6191
|
-
parent.
|
|
6192
|
-
parent.halfVisible = !parent.
|
|
6529
|
+
parent.renderVisible = parent.children.every(column => column.renderVisible);
|
|
6530
|
+
parent.halfVisible = !parent.renderVisible && parent.children.some(column => column.renderVisible || column.halfVisible);
|
|
6193
6531
|
handleOptionCheck(parent);
|
|
6194
6532
|
}
|
|
6195
6533
|
}
|
|
6196
6534
|
};
|
|
6197
6535
|
const changeCheckboxOption = column => {
|
|
6198
|
-
const isChecked = !column.
|
|
6536
|
+
const isChecked = !column.renderVisible;
|
|
6199
6537
|
const customOpts = computeCustomOpts.value;
|
|
6200
6538
|
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eachTree([column], item => {
|
|
6201
|
-
item.
|
|
6539
|
+
item.renderVisible = isChecked;
|
|
6202
6540
|
item.halfVisible = false;
|
|
6203
6541
|
});
|
|
6204
6542
|
handleOptionCheck(column);
|
|
@@ -6209,20 +6547,22 @@ const {
|
|
|
6209
6547
|
};
|
|
6210
6548
|
const changeFixedOption = (column, colFixed) => {
|
|
6211
6549
|
const isMaxFixedColumn = computeIsMaxFixedColumn.value;
|
|
6212
|
-
if (column.
|
|
6213
|
-
|
|
6550
|
+
if (column.renderFixed === colFixed) {
|
|
6551
|
+
column.renderFixed = '';
|
|
6552
|
+
// $xeTable.clearColumnFixed(column)
|
|
6214
6553
|
} else {
|
|
6215
|
-
if (!isMaxFixedColumn || column.
|
|
6216
|
-
|
|
6554
|
+
if (!isMaxFixedColumn || column.renderFixed) {
|
|
6555
|
+
column.renderFixed = colFixed;
|
|
6556
|
+
// $xeTable.setColumnFixed(column, colFixed)
|
|
6217
6557
|
}
|
|
6218
6558
|
}
|
|
6219
6559
|
};
|
|
6220
|
-
const changePopupFixedOption =
|
|
6221
|
-
|
|
6222
|
-
|
|
6223
|
-
|
|
6224
|
-
|
|
6225
|
-
}
|
|
6560
|
+
// const changePopupFixedOption = () => {
|
|
6561
|
+
// const isMaxFixedColumn = computeIsMaxFixedColumn.value
|
|
6562
|
+
// if (!isMaxFixedColumn) {
|
|
6563
|
+
// // $xeTable.setColumnFixed(column, column.fixed)
|
|
6564
|
+
// }
|
|
6565
|
+
// }
|
|
6226
6566
|
const allCustomEvent = () => {
|
|
6227
6567
|
const {
|
|
6228
6568
|
customStore
|
|
@@ -6239,7 +6579,7 @@ const {
|
|
|
6239
6579
|
if (!checkMethod || checkMethod({
|
|
6240
6580
|
column
|
|
6241
6581
|
})) {
|
|
6242
|
-
column.
|
|
6582
|
+
column.renderVisible = isAll;
|
|
6243
6583
|
column.halfVisible = false;
|
|
6244
6584
|
}
|
|
6245
6585
|
});
|
|
@@ -6274,16 +6614,6 @@ const {
|
|
|
6274
6614
|
evnt.dataTransfer.setDragImage(img, 0, 0);
|
|
6275
6615
|
}
|
|
6276
6616
|
};
|
|
6277
|
-
const updateColumnSort = () => {
|
|
6278
|
-
const {
|
|
6279
|
-
customColumnList
|
|
6280
|
-
} = reactData;
|
|
6281
|
-
// 更新顺序
|
|
6282
|
-
customColumnList.forEach((column, index) => {
|
|
6283
|
-
const sortIndex = index + 1;
|
|
6284
|
-
column.renderSortNumber = sortIndex;
|
|
6285
|
-
});
|
|
6286
|
-
};
|
|
6287
6617
|
const sortDragendEvent = evnt => {
|
|
6288
6618
|
const {
|
|
6289
6619
|
customColumnList
|
|
@@ -6323,8 +6653,6 @@ const {
|
|
|
6323
6653
|
}
|
|
6324
6654
|
removeClass(trEl, 'active--drag-target');
|
|
6325
6655
|
removeClass(trEl, 'active--drag-origin');
|
|
6326
|
-
// 更新顺序
|
|
6327
|
-
updateColumnSort();
|
|
6328
6656
|
};
|
|
6329
6657
|
const sortDragoverEvent = evnt => {
|
|
6330
6658
|
const trEl = evnt.currentTarget;
|
|
@@ -6372,6 +6700,8 @@ const {
|
|
|
6372
6700
|
const {
|
|
6373
6701
|
checkMethod,
|
|
6374
6702
|
visibleMethod,
|
|
6703
|
+
allowSort,
|
|
6704
|
+
allowFixed,
|
|
6375
6705
|
trigger
|
|
6376
6706
|
} = customOpts;
|
|
6377
6707
|
const isMaxFixedColumn = computeIsMaxFixedColumn.value;
|
|
@@ -6387,7 +6717,7 @@ const {
|
|
|
6387
6717
|
column
|
|
6388
6718
|
}) : true;
|
|
6389
6719
|
if (isVisible) {
|
|
6390
|
-
const isChecked = column.
|
|
6720
|
+
const isChecked = column.renderVisible;
|
|
6391
6721
|
const isIndeterminate = column.halfVisible;
|
|
6392
6722
|
const isColGroup = column.children && column.children.length;
|
|
6393
6723
|
const colTitle = formatText(column.getTitle(), 1);
|
|
@@ -6396,16 +6726,20 @@ const {
|
|
|
6396
6726
|
}) : false;
|
|
6397
6727
|
colVNs.push((0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('li', {
|
|
6398
6728
|
key: column.id,
|
|
6729
|
+
colid: column.id,
|
|
6399
6730
|
class: ['vxe-table-custom--option', `level--${column.level}`, {
|
|
6400
6731
|
'is--group': isColGroup
|
|
6401
|
-
}]
|
|
6732
|
+
}],
|
|
6733
|
+
onDragstart: sortDragstartEvent,
|
|
6734
|
+
onDragend: sortDragendEvent,
|
|
6735
|
+
onDragover: sortDragoverEvent
|
|
6402
6736
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
6403
|
-
title: colTitle,
|
|
6404
6737
|
class: ['vxe-table-custom--checkbox-option', {
|
|
6405
6738
|
'is--checked': isChecked,
|
|
6406
6739
|
'is--indeterminate': isIndeterminate,
|
|
6407
6740
|
'is--disabled': isDisabled
|
|
6408
6741
|
}],
|
|
6742
|
+
title: panel_getI18n('vxe.custom.setting.colVisible'),
|
|
6409
6743
|
onClick: () => {
|
|
6410
6744
|
if (!isDisabled) {
|
|
6411
6745
|
changeCheckboxOption(column);
|
|
@@ -6413,29 +6747,39 @@ const {
|
|
|
6413
6747
|
}
|
|
6414
6748
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
6415
6749
|
class: ['vxe-checkbox--icon', isIndeterminate ? panel_getIcon().TABLE_CHECKBOX_INDETERMINATE : isChecked ? panel_getIcon().TABLE_CHECKBOX_CHECKED : panel_getIcon().TABLE_CHECKBOX_UNCHECKED]
|
|
6416
|
-
}), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('
|
|
6417
|
-
class: 'vxe-
|
|
6418
|
-
},
|
|
6750
|
+
})]), allowSort && column.level === 1 ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
6751
|
+
class: 'vxe-table-custom--sort-option'
|
|
6752
|
+
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
6753
|
+
class: 'vxe-table-custom--sort-btn',
|
|
6754
|
+
title: panel_getI18n('vxe.custom.setting.sortHelpTip'),
|
|
6755
|
+
onMousedown: sortMousedownEvent,
|
|
6756
|
+
onMouseup: sortMouseupEvent
|
|
6757
|
+
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
6758
|
+
class: panel_getIcon().TABLE_CUSTOM_SORT
|
|
6759
|
+
})])]) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
6760
|
+
class: 'vxe-table-custom--checkbox-label',
|
|
6761
|
+
title: colTitle
|
|
6762
|
+
}, colTitle), !parent && allowFixed ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
6419
6763
|
class: 'vxe-table-custom--fixed-option'
|
|
6420
6764
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
6421
|
-
class: ['vxe-table-custom--fixed-left-option', column.
|
|
6422
|
-
'is--checked': column.
|
|
6423
|
-
'is--disabled': isMaxFixedColumn && !column.
|
|
6765
|
+
class: ['vxe-table-custom--fixed-left-option', column.renderFixed === 'left' ? panel_getIcon().TOOLBAR_TOOLS_FIXED_LEFT_ACTIVE : panel_getIcon().TOOLBAR_TOOLS_FIXED_LEFT, {
|
|
6766
|
+
'is--checked': column.renderFixed === 'left',
|
|
6767
|
+
'is--disabled': isMaxFixedColumn && !column.renderFixed
|
|
6424
6768
|
}],
|
|
6425
|
-
title: panel_getI18n(column.
|
|
6769
|
+
title: panel_getI18n(column.renderFixed === 'left' ? 'vxe.toolbar.cancelFixed' : 'vxe.toolbar.fixedLeft'),
|
|
6426
6770
|
onClick: () => {
|
|
6427
6771
|
changeFixedOption(column, 'left');
|
|
6428
6772
|
}
|
|
6429
6773
|
}), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
6430
|
-
class: ['vxe-table-custom--fixed-right-option', column.
|
|
6431
|
-
'is--checked': column.
|
|
6432
|
-
'is--disabled': isMaxFixedColumn && !column.
|
|
6774
|
+
class: ['vxe-table-custom--fixed-right-option', column.renderFixed === 'right' ? panel_getIcon().TOOLBAR_TOOLS_FIXED_RIGHT_ACTIVE : panel_getIcon().TOOLBAR_TOOLS_FIXED_RIGHT, {
|
|
6775
|
+
'is--checked': column.renderFixed === 'right',
|
|
6776
|
+
'is--disabled': isMaxFixedColumn && !column.renderFixed
|
|
6433
6777
|
}],
|
|
6434
|
-
title: panel_getI18n(column.
|
|
6778
|
+
title: panel_getI18n(column.renderFixed === 'right' ? 'vxe.toolbar.cancelFixed' : 'vxe.toolbar.fixedRight'),
|
|
6435
6779
|
onClick: () => {
|
|
6436
6780
|
changeFixedOption(column, 'right');
|
|
6437
6781
|
}
|
|
6438
|
-
})]) :
|
|
6782
|
+
})]) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)()]));
|
|
6439
6783
|
}
|
|
6440
6784
|
});
|
|
6441
6785
|
const isAllChecked = customStore.isAll;
|
|
@@ -6446,7 +6790,7 @@ const {
|
|
|
6446
6790
|
class: ['vxe-table-custom-wrapper', {
|
|
6447
6791
|
'is--active': customStore.visible
|
|
6448
6792
|
}]
|
|
6449
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('ul', {
|
|
6793
|
+
}, customStore.visible ? [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('ul', {
|
|
6450
6794
|
class: 'vxe-table-custom--header'
|
|
6451
6795
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('li', {
|
|
6452
6796
|
class: 'vxe-table-custom--option'
|
|
@@ -6461,21 +6805,34 @@ const {
|
|
|
6461
6805
|
class: ['vxe-checkbox--icon', isAllIndeterminate ? panel_getIcon().TABLE_CHECKBOX_INDETERMINATE : isAllChecked ? panel_getIcon().TABLE_CHECKBOX_CHECKED : panel_getIcon().TABLE_CHECKBOX_UNCHECKED]
|
|
6462
6806
|
}), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
6463
6807
|
class: 'vxe-checkbox--label'
|
|
6464
|
-
}, panel_getI18n('vxe.toolbar.customAll'))])])]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('
|
|
6808
|
+
}, panel_getI18n('vxe.toolbar.customAll'))])])]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
6809
|
+
ref: bodyElemRef,
|
|
6810
|
+
class: 'vxe-table-custom--list-wrapper'
|
|
6811
|
+
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)(external_commonjs_vue_commonjs2_vue_root_Vue_.TransitionGroup, {
|
|
6465
6812
|
class: 'vxe-table-custom--body',
|
|
6813
|
+
name: 'vxe-table-custom--list',
|
|
6814
|
+
tag: 'ul',
|
|
6466
6815
|
style: maxHeight ? {
|
|
6467
6816
|
maxHeight: `${maxHeight}px`
|
|
6468
6817
|
} : {},
|
|
6469
6818
|
...customWrapperOns
|
|
6470
|
-
},
|
|
6819
|
+
}, {
|
|
6820
|
+
default: () => colVNs
|
|
6821
|
+
}), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
6822
|
+
ref: dragHintElemRef,
|
|
6823
|
+
class: 'vxe-table-custom-popup--drag-hint'
|
|
6824
|
+
}, panel_getI18n('vxe.custom.cstmDragTarget', [dragColumn.value ? dragColumn.value.getTitle() : '']))]), customOpts.showFooter ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
6471
6825
|
class: 'vxe-table-custom--footer'
|
|
6472
6826
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('button', {
|
|
6473
6827
|
class: 'btn--reset',
|
|
6474
6828
|
onClick: resetCustomEvent
|
|
6475
|
-
}, customOpts.resetButtonText || panel_getI18n('vxe.
|
|
6829
|
+
}, customOpts.resetButtonText || panel_getI18n('vxe.table.customRestore')), customOpts.immediate ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)() : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('button', {
|
|
6830
|
+
class: 'btn--cancel',
|
|
6831
|
+
onClick: cancelCustomEvent
|
|
6832
|
+
}, customOpts.resetButtonText || panel_getI18n('vxe.table.customCancel')), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('button', {
|
|
6476
6833
|
class: 'btn--confirm',
|
|
6477
6834
|
onClick: confirmCustomEvent
|
|
6478
|
-
}, customOpts.confirmButtonText || panel_getI18n('vxe.
|
|
6835
|
+
}, customOpts.confirmButtonText || panel_getI18n('vxe.table.customConfirm'))]) : null] : []);
|
|
6479
6836
|
};
|
|
6480
6837
|
const renderPopupPanel = () => {
|
|
6481
6838
|
const {
|
|
@@ -6486,6 +6843,8 @@ const {
|
|
|
6486
6843
|
} = reactData;
|
|
6487
6844
|
const customOpts = computeCustomOpts.value;
|
|
6488
6845
|
const {
|
|
6846
|
+
allowSort,
|
|
6847
|
+
allowFixed,
|
|
6489
6848
|
checkMethod,
|
|
6490
6849
|
visibleMethod
|
|
6491
6850
|
} = customOpts;
|
|
@@ -6497,7 +6856,7 @@ const {
|
|
|
6497
6856
|
column
|
|
6498
6857
|
}) : true;
|
|
6499
6858
|
if (isVisible) {
|
|
6500
|
-
const isChecked = column.
|
|
6859
|
+
const isChecked = column.renderVisible;
|
|
6501
6860
|
const isIndeterminate = column.halfVisible;
|
|
6502
6861
|
const colTitle = formatText(column.getTitle(), 1);
|
|
6503
6862
|
const isColGroup = column.children && column.children.length;
|
|
@@ -6514,19 +6873,6 @@ const {
|
|
|
6514
6873
|
onDragend: sortDragendEvent,
|
|
6515
6874
|
onDragover: sortDragoverEvent
|
|
6516
6875
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('td', {
|
|
6517
|
-
class: 'vxe-table-custom-popup--column-item col--sort'
|
|
6518
|
-
}, [column.level === 1 ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
6519
|
-
class: 'vxe-table-custom-popup--column-sort-btn',
|
|
6520
|
-
onMousedown: sortMousedownEvent,
|
|
6521
|
-
onMouseup: sortMouseupEvent
|
|
6522
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
6523
|
-
class: 'vxe-icon-sort'
|
|
6524
|
-
})]) : null]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('td', {
|
|
6525
|
-
class: 'vxe-table-custom-popup--column-item col--name'
|
|
6526
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
6527
|
-
class: 'vxe-table-custom-popup--name',
|
|
6528
|
-
title: colTitle
|
|
6529
|
-
}, colTitle)]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('td', {
|
|
6530
6876
|
class: 'vxe-table-custom-popup--column-item col--visible'
|
|
6531
6877
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
6532
6878
|
class: ['vxe-table-custom--checkbox-option', {
|
|
@@ -6534,6 +6880,7 @@ const {
|
|
|
6534
6880
|
'is--indeterminate': isIndeterminate,
|
|
6535
6881
|
'is--disabled': isDisabled
|
|
6536
6882
|
}],
|
|
6883
|
+
title: panel_getI18n('vxe.custom.setting.colVisible'),
|
|
6537
6884
|
onClick: () => {
|
|
6538
6885
|
if (!isDisabled) {
|
|
6539
6886
|
changeCheckboxOption(column);
|
|
@@ -6541,10 +6888,24 @@ const {
|
|
|
6541
6888
|
}
|
|
6542
6889
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
6543
6890
|
class: ['vxe-checkbox--icon', isIndeterminate ? panel_getIcon().TABLE_CHECKBOX_INDETERMINATE : isChecked ? panel_getIcon().TABLE_CHECKBOX_CHECKED : panel_getIcon().TABLE_CHECKBOX_UNCHECKED]
|
|
6544
|
-
})])]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('td', {
|
|
6891
|
+
})])]), allowSort ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('td', {
|
|
6892
|
+
class: 'vxe-table-custom-popup--column-item col--sort'
|
|
6893
|
+
}, [column.level === 1 ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
6894
|
+
class: 'vxe-table-custom-popup--column-sort-btn',
|
|
6895
|
+
title: panel_getI18n('vxe.custom.setting.sortHelpTip'),
|
|
6896
|
+
onMousedown: sortMousedownEvent,
|
|
6897
|
+
onMouseup: sortMouseupEvent
|
|
6898
|
+
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('i', {
|
|
6899
|
+
class: panel_getIcon().TABLE_CUSTOM_SORT
|
|
6900
|
+
})]) : null]) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('td', {
|
|
6901
|
+
class: 'vxe-table-custom-popup--column-item col--name'
|
|
6902
|
+
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
6903
|
+
class: 'vxe-table-custom-popup--name',
|
|
6904
|
+
title: colTitle
|
|
6905
|
+
}, colTitle)]), allowFixed ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('td', {
|
|
6545
6906
|
class: 'vxe-table-custom-popup--column-item col--fixed'
|
|
6546
|
-
}, [!parent
|
|
6547
|
-
modelValue: column.
|
|
6907
|
+
}, [!parent ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.resolveComponent)('vxe-radio-group'), {
|
|
6908
|
+
modelValue: column.renderFixed || '',
|
|
6548
6909
|
type: 'button',
|
|
6549
6910
|
size: 'mini',
|
|
6550
6911
|
options: [{
|
|
@@ -6560,14 +6921,16 @@ const {
|
|
|
6560
6921
|
disabled: isMaxFixedColumn
|
|
6561
6922
|
}],
|
|
6562
6923
|
'onUpdate:modelValue'(value) {
|
|
6563
|
-
column.
|
|
6564
|
-
},
|
|
6565
|
-
onChange() {
|
|
6566
|
-
changePopupFixedOption(column);
|
|
6924
|
+
column.renderFixed = value;
|
|
6567
6925
|
}
|
|
6568
|
-
|
|
6926
|
+
// onChange () {
|
|
6927
|
+
// changePopupFixedOption(column)
|
|
6928
|
+
// }
|
|
6929
|
+
}) : null]) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)()]));
|
|
6569
6930
|
}
|
|
6570
6931
|
});
|
|
6932
|
+
const isAllChecked = customStore.isAll;
|
|
6933
|
+
const isAllIndeterminate = customStore.isIndeterminate;
|
|
6571
6934
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.resolveComponent)('vxe-modal'), {
|
|
6572
6935
|
key: 'popup',
|
|
6573
6936
|
className: 'vxe-table-custom-popup-wrapper vxe-table--ignore-clear',
|
|
@@ -6597,15 +6960,30 @@ const {
|
|
|
6597
6960
|
style: {
|
|
6598
6961
|
width: '80px'
|
|
6599
6962
|
}
|
|
6600
|
-
}),
|
|
6963
|
+
}), allowSort ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('col', {
|
|
6601
6964
|
style: {
|
|
6602
6965
|
width: '80px'
|
|
6603
6966
|
}
|
|
6604
|
-
}), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('col', {
|
|
6967
|
+
}) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('col', {
|
|
6968
|
+
style: {
|
|
6969
|
+
minWidth: '120px'
|
|
6970
|
+
}
|
|
6971
|
+
}), allowFixed ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('col', {
|
|
6605
6972
|
style: {
|
|
6606
6973
|
width: '200px'
|
|
6607
6974
|
}
|
|
6608
|
-
})]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('thead', {}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('tr', {}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('th', {}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('
|
|
6975
|
+
}) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)()]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('thead', {}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('tr', {}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('th', {}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
6976
|
+
class: ['vxe-table-custom--checkbox-option', {
|
|
6977
|
+
'is--checked': isAllChecked,
|
|
6978
|
+
'is--indeterminate': isAllIndeterminate
|
|
6979
|
+
}],
|
|
6980
|
+
title: panel_getI18n('vxe.table.allTitle'),
|
|
6981
|
+
onClick: allCustomEvent
|
|
6982
|
+
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
6983
|
+
class: ['vxe-checkbox--icon', isAllIndeterminate ? panel_getIcon().TABLE_CHECKBOX_INDETERMINATE : isAllChecked ? panel_getIcon().TABLE_CHECKBOX_CHECKED : panel_getIcon().TABLE_CHECKBOX_UNCHECKED]
|
|
6984
|
+
}), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
6985
|
+
class: 'vxe-checkbox--label'
|
|
6986
|
+
}, panel_getI18n('vxe.toolbar.customAll'))])]), allowSort ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('th', {}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('span', {
|
|
6609
6987
|
class: 'vxe-table-custom-popup--table-sort-help-title'
|
|
6610
6988
|
}, panel_getI18n('vxe.custom.setting.colSort')), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.resolveComponent)('vxe-tooltip'), {
|
|
6611
6989
|
enterable: true,
|
|
@@ -6616,7 +6994,7 @@ const {
|
|
|
6616
6994
|
class: 'vxe-table-custom-popup--table-sort-help-icon vxe-icon-question-circle-fill'
|
|
6617
6995
|
});
|
|
6618
6996
|
}
|
|
6619
|
-
})])
|
|
6997
|
+
})]) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('th', {}, panel_getI18n('vxe.custom.setting.colTitle')), allowFixed ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('th', {}, panel_getI18n('vxe.custom.setting.colFixed', [columnOpts.maxFixedSize || 0])) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)()])]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)(external_commonjs_vue_commonjs2_vue_root_Vue_.TransitionGroup, {
|
|
6620
6998
|
class: 'vxe-table-custom--body',
|
|
6621
6999
|
tag: 'tbody',
|
|
6622
7000
|
name: 'vxe-table-custom--list'
|
|
@@ -6632,7 +7010,7 @@ const {
|
|
|
6632
7010
|
class: 'vxe-table-custom-popup--footer'
|
|
6633
7011
|
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.resolveComponent)('vxe-button'), {
|
|
6634
7012
|
content: customOpts.resetButtonText || panel_getI18n('vxe.custom.cstmRestore'),
|
|
6635
|
-
onClick:
|
|
7013
|
+
onClick: resetCustomEvent
|
|
6636
7014
|
}), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.resolveComponent)('vxe-button'), {
|
|
6637
7015
|
content: customOpts.resetButtonText || panel_getI18n('vxe.custom.cstmCancel'),
|
|
6638
7016
|
onClick: cancelCustomEvent
|
|
@@ -7568,10 +7946,10 @@ const {
|
|
|
7568
7946
|
renderer: table_renderer,
|
|
7569
7947
|
formats: table_formats,
|
|
7570
7948
|
createEvent,
|
|
7571
|
-
globalResize,
|
|
7572
|
-
interceptor,
|
|
7573
|
-
hooks,
|
|
7574
|
-
globalEvents,
|
|
7949
|
+
globalResize: table_globalResize,
|
|
7950
|
+
interceptor: table_interceptor,
|
|
7951
|
+
hooks: table_hooks,
|
|
7952
|
+
globalEvents: table_globalEvents,
|
|
7575
7953
|
GLOBAL_EVENT_KEYS,
|
|
7576
7954
|
log: table_log,
|
|
7577
7955
|
useFns
|
|
@@ -7680,7 +8058,10 @@ const sortStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_SORT';
|
|
|
7680
8058
|
activeBtn: false,
|
|
7681
8059
|
activeWrapper: false,
|
|
7682
8060
|
visible: false,
|
|
7683
|
-
maxHeight: 0
|
|
8061
|
+
maxHeight: 0,
|
|
8062
|
+
oldSortMaps: {},
|
|
8063
|
+
oldFixedMaps: {},
|
|
8064
|
+
oldVisibleMaps: {}
|
|
7684
8065
|
},
|
|
7685
8066
|
customColumnList: [],
|
|
7686
8067
|
// 当前选中的筛选列
|
|
@@ -8454,7 +8835,8 @@ const sortStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_SORT';
|
|
|
8454
8835
|
} = props;
|
|
8455
8836
|
const customOpts = computeCustomOpts.value;
|
|
8456
8837
|
const {
|
|
8457
|
-
storage
|
|
8838
|
+
storage,
|
|
8839
|
+
restoreStore
|
|
8458
8840
|
} = customOpts;
|
|
8459
8841
|
const isAllCustom = storage === true;
|
|
8460
8842
|
const storageOpts = isAllCustom ? {} : Object.assign({}, storage || {});
|
|
@@ -8462,6 +8844,11 @@ const sortStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_SORT';
|
|
|
8462
8844
|
const isCustomVisible = isAllCustom || storageOpts.visible;
|
|
8463
8845
|
const isCustomFixed = isAllCustom || storageOpts.fixed;
|
|
8464
8846
|
const isCustomSort = isAllCustom || storageOpts.sort;
|
|
8847
|
+
if (storage && id && restoreStore) {
|
|
8848
|
+
restoreStore({
|
|
8849
|
+
id
|
|
8850
|
+
});
|
|
8851
|
+
}
|
|
8465
8852
|
if (customConfig && (isCustomResizable || isCustomVisible || isCustomFixed || isCustomSort)) {
|
|
8466
8853
|
const customMap = {};
|
|
8467
8854
|
if (!id) {
|
|
@@ -12965,7 +13352,7 @@ const sortStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_SORT';
|
|
|
12965
13352
|
const {
|
|
12966
13353
|
actived
|
|
12967
13354
|
} = editStore;
|
|
12968
|
-
const isEsc =
|
|
13355
|
+
const isEsc = table_globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.ESCAPE);
|
|
12969
13356
|
if (isEsc) {
|
|
12970
13357
|
tablePrivateMethods.preventEvent(evnt, 'event.keydown', null, () => {
|
|
12971
13358
|
tableMethods.dispatchEvent('keydown-start', {}, evnt);
|
|
@@ -13028,18 +13415,18 @@ const sortStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_SORT';
|
|
|
13028
13415
|
} = editStore;
|
|
13029
13416
|
const childrenField = treeOpts.children || treeOpts.childrenField;
|
|
13030
13417
|
const keyCode = evnt.keyCode;
|
|
13031
|
-
const isEsc =
|
|
13032
|
-
const isBack =
|
|
13033
|
-
const isTab =
|
|
13034
|
-
const isEnter =
|
|
13035
|
-
const isSpacebar =
|
|
13036
|
-
const isLeftArrow =
|
|
13037
|
-
const isUpArrow =
|
|
13038
|
-
const isRightArrow =
|
|
13039
|
-
const isDwArrow =
|
|
13040
|
-
const isDel =
|
|
13041
|
-
const isF2 =
|
|
13042
|
-
const isContextMenu =
|
|
13418
|
+
const isEsc = table_globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.ESCAPE);
|
|
13419
|
+
const isBack = table_globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.BACKSPACE);
|
|
13420
|
+
const isTab = table_globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.TAB);
|
|
13421
|
+
const isEnter = table_globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.ENTER);
|
|
13422
|
+
const isSpacebar = table_globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.SPACEBAR);
|
|
13423
|
+
const isLeftArrow = table_globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.ARROW_LEFT);
|
|
13424
|
+
const isUpArrow = table_globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.ARROW_UP);
|
|
13425
|
+
const isRightArrow = table_globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.ARROW_RIGHT);
|
|
13426
|
+
const isDwArrow = table_globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.ARROW_DOWN);
|
|
13427
|
+
const isDel = table_globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.DELETE);
|
|
13428
|
+
const isF2 = table_globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.F2);
|
|
13429
|
+
const isContextMenu = table_globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.CONTEXT_MENU);
|
|
13043
13430
|
const hasMetaKey = evnt.metaKey;
|
|
13044
13431
|
const hasCtrlKey = evnt.ctrlKey;
|
|
13045
13432
|
const hasShiftKey = evnt.shiftKey;
|
|
@@ -13853,10 +14240,10 @@ const sortStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_SORT';
|
|
|
13853
14240
|
reactData.reColumnFlag++;
|
|
13854
14241
|
},
|
|
13855
14242
|
preventEvent(evnt, type, args, next, end) {
|
|
13856
|
-
let evntList =
|
|
14243
|
+
let evntList = table_interceptor.get(type);
|
|
13857
14244
|
// 兼容老版本
|
|
13858
14245
|
if (!evntList.length && type === 'event.clearEdit') {
|
|
13859
|
-
evntList =
|
|
14246
|
+
evntList = table_interceptor.get('event.clearActived');
|
|
13860
14247
|
if (true) {
|
|
13861
14248
|
if (evntList.length) {
|
|
13862
14249
|
table_log.warn('vxe.error.delEvent', ['event.clearActived', 'event.clearEdit']);
|
|
@@ -15189,7 +15576,7 @@ const sortStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_SORT';
|
|
|
15189
15576
|
}
|
|
15190
15577
|
});
|
|
15191
15578
|
});
|
|
15192
|
-
|
|
15579
|
+
table_hooks.forEach(options => {
|
|
15193
15580
|
const {
|
|
15194
15581
|
setupTable
|
|
15195
15582
|
} = options;
|
|
@@ -15381,7 +15768,7 @@ const sortStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_SORT';
|
|
|
15381
15768
|
leading: true,
|
|
15382
15769
|
trailing: true
|
|
15383
15770
|
}) : null;
|
|
15384
|
-
resizeObserver =
|
|
15771
|
+
resizeObserver = table_globalResize.create(handleOptimizeResize ? () => {
|
|
15385
15772
|
if (props.autoResize) {
|
|
15386
15773
|
requestAnimationFrame(handleOptimizeResize);
|
|
15387
15774
|
}
|
|
@@ -15398,16 +15785,16 @@ const sortStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_SORT';
|
|
|
15398
15785
|
}
|
|
15399
15786
|
}
|
|
15400
15787
|
});
|
|
15401
|
-
|
|
15402
|
-
|
|
15403
|
-
|
|
15404
|
-
|
|
15405
|
-
|
|
15406
|
-
|
|
15407
|
-
|
|
15408
|
-
|
|
15788
|
+
table_globalEvents.on($xeTable, 'paste', handleGlobalPasteEvent);
|
|
15789
|
+
table_globalEvents.on($xeTable, 'copy', handleGlobalCopyEvent);
|
|
15790
|
+
table_globalEvents.on($xeTable, 'cut', handleGlobalCutEvent);
|
|
15791
|
+
table_globalEvents.on($xeTable, 'mousedown', handleGlobalMousedownEvent);
|
|
15792
|
+
table_globalEvents.on($xeTable, 'blur', handleGlobalBlurEvent);
|
|
15793
|
+
table_globalEvents.on($xeTable, 'mousewheel', handleGlobalMousewheelEvent);
|
|
15794
|
+
table_globalEvents.on($xeTable, 'keydown', handleGlobalKeydownEvent);
|
|
15795
|
+
table_globalEvents.on($xeTable, 'resize', handleGlobalResizeEvent);
|
|
15409
15796
|
if ($xeTable.handleGlobalContextmenuEvent) {
|
|
15410
|
-
|
|
15797
|
+
table_globalEvents.on($xeTable, 'contextmenu', $xeTable.handleGlobalContextmenuEvent);
|
|
15411
15798
|
}
|
|
15412
15799
|
tablePrivateMethods.preventEvent(null, 'mounted', {
|
|
15413
15800
|
$table: $xeTable
|
|
@@ -15426,15 +15813,15 @@ const sortStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_SORT';
|
|
|
15426
15813
|
});
|
|
15427
15814
|
});
|
|
15428
15815
|
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.onUnmounted)(() => {
|
|
15429
|
-
|
|
15430
|
-
|
|
15431
|
-
|
|
15432
|
-
|
|
15433
|
-
|
|
15434
|
-
|
|
15435
|
-
|
|
15436
|
-
|
|
15437
|
-
|
|
15816
|
+
table_globalEvents.off($xeTable, 'paste');
|
|
15817
|
+
table_globalEvents.off($xeTable, 'copy');
|
|
15818
|
+
table_globalEvents.off($xeTable, 'cut');
|
|
15819
|
+
table_globalEvents.off($xeTable, 'mousedown');
|
|
15820
|
+
table_globalEvents.off($xeTable, 'blur');
|
|
15821
|
+
table_globalEvents.off($xeTable, 'mousewheel');
|
|
15822
|
+
table_globalEvents.off($xeTable, 'keydown');
|
|
15823
|
+
table_globalEvents.off($xeTable, 'resize');
|
|
15824
|
+
table_globalEvents.off($xeTable, 'contextmenu');
|
|
15438
15825
|
tablePrivateMethods.preventEvent(null, 'unmounted', {
|
|
15439
15826
|
$table: $xeTable
|
|
15440
15827
|
});
|
|
@@ -16046,7 +16433,7 @@ hook_hooks.add('tableFilterModule', {
|
|
|
16046
16433
|
|
|
16047
16434
|
|
|
16048
16435
|
const {
|
|
16049
|
-
menus,
|
|
16436
|
+
menus: hook_menus,
|
|
16050
16437
|
hooks: menu_hook_hooks,
|
|
16051
16438
|
globalEvents: hook_globalEvents,
|
|
16052
16439
|
GLOBAL_EVENT_KEYS: hook_GLOBAL_EVENT_KEYS
|
|
@@ -16386,7 +16773,7 @@ menu_hook_hooks.add('tableMenuModule', {
|
|
|
16386
16773
|
ctxMenuLinkEvent(evnt, menu) {
|
|
16387
16774
|
// 如果一级菜单有配置 code 则允许点击,否则不能点击
|
|
16388
16775
|
if (!menu.disabled && (menu.code || !menu.children || !menu.children.length)) {
|
|
16389
|
-
const gMenuOpts =
|
|
16776
|
+
const gMenuOpts = hook_menus.get(menu.code);
|
|
16390
16777
|
const params = Object.assign({}, internalData._currMenuParams, {
|
|
16391
16778
|
menu,
|
|
16392
16779
|
$table: $xeTable,
|
|
@@ -19510,7 +19897,7 @@ keyboard_hook_hooks.add('tableKeyboardModule', {
|
|
|
19510
19897
|
|
|
19511
19898
|
const {
|
|
19512
19899
|
getConfig: validator_hook_getConfig,
|
|
19513
|
-
validators,
|
|
19900
|
+
validators: hook_validators,
|
|
19514
19901
|
hooks: validator_hook_hooks,
|
|
19515
19902
|
log: validator_hook_log
|
|
19516
19903
|
} = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI;
|
|
@@ -19892,7 +20279,7 @@ validator_hook_hooks.add('tableValidatorModule', {
|
|
|
19892
20279
|
};
|
|
19893
20280
|
let customValid;
|
|
19894
20281
|
if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isString(validator)) {
|
|
19895
|
-
const gvItem =
|
|
20282
|
+
const gvItem = hook_validators.get(validator);
|
|
19896
20283
|
if (gvItem) {
|
|
19897
20284
|
if (gvItem.cellValidatorMethod) {
|
|
19898
20285
|
customValid = gvItem.cellValidatorMethod(validParams);
|
|
@@ -20088,6 +20475,7 @@ validator_hook_hooks.add('tableValidatorModule', {
|
|
|
20088
20475
|
;// CONCATENATED MODULE: ./packages/table/module/custom/hook.ts
|
|
20089
20476
|
|
|
20090
20477
|
|
|
20478
|
+
|
|
20091
20479
|
const tableCustomMethodKeys = ['openCustom', 'closeCustom'];
|
|
20092
20480
|
external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.hooks.add('tableCustomModule', {
|
|
20093
20481
|
setupTable($xeTable) {
|
|
@@ -20129,9 +20517,28 @@ external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.
|
|
|
20129
20517
|
initStore,
|
|
20130
20518
|
customStore
|
|
20131
20519
|
} = reactData;
|
|
20520
|
+
const {
|
|
20521
|
+
collectColumn
|
|
20522
|
+
} = internalData;
|
|
20523
|
+
const sortMaps = {};
|
|
20524
|
+
const fixedMaps = {};
|
|
20525
|
+
const visibleMaps = {};
|
|
20526
|
+
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eachTree(collectColumn, column => {
|
|
20527
|
+
const colid = column.getKey();
|
|
20528
|
+
column.renderFixed = column.fixed;
|
|
20529
|
+
column.renderVisible = column.visible;
|
|
20530
|
+
sortMaps[colid] = column.renderSortNumber;
|
|
20531
|
+
fixedMaps[colid] = column.fixed;
|
|
20532
|
+
visibleMaps[colid] = column.visible;
|
|
20533
|
+
}, {
|
|
20534
|
+
children: 'children'
|
|
20535
|
+
});
|
|
20536
|
+
customStore.oldSortMaps = sortMaps;
|
|
20537
|
+
customStore.oldFixedMaps = fixedMaps;
|
|
20538
|
+
customStore.oldVisibleMaps = visibleMaps;
|
|
20539
|
+
reactData.customColumnList = collectColumn.slice(0);
|
|
20132
20540
|
customStore.visible = true;
|
|
20133
20541
|
initStore.custom = true;
|
|
20134
|
-
reactData.customColumnList = internalData.collectColumn.slice(0);
|
|
20135
20542
|
checkCustomStatus();
|
|
20136
20543
|
calcMaxHeight();
|
|
20137
20544
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)().then(() => calcMaxHeight());
|
|
@@ -20204,7 +20611,7 @@ external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.
|
|
|
20204
20611
|
$xeTable.emitCustomEvent('open', evnt);
|
|
20205
20612
|
}
|
|
20206
20613
|
},
|
|
20207
|
-
|
|
20614
|
+
customCloseEvent(evnt) {
|
|
20208
20615
|
const {
|
|
20209
20616
|
customStore
|
|
20210
20617
|
} = reactData;
|
|
@@ -21030,7 +21437,7 @@ const {
|
|
|
21030
21437
|
getIcon: toolbar_getIcon,
|
|
21031
21438
|
getI18n: toolbar_getI18n,
|
|
21032
21439
|
renderer: toolbar_renderer,
|
|
21033
|
-
commands,
|
|
21440
|
+
commands: toolbar_commands,
|
|
21034
21441
|
log: toolbar_log,
|
|
21035
21442
|
createEvent: toolbar_createEvent,
|
|
21036
21443
|
useFns: toolbar_useFns
|
|
@@ -21160,7 +21567,7 @@ const {
|
|
|
21160
21567
|
customStore.activeBtn = false;
|
|
21161
21568
|
setTimeout(() => {
|
|
21162
21569
|
if (!customStore.activeBtn && !customStore.activeWrapper) {
|
|
21163
|
-
$xeTable.
|
|
21570
|
+
$xeTable.customCloseEvent($event);
|
|
21164
21571
|
}
|
|
21165
21572
|
}, 350);
|
|
21166
21573
|
};
|
|
@@ -21203,7 +21610,7 @@ const {
|
|
|
21203
21610
|
if ($xeGrid) {
|
|
21204
21611
|
$xeGrid.triggerToolbarBtnEvent(item, evnt);
|
|
21205
21612
|
} else {
|
|
21206
|
-
const gCommandOpts =
|
|
21613
|
+
const gCommandOpts = toolbar_commands.get(code);
|
|
21207
21614
|
const params = {
|
|
21208
21615
|
code,
|
|
21209
21616
|
button: item,
|
|
@@ -21232,7 +21639,7 @@ const {
|
|
|
21232
21639
|
if ($xeGrid) {
|
|
21233
21640
|
$xeGrid.triggerToolbarTolEvent(item, evnt);
|
|
21234
21641
|
} else {
|
|
21235
|
-
const gCommandOpts =
|
|
21642
|
+
const gCommandOpts = toolbar_commands.get(code);
|
|
21236
21643
|
const params = {
|
|
21237
21644
|
code,
|
|
21238
21645
|
tool: item,
|
|
@@ -22817,464 +23224,184 @@ const gridComponentEmits = [...emits, 'page-change', 'form-submit', 'form-submit
|
|
|
22817
23224
|
return gridMethods.loadColumn(columns);
|
|
22818
23225
|
};
|
|
22819
23226
|
}
|
|
22820
|
-
const gridPrivateMethods = {
|
|
22821
|
-
extendTableMethods,
|
|
22822
|
-
callSlot(slotFunc, params) {
|
|
22823
|
-
if (slotFunc) {
|
|
22824
|
-
if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isString(slotFunc)) {
|
|
22825
|
-
slotFunc = slots[slotFunc] || null;
|
|
22826
|
-
}
|
|
22827
|
-
if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(slotFunc)) {
|
|
22828
|
-
return getSlotVNs(slotFunc(params));
|
|
22829
|
-
}
|
|
22830
|
-
}
|
|
22831
|
-
return [];
|
|
22832
|
-
},
|
|
22833
|
-
/**
|
|
22834
|
-
* 获取需要排除的高度
|
|
22835
|
-
*/
|
|
22836
|
-
getExcludeHeight() {
|
|
22837
|
-
const {
|
|
22838
|
-
height
|
|
22839
|
-
} = props;
|
|
22840
|
-
const {
|
|
22841
|
-
isZMax
|
|
22842
|
-
} = reactData;
|
|
22843
|
-
const el = refElem.value;
|
|
22844
|
-
const formWrapper = refFormWrapper.value;
|
|
22845
|
-
const toolbarWrapper = refToolbarWrapper.value;
|
|
22846
|
-
const topWrapper = refTopWrapper.value;
|
|
22847
|
-
const bottomWrapper = refBottomWrapper.value;
|
|
22848
|
-
const pagerWrapper = refPagerWrapper.value;
|
|
22849
|
-
const parentPaddingSize = isZMax || height !== 'auto' ? 0 : getPaddingTopBottomSize(el.parentNode);
|
|
22850
|
-
return parentPaddingSize + getPaddingTopBottomSize(el) + getOffsetHeight(formWrapper) + getOffsetHeight(toolbarWrapper) + getOffsetHeight(topWrapper) + getOffsetHeight(bottomWrapper) + getOffsetHeight(pagerWrapper);
|
|
22851
|
-
},
|
|
22852
|
-
getParentHeight() {
|
|
22853
|
-
const el = refElem.value;
|
|
22854
|
-
if (el) {
|
|
22855
|
-
return (reactData.isZMax ? getDomNode().visibleHeight : external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toNumber(getComputedStyle(el.parentNode).height)) - gridPrivateMethods.getExcludeHeight();
|
|
22856
|
-
}
|
|
22857
|
-
return 0;
|
|
22858
|
-
},
|
|
22859
|
-
triggerToolbarCommitEvent(params, evnt) {
|
|
22860
|
-
const {
|
|
22861
|
-
code
|
|
22862
|
-
} = params;
|
|
22863
|
-
return gridMethods.commitProxy(params, evnt).then(rest => {
|
|
22864
|
-
if (code && rest && rest.status && ['query', 'reload', 'delete', 'save'].includes(code)) {
|
|
22865
|
-
gridMethods.dispatchEvent(code === 'delete' || code === 'save' ? `proxy-${code}` : 'proxy-query', {
|
|
22866
|
-
...rest,
|
|
22867
|
-
isReload: code === 'reload'
|
|
22868
|
-
}, evnt);
|
|
22869
|
-
}
|
|
22870
|
-
});
|
|
22871
|
-
},
|
|
22872
|
-
triggerToolbarBtnEvent(button, evnt) {
|
|
22873
|
-
gridPrivateMethods.triggerToolbarCommitEvent(button, evnt);
|
|
22874
|
-
gridMethods.dispatchEvent('toolbar-button-click', {
|
|
22875
|
-
code: button.code,
|
|
22876
|
-
button
|
|
22877
|
-
}, evnt);
|
|
22878
|
-
},
|
|
22879
|
-
triggerToolbarTolEvent(tool, evnt) {
|
|
22880
|
-
gridPrivateMethods.triggerToolbarCommitEvent(tool, evnt);
|
|
22881
|
-
gridMethods.dispatchEvent('toolbar-tool-click', {
|
|
22882
|
-
code: tool.code,
|
|
22883
|
-
tool
|
|
22884
|
-
}, evnt);
|
|
22885
|
-
},
|
|
22886
|
-
triggerZoomEvent(evnt) {
|
|
22887
|
-
gridMethods.zoom();
|
|
22888
|
-
gridMethods.dispatchEvent('zoom', {
|
|
22889
|
-
type: reactData.isZMax ? 'max' : 'revert'
|
|
22890
|
-
}, evnt);
|
|
22891
|
-
}
|
|
22892
|
-
};
|
|
22893
|
-
Object.assign($xeGrid, gridExtendTableMethods, gridMethods, gridPrivateMethods);
|
|
22894
|
-
const columnFlag = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)(0);
|
|
22895
|
-
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(() => props.columns ? props.columns.length : -1, () => {
|
|
22896
|
-
columnFlag.value++;
|
|
22897
|
-
});
|
|
22898
|
-
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(() => props.columns, () => {
|
|
22899
|
-
columnFlag.value++;
|
|
22900
|
-
});
|
|
22901
|
-
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(columnFlag, () => {
|
|
22902
|
-
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => $xeGrid.loadColumn(props.columns || []));
|
|
22903
|
-
});
|
|
22904
|
-
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(() => props.toolbarConfig, () => {
|
|
22905
|
-
initToolbar();
|
|
22906
|
-
});
|
|
22907
|
-
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(() => props.pagerConfig, () => {
|
|
22908
|
-
initPages();
|
|
22909
|
-
});
|
|
22910
|
-
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(() => props.proxyConfig, () => {
|
|
22911
|
-
initProxy();
|
|
22912
|
-
});
|
|
22913
|
-
const handleGlobalKeydownEvent = evnt => {
|
|
22914
|
-
const zoomOpts = computeZoomOpts.value;
|
|
22915
|
-
const isEsc = grid_globalEvents.hasKey(evnt, grid_GLOBAL_EVENT_KEYS.ESCAPE);
|
|
22916
|
-
if (isEsc && reactData.isZMax && zoomOpts.escRestore !== false) {
|
|
22917
|
-
gridPrivateMethods.triggerZoomEvent(evnt);
|
|
22918
|
-
}
|
|
22919
|
-
};
|
|
22920
|
-
grid_hooks.forEach(options => {
|
|
22921
|
-
const {
|
|
22922
|
-
setupGrid
|
|
22923
|
-
} = options;
|
|
22924
|
-
if (setupGrid) {
|
|
22925
|
-
const hookRest = setupGrid($xeGrid);
|
|
22926
|
-
if (hookRest && external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isObject(hookRest)) {
|
|
22927
|
-
Object.assign($xeGrid, hookRest);
|
|
22928
|
-
}
|
|
22929
|
-
}
|
|
22930
|
-
});
|
|
22931
|
-
initPages();
|
|
22932
|
-
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.onMounted)(() => {
|
|
22933
|
-
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
|
|
22934
|
-
const {
|
|
22935
|
-
data,
|
|
22936
|
-
columns,
|
|
22937
|
-
proxyConfig
|
|
22938
|
-
} = props;
|
|
22939
|
-
const proxyOpts = computeProxyOpts.value;
|
|
22940
|
-
const formOpts = computeFormOpts.value;
|
|
22941
|
-
if (isEnableConf(proxyConfig) && (data || proxyOpts.form && formOpts.data)) {
|
|
22942
|
-
grid_log.err('vxe.error.errConflicts', ['grid.data', 'grid.proxy-config']);
|
|
22943
|
-
}
|
|
22944
|
-
// if (process.env.VUE_APP_VXE_ENV === 'development') {
|
|
22945
|
-
// if (proxyOpts.props) {
|
|
22946
|
-
// warnLog('vxe.error.delProp', ['proxy-config.props', 'proxy-config.response'])
|
|
22947
|
-
// }
|
|
22948
|
-
// }
|
|
22949
|
-
if (columns && columns.length) {
|
|
22950
|
-
$xeGrid.loadColumn(columns);
|
|
22951
|
-
}
|
|
22952
|
-
initToolbar();
|
|
22953
|
-
});
|
|
22954
|
-
grid_globalEvents.on($xeGrid, 'keydown', handleGlobalKeydownEvent);
|
|
22955
|
-
});
|
|
22956
|
-
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.onUnmounted)(() => {
|
|
22957
|
-
grid_globalEvents.off($xeGrid, 'keydown');
|
|
22958
|
-
});
|
|
22959
|
-
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
|
|
22960
|
-
initProxy();
|
|
22961
|
-
});
|
|
22962
|
-
const renderVN = () => {
|
|
22963
|
-
const vSize = computeSize.value;
|
|
22964
|
-
const styles = computeStyles.value;
|
|
22965
|
-
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
22966
|
-
ref: refElem,
|
|
22967
|
-
class: ['vxe-grid', {
|
|
22968
|
-
[`size--${vSize}`]: vSize,
|
|
22969
|
-
'is--animat': !!props.animat,
|
|
22970
|
-
'is--round': props.round,
|
|
22971
|
-
'is--maximize': reactData.isZMax,
|
|
22972
|
-
'is--loading': props.loading || reactData.tableLoading
|
|
22973
|
-
}],
|
|
22974
|
-
style: styles
|
|
22975
|
-
}, renderLayout());
|
|
22976
|
-
};
|
|
22977
|
-
$xeGrid.renderVN = renderVN;
|
|
22978
|
-
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.provide)('$xeGrid', $xeGrid);
|
|
22979
|
-
return $xeGrid;
|
|
22980
|
-
},
|
|
22981
|
-
render() {
|
|
22982
|
-
return this.renderVN();
|
|
22983
|
-
}
|
|
22984
|
-
}));
|
|
22985
|
-
;// CONCATENATED MODULE: ./packages/grid/index.ts
|
|
22986
|
-
|
|
22987
|
-
|
|
22988
|
-
const VxeGrid = Object.assign({}, grid, {
|
|
22989
|
-
install(app) {
|
|
22990
|
-
app.component(grid.name, grid);
|
|
22991
|
-
}
|
|
22992
|
-
});
|
|
22993
|
-
if (external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.dynamicApp) {
|
|
22994
|
-
external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.dynamicApp.component(grid.name, grid);
|
|
22995
|
-
}
|
|
22996
|
-
const Grid = VxeGrid;
|
|
22997
|
-
/* harmony default export */ var packages_grid = ((/* unused pure expression or super */ null && (VxeGrid)));
|
|
22998
|
-
;// CONCATENATED MODULE: ./packages/ui/index.ts
|
|
22999
|
-
|
|
23000
|
-
external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.version = "4.7.3";
|
|
23001
|
-
external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.tableVersion = "4.7.3";
|
|
23002
|
-
external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.setConfig({
|
|
23003
|
-
emptyCell: ' ',
|
|
23004
|
-
table: {
|
|
23005
|
-
fit: true,
|
|
23006
|
-
showHeader: true,
|
|
23007
|
-
animat: true,
|
|
23008
|
-
delayHover: 250,
|
|
23009
|
-
autoResize: true,
|
|
23010
|
-
minHeight: 144,
|
|
23011
|
-
// keepSource: false,
|
|
23012
|
-
// showOverflow: null,
|
|
23013
|
-
// showHeaderOverflow: null,
|
|
23014
|
-
// showFooterOverflow: null,
|
|
23015
|
-
// resizeInterval: 500,
|
|
23016
|
-
// size: null,
|
|
23017
|
-
// zIndex: null,
|
|
23018
|
-
// stripe: false,
|
|
23019
|
-
// border: false,
|
|
23020
|
-
// round: false,
|
|
23021
|
-
// emptyText: '暂无数据',
|
|
23022
|
-
// emptyRender: {
|
|
23023
|
-
// name: ''
|
|
23024
|
-
// },
|
|
23025
|
-
// rowConfig: {
|
|
23026
|
-
// keyField: '_X_ROW_KEY' // 行数据的唯一主键字段名
|
|
23027
|
-
// },
|
|
23028
|
-
resizeConfig: {
|
|
23029
|
-
refreshDelay: 250
|
|
23030
|
-
},
|
|
23031
|
-
radioConfig: {
|
|
23032
|
-
// trigger: 'default'
|
|
23033
|
-
strict: true
|
|
23034
|
-
},
|
|
23035
|
-
checkboxConfig: {
|
|
23036
|
-
// trigger: 'default',
|
|
23037
|
-
strict: true
|
|
23038
|
-
},
|
|
23039
|
-
tooltipConfig: {
|
|
23040
|
-
enterable: true
|
|
23041
|
-
},
|
|
23042
|
-
validConfig: {
|
|
23043
|
-
showMessage: true,
|
|
23044
|
-
autoClear: true,
|
|
23045
|
-
autoPos: true,
|
|
23046
|
-
message: 'inline',
|
|
23047
|
-
msgMode: 'single'
|
|
23048
|
-
},
|
|
23049
|
-
columnConfig: {
|
|
23050
|
-
maxFixedSize: 4
|
|
23051
|
-
},
|
|
23052
|
-
// menuConfig: {
|
|
23053
|
-
// visibleMethod () {}
|
|
23054
|
-
// },
|
|
23055
|
-
customConfig: {
|
|
23056
|
-
allowFixed: true,
|
|
23057
|
-
showFooter: true
|
|
23058
|
-
// storage: false,
|
|
23059
|
-
// checkMethod () {}
|
|
23060
|
-
},
|
|
23061
|
-
sortConfig: {
|
|
23062
|
-
// remote: false,
|
|
23063
|
-
// trigger: 'default',
|
|
23064
|
-
// orders: ['asc', 'desc', null],
|
|
23065
|
-
// sortMethod: null,
|
|
23066
|
-
showIcon: true,
|
|
23067
|
-
iconLayout: 'vertical'
|
|
23068
|
-
},
|
|
23069
|
-
filterConfig: {
|
|
23070
|
-
// remote: false,
|
|
23071
|
-
// filterMethod: null,
|
|
23072
|
-
showIcon: true
|
|
23073
|
-
},
|
|
23074
|
-
treeConfig: {
|
|
23075
|
-
rowField: 'id',
|
|
23076
|
-
parentField: 'parentId',
|
|
23077
|
-
childrenField: 'children',
|
|
23078
|
-
hasChildField: 'hasChild',
|
|
23079
|
-
mapChildrenField: '_X_ROW_CHILD',
|
|
23080
|
-
indent: 20,
|
|
23081
|
-
showIcon: true
|
|
23082
|
-
},
|
|
23083
|
-
expandConfig: {
|
|
23084
|
-
// trigger: 'default',
|
|
23085
|
-
showIcon: true
|
|
23086
|
-
},
|
|
23087
|
-
editConfig: {
|
|
23088
|
-
// mode: 'cell',
|
|
23089
|
-
showIcon: true,
|
|
23090
|
-
showAsterisk: true
|
|
23091
|
-
},
|
|
23092
|
-
importConfig: {
|
|
23093
|
-
_typeMaps: {
|
|
23094
|
-
csv: 1,
|
|
23095
|
-
html: 1,
|
|
23096
|
-
xml: 1,
|
|
23097
|
-
txt: 1
|
|
23098
|
-
},
|
|
23099
|
-
modes: ['insert', 'covering']
|
|
23100
|
-
},
|
|
23101
|
-
exportConfig: {
|
|
23102
|
-
_typeMaps: {
|
|
23103
|
-
csv: 1,
|
|
23104
|
-
html: 1,
|
|
23105
|
-
xml: 1,
|
|
23106
|
-
txt: 1
|
|
23107
|
-
},
|
|
23108
|
-
modes: ['current', 'selected']
|
|
23109
|
-
},
|
|
23110
|
-
printConfig: {
|
|
23111
|
-
modes: ['current', 'selected']
|
|
23112
|
-
},
|
|
23113
|
-
mouseConfig: {
|
|
23114
|
-
extension: true
|
|
23115
|
-
},
|
|
23116
|
-
keyboardConfig: {
|
|
23117
|
-
isEsc: true
|
|
23118
|
-
},
|
|
23119
|
-
areaConfig: {
|
|
23120
|
-
autoClear: true,
|
|
23121
|
-
selectCellByHeader: true
|
|
23122
|
-
},
|
|
23123
|
-
clipConfig: {
|
|
23124
|
-
isCopy: true,
|
|
23125
|
-
isCut: true,
|
|
23126
|
-
isPaste: true
|
|
23127
|
-
},
|
|
23128
|
-
fnrConfig: {
|
|
23129
|
-
isFind: true,
|
|
23130
|
-
isReplace: true
|
|
23131
|
-
},
|
|
23132
|
-
scrollX: {
|
|
23133
|
-
// enabled: false,
|
|
23134
|
-
gt: 60
|
|
23135
|
-
// oSize: 0
|
|
23136
|
-
},
|
|
23137
|
-
scrollY: {
|
|
23138
|
-
// enabled: false,
|
|
23139
|
-
gt: 100
|
|
23140
|
-
// oSize: 0
|
|
23141
|
-
}
|
|
23142
|
-
},
|
|
23143
|
-
// export: {
|
|
23144
|
-
// types: {}
|
|
23145
|
-
// },
|
|
23146
|
-
grid: {
|
|
23147
|
-
// size: null,
|
|
23148
|
-
// zoomConfig: {
|
|
23149
|
-
// escRestore: true
|
|
23150
|
-
// },
|
|
23151
|
-
formConfig: {
|
|
23152
|
-
enabled: true
|
|
23153
|
-
},
|
|
23154
|
-
pagerConfig: {
|
|
23155
|
-
enabled: true
|
|
23156
|
-
// perfect: false
|
|
23157
|
-
},
|
|
23158
|
-
toolbarConfig: {
|
|
23159
|
-
enabled: true
|
|
23160
|
-
// perfect: false
|
|
23161
|
-
},
|
|
23162
|
-
proxyConfig: {
|
|
23163
|
-
enabled: true,
|
|
23164
|
-
autoLoad: true,
|
|
23165
|
-
message: true,
|
|
23166
|
-
props: {
|
|
23167
|
-
list: null,
|
|
23168
|
-
result: 'result',
|
|
23169
|
-
total: 'page.total',
|
|
23170
|
-
message: 'message'
|
|
23171
|
-
}
|
|
23172
|
-
// beforeItem: null,
|
|
23173
|
-
// beforeColumn: null,
|
|
23174
|
-
// beforeQuery: null,
|
|
23175
|
-
// afterQuery: null,
|
|
23176
|
-
// beforeDelete: null,
|
|
23177
|
-
// afterDelete: null,
|
|
23178
|
-
// beforeSave: null,
|
|
23179
|
-
// afterSave: null
|
|
23180
|
-
}
|
|
23227
|
+
const gridPrivateMethods = {
|
|
23228
|
+
extendTableMethods,
|
|
23229
|
+
callSlot(slotFunc, params) {
|
|
23230
|
+
if (slotFunc) {
|
|
23231
|
+
if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isString(slotFunc)) {
|
|
23232
|
+
slotFunc = slots[slotFunc] || null;
|
|
23233
|
+
}
|
|
23234
|
+
if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(slotFunc)) {
|
|
23235
|
+
return getSlotVNs(slotFunc(params));
|
|
23236
|
+
}
|
|
23237
|
+
}
|
|
23238
|
+
return [];
|
|
23239
|
+
},
|
|
23240
|
+
/**
|
|
23241
|
+
* 获取需要排除的高度
|
|
23242
|
+
*/
|
|
23243
|
+
getExcludeHeight() {
|
|
23244
|
+
const {
|
|
23245
|
+
height
|
|
23246
|
+
} = props;
|
|
23247
|
+
const {
|
|
23248
|
+
isZMax
|
|
23249
|
+
} = reactData;
|
|
23250
|
+
const el = refElem.value;
|
|
23251
|
+
const formWrapper = refFormWrapper.value;
|
|
23252
|
+
const toolbarWrapper = refToolbarWrapper.value;
|
|
23253
|
+
const topWrapper = refTopWrapper.value;
|
|
23254
|
+
const bottomWrapper = refBottomWrapper.value;
|
|
23255
|
+
const pagerWrapper = refPagerWrapper.value;
|
|
23256
|
+
const parentPaddingSize = isZMax || height !== 'auto' ? 0 : getPaddingTopBottomSize(el.parentNode);
|
|
23257
|
+
return parentPaddingSize + getPaddingTopBottomSize(el) + getOffsetHeight(formWrapper) + getOffsetHeight(toolbarWrapper) + getOffsetHeight(topWrapper) + getOffsetHeight(bottomWrapper) + getOffsetHeight(pagerWrapper);
|
|
23258
|
+
},
|
|
23259
|
+
getParentHeight() {
|
|
23260
|
+
const el = refElem.value;
|
|
23261
|
+
if (el) {
|
|
23262
|
+
return (reactData.isZMax ? getDomNode().visibleHeight : external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toNumber(getComputedStyle(el.parentNode).height)) - gridPrivateMethods.getExcludeHeight();
|
|
23263
|
+
}
|
|
23264
|
+
return 0;
|
|
23265
|
+
},
|
|
23266
|
+
triggerToolbarCommitEvent(params, evnt) {
|
|
23267
|
+
const {
|
|
23268
|
+
code
|
|
23269
|
+
} = params;
|
|
23270
|
+
return gridMethods.commitProxy(params, evnt).then(rest => {
|
|
23271
|
+
if (code && rest && rest.status && ['query', 'reload', 'delete', 'save'].includes(code)) {
|
|
23272
|
+
gridMethods.dispatchEvent(code === 'delete' || code === 'save' ? `proxy-${code}` : 'proxy-query', {
|
|
23273
|
+
...rest,
|
|
23274
|
+
isReload: code === 'reload'
|
|
23275
|
+
}, evnt);
|
|
23276
|
+
}
|
|
23277
|
+
});
|
|
23278
|
+
},
|
|
23279
|
+
triggerToolbarBtnEvent(button, evnt) {
|
|
23280
|
+
gridPrivateMethods.triggerToolbarCommitEvent(button, evnt);
|
|
23281
|
+
gridMethods.dispatchEvent('toolbar-button-click', {
|
|
23282
|
+
code: button.code,
|
|
23283
|
+
button
|
|
23284
|
+
}, evnt);
|
|
23285
|
+
},
|
|
23286
|
+
triggerToolbarTolEvent(tool, evnt) {
|
|
23287
|
+
gridPrivateMethods.triggerToolbarCommitEvent(tool, evnt);
|
|
23288
|
+
gridMethods.dispatchEvent('toolbar-tool-click', {
|
|
23289
|
+
code: tool.code,
|
|
23290
|
+
tool
|
|
23291
|
+
}, evnt);
|
|
23292
|
+
},
|
|
23293
|
+
triggerZoomEvent(evnt) {
|
|
23294
|
+
gridMethods.zoom();
|
|
23295
|
+
gridMethods.dispatchEvent('zoom', {
|
|
23296
|
+
type: reactData.isZMax ? 'max' : 'revert'
|
|
23297
|
+
}, evnt);
|
|
23298
|
+
}
|
|
23299
|
+
};
|
|
23300
|
+
Object.assign($xeGrid, gridExtendTableMethods, gridMethods, gridPrivateMethods);
|
|
23301
|
+
const columnFlag = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)(0);
|
|
23302
|
+
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(() => props.columns ? props.columns.length : -1, () => {
|
|
23303
|
+
columnFlag.value++;
|
|
23304
|
+
});
|
|
23305
|
+
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(() => props.columns, () => {
|
|
23306
|
+
columnFlag.value++;
|
|
23307
|
+
});
|
|
23308
|
+
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(columnFlag, () => {
|
|
23309
|
+
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => $xeGrid.loadColumn(props.columns || []));
|
|
23310
|
+
});
|
|
23311
|
+
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(() => props.toolbarConfig, () => {
|
|
23312
|
+
initToolbar();
|
|
23313
|
+
});
|
|
23314
|
+
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(() => props.pagerConfig, () => {
|
|
23315
|
+
initPages();
|
|
23316
|
+
});
|
|
23317
|
+
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(() => props.proxyConfig, () => {
|
|
23318
|
+
initProxy();
|
|
23319
|
+
});
|
|
23320
|
+
const handleGlobalKeydownEvent = evnt => {
|
|
23321
|
+
const zoomOpts = computeZoomOpts.value;
|
|
23322
|
+
const isEsc = grid_globalEvents.hasKey(evnt, grid_GLOBAL_EVENT_KEYS.ESCAPE);
|
|
23323
|
+
if (isEsc && reactData.isZMax && zoomOpts.escRestore !== false) {
|
|
23324
|
+
gridPrivateMethods.triggerZoomEvent(evnt);
|
|
23325
|
+
}
|
|
23326
|
+
};
|
|
23327
|
+
grid_hooks.forEach(options => {
|
|
23328
|
+
const {
|
|
23329
|
+
setupGrid
|
|
23330
|
+
} = options;
|
|
23331
|
+
if (setupGrid) {
|
|
23332
|
+
const hookRest = setupGrid($xeGrid);
|
|
23333
|
+
if (hookRest && external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isObject(hookRest)) {
|
|
23334
|
+
Object.assign($xeGrid, hookRest);
|
|
23335
|
+
}
|
|
23336
|
+
}
|
|
23337
|
+
});
|
|
23338
|
+
initPages();
|
|
23339
|
+
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.onMounted)(() => {
|
|
23340
|
+
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
|
|
23341
|
+
const {
|
|
23342
|
+
data,
|
|
23343
|
+
columns,
|
|
23344
|
+
proxyConfig
|
|
23345
|
+
} = props;
|
|
23346
|
+
const proxyOpts = computeProxyOpts.value;
|
|
23347
|
+
const formOpts = computeFormOpts.value;
|
|
23348
|
+
if (isEnableConf(proxyConfig) && (data || proxyOpts.form && formOpts.data)) {
|
|
23349
|
+
grid_log.err('vxe.error.errConflicts', ['grid.data', 'grid.proxy-config']);
|
|
23350
|
+
}
|
|
23351
|
+
// if (process.env.VUE_APP_VXE_ENV === 'development') {
|
|
23352
|
+
// if (proxyOpts.props) {
|
|
23353
|
+
// warnLog('vxe.error.delProp', ['proxy-config.props', 'proxy-config.response'])
|
|
23354
|
+
// }
|
|
23355
|
+
// }
|
|
23356
|
+
if (columns && columns.length) {
|
|
23357
|
+
$xeGrid.loadColumn(columns);
|
|
23358
|
+
}
|
|
23359
|
+
initToolbar();
|
|
23360
|
+
});
|
|
23361
|
+
grid_globalEvents.on($xeGrid, 'keydown', handleGlobalKeydownEvent);
|
|
23362
|
+
});
|
|
23363
|
+
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.onUnmounted)(() => {
|
|
23364
|
+
grid_globalEvents.off($xeGrid, 'keydown');
|
|
23365
|
+
});
|
|
23366
|
+
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
|
|
23367
|
+
initProxy();
|
|
23368
|
+
});
|
|
23369
|
+
const renderVN = () => {
|
|
23370
|
+
const vSize = computeSize.value;
|
|
23371
|
+
const styles = computeStyles.value;
|
|
23372
|
+
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
23373
|
+
ref: refElem,
|
|
23374
|
+
class: ['vxe-grid', {
|
|
23375
|
+
[`size--${vSize}`]: vSize,
|
|
23376
|
+
'is--animat': !!props.animat,
|
|
23377
|
+
'is--round': props.round,
|
|
23378
|
+
'is--maximize': reactData.isZMax,
|
|
23379
|
+
'is--loading': props.loading || reactData.tableLoading
|
|
23380
|
+
}],
|
|
23381
|
+
style: styles
|
|
23382
|
+
}, renderLayout());
|
|
23383
|
+
};
|
|
23384
|
+
$xeGrid.renderVN = renderVN;
|
|
23385
|
+
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.provide)('$xeGrid', $xeGrid);
|
|
23386
|
+
return $xeGrid;
|
|
23181
23387
|
},
|
|
23182
|
-
|
|
23183
|
-
|
|
23184
|
-
// import: {
|
|
23185
|
-
// mode: 'covering'
|
|
23186
|
-
// },
|
|
23187
|
-
// export: {
|
|
23188
|
-
// types: ['csv', 'html', 'xml', 'txt']
|
|
23189
|
-
// },
|
|
23190
|
-
// buttons: []
|
|
23388
|
+
render() {
|
|
23389
|
+
return this.renderVN();
|
|
23191
23390
|
}
|
|
23192
|
-
});
|
|
23193
|
-
|
|
23194
|
-
external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.setIcon({
|
|
23195
|
-
// table
|
|
23196
|
-
TABLE_SORT_ASC: iconPrefix + 'caret-up',
|
|
23197
|
-
TABLE_SORT_DESC: iconPrefix + 'caret-down',
|
|
23198
|
-
TABLE_FILTER_NONE: iconPrefix + 'funnel',
|
|
23199
|
-
TABLE_FILTER_MATCH: iconPrefix + 'funnel',
|
|
23200
|
-
TABLE_EDIT: iconPrefix + 'edit',
|
|
23201
|
-
TABLE_TITLE_PREFIX: iconPrefix + 'question-circle-fill',
|
|
23202
|
-
TABLE_TITLE_SUFFIX: iconPrefix + 'question-circle-fill',
|
|
23203
|
-
TABLE_TREE_LOADED: iconPrefix + 'spinner roll',
|
|
23204
|
-
TABLE_TREE_OPEN: iconPrefix + 'caret-right rotate90',
|
|
23205
|
-
TABLE_TREE_CLOSE: iconPrefix + 'caret-right',
|
|
23206
|
-
TABLE_EXPAND_LOADED: iconPrefix + 'spinner roll',
|
|
23207
|
-
TABLE_EXPAND_OPEN: iconPrefix + 'arrow-right rotate90',
|
|
23208
|
-
TABLE_EXPAND_CLOSE: iconPrefix + 'arrow-right',
|
|
23209
|
-
TABLE_CHECKBOX_CHECKED: iconPrefix + 'checkbox-checked-fill',
|
|
23210
|
-
TABLE_CHECKBOX_UNCHECKED: iconPrefix + 'checkbox-unchecked',
|
|
23211
|
-
TABLE_CHECKBOX_INDETERMINATE: iconPrefix + 'checkbox-indeterminate-fill',
|
|
23212
|
-
TABLE_RADIO_CHECKED: iconPrefix + 'radio-checked-fill',
|
|
23213
|
-
TABLE_RADIO_UNCHECKED: iconPrefix + 'radio-unchecked',
|
|
23214
|
-
// toolbar
|
|
23215
|
-
TOOLBAR_TOOLS_REFRESH: iconPrefix + 'repeat',
|
|
23216
|
-
TOOLBAR_TOOLS_REFRESH_LOADING: iconPrefix + 'repeat roll',
|
|
23217
|
-
TOOLBAR_TOOLS_IMPORT: iconPrefix + 'upload',
|
|
23218
|
-
TOOLBAR_TOOLS_EXPORT: iconPrefix + 'download',
|
|
23219
|
-
TOOLBAR_TOOLS_PRINT: iconPrefix + 'print',
|
|
23220
|
-
TOOLBAR_TOOLS_FULLSCREEN: iconPrefix + 'fullscreen',
|
|
23221
|
-
TOOLBAR_TOOLS_MINIMIZE: iconPrefix + 'minimize',
|
|
23222
|
-
TOOLBAR_TOOLS_CUSTOM: iconPrefix + 'custom-column',
|
|
23223
|
-
TOOLBAR_TOOLS_FIXED_LEFT: iconPrefix + 'fixed-left',
|
|
23224
|
-
TOOLBAR_TOOLS_FIXED_LEFT_ACTIVE: iconPrefix + 'fixed-left-fill',
|
|
23225
|
-
TOOLBAR_TOOLS_FIXED_RIGHT: iconPrefix + 'fixed-right',
|
|
23226
|
-
TOOLBAR_TOOLS_FIXED_RIGHT_ACTIVE: iconPrefix + 'fixed-right-fill'
|
|
23227
|
-
});
|
|
23228
|
-
const setTheme = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.setTheme;
|
|
23229
|
-
const getTheme = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.getTheme;
|
|
23230
|
-
const setConfig = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.setConfig;
|
|
23231
|
-
const ui_getConfig = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.getConfig;
|
|
23232
|
-
const setIcon = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.setIcon;
|
|
23233
|
-
const ui_getIcon = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.getIcon;
|
|
23234
|
-
const setLanguage = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.setLanguage;
|
|
23235
|
-
const setI18n = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.setI18n;
|
|
23236
|
-
const ui_getI18n = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.getI18n;
|
|
23237
|
-
const ui_globalEvents = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.globalEvents;
|
|
23238
|
-
const ui_globalResize = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.globalResize;
|
|
23239
|
-
const ui_renderer = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.renderer;
|
|
23240
|
-
const ui_validators = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.validators;
|
|
23241
|
-
const ui_menus = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.menus;
|
|
23242
|
-
const ui_formats = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.formats;
|
|
23243
|
-
const ui_commands = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.commands;
|
|
23244
|
-
const ui_interceptor = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.interceptor;
|
|
23245
|
-
const clipboard = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.clipboard;
|
|
23246
|
-
const ui_log = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.log;
|
|
23247
|
-
const ui_hooks = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.hooks;
|
|
23248
|
-
const use = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.use;
|
|
23249
|
-
/**
|
|
23250
|
-
* 已废弃
|
|
23251
|
-
* @deprecated
|
|
23252
|
-
*/
|
|
23253
|
-
const setup = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.setup;
|
|
23254
|
-
/**
|
|
23255
|
-
* 已废弃
|
|
23256
|
-
* @deprecated
|
|
23257
|
-
*/
|
|
23258
|
-
const config = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.config;
|
|
23259
|
-
/**
|
|
23260
|
-
* 已废弃
|
|
23261
|
-
* @deprecated
|
|
23262
|
-
*/
|
|
23263
|
-
const t = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.t;
|
|
23264
|
-
/**
|
|
23265
|
-
* 已废弃
|
|
23266
|
-
* @deprecated
|
|
23267
|
-
*/
|
|
23268
|
-
const _t = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI._t;
|
|
23269
|
-
/**
|
|
23270
|
-
* 已废弃,兼容老版本
|
|
23271
|
-
* @deprecated
|
|
23272
|
-
*/
|
|
23273
|
-
const VXETable = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI;
|
|
23274
|
-
const saveFile = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.readFile;
|
|
23275
|
-
const readFile = external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.readFile;
|
|
23391
|
+
}));
|
|
23392
|
+
;// CONCATENATED MODULE: ./packages/grid/index.ts
|
|
23276
23393
|
|
|
23277
|
-
|
|
23394
|
+
|
|
23395
|
+
const VxeGrid = Object.assign({}, grid, {
|
|
23396
|
+
install(app) {
|
|
23397
|
+
app.component(grid.name, grid);
|
|
23398
|
+
}
|
|
23399
|
+
});
|
|
23400
|
+
if (external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.dynamicApp) {
|
|
23401
|
+
external_root_VxeUI_commonjs_vxe_pc_ui_commonjs2_vxe_pc_ui_amd_vxe_pc_ui_.VxeUI.dynamicApp.component(grid.name, grid);
|
|
23402
|
+
}
|
|
23403
|
+
const Grid = VxeGrid;
|
|
23404
|
+
/* harmony default export */ var packages_grid = ((/* unused pure expression or super */ null && (VxeGrid)));
|
|
23278
23405
|
;// CONCATENATED MODULE: ./packages/components.ts
|
|
23279
23406
|
|
|
23280
23407
|
|