The older the current issue is, the larger I want the LastUpdatedDateValue to be.
It really doesn't like def Date createdDate = getFieldById("created")
// get updated date
double LastUpdatedDateValue = 0d; // updatedDate value
def Date createdDate = getFieldById("created");
//def Timestamp createdTime = issue.getCreated();
//def Date createdDate = new Date(createdTime.getTime());
def Timestamp todayTime = new Timestamp(System.currentTimeMillis());
def Date todayDate = new Date(todayTime.getTime());
if (createdDate > todayDate - 2) {
LastUpdatedDateValue = 2d;
} else if (createdDate > todayDate - 7) {
LastUpdatedDateValue = 7d;
} else if (createdDate > todayDate - 14) {
LastUpdatedDateValue = 14d;
} else { // greater then 8
LastUpdatedDateValue = 16d;
}
What should I be using to get the create date?
Thanks.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.