[Answer]-How can I add a custom method to auth_user model class? I need to return a calculated field along with results

1👍

You can extend the django user model.

class Employee(models.Model):
    user = models.OneToOneField(User)
    def get_manager():
        ...

and in your template you can write

{{ user.employee.get_manager }}
👤OBu

0👍

Suppose that your user class is ‘User’. To return its default manager, call:

User._default_manager

Leave a comment