[autoform] fix restoration of pending generic relation: inconsistent id was generated (eg different from the one generated by javascript stable
authorSylvain Thénault <sylvain.thenault@logilab.fr>
Thu, 02 Dec 2010 10:08:28 +0100
branchstable
changeset 6725 6e6d1d19f341
parent 6722 3341521d857b
child 6726 51880d28ef63
[autoform] fix restoration of pending generic relation: inconsistent id was generated (eg different from the one generated by javascript
web/views/autoform.py
--- a/web/views/autoform.py	Wed Dec 01 17:08:42 2010 +0100
+++ b/web/views/autoform.py	Thu Dec 02 10:08:28 2010 +0100
@@ -550,6 +550,7 @@
         pending_inserts = set(get_pending_inserts(form._cw, form.edited_entity.eid))
         for pendingid in pending_inserts:
             eidfrom, rtype, eidto = pendingid.split(':')
+            pendingid = 'id' + pendingid
             if typed_eid(eidfrom) == entity.eid: # subject
                 label = display_name(form._cw, rtype, 'subject',
                                      entity.__regid__)