[ADD] account_statement_completion_voucher to better adapt the views of bank statement

(lp:c2c-financial-addons/6.1 rev 24.1.38)
This commit is contained in:
Joël Grand-Guillaume
2012-06-26 17:27:25 +02:00
parent e6ec523f77
commit b587cb45eb
5 changed files with 101 additions and 6 deletions

View File

@@ -10,9 +10,6 @@
<field name="type">form</field>
<field name="arch" type="xml">
<data>
<xpath expr="/form/notebook/page/field[@name='line_ids']/tree/field[@name='sequence']" position="before">
<field name="already_completed" />
</xpath>
<xpath expr="/form/notebook/page/field[@name='line_ids']/form/field[@name='sequence']" position="after">
<separator colspan="4" string="Importation related infos"/>
<field name="label" />
@@ -36,6 +33,19 @@
</data>
</field>
</record>
<record id="bank_statement_view_form2" model="ir.ui.view">
<field name="name">account_bank_statement_import_base.bank_statement.auto_cmpl</field>
<field name="model">account.bank.statement</field>
<field name="inherit_id" ref="account.view_bank_statement_form" />
<field name="type">form</field>
<field name="arch" type="xml">
<data>
<xpath expr="/form/notebook/page/field[@name='line_ids']/tree/field[@name='amount']" position="after">
<field name="already_completed" />
</xpath>
</data>
</field>
</record>
<record id="statement_rules_view_form" model="ir.ui.view">
<field name="name">account.statement.profil.view</field>

View File

@@ -0,0 +1,21 @@
# -*- coding: utf-8 -*-
##############################################################################
#
# Author: Joel Grand-Guillaume
# Copyright 2011-2012 Camptocamp SA
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################

View File

@@ -0,0 +1,44 @@
# -*- coding: utf-8 -*-
##############################################################################
#
# Author: Joel Grand-Guillaume
# Copyright 2011-2012 Camptocamp SA
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
{'name': "Bank statement extension with voucher",
'version': '1.0',
'author': 'Camptocamp',
'maintainer': 'Camptocamp',
'category': 'Finance',
'complexity': 'normal', #easy, normal, expert
'depends': ['account_statement_base_completion','account_voucher'],
'description': """
This module is only needed when using account_statement_base_completion with voucher in order adapt the view correctly.
""",
'website': 'http://www.camptocamp.com',
'init_xml': [],
'update_xml': [
"statement_view.xml",
],
'demo_xml': [],
'test': [],
'installable': True,
'images': [],
'auto_install': True,
'license': 'AGPL-3',
'active': False,
}

View File

@@ -0,0 +1,21 @@
<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
<!-- Override what we have in account_statement_base_completion to replace the one in the voucher -->
<record id="account_statement_base_completion.bank_statement_view_form2" model="ir.ui.view">
<field name="name">account_bank_statement_import_base.bank_statement.auto_cmpl</field>
<field name="model">account.bank.statement</field>
<field name="inherit_id" ref="account_voucher.view_bank_statement_tree_voucher" />
<field name="type">form</field>
<field name="arch" type="xml">
<data>
<xpath expr="/form/notebook/page/field[@name='line_ids']/tree/field[@name='voucher_id']" position="after">
<field name="already_completed" />
</xpath>
</data>
</field>
</record>
</data>
</openerp>

View File

@@ -137,12 +137,11 @@
<!-- Add a new group before the first one with name, profil and date -->
<xpath expr="/form/group[@col='7']" position="before">
<group col="8" colspan="4">
<field name="id" select="1" readonly="1"/>
<field name="name" select="1"/>
<field name="profile_id" select="1" required="1" on_change="onchange_imp_config_id(profile_id)" widget="selection"/>
<field name="date" select="1" on_change="onchange_date(date, company_id)"/>
<field name="name" select="1"/>
</group>
<separator string="Details" colspan="4"/>
<separator string="Profile Details" colspan="4"/>
</xpath>
<!-- Make balance visible or not depending on profil -->
<xpath expr="/form/group/field[@name='balance_start']" position="replace">