vxe-table 3.15.30 → 3.15.31

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.
@@ -31,7 +31,7 @@ function getSeq($xeTable, cellValue, row, $rowIndex, column, $columnIndex) {
31
31
  return cellValue;
32
32
  }
33
33
  function defaultFilterExportColumn(column) {
34
- return !!column.field || ['seq', 'checkbox', 'radio'].indexOf(column.type || '') > -1;
34
+ return !!column.field || ['seq', 'checkbox', 'radio'].indexOf(column.type || '') === -1;
35
35
  }
36
36
  function toTableBorder(border) {
37
37
  if (border === true) {
@@ -1138,9 +1138,14 @@ export default {
1138
1138
  if (!mode) {
1139
1139
  mode = selectRecords.length ? 'selected' : 'current';
1140
1140
  }
1141
- const customCols = columns && columns.length
1142
- ? columns
1143
- : XEUtils.searchTree(collectColumn, column => {
1141
+ let isCustomCol = false;
1142
+ let customCols = [];
1143
+ if (columns && columns.length) {
1144
+ isCustomCol = true;
1145
+ customCols = columns;
1146
+ }
1147
+ else {
1148
+ customCols = XEUtils.searchTree(collectColumn, column => {
1144
1149
  const isColGroup = column.children && column.children.length > 0;
1145
1150
  let isChecked = false;
1146
1151
  if (columns && columns.length) {
@@ -1154,9 +1159,10 @@ export default {
1154
1159
  }
1155
1160
  return isChecked;
1156
1161
  }, { children: 'children', mapChildren: 'childNodes', original: true });
1162
+ }
1157
1163
  const handleOptions = Object.assign({}, opts, { filename: '', sheetName: '' });
1158
1164
  // 如果设置源数据,则默认导出设置了字段的列
1159
- if (!customCols && !columnFilterMethod) {
1165
+ if (!isCustomCol && !columnFilterMethod) {
1160
1166
  columnFilterMethod = ({ column }) => {
1161
1167
  if (excludeFields) {
1162
1168
  if (XEUtils.includes(excludeFields, column.field)) {
package/es/ui/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { VxeUI } from '@vxe-ui/core';
2
2
  import { getFuncText } from './src/utils';
3
- export const version = "3.15.30";
3
+ export const version = "3.15.31";
4
4
  VxeUI.version = version;
5
5
  VxeUI.tableVersion = version;
6
6
  VxeUI.setConfig({
package/es/ui/src/log.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { VxeUI } from '@vxe-ui/core';
2
2
  const { log } = VxeUI;
3
- const version = `table v${"3.15.30"}`;
3
+ const version = `table v${"3.15.31"}`;
4
4
  export const warnLog = log.create('warn', version);
5
5
  export const errLog = log.create('error', version);
package/lib/index.umd.js CHANGED
@@ -2002,7 +2002,7 @@ function getClass(property, params) {
2002
2002
  ;// CONCATENATED MODULE: ./packages/ui/index.ts
2003
2003
 
2004
2004
 
2005
- const version = "3.15.30";
2005
+ const version = "3.15.31";
2006
2006
  core_.VxeUI.version = version;
2007
2007
  core_.VxeUI.tableVersion = version;
2008
2008
  core_.VxeUI.setConfig({
@@ -2646,7 +2646,7 @@ function isNodeElement(elem) {
2646
2646
  const {
2647
2647
  log: log_log
2648
2648
  } = core_.VxeUI;
2649
- const log_version = `table v${"3.15.30"}`;
2649
+ const log_version = `table v${"3.15.31"}`;
2650
2650
  const warnLog = log_log.create('warn', log_version);
2651
2651
  const errLog = log_log.create('error', log_version);
2652
2652
  ;// CONCATENATED MODULE: ./packages/table/src/columnInfo.ts
@@ -23551,7 +23551,7 @@ function getSeq($xeTable, cellValue, row, $rowIndex, column, $columnIndex) {
23551
23551
  return cellValue;
23552
23552
  }
23553
23553
  function defaultFilterExportColumn(column) {
23554
- return !!column.field || ['seq', 'checkbox', 'radio'].indexOf(column.type || '') > -1;
23554
+ return !!column.field || ['seq', 'checkbox', 'radio'].indexOf(column.type || '') === -1;
23555
23555
  }
23556
23556
  function toTableBorder(border) {
23557
23557
  if (border === true) {
@@ -24866,28 +24866,35 @@ const convertToRows = originColumns => {
24866
24866
  if (!mode) {
24867
24867
  mode = selectRecords.length ? 'selected' : 'current';
24868
24868
  }
24869
- const customCols = columns && columns.length ? columns : external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().searchTree(collectColumn, column => {
24870
- const isColGroup = column.children && column.children.length > 0;
24871
- let isChecked = false;
24872
- if (columns && columns.length) {
24873
- isChecked = handleFilterColumns(opts, column, columns);
24874
- } else if (excludeFields || includeFields) {
24875
- isChecked = handleFilterFields(opts, column, includeFields, excludeFields);
24876
- } else {
24877
- isChecked = column.visible && (isColGroup || defaultFilterExportColumn(column));
24878
- }
24879
- return isChecked;
24880
- }, {
24881
- children: 'children',
24882
- mapChildren: 'childNodes',
24883
- original: true
24884
- });
24869
+ let isCustomCol = false;
24870
+ let customCols = [];
24871
+ if (columns && columns.length) {
24872
+ isCustomCol = true;
24873
+ customCols = columns;
24874
+ } else {
24875
+ customCols = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().searchTree(collectColumn, column => {
24876
+ const isColGroup = column.children && column.children.length > 0;
24877
+ let isChecked = false;
24878
+ if (columns && columns.length) {
24879
+ isChecked = handleFilterColumns(opts, column, columns);
24880
+ } else if (excludeFields || includeFields) {
24881
+ isChecked = handleFilterFields(opts, column, includeFields, excludeFields);
24882
+ } else {
24883
+ isChecked = column.visible && (isColGroup || defaultFilterExportColumn(column));
24884
+ }
24885
+ return isChecked;
24886
+ }, {
24887
+ children: 'children',
24888
+ mapChildren: 'childNodes',
24889
+ original: true
24890
+ });
24891
+ }
24885
24892
  const handleOptions = Object.assign({}, opts, {
24886
24893
  filename: '',
24887
24894
  sheetName: ''
24888
24895
  });
24889
24896
  // 如果设置源数据,则默认导出设置了字段的列
24890
- if (!customCols && !columnFilterMethod) {
24897
+ if (!isCustomCol && !columnFilterMethod) {
24891
24898
  columnFilterMethod = ({
24892
24899
  column
24893
24900
  }) => {