Skip to content

Commit

Permalink
Improve assigment ordering and name
Browse files Browse the repository at this point in the history
  • Loading branch information
maxicecilia committed May 30, 2015
1 parent 327564a commit ce45411
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion simple_classroom/apps/classroom/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -164,9 +164,10 @@ class Assignment(OrderedModel):
class Meta(OrderedModel.Meta):
verbose_name = _(u'Asignación')
verbose_name_plural = _(u'Asignaciones')
ordering = ['-dictation__year', 'title']

def __unicode__(self):
return u'{}'.format(self.title)
return u'{} ({})'.format(self.title, self.dictation.year)

@staticmethod
def autocomplete_search_fields():
Expand Down

0 comments on commit ce45411

Please sign in to comment.