details:   https://code.tryton.org/tryton/commit/00f2a2cdb092
branch:    default
user:      Cédric Krier <[email protected]>
date:      Tue Feb 10 17:53:53 2026 +0100
description:
        Show email buttons of marketing record activity when the state is done

        The email is sent only when the record activity is in the state done so 
the
        buttons must not be available in any other state.

        Closes #14597
diffstat:

 modules/marketing_automation/marketing_automation.py |  4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diffs (19 lines):

diff -r 3c30bf919e36 -r 00f2a2cdb092 
modules/marketing_automation/marketing_automation.py
--- a/modules/marketing_automation/marketing_automation.py      Tue Feb 10 
12:43:51 2026 +0100
+++ b/modules/marketing_automation/marketing_automation.py      Tue Feb 10 
17:53:53 2026 +0100
@@ -910,13 +910,13 @@
                 ))
         cls._buttons.update(
             on_email_opened={
-                'invisible': ((Eval('state') != 'waiting')
+                'invisible': ((Eval('state') != 'done')
                     | (Eval('activity_action') != 'send_email')
                     | Eval('email_opened', False)),
                 'depends': ['state', 'activity_action', 'email_opened'],
                 },
             on_email_clicked={
-                'invisible': ((Eval('state') != 'waiting')
+                'invisible': ((Eval('state') != 'done')
                     | (Eval('activity_action') != 'send_email')
                     | Eval('email_clicked', False)),
                 'depends': ['state', 'activity_action', 'email_clicked'],

Reply via email to