Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Next challenges

Recent achievements

  • Global
  • Personal


  • Give kudos
  • Received
  • Given


  • Global

Trophy case

Kudos (beta program)

Kudos logo

You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.

View group

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

JEMH velocity template - get custom field value

I thought this would be simple, but a custom fields value will not display in the template. 

I've attempted:


#set( $test = $customFieldManager.getCustomFieldObject("customfield_###"))
$stringUtils.leftPad($, $padSize): $issue.getCustomFieldValue($test)


with no luck. I've reviewed but am still not able to render the custom field value. The custom field itself displays all the project roles of a project, so it's always populated.

2 answers

Hi Raynard,

For custom fields with simple string values, something like this should render:



#set($cf = $customFieldManager.getCustomFieldObject('customfield_10200'))

Please ensure that the custom field ID in your template is correct. Also, if you are using this template in an issue workflow post-function, make sure that the notification post-function is ordered to fire after re-indexing has occurred.

You can break your template down in order to debug it:

#set ($cfId = 'customfield_10200')
#set($cf = $customFieldManager.getCustomFieldObject($cfId))
#if ($cf)
Found custom field $cf.getName()
#set ($cfVal = $cf.getValue($issue))
#if ($cfVal)
It has value: $cfVal
It has no value
No custom field found for ID: $cfId

Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Marketplace Apps & Integrations

Bitbucket Smart Commits vs. Genius Commits - What's the difference?

If you already heard about Smart Commits in Bitbucket, know that you just stumbled upon something even better (and smarter!): Genius Commits by Better DevOps Automation for Jira Data Center (+ Server...

130 views 0 2
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you