Merge pull request #21490 from edx/BOM-262

BOM-262 Python 3 fixes
This commit is contained in:
Aarif
2019-09-02 14:26:55 +05:00
committed by GitHub

View File

@@ -9,6 +9,7 @@ from collections import OrderedDict
from django.core.exceptions import ValidationError
from django.db import models
from django.utils.encoding import python_2_unicode_compatible
from lxml import etree
from model_utils.models import TimeStampedModel
from opaque_keys.edx.django.models import CourseKeyField
@@ -20,6 +21,7 @@ from survey.exceptions import SurveyFormNameAlreadyExists, SurveyFormNotFound
log = logging.getLogger("edx.survey")
@python_2_unicode_compatible
class SurveyForm(TimeStampedModel):
"""
Model to define a Survey Form that contains the HTML form data
@@ -35,7 +37,7 @@ class SurveyForm(TimeStampedModel):
class Meta(object):
app_label = 'survey'
def __unicode__(self):
def __str__(self):
return self.name
def save(self, *args, **kwargs):