Browse Source

🚑 clicking numbers and enter in selection popups

pull/155/head
KolushovAlexandr 6 years ago
committed by Vincent Van Rossem
parent
commit
57835656a1
  1. 1
      pos_keyboard/__manifest__.py
  2. 7
      pos_keyboard/doc/changelog.rst
  3. 8
      pos_keyboard/static/src/js/pos.js

1
pos_keyboard/__manifest__.py

@ -26,6 +26,7 @@
], ],
"external_dependencies": {"python": [], "bin": []}, "external_dependencies": {"python": [], "bin": []},
"data": [ "data": [
"data.xml"
], ],
"demo": [ "demo": [
], ],

7
pos_keyboard/doc/changelog.rst

@ -1,7 +1,8 @@
.. _changelog:
`1.1.2`
-------
**Fix:** Error on clicking numbers and enter in selection popups
Updates
=======
`1.1.1` `1.1.1`
------- -------

8
pos_keyboard/static/src/js/pos.js

@ -50,12 +50,18 @@ odoo.define('pos_keyboard.pos', function (require) {
} else if (data.type === type.backspace){ } else if (data.type === type.backspace){
this.click_keyboard('BACKSPACE'); this.click_keyboard('BACKSPACE');
} else if (data.type === type.enter){ } else if (data.type === type.enter){
this.click_confirm();
if (this.click_confirm.length) {
return this.click_confirm();
}
return;
} else if (data.type === type.escape){ } else if (data.type === type.escape){
this.click_cancel(); this.click_cancel();
} }
}, },
click_keyboard: function(value){ click_keyboard: function(value){
if (typeof this.inputbuffer === 'undefined') {
return;
}
var newbuf = this.gui.numpad_input( var newbuf = this.gui.numpad_input(
this.inputbuffer, this.inputbuffer,
value, value,

Loading…
Cancel
Save