Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Next challenges

Recent achievements

  • Global
  • Personal

Recognition

  • Give kudos
  • Received
  • Given

Leaderboard

  • Global

Trophy case

Kudos (beta program)

Kudos logo

You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.

View group

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

What Issue Status should I see in a Post Function Script?

I assumed I would see the status Post the transition, but I am seeing the status prior to the transition.  Is this expected behavior?

2 answers

1 accepted

0 votes
Answer accepted

In a post-function, you will see the current status of the issue - the issue object has been read at the start of the transition and the status won't change until the end of the transition where the issue gets stored in the database with its new values.

So yes, that's exactly what I'd expect to happen.

Thanks Nic, looks like a need a listener instead of  a post function.

I did some more reading. Atlassian makes this statement:

Post functions carry out any additional processing required after a Jira workflow transition is executed, such as:

  • updating an issue's fields
  • adding a comment to an issue

Here: https://developer.atlassian.com/cloud/jira/software/modules/workflow-post-function/ 

I am back to figuring out why I don't see the status updates in my post function.

Because the status has not changed yet.  It only changes after the transition.  It's not a field, it is a display of where the issue is in the workflow, and during a transition, that is "in the starting status".

Like Jeff Abbott likes this

Thanks Nic, I now understand how to approach these scripts.  I was trying to write one script for all transitions for a given issue type, rather than one script per transition across issue types.

Jeff

Suggest an answer

Log in or Sign up to answer
TAGS

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you