SciPost Code Repository

Skip to content
Snippets Groups Projects
Commit eeedebf4 authored by Jean-Sébastien Caux's avatar Jean-Sébastien Caux
Browse files

Beautify ProfileNonDuplicates

parent 17f38de8
No related branches found
No related tags found
No related merge requests found
...@@ -149,6 +149,15 @@ class ProfileNonDuplicates(models.Model): ...@@ -149,6 +149,15 @@ class ProfileNonDuplicates(models.Model):
profiles = models.ManyToManyField('profiles.Profile') profiles = models.ManyToManyField('profiles.Profile')
reason = models.CharField(max_length=32, choices=PROFILE_NON_DUPLICATE_REASONS) reason = models.CharField(max_length=32, choices=PROFILE_NON_DUPLICATE_REASONS)
class Meta:
verbose_name = 'Profile non-duplicates'
verbose_name_plural = 'Profile non-duplicates'
def __str__(self):
return '%s, %s (%i)' % (self.profiles.first().last_name,
self.profiles.first().first_name,
self.profiles.count())
@property @property
def full_name(self): def full_name(self):
return '%s%s' % (self.profiles.first().last_name, self.profiles.first().first_name) return '%s%s' % (self.profiles.first().last_name, self.profiles.first().first_name)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment