Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,301,223
Community Members
 
Community Events
165
Community Groups

How to write a Jira Expression to the custom validator (jmweapp) to not allow the Exe attachment

Hi,

 

Need a jira expression to add a custom validator (using JMWE) app to validate that wether the given attachment by user is exe if it is exe then the user should not be able to create an issue, and if the attachment is any other type except exe then, the user should be able to create a issue,  and user should also be able to create the issue if there is no attachment attached,  how to write jira expression for this scenario

1 answer

1 accepted

1 vote
Answer accepted

Hi @Sunilkumar k 

you can create a Build-your-own Validator with this Jira expression:

!issue.attachments.length || !issue.attachments.some(it => it.filename.match("^(?i).*\.exe$"))

However, I haven't tested it when create a JSM Request from the customer portal, some validators just don't work in that specific case because of JSM limitations. 

Thanks @David Fischer _Appfire_ 

 

I tried this and it is working fine as needed.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
PERMISSIONS LEVEL
Site Admin
TAGS

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you