Exclude Employees With Less Than 90 Days from Holiday Hours - TWP

The following script can be used in TimeWorksPlus to limit Holiday hours to employees that have completed a probationary period, i.e. 90 days of service. It requires the following items to already be configured on the account:
  • Designated holidays through the USHolidays or Holiday Configuration rule
  • Employees must have a Start Date in Employee Setup
  • A holiday rule configured to add Holiday hours to the time card*
The logic here is that after all employees have been given Holiday hours through the Holiday Rule, the script checks to see if the employee has been with the company for less than 90 days. If that is true, the hours will be changed to 0.

It goes in the PayRate Script box.

if(reportingdate.isholiday and ishours and category = "Holiday" and employee.daysofservice < 90){
hours = 0;}


*Holiday hours can be added to a time card in one of two ways. You can use the TimeWorks Plus: Holiday Rule to add hours when the employee does not work on the holiday or, you can use the Holiday Configuration which not only designates the account holidays but also can add the holiday hours.
 

Did you find this article helpful?