Changeset 246:161ebb111e47
- Timestamp:
- 23.02.2010 13:19:41 (2 years ago)
- Branch:
- default
- File:
-
- 1 edited
-
djangobb/djangobb_forum/views.py (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
djangobb/djangobb_forum/views.py
r245 r246 80 80 topics = forum.topics.order_by('-sticky', '-updated').select_related() 81 81 if request.user.is_superuser or request.user in forum.moderators.all(): 82 topic_ids = request.POST.getlist('topic_id') 82 83 if 'move_topics' in request.POST: 83 topic_ids = request.POST.getlist('topic_id')84 84 return { 85 85 'categories': Category.objects.all(), … … 89 89 } 90 90 elif 'delete_topics' in request.POST: 91 for topic_id in topic_ list:91 for topic_id in topic_ids: 92 92 topic = get_object_or_404(Topic, pk=topic_id) 93 93 topic.delete() 94 94 return HttpResponseRedirect(reverse('djangobb:index')) 95 95 elif 'open_topics' in request.POST: 96 for topic_id in topic_ list:96 for topic_id in topic_ids: 97 97 open_close_topic(request, topic_id) 98 98 return HttpResponseRedirect(reverse('djangobb:index')) 99 99 elif 'close_topics' in request.POST: 100 for topic_id in topic_ list:100 for topic_id in topic_ids: 101 101 open_close_topic(request, topic_id) 102 102 return HttpResponseRedirect(reverse('djangobb:index'))
Note: See TracChangeset
for help on using the changeset viewer.
