脚本
import com.atlassian.jira.web.bean.PagerFilter
import com.atlassian.jira.component.ComponentAccessor
import com.atlassian.jira.bc.issue.search.SearchService
SearchService searchService = ComponentAccessor.getComponentOfType(SearchService);
def user = ComponentAccessor.jiraAuthenticationContext.getLoggedInUser();
def filter ="type = 标准任务";
SearchService.ParseResult parseResult = searchService.parseQuery(user,filter)
def results = searchService.search(user,parseResult.query,PagerFilter.unlimitedFilter)
def issues = results.results
log.info("length:"+issues.size())
issues.each { it ->
log.info(it.key)
}
Console执行结果