Scriptrunner search comments by days and specific time

Olga Videc
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 11, 2019

Hello, 

Is there a way to add time function to this scriptrunner function?

issueFunction in commented('after<startDate> before <endDate>') 

I need all the issues that were commented before 8 am and after 5pm in last 30 days

BR, Olga

1 answer

0 votes
fjodors
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 11, 2019

Hello

I am able to execute such queries ((my scriptrunner version is 5.2.2)) only using date without time, so looks like it doesn't recognize time...

issueFunction in commented('after 2019-04-11')

or

issueFunction in commented('by username after 2019-04-11')

 

But I think you can write your own script (for e.g. using rest endpoint) that returns issues from specified JQL.

Then you can check and filter comments at each issue returned from this JQL.

I assume it could be performed by getComments method from CommentManager

 

See these articles for details

https://community.atlassian.com/t5/Jira-questions/Scriptrunner-JQl-condition-to-script/qaq-p/991971#M318671

https://community.atlassian.com/t5/Jira-questions/Count-Number-of-FixVersion/qaq-p/1053007#M337570

 

 

Suggest an answer

Log in or Sign up to answer