~openerp-dev/openerp-web/6.1-opw-579621-msh

Viewing all changes in revision 2451.

  • Committer: Xavier Morel
  • Date: 2012-09-06 12:48:16 UTC
  • Revision ID: xmo@openerp.com-20120906124816-8ivtbppm9pixf8w6
[FIX] o2m breakage introduced in xmo@openerp.com-20120903131744-xfnxpqgn4ixbi7e9

BufferedDataSet#read_ids expect coherent between #cache and
#to_create, patch removed a record from #cache which was in #to_create
leading to not being able to create new records in editable o2ms:

* The record would be inserted in #cache and #to_create
* The listview would reload the record
  - Evicting the record from #cache
  - And re-reading the record
  - Leading to breakage

Don't evict records locally edited from the cache, the server probably
doesn't know about it (at all) or we can assume the server's outdated,
so the local version remains the "correct" one and there's nothing
more recent to fetch.

expand all expand all

Show diffs side-by-side

added added

removed removed

Lines of Context: