Hi there!
How to get parent issue id in javascript function on Create Sub-Task dialog?
Here is a sample of that javascript:
AJS.$(document).ready(function () { console.log("GLOBAL_CONTEXT"); JIRA.bind(JIRA.Events.NEW_CONTENT_ADDED, function (e,context) { setTimeout(function() {getParentIssueId();}, 50); }); }); function getParentIssueId(){ // I can't get parent issue id here as I can issueType var issueType = AJS.$('#issuetype').text(); console.log(issueType); }
Community moderators have prevented the ability to post new answers.
Hello,
From the pop up screen you can get the issue ID from the title on the page which contains the parent ID.
AJS.$('title').text()
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.