fix editable header column not hiding when grid is un-editable

This commit is contained in:
kevmodrome 2020-10-12 20:44:40 +02:00
parent 41e23e78ce
commit 9923266c51
1 changed files with 2 additions and 2 deletions

View File

@ -43,8 +43,8 @@
data = await fetchData(datasource) data = await fetchData(datasource)
columnDefs = Object.keys(schema).map((key, i) => { columnDefs = Object.keys(schema).map((key, i) => {
return { return {
headerCheckboxSelection: i === 0, headerCheckboxSelection: i === 0 && editable,
checkboxSelection: i === 0, checkboxSelection: i === 0 && editable,
valueSetter: setters.get(schema[key].type), valueSetter: setters.get(schema[key].type),
headerName: key.charAt(0).toUpperCase() + key.slice(1), headerName: key.charAt(0).toUpperCase() + key.slice(1),
field: key, field: key,