[Answer]-"self" in Django Model methods

1👍

In your model class Album:

sort_name = models.CharField(max_length=255, null=True, blank=True, default=self.s_n)

the self.s_n should be just s_n

sort_name = models.CharField(max_length=255, null=True, blank=True, default=s_n)

Leave a comment