Change request

Abhi_007
Kilo Guru

Hi Team, 

 

A change raised under the Expedited model cannot be sent for approval when the Planned Start Date is more than 5 days from the point of requesting approval

If a user attempts to request approval on an Expedited change where the Planned Start Date is more than 5 days in the future, display the following error message:

 

Planned Start Date must be less than 5 days from now. Please select a start before [Date - 5 days from now].

If your change is required more than 5 days from now, please amend the Model to Normal.

 

 

I tried to do business rule with before but there is issue in my code , please guide for the script 

 

if(current.chg_model == 'expedited' && current.start_date > gs.daysAgoStart(5))

{

gs.addErrorMessage('Planned Start Date must be less than 5 days from now.');

}

1 ACCEPTED SOLUTION

Thanks @Brad Bowman  however we have got another solution for the same.

View solution in original post

2 REPLIES 2

Brad Bowman
Kilo Patron
Kilo Patron

Manually filtering a list view gives this for the date part, so it's worth a shot:

gs.daysAgo(-5)

 

Thanks @Brad Bowman  however we have got another solution for the same.