Table: add indeterminate state to multiple selection header checkbox (#9363)

* Table: Add indeterminate and disabled state to multiple selection header checkbox

* Remove disabled state handling of select-all checkbox
This commit is contained in:
syn-zeta 2018-01-29 18:36:36 -08:00 committed by 杨奕
parent 575e2d1307
commit ca02cb9cd3

View File

@ -32,8 +32,9 @@ const defaults = {
const forced = {
selection: {
renderHeader: function(h) {
renderHeader: function(h, { store }) {
return <el-checkbox
indeterminate={ store.states.selection.length > 0 && !this.isAllSelected }
nativeOn-click={ this.toggleAllSelection }
value={ this.isAllSelected } />;
},