Re: Filtering Queryset by Foreign Key Properties

2011-02-11 Thread josch
Thank you both! -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit

Filtering Queryset by Foreign Key Properties

2011-02-11 Thread josch
Hi, I`m searching for a solution for the following problem: I have, for example, those two classes: class Order(self): type = models.CharField(1) class OrderPositions(self): order = ForeignKey(Order) Now I want to get every Order Position, whoose order has the type, for exampl

Re: Order a QuerySet by Method

2010-12-18 Thread josch
Another Question: How can I filter such an object list? -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@g

Re: Order a QuerySet by Method

2010-12-15 Thread josch
Thank you! On 15 Dez., 15:21, Daniel Roseman wrote: > On Wednesday, December 15, 2010 1:34:15 PM UTC, josch wrote: > > > Hallo, > > > I know, that the normal way to do that is to write the return value of > > the method to the foreign model, always when a model that a

Beginner Problem: I don`t get my view working

2010-12-15 Thread josch
Hallo, I don`t know what is wrong with my code, but I can not call a view in the urls.py of my site: I have an application hspoints. In the folder is a views.py. In will post a view files: settings.py of my Site: (...) INSTALLED_APPS = ( 'django.contrib.auth', 'django.contrib.contentty

Order a QuerySet by Method

2010-12-15 Thread josch
Hallo, I know, that the normal way to do that is to write the return value of the method to the foreign model, always when a model that affects the return value changes, and than order by that value of the model. But I have a model whoose objects gets a specific state after they are older than a