If I use the below code i am able to get the Issue Key, but i need to fetch the summary of the issue in js.
issueKey = JIRA.Issue.getIssueKey();// For Getting Issue Key
Try this, it will work
function getSummary() { var key = this.JIRA.Issue.getIssueKey(); var summary; AJS.$.ajax({ url: "/rest/api/2/issue/" + key, type: 'get', dataType: 'json', async: false, success: function(data) { summary = data.fields.summary; } }); return summary; }; getSummary();
I am sure there is an easier way, but this surely works
Happy weekend!
Not tried getSummary() yet?
Tried and not working, it not present in JIRA.Issue
I have already used this api to get the summary, but i thought there is some easy way to get it. Anyway's thanks for your reply.
It looks like you're new here. Sign in or register to get started.