Discussion:
[Erp5-dev] Re: [Erp5-report] r10319 - /erp5/trunk/products/ERP5Form/RelationField.py
Romain Courteaud
2006-09-27 07:57:14 UTC
Permalink
Hi,

Yesterday, I fixed a bug in RelationField, which was using the default value
of the LinesField ([]) as its default value.
As default values are saved inside each field, it is needed to update each
RelationField present in your site.

I attached an external method I used on my site.

Regards,
Romain
Author: romain
Date: Tue Sep 26 11:37:29 2006
New Revision: 10319
URL: http://svn.erp5.org?rev=10319&view=rev
Set default value of a RelationField as the default value of a TextField.
erp5/trunk/products/ERP5Form/RelationField.py
Modified: erp5/trunk/products/ERP5Form/RelationField.py
http://svn.erp5.org/erp5/trunk/products/ERP5Form/RelationField.py?rev=10319
&r1=10318&r2=10319&view=diff
===========================================================================
=== --- erp5/trunk/products/ERP5Form/RelationField.py (original)
+++ erp5/trunk/products/ERP5Form/RelationField.py Tue Sep 26 11:37:29 2006
@@ -55,6 +55,7 @@
MultiRelationField.MultiRelationStringFieldWidget.local_property_names
default_widget_rendering_instance = Widget.TextWidgetInstance
+ default = Widget.TextWidget.default
# value = value or NO_VALUE
_______________________________________________
Erp5-report mailing list
Erp5-report at erp5.org
http://www.erp5.org/mailman/listinfo/erp5-report
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fixrelationfield.py.zip
Type: application/x-zip
Size: 516 bytes
Desc: not available
URL: <http://mail.tiolive.com/pipermail/erp5-dev/attachments/20060927/50796ce9/attachment.bin>
Loading...