vxe-table 4.5.0-beta.11 → 4.5.0-beta.13
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/README.en.md +1 -1
- package/README.md +1 -1
- package/README.zh-TW.md +1 -1
- package/es/footer/src/footer.js +5 -1
- package/es/form/src/form.js +27 -5
- package/es/icon/style.css +1 -1
- package/es/input/src/input.js +4 -1
- package/es/locale/lang/en-US.js +4 -0
- package/es/locale/lang/es-ES.js +5 -0
- package/es/locale/lang/ja-JP.js +5 -0
- package/es/locale/lang/zh-CN.js +5 -0
- package/es/locale/lang/zh-TC.js +5 -0
- package/es/menu/src/hooks.js +3 -3
- package/es/select/src/select.js +4 -1
- package/es/style.css +1 -1
- package/es/style.min.css +1 -1
- package/es/table/src/body.js +7 -3
- package/es/table/src/table.js +30 -7
- package/es/table/style.css +14 -3
- package/es/textarea/src/textarea.js +4 -1
- package/es/tools/log.js +1 -1
- package/es/tooltip/style.css +0 -6
- package/es/v-x-e-table/index.js +4 -1
- package/es/v-x-e-table/src/conf.js +4 -1
- package/es/v-x-e-table/src/menus.js +48 -2
- package/es/v-x-e-table/src/store.js +4 -1
- package/es/v-x-e-table/src/validators.js +5 -0
- package/es/validator/src/hook.js +100 -22
- package/es/vxe-table/style.css +14 -3
- package/es/vxe-tooltip/style.css +0 -6
- package/lib/footer/src/footer.js +6 -1
- package/lib/footer/src/footer.min.js +1 -1
- package/lib/form/src/form.js +24 -4
- package/lib/form/src/form.min.js +1 -1
- package/lib/icon/style/style.css +1 -1
- package/lib/icon/style/style.min.css +1 -1
- package/lib/index.umd.js +271 -48
- package/lib/index.umd.min.js +1 -1
- package/lib/input/src/input.js +6 -1
- package/lib/input/src/input.min.js +1 -1
- package/lib/locale/lang/en-US.js +4 -0
- package/lib/locale/lang/en-US.min.js +1 -1
- package/lib/locale/lang/en-US.umd.js +4 -0
- package/lib/locale/lang/es-ES.js +5 -0
- package/lib/locale/lang/es-ES.min.js +1 -1
- package/lib/locale/lang/es-ES.umd.js +5 -0
- package/lib/locale/lang/ja-JP.js +5 -0
- package/lib/locale/lang/ja-JP.min.js +1 -1
- package/lib/locale/lang/ja-JP.umd.js +5 -0
- package/lib/locale/lang/zh-CN.js +5 -0
- package/lib/locale/lang/zh-CN.min.js +1 -1
- package/lib/locale/lang/zh-CN.umd.js +5 -0
- package/lib/locale/lang/zh-HK.min.js +1 -1
- package/lib/locale/lang/zh-HK.umd.js +5 -0
- package/lib/locale/lang/zh-MO.min.js +1 -1
- package/lib/locale/lang/zh-MO.umd.js +5 -0
- package/lib/locale/lang/zh-TC.js +5 -0
- package/lib/locale/lang/zh-TC.min.js +1 -1
- package/lib/locale/lang/zh-TC.umd.js +5 -0
- package/lib/locale/lang/zh-TW.min.js +1 -1
- package/lib/locale/lang/zh-TW.umd.js +5 -0
- package/lib/menu/src/hooks.js +3 -3
- package/lib/menu/src/hooks.min.js +1 -1
- package/lib/select/src/select.js +6 -1
- package/lib/select/src/select.min.js +1 -1
- package/lib/style.css +1 -1
- package/lib/style.min.css +1 -1
- package/lib/table/src/body.js +8 -2
- package/lib/table/src/body.min.js +1 -1
- package/lib/table/src/table.js +38 -9
- package/lib/table/src/table.min.js +1 -1
- package/lib/table/style/style.css +14 -3
- package/lib/table/style/style.min.css +1 -1
- package/lib/textarea/src/textarea.js +6 -1
- package/lib/textarea/src/textarea.min.js +1 -1
- package/lib/tools/log.js +1 -1
- package/lib/tools/log.min.js +1 -1
- package/lib/tooltip/style/style.css +0 -6
- package/lib/tooltip/style/style.min.css +1 -1
- package/lib/v-x-e-table/index.js +14 -1
- package/lib/v-x-e-table/index.min.js +1 -1
- package/lib/v-x-e-table/src/conf.js +4 -1
- package/lib/v-x-e-table/src/conf.min.js +1 -1
- package/lib/v-x-e-table/src/menus.js +48 -2
- package/lib/v-x-e-table/src/menus.min.js +1 -1
- package/lib/v-x-e-table/src/store.js +4 -1
- package/lib/v-x-e-table/src/store.min.js +1 -1
- package/lib/v-x-e-table/src/validators.js +15 -0
- package/lib/v-x-e-table/src/validators.min.js +1 -0
- package/lib/validator/src/hook.js +94 -20
- package/lib/validator/src/hook.min.js +1 -1
- package/lib/vxe-table/style/style.css +14 -3
- package/lib/vxe-table/style/style.min.css +1 -1
- package/lib/vxe-tooltip/style/style.css +0 -6
- package/lib/vxe-tooltip/style/style.min.css +1 -1
- package/package.json +2 -2
- package/packages/footer/src/footer.ts +5 -1
- package/packages/form/src/form.ts +24 -5
- package/packages/input/src/input.ts +4 -1
- package/packages/locale/lang/en-US.ts +4 -0
- package/packages/locale/lang/es-ES.ts +5 -0
- package/packages/locale/lang/ja-JP.ts +5 -0
- package/packages/locale/lang/zh-CN.ts +5 -0
- package/packages/locale/lang/zh-TC.ts +5 -0
- package/packages/menu/src/hooks.ts +3 -3
- package/packages/select/src/select.ts +4 -1
- package/packages/table/src/body.ts +7 -3
- package/packages/table/src/table.ts +34 -7
- package/packages/textarea/src/textarea.ts +4 -1
- package/packages/v-x-e-table/index.ts +3 -0
- package/packages/v-x-e-table/src/conf.ts +4 -1
- package/packages/v-x-e-table/src/menus.ts +52 -2
- package/packages/v-x-e-table/src/store.ts +3 -1
- package/packages/v-x-e-table/src/validators.ts +9 -0
- package/packages/validator/src/hook.ts +117 -36
- package/styles/cssvar.scss +1 -2
- package/styles/table.scss +27 -6
- package/styles/tooltip.scss +0 -8
- package/styles/variable.scss +1 -2
- package/types/form.d.ts +9 -12
- package/types/table.d.ts +20 -1
- package/types/v-x-e-table/index.d.ts +8 -1
- package/types/v-x-e-table/menus.d.ts +19 -7
- package/types/v-x-e-table/validators.d.ts +30 -0
- package/types/validator.d.ts +14 -1
- /package/es/icon/style/{iconfont.1689813279210.ttf → iconfont.1690032028705.ttf} +0 -0
- /package/es/icon/style/{iconfont.1689813279210.woff → iconfont.1690032028705.woff} +0 -0
- /package/es/icon/style/{iconfont.1689813279210.woff2 → iconfont.1690032028705.woff2} +0 -0
- /package/es/{iconfont.1689813279210.ttf → iconfont.1690032028705.ttf} +0 -0
- /package/es/{iconfont.1689813279210.woff → iconfont.1690032028705.woff} +0 -0
- /package/es/{iconfont.1689813279210.woff2 → iconfont.1690032028705.woff2} +0 -0
- /package/lib/icon/style/{iconfont.1689813279210.ttf → iconfont.1690032028705.ttf} +0 -0
- /package/lib/icon/style/{iconfont.1689813279210.woff → iconfont.1690032028705.woff} +0 -0
- /package/lib/icon/style/{iconfont.1689813279210.woff2 → iconfont.1690032028705.woff2} +0 -0
- /package/lib/{iconfont.1689813279210.ttf → iconfont.1690032028705.ttf} +0 -0
- /package/lib/{iconfont.1689813279210.woff → iconfont.1690032028705.woff} +0 -0
- /package/lib/{iconfont.1689813279210.woff2 → iconfont.1690032028705.woff2} +0 -0
package/lib/index.umd.js
CHANGED
|
@@ -1788,7 +1788,8 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
1788
1788
|
"setup": function() { return /* reexport */ setup; },
|
|
1789
1789
|
"t": function() { return /* reexport */ t; },
|
|
1790
1790
|
"use": function() { return /* reexport */ use; },
|
|
1791
|
-
"v": function() { return /* reexport */ v; }
|
|
1791
|
+
"v": function() { return /* reexport */ v; },
|
|
1792
|
+
"validators": function() { return /* reexport */ validators; }
|
|
1792
1793
|
});
|
|
1793
1794
|
|
|
1794
1795
|
// NAMESPACE OBJECT: ./packages/all.ts
|
|
@@ -1877,7 +1878,8 @@ __webpack_require__.d(all_namespaceObject, {
|
|
|
1877
1878
|
"setup": function() { return setup; },
|
|
1878
1879
|
"t": function() { return t; },
|
|
1879
1880
|
"use": function() { return use; },
|
|
1880
|
-
"v": function() { return v; }
|
|
1881
|
+
"v": function() { return v; },
|
|
1882
|
+
"validators": function() { return validators; }
|
|
1881
1883
|
});
|
|
1882
1884
|
|
|
1883
1885
|
;// CONCATENATED MODULE: ./node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js
|
|
@@ -1949,7 +1951,10 @@ const GlobalConfig = {
|
|
|
1949
1951
|
enterable: true
|
|
1950
1952
|
},
|
|
1951
1953
|
validConfig: {
|
|
1952
|
-
showMessage: true
|
|
1954
|
+
showMessage: true,
|
|
1955
|
+
autoClear: true,
|
|
1956
|
+
message: 'default',
|
|
1957
|
+
msgMode: 'single'
|
|
1953
1958
|
},
|
|
1954
1959
|
columnConfig: {
|
|
1955
1960
|
maxFixedSize: 4
|
|
@@ -2271,7 +2276,7 @@ const GlobalConfig = {
|
|
|
2271
2276
|
;// CONCATENATED MODULE: ./packages/tools/log.ts
|
|
2272
2277
|
|
|
2273
2278
|
function getLog(message, params) {
|
|
2274
|
-
return `[vxe-table v${"4.5.0-beta.
|
|
2279
|
+
return `[vxe-table v${"4.5.0-beta.12"}] ${conf.i18n(message, params)}`;
|
|
2275
2280
|
}
|
|
2276
2281
|
function outLog(type) {
|
|
2277
2282
|
return function (message, params) {
|
|
@@ -3970,7 +3975,9 @@ class Store {
|
|
|
3970
3975
|
_defineProperty(this, "store", {});
|
|
3971
3976
|
}
|
|
3972
3977
|
mixin(options) {
|
|
3973
|
-
|
|
3978
|
+
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().each(options, (item, key) => {
|
|
3979
|
+
this.add(key, item);
|
|
3980
|
+
});
|
|
3974
3981
|
return this;
|
|
3975
3982
|
}
|
|
3976
3983
|
has(name) {
|
|
@@ -4011,7 +4018,52 @@ if (true) {
|
|
|
4011
4018
|
}
|
|
4012
4019
|
;// CONCATENATED MODULE: ./packages/v-x-e-table/src/menus.ts
|
|
4013
4020
|
|
|
4014
|
-
|
|
4021
|
+
|
|
4022
|
+
|
|
4023
|
+
class VXEMenusStore {
|
|
4024
|
+
constructor() {
|
|
4025
|
+
_defineProperty(this, "store", {});
|
|
4026
|
+
}
|
|
4027
|
+
mixin(options) {
|
|
4028
|
+
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().each(options, (item, key) => {
|
|
4029
|
+
this.add(key, item);
|
|
4030
|
+
});
|
|
4031
|
+
return this;
|
|
4032
|
+
}
|
|
4033
|
+
has(name) {
|
|
4034
|
+
return !!this.get(name);
|
|
4035
|
+
}
|
|
4036
|
+
get(name) {
|
|
4037
|
+
return this.store[name];
|
|
4038
|
+
}
|
|
4039
|
+
add(name, render) {
|
|
4040
|
+
const conf = this.store[name];
|
|
4041
|
+
// 兼容
|
|
4042
|
+
if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(render)) {
|
|
4043
|
+
render = {
|
|
4044
|
+
menuMethod: render
|
|
4045
|
+
};
|
|
4046
|
+
}
|
|
4047
|
+
// 检测是否覆盖
|
|
4048
|
+
if (true) {
|
|
4049
|
+
const confKeys = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().keys(conf);
|
|
4050
|
+
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().each(render, (item, key) => {
|
|
4051
|
+
if (confKeys.includes(key)) {
|
|
4052
|
+
warnLog('vxe.error.coverProp', [name, key]);
|
|
4053
|
+
}
|
|
4054
|
+
});
|
|
4055
|
+
}
|
|
4056
|
+
this.store[name] = conf ? external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().merge(conf, render) : render;
|
|
4057
|
+
return this;
|
|
4058
|
+
}
|
|
4059
|
+
delete(name) {
|
|
4060
|
+
delete this.store[name];
|
|
4061
|
+
}
|
|
4062
|
+
forEach(callback) {
|
|
4063
|
+
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().objectEach(this.store, callback);
|
|
4064
|
+
}
|
|
4065
|
+
}
|
|
4066
|
+
const menus = new VXEMenusStore();
|
|
4015
4067
|
if (true) {
|
|
4016
4068
|
Object.assign(menus, {
|
|
4017
4069
|
_name: 'Menus'
|
|
@@ -4025,6 +4077,14 @@ if (true) {
|
|
|
4025
4077
|
_name: 'Formats'
|
|
4026
4078
|
});
|
|
4027
4079
|
}
|
|
4080
|
+
;// CONCATENATED MODULE: ./packages/v-x-e-table/src/validators.ts
|
|
4081
|
+
|
|
4082
|
+
const validators = new store();
|
|
4083
|
+
if (true) {
|
|
4084
|
+
Object.assign(validators, {
|
|
4085
|
+
_name: 'Validators'
|
|
4086
|
+
});
|
|
4087
|
+
}
|
|
4028
4088
|
;// CONCATENATED MODULE: ./packages/v-x-e-table/src/hooks.ts
|
|
4029
4089
|
|
|
4030
4090
|
const hooks = new store();
|
|
@@ -4049,6 +4109,7 @@ const setup = options => {
|
|
|
4049
4109
|
|
|
4050
4110
|
|
|
4051
4111
|
|
|
4112
|
+
|
|
4052
4113
|
function getExportOrImpotType(types, flag) {
|
|
4053
4114
|
const rest = [];
|
|
4054
4115
|
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().objectEach(types, (val, type) => {
|
|
@@ -4105,12 +4166,13 @@ const config = new VXETableConfig();
|
|
|
4105
4166
|
const v = 'v4';
|
|
4106
4167
|
const VXETable = {
|
|
4107
4168
|
v,
|
|
4108
|
-
version: "4.5.0-beta.
|
|
4169
|
+
version: "4.5.0-beta.12",
|
|
4109
4170
|
setup: setup,
|
|
4110
4171
|
interceptor: interceptor,
|
|
4111
4172
|
renderer: renderer,
|
|
4112
4173
|
commands: commands,
|
|
4113
4174
|
formats: formats,
|
|
4175
|
+
validators: validators,
|
|
4114
4176
|
menus: menus,
|
|
4115
4177
|
hooks: hooks,
|
|
4116
4178
|
config,
|
|
@@ -4125,6 +4187,7 @@ const VXETable = {
|
|
|
4125
4187
|
|
|
4126
4188
|
|
|
4127
4189
|
|
|
4190
|
+
|
|
4128
4191
|
/* harmony default export */ var v_x_e_table = ((/* unused pure expression or super */ null && (VXETable)));
|
|
4129
4192
|
;// CONCATENATED MODULE: ./packages/filter/src/panel.ts
|
|
4130
4193
|
|
|
@@ -5296,15 +5359,15 @@ const tableMenuHook = {
|
|
|
5296
5359
|
ctxMenuLinkEvent(evnt, menu) {
|
|
5297
5360
|
// 如果一级菜单有配置 code 则允许点击,否则不能点击
|
|
5298
5361
|
if (!menu.disabled && (menu.code || !menu.children || !menu.children.length)) {
|
|
5299
|
-
const
|
|
5362
|
+
const gMenuOpts = VXETable.menus.get(menu.code);
|
|
5300
5363
|
const params = Object.assign({}, internalData._currMenuParams, {
|
|
5301
5364
|
menu,
|
|
5302
5365
|
$table: $xetable,
|
|
5303
5366
|
$grid: $xetable.xegrid,
|
|
5304
5367
|
$event: evnt
|
|
5305
5368
|
});
|
|
5306
|
-
if (
|
|
5307
|
-
|
|
5369
|
+
if (gMenuOpts && gMenuOpts.menuMethod) {
|
|
5370
|
+
gMenuOpts.menuMethod(params, evnt);
|
|
5308
5371
|
}
|
|
5309
5372
|
$xetable.dispatchEvent('menu-click', params, evnt);
|
|
5310
5373
|
menuMethods.closeMenu();
|
|
@@ -7982,7 +8045,10 @@ const quarterSize = 8;
|
|
|
7982
8045
|
},
|
|
7983
8046
|
readonly: Boolean,
|
|
7984
8047
|
disabled: Boolean,
|
|
7985
|
-
placeholder:
|
|
8048
|
+
placeholder: {
|
|
8049
|
+
type: String,
|
|
8050
|
+
default: () => external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eqNull(conf.input.placeholder) ? conf.i18n('vxe.base.pleaseInput') : conf.input.placeholder
|
|
8051
|
+
},
|
|
7986
8052
|
maxlength: [String, Number],
|
|
7987
8053
|
autocomplete: {
|
|
7988
8054
|
type: String,
|
|
@@ -10613,7 +10679,10 @@ function getOptUniqueId() {
|
|
|
10613
10679
|
props: {
|
|
10614
10680
|
modelValue: null,
|
|
10615
10681
|
clearable: Boolean,
|
|
10616
|
-
placeholder:
|
|
10682
|
+
placeholder: {
|
|
10683
|
+
type: String,
|
|
10684
|
+
default: () => external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eqNull(conf.select.placeholder) ? conf.i18n('vxe.base.pleaseSelect') : conf.select.placeholder
|
|
10685
|
+
},
|
|
10617
10686
|
loading: Boolean,
|
|
10618
10687
|
disabled: Boolean,
|
|
10619
10688
|
multiple: Boolean,
|
|
@@ -14645,6 +14714,8 @@ const Keyboard = VxeModuleKeyboard;
|
|
|
14645
14714
|
|
|
14646
14715
|
|
|
14647
14716
|
|
|
14717
|
+
|
|
14718
|
+
|
|
14648
14719
|
/**
|
|
14649
14720
|
* 校验规则
|
|
14650
14721
|
*/
|
|
@@ -14681,6 +14752,9 @@ const validatorHook = {
|
|
|
14681
14752
|
reactData,
|
|
14682
14753
|
internalData
|
|
14683
14754
|
} = $xetable;
|
|
14755
|
+
const {
|
|
14756
|
+
refValidTooltip
|
|
14757
|
+
} = $xetable.getRefMaps();
|
|
14684
14758
|
const {
|
|
14685
14759
|
computeValidOpts,
|
|
14686
14760
|
computeTreeOpts,
|
|
@@ -14708,6 +14782,19 @@ const validatorHook = {
|
|
|
14708
14782
|
}
|
|
14709
14783
|
});
|
|
14710
14784
|
};
|
|
14785
|
+
const handleErrMsgMode = validErrMaps => {
|
|
14786
|
+
const validOpts = computeValidOpts.value;
|
|
14787
|
+
if (validOpts.msgMode === 'single') {
|
|
14788
|
+
const keys = Object.keys(validErrMaps);
|
|
14789
|
+
const resMaps = validErrMaps;
|
|
14790
|
+
if (keys.length) {
|
|
14791
|
+
const firstKey = keys[0];
|
|
14792
|
+
resMaps[firstKey] = validErrMaps[firstKey];
|
|
14793
|
+
}
|
|
14794
|
+
return resMaps;
|
|
14795
|
+
}
|
|
14796
|
+
return validErrMaps;
|
|
14797
|
+
};
|
|
14711
14798
|
/**
|
|
14712
14799
|
* 对表格数据进行校验
|
|
14713
14800
|
* 如果不指定数据,则默认只校验临时变动的数据,例如新增或修改
|
|
@@ -14798,7 +14885,7 @@ const validatorHook = {
|
|
|
14798
14885
|
}
|
|
14799
14886
|
return Promise.all(rowValids).then(() => {
|
|
14800
14887
|
const ruleProps = Object.keys(validRest);
|
|
14801
|
-
reactData.validErrorMaps = validErrMaps;
|
|
14888
|
+
reactData.validErrorMaps = handleErrMsgMode(validErrMaps);
|
|
14802
14889
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)().then(() => {
|
|
14803
14890
|
if (ruleProps.length) {
|
|
14804
14891
|
return Promise.reject(validRest[ruleProps[0]][0]);
|
|
@@ -14837,7 +14924,6 @@ const validatorHook = {
|
|
|
14837
14924
|
const row = firstErrParams.row;
|
|
14838
14925
|
const rowIndex = afterFullData.indexOf(row);
|
|
14839
14926
|
const locatRow = rowIndex > 0 ? afterFullData[rowIndex - 1] : row;
|
|
14840
|
-
reactData.validErrorMaps = validErrMaps;
|
|
14841
14927
|
if (validOpts.autoPos === false) {
|
|
14842
14928
|
finish();
|
|
14843
14929
|
} else {
|
|
@@ -14849,8 +14935,9 @@ const validatorHook = {
|
|
|
14849
14935
|
}
|
|
14850
14936
|
});
|
|
14851
14937
|
});
|
|
14938
|
+
} else {
|
|
14939
|
+
reactData.validErrorMaps = {};
|
|
14852
14940
|
}
|
|
14853
|
-
// reactData.validErrorMaps = validErrMaps
|
|
14854
14941
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)().then(() => {
|
|
14855
14942
|
if (cb) {
|
|
14856
14943
|
cb();
|
|
@@ -14871,11 +14958,24 @@ const validatorHook = {
|
|
|
14871
14958
|
return beginValidate(rows, cb);
|
|
14872
14959
|
},
|
|
14873
14960
|
clearValidate(rows, fieldOrColumn) {
|
|
14961
|
+
const {
|
|
14962
|
+
validErrorMaps
|
|
14963
|
+
} = reactData;
|
|
14964
|
+
const validTip = refValidTooltip.value;
|
|
14965
|
+
const validOpts = computeValidOpts.value;
|
|
14874
14966
|
const rowList = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(rows) ? rows : rows ? [rows] : [];
|
|
14875
14967
|
const colList = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(fieldOrColumn) ? fieldOrColumn : (fieldOrColumn ? [fieldOrColumn] : []).map(column => handleFieldOrColumn($xetable, column));
|
|
14876
14968
|
let validErrMaps = {};
|
|
14969
|
+
if (validTip && validTip.reactData.visible) {
|
|
14970
|
+
validTip.close();
|
|
14971
|
+
}
|
|
14972
|
+
// 如果是单个提示模式
|
|
14973
|
+
if (validOpts.msgMode === 'single') {
|
|
14974
|
+
reactData.validErrorMaps = {};
|
|
14975
|
+
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();
|
|
14976
|
+
}
|
|
14877
14977
|
if (rowList.length && colList.length) {
|
|
14878
|
-
validErrMaps = Object.assign({},
|
|
14978
|
+
validErrMaps = Object.assign({}, validErrorMaps);
|
|
14879
14979
|
rowList.forEach(row => {
|
|
14880
14980
|
colList.forEach(column => {
|
|
14881
14981
|
const vaildKey = `${getRowid($xetable, row)}:${column.id}`;
|
|
@@ -14886,14 +14986,14 @@ const validatorHook = {
|
|
|
14886
14986
|
});
|
|
14887
14987
|
} else if (rowList.length) {
|
|
14888
14988
|
const rowidList = rowList.map(row => `${getRowid($xetable, row)}`);
|
|
14889
|
-
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().each(
|
|
14989
|
+
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().each(validErrorMaps, (item, key) => {
|
|
14890
14990
|
if (rowidList.indexOf(key.split(':')[0]) > -1) {
|
|
14891
14991
|
validErrMaps[key] = item;
|
|
14892
14992
|
}
|
|
14893
14993
|
});
|
|
14894
14994
|
} else if (colList.length) {
|
|
14895
14995
|
const colidList = colList.map(column => `${column.id}`);
|
|
14896
|
-
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().each(
|
|
14996
|
+
external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().each(validErrorMaps, (item, key) => {
|
|
14897
14997
|
if (colidList.indexOf(key.split(':')[1]) > -1) {
|
|
14898
14998
|
validErrMaps[key] = item;
|
|
14899
14999
|
}
|
|
@@ -14962,11 +15062,12 @@ const validatorHook = {
|
|
|
14962
15062
|
const {
|
|
14963
15063
|
type,
|
|
14964
15064
|
trigger,
|
|
14965
|
-
required
|
|
15065
|
+
required,
|
|
15066
|
+
validator
|
|
14966
15067
|
} = rule;
|
|
14967
15068
|
if (validType === 'all' || !trigger || validType === trigger) {
|
|
14968
|
-
if (
|
|
14969
|
-
const
|
|
15069
|
+
if (validator) {
|
|
15070
|
+
const validParams = {
|
|
14970
15071
|
cellValue,
|
|
14971
15072
|
rule,
|
|
14972
15073
|
rules,
|
|
@@ -14974,9 +15075,29 @@ const validatorHook = {
|
|
|
14974
15075
|
rowIndex: $xetable.getRowIndex(row),
|
|
14975
15076
|
column,
|
|
14976
15077
|
columnIndex: $xetable.getColumnIndex(column),
|
|
14977
|
-
field: column.
|
|
14978
|
-
$table: $xetable
|
|
14979
|
-
|
|
15078
|
+
field: column.field,
|
|
15079
|
+
$table: $xetable,
|
|
15080
|
+
$grid: $xetable.xegrid
|
|
15081
|
+
};
|
|
15082
|
+
let customValid;
|
|
15083
|
+
if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isString(validator)) {
|
|
15084
|
+
const gvItem = VXETable.validators.get(validator);
|
|
15085
|
+
if (gvItem) {
|
|
15086
|
+
if (gvItem.cellValidatorMethod) {
|
|
15087
|
+
customValid = gvItem.cellValidatorMethod(validParams);
|
|
15088
|
+
} else {
|
|
15089
|
+
if (true) {
|
|
15090
|
+
warnLog('vxe.error.notValidators', [validator]);
|
|
15091
|
+
}
|
|
15092
|
+
}
|
|
15093
|
+
} else {
|
|
15094
|
+
if (true) {
|
|
15095
|
+
errLog('vxe.error.notValidators', [validator]);
|
|
15096
|
+
}
|
|
15097
|
+
}
|
|
15098
|
+
} else {
|
|
15099
|
+
customValid = validator(validParams);
|
|
15100
|
+
}
|
|
14980
15101
|
if (customValid) {
|
|
14981
15102
|
if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isError(customValid)) {
|
|
14982
15103
|
validRuleErr = true;
|
|
@@ -15057,6 +15178,12 @@ const validatorHook = {
|
|
|
15057
15178
|
actived
|
|
15058
15179
|
} = editStore;
|
|
15059
15180
|
const editOpts = computeEditOpts.value;
|
|
15181
|
+
const validOpts = computeValidOpts.value;
|
|
15182
|
+
// 检查清除校验消息
|
|
15183
|
+
if (editRules && validOpts.msgMode === 'single') {
|
|
15184
|
+
reactData.validErrorMaps = {};
|
|
15185
|
+
}
|
|
15186
|
+
// 校验单元格
|
|
15060
15187
|
if (editConfig && editRules && actived.row) {
|
|
15061
15188
|
const {
|
|
15062
15189
|
row,
|
|
@@ -15093,18 +15220,44 @@ const validatorHook = {
|
|
|
15093
15220
|
*/
|
|
15094
15221
|
showValidTooltip(params) {
|
|
15095
15222
|
const {
|
|
15096
|
-
|
|
15223
|
+
height
|
|
15224
|
+
} = props;
|
|
15225
|
+
const {
|
|
15226
|
+
tableData,
|
|
15227
|
+
validStore,
|
|
15228
|
+
validErrorMaps
|
|
15097
15229
|
} = reactData;
|
|
15230
|
+
const validOpts = computeValidOpts.value;
|
|
15231
|
+
const validTip = refValidTooltip.value;
|
|
15098
15232
|
validStore.visible = true;
|
|
15099
|
-
|
|
15100
|
-
|
|
15101
|
-
|
|
15102
|
-
|
|
15103
|
-
|
|
15104
|
-
|
|
15105
|
-
|
|
15106
|
-
|
|
15233
|
+
if (validOpts.msgMode === 'single') {
|
|
15234
|
+
reactData.validErrorMaps = {
|
|
15235
|
+
[`${getRowid($xetable, params.row)}:${params.column.id}`]: {
|
|
15236
|
+
column: params.column,
|
|
15237
|
+
row: params.row,
|
|
15238
|
+
rule: params.rule,
|
|
15239
|
+
content: params.rule.content
|
|
15240
|
+
}
|
|
15241
|
+
};
|
|
15242
|
+
} else {
|
|
15243
|
+
reactData.validErrorMaps = Object.assign({}, validErrorMaps, {
|
|
15244
|
+
[`${getRowid($xetable, params.row)}:${params.column.id}`]: {
|
|
15245
|
+
column: params.column,
|
|
15246
|
+
row: params.row,
|
|
15247
|
+
rule: params.rule,
|
|
15248
|
+
content: params.rule.content
|
|
15249
|
+
}
|
|
15250
|
+
});
|
|
15251
|
+
}
|
|
15107
15252
|
$xetable.dispatchEvent('valid-error', params, null);
|
|
15253
|
+
if (validTip) {
|
|
15254
|
+
const {
|
|
15255
|
+
cell
|
|
15256
|
+
} = params;
|
|
15257
|
+
if (validTip && (validOpts.message === 'tooltip' || validOpts.message === 'default' && !height && tableData.length < 2)) {
|
|
15258
|
+
return validTip.open(cell, params.rule.content);
|
|
15259
|
+
}
|
|
15260
|
+
}
|
|
15108
15261
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)();
|
|
15109
15262
|
}
|
|
15110
15263
|
};
|
|
@@ -19571,7 +19724,10 @@ let autoTxtElem;
|
|
|
19571
19724
|
name: String,
|
|
19572
19725
|
readonly: Boolean,
|
|
19573
19726
|
disabled: Boolean,
|
|
19574
|
-
placeholder:
|
|
19727
|
+
placeholder: {
|
|
19728
|
+
type: String,
|
|
19729
|
+
default: () => external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().eqNull(conf.textarea.placeholder) ? conf.i18n('vxe.base.pleaseInput') : conf.textarea.placeholder
|
|
19730
|
+
},
|
|
19575
19731
|
maxlength: [String, Number],
|
|
19576
19732
|
rows: {
|
|
19577
19733
|
type: [String, Number],
|
|
@@ -21147,11 +21303,12 @@ function getResetValue(value, resetValue) {
|
|
|
21147
21303
|
const {
|
|
21148
21304
|
type,
|
|
21149
21305
|
trigger,
|
|
21150
|
-
required
|
|
21306
|
+
required,
|
|
21307
|
+
validator
|
|
21151
21308
|
} = rule;
|
|
21152
21309
|
if (validType === 'all' || !trigger || validType === trigger) {
|
|
21153
|
-
if (
|
|
21154
|
-
const
|
|
21310
|
+
if (validator) {
|
|
21311
|
+
const validParams = {
|
|
21155
21312
|
itemValue,
|
|
21156
21313
|
rule,
|
|
21157
21314
|
rules,
|
|
@@ -21159,7 +21316,26 @@ function getResetValue(value, resetValue) {
|
|
|
21159
21316
|
field: property,
|
|
21160
21317
|
property,
|
|
21161
21318
|
$form: $xeform
|
|
21162
|
-
}
|
|
21319
|
+
};
|
|
21320
|
+
let customValid;
|
|
21321
|
+
if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isString(validator)) {
|
|
21322
|
+
const gvItem = VXETable.validators.get(validator);
|
|
21323
|
+
if (gvItem) {
|
|
21324
|
+
if (gvItem.itemValidatorMethod) {
|
|
21325
|
+
customValid = gvItem.itemValidatorMethod(validParams);
|
|
21326
|
+
} else {
|
|
21327
|
+
if (true) {
|
|
21328
|
+
warnLog('vxe.error.notValidators', [validator]);
|
|
21329
|
+
}
|
|
21330
|
+
}
|
|
21331
|
+
} else {
|
|
21332
|
+
if (true) {
|
|
21333
|
+
errLog('vxe.error.notValidators', [validator]);
|
|
21334
|
+
}
|
|
21335
|
+
}
|
|
21336
|
+
} else {
|
|
21337
|
+
customValid = validator(validParams);
|
|
21338
|
+
}
|
|
21163
21339
|
if (customValid) {
|
|
21164
21340
|
if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isError(customValid)) {
|
|
21165
21341
|
errorRules.push(new form_Rule({
|
|
@@ -23059,7 +23235,8 @@ const lineOffsetSizes = {
|
|
|
23059
23235
|
refTableBody,
|
|
23060
23236
|
refTableFooter,
|
|
23061
23237
|
refTableLeftBody,
|
|
23062
|
-
refTableRightBody
|
|
23238
|
+
refTableRightBody,
|
|
23239
|
+
refValidTooltip
|
|
23063
23240
|
} = $xetable.getRefMaps();
|
|
23064
23241
|
const {
|
|
23065
23242
|
computeEditOpts,
|
|
@@ -23172,6 +23349,7 @@ const lineOffsetSizes = {
|
|
|
23172
23349
|
const renderColumn = (seq, rowid, fixedType, rowLevel, row, rowIndex, $rowIndex, _rowIndex, column, $columnIndex, columns, items) => {
|
|
23173
23350
|
const {
|
|
23174
23351
|
columnKey,
|
|
23352
|
+
height,
|
|
23175
23353
|
showOverflow: allColumnOverflow,
|
|
23176
23354
|
cellClassName: allCellClassName,
|
|
23177
23355
|
cellStyle,
|
|
@@ -23238,7 +23416,7 @@ const lineOffsetSizes = {
|
|
|
23238
23416
|
const tdOns = {};
|
|
23239
23417
|
const cellAlign = align || allAlign;
|
|
23240
23418
|
const errorValidItem = validErrorMaps[`${rowid}:${column.id}`];
|
|
23241
|
-
const showValidTip = editRules && validOpts.showMessage;
|
|
23419
|
+
const showValidTip = editRules && validOpts.showMessage && (validOpts.message === 'default' ? height || tableData.length > 1 : validOpts.message === 'inline');
|
|
23242
23420
|
const attrs = {
|
|
23243
23421
|
colid: column.id
|
|
23244
23422
|
};
|
|
@@ -23648,6 +23826,7 @@ const lineOffsetSizes = {
|
|
|
23648
23826
|
const tableFooter = refTableFooter.value;
|
|
23649
23827
|
const leftBody = refTableLeftBody.value;
|
|
23650
23828
|
const rightBody = refTableRightBody.value;
|
|
23829
|
+
const validTip = refValidTooltip.value;
|
|
23651
23830
|
const scrollBodyElem = refElem.value;
|
|
23652
23831
|
const headerElem = tableHeader ? tableHeader.$el : null;
|
|
23653
23832
|
const footerElem = tableFooter ? tableFooter.$el : null;
|
|
@@ -23698,6 +23877,9 @@ const lineOffsetSizes = {
|
|
|
23698
23877
|
if (scrollYLoad && isRollY) {
|
|
23699
23878
|
$xetable.triggerScrollYEvent(evnt);
|
|
23700
23879
|
}
|
|
23880
|
+
if (isRollX && validTip && validTip.reactData.visible) {
|
|
23881
|
+
validTip.updatePlacement();
|
|
23882
|
+
}
|
|
23701
23883
|
$xetable.dispatchEvent('scroll', {
|
|
23702
23884
|
type: renderType,
|
|
23703
23885
|
fixed: fixedType,
|
|
@@ -24512,7 +24694,8 @@ function mergeFooterMethod(mergeFooterList, _rowIndex, _columnIndex) {
|
|
|
24512
24694
|
} = $xetable;
|
|
24513
24695
|
const {
|
|
24514
24696
|
refTableHeader,
|
|
24515
|
-
refTableBody
|
|
24697
|
+
refTableBody,
|
|
24698
|
+
refValidTooltip
|
|
24516
24699
|
} = $xetable.getRefMaps();
|
|
24517
24700
|
const {
|
|
24518
24701
|
computeTooltipOpts,
|
|
@@ -24538,6 +24721,7 @@ function mergeFooterMethod(mergeFooterList, _rowIndex, _columnIndex) {
|
|
|
24538
24721
|
const {
|
|
24539
24722
|
lastScrollLeft
|
|
24540
24723
|
} = tableInternalData;
|
|
24724
|
+
const validTip = refValidTooltip.value;
|
|
24541
24725
|
const tableHeader = refTableHeader.value;
|
|
24542
24726
|
const tableBody = refTableBody.value;
|
|
24543
24727
|
const headerElem = tableHeader ? tableHeader.$el : null;
|
|
@@ -24556,6 +24740,9 @@ function mergeFooterMethod(mergeFooterList, _rowIndex, _columnIndex) {
|
|
|
24556
24740
|
if (scrollXLoad && isX) {
|
|
24557
24741
|
$xetable.triggerScrollXEvent(evnt);
|
|
24558
24742
|
}
|
|
24743
|
+
if (isX && validTip && validTip.reactData.visible) {
|
|
24744
|
+
validTip.updatePlacement();
|
|
24745
|
+
}
|
|
24559
24746
|
$xetable.dispatchEvent('scroll', {
|
|
24560
24747
|
type: footer_renderType,
|
|
24561
24748
|
fixed: fixedType,
|
|
@@ -25133,6 +25320,7 @@ const orderStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_ORDER';
|
|
|
25133
25320
|
const refElem = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
|
|
25134
25321
|
const refTooltip = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
|
|
25135
25322
|
const refCommTooltip = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
|
|
25323
|
+
const refValidTooltip = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
|
|
25136
25324
|
const refTableFilter = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
|
|
25137
25325
|
const refTableMenu = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
|
|
25138
25326
|
const refTableHeader = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
|
|
@@ -25204,6 +25392,12 @@ const orderStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_ORDER';
|
|
|
25204
25392
|
...tooltipStore.currOpts
|
|
25205
25393
|
};
|
|
25206
25394
|
});
|
|
25395
|
+
const computeValidTipOpts = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
25396
|
+
const tooltipOpts = computeTooltipOpts.value;
|
|
25397
|
+
return Object.assign({
|
|
25398
|
+
isArrow: false
|
|
25399
|
+
}, tooltipOpts);
|
|
25400
|
+
});
|
|
25207
25401
|
const computeEditOpts = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
25208
25402
|
return Object.assign({}, conf.table.editConfig, props.editConfig);
|
|
25209
25403
|
});
|
|
@@ -25364,6 +25558,7 @@ const orderStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_ORDER';
|
|
|
25364
25558
|
const refMaps = {
|
|
25365
25559
|
refElem,
|
|
25366
25560
|
refTooltip,
|
|
25561
|
+
refValidTooltip,
|
|
25367
25562
|
refTableFilter,
|
|
25368
25563
|
refTableMenu,
|
|
25369
25564
|
refTableHeader,
|
|
@@ -29632,7 +29827,7 @@ const orderStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_ORDER';
|
|
|
29632
29827
|
* 如果组件值 v-model 发生 change 时,调用改函数用于更新某一列编辑状态
|
|
29633
29828
|
* 如果单元格配置了校验规则,则会进行校验
|
|
29634
29829
|
*/
|
|
29635
|
-
updateStatus(
|
|
29830
|
+
updateStatus(slotParams, cellValue) {
|
|
29636
29831
|
const customVal = !external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isUndefined(cellValue);
|
|
29637
29832
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)().then(() => {
|
|
29638
29833
|
const {
|
|
@@ -29642,11 +29837,11 @@ const orderStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_ORDER';
|
|
|
29642
29837
|
validStore
|
|
29643
29838
|
} = reactData;
|
|
29644
29839
|
const tableBody = refTableBody.value;
|
|
29645
|
-
if (
|
|
29840
|
+
if (slotParams && tableBody && editRules) {
|
|
29646
29841
|
const {
|
|
29647
29842
|
row,
|
|
29648
29843
|
column
|
|
29649
|
-
} =
|
|
29844
|
+
} = slotParams;
|
|
29650
29845
|
const type = 'change';
|
|
29651
29846
|
if ($xetable.hasCellRules) {
|
|
29652
29847
|
if ($xetable.hasCellRules(type, row, column)) {
|
|
@@ -29789,13 +29984,16 @@ const orderStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_ORDER';
|
|
|
29789
29984
|
filterStore
|
|
29790
29985
|
} = reactData;
|
|
29791
29986
|
const {
|
|
29792
|
-
mouseConfig
|
|
29987
|
+
mouseConfig,
|
|
29988
|
+
editRules
|
|
29793
29989
|
} = props;
|
|
29794
29990
|
const el = refElem.value;
|
|
29795
29991
|
const editOpts = computeEditOpts.value;
|
|
29992
|
+
const validOpts = computeValidOpts.value;
|
|
29796
29993
|
const {
|
|
29797
29994
|
actived
|
|
29798
29995
|
} = editStore;
|
|
29996
|
+
const $validTooltip = refValidTooltip.value;
|
|
29799
29997
|
const tableFilter = refTableFilter.value;
|
|
29800
29998
|
const tableMenu = refTableMenu.value;
|
|
29801
29999
|
if (tableFilter) {
|
|
@@ -29815,7 +30013,9 @@ const orderStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_ORDER';
|
|
|
29815
30013
|
// 如果是激活状态,点击了单元格之外
|
|
29816
30014
|
const cell = actived.args.cell;
|
|
29817
30015
|
if (!cell || !getEventTargetNode(evnt, cell).flag) {
|
|
29818
|
-
if (
|
|
30016
|
+
if ($validTooltip && getEventTargetNode(evnt, $validTooltip.$el).flag) {
|
|
30017
|
+
// 如果是激活状态,且点击了校验提示框
|
|
30018
|
+
} else if (!internalData._lastCallTime || internalData._lastCallTime + 50 < Date.now()) {
|
|
29819
30019
|
// 如果是激活状态,点击了单元格之外
|
|
29820
30020
|
if (!getEventTargetNode(evnt, document.body, 'vxe-table--ignore-clear').flag) {
|
|
29821
30021
|
// 如果手动调用了激活单元格,避免触发源被移除后导致重复关闭
|
|
@@ -29874,8 +30074,13 @@ const orderStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_ORDER';
|
|
|
29874
30074
|
$xetable.closeMenu();
|
|
29875
30075
|
}
|
|
29876
30076
|
}
|
|
30077
|
+
const isActivated = getEventTargetNode(evnt, $xegrid ? $xegrid.getRefMaps().refElem.value : el).flag;
|
|
30078
|
+
// 如果存在校验,点击了表格之外则清除
|
|
30079
|
+
if (!isActivated && editRules && validOpts.autoClear) {
|
|
30080
|
+
reactData.validErrorMaps = {};
|
|
30081
|
+
}
|
|
29877
30082
|
// 最后激活的表格
|
|
29878
|
-
internalData.isActivated =
|
|
30083
|
+
internalData.isActivated = isActivated;
|
|
29879
30084
|
};
|
|
29880
30085
|
/**
|
|
29881
30086
|
* 窗口失焦事件处理
|
|
@@ -32141,13 +32346,15 @@ const orderStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_ORDER';
|
|
|
32141
32346
|
loading,
|
|
32142
32347
|
stripe,
|
|
32143
32348
|
showHeader,
|
|
32349
|
+
height,
|
|
32144
32350
|
treeConfig,
|
|
32145
32351
|
mouseConfig,
|
|
32146
32352
|
showFooter,
|
|
32147
32353
|
highlightCell,
|
|
32148
32354
|
highlightHoverRow,
|
|
32149
32355
|
highlightHoverColumn,
|
|
32150
|
-
editConfig
|
|
32356
|
+
editConfig,
|
|
32357
|
+
editRules
|
|
32151
32358
|
} = props;
|
|
32152
32359
|
const {
|
|
32153
32360
|
isGroup,
|
|
@@ -32170,18 +32377,21 @@ const orderStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_ORDER';
|
|
|
32170
32377
|
} = columnStore;
|
|
32171
32378
|
const loadingSlot = slots.loading;
|
|
32172
32379
|
const tipConfig = computeTipConfig.value;
|
|
32380
|
+
const validOpts = computeValidOpts.value;
|
|
32173
32381
|
const treeOpts = computeTreeOpts.value;
|
|
32174
32382
|
const rowOpts = computeRowOpts.value;
|
|
32175
32383
|
const columnOpts = computeColumnOpts.value;
|
|
32176
32384
|
const vSize = computeSize.value;
|
|
32177
32385
|
const tableBorder = computeTableBorder.value;
|
|
32178
32386
|
const mouseOpts = computeMouseOpts.value;
|
|
32387
|
+
const validTipOpts = computeValidTipOpts.value;
|
|
32179
32388
|
const loadingOpts = computeLoadingOpts.value;
|
|
32180
32389
|
const isMenu = computeIsMenu.value;
|
|
32181
32390
|
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('div', {
|
|
32182
32391
|
ref: refElem,
|
|
32183
32392
|
class: ['vxe-table', 'vxe-table--render-default', `tid_${xID}`, `border--${tableBorder}`, {
|
|
32184
32393
|
[`size--${vSize}`]: vSize,
|
|
32394
|
+
[`vaild-msg--${validOpts.msgMode}`]: !!editRules,
|
|
32185
32395
|
'vxe-editable': !!editConfig,
|
|
32186
32396
|
'cell--highlight': highlightCell,
|
|
32187
32397
|
'cell--selected': mouseConfig && mouseOpts.selected,
|
|
@@ -32325,6 +32535,14 @@ const orderStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_ORDER';
|
|
|
32325
32535
|
isArrow: false,
|
|
32326
32536
|
enterable: false
|
|
32327
32537
|
}) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)(),
|
|
32538
|
+
/**
|
|
32539
|
+
* 校验提示
|
|
32540
|
+
*/
|
|
32541
|
+
hasUseTooltip && props.editRules && validOpts.showMessage && (validOpts.message === 'default' ? !height : validOpts.message === 'tooltip') ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.resolveComponent)('vxe-tooltip'), {
|
|
32542
|
+
ref: refValidTooltip,
|
|
32543
|
+
class: 'vxe-table--valid-error',
|
|
32544
|
+
...(validOpts.message === 'tooltip' || tableData.length === 1 ? validTipOpts : {})
|
|
32545
|
+
}) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)(),
|
|
32328
32546
|
/**
|
|
32329
32547
|
* 工具提示
|
|
32330
32548
|
*/
|
|
@@ -32356,6 +32574,10 @@ dynamicApp.component(table.name, table);
|
|
|
32356
32574
|
;// CONCATENATED MODULE: ./packages/locale/lang/zh-CN.ts
|
|
32357
32575
|
/* harmony default export */ var zh_CN = ({
|
|
32358
32576
|
vxe: {
|
|
32577
|
+
base: {
|
|
32578
|
+
pleaseInput: '请输入',
|
|
32579
|
+
pleaseSelect: '请选择'
|
|
32580
|
+
},
|
|
32359
32581
|
loading: {
|
|
32360
32582
|
text: '加载中...'
|
|
32361
32583
|
},
|
|
@@ -32375,6 +32597,7 @@ dynamicApp.component(table.name, table);
|
|
|
32375
32597
|
errProp: '不支持的参数 "{0}",可能为 "{1}"',
|
|
32376
32598
|
colRepet: 'column.{0}="{1}" 重复了,这可能会导致某些功能无法使用',
|
|
32377
32599
|
notFunc: '方法 "{0}" 不存在',
|
|
32600
|
+
notValidators: '全局校验 "{0}" 不存在',
|
|
32378
32601
|
notSlot: '插槽 "{0}" 不存在',
|
|
32379
32602
|
noTree: '树结构不支持 "{0}"',
|
|
32380
32603
|
notProp: '不支持的参数 "{0}"',
|