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.

71 lines
3.3 KiB

  1. <?xml version="1.0" encoding="utf-8"?>
  2. <!-- Copyright 2016 Lorenzo Battistini - Agile Business Group
  3. Copyright 2016 Antonio Espinosa <antonio.espinosa@tecnativa.com>
  4. License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). -->
  5. <odoo>
  6. <record id="view_tax_tree_balance" model="ir.ui.view">
  7. <field name="name">account.tax.tree.balance</field>
  8. <field name="model">account.tax</field>
  9. <field eval="100" name="priority"/>
  10. <field name="arch" type="xml">
  11. <tree string="Account Tax" create="false" delete="false">
  12. <field name="name"/>
  13. <field name="description" string="Short Name"/>
  14. <field name="account_id"/>
  15. <field name="balance_regular" sum="Total"/>
  16. <button type="object" name="view_tax_regular_lines"
  17. string="View tax regular lines" icon="fa-search-plus"/>
  18. <field name="base_balance_regular" sum="Base Total"/>
  19. <button type="object" name="view_base_regular_lines"
  20. string="View base regular lines" icon="fa-search-plus"/>
  21. <field name="balance_refund" sum="Total"/>
  22. <button type="object" name="view_tax_refund_lines"
  23. string="View tax refund lines" icon="fa-search-plus"/>
  24. <field name="base_balance_refund" sum="Base Total"/>
  25. <button type="object" name="view_base_refund_lines"
  26. string="View base refund lines" icon="fa-search-plus"/>
  27. <field name="balance" sum="Total"/>
  28. <button type="object" name="view_tax_lines"
  29. string="View tax lines" icon="fa-search-plus"/>
  30. <field name="base_balance" sum="Base Total"/>
  31. <button type="object" name="view_base_lines"
  32. string="View base lines" icon="fa-search-plus"/>
  33. </tree>
  34. </field>
  35. </record>
  36. <record id="view_tax_search_balance" model="ir.ui.view">
  37. <field name="name">account.tax.search.balance</field>
  38. <field name="model">account.tax</field>
  39. <field eval="100" name="priority"/>
  40. <field name="arch" type="xml">
  41. <search string="Account Tax">
  42. <field name="name"/>
  43. <field name="tag_ids"/>
  44. <field name="description" string="Short Name"/>
  45. <field name="type_tax_use"/>
  46. <field name="account_id"/>
  47. <group expand="0" string="Group By">
  48. <filter string="Tax Group" domain="[]" context="{'group_by':'tax_group_id'}"/>
  49. <filter string="Tax Scope" domain="[]" context="{'group_by':'type_tax_use'}"/>
  50. <filter string="Account" domain="[]" context="{'group_by':'account_id'}"/>
  51. </group>
  52. </search>
  53. </field>
  54. </record>
  55. <record id="action_tax_balances_tree" model="ir.actions.act_window">
  56. <field name="name">Taxes Balance</field>
  57. <field name="res_model">account.tax</field>
  58. <field name="view_type">form</field>
  59. <field name="view_mode">tree</field>
  60. <field name="domain">[
  61. '|', '|', ('base_balance', '!=', 0), ('base_balance_regular', '!=', 0),
  62. '|', '|', ('base_balance_refund', '!=', 0), ('balance', '!=', 0),
  63. '|', ('balance_regular', '!=', 0), ('balance_refund', '!=', 0)]</field>
  64. <field name="view_id" ref="view_tax_tree_balance"/>
  65. <field name="search_view_id" ref="view_tax_search_balance"/>
  66. </record>
  67. </odoo>