I'd like to be able to select 1 or more metrics from a multiselect confiform dropdown and when the form creates a jira story, it should automatically add the corresponding label for each of the metrics selected to the label field in the story.
I am using "Smart Multi-select" field type in ConfiForms field.
The output from that is in [A,B,C,D] format. JIRA considers it one label rather than seperate. I want these 4 labels gets created? how to do that I used array keyword as well.
{ "fields": { "project": {"key": "SATS"}, "summary": "[entry.Summary.escapeJSON]", "description": "Issue: [entry.Issue.escapeJSON] \r\n \r\n Requester: [entry.Requestor.escapeJSON] \r\n \r\n Tech contact: [entry.Techcontact.escapeJSON] \r\n \r\n Metric(s): [entry.Metrics.LinkedMetricSep.escapeJSON] \r\n \r\n Metric Label(s): [entry.Metrics.MetricLabelSep.escapeJSON] \r\n \r\n Benefits: [entry.Benefits.escapeJSON] \r\n \r\n Workaround: [entry.Current.escapeJSON] \r\n \r\n To Be: [entry.ToBe.escapeJSON] \r\n \r\n Additional Comments: [entry.Comments.escapeJSON]", "labels": ["Dynamos"], "customfield_10153": "[entry.Summary.escapeJSON]", "duedate": "[entry.DeployDate.jiraDate]", "reporter": {"name": "[entry._user]"}, "issuetype": {"id": "5"}, } }
Hi
Is this the expression in question?
[entry.Metrics.MetricLabelSep.escapeJSON]
Alex
Yes Alex. I want to seperate the lebels. As of now it's coming in format (A,B,C,D) and its getting as one label, I tried removing seperater comma but with space also it considers one label itself.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Although, I dont know your form's configuration but I believe this is what it should be
[entry.Metrics.transform(MetricLabelSep).asArray]
Alex
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
We are getting this error Alex. Could you let us know what is wrong here?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Try
[entry.Metrics.transform(MetricLabelSep).asArray.escapeJSON]
Alex
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
No that didn't help. We tried trimAllSpaces today and it is working now.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
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.