← Back to team overview

credativ team mailing list archive

[Bug 903929] Re: Bank import: browse record is written to

 

Hi Dmitrijs,

although move_line = move_line.browse() does refresh the local move_line
variable, it does so by creating a new browse record and updating the
local reference. The browse record that the caller passed originally,
and which may be processed again further down does not get updated.
Instead, we would need to find a way to invalidate the cache on an
existing browse record.

Looks like resetting _data might do the trick

move_line._data[move_line.id] = {'id': move_line.id}  might do the
trick.

Alternatively but less elegant, we may keep your suggestion and return
the move_line back to the caller, changing its call to

move_line = link_payment(cr, uid, move_line, ...)

Cheers,
Stefan.

-- 
You received this bug notification because you are a member of Banking
Addons Team, which is the registrant for Banking Addons.
https://bugs.launchpad.net/bugs/903929

Title:
  Bank import: browse record is written to

Status in Banking Addons:
  Fix Released

Bug description:
  in account_banking/wizard/bank_import.py, in _get_move_info() the
  browse record 'move_line' is being written to.

To manage notifications about this bug go to:
https://bugs.launchpad.net/banking-addons/+bug/903929/+subscriptions


References