fix: focus on child table

This commit is contained in:
sokumon 2025-11-06 17:05:14 +05:30
parent 66b3fb52b0
commit 071d0e6b97

View file

@ -1121,14 +1121,14 @@ export default class GridRow {
this.columns[df.fieldname] = $col;
this.columns_list.push($col);
if (ci == 0 && !this.header_row) {
if (ci == 0 && this.header_row) {
$col.attr("tabIndex", 0);
$col.on("focus", function () {
if (me.grid.grid_rows.length == 0) {
me.grid.add_new_row();
}
me.grid.grid_rows[me.grid.grid_rows.length - 1].toggle_editable_row(true);
me.grid.set_focus_on_row();
me.grid.set_focus_on_row(0);
$col.attr("tabIndex", "");
});
}