You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

30 lines
1.4 KiB

  1. <?xml version="1.0"?>
  2. <openerp>
  3. <data>
  4. <record id="act_analytic_invoices" model="ir.actions.act_window">
  5. <field name="context">{'search_default_analytic_account_ids':
  6. [active_id], 'default_analytic_account_ids': active_id}</field>
  7. <field name="name">Invoices</field>
  8. <field name="res_model">account.invoice</field>
  9. <field name="domain">[('analytic_account_ids','=',active_id)]</field>
  10. <field name="view_id" ref="account.invoice_tree" />
  11. <field name="search_view_id" ref="account.view_account_invoice_filter" />
  12. </record>
  13. <record id="account_analytic_account_button_invoice" model="ir.ui.view">
  14. <field name="name">account.analytic.account.button.invoice
  15. </field>
  16. <field name="model">account.analytic.account</field>
  17. <field name="inherit_id" ref="analytic.view_account_analytic_account_form" />
  18. <field name="arch" type="xml">
  19. <xpath expr='//div[@name="buttons"]' position='inside'>
  20. <button class="oe_stat_button" type="action" icon="fa-edit"
  21. name="%(contract_show_invoice.act_analytic_invoices)d"
  22. string="Invoices" help="Invoices related with this contract">
  23. </button>
  24. </xpath>
  25. </field>
  26. </record>
  27. </data>
  28. </openerp>