vxe-table 4.3.5 → 4.3.6

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.
Files changed (491) hide show
  1. package/es/button/style.css +465 -341
  2. package/es/checkbox/style.css +156 -127
  3. package/es/checkbox-group/style.css +1 -1
  4. package/es/colgroup/style.css +1 -1
  5. package/es/column/style.css +1 -1
  6. package/es/edit/style.css +1 -1
  7. package/es/export/src/hook.js +1 -0
  8. package/es/export/style.css +136 -108
  9. package/es/filter/src/hook.js +1 -1
  10. package/es/filter/style.css +103 -82
  11. package/es/form/src/form.js +5 -4
  12. package/es/form/style.css +201 -168
  13. package/es/form-gather/style.css +1 -1
  14. package/es/form-item/style.css +1 -1
  15. package/es/grid/style.css +61 -50
  16. package/es/icon/style/iconfont.1669214286403.ttf +0 -0
  17. package/es/icon/style/iconfont.1669214286403.woff +0 -0
  18. package/es/icon/style/iconfont.1669214286403.woff2 +0 -0
  19. package/es/icon/style.css +372 -195
  20. package/es/iconfont.1669214286403.ttf +0 -0
  21. package/es/iconfont.1669214286403.woff +0 -0
  22. package/es/iconfont.1669214286403.woff2 +0 -0
  23. package/es/input/style.css +771 -595
  24. package/es/keyboard/style.css +1 -1
  25. package/es/list/src/list.js +7 -1
  26. package/es/list/style.css +19 -14
  27. package/es/loading/style.css +52 -48
  28. package/es/menu/style.css +79 -59
  29. package/es/modal/style.css +311 -247
  30. package/es/optgroup/style.css +1 -1
  31. package/es/option/style.css +1 -1
  32. package/es/pager/style.css +307 -257
  33. package/es/pulldown/src/pulldown.js +9 -3
  34. package/es/pulldown/style.css +42 -31
  35. package/es/radio/style.css +184 -151
  36. package/es/radio-button/style.css +1 -1
  37. package/es/radio-group/style.css +1 -1
  38. package/es/select/style.css +108 -79
  39. package/es/style.css +1 -1
  40. package/es/style.min.css +1 -1
  41. package/es/switch/style.css +87 -67
  42. package/es/table/src/column.js +2 -0
  43. package/es/table/src/columnInfo.js +1 -0
  44. package/es/table/src/table.js +16 -16
  45. package/es/table/style.css +1025 -835
  46. package/es/textarea/style.css +57 -41
  47. package/es/toolbar/style.css +216 -174
  48. package/es/tools/log.js +1 -1
  49. package/es/tooltip/style.css +87 -63
  50. package/es/v-x-e-table/index.js +1 -1
  51. package/es/v-x-e-table/style.css +424 -243
  52. package/es/validator/style.css +1 -1
  53. package/es/vxe-button/style.css +465 -341
  54. package/es/vxe-checkbox/style.css +156 -127
  55. package/es/vxe-checkbox-group/style.css +1 -1
  56. package/es/vxe-colgroup/style.css +1 -1
  57. package/es/vxe-column/style.css +1 -1
  58. package/es/vxe-form/style.css +201 -168
  59. package/es/vxe-form-gather/style.css +1 -1
  60. package/es/vxe-form-item/style.css +1 -1
  61. package/es/vxe-grid/style.css +61 -50
  62. package/es/vxe-icon/style.css +372 -195
  63. package/es/vxe-input/style.css +771 -595
  64. package/es/vxe-list/style.css +19 -14
  65. package/es/vxe-loading/style.css +52 -48
  66. package/es/vxe-modal/style.css +311 -247
  67. package/es/vxe-module-edit/style.css +1 -1
  68. package/es/vxe-module-export/style.css +136 -108
  69. package/es/vxe-module-filter/style.css +103 -82
  70. package/es/vxe-module-keyboard/style.css +1 -1
  71. package/es/vxe-module-menu/style.css +79 -59
  72. package/es/vxe-module-validator/style.css +1 -1
  73. package/es/vxe-optgroup/style.css +1 -1
  74. package/es/vxe-option/style.css +1 -1
  75. package/es/vxe-pager/style.css +307 -257
  76. package/es/vxe-pulldown/style.css +42 -31
  77. package/es/vxe-radio/style.css +184 -151
  78. package/es/vxe-radio-button/style.css +1 -1
  79. package/es/vxe-radio-group/style.css +1 -1
  80. package/es/vxe-select/style.css +108 -79
  81. package/es/vxe-switch/style.css +87 -67
  82. package/es/vxe-table/style.css +1025 -835
  83. package/es/vxe-textarea/style.css +57 -41
  84. package/es/vxe-toolbar/style.css +216 -174
  85. package/es/vxe-tooltip/style.css +87 -63
  86. package/lib/all.js +45 -115
  87. package/lib/all.min.js +1 -1
  88. package/lib/button/index.js +1 -7
  89. package/lib/button/index.min.js +1 -1
  90. package/lib/button/src/button.js +48 -113
  91. package/lib/button/src/button.min.js +1 -1
  92. package/lib/button/style/style.css +465 -341
  93. package/lib/button/style/style.min.css +1 -1
  94. package/lib/checkbox/index.js +1 -7
  95. package/lib/checkbox/index.min.js +1 -1
  96. package/lib/checkbox/src/checkbox.js +12 -32
  97. package/lib/checkbox/src/checkbox.min.js +1 -1
  98. package/lib/checkbox/src/group.js +13 -28
  99. package/lib/checkbox/src/group.min.js +1 -1
  100. package/lib/checkbox/style/style.css +156 -127
  101. package/lib/checkbox/style/style.min.css +1 -1
  102. package/lib/checkbox-group/index.js +1 -7
  103. package/lib/checkbox-group/index.min.js +1 -1
  104. package/lib/checkbox-group/style/style.css +1 -1
  105. package/lib/colgroup/index.js +5 -12
  106. package/lib/colgroup/index.min.js +1 -1
  107. package/lib/colgroup/style/style.css +1 -1
  108. package/lib/column/index.js +5 -12
  109. package/lib/column/index.min.js +1 -1
  110. package/lib/column/style/style.css +1 -1
  111. package/lib/dynamics/index.js +1 -5
  112. package/lib/dynamics/index.min.js +1 -1
  113. package/lib/edit/index.js +1 -5
  114. package/lib/edit/index.min.js +1 -1
  115. package/lib/edit/src/hook.js +102 -248
  116. package/lib/edit/src/hook.min.js +1 -1
  117. package/lib/edit/style/style.css +1 -1
  118. package/lib/export/index.js +4 -19
  119. package/lib/export/index.min.js +1 -1
  120. package/lib/export/src/export-panel.js +38 -77
  121. package/lib/export/src/export-panel.min.js +1 -1
  122. package/lib/export/src/hook.js +127 -380
  123. package/lib/export/src/hook.min.js +1 -1
  124. package/lib/export/src/import-panel.js +17 -39
  125. package/lib/export/src/import-panel.min.js +1 -1
  126. package/lib/export/src/util.js +10 -52
  127. package/lib/export/src/util.min.js +1 -1
  128. package/lib/export/style/style.css +136 -108
  129. package/lib/export/style/style.min.css +1 -1
  130. package/lib/filter/index.js +1 -10
  131. package/lib/filter/index.min.js +1 -1
  132. package/lib/filter/src/hook.js +31 -82
  133. package/lib/filter/src/hook.min.js +1 -1
  134. package/lib/filter/src/panel.js +25 -52
  135. package/lib/filter/src/panel.min.js +1 -1
  136. package/lib/filter/style/style.css +103 -82
  137. package/lib/filter/style/style.min.css +1 -1
  138. package/lib/footer/index.js +1 -7
  139. package/lib/footer/index.min.js +1 -1
  140. package/lib/footer/src/footer.js +51 -96
  141. package/lib/footer/src/footer.min.js +1 -1
  142. package/lib/form/index.js +1 -7
  143. package/lib/form/index.min.js +1 -1
  144. package/lib/form/src/form-config-item.js +27 -56
  145. package/lib/form/src/form-config-item.min.js +1 -1
  146. package/lib/form/src/form-gather.js +3 -12
  147. package/lib/form/src/form-gather.min.js +1 -1
  148. package/lib/form/src/form-item.js +23 -52
  149. package/lib/form/src/form-item.min.js +1 -1
  150. package/lib/form/src/form.js +78 -185
  151. package/lib/form/src/form.min.js +1 -1
  152. package/lib/form/src/itemInfo.js +1 -9
  153. package/lib/form/src/render.js +7 -26
  154. package/lib/form/src/render.min.js +1 -1
  155. package/lib/form/src/util.js +4 -28
  156. package/lib/form/src/util.min.js +1 -1
  157. package/lib/form/style/style.css +201 -168
  158. package/lib/form/style/style.min.css +1 -1
  159. package/lib/form-gather/index.js +1 -7
  160. package/lib/form-gather/index.min.js +1 -1
  161. package/lib/form-gather/style/style.css +1 -1
  162. package/lib/form-item/index.js +1 -7
  163. package/lib/form-item/index.min.js +1 -1
  164. package/lib/form-item/style/style.css +1 -1
  165. package/lib/grid/index.js +1 -7
  166. package/lib/grid/index.min.js +1 -1
  167. package/lib/grid/src/grid.js +97 -315
  168. package/lib/grid/src/grid.min.js +1 -1
  169. package/lib/grid/style/style.css +61 -50
  170. package/lib/grid/style/style.min.css +1 -1
  171. package/lib/header/index.js +1 -7
  172. package/lib/header/index.min.js +1 -1
  173. package/lib/header/src/header.js +47 -87
  174. package/lib/header/src/header.min.js +1 -1
  175. package/lib/header/src/util.js +3 -14
  176. package/lib/header/src/util.min.js +1 -1
  177. package/lib/hooks/size.js +0 -2
  178. package/lib/icon/index.js +1 -7
  179. package/lib/icon/index.min.js +1 -1
  180. package/lib/icon/src/icon.js +2 -7
  181. package/lib/icon/style/iconfont.1669214286403.ttf +0 -0
  182. package/lib/icon/style/iconfont.1669214286403.woff +0 -0
  183. package/lib/icon/style/iconfont.1669214286403.woff2 +0 -0
  184. package/lib/icon/style/style.css +372 -195
  185. package/lib/icon/style/style.min.css +719 -1
  186. package/lib/iconfont.1669214286403.ttf +0 -0
  187. package/lib/iconfont.1669214286403.woff +0 -0
  188. package/lib/iconfont.1669214286403.woff2 +0 -0
  189. package/lib/index.common.js +3 -10
  190. package/lib/index.common.min.js +1 -1
  191. package/lib/index.umd.js +14466 -23839
  192. package/lib/index.umd.min.js +1 -1
  193. package/lib/input/index.js +1 -7
  194. package/lib/input/index.min.js +1 -1
  195. package/lib/input/src/date.js +0 -10
  196. package/lib/input/src/date.min.js +1 -1
  197. package/lib/input/src/input.js +217 -553
  198. package/lib/input/src/input.min.js +1 -1
  199. package/lib/input/src/number.js +0 -5
  200. package/lib/input/style/style.css +771 -595
  201. package/lib/input/style/style.min.css +1 -1
  202. package/lib/keyboard/index.js +1 -5
  203. package/lib/keyboard/index.min.js +1 -1
  204. package/lib/keyboard/src/hook.js +40 -106
  205. package/lib/keyboard/src/hook.min.js +1 -1
  206. package/lib/keyboard/style/style.css +1 -1
  207. package/lib/list/index.js +1 -7
  208. package/lib/list/index.min.js +1 -1
  209. package/lib/list/src/list.js +39 -91
  210. package/lib/list/src/list.min.js +1 -1
  211. package/lib/list/style/style.css +19 -14
  212. package/lib/loading/index.js +1 -4
  213. package/lib/loading/index.min.js +1 -1
  214. package/lib/loading/src/loading.js +1 -6
  215. package/lib/loading/style/style.css +52 -48
  216. package/lib/loading/style/style.min.css +1 -1
  217. package/lib/locale/lang/zh-HK.js +0 -3
  218. package/lib/locale/lang/zh-MO.js +0 -3
  219. package/lib/locale/lang/zh-TW.js +0 -3
  220. package/lib/menu/index.js +1 -10
  221. package/lib/menu/index.min.js +1 -1
  222. package/lib/menu/src/hooks.js +45 -109
  223. package/lib/menu/src/hooks.min.js +1 -1
  224. package/lib/menu/src/panel.js +10 -19
  225. package/lib/menu/src/panel.min.js +1 -1
  226. package/lib/menu/style/style.css +79 -59
  227. package/lib/menu/style/style.min.css +1 -1
  228. package/lib/modal/index.js +5 -36
  229. package/lib/modal/index.min.js +1 -1
  230. package/lib/modal/src/modal.js +128 -315
  231. package/lib/modal/src/modal.min.js +1 -1
  232. package/lib/modal/style/style.css +311 -247
  233. package/lib/modal/style/style.min.css +1 -1
  234. package/lib/optgroup/index.js +1 -7
  235. package/lib/optgroup/index.min.js +1 -1
  236. package/lib/optgroup/style/style.css +1 -1
  237. package/lib/option/index.js +1 -7
  238. package/lib/option/index.min.js +1 -1
  239. package/lib/option/style/style.css +1 -1
  240. package/lib/pager/index.js +1 -7
  241. package/lib/pager/index.min.js +1 -1
  242. package/lib/pager/src/pager.js +74 -151
  243. package/lib/pager/src/pager.min.js +1 -1
  244. package/lib/pager/style/style.css +307 -257
  245. package/lib/pager/style/style.min.css +1 -1
  246. package/lib/pulldown/index.js +1 -7
  247. package/lib/pulldown/index.min.js +1 -1
  248. package/lib/pulldown/src/pulldown.js +46 -90
  249. package/lib/pulldown/src/pulldown.min.js +1 -1
  250. package/lib/pulldown/style/style.css +42 -31
  251. package/lib/pulldown/style/style.min.css +1 -1
  252. package/lib/radio/index.js +1 -7
  253. package/lib/radio/index.min.js +1 -1
  254. package/lib/radio/src/button.js +14 -32
  255. package/lib/radio/src/button.min.js +1 -1
  256. package/lib/radio/src/group.js +11 -22
  257. package/lib/radio/src/group.min.js +1 -1
  258. package/lib/radio/src/radio.js +15 -34
  259. package/lib/radio/src/radio.min.js +1 -1
  260. package/lib/radio/style/style.css +184 -151
  261. package/lib/radio/style/style.min.css +1 -1
  262. package/lib/radio-button/index.js +1 -7
  263. package/lib/radio-button/index.min.js +1 -1
  264. package/lib/radio-button/style/style.css +1 -1
  265. package/lib/radio-group/index.js +1 -7
  266. package/lib/radio-group/index.min.js +1 -1
  267. package/lib/radio-group/style/style.css +1 -1
  268. package/lib/select/index.js +1 -7
  269. package/lib/select/index.min.js +1 -1
  270. package/lib/select/src/optgroup.js +1 -5
  271. package/lib/select/src/option.js +1 -5
  272. package/lib/select/src/optionInfo.js +1 -9
  273. package/lib/select/src/select.js +103 -256
  274. package/lib/select/src/select.min.js +1 -1
  275. package/lib/select/src/util.js +0 -13
  276. package/lib/select/src/util.min.js +1 -1
  277. package/lib/select/style/style.css +108 -79
  278. package/lib/select/style/style.min.css +1 -1
  279. package/lib/style.css +1 -1
  280. package/lib/style.min.css +1 -1
  281. package/lib/switch/index.js +1 -7
  282. package/lib/switch/index.min.js +1 -1
  283. package/lib/switch/src/switch.js +16 -35
  284. package/lib/switch/src/switch.min.js +1 -1
  285. package/lib/switch/style/style.css +87 -67
  286. package/lib/switch/style/style.min.css +1 -1
  287. package/lib/table/index.js +1 -7
  288. package/lib/table/index.min.js +1 -1
  289. package/lib/table/src/body.js +143 -262
  290. package/lib/table/src/body.min.js +1 -1
  291. package/lib/table/src/cell.js +138 -259
  292. package/lib/table/src/cell.min.js +1 -1
  293. package/lib/table/src/column.js +4 -13
  294. package/lib/table/src/column.min.js +1 -1
  295. package/lib/table/src/columnInfo.js +6 -35
  296. package/lib/table/src/columnInfo.min.js +1 -1
  297. package/lib/table/src/group.js +2 -15
  298. package/lib/table/src/group.min.js +1 -1
  299. package/lib/table/src/props.js +25 -29
  300. package/lib/table/src/props.min.js +1 -1
  301. package/lib/table/src/table.js +650 -1593
  302. package/lib/table/src/table.min.js +1 -1
  303. package/lib/table/src/util.js +32 -102
  304. package/lib/table/src/util.min.js +1 -1
  305. package/lib/table/style/style.css +1025 -835
  306. package/lib/table/style/style.min.css +1 -1
  307. package/lib/textarea/index.js +1 -7
  308. package/lib/textarea/index.min.js +1 -1
  309. package/lib/textarea/src/textarea.js +31 -71
  310. package/lib/textarea/src/textarea.min.js +1 -1
  311. package/lib/textarea/style/style.css +57 -41
  312. package/lib/textarea/style/style.min.css +1 -1
  313. package/lib/toolbar/index.js +1 -7
  314. package/lib/toolbar/index.min.js +1 -1
  315. package/lib/toolbar/src/toolbar.js +60 -167
  316. package/lib/toolbar/src/toolbar.min.js +1 -1
  317. package/lib/toolbar/style/style.css +216 -174
  318. package/lib/toolbar/style/style.min.css +1 -1
  319. package/lib/tools/dom.js +6 -48
  320. package/lib/tools/dom.min.js +1 -1
  321. package/lib/tools/event.js +8 -20
  322. package/lib/tools/event.min.js +1 -1
  323. package/lib/tools/log.js +1 -6
  324. package/lib/tools/log.min.js +1 -1
  325. package/lib/tools/resize.js +3 -27
  326. package/lib/tools/utils.js +0 -16
  327. package/lib/tools/utils.min.js +1 -1
  328. package/lib/tools/vn.js +0 -5
  329. package/lib/tooltip/index.js +1 -8
  330. package/lib/tooltip/index.min.js +1 -1
  331. package/lib/tooltip/src/tooltip.js +47 -111
  332. package/lib/tooltip/src/tooltip.min.js +1 -1
  333. package/lib/tooltip/style/style.css +87 -63
  334. package/lib/v-x-e-table/index.js +13 -44
  335. package/lib/v-x-e-table/index.min.js +1 -1
  336. package/lib/v-x-e-table/src/commands.js +0 -4
  337. package/lib/v-x-e-table/src/conf.js +31 -19
  338. package/lib/v-x-e-table/src/formats.js +0 -4
  339. package/lib/v-x-e-table/src/hooks.js +0 -3
  340. package/lib/v-x-e-table/src/interceptor.js +6 -18
  341. package/lib/v-x-e-table/src/interceptor.min.js +1 -1
  342. package/lib/v-x-e-table/src/menus.js +0 -4
  343. package/lib/v-x-e-table/src/renderer.js +66 -199
  344. package/lib/v-x-e-table/src/renderer.min.js +1 -1
  345. package/lib/v-x-e-table/src/setup.js +1 -6
  346. package/lib/v-x-e-table/src/store.js +3 -19
  347. package/lib/v-x-e-table/style/style.css +424 -243
  348. package/lib/v-x-e-table/style/style.min.css +1 -1
  349. package/lib/validator/index.js +1 -5
  350. package/lib/validator/index.min.js +1 -1
  351. package/lib/validator/src/hook.js +50 -116
  352. package/lib/validator/src/hook.min.js +1 -1
  353. package/lib/validator/style/style.css +1 -1
  354. package/lib/vxe-button/index.js +3 -10
  355. package/lib/vxe-button/index.min.js +1 -1
  356. package/lib/vxe-button/style/style.css +465 -341
  357. package/lib/vxe-button/style/style.min.css +1 -1
  358. package/lib/vxe-checkbox/index.js +3 -10
  359. package/lib/vxe-checkbox/index.min.js +1 -1
  360. package/lib/vxe-checkbox/style/style.css +156 -127
  361. package/lib/vxe-checkbox/style/style.min.css +1 -1
  362. package/lib/vxe-checkbox-group/index.js +3 -10
  363. package/lib/vxe-checkbox-group/index.min.js +1 -1
  364. package/lib/vxe-checkbox-group/style/style.css +1 -1
  365. package/lib/vxe-colgroup/index.js +3 -10
  366. package/lib/vxe-colgroup/index.min.js +1 -1
  367. package/lib/vxe-colgroup/style/style.css +1 -1
  368. package/lib/vxe-column/index.js +3 -10
  369. package/lib/vxe-column/index.min.js +1 -1
  370. package/lib/vxe-column/style/style.css +1 -1
  371. package/lib/vxe-form/index.js +3 -10
  372. package/lib/vxe-form/index.min.js +1 -1
  373. package/lib/vxe-form/style/style.css +201 -168
  374. package/lib/vxe-form/style/style.min.css +1 -1
  375. package/lib/vxe-form-gather/index.js +3 -10
  376. package/lib/vxe-form-gather/index.min.js +1 -1
  377. package/lib/vxe-form-gather/style/style.css +1 -1
  378. package/lib/vxe-form-item/index.js +3 -10
  379. package/lib/vxe-form-item/index.min.js +1 -1
  380. package/lib/vxe-form-item/style/style.css +1 -1
  381. package/lib/vxe-grid/index.js +3 -10
  382. package/lib/vxe-grid/index.min.js +1 -1
  383. package/lib/vxe-grid/style/style.css +61 -50
  384. package/lib/vxe-grid/style/style.min.css +1 -1
  385. package/lib/vxe-icon/index.js +3 -10
  386. package/lib/vxe-icon/index.min.js +1 -1
  387. package/lib/vxe-icon/style/style.css +372 -195
  388. package/lib/vxe-icon/style/style.min.css +1 -1
  389. package/lib/vxe-input/index.js +3 -10
  390. package/lib/vxe-input/index.min.js +1 -1
  391. package/lib/vxe-input/style/style.css +771 -595
  392. package/lib/vxe-input/style/style.min.css +1 -1
  393. package/lib/vxe-list/index.js +3 -10
  394. package/lib/vxe-list/index.min.js +1 -1
  395. package/lib/vxe-list/style/style.css +19 -14
  396. package/lib/vxe-loading/index.js +3 -10
  397. package/lib/vxe-loading/index.min.js +1 -1
  398. package/lib/vxe-loading/style/style.css +52 -48
  399. package/lib/vxe-loading/style/style.min.css +1 -1
  400. package/lib/vxe-modal/index.js +3 -10
  401. package/lib/vxe-modal/index.min.js +1 -1
  402. package/lib/vxe-modal/style/style.css +311 -247
  403. package/lib/vxe-modal/style/style.min.css +1 -1
  404. package/lib/vxe-module-edit/index.js +3 -10
  405. package/lib/vxe-module-edit/index.min.js +1 -1
  406. package/lib/vxe-module-edit/style/style.css +1 -1
  407. package/lib/vxe-module-export/index.js +3 -10
  408. package/lib/vxe-module-export/index.min.js +1 -1
  409. package/lib/vxe-module-export/style/style.css +136 -108
  410. package/lib/vxe-module-export/style/style.min.css +1 -1
  411. package/lib/vxe-module-filter/index.js +3 -10
  412. package/lib/vxe-module-filter/index.min.js +1 -1
  413. package/lib/vxe-module-filter/style/style.css +103 -82
  414. package/lib/vxe-module-filter/style/style.min.css +1 -1
  415. package/lib/vxe-module-keyboard/index.js +3 -10
  416. package/lib/vxe-module-keyboard/index.min.js +1 -1
  417. package/lib/vxe-module-keyboard/style/style.css +1 -1
  418. package/lib/vxe-module-menu/index.js +3 -10
  419. package/lib/vxe-module-menu/index.min.js +1 -1
  420. package/lib/vxe-module-menu/style/style.css +79 -59
  421. package/lib/vxe-module-menu/style/style.min.css +1 -1
  422. package/lib/vxe-module-validator/index.js +3 -10
  423. package/lib/vxe-module-validator/index.min.js +1 -1
  424. package/lib/vxe-module-validator/style/style.css +1 -1
  425. package/lib/vxe-optgroup/index.js +3 -10
  426. package/lib/vxe-optgroup/index.min.js +1 -1
  427. package/lib/vxe-optgroup/style/style.css +1 -1
  428. package/lib/vxe-option/index.js +3 -10
  429. package/lib/vxe-option/index.min.js +1 -1
  430. package/lib/vxe-option/style/style.css +1 -1
  431. package/lib/vxe-pager/index.js +3 -10
  432. package/lib/vxe-pager/index.min.js +1 -1
  433. package/lib/vxe-pager/style/style.css +307 -257
  434. package/lib/vxe-pager/style/style.min.css +1 -1
  435. package/lib/vxe-pulldown/index.js +3 -10
  436. package/lib/vxe-pulldown/index.min.js +1 -1
  437. package/lib/vxe-pulldown/style/style.css +42 -31
  438. package/lib/vxe-pulldown/style/style.min.css +1 -1
  439. package/lib/vxe-radio/index.js +3 -10
  440. package/lib/vxe-radio/index.min.js +1 -1
  441. package/lib/vxe-radio/style/style.css +184 -151
  442. package/lib/vxe-radio/style/style.min.css +1 -1
  443. package/lib/vxe-radio-button/index.js +3 -10
  444. package/lib/vxe-radio-button/index.min.js +1 -1
  445. package/lib/vxe-radio-button/style/style.css +1 -1
  446. package/lib/vxe-radio-group/index.js +3 -10
  447. package/lib/vxe-radio-group/index.min.js +1 -1
  448. package/lib/vxe-radio-group/style/style.css +1 -1
  449. package/lib/vxe-select/index.js +3 -10
  450. package/lib/vxe-select/index.min.js +1 -1
  451. package/lib/vxe-select/style/style.css +108 -79
  452. package/lib/vxe-select/style/style.min.css +1 -1
  453. package/lib/vxe-switch/index.js +3 -10
  454. package/lib/vxe-switch/index.min.js +1 -1
  455. package/lib/vxe-switch/style/style.css +87 -67
  456. package/lib/vxe-switch/style/style.min.css +1 -1
  457. package/lib/vxe-table/index.js +3 -10
  458. package/lib/vxe-table/index.min.js +1 -1
  459. package/lib/vxe-table/style/style.css +1025 -835
  460. package/lib/vxe-table/style/style.min.css +1 -1
  461. package/lib/vxe-textarea/index.js +3 -10
  462. package/lib/vxe-textarea/index.min.js +1 -1
  463. package/lib/vxe-textarea/style/style.css +57 -41
  464. package/lib/vxe-textarea/style/style.min.css +1 -1
  465. package/lib/vxe-toolbar/index.js +3 -10
  466. package/lib/vxe-toolbar/index.min.js +1 -1
  467. package/lib/vxe-toolbar/style/style.css +216 -174
  468. package/lib/vxe-toolbar/style/style.min.css +1 -1
  469. package/lib/vxe-tooltip/index.js +3 -10
  470. package/lib/vxe-tooltip/index.min.js +1 -1
  471. package/lib/vxe-tooltip/style/style.css +87 -63
  472. package/package.json +27 -33
  473. package/packages/export/src/hook.ts +1 -0
  474. package/packages/filter/src/hook.ts +1 -1
  475. package/packages/form/src/form.ts +5 -4
  476. package/packages/list/src/list.ts +8 -2
  477. package/packages/pulldown/src/pulldown.ts +11 -5
  478. package/packages/table/src/column.ts +2 -0
  479. package/packages/table/src/columnInfo.ts +1 -0
  480. package/packages/table/src/table.ts +95 -87
  481. package/packages/table/src/util.ts +1 -1
  482. package/styles/icon/iconfont.ttf +0 -0
  483. package/styles/icon/iconfont.woff +0 -0
  484. package/styles/icon/iconfont.woff2 +0 -0
  485. package/styles/icon.scss +10 -2
  486. package/styles/table.scss +1 -1
  487. package/styles/variable.scss +2 -2
  488. package/types/column.d.ts +6 -1
  489. package/types/list.d.ts +4 -4
  490. package/types/pulldown.d.ts +61 -61
  491. package/types/table.d.ts +11 -1
