Issue title, based on a name from a field in the form that the user fills out
Asked by michael schofield:

Hey there!  

\<brand\> new to JSM, looking for some help!

I'm configuring forms that users will submit for things like employee onboarding and offboarding. And then using automation to create subtasks for things like "Create Slack Account, Create Atlassian Account, Create Domain Account"   

Somewhere along the way in the forms, i defaulted the Title to something generic like "New Hire Onboarding" -- so it would stay consistent, versus employees typing in whatever they want.  

So now whenever a new employee onboarding form is completed, the task, and all subtasks, just say "New Hire Onboarding"  

Is there a way, either as the issue is created, or with automation after, that can slip in a variable from the form into the title of the issue?  

In a perfect world, I'd love for the new employee form to be filled out with the required "First Name" and "Last Name" fields somehow slipped into the title. Something like "New Hire Onboarding $First $Last" as the issue title for the helpdesk techs would be amazing.  

Happy to share my forms, or whatever else you guys might need, to help learn me something new :)   

Thank you!!  
Mike


Answers:
author: John Funk
body: Hi Mike - Welcome to the Atlassian Community!

What is the field that you are using to currently capture the name of the new hire?

And yes, you can go ahead and create the two fields for "First Name" and "Last Name". In fact, I am going to assume you already have for the the rest of this. But one more note, you need to create two custom fields if you have not already - for First Name and Last Name (single line text fields). Then add those fields to your form.

Now, create an Automation Rule base on an Issue Created trigger.

Add any needed Condition - like Last Name is not empty.

Add an action for Re-fetch for good measure.

Then add an Action for Edit Issue. Select the Summary field - it should already be there. In the bank box type this:

{{issue.Summary}} - {{issue.First Name}} {{issue.Last Name}}

where those field names match EXACTLY as you created them.

Save and update and you are good to go.

comments: author: John Funk
body: Great to hear!


author: Ash Yadav
body: Hey [@michael schofield](/t5/user/viewprofilepage/user-id/5505537) welcome to the community :)

You'll be happy to hear that this is relatively straight-forward and it looks like you're on the right track so I'll leave this here: <https://support.atlassian.com/cloud-automation/docs/jira-smart-values-users/>

In a nutshell: You can pull data from custom fields/system fields and add them to your summary.

Let's say your "New Hire" is called John and John is being displayed as the reporter of the issue.

Your smart value for reporter would be:  
`{{reporter.displayName}}`

You can then use automation to "Edit Issue" -\> Summary -\> Modify the summary as "New Hire `{{reporter.displayName}} "`

This is just assuming you're using system fields, if you're using a custom field the process is pretty much the same so I'd suggest going through the documentation above :)

Hope this helps.

Ash


author: Joseph Chung Yin
body: [@michael schofield](/t5/user/viewprofilepage/user-id/5505537) -

Welcome to the community. The onboarding/offboarding individual - Are he/she already exist in your systems? (i.e. The person has a valid account setup against your site?)

If so, then you can use the smart value to pull the information to update the Summary line of your issue. If not, I would recommend the following steps -

Create a custom field for your site (i.e. Person's Name - Single Line of text data format), make this field context assigned to your JSM project. Afterward, update your FORM design to include a element and MAPPED it to the custom field. This means that when issue is created in the project via the FORM, the field in the issue will have that user's information.

As of right now, if a FORM's element is not mapped to an actual issue's field, then it is only available in the FORM. As far as I know - Currently you can only access the data in the form in an automation rule if you have linked the form fields to Jira fields. Atlassian is still working on enhancing APIs for Forms ithat allows you to get the data out of the form.

Hope this helps.

Best, Joseph Chung Yin


author: michael schofield
body: Thank you all so much!! Your instructions were all beautiful! We're good to go now!


Tags: cloud

jira-service-management

jira-service-management-cloud