diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index fa6e933cefc..148c79b3efd 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -3978,7 +3978,7 @@ instance.web.form.One2ManyListView = instance.web.ListView.extend({ } this.cancel_edition(); }, - keyup_ENTER: function () { + keypress_ENTER: function () { // blurring caused by hitting the [Return] key, should skip the // autosave-on-blur and let the handler for [Return] do its thing (save // the current row *anyway*, then create a new one/edit the next one) diff --git a/addons/web/static/src/js/view_list_editable.js b/addons/web/static/src/js/view_list_editable.js index 4c7e4655054..53ea069cee6 100644 --- a/addons/web/static/src/js/view_list_editable.js +++ b/addons/web/static/src/js/view_list_editable.js @@ -459,7 +459,7 @@ openerp.web.list_editable = function (instance) { }); }); - this.editor.$el.on('keyup keydown', function (e) { + this.editor.$el.on('keyup keypress keydown', function (e) { if (!self.editor.is_editing()) { return true; } var key = _($.ui.keyCode).chain() .map(function (v, k) { return {name: k, code: v}; }) @@ -494,7 +494,7 @@ openerp.web.list_editable = function (instance) { return self.start_edition(record, options); }); }, - keyup_ENTER: function () { + keypress_ENTER: function () { return this._next(); }, keydown_ESCAPE: function (e) {