Home      Ask a Question      My Stuff      Help   
  
Scripting - OTRULES Keyword
The OTRULES script allows someone to modify the default overtime rules set up by the system which is based on FLSA and is defined as overtime of 1.5 times the payrate for every hour worked after 40 hours has been worked in a weeks period.

With the "OTRULES " script you can modify the rules much like under the Accountant Menu from the "Pay Period and Overtime Rules" link. In fact all the rules can be created using the OTRULES script like "Blank", "NO", "8H", etc. Such as to do an otules for "8H" or Overtime after 40hr/week or 8hr/day it would be:

otrules = "8H";

That by itself doesn't do much and is accomplished much easier by modifying it from the "Pay Period and Overtime Rules" link. But with scripting what it can do in addition is to allow clients multiple overtime rules by adding more variables or identifiers to these rules such as by department, location, day, or even off of the hours in a pay period. We will go over examples of each here:

The simplest way to apply this script would be by using an identifier or variable found in "Employee Setup" for example a department or location. Remember before this rule will work these fields must be filled out in each employee's set up it applies to.

In the below example the script translates to "If the employee is in the 001 department his overtime rule is 8H" (Overtime after 40hr/week or 8hr/day):

if (Department = "001")
{
otrules = "8H";
}

To do it by location would be to simply change the if (Department = "001") statement to something like if (Location = "California")

To be able to apply the "otrules" based on a single day of the week or possibly multiple days of the week you would use the scripting for days in conjunction with your script like in the below example which means the overtime rules for Saturday and Sunday are "8H":

if ("SU" contains weekday (punchdate))
{
otrules = "8H";
}

More on scripting assigned by day can be found here: Scripting - Days.

To be able to apply the "otrules" based on a pay period you can use a variable to identify where the overtime applies to such as in our example below which would mean if the location is California the overtime rule will apply after 24 hours per pay period.

if (Location = "California")
{
otrules = "pp24";
}

You can also use just "otrules = "pp24";" if you want it to apply to everyone.

More information for scripting overtime can also be found here: Scripting - Overtime/Doubletime Threshold.



ID
193
Category
Training
  FAQ's
Date Created
2/1/2008 4:50:16 PM
Date Updated
10/27/2011 12:41:54 PM
Back to Search Results