I have a workflow transition which requires the assignee to set a value for a required custom field. The custom field is listed on the screen used for the transition, and it's also on the issue edit/view screens. There is a validator on the transition which requires the field to be updated by the user. There is a post-function on the same transition which sends a custom email to multiple recipients, and includes this field in the body.
When the user triggers this transition, they are presented with the correct screen, and they provide a value in the custom field. The issue transitions properly, and the email is delivered correctly. In the email body, the custom field value is shown exactly how the user entered it. BUT the issue does not show the new value set for that field.
I have double-checked, and the custom field is present in both the edit and view screens for the issue type. When I use the Admin > Where's My Field? helper, it says that the custom field still has no value, so it won't show up on the screen. But that can't be correct, because the user DID enter a value (it was required), and the email that was deliver DOES show the field value.
So...why would the field not be updating after the transition has completed? It's doing everything else correctly, but then acting as if the field was never updated. No errors at all.
More details:
The post-function that delivers the email also has a condition so that it won't send unless that specific custom field is not null. The email delivers perfectly, which means that the field is not null.
Also, looking through the History tab at the bottom of the issue, other field changes are recorded, but that one shows no change.
Why would the field value be ok during the transition, but then be emptied after it's completed?
Update 1:
The transition also included a post-function which created a sub-task before sending the follow-up email. When I disabled the subtask post-function, everything worked as expected; The email delivers correctly, AND the field is changed/visible on the issue screen as desired.
Therefore, something about the subtask creation is interfering with the field being updated properly. I just don't know what needs to be changed. The subtask creation is the very first post-function listed. Perhaps I need to move it to a later position in the transition?
Update 2:
I re-ordered things so that the sub-task creation was after everything else, and this solved the problem. I'm not exactly sure why this made the difference, but it appears to all be good now.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.