Odoo POS弹出窗口小部件文本输入无效

时间:2017-05-30 06:59:11

标签: javascript popup odoo-9 odoo-10 point-of-sale

我已经为卡片付款创建了一种新的付款方式。选择此付款选项时,会出现一个弹出窗口,以便从用户处获取卡详细信息。这里我无法输入输入字段中的详细信息。 (ctrl + v正在运行)。

我测试了像 TextInputPopupWidget 这样的odoo基础弹出窗口小部件和 TextIAreaPopupWidget 两者都不起作用,无法键入值。

任何解决方案。?

1 个答案:

答案 0 :(得分:0)

键盘在POS的付款时间被阻止。所以你需要覆盖两个

this.keyboard_handler = function(event){
var key = '';
            if (event.type === "keypress") {
                if($(".your popup div class").not('.oe_hidden').length){
                    return;
                }

              rest of code......
};

and 

this.keyboard_keydown_handler = function(event){
            if($(".your popup div class").not('.oe_hidden').length){
                return;
            }
     rest of code......
};

Thanks