django - retrieving objects from another model -
i have situation:
class item (models.model): name = models.charfield(maxlenght=15) class itemishired(models.model): item = models.foreignkey(item) ishirednow = models.booleanfield(null=false)
the thing want retrieve items hired right now, if make query using itemishired.objects.filter(ishirednow=true)
objects itemishired
class when want objects item class related them.
Comments
Post a Comment