Right, the intent there is to make the UI clear for the instructor--so they
only see homework assignments and exams, not individual problems.




On Wed, Oct 16, 2013 at 8:19 PM, ichuang <notifications@github.com> wrote:

> In lms/djangoapps/instructor/views/extensions.py:
>
> > +        if found:
> > +            return found
> > +    return None
> > +
> > +
> > +def get_units_with_due_date(course):
> > +    units = []
> > +    def visit(node, level=0):
> > +        if getattr(node, 'due', None):
> > +            units.append(node)
> > +        else:
> > +            for child in node.get_children():
> > +                visit(child, level+1)
> > +    visit(course)
> > +    units.sort(key=title_or_url)
> > +    return units
>
> That's fine for now. The documentation should make it clear to course
> authors that if a set X of problems needs to allow due date extensions,
> then X should be given a single due date using a container holding X. The
> natural place for this is a sequential, since due dates are shown in the
> edX UI at that level.
> … <#141c3c854750f580_>
> On Wed, Oct 16, 2013 at 7:57 PM, Peter Pinch <notifications@github.com>wrote:
> In lms/djangoapps/instructor/views/extensions.py: > + if found: > + return
> found > + return None > + > + > +def get_units_with_due_date(course): > +
> units = [] > + def visit(node, level=0): > + if getattr(node, 'due', None):
> > + units.append(node) > + else: > + for child in node.get_children(): > +
> visit(child, level+1) > + visit(course) > + units.sort(key=title_or_url) >
> + return units Unless I'm mistaken, get_units_with_due_dates() appears to
> only walk the course tree until it hits a due date and then it stops. I
> think that works for our needs, but I wanted to check. @ichuang<https://github.com/ichuang><
> https://github.com/ichuang> — Reply to this email directly or view it on
> GitHub<https://github.com/edx/edx-platform/pull/1338/files#r7020281> .
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/edx/edx-platform/pull/1338/files#r7020742>
> .
>