Custom Field Configuration - default value not displaying correctly

I have developed a custom field, that is able to store two values (a number and a unit chosen from a selectbox). Field values are represented by a simple carrier object, that has just getters and setters for the two fields, plus some methods like toString and equals.

It seems that everything works fine, aside from displaying default values. In the field configuration screen, it only shows the String part of the carrier, not the number. I have verified by debugging that the default value chosen is stored correctly, as a number + string. When I click the Edit default value option, it shows what I put in before. However in the main configuration screen it still shows only the unit part.

I have checked my getDefaultValue method and it provides the right carrier filled with data. The program even seems to call the toString method of the carrier, and then proceeds to ignore the result of this method and only picks the String part of the carrier to display.



0 answers

Suggest an answer

Log in or Join to answer
Community showcase
Sarah Schuster
Posted Jan 29, 2018 in Jira

What are common themes you've seen across successful & failed Jira Software implementations?

Hey everyone! My name is Sarah Schuster, and I'm a Customer Success Manager in Atlassian specializing in Jira Software Cloud. Over the next few weeks I will be posting discussion topics (8 total) to ...

2,802 views 11 18
Join discussion

Atlassian User Groups

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

Find a group

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

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot