# HG changeset patch # User Madhusudan.C.S # Date 1251985050 -19800 # Node ID 272dced1685b5d3d75d6fcc24e7c101fca914788 # Parent 6af9056ccac98f90b243d0fd55e33931a12e1d40 Table to view uploads. diff -r 6af9056ccac9 -r 272dced1685b site-content/style.css --- a/site-content/style.css Thu Sep 03 18:52:01 2009 +0530 +++ b/site-content/style.css Thu Sep 03 19:07:30 2009 +0530 @@ -222,6 +222,46 @@ position: relative; left: -7%; } + +/* start - table */ +table { + border-collapse: collapse; + margin: 10px 15px; +} +th strong { + color: #fff; +} +th { + background: #8EC102; + height: 29px; + padding-left: 11px; + padding-right: 11px; + color: #fff; + text-align: left; + border-left: 1px solid #B6D59A; + border-bottom: solid 2px #FFF; +} +tr { + height: 30px; +} +td { + padding-left: 11px; + padding-right: 11px; + /* border-left: 1px solid #FFE1C3; */ + border-left: 1px solid #FFF; + border-bottom: solid 1px #ffffff; +} +td.first,th.first { + border-left: 0px; +} +tr.row-a { + background: #F8F8F8; +} +tr.row-b { + background: #EFEFEF; +} +/* end - table */ + /* Footer */ #footer { diff -r 6af9056ccac9 -r 272dced1685b template/submission.html --- a/template/submission.html Thu Sep 03 18:52:01 2009 +0530 +++ b/template/submission.html Thu Sep 03 19:07:30 2009 +0530 @@ -2,7 +2,7 @@ -OCR +Spoken Tutorials @@ -44,15 +44,15 @@ {% for participant in participants %} - {{ participant.name }} - {{ participant.email }} - {{ participant.language }} - {{ participant.phonenumber }} - {{ participant.age }} - {{ participant.category }} - {{ file }} + {{ participant.participant.name }} + {{ participant.participant.email }} + {{ participant.participant.language }} + {{ participant.participant.age }} + {{ participant.participant.phonenumber }} + {{ participant.participant.category }} + {{ participant.file_name }} - {% endfor %} + {% endfor %} {% endblock %}

diff -r 6af9056ccac9 -r 272dced1685b upload/views.py --- a/upload/views.py Thu Sep 03 18:52:01 2009 +0530 +++ b/upload/views.py Thu Sep 03 19:07:30 2009 +0530 @@ -30,8 +30,17 @@ def submission(request, template_name='submission.html'): """View to return the submitted videos """ + context_participants = [] + + participants = Participant.objects.all() + for participant in participants: + context_participants.append({ + 'participant': participant, + 'file_name': str(participant.filename).split('/')[-1], + }) + context = { - 'participants': Participant.objects.all() + 'participants': context_participants, } return render_to_response(template_name, context)