[Answer]-Using a Django Custom Manager

1👍

This isn’t something that you’d do in a Manager. This is a job for a normal Model method.

Manager methods are for things that modify the query in some way. That’s not what you want to do: you want to annotate a property to each object in the queryset. Since that doesn’t require any further database calculations, a model method is the appropriate place.

Leave a comment