mirror of
https://github.com/overte-org/overte.git
synced 2025-07-23 00:34:22 +02:00
jump to input for next row after enter on previous row
This commit is contained in:
parent
a6c5f4308a
commit
ee36b6b91a
1 changed files with 4 additions and 2 deletions
|
@ -109,11 +109,13 @@ $(document).ready(function(){
|
|||
sibling = $(this).parent('td').next();
|
||||
|
||||
if (sibling.hasClass(Settings.DATA_COL_CLASS)) {
|
||||
// jump to that input
|
||||
// set focus to next input
|
||||
sibling.find('input').focus()
|
||||
} else if (sibling.hasClass(Settings.TABLE_BUTTONS_CLASS)) {
|
||||
sibling.find('.' + Settings.ADD_ROW_BUTTON_CLASS).click()
|
||||
$(this).blur()
|
||||
|
||||
// set focus to the first input in the new row
|
||||
$(this).closest('table').find('tr.inputs input:first').focus()
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue