The Atlassian Community can help you and your team get more value out of Atlassian products and practices.
How to change the format of my Date Picker Custom field in my Email post-function please ?
I am using this in the Email template :
<% out << issue.getCustomFieldValue(com.atlassian.jira.component.ComponentAccessor.getCustomFieldManager().getCustomFieldObjectByName("DatePickerCustomFieldName")) %>
And I am getting this :
2018-04-23 00:00:00.0
I'd like to get :
23-04-2018
Thank you for your help !
Hi,
You could try:
issue.getCustomFieldValue(com.atlassian.jira.component.ComponentAccessor.getCustomFieldManager().getCustomFieldObjectByName("DatePickerCustomFieldName")).format("dd-MM-yyyy")
It's working fine for me, maybe it works for you too.
Regards,
Marcos
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I get:
No signature of method: com.atlassian.jira.issue.fields.ImmutableCustomField.format() is applicable for argument types: (java.lang.String) values: [dd-mm-yyyy]
def subTaskCustomField17127 = com.atlassian.jira.component.ComponentAccessor.getCustomFieldManager().getCustomFieldObject("customfield_17127")
def customFieldValue17127 = issue.getCustomFieldValue(subTaskCustomField17127.format("dd-mm-yyyy"))
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello everyone! We are very excited to announce some much needed changes to the issue create experience in JSM (the blue "create" button) at the top of the screen. We have just starte...
Connect with like-minded Atlassian users at free events near you!
Find an eventConnect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.
Host an eventYou're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.