# HG changeset patch # User Alexandre Fayolle # Date 1254840982 -7200 # Node ID f1dbb9bf4da322b9df5e8199b801f9801dfa8cf3 # Parent cff18f0d7c73e920eb2d4e0f3aaa288f09950baf fix label in generated form for relations the label for object relations was incorrect, because the '_object' mangling is done on the wrong component of field.label. fix ticket 472831 diff -r cff18f0d7c73 -r f1dbb9bf4da3 web/formfields.py --- a/web/formfields.py Tue Oct 06 14:14:16 2009 +0200 +++ b/web/formfields.py Tue Oct 06 16:56:22 2009 +0200 @@ -576,6 +576,8 @@ skip_meta_attr=False) return fieldclass(**kwargs) kwargs['role'] = role + if role == 'object': # tag the type with '_object' instead of the type + kwargs['label'] = (eschema.type, rschema.type + '_object') return RelationField.fromcardinality(card, **kwargs)