Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
edx-platform-release
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
1
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Hsin-Yu Chien
edx-platform-release
Commits
f1542028
Commit
f1542028
authored
12 years ago
by
kimth
Browse files
Options
Downloads
Plain Diff
Merge pull request #986 from MITx/feature/arjun/allow_save
Feature/arjun/allow save
parents
040464cf
75f0a56d
Loading
Loading
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
common/lib/xmodule/xmodule/capa_module.py
+6
-3
6 additions, 3 deletions
common/lib/xmodule/xmodule/capa_module.py
with
6 additions
and
3 deletions
common/lib/xmodule/xmodule/capa_module.py
+
6
−
3
View file @
f1542028
...
...
@@ -120,6 +120,8 @@ class CapaModule(XModule):
self
.
show_answer
=
self
.
metadata
.
get
(
'
showanswer
'
,
'
closed
'
)
self
.
force_save_button
=
self
.
metadata
.
get
(
'
force_save_button
'
,
'
false
'
)
if
self
.
show_answer
==
""
:
self
.
show_answer
=
"
closed
"
...
...
@@ -320,9 +322,10 @@ class CapaModule(XModule):
if
not
self
.
lcp
.
done
:
reset_button
=
False
# We don't need a "save" button if infinite number of attempts and
# non-randomized
if
self
.
max_attempts
is
None
and
self
.
rerandomize
!=
"
always
"
:
# We may not need a "save" button if infinite number of attempts and
# non-randomized. The problem author can force it. It's a bit weird for
# randomization to control this; should perhaps be cleaned up.
if
(
self
.
force_save_button
==
"
false
"
)
and
(
self
.
max_attempts
is
None
and
self
.
rerandomize
!=
"
always
"
):
save_button
=
False
context
=
{
'
problem
'
:
content
,
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment