Hello,
I need help to copy a user picker value via post function to the summary field.
I tried several snippets from here, but cant get it working. I want something like "Onboarding" + "UserPickerField"
Best regards,
Martin
Hi @Martin
Try this.
import com.atlassian.jira.component.ComponentAccessorimport com.atlassian.jira.user.ApplicationUserdef customFieldManager = ComponentAccessor.getCustomFieldManager()def cField = customFieldManager.getCustomFieldObjectsByName("User Picker Field")def cFieldValue = issue.getCustomFieldValue(cField[0]) as ApplicationUserif (cFieldValue) {issue.summary = issue.summary + ": " + cFieldValue.displayName }
I hope it helps.
Ravi
Hi @Ravi Sagar _Sparxsys_ ,
thanks for your help! I really appreciate it.
It works pretty well for my tasks which i create with post functions, but my "main task" where i put this script in a postfunction, does not rename the preset name of the summary field.
Do you have any solution for this?
As you can see in the picture, the task HR-187 didnt get a summary change.
The Post Function Order is
I tried the Script at position 2 and 4, doesnt work for the main task.
Do you have any advice for me?
Best regards
Do you need to do this for parent and subtask both? Do you have same workflow for both of them?
I create Tasks out of Tasks, because i need to show them on the Customer Portal. SubTask arent show on the Portal right?
I have a workflow for "Onboarding" - on creation 14 post functions get triggered to create other tasks after point 4 where we rename the summary with your script. this is working for the "tasks which are created out of the parenttask" but it doesnt rename the parenttask.
the "tasks which are created out of the parenttask" do have different workflows.
It looks like you're new here. Sign in or register to get started.