mirror of
https://github.com/OCA/bank-payment.git
synced 2025-02-02 10:37:31 +02:00
[FIX] account_payment_order: Add extra form view only to avoid open move lines in edit mode
TT45211
This commit is contained in:
committed by
David Ramia
parent
66868fa55a
commit
a2dd94fdd4
@@ -18,12 +18,25 @@
|
||||
</group>
|
||||
</field>
|
||||
</record>
|
||||
<!-- Extra form view only to avoid open the recod in edit mode !-->
|
||||
<record id="view_move_line_form_no_edit" model="ir.ui.view">
|
||||
<field name="name">account.move.line.form.no_edit</field>
|
||||
<field name="model">account.move.line</field>
|
||||
<field name="inherit_id" ref="account.view_move_line_form" />
|
||||
<field name="mode">primary</field>
|
||||
<field name="priority">999</field>
|
||||
<field name="arch" type="xml">
|
||||
<form position="attributes">
|
||||
<attribute name="edit">0</attribute>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
<record id="view_move_line_tree" model="ir.ui.view">
|
||||
<field name="name">account_payment_order.add.move_line_tree</field>
|
||||
<field name="model">account.move.line</field>
|
||||
<field name="inherit_id" ref="account.view_move_line_tree" />
|
||||
<field name="mode">primary</field>
|
||||
<field name="priority">99</field>
|
||||
<field name="priority">999</field>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//field[@name='amount_currency']" position="after">
|
||||
<field name="balance" readonly="1" />
|
||||
|
||||
@@ -49,7 +49,8 @@
|
||||
<field
|
||||
name="move_line_ids"
|
||||
nolabel="1"
|
||||
context="{'tree_view_ref': 'account_payment_order.view_move_line_tree'}"
|
||||
force_save="1"
|
||||
context="{'tree_view_ref': 'account_payment_order.view_move_line_tree', 'form_view_ref':'account_payment_order.view_move_line_form_no_edit'}"
|
||||
>
|
||||
<tree>
|
||||
<field name="date" />
|
||||
|
||||
Reference in New Issue
Block a user