Add current date and fixed text when transitioning an issue

Hello,

Is there a way to add current date and a fixed text to a multiline field in an issue, when the issue transitions from one state to another?

I'm currently a bit stuck. I added "Fixed text and %%CURRENT_DATETIME%%" in a multiline text as a post function to a transition, but when I transition the issue, the current date is not displayed. Its still displayed as text %%CURRENT_DATETIME%%.

Using only %%CURRENT_DATETIME%% without any text before or after it works, displaying the date, which makes things more confusing.

Any thoughts on this?

Andrei

2 answers

0 vote
Tarun Sapra Community Champion Aug 12, 2016

IN the docs it says - "If you use %%CURRENT_DATETIME%%
as the custom field value (exactly this, nothing more), the current date and time will be set as value."

But this makes no sense, cause they also say that:

 Additionally to enter text or numbers as value, you may use the following: 

  • You may use macro '%%CURRENT_USER%%' to insert the function caller.
  • You may use macro '%%CURRENT_DATETIME%%' to insert the current date and time.


By "additionally to enter text", I understand I can use text and one of those.

Tarun Sapra Community Champion Aug 12, 2016

where is it in the docs? can you share the link.

Its in the same page you sent me.

https://jsutil.atlassian.net/wiki/download/attachments/786627/JSU-UpdateIssueCustomField-ConfigurePostFunction.png?version=3&modificationDate=1392117818802&api=v2

Maybe I'm not understanding this well enough. I just want an automatic comment that says: "Fixed on 12/08/2016" to be set whenever I transition an issue.

Ignacio Pulgar Community Champion Aug 12, 2016

I'm not a native English speaker, but I think that "additionally to enter text" is quite ambiguous, as it may be interpreted also as "an additional option besides of entering text".

Based on that quote, ambiguity might be decreased (if not suppressed) by using a more appropriate phrase like:

  1. Alternatively to enter text or numbers, you may use a macro by entering just one of these exact sequences of characters as its exact value, without any additions:
  2. You may also insert dynamic phrases by intercalating any alphanumerical characters with any of the following exact sequences of characters, which will be substituted by the value returned by a macro:

Try adding two different Post Functions;

1 - Add the Date stamp

2 - Add the text using the "append" option.

or change the order as needed.

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Posted 5 hours ago in Confluence

Calling all marketing teams who use Confluence - we want to hear from you!

Hi Community! me again 🙂 If you’re a marketing team using Confluence, we want to hear your story! How did you start using Confluence? What are your use cases? What have been some of the benefits?...

29 views 1 2
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