O'Reilly logo

Django 1.1 Testing and Debugging by Karen M. Tracey

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Customizing the admin add and change survey pages

We've already seen how the Django admin application provides a convenient way to examine and manipulate data in our database. In the previous chapter, we set up the admin with some simple customizations to allow editing Questions inline with Surveys and Answers inline with Questions. Besides those inline customizations, however, we made no changes to the admin defaults.

One additional change that would be good to make to the admin is to ensure that Survey opens and closes dates are valid. Clearly for this application, it makes no sense to have an opens date that is later than closes, but there is no way for the admin to know that. In this section, we will customize the admin to enforce our application ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required