From faa57ce0afd21fbb60cfd7cdee0ed3b8e9a578eb Mon Sep 17 00:00:00 2001 From: jacobtoppm Date: Tue, 28 Jul 2020 17:17:56 +0100 Subject: [PATCH] Remove 'and publish' from final workflow step approve button if using a nonlinear workflow mode where approval might not actually publish the page --- wagtail/admin/action_menu.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wagtail/admin/action_menu.py b/wagtail/admin/action_menu.py index c391c5720c..7b3b453145 100644 --- a/wagtail/admin/action_menu.py +++ b/wagtail/admin/action_menu.py @@ -314,7 +314,7 @@ class PageActionMenu: for name, label, launch_modal in actions: icon_name = 'edit' if name == "approve": - if is_final_task: + if is_final_task and not getattr(settings, 'WAGTAIL_WORKFLOW_REQUIRE_REAPPROVAL_ON_EDIT', False): label = _("%(label)s and Publish") % {'label': label} icon_name = 'success'