Commit graph

11 commits

Author SHA1 Message Date
Henrik Levkowetz 26a97835a5 * More logic moved to ipr/views.py.
* Added InternationalPhoneNumberField to ipr/models.py
  Probably should be moved to a common model class file.
 - Legacy-Id: 106
2007-05-06 22:09:52 +00:00
Henrik Levkowetz e8980df65f IPR Form display now works with the same template as data display.
Using some more logic in views.py, less in the templated.

 * Some tweaks in FormattingForm rendering.
 * Selection of which sections to show is now table driven in views.py
 * Some minor refactoring and cleanup in views.py
 * Some more form subclassing in ipr/views.py in order to support form
   validation.
 * Removed style information from ipr/details.html template, and added
   ipr/style.html
 * Cleanup of details.html
 * Fixed ipr/formfield.html to display error messages, and with the right
   class.
 - Legacy-Id: 105
2007-05-06 19:18:17 +00:00
Henrik Levkowetz 68d4a58fa7 The fourth (and last?) take on a form from multiple models,
using pretty much the same template as for a non-form view.

This solution is less hackish than the previous one which
used the form.as_table() rendering of a form, and then split
the resulting html in chunks.

Instead, '''all''' the html has been moved out to a formfield
template, and a custom form class is generated which will render
the form elements using an indicated template.

 * Add form factory in utils.py (an old version which still has
   html in the code is there for history, but will be removed

 * Changes in ipr/views.py:new(), now subclassing one form with
   some class members being other form instances, matching the
   members used for the show() view

 * A fix in ipr/models, making an email field use models.EmailField

 * Reverting a number of changes in ipr/details.html which aren't
   needed any more, as well as in ipr/new.html; and adding
   ipr/formfield.html
 - Legacy-Id: 104
2007-05-06 05:35:46 +00:00
Henrik Levkowetz 80829985a0 Added prettifying middleware (from djangosnippet 172)
- Legacy-Id: 103
2007-05-06 05:14:25 +00:00
Henrik Levkowetz d927568b25 * Added henrik's IPs to local sites in settings.py
* Added accessor functions for contacts to ipr/models.py
 * Added an IPR feed
 - Legacy-Id: 102
2007-05-05 08:58:22 +00:00
Bill Fenner f9b9b51536 Add author to iesg telechat minutes feed, to make it valid.
Add document comments feed to top-level urls.
 - Legacy-Id: 101
2007-05-04 21:49:21 +00:00
Bill Fenner 5fb1900540 Remove rfcs model; it's now in idtracker.
- Legacy-Id: 100
2007-05-04 21:35:33 +00:00
Bill Fenner 19896dc647 Adapt to moved Rfc model.
- Legacy-Id: 99
2007-05-04 21:35:12 +00:00
Bill Fenner e73f7dbf5f Implement most of view_id.
* Moved RFCs model into idtracker
 * Switched idtracker querys to use idinternal
 * Created idinternal.document which returns either an InternetDraft or
   an Rfc depending on the value of rfc_flag
 * Create compatability methods in InternetDraft and Rfc models
   to be able to use certain attributes in the template without
   worring about where they come from.

Ticket #59 has a list of remaining bits.
 - Legacy-Id: 98
2007-05-04 21:33:56 +00:00
Henrik Levkowetz c2c08c9edc * Added a new funtion in utils.py: split_form()
* Re-wrote the IPR declaration form using form.to_table()
   and the split_form() function in order to get sub-blocks
   of the form which could easily be used with the existing
   IPR detail display templates.

   How to merge forms from multiple models took some thinking;
   since the forms have a common ancestor, multiple inheritance
   doesn't preserve the form data.  In the end the merging
   didn't turn out too horrible.  See ipr.views.new().
 * Changed the IprDetail model; first to specify editable=False
   for all fieleds which shouldn't be shown in the form, but
   this has the drawback of also removing them from the admin
   page form.  Simply bagging them in an un-used sub block with
   split_form() works fine.
 * Changed the URLs for IPR by-date some again
 * Updated the ipr/new* templates to use the form sub-blocks
 - Legacy-Id: 97
2007-05-04 20:21:03 +00:00
Henrik Levkowetz 5872696834 Moving ietf to trunk/ietf
[[Split portion of a mixed commit.]]
 - Legacy-Id: 96.1
2007-05-04 12:37:28 +00:00