Home      Ask a Question      My Stuff      Help   
  
Scripting - Excluding Certain Days from Calculating Towards Overtime
Question
ID
283
Category
Training
  FAQ's
Date Created
7/18/2008 12:32:55 PM
Date Updated
9/7/2011 9:48:58 AM
How do I exclude Overtime for working on certain days like weekends (Saturday and Sunday)?
Answer
To do this we would use a script that would trigger only if it was either Saturday or Sunday by using Scripting - Days. Then we would use a new category for exmaple "Weekend OT Exempt" in our script for the punches on these days to be assigned. Because it is a different category then what the system defaulted to it will not promote this category towards overtime. Below is an example of the script:

if ("SU" contains weekday (punchdate))
{
category = "Weekend OT Exempt";
}

This reads as:

If it is either Saturday, or Sunday, assign it the category of "Weekend OT Exempt".

Since this is not a category the system knows to promote to overtime like for example the category of "Regular" it will not include these categorized hours towards calculating overtime.
Back to Search Results