X-Git-Url: https://git.openstreetmap.org./osqa.git/blobdiff_plain/f32668123bbf48a0b73e90024bc09aa60e903ea0..4da66439c7e1cd073b2f97466208730cf5db9dff:/forum/views/admin.py diff --git a/forum/views/admin.py b/forum/views/admin.py index 724315f..6dffa51 100644 --- a/forum/views/admin.py +++ b/forum/views/admin.py @@ -401,6 +401,12 @@ def edit_page(request, id=None): 'published': published }) +@admin_page +def delete_page(request, id=None): + page = get_object_or_404(Page, id=id) + page.delete() + return HttpResponseRedirect(reverse('admin_static_pages')) + @admin_tools_page(_('createuser'), _("Create new user")) def create_user(request): if request.POST: