Table: 修复 el-table-column 中切换 type DOM 不更新以及多选框表头与内容不对齐的问题

pull/21360/head
gaosheng08 2021-10-05 21:49:41 +08:00
parent 492ab00ad7
commit e96cdee8ea
2 changed files with 6 additions and 3 deletions

View File

@ -195,7 +195,7 @@ export default {
},
registerNormalWatchers() {
const props = ['label', 'property', 'filters', 'filterMultiple', 'sortable', 'index', 'formatter', 'className', 'labelClassName', 'showOverflowTooltip'];
const props = ['type', 'label', 'property', 'filters', 'filterMultiple', 'sortable', 'index', 'formatter', 'className', 'labelClassName', 'showOverflowTooltip'];
// 一些属性具有别名
const aliases = {
prop: 'property',
@ -213,6 +213,9 @@ export default {
this.$watch(key, (newVal) => {
this.columnConfig[columnKey] = newVal;
if (key === 'type') {
compose(this.setColumnRenders, this.setColumnWidth, this.setColumnForcedProps)(this.columnConfig);
}
});
});
},

View File

@ -3,7 +3,7 @@
@import "tag";
@import "common/var";
@include b(table-column) {
@include b(el-table table-column) {
@include m(selection) {
.cell {
padding-left: 14px;