Opened 10 years ago
Last modified 10 years ago
#11924 new defect
Erroneous text displayed in ticket action
Reported by: | Jared | Owned by: | ejucovy |
---|---|---|---|
Priority: | normal | Component: | WorkflowNotificationPlugin |
Severity: | major | Keywords: | |
Cc: | Trac Release: | 1.2 |
Description
I've implemented a workflow notification for resolution status = resolved and a condition of 'Signed'. However, I noticed when attempting to resolve a request as 'Resolved', the following text will show next to the action (see attachment).
Text displayed next to resolve action in 'ticket modify'
An email titled "Ticket 2197 has been signed" will be sent to the following recipients: monica.chavez@bayer.com, yolander.dorsey@bayer.com, jared.bownds@bayer.com.
Trac.ini configuration
[ticket-workflow-notifications] when_signed = resolve when_signed.body = Ticket $ticket.id has been signed! View it here: $link when_signed.condition = ${ticket.resolution == 'Signed'} when_signed.recipients = monica.chavez@bayer.com, yolander.dorsey@bayer.com, jared.bownds@bayer.com when_signed.subject = Ticket $ticket.id has been signed
Attachments (1)
Change History (4)
Changed 10 years ago by
Attachment: | erronous_text.png added |
---|
comment:1 follow-ups: 2 3 Changed 10 years ago by
comment:2 Changed 10 years ago by
Replying to ethan.jucovy@…:
I'll look at the trac plugin points and see if there's currently a place to hook in to change that text when the value of the dropdown changes. If not, I can at least update the hint text to include the condition, e.g. "If ticket.resolution == 'Signed', an email titled .." -- which would be clunky but at least not lying like it currently is.
Your proposed intermediate solution is a good one, the only thing to consider is how to treat multiple conditions based on the same parameter, for example:
when_signed.condition = ${ticket.resolution == 'Signed' or *
or whatever variation, I'm not incredibly familiar with all the features of the plugin, and how to best coordinate multiple conditions.
The notification itself is working correctly and only getting sent when the ticket is resolved as "Signed", right? It's just the "hint" text that's wrong?
Over all, Yes! The desired functionality has worked perfectly so far, this is a great plugin that offers a lot of flexibility and options.
comment:3 Changed 10 years ago by
Replying to ethan.jucovy@…:
I'll look at the trac plugin points and see if there's currently a place to hook in to change that text when the value of the dropdown changes.
It sounds like this ticket is a duplicate of #11498
I've spent a bit of time working in default_workflow.py
lately, and as far as I know the only way to accomplish this presently would be to change the hint using some JavaScript that is triggered when the Resolution <select>
is changed.
Oh -- hmm. The text displayed next to the action is determined when the ticket page first loads, and doesn't actually get updated based on the value of the "resolution" dropdown.
I'll look at the trac plugin points and see if there's currently a place to hook in to change that text when the value of the dropdown changes. If not, I can at least update the hint text to include the condition, e.g. "If ticket.resolution == 'Signed', an email titled .." -- which would be clunky but at least not lying like it currently is.
The notification itself is working correctly and only getting sent when the ticket is resolved as "Signed", right? It's just the "hint" text that's wrong?