Hello Community,
I'm currently building a JSM ITSM Project and creating a form for our department site contacts to submit Active Directory access requests.
Is there a way to search what has been submitted in a paragraph field and flag it if it matches certain phrases or text strings?
I want to be able to flag or highlight via Markdown (Bold/Strikethrough) certain restricted security groups, and flag others that may require additional approvals.
Is there a way to do this via automation?
Hi @Mathieu,
Welcome to Atlassian Community!
Yes, that is possible by using smart values in automation. There are multiple ways to find specific phrases, I would recommend that you take a look at the documentation for smart values as a start. For example, you could use replace to find a specific phrase and then replace it with markdown formatting, something like this:
{{issue.summary.replace("Hello","*Hello*")}}
Thank you for the response Mikael.
The Markdown gets added, but in the Agent View, the text doesn't show up being either bolded or struck through, even though it's set to Paragraph and the custom field is Rich Text.
{{issue.customfield_10171.replace("FIN_AP_SECOND_BREAKFAST","**FIN_AP_SECOND_BREAKFAST**")}}
At least this does flag it for the Agent, and from there we can train them to verify the group, so I'd deem this successful.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The markdown does not have a ** option, if you want to make the text bold/strong ty using just a single *. You can find all the text formatting notation that is supported here.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I tried a single *, single -, and some other options from the the text effects, but in the Agent View they don't display. I've used the updated replace field to add additional text to the "replaced text" to ask if it's a proper user.
ex:{{issue.customfield_10171.replace("FIN_AP_SECOND_BREAKFAST","*FIN_AP_SECOND_BREAKFAST* *HOBBIT?*")}}
I was able to chain them all together to flag multiple strings at once, incase they submit multiple restricted groups, but it required a separate Edit Issue for the field, and a "re-fetch issue data" in between each, but I've chained the Automation together to flag for 13 groups.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Okay, since it is a custom field, go to Project settings > Fields and select Actions > Edit fields. On the next screen click on your field configuration and then lookup the field. Make sure that the renderer is set to Wiki Style Renderer. Paragraph fields will by default not be set to that, and will not recognize the markdown text.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you Mikael
That was the fix,
Markdown now displays correctly in the Agent View. With this in mind I'll update a few other fields.
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.