>From tutorial, part 2, the following type of code
class Poll(models.Model):
...
class Admin:
fields = ( )
is used to control how the admin interface displays the Poll objects
(controlling which items appear on separate lines, etc).
How can I control how the contained obje
I'm having a problem with custom forms and models with related objects.
I've created a simplified test case that illustrates the problem.
Here is the model file (a room contains several chairs):
-- model.py -
class Room(models.Model):
name = models.CharField(ma
Thanks ElGranAzul, my django code is up to date (via svn), so
'oldforms' is equivalent to 'forms' (the __init__.py files are the
same). So using 'from django import oldforms as forms' may be better
form (no pun intended!), but will not fix the problem I'm trying to
figure out.
Both RoomForm a
Thanks Justin!
I just figured this out myself. I'll include the updated RoomForm
definition below since I've cleaned it up a bit and made a small fix to
the save function:
--
from django.db.models.related import RelatedObjec
4 matches
Mail list logo