Skip to content

Commit

Permalink
fixes #5197
Browse files Browse the repository at this point in the history
added __unicode__ functions for menu and menu items
  • Loading branch information
gannebamm committed Nov 5, 2019
1 parent fc129fb commit 6092957
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions geonode/base/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -1358,6 +1358,8 @@ class MenuPlaceholder(models.Model):
blank=False,
unique=True
)
def __unicode__(self):
return u"{0}".format(self.name)

def __str__(self):
return self.name
Expand All @@ -1379,6 +1381,9 @@ class Menu(models.Model):
null=False,
)

def __unicode__(self):
return u"{0}".format(self.title)

def __str__(self):
return self.title

Expand Down Expand Up @@ -1412,6 +1417,9 @@ class MenuItem(models.Model):
blank=False
)

def __unicode__(self):
return u"{0}".format(self.title)

def __str__(self):
return self.title

Expand Down

0 comments on commit 6092957

Please sign in to comment.