Include the field_id in the context of _as_table_helper
authorSverre Rabbelier <srabbelier@gmail.com>
Wed, 04 Feb 2009 23:04:10 +0000
changeset 1214 7fb705534dd1
parent 1213 365b4a2df40d
child 1215 b21e40ef8dad
Include the field_id in the context of _as_table_helper This makes it possible to refer to the field that is being edited by it's ID (in for example Javascript). Patch by: "Mario Ferraro" <fadinlight@gmail.com>
app/soc/views/helper/templatetags/forms_helpers.py
--- a/app/soc/views/helper/templatetags/forms_helpers.py	Wed Feb 04 23:01:36 2009 +0000
+++ b/app/soc/views/helper/templatetags/forms_helpers.py	Wed Feb 04 23:04:10 2009 +0000
@@ -263,6 +263,7 @@
       'field_class_type': field_class_type,
       'label': force_unicode(label) if field.label else '',
       'field': unicode(field),
+      'field_id': field.auto_id,
       'required': required,
       'example_text': example_text,
       'select_url': select_url if reference else None,