when use done transition in bug then automatically display link issue field and mandatory only for select duplicate value in resolution drop down list.
Hi @koteswararao puralasetty,
You'll have to place transition screen in Done transition of Bug's workflow with linked issue and Resolution field
And to make Linked issue field as mandatory when resolution is Duplicate, I would go with scriptrunner's validator with script below
import com.atlassian.jira.component.ComponentAccessorimport com.atlassian.jira.issue.IssueFieldConstantsimport com.atlassian.jira.issue.fields.IssueLinksSystemFieldimport com.opensymphony.workflow.InvalidInputExceptionimport webwork.action.ActionContextimport com.atlassian.jira.issue.MutableIssue;import com.atlassian.jira.issue.link.IssueLinkdef fieldManager = ComponentAccessor.getFieldManager()def linksSystemField = fieldManager.getField("issuelinks") as IssueLinksSystemFielddef customFieldManager = ComponentAccessor.getCustomFieldManager()def request = ActionContext.getRequest()if(issue.resolution.name =="Duplicate") {if (request) {def params = request.getParameterMap()def issueLinkingValue = linksSystemField.getRelevantParams(params) as IssueLinksSystemField.IssueLinkingValueif (! (issueLinkingValue.linkDescription == "duplicates" && issueLinkingValue.linkedIssues.size())) {throw new InvalidInputException(IssueFieldConstants.ISSUE_LINKS,"Note: You must use link type 'duplicates'.")}
Note: it won't place * symbol but it won't allow you to proceed further when resolution is Done and linked issue field is empty and even the link type is different. you can modify the condition according to your requirement
Hope this helps
BR,
Leo
It looks like you're new here. Sign in or register to get started.