Unverified Commit 0fd61159 authored by David Haynes's avatar David Haynes 🙆
Browse files

refactor: __unicode__ -> __str__ in models



- deprecation fix
Signed-off-by: David Haynes's avatarDavid Haynes <dhaynes3@gmu.edu>
parent a167e64c
Pipeline #1204 passed with stage
in 19 seconds
......@@ -20,7 +20,7 @@ class Category(TimeStampedModel):
# Sort by name in admin view
ordering = ['name']
def __unicode__(self):
def __str__(self):
return '%s' % self.name
class Facility(TimeStampedModel):
......@@ -67,7 +67,7 @@ class Facility(TimeStampedModel):
return True
return False
def __unicode__(self):
def __str__(self):
return self.name
class Schedule(TimeStampedModel):
......@@ -95,7 +95,7 @@ class Schedule(TimeStampedModel):
return True
return False
def __unicode__(self):
def __str__(self):
return self.name
......@@ -151,7 +151,7 @@ class OpenTime(TimeStampedModel):
return False
return True
def __unicode__(self):
def __str__(self):
weekdays = ['Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday',
'Saturday', 'Sunday']
return '%s %s to %s %s' % (weekdays[self.start_day],
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment