Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def pageManager = ComponentLocator.getComponent(PageManager)
- def page = pageManager.getPage('OP','2019-10-09 Meeting notes')
- def text_page = page.getBodyAsString()
- def doc = Jsoup.parse(text_page)
- def element = doc.select("td")
- def result = element.collect {it.text()}
- for (int i = 0; i < result.size(); i = i + 5){
- def body = new JsonBuilder([
- fields: [
- project : [key: "QQ"],
- issuetype : [name: "Техническая консультация"],
- summary : [result[ i+1]],
- description: [result[i+2]],
- assignee : [result[i+3]],
- priority : [result[i+4]],
- customfield_11801 : [result[i+5]]
- ]
- ]).toString()
- }
- log.debug(result[1])
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement