Hi
I have a requirement as following
The user will enter a number in the custom field which is validated to enter number only while creating a ticket. Once ticket gets created I need that number to get added to the URL so that user clicks that link and it takes to the appropriate page.
Eg: In a different enterprise system, there is a numeric id for a ticket, and that numeric id is entered in Jira, I need JIRA custom field which enables users to input that number and that field data should convert into URL like http://abcdef.com/nbvj/1234 in ticket view so that user gets direct to that page when clicked.
Am new to JIRA scripting and am not sure where to add the script and what to code. I'm a beginner so any help is appreciated
This is in JIRA-Cloud
Hi @[deleted] ,
This can be solved with the inbuilt automation functions.
First you will need to create a custom field with the type "short text" and add that to the create and view screens for your issue type. Then you can use Automation to add the link part using smart values.
Create an automation with the following functions:
In my example I've named the field for the ticket key "External ticket key" and used your example link http://abcdef.com/nbvj/. Automation combines the two into the resulting link.
Please be aware of the following:
If you only need this to happen for specific issue types (or if this is in Jira Service Management, for specific request types) you can add that to the automation as conditions before the action.
Thank you so much. It worked :)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
We use the "Data Center" version of JIRA and the above does not seem to work:
The custom field type does not exist - the closest is "Text field (Single line)"
The custom field does not show on the selectable drop down list when entering the action (after the "Then:" part of the rule).
Is this function unique to the Cloud version?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Niels,
"Text field (Single line)" should work for this purpose. In our DC environment I can select all fields of this type in the "Choose fields to set" dropdown when using the Edit Issue action.
If you have just created the field, try refreshing the page. If that fails, a (background) re-index may help.
Hope that helps,
Els
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I should have added the info, sorry. I did try a - full - reindex without any improvement.
Perhaps it would be better to modify the Groovy code handling the creation of the issue. We have an integration with ServiceNow which mirrors some issues into JIRA issues.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Niels,
If the mirroring is already handled in ServiceNow it does seem easier to have the groovy code include the link, if that information is available.
In the example from the OP is seemed like the external issue ID was entered manually. But if you have an integration already it is less error prone to have the integration include all of the required information when the ticket is mirrored.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
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.