Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
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
edx
edx-platform
Commits
706fd99c
Commit
706fd99c
authored
Aug 13, 2012
by
Victor Shnayder
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Address comments on #394
parent
ecffe3e0
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
9 deletions
+5
-9
common/lib/xmodule/xmodule/x_module.py
+2
-2
lms/djangoapps/courseware/grades.py
+3
-7
No files found.
common/lib/xmodule/xmodule/x_module.py
View file @
706fd99c
...
...
@@ -227,7 +227,7 @@ class XModule(HTMLSnippet):
def
get_display_items
(
self
):
'''
Returns a list of descendent module instances that will display
immediately inside this module
immediately inside this module
.
'''
items
=
[]
for
child
in
self
.
get_children
():
...
...
@@ -238,7 +238,7 @@ class XModule(HTMLSnippet):
def
displayable_items
(
self
):
'''
Returns list of displayable modules contained by this module. If this
module is visible, should return [self]
module is visible, should return [self]
.
'''
return
[
self
]
...
...
lms/djangoapps/courseware/grades.py
View file @
706fd99c
...
...
@@ -145,15 +145,11 @@ def progress_summary(student, course, grader, student_module_cache):
instance_modules for the student
"""
chapters
=
[]
for
c
in
course
.
get_children
():
# Don't include chapters that aren't displayable (e.g. due to error)
if
c
not
in
c
.
displayable_items
():
continue
# Don't include chapters that aren't displayable (e.g. due to error)
for
c
in
course
.
get_display_items
():
sections
=
[]
for
s
in
c
.
get_
children
():
for
s
in
c
.
get_
display_items
():
# Same for sections
if
s
not
in
s
.
displayable_items
():
continue
graded
=
s
.
metadata
.
get
(
'graded'
,
False
)
scores
=
[]
for
module
in
yield_module_descendents
(
s
):
...
...
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