I have a todo model defined below:
class Action(models.Model):
name = models.CharField(\"Action Name\", max_length=200, unique = True)
complete = mo
The problem is that tags
is not a field, but a custom manager, which lives at the class-level and simply does queries.
I am not sure if this will work on custom managers, as it is meant for many-to-many fields and the like that produce similar query sets. But if you are using django 1.4 you can try the prefetch_related. It will do one more query that batches out the relations and caches them.
Disclaimer again: I don't know if this works for managers
actions = Action.objects.select_related('reoccurance').filter(complete=False)\
.prefetch_related('tags')