[Answered ]-How do I properly specify arguments to display a method's output in Django admin?

1👍

The method should take two parameters; self: MyModelAdmin instance, obj: MyModel instance.

Replacing my_method as following will solve your problem:

def my_method(self, obj):
    return obj.get_some_info()

1👍

Alternatively, you can just add "get_some_info" directly in list_display.

Leave a comment