banking-addons-team team mailing list archive
-
banking-addons-team team
-
Mailing list archive
-
Message #00228
lp:~banking-addons-team/banking-addons/bank-statement-reconcile-61to70 into lp:banking-addons/bank-statement-reconcile-70
Joël Grand-Guillaume @ camptocamp has proposed merging lp:~banking-addons-team/banking-addons/bank-statement-reconcile-61to70 into lp:banking-addons/bank-statement-reconcile-70.
Requested reviews:
Banking Addons Team (banking-addons-team)
For more details, see:
https://code.launchpad.net/~banking-addons-team/banking-addons/bank-statement-reconcile-61to70/+merge/140557
Migrate the bank-statement-reconcile addons to v7.0.
This is a first proposal that make those module "installable" on a version 7.0.
- Adapt views
- Change the huge create_move_from_st_line method to take part of the v7.0 refactoring done by my previous merge ;)
- Small fixes in the code
- Make installable = False on non-needed module
--
https://code.launchpad.net/~banking-addons-team/banking-addons/bank-statement-reconcile-61to70/+merge/140557
Your team Banking Addons Team is requested to review the proposed merge of lp:~banking-addons-team/banking-addons/bank-statement-reconcile-61to70 into lp:banking-addons/bank-statement-reconcile-70.
=== modified file 'account_statement_base_completion/statement.py'
--- account_statement_base_completion/statement.py 2012-12-13 13:57:29 +0000
+++ account_statement_base_completion/statement.py 2012-12-18 21:35:26 +0000
@@ -353,8 +353,7 @@
+ "\n" + error_log + "-------------" + "\n"]
log = "\n".join(log_line)
self.write(cr, uid, [stat_id], {'completion_logs' : log}, context=context)
- logger.notifyChannel('Bank Statement Completion', netsvc.LOG_INFO,
- "Bank Statement ID %s has %s lines completed"%(stat_id, number_imported))
+ self.message_post(cr, uid, [stat_id], body=_('Statement ID %s auto-completed for %s lines completed') % (stat_id,number_imported), context=context)
return True
def button_auto_completion(self, cr, uid, ids, context=None):
@@ -383,6 +382,6 @@
if res:
vals = res[line.id]
vals['already_completed'] = True
- stat_line_obj.write(cr, uid, line.id, vals, context=ctx)
+ stat_line_obj.write(cr, uid, [line.id], vals, context=ctx)
self.write_completion_log(cr, uid, stat.id, msg, compl_lines, context=context)
return True
=== modified file 'account_statement_base_completion/statement_view.xml'
--- account_statement_base_completion/statement_view.xml 2012-08-02 12:46:12 +0000
+++ account_statement_base_completion/statement_view.xml 2012-12-18 21:35:26 +0000
@@ -10,21 +10,21 @@
<field name="type">form</field>
<field name="arch" type="xml">
<data>
- <xpath expr="/form/notebook/page/field[@name='line_ids']/form/field[@name='sequence']" position="after">
+ <xpath expr="/form/sheet/notebook/page/field[@name='line_ids']/form/group/field[@name='sequence']" position="after">
<separator colspan="4" string="Importation related infos"/>
<field name="label" />
<field name="already_completed" />
</xpath>
- <xpath expr="/form/group[2]" position="attributes">
- <attribute name="col">10</attribute>
- </xpath>
+ <!-- <xpath expr="/form/group[2]" position="attributes">
+ <attribute name="col">10</attribute>
+ </xpath> -->
- <xpath expr="/form/group/field[@name='balance_end']" position="after">
+ <xpath expr="/form/sheet/div[@name='import_buttons']" position="after">
<button name="button_auto_completion" string="Auto Completion" states='draft,open' type="object" colspan="1"/>
</xpath>
- <xpath expr="/form/notebook/page[@string='Journal Entries']" position="after">
+ <xpath expr="/form/sheet/notebook/page[@string='Transactions']" position="after">
<page string="Completion Logs" attrs="{'invisible':[('completion_logs','=',False)]}">
<field name="completion_logs" colspan="4" nolabel="1" attrs="{'invisible':[('completion_logs','=',False)]}"/>
</page>
@@ -40,7 +40,7 @@
<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">
+ <xpath expr="/form/sheet/notebook/page/field[@name='line_ids']/tree/field[@name='amount']" position="after">
<field name="already_completed" />
</xpath>
</data>
=== modified file 'account_statement_base_import/statement_view.xml'
--- account_statement_base_import/statement_view.xml 2012-08-02 12:46:12 +0000
+++ account_statement_base_import/statement_view.xml 2012-12-18 21:35:26 +0000
@@ -32,7 +32,7 @@
<field eval="20" name="priority"/>
<field name="arch" type="xml">
<data>
- <xpath expr="/form/notebook/page/field[@name='line_ids']/form/field[@name='label']" position="after">
+ <xpath expr="/form/sheet/notebook/page/field[@name='line_ids']/form/group/field[@name='label']" position="after">
<field name="commission_amount" />
</xpath>
</data>
=== modified file 'account_statement_completion_voucher/__openerp__.py'
--- account_statement_completion_voucher/__openerp__.py 2012-06-27 07:58:32 +0000
+++ account_statement_completion_voucher/__openerp__.py 2012-12-18 21:35:26 +0000
@@ -36,9 +36,9 @@
],
'demo_xml': [],
'test': [],
- 'installable': True,
+ 'installable': False,
'images': [],
- 'auto_install': True,
+ 'auto_install': False,
'license': 'AGPL-3',
'active': False,
}
=== modified file 'account_statement_completion_voucher/statement_view.xml'
--- account_statement_completion_voucher/statement_view.xml 2012-06-27 07:58:32 +0000
+++ account_statement_completion_voucher/statement_view.xml 2012-12-18 21:35:26 +0000
@@ -3,19 +3,19 @@
<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">
+ <!-- <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">
+ <xpath expr="/form/sheet/notebook/page/field[@name='line_ids']/tree/field[@name='voucher_id']" position="after">
<field name="already_completed" />
</xpath>
</data>
</field>
- </record>
+ </record> -->
</data>
</openerp>
=== modified file 'account_statement_ext/__openerp__.py'
--- account_statement_ext/__openerp__.py 2012-10-25 06:40:13 +0000
+++ account_statement_ext/__openerp__.py 2012-12-18 21:35:26 +0000
@@ -25,7 +25,7 @@
'maintainer': 'Camptocamp',
'category': 'Finance',
'complexity': 'normal', #easy, normal, expert
- 'depends': ['account'],
+ 'depends': ['account','report_webkit'],
'description': """
Improve the basic bank statement, by adding various new features,
and help dealing with huge volume of reconciliation through payment offices such as Paypal, Lazer,
=== modified file 'account_statement_ext/statement.py'
--- account_statement_ext/statement.py 2012-10-25 07:38:31 +0000
+++ account_statement_ext/statement.py 2012-12-18 21:35:26 +0000
@@ -19,12 +19,11 @@
#
##############################################################################
-from tools.translate import _
-import datetime
-import netsvc
-logger = netsvc.Logger()
+import time
+
from openerp.osv.orm import Model, fields
-from openerp.osv import fields, osv
+from openerp.tools.translate import _
+import openerp.addons.decimal_precision as dp
class AccountStatementProfil(Model):
"""
@@ -160,7 +159,7 @@
_constraints = [
(_check_company_id, 'The journal and period chosen have to belong to the same company.', ['journal_id','period_id']),
]
-
+
def button_cancel(self, cr, uid, ids, context={}):
"""
We cancel the related move, delete them and finally put the
@@ -176,140 +175,71 @@
for move in line.move_ids:
if move.state <> 'draft':
move.button_cancel(context=context)
- move.unlink(context=context)
- done.append(st.id)
- self.write(cr, uid, done, {'state':'draft'}, context=context)
- return True
-
- def create_move_from_st_line(self, cr, uid, st_line_id, company_currency_id, st_line_number, context=None):
- """
- Override a large portion of the code to compute the periode for each line instead of
- taking the period of the whole statement.
- Remove the entry posting on generated account moves.
+ return super(AccountBankSatement, self).button_cancel(cr, uid, vals, context=context)
+
+ def _prepare_move(self, cr, uid, st_line, st_line_number, context=None):
+ """Add the period_id from the statement line date to the move preparation.
+ Originaly, it was taken from the statement period_id
+ :param browse_record st_line: account.bank.statement.line record to
+ create the move from.
+ :param char st_line_number: will be used as the name of the generated account move
+ :return: dict of value to create() the account.move
+ """
+ if context is None:
+ context = {}
+ res = super(AccountBankSatement, self)._prepare_move(cr, uid, st_line, st_line_number, context=context)
+ ctx = context.copy()
+ ctx['company_id'] = st_line.company_id.id
+ period_id = self._get_period(cr, uid, st_line.date, context=ctx)
+ res.update({'period_id': period_id})
+ return res
+
+ def _prepare_move_line_vals(self, cr, uid, st_line, move_id, debit, credit, currency_id = False,
+ amount_currency= False, account_id = False, analytic_id = False,
+ partner_id = False, context=None):
+ """Add the period_id from the statement line date to the move preparation.
+ Originaly, it was taken from the statement period_id
+
+ :param browse_record st_line: account.bank.statement.line record to
+ create the move from.
+ :param int/long move_id: ID of the account.move to link the move line
+ :param float debit: debit amount of the move line
+ :param float credit: credit amount of the move line
+ :param int/long currency_id: ID of currency of the move line to create
+ :param float amount_currency: amount of the debit/credit expressed in the currency_id
+ :param int/long account_id: ID of the account to use in the move line if different
+ from the statement line account ID
+ :param int/long analytic_id: ID of analytic account to put on the move line
+ :param int/long partner_id: ID of the partner to put on the move line
+ :return: dict of value to create() the account.move.line
+ """
+ if context is None:
+ context = {}
+ res = super(AccountBankSatement, self)._prepare_move_line_vals(cr, uid, st_line, move_id, debit,
+ credit, currency_id = currency_id, amount_currency = amount_currency, account_id = account_id,
+ analytic_id = analytic_id, partner_id = partner_id, context = context)
+ ctx = context.copy()
+ ctx['company_id'] = st_line.company_id.id
+ period_id = self._get_period(cr, uid, st_line.date, context=ctx)
+ res.update({'period_id': period_id})
+ return res
+
+ def _get_counter_part_partner(self, cr, uid, st_line, context=None):
+ """
We change the move line generated from the lines depending on the profile:
- - If receivable_account_id is set, we'll use it instead of the "partner" one
- - If partner_id is set, we'll us it for the commission (when imported throufh the wizard)
- If partner_id is set and force_partner_on_bank is ticked, we'll let the partner of each line
for the debit line, but we'll change it on the credit move line for the choosen partner_id
=> This will ease the reconciliation process with the bank as the partner will match the bank
statement line
-
- :param int/long: st_line_id: account.bank.statement.line ID
- :param int/long: company_currency_id: res.currency ID
- :param char: st_line_number: that will be used as the name of the generated account move
- :return: int/long: ID of the created account.move
+ :param browse_record st_line: account.bank.statement.line record to
+ create the move from.
+ :return: int/long of the res.partner to use as counterpart
"""
- if context is None:
- context = {}
- res_currency_obj = self.pool.get('res.currency')
- account_move_obj = self.pool.get('account.move')
- account_move_line_obj = self.pool.get('account.move.line')
- account_bank_statement_line_obj = self.pool.get('account.bank.statement.line') # Chg
- st_line = account_bank_statement_line_obj.browse(cr, uid, st_line_id, context=context) # Chg
- st = st_line.statement_id
-
- context.update({'date': st_line.date})
- ctx = context.copy() # Chg
- ctx['company_id'] = st_line.company_id.id # Chg
- period_id = self._get_period( # Chg
- cr, uid, st_line.date, context=ctx)
-
- move_id = account_move_obj.create(cr, uid, {
- 'journal_id': st.journal_id.id,
- 'period_id': period_id, # Chg
- 'date': st_line.date,
- 'name': st_line_number,
- 'ref': st_line.ref,
- }, context=context)
- account_bank_statement_line_obj.write(cr, uid, [st_line.id], { # Chg
- 'move_ids': [(4, move_id, False)]
- })
-
- torec = []
- if st_line.amount >= 0:
- account_id = st.journal_id.default_credit_account_id.id
- else:
- account_id = st.journal_id.default_debit_account_id.id
-
- acc_cur = ((st_line.amount<=0) and st.journal_id.default_debit_account_id) or st_line.account_id
- context.update({
- 'res.currency.compute.account': acc_cur,
- })
- amount = res_currency_obj.compute(cr, uid, st.currency.id,
- company_currency_id, st_line.amount, context=context)
-
- val = {
- 'name': st_line.name,
- 'date': st_line.date,
- 'ref': st_line.ref,
- 'move_id': move_id,
- 'partner_id': ((st_line.partner_id) and st_line.partner_id.id) or False,
- 'account_id': (st_line.account_id) and st_line.account_id.id,
- 'credit': ((amount>0) and amount) or 0.0,
- 'debit': ((amount<0) and -amount) or 0.0,
- # Replace with the treasury one instead of bank #Chg
- 'statement_id': st.id,
- 'journal_id': st.journal_id.id,
- 'period_id': period_id, #Chg
- 'currency_id': st.currency.id,
- 'analytic_account_id': st_line.analytic_account_id and st_line.analytic_account_id.id or False
- }
-
- if st.currency.id <> company_currency_id:
- amount_cur = res_currency_obj.compute(cr, uid, company_currency_id,
- st.currency.id, amount, context=context)
- val['amount_currency'] = -amount_cur
-
- if st_line.account_id and st_line.account_id.currency_id and st_line.account_id.currency_id.id <> company_currency_id:
- val['currency_id'] = st_line.account_id.currency_id.id
- amount_cur = res_currency_obj.compute(cr, uid, company_currency_id,
- st_line.account_id.currency_id.id, amount, context=context)
- val['amount_currency'] = -amount_cur
-
- move_line_id = account_move_line_obj.create(cr, uid, val, context=context)
- torec.append(move_line_id)
-
- # Fill the secondary amount/currency
- # if currency is not the same than the company
- amount_currency = False
- currency_id = False
- if st.currency.id <> company_currency_id:
- amount_currency = st_line.amount
- currency_id = st.currency.id
- # GET THE RIGHT PARTNER ACCORDING TO THE CHOSEN PROFIL # Chg
- if st.profile_id.force_partner_on_bank: # Chg
- bank_parrtner_id = st.profile_id.partner_id.id # Chg
- else: # Chg
- bank_parrtner_id = ((st_line.partner_id) and st_line.partner_id.id) or False # Chg
-
- account_move_line_obj.create(cr, uid, {
- 'name': st_line.name,
- 'date': st_line.date,
- 'ref': st_line.ref,
- 'move_id': move_id,
- 'partner_id': bank_parrtner_id, # Chg
- 'account_id': account_id,
- 'credit': ((amount < 0) and -amount) or 0.0,
- 'debit': ((amount > 0) and amount) or 0.0,
- # Replace with the treasury one instead of bank #Chg
- 'statement_id': st.id,
- 'journal_id': st.journal_id.id,
- 'period_id': period_id, #Chg
- 'amount_currency': amount_currency,
- 'currency_id': currency_id,
- }, context=context)
-
- for line in account_move_line_obj.browse(cr, uid, [x.id for x in
- account_move_obj.browse(cr, uid, move_id,
- context=context).line_id],
- context=context):
- if line.state <> 'valid':
- raise osv.except_osv(_('Error !'),
- _('Journal item "%s" is not valid.') % line.name)
-
- # Bank statements will not consider boolean on journal entry_posted
- account_move_obj.post(cr, uid, [move_id], context=context)
- return move_id
+ bank_partner_id = super(AccountBankSatement, self)._get_counter_part_partner(cr, uid, st_line, context=context)
+ # GET THE RIGHT PARTNER ACCORDING TO THE CHOSEN PROFIL
+ if st_line.statement_id.profile_id.force_partner_on_bank:
+ bank_partner_id = st_line.statement_id.profile_id.partner_id.id
+ return bank_partner_id
def _get_st_number_period_profile(self, cr, uid, date, profile_id):
"""
@@ -397,7 +327,7 @@
'name': st_number,
'balance_end_real': st.balance_end
}, context=context)
- self.log(cr, uid, st.id, _('Statement %s is confirmed, journal items are created.') % (st_number,))
+ self.message_post(cr, uid, [st.id], body=_('Statement %s confirmed, journal items were created.') % (st_number,), context=context)
return self.write(cr, uid, ids, {'state':'confirm'}, context=context)
def get_account_for_counterpart(self, cursor, uid,
=== modified file 'account_statement_ext/statement_view.xml'
--- account_statement_ext/statement_view.xml 2012-08-02 12:46:12 +0000
+++ account_statement_ext/statement_view.xml 2012-12-18 21:35:26 +0000
@@ -73,32 +73,20 @@
<menuitem string="Bank Statements Profile" action="action_treasury_statement_profile_tree" id="menu_treasury_statement_profile_tree" parent="account.menu_configuration_misc" sequence="30"/>
- <record model="ir.ui.view" id="id_in_statement_line">
- <field name="name">account.bank.statement.line.inherit</field>
- <field name="model">account.bank.statement</field>
- <field name="inherit_id" ref="account.view_bank_statement_periodic_form"/>
- <field name="priority" eval="30"/>
- <field name="arch" type="xml">
- <xpath expr="/form/notebook/page[@string='Journal Entries']/field/tree/field[@name='ref']" position="before">
- <field name="id" />
- </xpath>
- </field>
- </record>
<record id="view_treasury_statement_search" model="ir.ui.view">
<field name="name">account.bank.statement.search</field>
<field name="model">account.bank.statement</field>
<field name="inherit_id" ref="account.view_bank_statement_search"/>
- <field name="type">search</field>
<field name="arch" type="xml">
- <xpath expr="/search/group/field[@name='name']" position="before">
+ <xpath expr="/search/field[@name='name']" position="before">
<field name="id"/>
<field name="profile_id"/>
<field name="credit_partner_id"/>
<separator orientation="vertical"/>
</xpath>
- <xpath expr="/search/group/field[@name='period_id']" position="replace">
+ <xpath expr="/search/field[@name='period_id']" position="replace">
</xpath>
<xpath expr="/search/group/filter[@string='Period']" position="replace">
<filter string="Financial Partner" context="{'group_by': 'credit_partner_id'}" icon="terp-partner"/>
@@ -124,76 +112,64 @@
</field>
</record>
-
- <record id="view_treasury_statement_form" model="ir.ui.view">
- <field name="name">account.bank.statement.form</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">
- <!-- Remove name and date from group tag -->
- <xpath expr="/form/group/field[@name='name']" position="replace">
- </xpath>
- <xpath expr="/form/group/field[@name='date']" position="replace">
- </xpath>
- <!-- Add a new group before the first one with name, profile and date -->
- <xpath expr="/form/group[@col='7']" position="before">
- <group col="8" colspan="4">
- <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="Profile Details" colspan="4"/>
- </xpath>
- <!-- Make balance visible or not depending on profile -->
- <xpath expr="/form/group/field[@name='balance_start']" position="replace">
- </xpath>
- <xpath expr="/form/group/field[@name='balance_end_real']" position="replace">
- </xpath>
- <xpath expr="/form/group[@col='7']" position="after">
- <separator string="Balance Check" colspan="4" attrs="{'invisible':[('balance_check','=',False)]}"/>
- <group col="6" colspan="4" attrs="{'invisible':[('balance_check','=',False)]}">
- <field name="balance_start" />
- <field name="balance_end_real" />
- </group>
- </xpath>
- <xpath expr="/form/group/field[@name='balance_end']" position="replace">
- <field name="balance_end"/>
- </xpath>
-
- <xpath expr="/form/group/field[@name='journal_id']" position="attributes">
- <attribute name="widget"></attribute>
- </xpath>
- <xpath expr="/form/group/field[@name='period_id']" position="replace">
- <field name="credit_partner_id"/>
- <field name="account_id" invisible="1"/>
- <field name="balance_check" invisible="1"/>
- </xpath>
- <xpath expr="/form/notebook/page/field/tree/field[@name='sequence']" position="after">
- <field name="id"/>
- </xpath>
- <xpath expr="/form/notebook/page/field/tree/field[@name='partner_id']" position="replace">
- <field name="partner_id" on_change="onchange_partner_id(partner_id,parent.profile_id)"/>
- </xpath>
- <xpath expr="/form/notebook/page/field/form/field[@name='date']" position="before">
- <field name="id"/>
- </xpath>
- <!-- Adapt onchange signature -->
- <xpath expr="/form/notebook/page/field/tree/field[@name='partner_id']" position="replace">
- <field name="partner_id" on_change="onchange_partner_id(partner_id,parent.profile_id)"/>
- </xpath>
- <xpath expr="/form/notebook/page/field/form/field[@name='partner_id']" position="replace">
- <field name="partner_id" on_change="onchange_partner_id(partner_id,parent.profile_id)"/>
- </xpath>
- <xpath expr="/form/notebook/page/field/form/field[@name='type']" position="replace">
- <field name="type" on_change="onchange_type(partner_id, type, parent.profile_id)"/>
- </xpath>
- <xpath expr="/form/notebook/page/field/tree/field[@name='type']" position="replace">
- <field name="type" on_change="onchange_type(partner_id, type, parent.profile_id)"/>
- </xpath>
-
- </field>
- </record>
+
+ <record id="view_treasury_statement_form" model="ir.ui.view">
+ <field name="name">account.bank.statement.form</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">
+
+ <!-- Add before the group : profile and related infos -->
+ <xpath expr="/form/sheet/group/group/field[@name='journal_id']" position="replace">
+ </xpath>
+
+ <xpath expr="/form/sheet/group" position="after">
+ <group>
+ <field name="profile_id" select="1" required="1" on_change="onchange_imp_config_id(profile_id)" widget="selection"/>
+ <separator string="Profile Details" colspan="4"/>
+ <field name="journal_id" domain="[('type', '=', 'bank')]" on_change="onchange_journal_id(journal_id)" widget="selection"/>
+ <field name="credit_partner_id"/>
+ <field name="account_id" invisible="1"/>
+ <field name="balance_check" invisible="1"/>
+ </group>
+ </xpath>
+
+ # Make balance visible or not depending on profile
+ <xpath expr="/form/sheet/group/group/field[@name='balance_start']" position="attributes">
+ <attribute name="attrs">{'invisible':[('balance_check','=',False)]}</attribute>
+ </xpath>
+ <xpath expr="/form/sheet/group/group/field[@name='balance_end_real']" position="attributes">
+ <attribute name="attrs">{'invisible':[('balance_check','=',False)]}</attribute>
+ </xpath>
+ <xpath expr="/form/sheet/group/group/field[@name='balance_end_real']" position="after">
+ <field name="balance_end" widget="monetary" options='{"currency_field" : "currency"}'/>
+ </xpath>
+
+ <xpath expr="/form/sheet/notebook/page/field/tree/field[@name='sequence']" position="after">
+ <field name="id" readonly="1" />
+ </xpath>
+
+ <xpath expr="/form/sheet/notebook/page/field/form/group/field[@name='date']" position="before">
+ <field name="id" readonly="1" />
+ </xpath>
+ # Adapt onchange signature
+ <xpath expr="/form/sheet/notebook/page/field/tree/field[@name='partner_id']" position="replace">
+ <field name="partner_id" on_change="onchange_partner_id(partner_id,parent.profile_id)" domain="['|',('parent_id','=',False),('is_company','=',True)]"/>
+ </xpath>
+
+ <xpath expr="/form/sheet/notebook/page/field/form/group/field[@name='partner_id']" position="replace">
+ <field name="partner_id" on_change="onchange_partner_id(partner_id,parent.profile_id)" domain="['|',('parent_id','=',False),('is_company','=',True)]"/>
+ </xpath>
+ <xpath expr="/form/sheet/notebook/page/field/form/group/field[@name='type']" position="replace">
+ <field name="type" on_change="onchange_type(partner_id, type, parent.profile_id)"/>
+ </xpath>
+ <xpath expr="/form/sheet/notebook/page/field/tree/field[@name='type']" position="replace">
+ <field name="type" on_change="onchange_type(partner_id, type, parent.profile_id)"/>
+ </xpath>
+
+ </field>
+ </record>
<act_window id="act_bank_statement_from_profile"
=== modified file 'account_statement_transactionid_completion/statement_view.xml'
--- account_statement_transactionid_completion/statement_view.xml 2012-06-22 15:45:50 +0000
+++ account_statement_transactionid_completion/statement_view.xml 2012-12-18 21:35:26 +0000
@@ -10,7 +10,7 @@
<field name="type">form</field>
<field name="arch" type="xml">
<data>
- <xpath expr="/form/notebook/page/field[@name='line_ids']/form/field[@name='label']" position="after">
+ <xpath expr="/form/sheet/notebook/page/field[@name='line_ids']/form/group/field[@name='label']" position="after">
<field name="transaction_id" />
</xpath>
</data>
Follow ups