That worked like a charm! I read about the double underscore but didn't
think much about it when it crossed my mind. I've been grinding on this for
the whole day. My eyes... =)
On Tuesday, June 26, 2012 1:04:40 PM UTC-7, Kurtis wrote:
>
> I performed infobox = InfoDetail.objects.filter(title=in
>
> I performed infobox = InfoDetail.objects.filter(title=info_title), but it
> returns an error cus 'title' doesn't live in InfoDetail.
>
> How can i grab and filter it by title and pass {'infobox': infobox} in
> HttpResponse when HttpRequest is called?
>
If you want to filter by a certain title
I'm trying to pass a objects.filter dictionary to HttpResponse. The problem
is I have 2 models: InfoBox and InfoDetail. InfoDetail is linked to InfoBox
by models.ForeignKey(InfoBox). What I want to do is filter by title which
lives in the InfoBox model. I performed infobox =
InfoDetail.objects.
3 matches
Mail list logo