To find the link type id, go to Administration > System > Issue Linking. Here you will see your Jira instance's link types. Each will have an "Edit" and "Delete" operation hyperlink. Mouse over these hyperlinks and you will see the link type id at the end of the URL.
For example https://yourserver/secure/admin/EditLinkType!default.jspa?id=10020
The id=10020 indicates the link type id is 10020.
You need to pass in:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I got the point for SourceIssue ID, Destination Issue ID, User. but id of the type of link is what i am stuck, so can you elaborate on it?
My code seems like this.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Sorry nic, code didint get attached. okay that value i got it from database.
Here is my code:
def public TransitionStatus(MutableIssue issue)
{
def cfopts = issue.getCustomFieldValue(customField_name)
def MutableIssue opt = issueManager.getIssueObject(cfopts)
log.warn("get OPT name: " + opt.key)
def currentUser = jiraAuthenticationContext.getUser();
Collection<ActionDescriptor> actions1 = issueWorkflowManager.getAvailableActions(issue);
log.warn("Action for Candidate Tickets are: " + actions1)
log.warn("Open Position :" + opt.dump())
log.warn("Open Position Class : " + opt.getClass())
log.warn("Current Status for open position" + opt.getStatusObject())
def jiraworkflow = workflowManager.getWorkflow((Issue)opt) as JiraWorkflow;
def transitions = jiraworkflow.getAllActions()
def status=jiraworkflow.getLinkedStatusObjects()
WorkflowTransitionUtil workflowTransitionUtil = ( WorkflowTransitionUtil ) JiraUtils.loadComponent( WorkflowTransitionUtilImpl.class ); //This will capture the Wokflow
workflowTransitionUtil.setIssue(issue); //This will set the Issue
workflowTransitionUtil.setAction(221);//This will set the Action Id to Make an Offer Transition
workflowTransitionUtil.progress(); //This will vallidate the progress
log.warn("I have set the Status Transition have performed from Second Round to Make an Offer!!")
WorkflowTransitionUtil workflowTransitionUtil1 = ( WorkflowTransitionUtil ) JiraUtils.loadComponent( WorkflowTransitionUtilImpl.class );
workflowTransitionUtil.setIssue(opt); //This will set the Issue
workflowTransitionUtil.setAction(11); //This will set the Action Id Candidate Joined Transition
workflowTransitionUtil.progress(); //This will vallidate the progress
log.warn("I have set the Status Transition have performed from Pending to Candidate Joined for OPen Position !!")
}
TransitionStatus(issue)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I can't see any code there, but I can try to explain the link type id.
If you, as an administrator, go into "issue linking" in the web interface, you'll see a list of link *types*. For example "related", "cloned", "dependent on" and so-on. You need to pass in the ID of the link type you wish to use.
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.