Transform a groovy code to painless


(Lutundula Jeanchris) #1

I wanna translate this groovy code to a painless one :

use (groovy.time.TimeCategory) {
println new Date()
println 20.days.from.now
}

I tried this :

def date = new Date()
date = date-20.days.from.now
return date

but it didn't work

Thanks


(system) #2

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.