Commit 5b8531f0 by Xavier Antoviaque

Merge pull request #50 from edx-solutions/display-name

display-name: Update usage of `display_name` to include upstream changes
parents fd3a1532 c9474bcf
...@@ -83,6 +83,8 @@ class MentoringBlock(XBlockWithLightChildren): ...@@ -83,6 +83,8 @@ class MentoringBlock(XBlockWithLightChildren):
student_results = List(help="Store results of student choices.", default=[], student_results = List(help="Store results of student choices.", default=[],
scope=Scope.user_state) scope=Scope.user_state)
display_name = String(help="Display name of the component", default="Mentoring XBlock",
scope=Scope.settings)
icon_class = 'problem' icon_class = 'problem'
has_score = True has_score = True
...@@ -403,14 +405,3 @@ class MentoringBlock(XBlockWithLightChildren): ...@@ -403,14 +405,3 @@ class MentoringBlock(XBlockWithLightChildren):
Scenarios displayed by the workbench. Load them from external (private) repository Scenarios displayed by the workbench. Load them from external (private) repository
""" """
return get_scenarios_from_path('templates/xml') return get_scenarios_from_path('templates/xml')
@property
def display_name_with_default(self):
"""
Return a display name for the module: use display_name if defined in
metadata, otherwise use a custom default value.
"""
name = self.display_name
if name is None:
name = "Mentoring Block"
return name
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