Commit Graph

398 Commits

Author SHA1 Message Date
Xavier Morel b6a0874f4c [FIX] disgusting hack to skip around race condition
When clicking on an action button, form view first saves then executes
the action. In doing so, it causes the o2m field to call
ListView#reload_content twice without waiting for the reloading to
end, generating a race condition in ListView.List#render_dataset.

As a result, the read_slice callback fills the list twice (once for
each #reload_content call), resulting in everything being duplicated.

Clear the content of the records collection before adding stuff.

note: collections should dedup on ids.

lp bug: https://launchpad.net/bugs/877965 fixed

bzr revid: xmo@openerp.com-20111025085112-q38q8m0k2mopwadg
2011-10-25 10:51:12 +02:00
Xavier Morel ba2f06a2ac [ADD] missing deferred propagation in ListView.reload_content
bzr revid: xmo@openerp.com-20111025070626-pxxp6virhhomb7kl
2011-10-25 09:06:26 +02:00
kbh fa94cf7578 [IMP] Remove unnecessary code in checkbutton select all/none in list view.
bzr revid: kbh@bde-desktop-20111025062429-dvx4x0h1caqwg21i
2011-10-25 11:54:29 +05:30
kbh 276cff1807 [IMP] Remove unnecessary code in checkbutton select all/none in list view.
bzr revid: kbh@bde-desktop-20111025060142-47y025oqteocdgj3
2011-10-25 11:31:42 +05:30
kbh 3e20652e55 [IMP] Fixed the issue of checkbutton select all/none in tree view.
bzr revid: kbh@bde-desktop-20111024132959-y9b3scfye91nut1c
2011-10-24 18:59:59 +05:30
kbh 2ce07c97c6 [FIX] Fixed the issue of checkbutton select all/none in tree view.
lp bug: https://launchpad.net/bugs/878108 fixed

bzr revid: kbh@bde-desktop-20111024091730-dkzafro2f9e0k7tf
2011-10-24 14:47:30 +05:30
Fabien Meghazi 69d36a02ca [FIX] Fix bug for Internet Explorer 3.0
In fact IE<9

bzr revid: fme@openerp.com-20111020162255-5duca37zd18by343
2011-10-20 18:22:55 +02:00
Fabien Meghazi a958ff049f [REM] Removed a console.log
bzr revid: fme@openerp.com-20111019160612-w0ih265m5no00khg
2011-10-19 18:06:12 +02:00
Xavier Morel 7a5e3da9ad [FIX] incorrect management of dataset indexes leading to always selecting a record on the listview's first page when clicking on a record to open its form (even when at the 5th page)
lp bug: https://launchpad.net/bugs/878103 fixed

bzr revid: xmo@openerp.com-20111019151703-dxvzdrn2mg75y8fd
2011-10-19 17:17:03 +02:00
Fabien Meghazi 062449472f [FIX] In paginated list view, clicking on a row on page 2+ goes to wrong record in form view
bzr revid: fme@openerp.com-20111019144507-j5oec235bw79gw73
2011-10-19 16:45:07 +02:00
Xavier Morel 8c9d65c41a [IMP] fix mistake done while merging ref-in-listviews, improve discrimination between ref-value and printable value
* Removed a test on splitting on ',' yielding more than one value, which means we're going to loop on the name_get since they're all strings
* Improved value-detection: we should only name_get the reference field if the value is an actual reference value, meaning a model name, a ',' and an id. Used regex instead of naive split, so we don't match referenced names with a comma (e.g. 'Hubert de Vaucanson, Vicomte de Blois')

bzr revid: xmo@openerp.com-20111018105255-6vz6l9lg1iiurfc9
2011-10-18 12:52:55 +02:00
Xavier Morel 7b600e82c4 [IMP] don't check for the column type being m2o if we already went through the reference case
bzr revid: xmo@openerp.com-20111018103443-p1l5cya0nexf6cj1
2011-10-18 12:34:43 +02:00
Xavier Morel adea72acd7 [FIX] correctly display reference field values in list view
bzr revid: xmo@openerp.com-20111018103258-qnldbs6jwh1fa8is
2011-10-18 12:32:58 +02:00
Vaibhav (OpenERP) c7f4482d5b [FIX] Check value type,base with parseint.
bzr revid: vda@tinyerp.com-20111018093432-0ixihleg3vynpvwx
2011-10-18 15:04:32 +05:30
Vaibhav (OpenERP) 8b8d7a1d76 [FIX] Display name of reference field in tree.
lp bug: https://launchpad.net/bugs/861434 fixed

bzr revid: vda@tinyerp.com-20111018055400-2j1gvgvognuo6ka9
2011-10-18 11:24:00 +05:30
Xavier Morel 3790db3e40 [FIX] action buttons with a name composed solely of digits in list view
lp bug: https://launchpad.net/bugs/869746 fixed

bzr revid: xmo@openerp.com-20111017141022-u7v9aiw08aczpsv1
2011-10-17 16:10:22 +02:00
Xavier Morel 9012103f82 [IMP] add translation marks to printed text in listview
bzr revid: xmo@openerp.com-20111017115652-9230tli493e9sqkt
2011-10-17 13:56:52 +02:00
Xavier Morel 484063df5e [ADD] confirmation popup when deleting an element from the list view
bzr revid: xmo@openerp.com-20111017115117-0mas0bkdbkq0yku6
2011-10-17 13:51:17 +02:00
Fabien Meghazi 22da3764df [FIX] Fix error when clicking on empty row in editable lists
bzr revid: fme@openerp.com-20111017095216-zfzqgmsfrdcjvccj
2011-10-17 11:52:16 +02:00
Xavier Morel f786f5537a [FIX] method call invocation indentation
bzr revid: xmo@openerp.com-20111014084941-cj85qsl9tfbxsvhp
2011-10-14 10:49:41 +02:00
Xavier Morel 405beaa3c6 [FIX] m2o values display in list views (mostly under onchange condition)
Normal m2o values are pairs of (id, name) (name_get format, basically)
but in some cases (lazyness & al), APIs (often onchange results) only
return the `id` part, which is not sufficient to display the m2o
as-is, a name_get has to be performed.

Added an intermediate step in displaying a table cell (in list view):
if we're displaying an m2o cell (~a cell for an m2o column) and the
value is a number, then dispatch a name_get and keep trucking (display
the rows without the m2o values).

When the name_get returns, it will simply refresh the row and diplay
the m2o name.

bzr revid: xmo@openerp.com-20111014084310-pv2mmmy28fwwk9sm
2011-10-14 10:43:10 +02:00
Turkesh Patel (Open ERP) 937c881aaa [FIX] Fixed the issue for confirmation popup when we delete a record from a list
lp bug: https://launchpad.net/bugs/872708 fixed

bzr revid: tpa@tinyerp.com-20111013085758-el0bn170ai0h6wfc
2011-10-13 14:27:58 +05:30
niv-openerp aaf01c6395 [fix] dirty fix of the problem with list views in o2m
bzr revid: nicolas.vanhoren@openerp.com-20111010143634-sjld7z726l6ebg53
2011-10-10 16:36:34 +02:00
Xavier Morel acc3d54316 [ADD] update pager on record deletion
bzr revid: xmo@openerp.com-20111007071756-h73imu0g4tl3fhay
2011-10-07 09:17:56 +02:00
Fabien Meghazi 65745d5142 [FIX] Do not compute modifiers for aggregates in list view.
lp bug: https://launchpad.net/bugs/865188 fixed

bzr revid: fme@openerp.com-20111005153202-4ao575zh3885ukuy
2011-10-05 17:32:02 +02:00
Xavier Morel 318ec9998b [IMP] use .children(selector) rather than .find('> ' + selector)
bzr revid: xmo@openerp.com-20111004155918-c2vy0rwkesvdkmli
2011-10-04 17:59:18 +02:00
Xavier Morel 72b852c2c6 [FIX] insertion position of new lines (in editable lists) in case of lists padded to 5 (empty) lines
bzr revid: xmo@openerp.com-20111004154246-7o1cw016cf9ygem3
2011-10-04 17:42:46 +02:00
Xavier Morel 29cef016f9 [FIX] re-rendering of a given list's row (e.g. onchange, edition, etc...): 'view' needs to be in the context so the row's color can be computed
bzr revid: xmo@openerp.com-20111004104848-277ajqmaud8oc8hn
2011-10-04 12:48:48 +02:00
Xavier Morel 3190884fa1 [FIX] don't perform a search_read when switching view from list to form
I don't remember why I did that originally, it does not seem to serve any purpose and it causes problems in case of records with binary fields

bzr revid: xmo@openerp.com-20111004102115-lz6kgyiw35vp1t99
2011-10-04 12:21:15 +02:00
Fabien Meghazi f76b2f55ae [MERGE] ViewManager now triggers do_search() in on_mode_switch()
The views doesn't have to worry about the search in do_show().
They just have to listen to do_search() if they are searchable.

bzr revid: fme@openerp.com-20111004094738-at91ab6a2kkxf8bq
2011-10-04 11:47:38 +02:00
Vaibhav (OpenERP) be5bef72fa [FIX] Need to Update Pager after delete record.
lp bug: https://launchpad.net/bugs/849020 fixed

bzr revid: vda@tinyerp.com-20111004071945-2fixgi12ozr6wm6g
2011-10-04 12:49:45 +05:30
Fabien Meghazi e80894b775 [FIX] Fixed error for sidebar-less embedded list views
bzr revid: fme@openerp.com-20111003150049-hty30u42ozakevc8
2011-10-03 17:00:49 +02:00
Fabien Meghazi 82006438fe [MERGE] Merge with trunk
bzr revid: fme@openerp.com-20111003135613-8d2ep2fv3bv713t7
2011-10-03 15:56:13 +02:00
kbh 335c99fda4 [FIX] Minor change in issue of open sidebar on checked list record.
lp bug: https://launchpad.net/bugs/856376 fixed

bzr revid: kbh@bde-desktop-20111003071807-33zlrcc0vopiahoz
2011-10-03 12:48:07 +05:30
kbh fdfe102cc4 [FIX] change in listview for sidebar.
bzr revid: kbh@bde-desktop-20111003060239-l7bwy55n8t9fkz66
2011-10-03 11:32:39 +05:30
Xavier Morel d4d2b1b5b8 [FIX] don't break when @colors end with a semicolon
bzr revid: xmo@openerp.com-20110930132941-mw8byod4xanb8dat
2011-09-30 15:29:41 +02:00
Xavier Morel ba86faac47 [IMP] shave ~190ms off of *big* listview rendering speed
make conversion of internal Records to form-shape faster by iterating over the attributes object directly instead of using _.each

bzr revid: xmo@openerp.com-20110929145031-q7mqf43gza94ekj6
2011-09-29 16:50:31 +02:00
Xavier Morel d793d6c1ae [ADD] atom context keys (uid and current_date) to evaluation context of row colors
bzr revid: xmo@openerp.com-20110929142410-1f9btd6f3ws0srpj
2011-09-29 16:24:10 +02:00
Fabien Meghazi e34b07e1e3 [IMP] Fixed list view in order to support new do_search
bzr revid: fme@openerp.com-20110929103229-l9pfjqbezj28ihd9
2011-09-29 12:32:29 +02:00
Fabien Meghazi 03156f88ff [IMP] The views do not have to search manually on do_show anymore
bzr revid: fme@openerp.com-20110928154608-mlehfgprg03byksr
2011-09-28 17:46:08 +02:00
Xavier Morel c94872fc02 [ADD] basic colors support to listview via py.parse
bzr revid: xmo@openerp.com-20110925180407-n0asxrrjeb1oo5a4
2011-09-25 20:04:07 +02:00
Jagdish Panchal (Open ERP) 1d94e954e0 [FIX] clen up.
bzr revid: jap@tinyerp.com-20110922130540-nuru8qifwyym5d0s
2011-09-22 18:35:40 +05:30
Jagdish Panchal (Open ERP) cba17940ce [FIX] Workflow buttons in one2many crash due to Name typecasting.
lp bug: https://launchpad.net/bugs/851866 fixed

bzr revid: jap@tinyerp.com-20110922110914-u1cydxz1njcp6h0k
2011-09-22 16:39:14 +05:30
Xavier Morel cdef8d8f8f [FIX] correctly handle 'false' domain on listview dataset: filter it out
bzr revid: xmo@openerp.com-20110921074509-2gkgp3ai4ly1vwdf
2011-09-21 09:45:09 +02:00
Xavier Morel b9869f9354 [FIX] empty root groups in aggregations
bzr revid: xmo@openerp.com-20110921071925-by8fl0o85v76d6am
2011-09-21 09:19:25 +02:00
niv-openerp eddd4a8827 [imp] added this._super() in all views
bzr revid: nicolas.vanhoren@openerp.com-20110915094246-6v6imml9bf3y4ycj
2011-09-15 11:42:46 +02:00
niv-openerp eb45de7805 [merge]
bzr revid: nicolas.vanhoren@openerp.com-20110915093144-0ix1tdc8mcmx6l9p
2011-09-15 11:31:44 +02:00
Antony Lesuisse 3ef575744d [IMP] prefix view (obsessive–compulsive rename disorder)
bzr revid: al@openerp.com-20110914204057-cg8y5yy3py70ge62
2011-09-14 22:40:57 +02:00