Hi,
It appears that the smart variables don't render when used within functions. Here is variable DayOfStay that i pass into the function plusDays, however. It renders to nothing. How to use variable within function if possible. Thank you
If DayOfStay is a custom variable created with the Variable component, then simply write on your smart value the .asNumber method:
{{issue.Check-in.plusDays(DayOfStay.asNumber)}}
Keep in mind that custom variable are treated, to my knowledge, as text. So when you try to add a text to a date, the date becomes null.
Let me know if that solved your problem!
Thank you Alex. It works by adding asNumber function at the end. Thank you for helping
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Interesting! Suggestions/thoughts:
Does the Date Of Stay field expect a certain formatting, that is, does it work if you e.g. add ".jqlDate" at the end?
Then again, it sounds very much like this weird problem: https://community.atlassian.com/t5/Jira-Software-questions/plusdays-function-not-working-when-I-pass-in-a-variable/qaq-p/1500605 ... from 2020. Is that really still a thing?? And does that workaround still do the trick, maybe? oO
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Join us to learn how your team can stay fully engaged in meetings without worrying about writing everything down. Dive into Loom's newest feature, Loom AI for meetings, which automatically takes notes and tracks action items.
Register today!Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.