mirror of https://github.com/ElemeFE/element
Table: 修复 el-table-column 中切换 type DOM 不更新以及多选框表头与内容不对齐的问题
parent
492ab00ad7
commit
e96cdee8ea
|
@ -195,7 +195,7 @@ export default {
|
||||||
},
|
},
|
||||||
|
|
||||||
registerNormalWatchers() {
|
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 = {
|
const aliases = {
|
||||||
prop: 'property',
|
prop: 'property',
|
||||||
|
@ -213,6 +213,9 @@ export default {
|
||||||
|
|
||||||
this.$watch(key, (newVal) => {
|
this.$watch(key, (newVal) => {
|
||||||
this.columnConfig[columnKey] = newVal;
|
this.columnConfig[columnKey] = newVal;
|
||||||
|
if (key === 'type') {
|
||||||
|
compose(this.setColumnRenders, this.setColumnWidth, this.setColumnForcedProps)(this.columnConfig);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
@import "tag";
|
@import "tag";
|
||||||
@import "common/var";
|
@import "common/var";
|
||||||
|
|
||||||
@include b(table-column) {
|
@include b(el-table table-column) {
|
||||||
@include m(selection) {
|
@include m(selection) {
|
||||||
.cell {
|
.cell {
|
||||||
padding-left: 14px;
|
padding-left: 14px;
|
||||||
|
@ -94,4 +94,4 @@
|
||||||
margin-bottom: 0;
|
margin-bottom: 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue