Coding consistency changes for code review.

This commit is contained in:
Don Mitchell
2013-05-29 12:39:18 -04:00
parent b7cfbe0ce6
commit e47f8b1765
2 changed files with 5 additions and 4 deletions

View File

@@ -990,7 +990,7 @@ class ContentStoreTest(ModuleStoreTestCase):
def test_metadata_inheritance(self):
module_store = modulestore('direct')
import_from_xml(module_store, 'common/test/data/', ['full'], verbose=True)
import_from_xml(module_store, 'common/test/data/', ['full'])
course = module_store.get_item(Location(['i4x', 'edX', 'full', 'course', '6.002_Spring_2012', None]))

View File

@@ -18,6 +18,7 @@ import json
from xblock.core import Scope, List, String, Object, Boolean
from .fields import Date
from django.utils.timezone import UTC
from xmodule.util import date_utils
log = logging.getLogger(__name__)
@@ -743,15 +744,15 @@ class CourseDescriptor(CourseFields, SequenceDescriptor):
@property
def first_eligible_appointment_date_text(self):
return datetime.strftime("%b %d, %Y", self.first_eligible_appointment_date)
return self.first_eligible_appointment_date.strftime("%b %d, %Y")
@property
def last_eligible_appointment_date_text(self):
return datetime.strftime("%b %d, %Y", self.last_eligible_appointment_date)
return self.last_eligible_appointment_date.strftime("%b %d, %Y")
@property
def registration_end_date_text(self):
return datetime.strftime("%b %d, %Y at %H:%M UTC", self.registration_end_date)
return date_utils.get_default_time_display(self.registration_end_date)
@property
def current_test_center_exam(self):