Commit Graph

86 Commits

Author SHA1 Message Date
Xavier Morel 9c6f8c5335 [FIX] broken keyup handling for return key, incorrect name ($.ui.keyCode uses enter)
bzr revid: xmo@openerp.com-20120704121957-hcwk5ove76kpo7y0
2012-07-04 14:19:57 +02:00
Xavier Morel 039cf85e32 [TEST] start adding some testing to new editable listview, validate structure of editionView in Editor
bzr revid: xmo@openerp.com-20120704095626-j7wtbgdmoti0kjie
2012-07-04 11:56:26 +02:00
Xavier Morel db4aa8dfe7 [REF] remove deprecated & unused methods; extract some other methods
bzr revid: xmo@openerp.com-20120703155305-4bigm8htt3xutkyt
2012-07-03 17:53:05 +02:00
Xavier Morel 7ab7992fd6 [FIX] ensure current edition is saved before performing action
bzr revid: xmo@openerp.com-20120703143126-6ludobg5o75t14ic
2012-07-03 16:31:26 +02:00
Xavier Morel 58d1d6bb39 [FIX] forgot to instantiate deferred
bzr revid: xmo@openerp.com-20120703143035-zi336bg5lheocjpa
2012-07-03 16:30:35 +02:00
Xavier Morel 895dfe2448 [FIX] replace references to parent in editor with delegate, write some basic APIDoc
bzr revid: xmo@openerp.com-20120703133210-kgrj7y10cr3c8hai
2012-07-03 15:32:10 +02:00
Xavier Morel 336443d604 [IMP] hiding of readonly form fields in edition row: don't directly access DOM visibility properties
bzr revid: xmo@openerp.com-20120703110700-k0dqtthwo1g36pod
2012-07-03 13:07:00 +02:00
Xavier Morel ae6c6eb8ec [ADD] save button instead of selector during edition
bzr revid: xmo@openerp.com-20120703102750-1vmoljtbrnnl3lzo
2012-07-03 12:27:50 +02:00
Xavier Morel a5940c4147 [IMP] reload record after cancelling an edition
bzr revid: xmo@openerp.com-20120703102731-mh1gqbglenr4boem
2012-07-03 12:27:31 +02:00
Xavier Morel 1a7ca5f676 [IMP] attempt to tighten concurrent operations during save phase of an edited row
bzr revid: xmo@openerp.com-20120703093200-hxsr9pnwoszbgwgl
2012-07-03 11:32:00 +02:00
Xavier Morel 29e65ff052 [FIX] move 'behavior on save' to handler for [Return] key as it's the only situation where we want to skip to next record
bzr revid: xmo@openerp.com-20120703091058-b7wdebu8ak6gssyb
2012-07-03 11:10:58 +02:00
Xavier Morel 70fa57b9df [IMP] move onwrite handling to ListView (from List)
untested

bzr revid: xmo@openerp.com-20120702135824-ngcx34qfuu3t2kab
2012-07-02 15:58:24 +02:00
Xavier Morel 5df6c47700 [FIX] methods capitalization
bzr revid: xmo@openerp.com-20120702133451-e5b7uozm0p36jbpr
2012-07-02 15:34:51 +02:00
Xavier Morel 13cf266e2c [FIX] next on create/save
* Move prev/next behavior after save to ListView
* Have fetching of row for a record be a method chain on Group/List
* Have edition behavior be fully specified in ListView

bzr revid: xmo@openerp.com-20120702132217-ni1byjkf7t6tr5a4
2012-07-02 15:22:17 +02:00
Xavier Morel d6a9d86e09 [FIX] change event handling for 'new' records (records w/o an id yet)
bzr revid: xmo@openerp.com-20120702111026-twmh5gbg4i1fd4kj
2012-07-02 13:10:26 +02:00
Xavier Morel c262b2d1ae [FIX] shallow-copy info passed into Editor#edit to avoid mutating an object owned by somebody else
bzr revid: xmo@openerp.com-20120702110733-0qp0ki3hbw5b2nd3
2012-07-02 13:07:33 +02:00
Xavier Morel d1eeaaa51e [FIX] better filtering of id-less rows being selected in a ListView.List body
bzr revid: xmo@openerp.com-20120702110658-7t8pu12uso55enrh
2012-07-02 13:06:58 +02:00
Xavier Morel 3cc825994b [TODO] add todo note
bzr revid: xmo@openerp.com-20120702110607-csi1oa4hm6lxtwat
2012-07-02 13:06:07 +02:00
Xavier Morel ac2895fd62 [IMP] don't handle keypresses at the editor level, do that in the view instead
maybe the editor could do it and trigger an event of its own for the view to handle?

bzr revid: xmo@openerp.com-20120702093113-berlms96fqzfjlyg
2012-07-02 11:31:13 +02:00
Xavier Morel f83684265d [FIX] make edition of existing records kinda-sorta work (if the record is 'saved' by clicking on an other one)
bzr revid: xmo@openerp.com-20120628141403-z8kdg24xy5thmg50
2012-06-28 16:14:03 +02:00
Xavier Morel cbba19da67 [IMP] automatically focus first field of edited row
bzr revid: xmo@openerp.com-20120628084547-6fo7fkiy2gh2wb6m
2012-06-28 10:45:47 +02:00
Xavier Morel 94f6eec2ab [BREAK] editable list view
* Introduce overlay form on row edition
* Broken save
* Broken cancel
* (probably) broken o2m
* Broken create

bzr revid: xmo@openerp.com-20120627143228-qku9ku3zo6k59r0f
2012-06-27 16:32:28 +02:00
Xavier Morel 92431bf895 [FIX] usage of retarded API
bzr revid: xmo@openerp.com-20120625145103-bgbll0d9bcco0ikp
2012-06-25 16:51:03 +02:00
Xavier Morel 54a8f9e193 [MERGE] 6.1 changes and trunk
bzr revid: xmo@openerp.com-20120625135215-az1927llmk0vw655
2012-06-25 15:52:15 +02:00
Xavier Morel 3e2cab2aad [FIX] handling of [Return] key to save records being edited in MSIE
* DOM events sequence screwed up, requiring an explicit blur on the
  current target to try and ensure the corresponding form widget would
  register its own change event
* Requirement to stop the default behavior of keypress and keydown on
  [Return] as they would somehow trigger the contextual menu of m2o
  fields on the row, at the wrong place, when in a char field (I don't
  even...)
* Delaying of the actual saving of the form (via `setTimeout`) to try
  and ensure the blur/change event has had the time to propagate
  correctly (and be handled) before we actually save

bzr revid: xmo@openerp.com-20120615055440-yn00uv4q8y29nboq
2012-06-15 07:54:40 +02:00
Xavier Morel acfff868cb [IMP] return deferred from ListView#render_row_as_form indicating *when* the row has been rendered as a form
bzr revid: xmo@openerp.com-20120614123130-1z1vvt62rnr21bpz
2012-06-14 14:31:30 +02:00
Xavier Morel 83eef22856 [FIX] don't break the handling of record index 0 in editable list views: index 0 means something different than index = null
bzr revid: xmo@openerp.com-20120614085009-xuo1ifu2vnlcic72
2012-06-14 10:50:09 +02:00
Xavier Morel 49f6ab9853 [FIX] do not break dataset index (at the wrong moment) when clicking on [Create] row
dataset.index was previously set to ``null`` in handler of [Create]
button (to fullfill contract with form view that dataset.index should
be ``null`` to indicate the creation of a new record with no id).

Issue: after setting the index to ``null``, the list view calls
``render_row_as_form`` which starts out trying to save a row being
edited (case: clicking of the [Create] button after having selected a
row for edition or after having written in a new record e.g. [Create]
-> type -> [Create] type -> ...). This tentative to save the existing
form would be performed in the context of a ``null`` dataset.index,
which the form view doesn't (and shouldn't, index should be that of
record *being edited*) expect.

-> first save in whatever dataset state is the current one, and *right
before* creating the new form (after having saved and/or discarded the
previous one) we have the id of the new record to edit (or ``null``),
find the index for *that* and set ``dataset.index`` to that (or
``null``) so the new form view can be created and opened in the right
context.

bzr revid: xmo@openerp.com-20120613153842-pd6xitjs8n003ogs
2012-06-13 17:38:42 +02:00
Xavier Morel 9f9bbcff33 [FIX] in ensure_saved, discard non-dirty editable rows
if the editable row's form isn't dirty, either nothing has been
entered in a new row or an existing row (being edited) has not been
altered, so can just discard the row (and reload it from cache if it's
an edition).

bzr revid: xmo@openerp.com-20120613153633-ms7i8t9lvdarxqi3
2012-06-13 17:36:33 +02:00
Xavier Morel 632a4dee0c [FIX] correctly forward arguments in _super() call of editable listview's form widgets override
bzr revid: xmo@openerp.com-20120613094037-3iny9dsdhmp7qspi
2012-06-13 11:40:37 +02:00
Xavier Morel 0240ab1682 [CHG] try saving any row under edition when starting an (other) row edition
editable lists should not lose data unless explicitly asked to forget about it by user action

bzr revid: xmo@openerp.com-20120612150820-z97jxme1vcu3x3jd
2012-06-12 17:08:20 +02:00
Xavier Morel eb83b58e32 [IMP] Deferred usage in editable listview
bzr revid: xmo@openerp.com-20120612150708-0z5dsclcrtj29st3
2012-06-12 17:07:08 +02:00
niv-openerp c7e32e7175 [FIX] Problem with SelectCreatePopup, the list view can sometimes be editable
lp bug: https://launchpad.net/bugs/1005812 fixed

bzr revid: nicolas.vanhoren@openerp.com-20120607152301-mu43z3n7q2fonsuk
2012-06-07 17:23:01 +02:00
niv-openerp d70caa73d7 [fix] Put back disk icon in editable lists
bzr revid: nicolas.vanhoren@openerp.com-20120606132035-3zo2ld4q7vycuej6
2012-06-06 15:20:35 +02:00
Hiral Patel (OpenERP) 97d09bbd3c [FIX]display icon of save button.
lp bug: https://launchpad.net/bugs/985715 fixed

bzr revid: hip@tinyerp.com-20120522100448-wslfkjb6j7lj8ipc
2012-05-22 15:34:48 +05:30
Fabien Meghazi 8b95683d20 [FIX] Fix some css, remove useless classes
bzr revid: fme@openerp.com-20120510103513-ejjeab5g3s6tr4tc
2012-05-10 12:35:13 +02:00
Fabien Meghazi 9eb8e07d4f [FIX] Fix empty list menu tips on editable lists
bzr revid: fme@openerp.com-20120510092621-kbjjmo6yct1ndg3c
2012-05-10 11:26:21 +02:00
Fabien Meghazi 104615333c [MERGE] Merge trunk
bzr revid: fme@openerp.com-20120509084139-q0jae332yok87ae1
2012-05-09 10:41:39 +02:00
Antony Lesuisse bb8380314c Clark Gable is dead. Frankly, my dear, I don't give a damn.
bzr revid: al@openerp.com-20120430000158-fp451ymdjxgzwi8v
2012-04-30 02:01:58 +02:00
niv-openerp f719b8f325 [imp] modified form rendering interface
bzr revid: nicolas.vanhoren@openerp.com-20120502091053-o1knrm01225qdq0o
2012-05-02 11:10:53 +02:00
niv-openerp 8a66f58d52 [fix] problem in editable lists: could not edit an existing row
bzr revid: nicolas.vanhoren@openerp.com-20120419155514-j8bslmn6z7z1dh8h
2012-04-19 17:55:14 +02:00
niv-openerp 630eabbbb2 [fix] some problem in editable list, still not solved but made more usable until we find a real fix
bzr revid: nicolas.vanhoren@openerp.com-20120419153857-cdnau0g5yt2e1iy6
2012-04-19 17:38:57 +02:00
niv-openerp 3da11976a4 [fix] problem with editable lists & buttons
bzr revid: nicolas.vanhoren@openerp.com-20120419145051-41ywt5u35z04m8wm
2012-04-19 16:50:51 +02:00
niv-openerp 759be357ce [imp] remaining of refactoring
bzr revid: nicolas.vanhoren@openerp.com-20120417121559-e94wr8ym8sb2f7c1
2012-04-17 14:15:59 +02:00
niv-openerp f03e76c409 [fix] small problem in editable lists
bzr revid: nicolas.vanhoren@openerp.com-20120416160921-yzvyomy5jco0dsgm
2012-04-16 18:09:21 +02:00
niv-openerp de10147813 [imp] small refactoring in form view
bzr revid: nicolas.vanhoren@openerp.com-20120416150839-vr45ozrqffc72qmk
2012-04-16 17:08:39 +02:00
Jacques-Etienne Baudoux f8fc080545 [FIX] Fixed editable list view wrong class assignment.
bzr revid: cpa@tinyerp.com-20120511111527-4iz76pe2x815nd9n
2012-05-11 16:45:27 +05:30
niv-openerp 3899c7896e [imp] more refactoring in rendering engine
bzr revid: nicolas.vanhoren@openerp.com-20120410122110-iz4w1f9b8838sio4
2012-04-10 14:21:10 +02:00
niv-openerp 6de6958a85 [imp] refactoring of form registries
bzr revid: nicolas.vanhoren@openerp.com-20120410120938-y0iwowq7hsvdzjji
2012-04-10 14:09:38 +02:00
niv-openerp 92b3a975f3 [imp] added save button in editable list
bzr revid: nicolas.vanhoren@openerp.com-20120327163417-qba5kkwtgulomjru
2012-03-27 18:34:17 +02:00