https://docs.djangoproject.com/en/dev/ref/class-based-views/generic-display/#detailview
Many thanks,
Serge
+380 636150445
skype: skhohlov
2012/12/12 Jonas Geiregat :
> Thanks for the response Serge,
>
> So basically I was on the right path.
>
> But I don't see what the DetailView has to do wit
Thanks for the response Serge,
So basically I was on the right path.
But I don't see what the DetailView has to do with this ? Don't you mean the
CreateView ?
Jonas.
> 1) you should create a form for building
> 2) you should create a form for inhabitant and set key to the correct
> value be
1) you should create a form for building
2) you should create a form for inhabitant and set key to the correct
value before saving
IMHO simple way is create a edit form for buiding which has buttons
add/remove inhabitant . check DetailView in docs please
thanks, Serge
skype: skhohlov
te
Hello,
Suppose I have a model with a foreign key.
class Building(models.Model):
pass
class Inhabitant(models.Model):
building = models.ForeignKey(Building)
I would like to display a form where all fields from the Building model and
Inhabitant model are visible (but only once)
Should I
4 matches
Mail list logo