Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Update for JIRA 5 rest

  • Loading branch information...
commit 2fccb4e92937a4ac0354e954aaa986bea225a521 1 parent 10370ce
@i386 i386 authored
Showing with 8 additions and 8 deletions.
  1. +8 −8 src/scripts/jira.coffee
View
16 src/scripts/jira.coffee
@@ -69,21 +69,21 @@ module.exports = (robot) ->
issue =
key: issues.key
- summary: issues.fields.summary.value
+ summary: issues.fields.summary
assignee: ->
- if issues.fields.assignee.value != undefined
- issues.fields.assignee.value.displayName
+ if issues.fields.assignee != undefined
+ issues.fields.assignee.displayName
else
"no assignee"
- status: issues.fields.status.value.name
+ status: issues.fields.status.name
fixVersion: ->
- if issues.fields.fixVersions? and issues.fields.fixVersions.value != undefined
- issues.fields.fixVersions.value.map((fixVersion) -> return fixVersion.name).join(", ")
+ if issues.fields.fixVersions? and issues.fields.fixVersions != undefined
+ issues.fields.fixVersions.map((fixVersion) -> return fixVersion.name).join(", ")
else
"no fix version"
url: process.env.HUBOT_JIRA_URL + '/browse/' + issues.key
- cb "[#{issue.key}] #{issue.summary}. #{issue.assignee()} / #{issue.status}, #{issue.fixVersion()} <#{issue.url}>"
+ cb "#{issue.key}: #{issue.summary}. #{issue.assignee()} / #{issue.status}, Fix for: #{issue.fixVersion()} #{issue.url}"
search = (msg, jql, cb) ->
get msg, "search/?jql=#{escape(jql)}", (result) ->
@@ -147,4 +147,4 @@ module.exports = (robot) ->
msg.send "#{filter.name}: #{filter.jql}"
else
filter = filters.get msg.match[3]
- msg.send "#{filter.name}: #{filter.jql}"
+ msg.send "#{filter.name}: #{filter.jql}"
Please sign in to comment.
Something went wrong with that request. Please try again.