@@ -4,34 +4,22 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
-
8
7
  var _vue = require("vue");
9
-
10
8
  var _xeUtils = _interopRequireDefault(require("xe-utils"));
11
-
12
9
  var _conf = _interopRequireDefault(require("../../v-x-e-table/src/conf"));
13
-
14
10
  var _vXETable = require("../../v-x-e-table");
15
-
16
11
  var _util = require("../../table/src/util");
17
-
18
12
  var _utils = require("../../tools/utils");
19
-
20
13
  var _log = require("../../tools/log");
21
-
22
14
  var _util2 = require("./util");
23
-
24
15
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
25
-
26
16
  var htmlCellElem;
27
- var csvBOM = "\uFEFF";
17
+ var csvBOM = '\ufeff';
28
18
  var enterSymbol = '\r\n';
29
-
30
19
  function defaultFilterExportColumn(column) {
31
20
  return column.property || ['seq', 'checkbox', 'radio'].indexOf(column.type) > -1;
32
21
  }
33
-
34
- var getConvertColumns = function getConvertColumns(columns) {
22
+ var getConvertColumns = function (columns) {
35
23
  var result = [];
36
24
  columns.forEach(function (column) {
37
25
  if (column.childNodes && column.childNodes.length) {
@@ -43,19 +31,15 @@ var getConvertColumns = function getConvertColumns(columns) {
43
31
  });
44
32
  return result;
45
33
  };
46
-
47
- var convertToRows = function convertToRows(originColumns) {
34
+ var convertToRows = function (originColumns) {
48
35
  var maxLevel = 1;
49
-
50
- var traverse = function traverse(column, parent) {
36
+ var traverse = function (column, parent) {
51
37
  if (parent) {
52
38
  column._level = parent._level + 1;
53
-
54
39
  if (maxLevel < column._level) {
55
40
  maxLevel = column._level;
56
41
  }
57
42
  }
58
-
59
43
  if (column.childNodes && column.childNodes.length) {
60
44
  var colSpan_1 = 0;
61
45
  column.childNodes.forEach(function (subColumn) {
@@ -67,17 +51,14 @@ var convertToRows = function convertToRows(originColumns) {
67
51
  column._colSpan = 1;
68
52
  }
69
53
  };
70
-
71
54
  originColumns.forEach(function (column) {
72
55
  column._level = 1;
73
56
  traverse(column);
74
57
  });
75
58
  var rows = [];
76
-
77
59
  for (var i = 0; i < maxLevel; i++) {
78
60
  rows.push([]);
79
61
  }
80
-
81
62
  var allColumns = getConvertColumns(originColumns);
82
63
  allColumns.forEach(function (column) {
83
64
  if (column.childNodes && column.childNodes.length) {
@@ -85,32 +66,25 @@ var convertToRows = function convertToRows(originColumns) {
85
66
  } else {
86
67
  column._rowSpan = maxLevel - column._level + 1;
87
68
  }
88
-
89
69
  rows[column._level - 1].push(column);
90
70
  });
91
71
  return rows;
92
72
  };
93
-
94
73
  function toTableBorder(border) {
95
74
  if (border === true) {
96
75
  return 'full';
97
76
  }
98
-
99
77
  if (border) {
100
78
  return border;
101
79
  }
102
-
103
80
  return 'default';
104
81
  }
105
-
106
82
  function getBooleanValue(cellValue) {
107
83
  return cellValue === 'TRUE' || cellValue === 'true' || cellValue === true;
108
84
  }
109
-
110
85
  function getHeaderTitle(opts, column) {
111
86
  return (opts.original ? column.property : column.getTitle()) || '';
112
87
  }
113
-
114
88
  function getFooterData(opts, footerTableData) {
115
89
  var footerFilterMethod = opts.footerFilterMethod;
116
90
  return footerFilterMethod ? footerTableData.filter(function (items, index) {
@@ -120,70 +94,55 @@ function getFooterData(opts, footerTableData) {
120
94
  });
121
95
  }) : footerTableData;
122
96
  }
123
-
124
97
  function getCsvCellTypeLabel(column, cellValue) {
125
98
  if (cellValue) {
126
99
  if (column.type === 'seq') {
127
100
  return "\t".concat(cellValue);
128
101
  }
129
-
130
102
  switch (column.cellType) {
131
103
  case 'string':
132
104
  if (!isNaN(cellValue)) {
133
105
  return "\t".concat(cellValue);
134
106
  }
135
-
136
107
  break;
137
-
138
108
  case 'number':
139
109
  break;
140
-
141
110
  default:
142
111
  if (cellValue.length >= 12 && !isNaN(cellValue)) {
143
112
  return "\t".concat(cellValue);
144
113
  }
145
-
146
114
  break;
147
115
  }
148
116
  }
149
-
150
117
  return cellValue;
151
118
  }
152
-
153
119
  function toTxtCellLabel(val) {
154
120
  if (/[",\s\n]/.test(val)) {
155
121
  return "\"".concat(val.replace(/"/g, '""'), "\"");
156
122
  }
157
-
158
123
  return val;
159
124
  }
160
-
161
125
  function getElementsByTagName(elem, qualifiedName) {
162
126
  return elem.getElementsByTagName(qualifiedName);
163
127
  }
164
-
165
128
  function getTxtCellKey(now) {
166
129
  return "#".concat(now, "@").concat(_xeUtils.default.uniqueId());
167
130
  }
168
-
169
131
  function replaceTxtCell(cell, vMaps) {
170
132
  return cell.replace(/#\d+@\d+/g, function (key) {
171
133
  return _xeUtils.default.hasOwnProp(vMaps, key) ? vMaps[key] : key;
172
134
  });
173
135
  }
174
-
175
136
  function getTxtCellValue(val, vMaps) {
176
137
  var rest = replaceTxtCell(val, vMaps);
177
138
  return rest.replace(/^"+$/g, function (qVal) {
178
139
  return '"'.repeat(Math.ceil(qVal.length / 2));
179
140
  });
180
141
  }
181
-
182
142
  function parseCsvAndTxt(columns, content, cellSeparator) {
183
143
  var list = content.split(enterSymbol);
184
144
  var rows = [];
185
145
  var fields = [];
186
-
187
146
  if (list.length) {
188
147
  var vMaps_1 = {};
189
148
  var now_1 = Date.now();
@@ -200,7 +159,6 @@ function parseCsvAndTxt(columns, content, cellSeparator) {
200
159
  return key;
201
160
  });
202
161
  var cells = rVal.split(cellSeparator);
203
-
204
162
  if (!fields.length) {
205
163
  fields = cells.map(function (val) {
206
164
  return getTxtCellValue(val.trim(), vMaps_1);
@@ -216,108 +174,87 @@ function parseCsvAndTxt(columns, content, cellSeparator) {
216
174
  }
217
175
  });
218
176
  }
219
-
220
177
  return {
221
178
  fields: fields,
222
179
  rows: rows
223
180
  };
224
181
  }
225
-
226
182
  function parseCsv(columns, content) {
227
183
  return parseCsvAndTxt(columns, content, ',');
228
184
  }
229
-
230
185
  function parseTxt(columns, content) {
231
186
  return parseCsvAndTxt(columns, content, '\t');
232
187
  }
233
-
234
188
  function parseHTML(columns, content) {
235
189
  var domParser = new DOMParser();
236
190
  var xmlDoc = domParser.parseFromString(content, 'text/html');
237
191
  var bodyNodes = getElementsByTagName(xmlDoc, 'body');
238
192
  var rows = [];
239
193
  var fields = [];
240
-
241
194
  if (bodyNodes.length) {
242
195
  var tableNodes = getElementsByTagName(bodyNodes[0], 'table');
243
-
244
196
  if (tableNodes.length) {
245
197
  var theadNodes = getElementsByTagName(tableNodes[0], 'thead');
246
-
247
198
  if (theadNodes.length) {
248
199
  _xeUtils.default.arrayEach(getElementsByTagName(theadNodes[0], 'tr'), function (rowNode) {
249
200
  _xeUtils.default.arrayEach(getElementsByTagName(rowNode, 'th'), function (cellNode) {
250
201
  fields.push(cellNode.textContent);
251
202
  });
252
203
  });
253
-
254
204
  var tbodyNodes = getElementsByTagName(tableNodes[0], 'tbody');
255
-
256
205
  if (tbodyNodes.length) {
257
206
  _xeUtils.default.arrayEach(getElementsByTagName(tbodyNodes[0], 'tr'), function (rowNode) {
258
207
  var item = {};
259
-
260
208
  _xeUtils.default.arrayEach(getElementsByTagName(rowNode, 'td'), function (cellNode, colIndex) {
261
209
  if (fields[colIndex]) {
262
210
  item[fields[colIndex]] = cellNode.textContent || '';
263
211
  }
264
212
  });
265
-
266
213
  rows.push(item);
267
214
  });
268
215
  }
269
216
  }
270
217
  }
271
218
  }
272
-
273
219
  return {
274
220
  fields: fields,
275
221
  rows: rows
276
222
  };
277
223
  }
278
-
279
224
  function parseXML(columns, content) {
280
225
  var domParser = new DOMParser();
281
226
  var xmlDoc = domParser.parseFromString(content, 'application/xml');
282
227
  var sheetNodes = getElementsByTagName(xmlDoc, 'Worksheet');
283
228
  var rows = [];
284
229
  var fields = [];
285
-
286
230
  if (sheetNodes.length) {
287
231
  var tableNodes = getElementsByTagName(sheetNodes[0], 'Table');
288
-
289
232
  if (tableNodes.length) {
290
233
  var rowNodes = getElementsByTagName(tableNodes[0], 'Row');
291
-
292
234
  if (rowNodes.length) {
293
235
  _xeUtils.default.arrayEach(getElementsByTagName(rowNodes[0], 'Cell'), function (cellNode) {
294
236
  fields.push(cellNode.textContent);
295
237
  });
296
-
297
238
  _xeUtils.default.arrayEach(rowNodes, function (rowNode, index) {
298
239
  if (index) {
299
240
  var item_2 = {};
300
241
  var cellNodes = getElementsByTagName(rowNode, 'Cell');
301
-
302
242
  _xeUtils.default.arrayEach(cellNodes, function (cellNode, colIndex) {
303
243
  if (fields[colIndex]) {
304
244
  item_2[fields[colIndex]] = cellNode.textContent;
305
245
  }
306
246
  });
307
-
308
247
  rows.push(item_2);
309
248
  }
310
249
  });
311
250
  }
312
251
  }
313
252
  }
314
-
315
253
  return {
316
254
  fields: fields,
317
255
  rows: rows
318
256
  };
319
257
  }
320
-
321
258
  function clearColumnConvert(columns) {
322
259
  _xeUtils.default.eachTree(columns, function (column) {
323
260
  delete column._level;
@@ -334,13 +271,10 @@ function clearColumnConvert(columns) {
334
271
  * @param {Array} fields 字段名列表
335
272
  * @param {Array} rows 数据列表
336
273
  */
337
-
338
-
339
274
  function checkImportData(columns, fields) {
340
275
  var tableFields = [];
341
276
  columns.forEach(function (column) {
342
277
  var field = column.property;
343
-
344
278
  if (field) {
345
279
  tableFields.push(field);
346
280
  }
@@ -349,35 +283,29 @@ function checkImportData(columns, fields) {
349
283
  return tableFields.indexOf(field) > -1;
350
284
  });
351
285
  }
352
-
353
286
  var tableExportMethodKeys = ['exportData', 'importByFile', 'importData', 'saveFile', 'readFile', 'print', 'openImport', 'openExport', 'openPrint'];
354
287
  var tableExportHook = {
355
- setupTable: function setupTable($xetable) {
288
+ setupTable: function ($xetable) {
356
289
  var props = $xetable.props,
357
- reactData = $xetable.reactData,
358
- internalData = $xetable.internalData;
359
-
290
+ reactData = $xetable.reactData,
291
+ internalData = $xetable.internalData;
360
292
  var _a = $xetable.getComputeMaps(),
361
- computeTreeOpts = _a.computeTreeOpts,
362
- computePrintOpts = _a.computePrintOpts,
363
- computeExportOpts = _a.computeExportOpts,
364
- computeImportOpts = _a.computeImportOpts,
365
- computeCustomOpts = _a.computeCustomOpts,
366
- computeSeqOpts = _a.computeSeqOpts,
367
- computeRadioOpts = _a.computeRadioOpts,
368
- computeCheckboxOpts = _a.computeCheckboxOpts;
369
-
293
+ computeTreeOpts = _a.computeTreeOpts,
294
+ computePrintOpts = _a.computePrintOpts,
295
+ computeExportOpts = _a.computeExportOpts,
296
+ computeImportOpts = _a.computeImportOpts,
297
+ computeCustomOpts = _a.computeCustomOpts,
298
+ computeSeqOpts = _a.computeSeqOpts,
299
+ computeRadioOpts = _a.computeRadioOpts,
300
+ computeCheckboxOpts = _a.computeCheckboxOpts;
370
301
  var $xegrid = (0, _vue.inject)('$xegrid', null);
371
-
372
- var hasTreeChildren = function hasTreeChildren(row) {
302
+ var hasTreeChildren = function (row) {
373
303
  var treeOpts = computeTreeOpts.value;
374
304
  return row[treeOpts.children] && row[treeOpts.children].length;
375
305
  };
376
-
377
- var getSeq = function getSeq(row, $rowIndex, column, $columnIndex) {
306
+ var getSeq = function (row, $rowIndex, column, $columnIndex) {
378
307
  var seqOpts = computeSeqOpts.value;
379
308
  var seqMethod = seqOpts.seqMethod || column.seqMethod;
380
-
381
309
  if (seqMethod) {
382
310
  return seqMethod({
383
311
  row: row,
@@ -388,35 +316,28 @@ var tableExportHook = {
388
316
  $columnIndex: $columnIndex
389
317
  });
390
318
  }
391
-
392
319
  return $xetable.getRowSeq(row);
393
320
  };
394
-
395
- var toBooleanValue = function toBooleanValue(cellValue) {
321
+ var toBooleanValue = function (cellValue) {
396
322
  return _xeUtils.default.isBoolean(cellValue) ? cellValue ? 'TRUE' : 'FALSE' : cellValue;
397
323
  };
398
-
399
- var getLabelData = function getLabelData(opts, columns, datas) {
324
+ var getLabelData = function (opts, columns, datas) {
400
325
  var isAllExpand = opts.isAllExpand,
401
- mode = opts.mode;
326
+ mode = opts.mode;
402
327
  var treeConfig = props.treeConfig;
403
328
  var radioOpts = computeRadioOpts.value;
404
329
  var checkboxOpts = computeCheckboxOpts.value;
405
330
  var treeOpts = computeTreeOpts.value;
406
-
407
331
  if (!htmlCellElem) {
408
332
  htmlCellElem = document.createElement('div');
409
333
  }
410
-
411
334
  if (treeConfig) {
412
335
  // 如果是树表格只允许导出数据源
413
336
  var rest_1 = [];
414
337
  var expandMaps_1 = new Map();
415
-
416
338
  _xeUtils.default.eachTree(datas, function (item, $rowIndex, items, path, parent, nodes) {
417
339
  var row = item._row || item;
418
340
  var parentRow = parent && parent._row ? parent._row : parent;
419
-
420
341
  if (isAllExpand || !parentRow || expandMaps_1.has(parentRow) && $xetable.isTreeExpandByRow(parentRow)) {
421
342
  var hasRowChild = hasTreeChildren(row);
422
343
  var item_3 = {
@@ -429,15 +350,12 @@ var tableExportHook = {
429
350
  var cellValue = '';
430
351
  var renderOpts = column.editRender || column.cellRender;
431
352
  var exportLabelMethod = column.exportMethod;
432
-
433
353
  if (!exportLabelMethod && renderOpts && renderOpts.name) {
434
354
  var compConf = _vXETable.VXETable.renderer.get(renderOpts.name);
435
-
436
355
  if (compConf) {
437
356
  exportLabelMethod = compConf.exportMethod;
438
357
  }
439
358
  }
440
-
441
359
  if (exportLabelMethod) {
442
360
  cellValue = exportLabelMethod({
443
361
  $table: $xetable,
@@ -452,7 +370,6 @@ var tableExportHook = {
452
370
  return i % 2 === 0 ? Number(num) + 1 : '.';
453
371
  }).join('') : getSeq(row, $rowIndex, column, $columnIndex);
454
372
  break;
455
-
456
373
  case 'checkbox':
457
374
  cellValue = toBooleanValue($xetable.isCheckedByCheckboxRow(row));
458
375
  item_3._checkboxLabel = checkboxOpts.labelField ? _xeUtils.default.get(row, checkboxOpts.labelField) : '';
@@ -460,7 +377,6 @@ var tableExportHook = {
460
377
  row: row
461
378
  });
462
379
  break;
463
-
464
380
  case 'radio':
465
381
  cellValue = toBooleanValue($xetable.isCheckedByRadioRow(row));
466
382
  item_3._radioLabel = radioOpts.labelField ? _xeUtils.default.get(row, radioOpts.labelField) : '';
@@ -468,38 +384,31 @@ var tableExportHook = {
468
384
  row: row
469
385
  });
470
386
  break;
471
-
472
387
  default:
473
388
  if (opts.original) {
474
389
  cellValue = (0, _util.getCellValue)(row, column);
475
390
  } else {
476
391
  cellValue = $xetable.getCellLabel(row, column);
477
-
478
392
  if (column.type === 'html') {
479
393
  htmlCellElem.innerHTML = cellValue;
480
394
  cellValue = htmlCellElem.innerText.trim();
481
395
  } else {
482
396
  var cell = $xetable.getCell(row, column);
483
-
484
397
  if (cell) {
485
398
  cellValue = cell.innerText.trim();
486
399
  }
487
400
  }
488
401
  }
489
-
490
402
  }
491
403
  }
492
-
493
404
  item_3[column.id] = _xeUtils.default.toValueString(cellValue);
494
405
  });
495
406
  expandMaps_1.set(row, 1);
496
407
  rest_1.push(Object.assign(item_3, row));
497
408
  }
498
409
  }, treeOpts);
499
-
500
410
  return rest_1;
501
411
  }
502
-
503
412
  return datas.map(function (row, $rowIndex) {
504
413
  var item = {
505
414
  _row: row
@@ -508,15 +417,12 @@ var tableExportHook = {
508
417
  var cellValue = '';
509
418
  var renderOpts = column.editRender || column.cellRender;
510
419
  var exportLabelMethod = column.exportMethod;
511
-
512
420
  if (!exportLabelMethod && renderOpts && renderOpts.name) {
513
421
  var compConf = _vXETable.VXETable.renderer.get(renderOpts.name);
514
-
515
422
  if (compConf) {
516
423
  exportLabelMethod = compConf.exportMethod;
517
424
  }
518
425
  }
519
-
520
426
  if (exportLabelMethod) {
521
427
  cellValue = exportLabelMethod({
522
428
  $table: $xetable,
@@ -529,7 +435,6 @@ var tableExportHook = {
529
435
  case 'seq':
530
436
  cellValue = mode === 'all' ? $rowIndex + 1 : getSeq(row, $rowIndex, column, $columnIndex);
531
437
  break;
532
-
533
438
  case 'checkbox':
534
439
  cellValue = toBooleanValue($xetable.isCheckedByCheckboxRow(row));
535
440
  item._checkboxLabel = checkboxOpts.labelField ? _xeUtils.default.get(row, checkboxOpts.labelField) : '';
@@ -537,7 +442,6 @@ var tableExportHook = {
537
442
  row: row
538
443
  });
539
444
  break;
540
-
541
445
  case 'radio':
542
446
  cellValue = toBooleanValue($xetable.isCheckedByRadioRow(row));
543
447
  item._radioLabel = radioOpts.labelField ? _xeUtils.default.get(row, radioOpts.labelField) : '';
@@ -545,39 +449,32 @@ var tableExportHook = {
545
449
  row: row
546
450
  });
547
451
  break;
548
-
549
452
  default:
550
453
  if (opts.original) {
551
454
  cellValue = (0, _util.getCellValue)(row, column);
552
455
  } else {
553
456
  cellValue = $xetable.getCellLabel(row, column);
554
-
555
457
  if (column.type === 'html') {
556
458
  htmlCellElem.innerHTML = cellValue;
557
459
  cellValue = htmlCellElem.innerText.trim();
558
460
  } else {
559
461
  var cell = $xetable.getCell(row, column);
560
-
561
462
  if (cell) {
562
463
  cellValue = cell.innerText.trim();
563
464
  }
564
465
  }
565
466
  }
566
-
567
467
  }
568
468
  }
569
-
570
469
  item[column.id] = _xeUtils.default.toValueString(cellValue);
571
470
  });
572
471
  return item;
573
472
  });
574
473
  };
575
-
576
- var getExportData = function getExportData(opts) {
474
+ var getExportData = function (opts) {
577
475
  var columns = opts.columns,
578
- dataFilterMethod = opts.dataFilterMethod;
476
+ dataFilterMethod = opts.dataFilterMethod;
579
477
  var datas = opts.data;
580
-
581
478
  if (dataFilterMethod) {
582
479
  datas = datas.filter(function (row, index) {
583
480
  return dataFilterMethod({
@@ -586,24 +483,18 @@ var tableExportHook = {
586
483
  });
587
484
  });
588
485
  }
589
-
590
486
  return getLabelData(opts, columns, datas);
591
487
  };
592
-
593
- var getFooterCellValue = function getFooterCellValue(opts, items, column) {
488
+ var getFooterCellValue = function (opts, items, column) {
594
489
  var renderOpts = column.editRender || column.cellRender;
595
490
  var exportLabelMethod = column.footerExportMethod;
596
-
597
491
  if (!exportLabelMethod && renderOpts && renderOpts.name) {
598
492
  var compConf = _vXETable.VXETable.renderer.get(renderOpts.name);
599
-
600
493
  if (compConf) {
601
494
  exportLabelMethod = compConf.footerExportMethod;
602
495
  }
603
496
  }
604
-
605
497
  var _columnIndex = $xetable.getVTColumnIndex(column);
606
-
607
498
  var cellValue = exportLabelMethod ? exportLabelMethod({
608
499
  $table: $xetable,
609
500
  items: items,
@@ -614,22 +505,18 @@ var tableExportHook = {
614
505
  }) : _xeUtils.default.toValueString(items[_columnIndex]);
615
506
  return cellValue;
616
507
  };
617
-
618
- var toCsv = function toCsv(opts, columns, datas) {
508
+ var toCsv = function (opts, columns, datas) {
619
509
  var content = csvBOM;
620
-
621
510
  if (opts.isHeader) {
622
511
  content += columns.map(function (column) {
623
512
  return toTxtCellLabel(getHeaderTitle(opts, column));
624
513
  }).join(',') + enterSymbol;
625
514
  }
626
-
627
515
  datas.forEach(function (row) {
628
516
  content += columns.map(function (column) {
629
517
  return toTxtCellLabel(getCsvCellTypeLabel(column, row[column.id]));
630
518
  }).join(',') + enterSymbol;
631
519
  });
632
-
633
520
  if (opts.isFooter) {
634
521
  var footerTableData = reactData.footerTableData;
635
522
  var footers = getFooterData(opts, footerTableData);
@@ -639,25 +526,20 @@ var tableExportHook = {
639
526
  }).join(',') + enterSymbol;
640
527
  });
641
528
  }
642
-
643
529
  return content;
644
530
  };
645
-
646
- var toTxt = function toTxt(opts, columns, datas) {
531
+ var toTxt = function (opts, columns, datas) {
647
532
  var content = '';
648
-
649
533
  if (opts.isHeader) {
650
534
  content += columns.map(function (column) {
651
535
  return toTxtCellLabel(getHeaderTitle(opts, column));
652
536
  }).join('\t') + enterSymbol;
653
537
  }
654
-
655
538
  datas.forEach(function (row) {
656
539
  content += columns.map(function (column) {
657
540
  return toTxtCellLabel(row[column.id]);
658
541
  }).join('\t') + enterSymbol;
659
542
  });
660
-
661
543
  if (opts.isFooter) {
662
544
  var footerTableData = reactData.footerTableData;
663
545
  var footers = getFooterData(opts, footerTableData);
@@ -667,48 +549,43 @@ var tableExportHook = {
667
549
  }).join(',') + enterSymbol;
668
550
  });
669
551
  }
670
-
671
552
  return content;
672
553
  };
673
-
674
- var hasEllipsis = function hasEllipsis(column, property, allColumnOverflow) {
554
+ var hasEllipsis = function (column, property, allColumnOverflow) {
675
555
  var columnOverflow = column[property];
676
556
  var headOverflow = _xeUtils.default.isUndefined(columnOverflow) || _xeUtils.default.isNull(columnOverflow) ? allColumnOverflow : columnOverflow;
677
557
  var showEllipsis = headOverflow === 'ellipsis';
678
558
  var showTitle = headOverflow === 'title';
679
559
  var showTooltip = headOverflow === true || headOverflow === 'tooltip';
680
- var isEllipsis = showTitle || showTooltip || showEllipsis; // 虚拟滚动不支持动态高度
681
-
560
+ var isEllipsis = showTitle || showTooltip || showEllipsis;
561
+ // 虚拟滚动不支持动态高度
682
562
  var scrollXLoad = reactData.scrollXLoad,
683
- scrollYLoad = reactData.scrollYLoad;
684
-
563
+ scrollYLoad = reactData.scrollYLoad;
685
564
  if ((scrollXLoad || scrollYLoad) && !isEllipsis) {
686
565
  isEllipsis = true;
687
566
  }
688
-
689
567
  return isEllipsis;
690
568
  };
691
-
692
- var toHtml = function toHtml(opts, columns, datas) {
569
+ var toHtml = function (opts, columns, datas) {
693
570
  var id = props.id,
694
- border = props.border,
695
- treeConfig = props.treeConfig,
696
- allHeaderAlign = props.headerAlign,
697
- allAlign = props.align,
698
- allFooterAlign = props.footerAlign,
699
- allColumnOverflow = props.showOverflow,
700
- allColumnHeaderOverflow = props.showHeaderOverflow;
571
+ border = props.border,
572
+ treeConfig = props.treeConfig,
573
+ allHeaderAlign = props.headerAlign,
574
+ allAlign = props.align,
575
+ allFooterAlign = props.footerAlign,
576
+ allColumnOverflow = props.showOverflow,
577
+ allColumnHeaderOverflow = props.showHeaderOverflow;
701
578
  var isAllSelected = reactData.isAllSelected,
702
- isIndeterminate = reactData.isIndeterminate,
703
- mergeList = reactData.mergeList;
579
+ isIndeterminate = reactData.isIndeterminate,
580
+ mergeList = reactData.mergeList;
704
581
  var treeOpts = computeTreeOpts.value;
705
582
  var isPrint = opts.print,
706
- isHeader = opts.isHeader,
707
- isFooter = opts.isFooter,
708
- isColgroup = opts.isColgroup,
709
- isMerge = opts.isMerge,
710
- colgroups = opts.colgroups,
711
- original = opts.original;
583
+ isHeader = opts.isHeader,
584
+ isFooter = opts.isFooter,
585
+ isColgroup = opts.isColgroup,
586
+ isMerge = opts.isMerge,
587
+ colgroups = opts.colgroups,
588
+ original = opts.original;
712
589
  var allCls = 'check-all';
713
590
  var clss = ['vxe-table', "border--".concat(toTableBorder(border)), isPrint ? 'is--print' : '', isHeader ? 'is--header' : ''].filter(function (cls) {
714
591
  return cls;
@@ -716,10 +593,8 @@ var tableExportHook = {
716
593
  var tables = ["<table class=\"".concat(clss.join(' '), "\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">"), "<colgroup>".concat(columns.map(function (column) {
717
594
  return "<col style=\"width:".concat(column.renderWidth, "px\">");
718
595
  }).join(''), "</colgroup>")];
719
-
720
596
  if (isHeader) {
721
597
  tables.push('<thead>');
722
-
723
598
  if (isColgroup && !original) {
724
599
  colgroups.forEach(function (cols) {
725
600
  tables.push("<tr>".concat(cols.map(function (column) {
@@ -728,27 +603,21 @@ var tableExportHook = {
728
603
  var cellTitle = getHeaderTitle(opts, column);
729
604
  var childWidth = 0;
730
605
  var countChild = 0;
731
-
732
606
  _xeUtils.default.eachTree([column], function (item) {
733
607
  if (!item.childNodes || !column.childNodes.length) {
734
608
  countChild++;
735
609
  }
736
-
737
610
  childWidth += item.renderWidth;
738
611
  }, {
739
612
  children: 'childNodes'
740
613
  });
741
-
742
614
  var cellWidth = childWidth - countChild;
743
-
744
615
  if (headAlign) {
745
616
  classNames.push("col--".concat(headAlign));
746
617
  }
747
-
748
618
  if (column.type === 'checkbox') {
749
619
  return "<th class=\"".concat(classNames.join(' '), "\" colspan=\"").concat(column._colSpan, "\" rowspan=\"").concat(column._rowSpan, "\"><div ").concat(isPrint ? '' : "style=\"width: ".concat(cellWidth, "px\""), "><input type=\"checkbox\" class=\"").concat(allCls, "\" ").concat(isAllSelected ? 'checked' : '', "><span>").concat(cellTitle, "</span></div></th>");
750
620
  }
751
-
752
621
  return "<th class=\"".concat(classNames.join(' '), "\" colspan=\"").concat(column._colSpan, "\" rowspan=\"").concat(column._rowSpan, "\" title=\"").concat(cellTitle, "\"><div ").concat(isPrint ? '' : "style=\"width: ".concat(cellWidth, "px\""), "><span>").concat((0, _utils.formatText)(cellTitle, true), "</span></div></th>");
753
622
  }).join(''), "</tr>"));
754
623
  });
@@ -757,60 +626,46 @@ var tableExportHook = {
757
626
  var headAlign = column.headerAlign || column.align || allHeaderAlign || allAlign;
758
627
  var classNames = hasEllipsis(column, 'showHeaderOverflow', allColumnHeaderOverflow) ? ['col--ellipsis'] : [];
759
628
  var cellTitle = getHeaderTitle(opts, column);
760
-
761
629
  if (headAlign) {
762
630
  classNames.push("col--".concat(headAlign));
763
631
  }
764
-
765
632
  if (column.type === 'checkbox') {
766
633
  return "<th class=\"".concat(classNames.join(' '), "\"><div ").concat(isPrint ? '' : "style=\"width: ".concat(column.renderWidth, "px\""), "><input type=\"checkbox\" class=\"").concat(allCls, "\" ").concat(isAllSelected ? 'checked' : '', "><span>").concat(cellTitle, "</span></div></th>");
767
634
  }
768
-
769
635
  return "<th class=\"".concat(classNames.join(' '), "\" title=\"").concat(cellTitle, "\"><div ").concat(isPrint ? '' : "style=\"width: ".concat(column.renderWidth, "px\""), "><span>").concat((0, _utils.formatText)(cellTitle, true), "</span></div></th>");
770
636
  }).join(''), "</tr>"));
771
637
  }
772
-
773
638
  tables.push('</thead>');
774
639
  }
775
-
776
640
  if (datas.length) {
777
641
  tables.push('<tbody>');
778
-
779
642
  if (treeConfig) {
780
643
  datas.forEach(function (item) {
781
644
  tables.push('<tr>' + columns.map(function (column) {
782
645
  var cellAlign = column.align || allAlign;
783
646
  var classNames = hasEllipsis(column, 'showOverflow', allColumnOverflow) ? ['col--ellipsis'] : [];
784
647
  var cellValue = item[column.id];
785
-
786
648
  if (cellAlign) {
787
649
  classNames.push("col--".concat(cellAlign));
788
650
  }
789
-
790
651
  if (column.treeNode) {
791
652
  var treeIcon = '';
792
-
793
653
  if (item._hasChild) {
794
654
  treeIcon = "<i class=\"".concat(item._expand ? 'vxe-table--tree-fold-icon' : 'vxe-table--tree-unfold-icon', "\"></i>");
795
655
  }
796
-
797
656
  classNames.push('vxe-table--tree-node');
798
-
799
657
  if (column.type === 'radio') {
800
658
  return "<td class=\"".concat(classNames.join(' '), "\" title=\"").concat(cellValue, "\"><div ").concat(isPrint ? '' : "style=\"width: ".concat(column.renderWidth, "px\""), "><div class=\"vxe-table--tree-node-wrapper\" style=\"padding-left: ").concat(item._level * treeOpts.indent, "px\"><div class=\"vxe-table--tree-icon-wrapper\">").concat(treeIcon, "</div><div class=\"vxe-table--tree-cell\"><input type=\"radio\" name=\"radio_").concat(id, "\" ").concat(item._radioDisabled ? 'disabled ' : '').concat(getBooleanValue(cellValue) ? 'checked' : '', "><span>").concat(item._radioLabel, "</span></div></div></div></td>");
801
659
  } else if (column.type === 'checkbox') {
802
660
  return "<td class=\"".concat(classNames.join(' '), "\" title=\"").concat(cellValue, "\"><div ").concat(isPrint ? '' : "style=\"width: ".concat(column.renderWidth, "px\""), "><div class=\"vxe-table--tree-node-wrapper\" style=\"padding-left: ").concat(item._level * treeOpts.indent, "px\"><div class=\"vxe-table--tree-icon-wrapper\">").concat(treeIcon, "</div><div class=\"vxe-table--tree-cell\"><input type=\"checkbox\" ").concat(item._checkboxDisabled ? 'disabled ' : '').concat(getBooleanValue(cellValue) ? 'checked' : '', "><span>").concat(item._checkboxLabel, "</span></div></div></div></td>");
803
661
  }
804
-
805
662
  return "<td class=\"".concat(classNames.join(' '), "\" title=\"").concat(cellValue, "\"><div ").concat(isPrint ? '' : "style=\"width: ".concat(column.renderWidth, "px\""), "><div class=\"vxe-table--tree-node-wrapper\" style=\"padding-left: ").concat(item._level * treeOpts.indent, "px\"><div class=\"vxe-table--tree-icon-wrapper\">").concat(treeIcon, "</div><div class=\"vxe-table--tree-cell\">").concat(cellValue, "</div></div></div></td>");
806
663
  }
807
-
808
664
  if (column.type === 'radio') {
809
665
  return "<td class=\"".concat(classNames.join(' '), "\"><div ").concat(isPrint ? '' : "style=\"width: ".concat(column.renderWidth, "px\""), "><input type=\"radio\" name=\"radio_").concat(id, "\" ").concat(item._radioDisabled ? 'disabled ' : '').concat(getBooleanValue(cellValue) ? 'checked' : '', "><span>").concat(item._radioLabel, "</span></div></td>");
810
666
  } else if (column.type === 'checkbox') {
811
667
  return "<td class=\"".concat(classNames.join(' '), "\"><div ").concat(isPrint ? '' : "style=\"width: ".concat(column.renderWidth, "px\""), "><input type=\"checkbox\" ").concat(item._checkboxDisabled ? 'disabled ' : '').concat(getBooleanValue(cellValue) ? 'checked' : '', "><span>").concat(item._checkboxLabel, "</span></div></td>");
812
668
  }
813
-
814
669
  return "<td class=\"".concat(classNames.join(' '), "\" title=\"").concat(cellValue, "\"><div ").concat(isPrint ? '' : "style=\"width: ".concat(column.renderWidth, "px\""), ">").concat((0, _utils.formatText)(cellValue, true), "</div></td>");
815
670
  }).join('') + '</tr>');
816
671
  });
@@ -822,54 +677,41 @@ var tableExportHook = {
822
677
  var cellValue = item[column.id];
823
678
  var rowSpan = 1;
824
679
  var colSpan = 1;
825
-
826
680
  if (isMerge && mergeList.length) {
827
681
  var _rowIndex = $xetable.getVTRowIndex(item._row);
828
-
829
682
  var _columnIndex = $xetable.getVTColumnIndex(column);
830
-
831
683
  var spanRest = (0, _util.mergeBodyMethod)(mergeList, _rowIndex, _columnIndex);
832
-
833
684
  if (spanRest) {
834
685
  var rowspan = spanRest.rowspan,
835
- colspan = spanRest.colspan;
836
-
686
+ colspan = spanRest.colspan;
837
687
  if (!rowspan || !colspan) {
838
688
  return '';
839
689
  }
840
-
841
690
  if (rowspan > 1) {
842
691
  rowSpan = rowspan;
843
692
  }
844
-
845
693
  if (colspan > 1) {
846
694
  colSpan = colspan;
847
695
  }
848
696
  }
849
697
  }
850
-
851
698
  if (cellAlign) {
852
699
  classNames.push("col--".concat(cellAlign));
853
700
  }
854
-
855
701
  if (column.type === 'radio') {
856
702
  return "<td class=\"".concat(classNames.join(' '), "\" rowspan=\"").concat(rowSpan, "\" colspan=\"").concat(colSpan, "\"><div ").concat(isPrint ? '' : "style=\"width: ".concat(column.renderWidth, "px\""), "><input type=\"radio\" name=\"radio_").concat(id, "\" ").concat(item._radioDisabled ? 'disabled ' : '').concat(getBooleanValue(cellValue) ? 'checked' : '', "><span>").concat(item._radioLabel, "</span></div></td>");
857
703
  } else if (column.type === 'checkbox') {
858
704
  return "<td class=\"".concat(classNames.join(' '), "\" rowspan=\"").concat(rowSpan, "\" colspan=\"").concat(colSpan, "\"><div ").concat(isPrint ? '' : "style=\"width: ".concat(column.renderWidth, "px\""), "><input type=\"checkbox\" ").concat(item._checkboxDisabled ? 'disabled ' : '').concat(getBooleanValue(cellValue) ? 'checked' : '', "><span>").concat(item._checkboxLabel, "</span></div></td>");
859
705
  }
860
-
861
706
  return "<td class=\"".concat(classNames.join(' '), "\" rowspan=\"").concat(rowSpan, "\" colspan=\"").concat(colSpan, "\" title=\"").concat(cellValue, "\"><div ").concat(isPrint ? '' : "style=\"width: ".concat(column.renderWidth, "px\""), ">").concat((0, _utils.formatText)(cellValue, true), "</div></td>");
862
707
  }).join('') + '</tr>');
863
708
  });
864
709
  }
865
-
866
710
  tables.push('</tbody>');
867
711
  }
868
-
869
712
  if (isFooter) {
870
713
  var footerTableData = reactData.footerTableData;
871
714
  var footers = getFooterData(opts, footerTableData);
872
-
873
715
  if (footers.length) {
874
716
  tables.push('<tfoot>');
875
717
  footers.forEach(function (rows) {
@@ -877,41 +719,34 @@ var tableExportHook = {
877
719
  var footAlign = column.footerAlign || column.align || allFooterAlign || allAlign;
878
720
  var classNames = hasEllipsis(column, 'showOverflow', allColumnOverflow) ? ['col--ellipsis'] : [];
879
721
  var cellValue = getFooterCellValue(opts, rows, column);
880
-
881
722
  if (footAlign) {
882
723
  classNames.push("col--".concat(footAlign));
883
724
  }
884
-
885
725
  return "<td class=\"".concat(classNames.join(' '), "\" title=\"").concat(cellValue, "\"><div ").concat(isPrint ? '' : "style=\"width: ".concat(column.renderWidth, "px\""), ">").concat((0, _utils.formatText)(cellValue, true), "</div></td>");
886
726
  }).join(''), "</tr>"));
887
727
  });
888
728
  tables.push('</tfoot>');
889
729
  }
890
- } // 是否半选状态
891
-
892
-
730
+ }
731
+ // 是否半选状态
893
732
  var script = !isAllSelected && isIndeterminate ? "<script>(function(){var a=document.querySelector(\".".concat(allCls, "\");if(a){a.indeterminate=true}})()</script>") : '';
894
733
  tables.push('</table>', script);
895
734
  return isPrint ? tables.join('') : (0, _util2.createHtmlPage)(opts, tables.join(''));
896
735
  };
897
-
898
- var toXML = function toXML(opts, columns, datas) {
736
+ var toXML = function (opts, columns, datas) {
899
737
  var xml = ['<?xml version="1.0"?>', '<?mso-application progid="Excel.Sheet"?>', '<Workbook xmlns="urn:schemas-microsoft-com:office:spreadsheet" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet" xmlns:html="http://www.w3.org/TR/REC-html40">', '<DocumentProperties xmlns="urn:schemas-microsoft-com:office:office">', '<Version>16.00</Version>', '</DocumentProperties>', '<ExcelWorkbook xmlns="urn:schemas-microsoft-com:office:excel">', '<WindowHeight>7920</WindowHeight>', '<WindowWidth>21570</WindowWidth>', '<WindowTopX>32767</WindowTopX>', '<WindowTopY>32767</WindowTopY>', '<ProtectStructure>False</ProtectStructure>', '<ProtectWindows>False</ProtectWindows>', '</ExcelWorkbook>', "<Worksheet ss:Name=\"".concat(opts.sheetName, "\">"), '<Table>', columns.map(function (column) {
900
738
  return "<Column ss:Width=\"".concat(column.renderWidth, "\"/>");
901
739
  }).join('')].join('');
902
-
903
740
  if (opts.isHeader) {
904
741
  xml += "<Row>".concat(columns.map(function (column) {
905
742
  return "<Cell><Data ss:Type=\"String\">".concat(getHeaderTitle(opts, column), "</Data></Cell>");
906
743
  }).join(''), "</Row>");
907
744
  }
908
-
909
745
  datas.forEach(function (row) {
910
746
  xml += '<Row>' + columns.map(function (column) {
911
747
  return "<Cell><Data ss:Type=\"String\">".concat(row[column.id], "</Data></Cell>");
912
748
  }).join('') + '</Row>';
913
749
  });
914
-
915
750
  if (opts.isFooter) {
916
751
  var footerTableData = reactData.footerTableData;
917
752
  var footers = getFooterData(opts, footerTableData);
@@ -921,35 +756,27 @@ var tableExportHook = {
921
756
  }).join(''), "</Row>");
922
757
  });
923
758
  }
924
-
925
759
  return "".concat(xml, "</Table></Worksheet></Workbook>");
926
760
  };
927
-
928
- var getContent = function getContent(opts, columns, datas) {
761
+ var getContent = function (opts, columns, datas) {
929
762
  if (columns.length) {
930
763
  switch (opts.type) {
931
764
  case 'csv':
932
765
  return toCsv(opts, columns, datas);
933
-
934
766
  case 'txt':
935
767
  return toTxt(opts, columns, datas);
936
-
937
768
  case 'html':
938
769
  return toHtml(opts, columns, datas);
939
-
940
770
  case 'xml':
941
771
  return toXML(opts, columns, datas);
942
772
  }
943
773
  }
944
-
945
774
  return '';
946
775
  };
947
-
948
- var downloadFile = function downloadFile(opts, content) {
776
+ var downloadFile = function (opts, content) {
949
777
  var filename = opts.filename,
950
- type = opts.type,
951
- download = opts.download;
952
-
778
+ type = opts.type,
779
+ download = opts.download;
953
780
  if (!download) {
954
781
  var blob = (0, _util2.getExportBlobByContent)(content, opts);
955
782
  return Promise.resolve({
@@ -958,7 +785,6 @@ var tableExportHook = {
958
785
  blob: blob
959
786
  });
960
787
  }
961
-
962
788
  (0, _util2.saveLocalFile)({
963
789
  filename: filename,
964
790
  type: type,
@@ -971,7 +797,6 @@ var tableExportHook = {
971
797
  (0, _log.errLog)('vxe.error.reqModule', ['Modal']);
972
798
  }
973
799
  }
974
-
975
800
  _vXETable.VXETable.modal.message({
976
801
  content: _conf.default.i18n('vxe.table.expSuccess'),
977
802
  status: 'success'
@@ -979,13 +804,12 @@ var tableExportHook = {
979
804
  }
980
805
  });
981
806
  };
982
-
983
- var handleExport = function handleExport(opts) {
807
+ var handleExport = function (opts) {
984
808
  var remote = opts.remote,
985
- columns = opts.columns,
986
- colgroups = opts.colgroups,
987
- exportMethod = opts.exportMethod,
988
- afterExportMethod = opts.afterExportMethod;
809
+ columns = opts.columns,
810
+ colgroups = opts.colgroups,
811
+ exportMethod = opts.exportMethod,
812
+ afterExportMethod = opts.afterExportMethod;
989
813
  return new Promise(function (resolve) {
990
814
  if (remote) {
991
815
  var params = {
@@ -1007,7 +831,6 @@ var tableExportHook = {
1007
831
  }
1008
832
  }).then(function (params) {
1009
833
  clearColumnConvert(columns);
1010
-
1011
834
  if (!opts.print) {
1012
835
  if (afterExportMethod) {
1013
836
  afterExportMethod({
@@ -1018,13 +841,11 @@ var tableExportHook = {
1018
841
  });
1019
842
  }
1020
843
  }
1021
-
1022
844
  return Object.assign({
1023
845
  status: true
1024
846
  }, params);
1025
847
  }).catch(function () {
1026
848
  clearColumnConvert(columns);
1027
-
1028
849
  if (!opts.print) {
1029
850
  if (afterExportMethod) {
1030
851
  afterExportMethod({
@@ -1035,55 +856,45 @@ var tableExportHook = {
1035
856
  });
1036
857
  }
1037
858
  }
1038
-
1039
859
  var params = {
1040
860
  status: false
1041
861
  };
1042
862
  return Promise.reject(params);
1043
863
  });
1044
864
  };
1045
-
1046
- var handleImport = function handleImport(content, opts) {
865
+ var handleImport = function (content, opts) {
1047
866
  var tableFullColumn = internalData.tableFullColumn,
1048
- _importResolve = internalData._importResolve,
1049
- _importReject = internalData._importReject;
867
+ _importResolve = internalData._importResolve,
868
+ _importReject = internalData._importReject;
1050
869
  var rest = {
1051
870
  fields: [],
1052
871
  rows: []
1053
872
  };
1054
-
1055
873
  switch (opts.type) {
1056
874
  case 'csv':
1057
875
  rest = parseCsv(tableFullColumn, content);
1058
876
  break;
1059
-
1060
877
  case 'txt':
1061
878
  rest = parseTxt(tableFullColumn, content);
1062
879
  break;
1063
-
1064
880
  case 'html':
1065
881
  rest = parseHTML(tableFullColumn, content);
1066
882
  break;
1067
-
1068
883
  case 'xml':
1069
884
  rest = parseXML(tableFullColumn, content);
1070
885
  break;
1071
886
  }
1072
-
1073
887
  var fields = rest.fields,
1074
- rows = rest.rows;
888
+ rows = rest.rows;
1075
889
  var status = checkImportData(tableFullColumn, fields);
1076
-
1077
890
  if (status) {
1078
891
  $xetable.createData(rows).then(function (data) {
1079
892
  var loadRest;
1080
-
1081
893
  if (opts.mode === 'insert') {
1082
894
  loadRest = $xetable.insert(data);
1083
895
  } else {
1084
896
  loadRest = $xetable.reloadData(data);
1085
897
  }
1086
-
1087
898
  if (opts.message !== false) {
1088
899
  // 检测弹窗模块
1089
900
  if (process.env.NODE_ENV === 'development') {
@@ -1091,13 +902,11 @@ var tableExportHook = {
1091
902
  (0, _log.errLog)('vxe.error.reqModule', ['Modal']);
1092
903
  }
1093
904
  }
1094
-
1095
905
  _vXETable.VXETable.modal.message({
1096
906
  content: _conf.default.i18n('vxe.table.impSuccess', [rows.length]),
1097
907
  status: 'success'
1098
908
  });
1099
909
  }
1100
-
1101
910
  return loadRest.then(function () {
1102
911
  if (_importResolve) {
1103
912
  _importResolve({
@@ -1113,12 +922,10 @@ var tableExportHook = {
1113
922
  (0, _log.errLog)('vxe.error.reqModule', ['Modal']);
1114
923
  }
1115
924
  }
1116
-
1117
925
  _vXETable.VXETable.modal.message({
1118
926
  content: _conf.default.i18n('vxe.error.impFields'),
1119
927
  status: 'error'
1120
928
  });
1121
-
1122
929
  if (_importReject) {
1123
930
  _importReject({
1124
931
  status: false
@@ -1126,16 +933,13 @@ var tableExportHook = {
1126
933
  }
1127
934
  }
1128
935
  };
1129
-
1130
- var handleFileImport = function handleFileImport(file, opts) {
936
+ var handleFileImport = function (file, opts) {
1131
937
  var importMethod = opts.importMethod,
1132
- afterImportMethod = opts.afterImportMethod;
1133
-
938
+ afterImportMethod = opts.afterImportMethod;
1134
939
  var _a = (0, _utils.parseFile)(file),
1135
- type = _a.type,
1136
- filename = _a.filename; // 检查类型,如果为自定义导出,则不需要校验类型
1137
-
1138
-
940
+ type = _a.type,
941
+ filename = _a.filename;
942
+ // 检查类型,如果为自定义导出,则不需要校验类型
1139
943
  if (!importMethod && !_xeUtils.default.includes(_vXETable.VXETable.config.importTypes, type)) {
1140
944
  if (opts.message !== false) {
1141
945
  // 检测弹窗模块
@@ -1144,35 +948,29 @@ var tableExportHook = {
1144
948
  (0, _log.errLog)('vxe.error.reqModule', ['Modal']);
1145
949
  }
1146
950
  }
1147
-
1148
951
  _vXETable.VXETable.modal.message({
1149
952
  content: _conf.default.i18n('vxe.error.notType', [type]),
1150
953
  status: 'error'
1151
954
  });
1152
955
  }
1153
-
1154
956
  var params = {
1155
957
  status: false
1156
958
  };
1157
959
  return Promise.reject(params);
1158
960
  }
1159
-
1160
961
  var rest = new Promise(function (resolve, reject) {
1161
- var _importResolve = function _importResolve(params) {
962
+ var _importResolve = function (params) {
1162
963
  resolve(params);
1163
964
  internalData._importResolve = null;
1164
965
  internalData._importReject = null;
1165
966
  };
1166
-
1167
- var _importReject = function _importReject(params) {
967
+ var _importReject = function (params) {
1168
968
  reject(params);
1169
969
  internalData._importResolve = null;
1170
970
  internalData._importReject = null;
1171
971
  };
1172
-
1173
972
  internalData._importResolve = _importResolve;
1174
973
  internalData._importReject = _importReject;
1175
-
1176
974
  if (window.FileReader) {
1177
975
  var options_1 = Object.assign({
1178
976
  mode: 'insert'
@@ -1180,7 +978,6 @@ var tableExportHook = {
1180
978
  type: type,
1181
979
  filename: filename
1182
980
  });
1183
-
1184
981
  if (options_1.remote) {
1185
982
  if (importMethod) {
1186
983
  Promise.resolve(importMethod({
@@ -1209,19 +1006,15 @@ var tableExportHook = {
1209
1006
  columns: tableFullColumn
1210
1007
  }, function () {
1211
1008
  var reader = new FileReader();
1212
-
1213
1009
  reader.onerror = function () {
1214
1010
  (0, _log.errLog)('vxe.error.notType', [type]);
1215
-
1216
1011
  _importReject({
1217
1012
  status: false
1218
1013
  });
1219
1014
  };
1220
-
1221
1015
  reader.onload = function (e) {
1222
1016
  handleImport(e.target.result, options_1);
1223
1017
  };
1224
-
1225
1018
  reader.readAsText(file, options_1.encoding || 'UTF-8');
1226
1019
  });
1227
1020
  }
@@ -1230,7 +1023,6 @@ var tableExportHook = {
1230
1023
  if (process.env.NODE_ENV === 'development') {
1231
1024
  (0, _log.errLog)('vxe.error.notExp');
1232
1025
  }
1233
-
1234
1026
  _importResolve({
1235
1027
  status: true
1236
1028
  });
@@ -1252,21 +1044,19 @@ var tableExportHook = {
1252
1044
  $table: $xetable
1253
1045
  });
1254
1046
  }
1255
-
1256
1047
  return Promise.reject(e);
1257
1048
  });
1258
1049
  };
1259
-
1260
- var handleExportAndPrint = function handleExportAndPrint(options, isPrint) {
1050
+ var handleExportAndPrint = function (options, isPrint) {
1261
1051
  var treeConfig = props.treeConfig,
1262
- showHeader = props.showHeader,
1263
- showFooter = props.showFooter;
1052
+ showHeader = props.showHeader,
1053
+ showFooter = props.showFooter;
1264
1054
  var initStore = reactData.initStore,
1265
- mergeList = reactData.mergeList,
1266
- isGroup = reactData.isGroup,
1267
- footerTableData = reactData.footerTableData,
1268
- exportStore = reactData.exportStore,
1269
- exportParams = reactData.exportParams;
1055
+ mergeList = reactData.mergeList,
1056
+ isGroup = reactData.isGroup,
1057
+ footerTableData = reactData.footerTableData,
1058
+ exportStore = reactData.exportStore,
1059
+ exportParams = reactData.exportParams;
1270
1060
  var collectColumn = internalData.collectColumn;
1271
1061
  var hasTree = treeConfig;
1272
1062
  var customOpts = computeCustomOpts.value;
@@ -1282,8 +1072,8 @@ var tableExportHook = {
1282
1072
  var modes = defOpts.modes;
1283
1073
  var checkMethod = customOpts.checkMethod;
1284
1074
  var exportColumns = collectColumn.slice(0);
1285
- var columns = defOpts.columns; // 处理类型
1286
-
1075
+ var columns = defOpts.columns;
1076
+ // 处理类型
1287
1077
  var typeList = types.map(function (value) {
1288
1078
  return {
1289
1079
  value: value,
@@ -1295,11 +1085,10 @@ var tableExportHook = {
1295
1085
  value: value,
1296
1086
  label: "vxe.export.modes.".concat(value)
1297
1087
  };
1298
- }); // 默认选中
1299
-
1088
+ });
1089
+ // 默认选中
1300
1090
  _xeUtils.default.eachTree(exportColumns, function (column, index, items, path, parent) {
1301
1091
  var isColGroup = column.children && column.children.length;
1302
-
1303
1092
  if (isColGroup || defaultFilterExportColumn(column)) {
1304
1093
  column.checked = columns ? columns.some(function (item) {
1305
1094
  if ((0, _util.isColumnInfo)(item)) {
@@ -1310,7 +1099,6 @@ var tableExportHook = {
1310
1099
  var colid = item.id || item.colId;
1311
1100
  var type = item.type;
1312
1101
  var field = item.property || item.field;
1313
-
1314
1102
  if (colid) {
1315
1103
  return column.id === colid;
1316
1104
  } else if (field && type) {
@@ -1321,15 +1109,15 @@ var tableExportHook = {
1321
1109
  return column.type === type;
1322
1110
  }
1323
1111
  }
1112
+ return false;
1324
1113
  }) : column.visible;
1325
1114
  column.halfChecked = false;
1326
1115
  column.disabled = parent && parent.disabled || (checkMethod ? !checkMethod({
1327
1116
  column: column
1328
1117
  }) : false);
1329
1118
  }
1330
- }); // 更新条件
1331
-
1332
-
1119
+ });
1120
+ // 更新条件
1333
1121
  Object.assign(exportStore, {
1334
1122
  columns: exportColumns,
1335
1123
  typeList: typeList,
@@ -1340,26 +1128,22 @@ var tableExportHook = {
1340
1128
  isPrint: isPrint,
1341
1129
  hasColgroup: isGroup,
1342
1130
  visible: true
1343
- }); // 默认参数
1344
-
1131
+ });
1132
+ // 默认参数
1345
1133
  if (!initStore.export) {
1346
1134
  Object.assign(exportParams, {
1347
1135
  mode: selectRecords.length ? 'selected' : 'current'
1348
1136
  }, defOpts);
1349
1137
  }
1350
-
1351
1138
  if (modes.indexOf(exportParams.mode) === -1) {
1352
1139
  exportParams.mode = modes[0];
1353
1140
  }
1354
-
1355
1141
  if (types.indexOf(exportParams.type) === -1) {
1356
1142
  exportParams.type = types[0];
1357
1143
  }
1358
-
1359
1144
  initStore.export = true;
1360
1145
  return (0, _vue.nextTick)();
1361
1146
  };
1362
-
1363
1147
  var exportMethods = {
1364
1148
  /**
1365
1149
  * 导出文件,支持 csv/html/xml/txt
@@ -1367,12 +1151,12 @@ var tableExportHook = {
1367
1151
  * 如果是启用了虚拟滚动,则只能导出数据源,可以配合 dataFilterMethod 函数自行转换数据
1368
1152
  * @param {Object} options 参数
1369
1153
  */
1370
- exportData: function exportData(options) {
1154
+ exportData: function (options) {
1371
1155
  var treeConfig = props.treeConfig;
1372
1156
  var isGroup = reactData.isGroup,
1373
- tableGroupColumn = reactData.tableGroupColumn;
1157
+ tableGroupColumn = reactData.tableGroupColumn;
1374
1158
  var tableFullColumn = internalData.tableFullColumn,
1375
- afterFullData = internalData.afterFullData;
1159
+ afterFullData = internalData.afterFullData;
1376
1160
  var exportOpts = computeExportOpts.value;
1377
1161
  var treeOpts = computeTreeOpts.value;
1378
1162
  var opts = Object.assign({
@@ -1387,7 +1171,8 @@ var tableExportHook = {
1387
1171
  // isAllExpand: false,
1388
1172
  download: true,
1389
1173
  type: 'csv',
1390
- mode: 'current' // data: null,
1174
+ mode: 'current'
1175
+ // data: null,
1391
1176
  // remote: false,
1392
1177
  // dataFilterMethod: null,
1393
1178
  // footerFilterMethod: null,
@@ -1395,19 +1180,18 @@ var tableExportHook = {
1395
1180
  // columnFilterMethod: null,
1396
1181
  // beforeExportMethod: null,
1397
1182
  // afterExportMethod: null
1398
-
1399
1183
  }, exportOpts, {
1400
1184
  print: false
1401
1185
  }, options);
1402
1186
  var type = opts.type,
1403
- mode = opts.mode,
1404
- columns = opts.columns,
1405
- original = opts.original,
1406
- beforeExportMethod = opts.beforeExportMethod;
1187
+ mode = opts.mode,
1188
+ columns = opts.columns,
1189
+ original = opts.original,
1190
+ beforeExportMethod = opts.beforeExportMethod;
1407
1191
  var groups = [];
1408
1192
  var customCols = columns && columns.length ? columns : null;
1409
- var columnFilterMethod = opts.columnFilterMethod; // 如果设置源数据,则默认导出设置了字段的列
1410
-
1193
+ var columnFilterMethod = opts.columnFilterMethod;
1194
+ // 如果设置源数据,则默认导出设置了字段的列
1411
1195
  if (!customCols && !columnFilterMethod) {
1412
1196
  columnFilterMethod = original ? function (_a) {
1413
1197
  var column = _a.column;
@@ -1417,11 +1201,9 @@ var tableExportHook = {
1417
1201
  return defaultFilterExportColumn(column);
1418
1202
  };
1419
1203
  }
1420
-
1421
1204
  if (customCols) {
1422
1205
  groups = _xeUtils.default.searchTree(_xeUtils.default.mapTree(customCols, function (item) {
1423
1206
  var targetColumn;
1424
-
1425
1207
  if (item) {
1426
1208
  if ((0, _util.isColumnInfo)(item)) {
1427
1209
  targetColumn = item;
@@ -1431,7 +1213,6 @@ var tableExportHook = {
1431
1213
  var colid = item.id || item.colId;
1432
1214
  var type_1 = item.type;
1433
1215
  var field_1 = item.property || item.field;
1434
-
1435
1216
  if (colid) {
1436
1217
  targetColumn = $xetable.getColumnById(colid);
1437
1218
  } else if (field_1 && type_1) {
@@ -1446,7 +1227,6 @@ var tableExportHook = {
1446
1227
  });
1447
1228
  }
1448
1229
  }
1449
-
1450
1230
  return targetColumn || {};
1451
1231
  }
1452
1232
  }, {
@@ -1473,45 +1253,36 @@ var tableExportHook = {
1473
1253
  mapChildren: 'childNodes',
1474
1254
  original: true
1475
1255
  });
1476
- } // 获取所有列
1477
-
1478
-
1256
+ }
1257
+ // 获取所有列
1479
1258
  var cols = [];
1480
-
1481
1259
  _xeUtils.default.eachTree(groups, function (column) {
1482
1260
  var isColGroup = column.children && column.children.length;
1483
-
1484
1261
  if (!isColGroup) {
1485
1262
  cols.push(column);
1486
1263
  }
1487
1264
  }, {
1488
1265
  children: 'childNodes'
1489
- }); // 构建分组层级
1490
-
1491
-
1266
+ });
1267
+ // 构建分组层级
1492
1268
  opts.columns = cols;
1493
1269
  opts.colgroups = convertToRows(groups);
1494
-
1495
1270
  if (!opts.filename) {
1496
1271
  opts.filename = _conf.default.i18n(opts.original ? 'vxe.table.expOriginFilename' : 'vxe.table.expFilename', [_xeUtils.default.toDateString(Date.now(), 'yyyyMMddHHmmss')]);
1497
1272
  }
1498
-
1499
1273
  if (!opts.sheetName) {
1500
1274
  opts.sheetName = document.title;
1501
- } // 检查类型,如果为自定义导出,则不需要校验类型
1502
-
1503
-
1275
+ }
1276
+ // 检查类型,如果为自定义导出,则不需要校验类型
1504
1277
  if (!opts.exportMethod && !_xeUtils.default.includes(_vXETable.VXETable.config.exportTypes, type)) {
1505
1278
  if (process.env.NODE_ENV === 'development') {
1506
1279
  (0, _log.errLog)('vxe.error.notType', [type]);
1507
1280
  }
1508
-
1509
1281
  var params = {
1510
1282
  status: false
1511
1283
  };
1512
1284
  return Promise.reject(params);
1513
1285
  }
1514
-
1515
1286
  if (!opts.print) {
1516
1287
  if (beforeExportMethod) {
1517
1288
  beforeExportMethod({
@@ -1521,13 +1292,10 @@ var tableExportHook = {
1521
1292
  });
1522
1293
  }
1523
1294
  }
1524
-
1525
1295
  if (!opts.data) {
1526
1296
  opts.data = afterFullData;
1527
-
1528
1297
  if (mode === 'selected') {
1529
1298
  var selectRecords_1 = $xetable.getCheckboxRecords();
1530
-
1531
1299
  if (['html', 'pdf'].indexOf(type) > -1 && treeConfig) {
1532
1300
  opts.data = _xeUtils.default.searchTree($xetable.getTableData().fullData, function (item) {
1533
1301
  return $xetable.findRowIndexOf(selectRecords_1, item) > -1;
@@ -1543,25 +1311,22 @@ var tableExportHook = {
1543
1311
  (0, _log.warnLog)('vxe.error.errProp', ['all', 'mode=current,selected']);
1544
1312
  }
1545
1313
  }
1546
-
1547
1314
  if ($xegrid && !opts.remote) {
1548
1315
  var gridReactData = $xegrid.reactData;
1549
1316
  var computeProxyOpts = $xegrid.getComputeMaps().computeProxyOpts;
1550
1317
  var proxyOpts = computeProxyOpts.value;
1551
1318
  var beforeQueryAll = proxyOpts.beforeQueryAll,
1552
- afterQueryAll_1 = proxyOpts.afterQueryAll,
1553
- _a = proxyOpts.ajax,
1554
- ajax = _a === void 0 ? {} : _a,
1555
- _b = proxyOpts.props,
1556
- props_1 = _b === void 0 ? {} : _b;
1319
+ afterQueryAll_1 = proxyOpts.afterQueryAll,
1320
+ _a = proxyOpts.ajax,
1321
+ ajax = _a === void 0 ? {} : _a,
1322
+ _b = proxyOpts.props,
1323
+ props_1 = _b === void 0 ? {} : _b;
1557
1324
  var ajaxMethods = ajax.queryAll;
1558
-
1559
1325
  if (process.env.NODE_ENV === 'development') {
1560
1326
  if (!ajaxMethods) {
1561
1327
  (0, _log.warnLog)('vxe.error.notFunc', ['proxy-config.ajax.queryAll']);
1562
1328
  }
1563
1329
  }
1564
-
1565
1330
  if (ajaxMethods) {
1566
1331
  var params_1 = {
1567
1332
  $table: $xetable,
@@ -1576,50 +1341,43 @@ var tableExportHook = {
1576
1341
  return e;
1577
1342
  }).then(function (rest) {
1578
1343
  opts.data = (props_1.list ? _xeUtils.default.get(rest, props_1.list) : rest) || [];
1579
-
1580
1344
  if (afterQueryAll_1) {
1581
1345
  afterQueryAll_1(params_1);
1582
1346
  }
1583
-
1584
1347
  return handleExport(opts);
1585
1348
  });
1586
1349
  }
1587
1350
  }
1588
1351
  }
1589
1352
  }
1590
-
1591
1353
  return handleExport(opts);
1592
1354
  },
1593
- importByFile: function importByFile(file, options) {
1355
+ importByFile: function (file, options) {
1594
1356
  var opts = Object.assign({}, options);
1595
1357
  var beforeImportMethod = opts.beforeImportMethod;
1596
-
1597
1358
  if (beforeImportMethod) {
1598
1359
  beforeImportMethod({
1599
1360
  options: opts,
1600
1361
  $table: $xetable
1601
1362
  });
1602
1363
  }
1603
-
1604
1364
  return handleFileImport(file, opts);
1605
1365
  },
1606
- importData: function importData(options) {
1366
+ importData: function (options) {
1607
1367
  var importOpts = computeImportOpts.value;
1608
1368
  var opts = Object.assign({
1609
- types: _vXETable.VXETable.config.importTypes // beforeImportMethod: null,
1369
+ types: _vXETable.VXETable.config.importTypes
1370
+ // beforeImportMethod: null,
1610
1371
  // afterImportMethod: null
1611
-
1612
1372
  }, importOpts, options);
1613
1373
  var beforeImportMethod = opts.beforeImportMethod,
1614
- afterImportMethod = opts.afterImportMethod;
1615
-
1374
+ afterImportMethod = opts.afterImportMethod;
1616
1375
  if (beforeImportMethod) {
1617
1376
  beforeImportMethod({
1618
1377
  options: opts,
1619
1378
  $table: $xetable
1620
1379
  });
1621
1380
  }
1622
-
1623
1381
  return (0, _util2.readLocalFile)(opts).catch(function (e) {
1624
1382
  if (afterImportMethod) {
1625
1383
  afterImportMethod({
@@ -1628,35 +1386,32 @@ var tableExportHook = {
1628
1386
  $table: $xetable
1629
1387
  });
1630
1388
  }
1631
-
1632
1389
  return Promise.reject(e);
1633
1390
  }).then(function (params) {
1634
1391
  var file = params.file;
1635
1392
  return handleFileImport(file, opts);
1636
1393
  });
1637
1394
  },
1638
- saveFile: function saveFile(options) {
1395
+ saveFile: function (options) {
1639
1396
  return (0, _util2.saveLocalFile)(options);
1640
1397
  },
1641
- readFile: function readFile(options) {
1398
+ readFile: function (options) {
1642
1399
  return (0, _util2.readLocalFile)(options);
1643
1400
  },
1644
- print: function print(options) {
1401
+ print: function (options) {
1645
1402
  var printOpts = computePrintOpts.value;
1646
1403
  var opts = Object.assign({
1647
- original: false // beforePrintMethod
1648
-
1404
+ original: false
1405
+ // beforePrintMethod
1649
1406
  }, printOpts, options, {
1650
1407
  type: 'html',
1651
1408
  download: false,
1652
1409
  remote: false,
1653
1410
  print: true
1654
1411
  });
1655
-
1656
1412
  if (!opts.sheetName) {
1657
1413
  opts.sheetName = document.title;
1658
1414
  }
1659
-
1660
1415
  return new Promise(function (resolve) {
1661
1416
  if (opts.content) {
1662
1417
  resolve((0, _util2.handlePrint)($xetable, opts, opts.content));
@@ -1668,12 +1423,12 @@ var tableExportHook = {
1668
1423
  }
1669
1424
  });
1670
1425
  },
1671
- openImport: function openImport(options) {
1426
+ openImport: function (options) {
1672
1427
  var treeConfig = props.treeConfig,
1673
- importConfig = props.importConfig;
1428
+ importConfig = props.importConfig;
1674
1429
  var initStore = reactData.initStore,
1675
- importStore = reactData.importStore,
1676
- importParams = reactData.importParams;
1430
+ importStore = reactData.importStore,
1431
+ importParams = reactData.importParams;
1677
1432
  var importOpts = computeImportOpts.value;
1678
1433
  var defOpts = Object.assign({
1679
1434
  mode: 'insert',
@@ -1682,7 +1437,6 @@ var tableExportHook = {
1682
1437
  }, options, importOpts);
1683
1438
  var types = defOpts.types;
1684
1439
  var isTree = !!treeConfig;
1685
-
1686
1440
  if (isTree) {
1687
1441
  if (defOpts.message) {
1688
1442
  _vXETable.VXETable.modal.message({
@@ -1690,15 +1444,12 @@ var tableExportHook = {
1690
1444
  status: 'error'
1691
1445
  });
1692
1446
  }
1693
-
1694
1447
  return;
1695
1448
  }
1696
-
1697
1449
  if (!importConfig) {
1698
1450
  (0, _log.errLog)('vxe.error.reqProp', ['import-config']);
1699
- } // 处理类型
1700
-
1701
-
1451
+ }
1452
+ // 处理类型
1702
1453
  var typeList = types.map(function (value) {
1703
1454
  return {
1704
1455
  value: value,
@@ -1722,32 +1473,28 @@ var tableExportHook = {
1722
1473
  Object.assign(importParams, defOpts);
1723
1474
  initStore.import = true;
1724
1475
  },
1725
- openExport: function openExport(options) {
1476
+ openExport: function (options) {
1726
1477
  var exportOpts = computeExportOpts.value;
1727
-
1728
1478
  if (process.env.NODE_ENV === 'development') {
1729
1479
  if (!props.exportConfig) {
1730
1480
  (0, _log.errLog)('vxe.error.reqProp', ['export-config']);
1731
1481
  }
1732
1482
  }
1733
-
1734
1483
  handleExportAndPrint(Object.assign({}, exportOpts, options));
1735
1484
  },
1736
- openPrint: function openPrint(options) {
1485
+ openPrint: function (options) {
1737
1486
  var printOpts = computePrintOpts.value;
1738
-
1739
1487
  if (process.env.NODE_ENV === 'development') {
1740
1488
  if (!props.printConfig) {
1741
1489
  (0, _log.errLog)('vxe.error.reqProp', ['print-config']);
1742
1490
  }
1743
1491
  }
1744
-
1745
1492
  handleExportAndPrint(Object.assign({}, printOpts, options), true);
1746
1493
  }
1747
1494
  };
1748
1495
  return exportMethods;
1749
1496
  },
1750
- setupGrid: function setupGrid($xegrid) {
1497
+ setupGrid: function ($xegrid) {
1751
1498
  return $xegrid.extendTableMethods(tableExportMethodKeys);
1752
1499
  }
1753
1500
  };