invoice_view.xml 2.46 KB
Newer Older
François C. committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55
<openerp>
  <data>
    <record id="invoice_voucher_group" model="ir.ui.view">
      <field name="name">Hide voucher in invoice</field>
      <field name="model">account.invoice</field>
      <field name="inherit_id" ref="account_voucher.view_invoice_customer" />
      <field name="arch" type="xml">
        <xpath expr="//button[@name='invoice_pay_customer'][last()]"
               position="attributes">
           <attribute name="groups">account_voucher_killer.invoice_voucher_user</attribute>
        </xpath>
        <xpath expr="//button[@name='invoice_pay_customer'][1]"
               position="attributes">
           <attribute name="groups">account_voucher_killer.invoice_voucher_user</attribute>
        </xpath>
      </field>
    </record>

    <record id="invoice_voucher_group_supp_inv" model="ir.ui.view">
      <field name="name">Hide voucher in supplier invoice</field>
      <field name="model">account.invoice</field>
      <field name="inherit_id" ref="account_voucher.view_invoice_supplier" />
      <field name="arch" type="xml">
        <xpath expr="//button[@name='invoice_pay_customer'][last()]"
               position="attributes">
           <attribute name="groups">account_voucher_killer.invoice_voucher_user</attribute>
        </xpath>
      </field>
    </record>

   <record id="account_voucher.menu_action_sale_receipt" model="ir.ui.menu">
       <field name="groups_id" eval="[(6,0,[ref('account_voucher_killer.invoice_voucher_user')])]"/>
   </record>
   
   <record id="account_voucher.menu_action_vendor_receipt" model="ir.ui.menu">
       <field name="groups_id" eval="[(6,0,[ref('account_voucher_killer.invoice_voucher_user')])]"/>
   </record>
   
   <record id="account_voucher.menu_action_purchase_receipt" model="ir.ui.menu">
       <field name="groups_id" eval="[(6,0,[ref('account_voucher_killer.invoice_voucher_user')])]"/>
   </record>
   
   <record id="account_voucher.menu_action_vendor_payment" model="ir.ui.menu">
       <field name="groups_id" eval="[(6,0,[ref('account_voucher_killer.invoice_voucher_user')])]"/>
   </record>
   
   <record id="account_voucher.menu_encode_entries_by_voucher" model="ir.ui.menu">
       <field name="groups_id" eval="[(6,0,[ref('account_voucher_killer.invoice_voucher_user')])]"/>
   </record>
   
   <record id="account_voucher.menu_action_sale_receipt_report_all" model="ir.ui.menu">
       <field name="groups_id" eval="[(6,0,[ref('account_voucher_killer.invoice_voucher_user')])]"/>
   </record>
  </data>
</openerp>