Hi,
I have a custom @ people field called Contact, which may contain one or more people.
I want to populate this field with the value of the reporter or creator of the idea (when idea is created, if not filled already). Is this possible? Can someone help me with such automation? I get error when using {{issue.creator}} or {{issue.reporter}}:
Hi @Mari-Ann Eriksen ,
I believe @Gary Spross is correct, and you will need to use the "Additional fields" section (under "More options").
When searching for a custom JPD people-field within an automation (at least when mapping to this field-type when creating an idea), I cannot seem to find it. For example:
So instead I used the JSON body below to copy the idea's Reporter to the JPD people-field in my project / idea:
{
"fields": {
"customfield_XXXXX": [ { "accountId": "{{issue.reporter.accountId}}" } ]
}
}
customfield_XXXXX above would be the ID of your Contact field. Check out this page on how to find the field's ID: How to find any custom field's IDs
Also something to note: any custom JPD people-field is parsed as an array, so formatting is important! Otherwise the automation would have errors mentioning something like, "data was not an array."
The JSON body shared above should be the correct formatting needed to get this working as expected.
Here's the automation for visibility, along with a test:
Hope that helps!
Yes, and...to the suggestions from Nick and Gary:
How do you want to use the People field later in automation rules?
I recall team-managed project (TMP), People fields have limited data within rules. And JPD projects seem based upon TMP. For example, People fields cannot be used in rules to send emails: https://jira.atlassian.com/browse/AUTO-519
If you believe you need that capability, there is no workaround yet for JPD. (The workaround for TMP is to add a global, user-select field. That is not yet possible for JPD.)
Kind regards,
Bill
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks a lot, @Nick Haller and @Gary Spross, the detailed explanation was very helpful! This worked! :)
Thanks for the information @Bill Sheboy I will keep this in mind, but as of now, there is no plans to automate emails to this people field.
What I also discovered is that I had the wrong field. We used to keep the ideas in Jira before and the Contact field that I selected was actually from Jira and not JPD. That explains why it was available to select for me, and you were not able to reproduce to pick a people field @Hermance NDounga This has fooled me many times. I find it confusing that fields from Jira is appearing in the automation for JPD, when the scope is specifically set to the JDP project (and not being a global rule)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello,
Can you click the three dots don't he right to the field instead, and choose copy, select the field creator.
However, I'm going to be very honest - I thought people fields were not supported in this interface, and I am personally not able to pick a people field to reproduce your issue.
Best Regards,
Hermance
Product Manager @ Jira Product Discovery
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I think you need to set the field using the "Additional fields" section (under "More options"). Not sure of the exact syntax (and this is untested), but below is my first thought:
{
"fields":{
"customfield_10061": "{{issue.reporter}}"
}
}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.