I am trying to redirect to a page I intend to implement as an object\'s homepage after creation of one.
Below is corresponding part of my views.py
The function is getting one argument more than it is supposed to. Change it to:
def get(self, request, pk):
The value of pk will be equal to the pattern that has been matched, and since you've specified that it's going to be a number, the type of pk will be int.
add the kwargs into the method definition:
def get(self, request, *args, **kwargs):
return HttpResponse("Created :)")
Check that if your views.fun_name is same as the function name in views