From 4992be76c6e059248b6bfdfa1c750ecb5b9be9a9 Mon Sep 17 00:00:00 2001 From: Bridger Maxwell Date: Fri, 3 Feb 2012 17:03:24 -0500 Subject: [PATCH] Added links from profile page back to courseware. This is also the last commit with the course overview graph enabled. It is about to be removed. --- accordion.html | 6 +++++- profile.html | 25 ++++++++++++++++++++----- 2 files changed, 25 insertions(+), 6 deletions(-) diff --git a/accordion.html b/accordion.html index b9502acb9c..bf3332d788 100644 --- a/accordion.html +++ b/accordion.html @@ -1,3 +1,7 @@ +<%! + from django.core.urlresolvers import reverse +%> + <%def name="make_chapter(chapter)">

${chapter['name']}

@@ -9,7 +13,7 @@ % endif > - +

${section['name']}

diff --git a/profile.html b/profile.html index c846178b06..3a9646614c 100644 --- a/profile.html +++ b/profile.html @@ -1,5 +1,9 @@ <%inherit file="main.html" /> +<%! + from django.core.urlresolvers import reverse +%> + <%block name="headextra"> @@ -86,16 +90,27 @@ $(function() {

Course Progress

- - +
+
    + <% + lastChapter = None + %> % for hw in homeworks:
  1. -

    ${ hw['chapter'] }

    + %if hw['chapter'] != lastChapter: +

    + ${ hw['chapter'] }

    + <% lastChapter = hw['chapter'] %> + %else: +

    -

    + %endif
    -

    ${ hw['section'] } ${"({0}/{1})".format( hw['section_total'][0], hw['section_total'][1] )}

    - +

    + ${ hw['section'] } ${"({0}/{1})".format( hw['section_total'][0], hw['section_total'][1] )}

    + +
      % for score in hw['scores']:
    • ${ score[0] }/${ score[1] }