Create a Rule Template That Calculates the Threshold for Expenditure and Payroll Time Types

You want to create a time calculation rule template that calculates regular and overtime hours.

Rules created with this template should run whenever people save, submit, or resubmit time cards. And, the rules should update, or reapportion, the calculated hours, rather than create more hours. Also, you want to use hours-based PJC_EXPENDITURE_TYPE_NAME and PayrollTimeType attributes to store the calculated hours that are under and over a specific threshold.
  1. In the Time Management work area, on the Tasks panel tab, click Rule Templates.
  2. On the Rule Templates page, click the Create icon.
  3. On the Create Rule Template dialog box, complete these steps:
    1. In the Template Type field, select Time calculation rule.
    2. In the Formula Name field, select WFM_THRESHOLD_TIME_CALCULATION_RULE.
    3. Click Continue.
  4. On the Create Rule Template: Definition page, complete these steps:
    1. In the Name field, enter Threshold for Expenditure and Pay Types.
    2. In the Description field, enter Calculates hours to store for specific expenditure and payroll types using time category and threshold parameters.
    3. In the Rule Classification field, select Threshold.
    4. In the Rule Execution Type field, select Update to handle overtime by splitting the reported hours between two Payroll Time Type attribute values.
    5. In the Summation Level field, select Day.
    6. In the Time Card Events that Trigger Rule section, select Save.
    7. Click Next.
  5. On the Create Rule Template: Parameters page, complete these steps:
    1. In the DEFINED_LIMIT row, set Parameter Type to Fixed number and Display Name to Threshold.
    2. In the WORKED_TIME_CONDITION row, set Parameter Type to Time category and Display Name to Time to Consider.
    3. Click Next.
  6. On the Create Rule Template: Outputs page, complete these steps:
    1. On the Outputs toolbar, click Add four times to insert four table rows.
    2. Complete the two existing and four new outputs, as shown here. In this example, you store the calculated hours in different project and payroll attributes than those of the reported time.

      Note: After inserting the four rows, the first time that you click a field, a comprehensive message about all of the missing required values appears. Click OK to close the message and complete the fields.
      Display Sequence Output Name Output Group Time Attribute Value Type Display Name
      1 OUT_MEASURE_UNDER Output Group 1 Measure NA Under Calculated Hours
      2 EXPEND_ATTRIBUTE_UNDER Output Group 1 PJC_EXPENDITURE_TYPE_NAME Data source Under Expenditure Type
      3 PAY_ATTRIBUTE_UNDER Output Group 1 PayrollTimeType Data source Under Pay Type
      4 OUT_MEASURE_OVER Output Group 2 Measure NA Over Calculated Hours
      5 EXPEND_ATTRIBUTE_OVER Output Group 2 PJC_EXPENDITURE_TYPE_NAME Data source Over Expenditure Type
      6 PAY_ATTRIBUTE_OVER Output Group 2 PayrollTimeType Data source Over Pay Type
    3. On the Outputs section toolbar, click Reorder.
    4. On the Reorder Display Sequence dialog box, reorder the display sequence as specified in the preceding table.
    5. Click OK.
    6. On the Create Rule Templates: Outputs page, click Next.
  7. On the Create Rule Template: Explanation page, in the Explanation section, add this explanation. To insert placeholders, select the appropriate tokens from the Message Tokens drop-down list.
    Compare the total hours in the {WORKED_TIME_CONDITION} time category with the threshold of {DEFINED_LIMIT} hours. Store calculated hours under the threshold, with the {EXPEND_ATTRIBUTE_UNDER} expenditure type and the {PAY_ATTRIBUTE_UNDER} pay type. Store calculated hours over the threshold with the {EXPEND_ATTRIBUTE_OVER} expenditure type and the {PAY_ATTRIBUTE_OVER} pay type.
  8. Click Next.
  9. On the Create Rule Template: Review page, review your template settings. Make sure that the outputs display sequence is what you want.
  10. Click Save and Close.

What to do next

Create a Rule That Calculates the Daily 8h Threshold for Expenditure and Payroll Time Types and Create the Projects and Payroll Time Calculation Rule Set