在Odoo(POS)的头文件中添加一个按钮

时间:2017-12-09 13:09:25

标签: odoo-10 point-of-sale

我在POS(Odoo)的标题行中创建新图像按钮时遇到问题。我附上了一张图片,告诉你我想要这个锁定图像的位置。(在odoo符号和管理员之间)enter image description here 这是我在xml文件中所做的事情。 (所有文件都完美地包含在清单 .py中。)

<?xml version="1.0" encoding="UTF-8"?>
<templates id="template" xml:space="preserve">
    <t t-extend="Chrome">
        <t t-jquery="div.pos-branding img.pos-logo" t-operation="after">
            <span class="order-button lock_button">
                <i class="fa fa-lock" aria-hidden="true"></i>
            </span>
        </t>
    </t>
</templates>

1 个答案:

答案 0 :(得分:2)

(已加入)在Odoo @ v10(POS)的标题文件中添加按钮图标

Code

    <?xml version="1.0" encoding="UTF-8"?>
    <templates id="template" xml:space="preserve">
        <t t-extend="Chrome">
           <t t-jquery="div.pos-branding img.pos-logo" t-operation="after">
             <span>
                 <i class="fa fa-lock fa-lg" aria-hidden="true"></i>
             </span>
           </t>
        </t>  
   </templates> 

同时附上图片:enter image description here