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

Next challenges

Recent achievements

  • Global
  • Personal

Recognition

  • Give kudos
  • Received
  • Given

Leaderboard

  • 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

How to copy 8 percent of custom field value to another custom field

Hi,

We have a requirement to copy the 8 percent of custom field value to another custom field in a workflow transition. If the value is less than 1, then round off to 1. If the value is greater than 1, take the same value. We have JSU add-on, JWT add-on and Script Runner add-on. Could you please help me .

 

Thanks in advance.

1 answer

Hi @VENKATESHWARARAO ,

if I get your use case right, you should be able to use an expression like this with JWT:

{nnnnn} * 0.08 < 1 ? 1 : {nnnnn} * 0.08

nnnnn has to be replaced with the value of your source custom field.

The behavior is: return 1 if multiplying this field with 0.08 (the 8 percent) is lower than 1 and return the result otherwise. 

Please let me know if I understood you correctly and this solves your request.

Cheers
Thorsten

P.S. You should obviously go for an update issue fields post function, selecting your target field and then using the numeric parsing mode.

Hi @Thorsten Letschert _Decadis AG_ ,

 

Thank you for the response. When I am trying to implement above expression, it's not copy the value. Just it copy the entire expression new custom field. Could you please help is there anything I want to do.

 

Thanks in advance.

Hi @VENKATESHWARARAO ,

please make sure, the 'Parsing mode' is set correctly. However, if you're saying that the whole expression is being copied, I assume that you have a text field here.

For a number field, choose Math/Time expression - for a text field, choose Parsed text (advanced mode).

community_parsing-modes.png

Cheers
Thorsten

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
VERSION
8.8.1
TAGS
Community showcase
Posted in Jira Software

Presenting the "Best of 2020" Jira Software roundup!

Catch up with Atlassian Product Managers in our 2020 Demo Den round-up! From Advanced Roadmaps to Code in Jira to Next-Gen Workflows, check out the videos below to help up-level your work in the new ...

7,193 views 8 28
Join discussion

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