Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
problem-builder
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
problem-builder
Commits
e2f8c7ad
Commit
e2f8c7ad
authored
May 05, 2015
by
E. Kolpakov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added ability to override feedback messages title
parent
a4703a2a
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
11 additions
and
4 deletions
+11
-4
problem_builder/mentoring.py
+7
-1
problem_builder/public/js/mentoring.js
+2
-1
problem_builder/public/js/mentoring_standard_view.js
+1
-1
problem_builder/templates/html/mentoring.html
+1
-1
No files found.
problem_builder/mentoring.py
View file @
e2f8c7ad
...
@@ -131,6 +131,12 @@ class MentoringBlock(XBlock, StepParentMixin, StudioEditableXBlockMixin, StudioC
...
@@ -131,6 +131,12 @@ class MentoringBlock(XBlock, StepParentMixin, StudioEditableXBlockMixin, StudioC
default
=
_
(
"Mentoring Questions"
),
default
=
_
(
"Mentoring Questions"
),
scope
=
Scope
.
settings
scope
=
Scope
.
settings
)
)
feedback_label
=
String
(
display_name
=
_
(
"Feedback Messages Title"
),
help
=
_
(
"Title for feedback messages"
),
default
=
_
(
"Feedback"
),
scope
=
Scope
.
content
)
# User state
# User state
attempted
=
Boolean
(
attempted
=
Boolean
(
...
@@ -170,7 +176,7 @@ class MentoringBlock(XBlock, StepParentMixin, StudioEditableXBlockMixin, StudioC
...
@@ -170,7 +176,7 @@ class MentoringBlock(XBlock, StepParentMixin, StudioEditableXBlockMixin, StudioC
editable_fields
=
(
editable_fields
=
(
'display_name'
,
'mode'
,
'followed_by'
,
'max_attempts'
,
'enforce_dependency'
,
'display_name'
,
'mode'
,
'followed_by'
,
'max_attempts'
,
'enforce_dependency'
,
'display_submit'
,
'weight'
,
'display_submit'
,
'
feedback_label'
,
'
weight'
,
)
)
icon_class
=
'problem'
icon_class
=
'problem'
has_score
=
True
has_score
=
True
...
...
problem_builder/public/js/mentoring.js
View file @
e2f8c7ad
...
@@ -22,7 +22,8 @@ function MentoringBlock(runtime, element) {
...
@@ -22,7 +22,8 @@ function MentoringBlock(runtime, element) {
hideAllSteps
:
hideAllSteps
,
hideAllSteps
:
hideAllSteps
,
step
:
step
,
step
:
step
,
steps
:
steps
,
steps
:
steps
,
publish_event
:
publish_event
publish_event
:
publish_event
,
data
:
data
};
};
function
publish_event
(
data
)
{
function
publish_event
(
data
)
{
...
...
problem_builder/public/js/mentoring_standard_view.js
View file @
e2f8c7ad
...
@@ -25,7 +25,7 @@ function MentoringStandardView(runtime, element, mentoring) {
...
@@ -25,7 +25,7 @@ function MentoringStandardView(runtime, element, mentoring) {
// Messages should only be displayed upon hitting 'submit', not on page reload
// Messages should only be displayed upon hitting 'submit', not on page reload
mentoring
.
setContent
(
messagesDOM
,
results
.
message
);
mentoring
.
setContent
(
messagesDOM
,
results
.
message
);
if
(
messagesDOM
.
html
().
trim
())
{
if
(
messagesDOM
.
html
().
trim
())
{
messagesDOM
.
prepend
(
'<div class="title1">'
+
gettext
(
'Feedback'
)
+
'</div>'
);
messagesDOM
.
prepend
(
'<div class="title1">'
+
mentoring
.
data
.
feedback_label
+
'</div>'
);
messagesDOM
.
show
();
messagesDOM
.
show
();
}
}
...
...
problem_builder/templates/html/mentoring.html
View file @
e2f8c7ad
{% load i18n %}
{% load i18n %}
<div
class=
"mentoring themed-xblock"
data-mode=
"{{ self.mode }}"
data-step=
"{{ self.step }}"
>
<div
class=
"mentoring themed-xblock"
data-mode=
"{{ self.mode }}"
data-step=
"{{ self.step }}"
data-feedback_label=
"{{ self.feedback_label}}"
>
<div
class=
"missing-dependency warning"
data-missing=
"{{ self.has_missing_dependency }}"
>
<div
class=
"missing-dependency warning"
data-missing=
"{{ self.has_missing_dependency }}"
>
{% with url=missing_dependency_url|safe %}
{% with url=missing_dependency_url|safe %}
{% blocktrans with link_start="
<a
href=
'"|add:url|add:"'
>
" link_end="
</a>
" %}
{% blocktrans with link_start="
<a
href=
'"|add:url|add:"'
>
" link_end="
</a>
" %}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment