Files
account-financial-tools/account_reversal/views/account_move_view.xml
Cédric Pigeon (ACSONE) a605243de3 [10.0][MIG] account_reversal migration (#445)
* OCA Transbot updated translations from Transifex
* Add option to reconcile the reversal move with the original move (#387)
* [IMP] account_reversal: Several improvements
* Default date for reverse move is not start_date of the period following the period of the original move (and not the period following today's period)
* Return form view of account.move if only 1 move is reversed
* Add option to reconcile with the reversal entry.
* [10.0][MIG] account_reversal migration
* [CHG] skid Odoo method to allow better performance on huge volume
2017-05-05 17:57:47 -05:00

60 lines
2.3 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright 2011 Alexis de Lattre <alexis.delattre@akretion.com>
Copyright 2016 Antonio Espinosa <antonio.espinosa@tecnativa.com>
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). -->
<odoo>
<record id="view_move_tree" model="ir.ui.view">
<field name="name">Add to_be_reversed column</field>
<field name="model">account.move</field>
<field name="inherit_id" ref="account.view_move_tree" />
<field name="arch" type="xml">
<field name="state" position="after">
<field name="to_be_reversed"/>
</field>
</field>
</record>
<record id="view_move_form" model="ir.ui.view">
<field name="name">Add to_be_reversed and reversal_id fields</field>
<field name="model">account.move</field>
<field name="inherit_id" ref="account.view_move_form"/>
<field name="arch" type="xml">
<button name="%(account.action_view_account_move_reversal)d" position="attributes">
<attribute name="name">%(act_account_move_reverse)d</attribute>
</button>
<xpath expr="//field[@name='company_id']" position="after">
<field name="to_be_reversed"/>
<field name="reversal_id"
attrs="{'invisible': [('to_be_reversed', '=', False), ('reversal_id', '=', False)]}"/>
</xpath>
</field>
</record>
<record id="view_account_move_filter" model="ir.ui.view">
<field name="name">Add to_be_reversed filter</field>
<field name="model">account.move</field>
<field name="inherit_id" ref="account.view_account_move_filter" />
<field name="arch" type="xml">
<field name="date" position="after">
<filter name="to_be_reversed"
string="To Be Reversed"
domain="[('to_be_reversed', '=', True), ('reversal_id', '=', False)]"
help="Journal Entries to be Reversed"/>
</field>
</field>
</record>
<act_window
context="{'search_default_to_be_reversed':1}"
id="action_move_to_be_reversed" name="Journal Entries to be Reversed"
res_model="account.move"
view_id="account.view_move_tree"/>
<menuitem id="menu_move_to_be_reversed"
parent="account.menu_finance_entries" sequence="80"
name="Journal Entries to be Reversed"
action="action_move_to_be_reversed"/>
</odoo>