Search code examples
javascriptjquerypython-2.7openerp-7one2many

How to use "Enter" key insted of "Tab" key in openerp 7 for one2many field


I am working in sale order line and currently by pressing "Enter" key in one2many field it is creating new line, but I want to do some changes so Enter key work as TAB key ,It means if I pressed Enter key then insted of creating new line it should focus on next field of one2many.

Example:

There are 4 fields in one line so when I pressed enter key it should switch to next field in same line insted of creating new line.


Solution

  • I am giving answer to my question .. Actually I tried and found one solution from the following link:

    From odoo forum

    There are some issue which I found in that answer but didn't able to solve that :(

    Issues are:

    (1) I make change in base model of web in that "view_list_editable.js" as told in this link insted of my custom model.

    (2) Also when any read-only fields is there in between One2Many visible fields then this solution is not working..