[IMP] base, account: move bank accounts partner information from base to account

Before this commit, bank accounts tab on partner view is available directly
in base whereas it should not, as it contains information useful only
for accountants. We therefore move them directly to account.

Task ID: 2172260

closes odoo/odoo#43322

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
This commit is contained in:
Thibault Delavallée
2020-01-15 09:30:07 +00:00
parent 03e7a99e91
commit d6e6e2d771
3 changed files with 33 additions and 33 deletions
+32 -7
View File
@@ -166,13 +166,38 @@
<field name="inherit_id" ref="base.view_partner_form"/>
<field name="groups_id" eval="[(5,)]"/>
<field name="arch" type="xml">
<xpath expr="//group[@name='banks']" position="after">
<group string="Accounting Entries" name="accounting_entries" groups="account.group_account_user">
<field name="currency_id" invisible="1"/>
<field name="property_account_receivable_id"/>
<field name="property_account_payable_id"/>
</group>
</xpath>
<page name="sales_purchases" position="after">
<page string="Invoicing" name="accounting" attrs="{'invisible': [('is_company','=',False),('parent_id','!=',False)]}" groups="account.group_account_invoice">
<group>
<group string="Bank Accounts" name="banks" groups="account.group_account_invoice">
<field name="bank_ids" nolabel="1">
<tree editable="bottom">
<field name="sequence" widget="handle"/>
<field name="bank_id"/>
<field name="acc_number"/>
<field name="acc_holder_name" invisible="1"/>
</tree>
</field>
<button type="action" class="btn-link"
name="%(base.action_res_partner_bank_account_form)d"
context="{'search_default_partner_id': active_id, 'default_partner_id': active_id, 'form_view_ref': 'account.view_company_partner_bank_form'}"
string="View accounts detail"
colspan="2"
/>
</group>
<group string="Accounting Entries" name="accounting_entries" groups="account.group_account_user">
<field name="currency_id" invisible="1"/>
<field name="property_account_receivable_id"/>
<field name="property_account_payable_id"/>
</group>
</group>
</page>
<page string="Invoicing" name="accounting_disabled" attrs="{'invisible': ['|',('is_company','=',True),('parent_id','=',False)]}" groups="account.group_account_invoice">
<div>
<p>Accounting-related settings are managed on <button name="open_commercial_entity" type="object" string="the parent company" class="oe_link"/></p>
</div>
</page>
</page>
<xpath expr="//group[@name='misc']" position="before">
<group string="Fiscal Information" name="fiscal_information" priority="5" groups="account.group_account_invoice">
<field name="property_account_position_id" options="{'no_create': True, 'no_open': True}"/>
+1 -1
View File
@@ -63,8 +63,8 @@ The kernel of Odoo, needed for all installation.
'data/ir_demo_failure_data.xml',
'views/res_company_views.xml',
'views/res_lang_views.xml',
'views/res_bank_views.xml',
'views/res_partner_views.xml',
'views/res_bank_views.xml',
'views/res_country_views.xml',
'views/res_currency_views.xml',
'views/res_users_views.xml',
@@ -403,31 +403,6 @@
</group>
</group>
</page>
<page string="Invoicing" name="accounting" attrs="{'invisible': [('is_company','=',False),('parent_id','!=',False)]}">
<group>
<group string="Bank Accounts" name="banks">
<field name="bank_ids" nolabel="1">
<tree editable="bottom">
<field name="sequence" widget="handle"/>
<field name="bank_id"/>
<field name="acc_number"/>
<field name="acc_holder_name" invisible="1"/>
</tree>
</field>
<button type="action" class="btn-link"
name="%(base.action_res_partner_bank_account_form)d"
context="{'search_default_partner_id': active_id, 'default_partner_id': active_id, 'form_view_ref': 'account.view_company_partner_bank_form'}"
string="View accounts detail"
colspan="2"
/>
</group>
</group>
</page>
<page string="Invoicing" name="accounting_disabled" attrs="{'invisible': ['|',('is_company','=',True),('parent_id','=',False)]}">
<div>
<p>Accounting-related settings are managed on <button name="open_commercial_entity" type="object" string="the parent company" class="oe_link"/></p>
</div>
</page>
<page name='internal_notes' string="Internal Notes">
<field name="comment" placeholder="Internal note..."/>
</page>