From 15c18deb0981a497b9a33ec99f6d73ab3cc1f887 Mon Sep 17 00:00:00 2001 From: Donald Buczek Date: Mon, 18 Nov 2019 14:10:52 +0100 Subject: [PATCH] Disable "submit" option from edit action menu Disable option to submit a page for moderation. --- mpicms/base/wagtail_hooks.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mpicms/base/wagtail_hooks.py b/mpicms/base/wagtail_hooks.py index 41ea1a3..0dd1963 100644 --- a/mpicms/base/wagtail_hooks.py +++ b/mpicms/base/wagtail_hooks.py @@ -58,6 +58,9 @@ def send_notifications(request, page): fail_silently=True) logger.debug(f'Send change notification to {subscribers}') +@hooks.register('construct_page_action_menu') +def remove_submit_to_moderator_option(menu_items, request, context): + menu_items[:] = [item for item in menu_items if item.name != 'action-submit'] class FeaturedImageAdmin(ModelAdmin): model = FeaturedImage