#8993: Rendering formsets as tables with a row per form
---------------------------------------+------------------------------------
 Reporter:  [EMAIL PROTECTED]  |       Owner:  nobody    
   Status:  new                        |   Milestone:            
Component:  Uncategorized              |     Version:  SVN       
 Keywords:  formsets                   |       Stage:  Unreviewed
Has_patch:  1                          |  
---------------------------------------+------------------------------------
 In the default as_table method of formsets it states:

 {{{
         # XXX: there is no semantic division between forms here, there
         # probably should be. It might make sense to render each form as a
         # table row with each field as a td.
 }}}

 The attached patch provides an 'as_table_wide' method, which does this.
 It calls an 'as_row' method on each form.  This 'as_row' method is also
 supplied in the patch.

 It is also useful to be able to easily include extra columns in the table,
 that are not form entries, but which depend on the form.  This is
 especially true for model formsets, where the contents of the extra
 columns depends on the same model instance as the form, eg for fields of
 the model that may not change, but which should be displayed.  This can be
 done by providing a form class with its own 'as_row' method, which
 modifies the standard one.

-- 
Ticket URL: <http://code.djangoproject.com/ticket/8993>
Django Code <http://code.djangoproject.com/>
The web framework for perfectionists with deadlines
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to