Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <form method="GET" action="{% url 'register' activity.pk %}">
- {% csrf_token %}
- <button
- type="submit"
- class="btn btn-primary"
- id="Register">Register
- </button>
- </form>
- url(r'^(?P<pk>)', authentication_views.registerAttende, name='register'),
- def registerAttende(request,pk):
- act = Activity.objects.get(pk=pk) //This is the line that is causing the error
- act.save()
- attend = act.attendee.create(student=request.user.id)
- return render(request, 'dashboard.html')
Add Comment
Please, Sign In to add comment