I have a request for a project that will require approvals and I am trying to decide the best way to implement a certain requirement. Essentially the project will be for contract and purchase requests and the approvers will be determined by the dollar amount of the request. Basically the larger the amount the approvals will need to go hire up. I could and might use separate issue types for each but was wondering if the appovers could be set dynamically based upon the value of a numeric field. I'm thinking potentially script runner could do this.
We have implemented a similar idea using JMWE conditions. We have 3 particular statuses/transitions in our workflow, each of which is conditionally used if a particular checkbox is checked. You may could do a similar thing based upon your value.
e.g. for one particular transition, you could have a condition like
"The Numeric Field"
).value > 5000
so that if the field is > 5000, that transition is activated.
Hope that helps,
Script runner would almost certainly work. An alternative would be to use a calculated text field available with JIRA Suite Utilities plugin. It used to be free, but now looks like it's upgraded to paid for, but it does come with a lot of useful features.
Using HTML script you can use the calculated field to set a predetermined text value based on numeric , text or date values from other fields. For example;
<!-- @@Formula: if (issue.get("customfield_[x]") == null) return null;
Integer i = Integer.parseInt(issue.get("customfield_[x]"));
if (i==null) return null;
if (i>=100 && i<=500) return "[name]";
if (i>=600 && i<=1200) return "[name]";
Hello Community 👋, I'm a product manager at Atlassian, looking at improving change management capabilities across our products. In particular, we're looking at bridging the gap between Dev & ...
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