create a document code based on issue type

Francesco Mazza November 14, 2017

I need to create a document code in a customfield (document_code) that autoincreases based on the issue type. for example
I insert the first record with issuetype = bug -> document_code = bug-001
I insert the second record with issuetype = change request -> document_code = CR-001
I insert the third record with issuetype = bug --> document_code = bug-002
I insert the fourth record with issuetype = New Request -> document_code = NR-001

I insert the fourth record with issuetype = Change Request -> document_code = NR-002
and so on
Any suggestions?

1 answer

0 votes
Aron Gombas _Midori_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
November 14, 2017

I would implement a sequence per issue type and then a scripted custom field. The sequence value could be stored via ActiveObjects in the JIRA database.

You could do this with the ScriptRunner app.

Francesco Mazza November 17, 2017

I think I'll do it manually. Script Runner has a cash cost
Thank you for your suggestion

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events