Commit 37fbed34 authored by Jean Michel Rouly's avatar Jean Michel Rouly
Browse files

asdf

parent 9470f2b4
# Create your views here.
from stepup.models import *
from django.shortcuts import render_to_response
from django.shortcuts import render_to_response, get_object_or_404
from django.core.paginator import Paginator, InvalidPage, EmptyPage
from django.core.urlresolvers import reverse
from django.contrib.auth import authenticate, login
......@@ -54,7 +54,7 @@ def index(request):
# opportunities = paginator.page(paginator.num_pages)
return render_to_response('index.html', {
# "everything" : Objects.opportunities.all(),
},
context_instance = RequestContext(request),
)
......@@ -70,7 +70,18 @@ def opportunity(request, slug):
@login_required
def person(request, slug):
return render_to_response('person.html', {
"current_user" : request.user,
"requested_user" : Person.objects.get(user__username=slug),
"requested_tags" : Person.objects.get(user__username=slug).tags.all(),
#"global_tags" : Tag.objects.all(),
"global_events" : Opportunity.objects.all(),
"sunday" : len(Person.objects.get(user__username=slug).sunday),
"monday" : len(Person.objects.get(user__username=slug).monday),
"tuesday" : len(Person.objects.get(user__username=slug).tuesday),
"wednesday" : len(Person.objects.get(user__username=slug).wednesday),
"thursday" : len(Person.objects.get(user__username=slug).thursday),
"friday" : len(Person.objects.get(user__username=slug).friday),
"saturday" : len(Person.objects.get(user__username=slug).saturday),
},
context_instance = RequestContext(request),
)
......@@ -86,7 +97,6 @@ def organization(request, slug):
@login_required
def search(request):
return render_to_response('search.html', {
},
context_instance = RequestContext(request),
)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment