Hi,
I use a Adaptavist ScriptRunner Listener to calculate a Date/Time field and its value. But it's somehow not working.
Can you spot my mistake?
def dateofDeployDate = new GregorianCalendar(2020, 10, 1, 4, 30, 0)
def days = 1
def hours = 2
def mins = 3
def tempScheduledEndDate = new GregorianCalendar()
tempScheduledEndDate = dateofDeployDate.add(Calendar.DATE, days)
tempScheduledEndDate = dateofDeployDate.add(Calendar.HOUR, hours)
tempScheduledEndDate = dateofDeployDate.add(Calendar.MINUTE, mins)
In this example I want to calculate an "End of Deployment"-Time. I do this on basis of a dateofDeployDate (2020-10-01 at 4:30:00 a.m.) and want to simply add 1 day, 2 hours and 3 minutes. So the result of tempScheduledEndDate would be 2020-10-02 at 6:33:00 a.m).
But the build in compiler of scriptrunner tells me an error that says: Cannot find matching mehtod
Thanks in Advance.