Returns to first page when adding a post
This commit is contained in:
parent
cac9e366b7
commit
0e84244db3
1
views.py
1
views.py
|
@ -424,6 +424,7 @@ def add_post(request, blog_id):
|
||||||
form.createPost(content, request.POST['text_tags'])
|
form.createPost(content, request.POST['text_tags'])
|
||||||
s = Search()
|
s = Search()
|
||||||
s.index_post(b, form.id)
|
s.index_post(b, form.id)
|
||||||
|
request.session['cur_page'] = 0
|
||||||
return HttpResponseRedirect('/blog/' + blog_id)
|
return HttpResponseRedirect('/blog/' + blog_id)
|
||||||
else:
|
else:
|
||||||
return HttpResponseRedirect('/blog/' + blog_id)
|
return HttpResponseRedirect('/blog/' + blog_id)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user