Merge pull request #14891 from edx/noriaz/ECOM-7537

ECOM-7537 Priortize advertised start date to diplay on learner's dashboard
This commit is contained in:
Noraiz Anwar
2017-04-17 11:46:34 +05:00
committed by GitHub
3 changed files with 44 additions and 4 deletions

View File

@@ -361,6 +361,13 @@ class CourseOverview(TimeStampedModel):
"""
return block_metadata_utils.display_name_with_default_escaped(self)
@property
def dashboard_start_display(self):
"""
Return start date to diplay on learner's dashboard, preferably `Course Advertised Start`
"""
return self.advertised_start or self.start
def has_started(self):
"""
Returns whether the the course has started.