vxe-table 3.19.39 → 3.20.0-beta.1
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/index.css +1 -1
- package/es/index.esm.js +2 -1
- package/es/index.min.css +1 -1
- package/es/style.css +1 -1
- package/es/style.min.css +1 -1
- package/es/table/module/custom/mixin.js +6 -4
- package/es/table/module/custom/panel.js +806 -799
- package/es/table/module/edit/mixin.js +43 -31
- package/es/table/module/export/export-panel.js +511 -458
- package/es/table/module/export/import-panel.js +224 -192
- package/es/table/module/keyboard/mixin.js +2 -2
- package/es/table/module/menu/panel.js +165 -161
- package/es/table/module/validator/mixin.js +255 -236
- package/es/table/src/body.js +2 -1
- package/es/table/src/cell.js +2 -2
- package/es/table/src/methods.js +33 -43
- package/es/table/src/table.js +13 -249
- package/es/table/src/util.js +242 -0
- package/es/table/style.css +23 -50
- package/es/table/style.min.css +1 -1
- package/es/ui/index.js +2 -2
- package/es/ui/src/dom.js +22 -0
- package/es/ui/src/log.js +1 -1
- package/es/vxe-table/style.css +23 -50
- package/es/vxe-table/style.min.css +1 -1
- package/lib/index.common.js +2 -1
- package/lib/index.css +1 -1
- package/lib/index.min.css +1 -1
- package/lib/index.umd.js +3640 -4790
- package/lib/index.umd.min.js +1 -1
- package/lib/style.css +1 -1
- package/lib/style.min.css +1 -1
- package/lib/table/module/custom/mixin.js +6 -4
- package/lib/table/module/custom/mixin.min.js +1 -1
- package/lib/table/module/custom/panel.js +693 -685
- package/lib/table/module/custom/panel.min.js +1 -1
- package/lib/table/module/edit/mixin.js +47 -31
- package/lib/table/module/edit/mixin.min.js +1 -1
- package/lib/table/module/export/export-panel.js +450 -384
- package/lib/table/module/export/export-panel.min.js +1 -1
- package/lib/table/module/export/import-panel.js +200 -159
- package/lib/table/module/export/import-panel.min.js +1 -1
- package/lib/table/module/keyboard/mixin.js +2 -2
- package/lib/table/module/keyboard/mixin.min.js +1 -1
- package/lib/table/module/menu/panel.js +119 -114
- package/lib/table/module/menu/panel.min.js +1 -1
- package/lib/table/module/validator/mixin.js +271 -259
- package/lib/table/module/validator/mixin.min.js +1 -1
- package/lib/table/src/body.js +2 -1
- 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/methods.js +33 -45
- package/lib/table/src/methods.min.js +1 -1
- package/lib/table/src/table.js +12 -248
- package/lib/table/src/table.min.js +1 -1
- package/lib/table/src/util.js +243 -0
- package/lib/table/src/util.min.js +1 -1
- package/lib/table/style/style.css +23 -50
- package/lib/table/style/style.min.css +1 -1
- package/lib/ui/index.js +2 -2
- package/lib/ui/index.min.js +1 -1
- package/lib/ui/src/dom.js +22 -0
- package/lib/ui/src/dom.min.js +1 -1
- package/lib/ui/src/log.js +1 -1
- package/lib/ui/src/log.min.js +1 -1
- package/lib/v-x-e-table/index.js +2 -1
- package/lib/v-x-e-table/index.min.js +1 -1
- package/lib/vxe-colgroup/index.js +2 -1
- package/lib/vxe-colgroup/index.min.js +1 -1
- package/lib/vxe-column/index.js +2 -1
- package/lib/vxe-column/index.min.js +1 -1
- package/lib/vxe-grid/index.js +2 -1
- package/lib/vxe-grid/index.min.js +1 -1
- package/lib/vxe-table/index.js +2 -1
- package/lib/vxe-table/index.min.js +1 -1
- package/lib/vxe-table/style/style.css +23 -50
- package/lib/vxe-table/style/style.min.css +1 -1
- package/lib/vxe-toolbar/index.js +2 -1
- package/lib/vxe-toolbar/index.min.js +1 -1
- package/lib/vxe-ui/index.js +2 -1
- package/lib/vxe-ui/index.min.js +1 -1
- package/lib/vxe-v-x-e-table/index.js +2 -1
- package/lib/vxe-v-x-e-table/index.min.js +1 -1
- package/package.json +1 -1
- package/packages/table/module/custom/mixin.ts +7 -4
- package/packages/table/module/custom/panel.ts +846 -839
- package/packages/table/module/edit/mixin.ts +55 -35
- package/packages/table/module/export/export-panel.ts +545 -469
- package/packages/table/module/export/import-panel.ts +245 -202
- package/packages/table/module/filter/panel.ts +4 -18
- package/packages/table/module/keyboard/mixin.ts +2 -2
- package/packages/table/module/menu/panel.ts +171 -163
- package/packages/table/module/validator/mixin.ts +279 -240
- package/packages/table/src/body.ts +2 -1
- package/packages/table/src/cell.ts +2 -2
- package/packages/table/src/methods.ts +43 -45
- package/packages/table/src/table.ts +14 -260
- package/packages/table/src/util.ts +254 -0
- package/packages/ui/index.ts +1 -1
- package/packages/ui/src/dom.ts +22 -0
- package/styles/components/table.scss +5 -2
- package/styles/theme/base.scss +2 -1
- /package/es/{iconfont.1767145426781.ttf → iconfont.1767492234857.ttf} +0 -0
- /package/es/{iconfont.1767145426781.woff → iconfont.1767492234857.woff} +0 -0
- /package/es/{iconfont.1767145426781.woff2 → iconfont.1767492234857.woff2} +0 -0
- /package/lib/{iconfont.1767145426781.ttf → iconfont.1767492234857.ttf} +0 -0
- /package/lib/{iconfont.1767145426781.woff → iconfont.1767492234857.woff} +0 -0
- /package/lib/{iconfont.1767145426781.woff2 → iconfont.1767492234857.woff2} +0 -0
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { defineVxeComponent } from '../../../ui/src/comp';
|
|
1
2
|
import { VxeUI } from '../../../ui';
|
|
2
3
|
import XEUtils from 'xe-utils';
|
|
3
4
|
import { parseFile } from '../../../ui/src/utils';
|
|
@@ -9,12 +10,14 @@ export default {
|
|
|
9
10
|
globalMixins.sizeMixin
|
|
10
11
|
],
|
|
11
12
|
props: {
|
|
12
|
-
defaultOptions:
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
13
|
+
defaultOptions: {
|
|
14
|
+
type: Object,
|
|
15
|
+
default: () => ({})
|
|
16
|
+
},
|
|
17
|
+
storeData: {
|
|
18
|
+
type: Object,
|
|
19
|
+
default: () => ({})
|
|
20
|
+
}
|
|
18
21
|
},
|
|
19
22
|
inject: {
|
|
20
23
|
$xeTable: {
|
|
@@ -22,27 +25,36 @@ export default {
|
|
|
22
25
|
}
|
|
23
26
|
},
|
|
24
27
|
data() {
|
|
25
|
-
|
|
28
|
+
const reactData = {
|
|
26
29
|
loading: false
|
|
27
30
|
};
|
|
31
|
+
return {
|
|
32
|
+
reactData
|
|
33
|
+
};
|
|
28
34
|
},
|
|
29
|
-
computed: {
|
|
30
|
-
|
|
31
|
-
|
|
35
|
+
computed: Object.assign(Object.assign({}, {}), { computeSelectName() {
|
|
36
|
+
const $xeImportPanel = this;
|
|
37
|
+
const props = $xeImportPanel;
|
|
38
|
+
const { storeData } = props;
|
|
39
|
+
return `${storeData.filename}.${storeData.type}`;
|
|
32
40
|
},
|
|
33
|
-
|
|
34
|
-
|
|
41
|
+
computeHasFile() {
|
|
42
|
+
const $xeImportPanel = this;
|
|
43
|
+
const props = $xeImportPanel;
|
|
44
|
+
const { storeData } = props;
|
|
45
|
+
return storeData.file && storeData.type;
|
|
35
46
|
},
|
|
36
|
-
|
|
37
|
-
const
|
|
47
|
+
computeParseTypeLabel() {
|
|
48
|
+
const $xeImportPanel = this;
|
|
49
|
+
const props = $xeImportPanel;
|
|
50
|
+
const { storeData } = props;
|
|
38
51
|
const { type, typeList } = storeData;
|
|
39
52
|
if (type) {
|
|
40
53
|
const selectItem = XEUtils.find(typeList, item => type === item.value);
|
|
41
|
-
return selectItem ? selectItem.label : '*.*'
|
|
54
|
+
return `${selectItem ? selectItem.label : '*.*'}`;
|
|
42
55
|
}
|
|
43
56
|
return `*.${typeList.map((item) => item.value).join(', *.')}`;
|
|
44
|
-
}
|
|
45
|
-
},
|
|
57
|
+
} }),
|
|
46
58
|
created() {
|
|
47
59
|
const $xeTableImportPanel = this;
|
|
48
60
|
const VxeUIModalComponent = VxeUI.getComponent('VxeModal');
|
|
@@ -60,167 +72,6 @@ export default {
|
|
|
60
72
|
}
|
|
61
73
|
});
|
|
62
74
|
},
|
|
63
|
-
render(h) {
|
|
64
|
-
const $xeTable = this.$parent;
|
|
65
|
-
const $xeGrid = $xeTable.$xeGrid;
|
|
66
|
-
const $xeGantt = $xeTable.$xeGantt;
|
|
67
|
-
const { hasFile, loading, parseTypeLabel, defaultOptions, storeData, selectName } = this;
|
|
68
|
-
const slots = defaultOptions.slots || {};
|
|
69
|
-
const topSlot = slots.top;
|
|
70
|
-
const bottomSlot = slots.bottom;
|
|
71
|
-
const defaultSlot = slots.default;
|
|
72
|
-
const footerSlot = slots.footer;
|
|
73
|
-
return h('vxe-modal', {
|
|
74
|
-
ref: 'modal',
|
|
75
|
-
props: {
|
|
76
|
-
id: 'VXE_IMPORT_MODAL',
|
|
77
|
-
value: storeData.visible,
|
|
78
|
-
title: getI18n('vxe.import.impTitle'),
|
|
79
|
-
width: 540,
|
|
80
|
-
minWidth: 360,
|
|
81
|
-
minHeight: 240,
|
|
82
|
-
mask: true,
|
|
83
|
-
lockView: true,
|
|
84
|
-
showFooter: true,
|
|
85
|
-
escClosable: true,
|
|
86
|
-
maskClosable: true,
|
|
87
|
-
showMaximize: true,
|
|
88
|
-
resize: true,
|
|
89
|
-
loading
|
|
90
|
-
},
|
|
91
|
-
on: {
|
|
92
|
-
input(value) {
|
|
93
|
-
storeData.visible = value;
|
|
94
|
-
},
|
|
95
|
-
show: this.showEvent
|
|
96
|
-
},
|
|
97
|
-
scopedSlots: {
|
|
98
|
-
default: () => {
|
|
99
|
-
const params = {
|
|
100
|
-
$table: $xeTable,
|
|
101
|
-
$grid: $xeGrid,
|
|
102
|
-
$gantt: $xeGantt,
|
|
103
|
-
options: defaultOptions,
|
|
104
|
-
params: defaultOptions.params
|
|
105
|
-
};
|
|
106
|
-
return h('div', {
|
|
107
|
-
class: 'vxe-table-export--panel'
|
|
108
|
-
}, [
|
|
109
|
-
topSlot
|
|
110
|
-
? h('div', {
|
|
111
|
-
class: 'vxe-table-export--panel-top'
|
|
112
|
-
}, $xeTable.callSlot(topSlot, params, h))
|
|
113
|
-
: renderEmptyElement(this),
|
|
114
|
-
h('div', {
|
|
115
|
-
class: 'vxe-table-export--panel-body'
|
|
116
|
-
}, defaultSlot
|
|
117
|
-
? $xeTable.callSlot(defaultSlot, params, h)
|
|
118
|
-
: [
|
|
119
|
-
h('table', {
|
|
120
|
-
class: 'vxe-table-export--panel-table',
|
|
121
|
-
attrs: {
|
|
122
|
-
cellspacing: 0,
|
|
123
|
-
cellpadding: 0,
|
|
124
|
-
border: 0
|
|
125
|
-
}
|
|
126
|
-
}, [
|
|
127
|
-
h('tbody', [
|
|
128
|
-
h('tr', [
|
|
129
|
-
h('td', getI18n('vxe.import.impFile')),
|
|
130
|
-
h('td', [
|
|
131
|
-
hasFile
|
|
132
|
-
? h('div', {
|
|
133
|
-
class: 'vxe-table-export--selected--file',
|
|
134
|
-
attrs: {
|
|
135
|
-
title: selectName
|
|
136
|
-
}
|
|
137
|
-
}, [
|
|
138
|
-
h('span', selectName),
|
|
139
|
-
h('i', {
|
|
140
|
-
class: getIcon().INPUT_CLEAR,
|
|
141
|
-
on: {
|
|
142
|
-
click: this.clearFileEvent
|
|
143
|
-
}
|
|
144
|
-
})
|
|
145
|
-
])
|
|
146
|
-
: h('button', {
|
|
147
|
-
ref: 'fileBtn',
|
|
148
|
-
class: 'vxe-table-export--select--file',
|
|
149
|
-
attrs: {
|
|
150
|
-
type: 'button'
|
|
151
|
-
},
|
|
152
|
-
on: {
|
|
153
|
-
click: this.selectFileEvent
|
|
154
|
-
}
|
|
155
|
-
}, getI18n('vxe.import.impSelect'))
|
|
156
|
-
])
|
|
157
|
-
]),
|
|
158
|
-
h('tr', [
|
|
159
|
-
h('td', getI18n('vxe.import.impType')),
|
|
160
|
-
h('td', parseTypeLabel)
|
|
161
|
-
]),
|
|
162
|
-
h('tr', [
|
|
163
|
-
h('td', getI18n('vxe.import.impMode')),
|
|
164
|
-
h('td', [
|
|
165
|
-
h('vxe-select', {
|
|
166
|
-
props: {
|
|
167
|
-
value: defaultOptions.mode,
|
|
168
|
-
options: storeData.modeList
|
|
169
|
-
},
|
|
170
|
-
on: {
|
|
171
|
-
modelValue(value) {
|
|
172
|
-
defaultOptions.mode = value;
|
|
173
|
-
}
|
|
174
|
-
}
|
|
175
|
-
})
|
|
176
|
-
])
|
|
177
|
-
])
|
|
178
|
-
])
|
|
179
|
-
])
|
|
180
|
-
]),
|
|
181
|
-
bottomSlot
|
|
182
|
-
? h('div', {
|
|
183
|
-
class: 'vxe-table-export--panel-bottom'
|
|
184
|
-
}, $xeTable.callSlot(bottomSlot, params, h))
|
|
185
|
-
: renderEmptyElement(this)
|
|
186
|
-
]);
|
|
187
|
-
},
|
|
188
|
-
footer: () => {
|
|
189
|
-
const params = {
|
|
190
|
-
$table: $xeTable,
|
|
191
|
-
$grid: $xeGrid,
|
|
192
|
-
$gantt: $xeGantt,
|
|
193
|
-
options: defaultOptions,
|
|
194
|
-
params: defaultOptions.params
|
|
195
|
-
};
|
|
196
|
-
return h('div', {
|
|
197
|
-
class: 'vxe-table-export--panel-footer'
|
|
198
|
-
}, footerSlot
|
|
199
|
-
? $xeTable.callSlot(footerSlot, params, h)
|
|
200
|
-
: [
|
|
201
|
-
h('div', {
|
|
202
|
-
class: 'vxe-table-export--panel-btns'
|
|
203
|
-
}, [
|
|
204
|
-
h('vxe-button', {
|
|
205
|
-
on: {
|
|
206
|
-
click: this.cancelEvent
|
|
207
|
-
}
|
|
208
|
-
}, getI18n('vxe.import.impCancel')),
|
|
209
|
-
h('vxe-button', {
|
|
210
|
-
props: {
|
|
211
|
-
status: 'primary',
|
|
212
|
-
disabled: !hasFile || loading
|
|
213
|
-
},
|
|
214
|
-
on: {
|
|
215
|
-
click: this.importEvent
|
|
216
|
-
}
|
|
217
|
-
}, getI18n('vxe.import.impConfirm'))
|
|
218
|
-
])
|
|
219
|
-
]);
|
|
220
|
-
}
|
|
221
|
-
}
|
|
222
|
-
});
|
|
223
|
-
},
|
|
224
75
|
methods: {
|
|
225
76
|
clearFileEvent() {
|
|
226
77
|
Object.assign(this.storeData, {
|
|
@@ -230,33 +81,214 @@ export default {
|
|
|
230
81
|
});
|
|
231
82
|
},
|
|
232
83
|
selectFileEvent() {
|
|
233
|
-
const $
|
|
234
|
-
|
|
84
|
+
const $xeImportPanel = this;
|
|
85
|
+
const props = $xeImportPanel;
|
|
86
|
+
const $xeTable = $xeImportPanel.$xeTable;
|
|
87
|
+
const { storeData, defaultOptions } = props;
|
|
88
|
+
$xeTable.readFile(defaultOptions).then((params) => {
|
|
235
89
|
const { file } = params;
|
|
236
|
-
Object.assign(
|
|
237
|
-
}).catch((
|
|
90
|
+
Object.assign(storeData, parseFile(file), { file });
|
|
91
|
+
}).catch(() => { });
|
|
238
92
|
},
|
|
239
93
|
showEvent() {
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
const targetElem = $refs.fileBtn;
|
|
94
|
+
const $xeImportPanel = this;
|
|
95
|
+
$xeImportPanel.$nextTick(() => {
|
|
96
|
+
const targetElem = $xeImportPanel.$refs.fileBtn;
|
|
243
97
|
if (targetElem) {
|
|
244
98
|
targetElem.focus();
|
|
245
99
|
}
|
|
246
100
|
});
|
|
247
101
|
},
|
|
248
102
|
cancelEvent() {
|
|
249
|
-
|
|
103
|
+
const $xeImportPanel = this;
|
|
104
|
+
const props = $xeImportPanel;
|
|
105
|
+
const { storeData } = props;
|
|
106
|
+
storeData.visible = false;
|
|
250
107
|
},
|
|
251
108
|
importEvent() {
|
|
252
|
-
const $
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
109
|
+
const $xeImportPanel = this;
|
|
110
|
+
const props = $xeImportPanel;
|
|
111
|
+
const reactData = $xeImportPanel.reactData;
|
|
112
|
+
const $xeTable = $xeImportPanel.$xeTable;
|
|
113
|
+
const { storeData, defaultOptions } = props;
|
|
114
|
+
const importOpts = $xeTable.computeImportOpts;
|
|
115
|
+
reactData.loading = true;
|
|
116
|
+
$xeTable.importByFile(storeData.file, Object.assign({}, importOpts, defaultOptions)).then(() => {
|
|
117
|
+
reactData.loading = false;
|
|
118
|
+
storeData.visible = false;
|
|
257
119
|
}).catch(() => {
|
|
258
|
-
|
|
120
|
+
reactData.loading = false;
|
|
121
|
+
});
|
|
122
|
+
},
|
|
123
|
+
renderVN(h) {
|
|
124
|
+
const $xeImportPanel = this;
|
|
125
|
+
const props = $xeImportPanel;
|
|
126
|
+
const reactData = $xeImportPanel.reactData;
|
|
127
|
+
const $xeTable = $xeImportPanel.$xeTable;
|
|
128
|
+
const $xeGrid = $xeTable.$xeGrid;
|
|
129
|
+
const $xeGantt = $xeTable.$xeGantt;
|
|
130
|
+
const { defaultOptions, storeData } = props;
|
|
131
|
+
const selectName = $xeImportPanel.computeSelectName;
|
|
132
|
+
const hasFile = $xeImportPanel.computeHasFile;
|
|
133
|
+
const parseTypeLabel = $xeImportPanel.computeParseTypeLabel;
|
|
134
|
+
const slots = defaultOptions.slots || {};
|
|
135
|
+
const topSlot = slots.top;
|
|
136
|
+
const bottomSlot = slots.bottom;
|
|
137
|
+
const defaultSlot = slots.default;
|
|
138
|
+
const footerSlot = slots.footer;
|
|
139
|
+
return h('vxe-modal', {
|
|
140
|
+
ref: 'modal',
|
|
141
|
+
props: {
|
|
142
|
+
id: 'VXE_IMPORT_MODAL',
|
|
143
|
+
value: storeData.visible,
|
|
144
|
+
title: getI18n('vxe.import.impTitle'),
|
|
145
|
+
width: 540,
|
|
146
|
+
minWidth: 360,
|
|
147
|
+
minHeight: 240,
|
|
148
|
+
mask: true,
|
|
149
|
+
lockView: true,
|
|
150
|
+
showFooter: true,
|
|
151
|
+
escClosable: true,
|
|
152
|
+
maskClosable: true,
|
|
153
|
+
showMaximize: true,
|
|
154
|
+
resize: true,
|
|
155
|
+
loading: reactData.loading
|
|
156
|
+
},
|
|
157
|
+
on: {
|
|
158
|
+
input(value) {
|
|
159
|
+
storeData.visible = value;
|
|
160
|
+
},
|
|
161
|
+
show: $xeImportPanel.showEvent
|
|
162
|
+
},
|
|
163
|
+
scopedSlots: {
|
|
164
|
+
default: () => {
|
|
165
|
+
const params = {
|
|
166
|
+
$table: $xeTable,
|
|
167
|
+
$grid: $xeGrid,
|
|
168
|
+
$gantt: $xeGantt,
|
|
169
|
+
options: defaultOptions,
|
|
170
|
+
params: defaultOptions.params
|
|
171
|
+
};
|
|
172
|
+
return h('div', {
|
|
173
|
+
class: 'vxe-table-export--panel'
|
|
174
|
+
}, [
|
|
175
|
+
topSlot
|
|
176
|
+
? h('div', {
|
|
177
|
+
class: 'vxe-table-export--panel-top'
|
|
178
|
+
}, $xeTable.callSlot(topSlot, params, h))
|
|
179
|
+
: renderEmptyElement($xeTable),
|
|
180
|
+
h('div', {
|
|
181
|
+
class: 'vxe-table-export--panel-body'
|
|
182
|
+
}, defaultSlot
|
|
183
|
+
? $xeTable.callSlot(defaultSlot, params, h)
|
|
184
|
+
: [
|
|
185
|
+
h('table', {
|
|
186
|
+
class: 'vxe-table-export--panel-table',
|
|
187
|
+
attrs: {
|
|
188
|
+
cellspacing: 0,
|
|
189
|
+
cellpadding: 0,
|
|
190
|
+
border: 0
|
|
191
|
+
}
|
|
192
|
+
}, [
|
|
193
|
+
h('tbody', [
|
|
194
|
+
h('tr', [
|
|
195
|
+
h('td', getI18n('vxe.import.impFile')),
|
|
196
|
+
h('td', [
|
|
197
|
+
hasFile
|
|
198
|
+
? h('div', {
|
|
199
|
+
class: 'vxe-table-export--selected--file',
|
|
200
|
+
attrs: {
|
|
201
|
+
title: selectName
|
|
202
|
+
}
|
|
203
|
+
}, [
|
|
204
|
+
h('span', selectName),
|
|
205
|
+
h('i', {
|
|
206
|
+
class: getIcon().INPUT_CLEAR,
|
|
207
|
+
on: {
|
|
208
|
+
click: $xeImportPanel.clearFileEvent
|
|
209
|
+
}
|
|
210
|
+
})
|
|
211
|
+
])
|
|
212
|
+
: h('button', {
|
|
213
|
+
ref: 'fileBtn',
|
|
214
|
+
class: 'vxe-table-export--select--file',
|
|
215
|
+
attrs: {
|
|
216
|
+
type: 'button'
|
|
217
|
+
},
|
|
218
|
+
on: {
|
|
219
|
+
click: $xeImportPanel.selectFileEvent
|
|
220
|
+
}
|
|
221
|
+
}, getI18n('vxe.import.impSelect'))
|
|
222
|
+
])
|
|
223
|
+
]),
|
|
224
|
+
h('tr', [
|
|
225
|
+
h('td', getI18n('vxe.import.impType')),
|
|
226
|
+
h('td', parseTypeLabel)
|
|
227
|
+
]),
|
|
228
|
+
h('tr', [
|
|
229
|
+
h('td', getI18n('vxe.import.impMode')),
|
|
230
|
+
h('td', [
|
|
231
|
+
h('vxe-select', {
|
|
232
|
+
props: {
|
|
233
|
+
value: defaultOptions.mode,
|
|
234
|
+
options: storeData.modeList
|
|
235
|
+
},
|
|
236
|
+
on: {
|
|
237
|
+
modelValue(value) {
|
|
238
|
+
defaultOptions.mode = value;
|
|
239
|
+
}
|
|
240
|
+
}
|
|
241
|
+
})
|
|
242
|
+
])
|
|
243
|
+
])
|
|
244
|
+
])
|
|
245
|
+
])
|
|
246
|
+
]),
|
|
247
|
+
bottomSlot
|
|
248
|
+
? h('div', {
|
|
249
|
+
class: 'vxe-table-export--panel-bottom'
|
|
250
|
+
}, $xeTable.callSlot(bottomSlot, params, h))
|
|
251
|
+
: renderEmptyElement($xeTable)
|
|
252
|
+
]);
|
|
253
|
+
},
|
|
254
|
+
footer: () => {
|
|
255
|
+
const params = {
|
|
256
|
+
$table: $xeTable,
|
|
257
|
+
$grid: $xeGrid,
|
|
258
|
+
$gantt: $xeGantt,
|
|
259
|
+
options: defaultOptions,
|
|
260
|
+
params: defaultOptions.params
|
|
261
|
+
};
|
|
262
|
+
return h('div', {
|
|
263
|
+
class: 'vxe-table-export--panel-footer'
|
|
264
|
+
}, footerSlot
|
|
265
|
+
? $xeTable.callSlot(footerSlot, params, h)
|
|
266
|
+
: [
|
|
267
|
+
h('div', {
|
|
268
|
+
class: 'vxe-table-export--panel-btns'
|
|
269
|
+
}, [
|
|
270
|
+
h('vxe-button', {
|
|
271
|
+
on: {
|
|
272
|
+
click: $xeImportPanel.cancelEvent
|
|
273
|
+
}
|
|
274
|
+
}, getI18n('vxe.import.impCancel')),
|
|
275
|
+
h('vxe-button', {
|
|
276
|
+
props: {
|
|
277
|
+
status: 'primary',
|
|
278
|
+
disabled: !hasFile || reactData.loading
|
|
279
|
+
},
|
|
280
|
+
on: {
|
|
281
|
+
click: $xeImportPanel.importEvent
|
|
282
|
+
}
|
|
283
|
+
}, getI18n('vxe.import.impConfirm'))
|
|
284
|
+
])
|
|
285
|
+
]);
|
|
286
|
+
}
|
|
287
|
+
}
|
|
259
288
|
});
|
|
260
289
|
}
|
|
290
|
+
},
|
|
291
|
+
render(h) {
|
|
292
|
+
return this.renderVN(h);
|
|
261
293
|
}
|
|
262
294
|
};
|
|
@@ -502,8 +502,8 @@ export default {
|
|
|
502
502
|
const checkboxOpts = $xeTable.computeCheckboxOpts;
|
|
503
503
|
const mouseOpts = $xeTable.computeMouseOpts;
|
|
504
504
|
const editOpts = $xeTable.computeEditOpts;
|
|
505
|
-
if (mouseConfig && mouseOpts.area && $xeTable.
|
|
506
|
-
return $xeTable.
|
|
505
|
+
if (mouseConfig && mouseOpts.area && $xeTable.triggerClAreaModnEvent) {
|
|
506
|
+
return $xeTable.triggerClAreaModnEvent(evnt, params);
|
|
507
507
|
}
|
|
508
508
|
else {
|
|
509
509
|
if (checkboxConfig && checkboxOpts.range) {
|