Commits

Anonymous committed b92fdcd

modified getdelegates

  • Participants
  • Parent commits 512bfd6

Comments (0)

Files changed (1)

File web/views.py

     # Create the HttpResponse object with the appropriate CSV header.
     response = HttpResponse(mimetype='text/csv')
     response['Content-Disposition'] = 'attachment; filename=delegates.csv'
-    dels = Delegate.objects.exclude(private=True)
+    dels = Delegate.objects.all().order_by('username')
     writer = csv.writer(response)
-    writer.writerow(['Name', 'Email', 'City', 'Occupation','organisation','bio'])
+    writer.writerow(['username', 'Name', 'teesize', 'Occupation','organisation','joindate'])
     for dl in dels:
         try:
-            writer.writerow([getname(dl),dl.username.email,dl.city,
-            dl.occupation,dl.organisation,dl.bio])
+            writer.writerow([dl.username,getname(dl),dl.teesize,
+            dl.occupation,dl.organisation,dl.joindate])
         except:
             pass