How can I reset(delete the current value) of a tranistion count/caller field? Edited

Hi

during the work on an issue I keep track on the last caller of a certain transition (e.g. approval) for audit purposes. But some days the issues is closed and archived. It is possible to "re-open" an archived isseu, modify it and start work on it from scrath. But in this case all "Transition count/caller fields" must be reseted.

I tried to do it with post functions:

- "Clear field value": does not generate any error but it does not do anything

- "Update issue custon field": generate an error.

I do not see any other simple means to achive my goal. Do you know any?

How can I fix this problem?

 

3 answers

This widget could not be displayed.

The field type you have there is read-only, calculated from the historical data on the issue.  You can't change it.

To meet your requirements, you'll need some (very simple) code.

  • Create a new field for the transistion count, selecting a standard number field.
  • Do not place this on any screens other than "view"
  • Find/write code that will add 1 to the value every time your countable transition is used
  • "Clear field value" will now work, as it's acting on a writeable field
This widget could not be displayed.

Hi,

Nick is absolutely right, calculated fields are read-only, so you must instead create a user picker custom field to hold the transition caller, and a number custom field to hold the transition count.
Then you can use the Set Field Value post-function from the JMWE add-on to set the transition caller field during the transition, and the Increase Field Value post-function from the same add-on to increase the counter.
Finally, you can use the Clear Field Value post-function to clear both fields when reopening the issue.
David

This widget could not be displayed.

Thanks guys

 

Suggest an answer

Log in or Sign up to answer
Atlassian Summit 2018

Meet the community IRL

Atlassian Summit is an excellent opportunity for in-person support, training, and networking.

Learn more
Community showcase
Published Jul 25, 2018 in Marketplace Apps

Jira Cloud and Bitbucket Cloud Integration with Microsoft Teams

One of the newest products in the Microsoft family - Microsoft Teams,  is a chat-based hub for teamwork that integrates all the people, content, and tools your team needs to be more engaged and ...

727 views 0 3
Read article

Atlassian User Groups

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

Find a group

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

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you