I have a model which has an active
field, and i want to filter out all records which are inactive basing on this field. Let's say:
Record(Model):
active = BooleanField()
...
to filter them out i can do:
Record.objects(active=True)
But it is a general case and i want inactive records to be filtered out almost any time. What is the best way to follow DRY principle and do not filter every request i do manually like in example above and in meantime keep the ability to manage inactive records in admin panel.