Merge lp:~ruchir.shukla/banking-addons/banking-addons-fix-1266890 into lp:banking-addons

Proposed by Ruchir Shukla(BizzAppDev)
Status: Merged
Merged at revision: 228
Proposed branch: lp:~ruchir.shukla/banking-addons/banking-addons-fix-1266890
Merge into: lp:banking-addons
Diff against target: 43 lines (+8/-4)
1 file modified
account_banking/account_banking_view.xml (+8/-4)
To merge this branch: bzr merge lp:~ruchir.shukla/banking-addons/banking-addons-fix-1266890
Reviewer Review Type Date Requested Status
Stefan Rijnhart (Opener) Approve
Holger Brunn (Therp) code review Approve
Review via email: mp+203237@code.launchpad.net

Description of the change

Fix bug

To post a comment you must log in.
Revision history for this message
Stefan Rijnhart (Opener) (stefan-opener) wrote :

Thanks! I'm thinking that the account should be readonly if there is any match type at all, not just move or payment. Do you agree?

review: Needs Information
220. By Ruchir Shukla(BizzAppDev)

fix the condition

Revision history for this message
Ruchir Shukla(BizzAppDev) (ruchir.shukla) wrote :

Hello Stefan !
Thank you for review and raise that point. I have make changes for any match type it will be readonly.

221. By Ruchir Shukla(BizzAppDev)

fix condition

Revision history for this message
Holger Brunn (Therp) (hbrunn) :
review: Approve (code review)
Revision history for this message
Stefan Rijnhart (Opener) (stefan-opener) wrote :

Thanks for the change!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'account_banking/account_banking_view.xml'
2--- account_banking/account_banking_view.xml 2013-10-31 07:33:46 +0000
3+++ account_banking/account_banking_view.xml 2014-01-27 08:49:39 +0000
4@@ -95,7 +95,7 @@
5 action="action_account_banking_journals"
6 sequence="20"
7 />
8-
9+
10 <!-- Create new view on imported statement files -->
11 <record model="ir.ui.view" id="view_account_banking_imported_file_form">
12 <field name="name">account.banking.imported.file.form</field>
13@@ -221,7 +221,7 @@
14 </xpath>
15
16 <!-- Add invisible field for identification of import file
17- on bank statements
18+ on bank statements
19 -->
20 <field name="balance_end_real" position="after">
21 <field name="banking_id" invisible="True"/>
22@@ -248,7 +248,10 @@
23 position="after">
24 <field name="partner_bank_id"/>
25 </xpath>
26-
27+ <xpath expr="//field[@name='line_ids']/tree//field[@name='account_id']"
28+ position="attributes">
29+ <attribute name="attrs">{'readonly': ['|', ('state', '!=', 'draft'), ('match_type', '!=', '')]}</attribute>
30+ </xpath>
31 <xpath expr="//field[@name='line_ids']/tree/field[@name='amount']"
32 position="after">
33 <field name="match_type"/>
34@@ -336,7 +339,8 @@
35 <field name="partner_bank_id"/>
36 <field name="type" on_change="onchange_type(partner_id, type)"/>
37 <!-- TODO note the references to parent from the statement form view -->
38- <field domain="[('journal_id','=',parent.journal_id)]" name="account_id"/>
39+ <field domain="[('journal_id','=',parent.journal_id)]"
40+ attrs="{'readonly': ['|', ('state', '!=', 'draft'), ('match_type', '!=', '')]}" name="account_id"/>
41 <field name="analytic_account_id" groups="analytic.group_analytic_accounting" domain="[('company_id', '=', parent.company_id), ('type', '&lt;&gt;', 'view')]"/>
42 <field name="amount"/>
43 <field name="match_type"/>

Subscribers

People subscribed via source and target branches

to status/vote changes: