Skip to content

Commit 7320dd4

Browse files
committed
fix #1099
1 parent f5d3789 commit 7320dd4

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

src/TableBody.js

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -321,13 +321,20 @@ class TableBody extends Component {
321321
}
322322

323323
handleEditCell = (rowIndex, columnIndex, action, e) => {
324-
if (this._isSelectRowDefined()) {
324+
const defineSelectRow = this._isSelectRowDefined();
325+
const expandColumnVisible = this._isExpandColumnVisible();
326+
if (defineSelectRow) {
325327
columnIndex--;
326328
if (this.props.selectRow.hideSelectColumn) columnIndex++;
327329
}
330+
if (expandColumnVisible) {
331+
columnIndex--;
332+
}
328333
rowIndex--;
329334

330335
if (action === 'tab') {
336+
if (defineSelectRow) columnIndex++;
337+
if (expandColumnVisible) columnIndex++;
331338
this.handleCompleteEditCell(e.target.value, rowIndex, columnIndex - 1);
332339
if (columnIndex >= this.props.columns.length) {
333340
rowIndex = rowIndex + 1;

0 commit comments

Comments
 (0)