I am fairly new to Scriptrunner and is someone who is not from a development background. Anyway, I had been looking for ways to make the release date visible along with the fix versions. So, created a scripted field (Date picker) and added the script for the same and it works fine. My question now is, what is the next step for making this field visible in the issue page along with the Fix version. How should we do that. Dos simply adding the field to the screens work ? I am actually clueless. Kindly help. Thanks
Add it to the view screen, like any other custom field. It will only appear in view. as a scripted field.
Hi Aisha,
Now that you have created your field you have to add it at least to your issue 'Veiw' screen.
1) Go to your Project Settings -> Screens and check which screen is associated with the 'View' operation
2) Go to Administration -> Issues -> Custom Fields, find your field in the list of fields and click on the 'gear' icon to the right of it to open a context menu. Click on 'Screens' in that menu to bring up a list of screens to add this field to. Check the screens you need and click 'Update' at the bottom.
You can find more details about screens in this documentation.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Aisha,
Could you please share the script here ?
i want to use Version Release date on issue.
Regards,
Sandeep
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @sandeepsai
Template - Date Time picker
Inline script -
import com.atlassian.jira.issue.IssueManager
import com.atlassian.jira.component.ComponentAccessor
import com.atlassian.jira.bc.issue.IssueService
import java.lang.Exception
import com.atlassian.jira.issue.Issue
import com.atlassian.jira.issue.MutableIssue
import com.atlassian.jira.project.version.Version
import java.text.SimpleDateFormat
import java.sql.Timestamp
import java.text.DateFormat
import java.util.Date
Collection versions = issue.getFixVersions()
if (versions==null || versions.size()!=1)
return null
def version = versions.iterator().next()
new Date(version.releaseDate.time)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
$dateFormatterWithoutTime.format($value) this is showing in result no success
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Sandeep, check what Search Template you've used for the custom field. Should be Date Time Range Picker. Configuration is made from Jira Administration -> Issues -> Custom Fields -> search for your field -> Edit.
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.