> ## Documentation Index
> Fetch the complete documentation index at: https://documentation.2cloudnine.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Leave Setup and Processing - Key Information

## Prerequisites

Prior to the creation and management of Leave records, the following prerequisites must be met:

1. Users must have sufficient privileges to manage Leave Rules, Payee Leave Events, and Leave Templates and related records. See your System Administrator if you do not have the required access.
2. System-Level Leave Rules and Payee Leave Rules must be created before a Leave Event can be created for a Payee.
3. There must be active Payroll Calendars and Calendar Periods for the duration of the Start Date & End Date of the Leave Event.
4. Pay Codes must be created for all applicable Leave Types (both paid and unpaid leave).
5. Leave will only accrue on Pay Transactions if the Payment Pay Code has the checkbox of ‘Accrues Leave’ checked.
6. Employees must have their Leave Notification process (if any) and Leave Approval process in place.
7. The Effective Date of a Payee Leave Rule record must fall within a Payroll Calendar Period.
8. All the necessary Leave validations must be in place unless specified otherwise.

## Definitions

### **Payee Leave Event Record Types**

* **Leave Take**
  Used to define Leave Events where the Payee either will have, or has had, an absence from work and their leave balance will be reduced.

* **Leave Credit**
  Used to define Leave Events where the Payee’s leave balance will be increased. This includes automatic accruals for leave processed during Pay Batch processing.

* **Leave Cash Out**
  Used to define Leave Events where a Payee is taking a payment to reduce their leave balance in place of actually taking leave.

### **Payee Leave Event Processing Status’ Defined**

* **New**
  Indicates the Leave Event has had no related Calendar Periods processed through payroll.

* **Part Processed**
  Indicates the Leave Event has had one or more related Calendar Periods processed through payroll, however, there are still Pending Calendar Periods to be processed.

* **Fully Processed**
  Indicates the Leave Event has had all Calendar Periods processed through payroll.

Note: A Leave Cash Out record can only be updated from ‘New’ to ‘Fully Processed’.

### **Payee Leave Event Approval Status Defined**

* **New**
  The Leave Event is New and has not yet been Submitted for approval. Until Approved, this Leave Event will not be processed during Pay Batch processing.

* **Submitted**
  The Leave Event was Submitted awaiting approval from the Approver. Until Approved, this Leave Event will not be processed during Pay Batch processing.

* **Approved**
  The Leave Event was either auto-approved (as configured on the associated Leave Rule) or was Approved by the Leave Approver. This Leave Event can now be processed during Pay Batch processing.

* **Rejected**
  The Leave Event was Rejected by the Approver. This Leave Event will not be processed during Pay Batch processing.

* **Recalled**
  The Employee has revoked their Leave Event. This Leave Event will not be processed during Pay Batch processing.

### **Payee Leave Rule Status Defined**

* **Active**
  Indicates the current date falls after the Effective Date AND prior to the Expiry Date (if populated) of this Payee Leave Rule.

* **Inactive**
  Indicates the current date falls before the Effective Date OR after the Expiry Date (if populated) of this Payee Leave Rule.

* **Pending**
  Indicates the Payee Leave Rule’s Effective Date is greater than the Current Calendar Period’s end date.

* **On Hold**
  Indicates the Payee Leave Rule has been placed On Hold by a Payroll User, and will not be picked up during Pay Batch processing until the status is changed by a Payroll User.

### **Payee Leave Rule Processing Status Defined**

* **New**
  Indicates the Payee Leave Rule has had no Calendar Periods processed through payroll.

* **Part Processed**
  Indicates the Payee Leave Rule has had one or more Calendar Periods processed through payroll however there are still Pending Calendar Periods to be processed.

* **Fully Processed**
  Indicates the Payee Leave Rule has had all Calendar Periods processed through payroll.

## General Overviews

### **Leave Functionality**

* System Level Leave Setup
  * Set Up Leave Rules
  * Set Up Leave Rule Items
  * Set Up Leave Templates
* Payee Level Leave Setup
  * Set Up Payee Leave Rules
* Managing Payee Leave Events
  * Create Payee Leave Events - Payroll Users
    1. Leave Take
    2. Leave Credit
    3. Leave Cash Out

  * Leave Forecast

  * View Leave Balances
* Managing Leave Balances
  * Payee Leave Transfer

### **Leave Rules**

* A Leave Rule determines at an Org-wide level a type of Leave that the Employees can be entitled
  to, such as Annual Leave, Personal Leave, Time in Lieu, Compassionate Leave, etc

### **Leave Rule Items**

* The Leave Rule Items define the leave accruals for a Leave Rule.

* Leave Rule Items are created only for those Leave Rules that accrue and maintain a balance e.g.
  Annual Leave, Personal Leave, and Long Service Leave.

* All Leave Rule Items have a one-to-one relationship with a Leave Rule.

* Leave Rules however can have multiple Leave Rule Items associated with them and can be
  accessed via the Leave Rule Related List.

* The Accrual Type for Leave Rules Items can be:
  * Units per Hour Worked
  * Fixed Per Period
  * Leave Grant

### **Leave Templates**

* The Leave Template defines a set of Leave Rules which, when referenced on a Payee record, will
  automatically create the associated Leave Rules as individual Payee Leave Rules for that one Payee.

* Leave Templates are not essential, however they are used to reduce the requirement for each
  individual Payee Leave Record to be created manually by Payroll users.

### **Payee Leave Rules**

* Payee Leave Rules are set up at the Payee level referencing the Leave Rules and apply to individual
  Payees, whereas Leave Rules are set up at the Org-wide level and are only referenced on a Payee
  Leave Rule.

* At a Payee-level, they may also detail any variations specific to the Payee. This could include the
  Minimum Allowable Balance.

* Payee Leave Rules can be created individually, or in bulk via an automation using Leave Templates.

### **Payee Leave Events**

* When a Payee Leave Event record is created, it must be associated with a Payee Leave Rule and a
  Leave Rule that are already related to each other. A Payee Leave Event can be a Leave Credit, a
  Leave Take or a Leave Cash Out:

  * Leave Take: Indicates leave has been taken, therefore the hours will be reduced from
    available Payee Leave Rule balance along with payment for those hours taken
    (consideration of partial payment of hours against available leave balance will occur during
    the Pay Batch Calculation).

  * Leave Credit: Indicates the hours will be credited to the Payee Leave Rule balance without
    payment for these hours. These hours will be available to be taken via a Leave Event.

  * Leave Cash Out: Indicates no leave has been taken, however, the hours will be reduced
    from the Payee Leave Rule balance and paid as gross wages. This is only available to occur
    if the Leave Rule is configured to allow for Leave Cash Outs.

## System Process Outlines

### **Pay Codes**

* Pay Codes are applied to Pay Transactions, Leave Rules, and Leave Events processed for an
  Employee.

* Pay Codes must be created prior to the creation of Leave Rules, and all Leave Rules require a Pay
  Code as well as an Unpaid Paid Code (which can not be the same Pay Code).

* When setting up Payment Pay Codes that accrue leave, the ‘Accrues Leave’ checkbox must be
  ticked within the Pay Code record.

* The Pay Rate Multiplier field is applied to the Pay Rate on the Assignment Rate Record, to
  determine the Pay Rate to apply on the Pay Transactions.

### **Leave Rules**

* The Leave Event Controls section on the Leave Rule record contains fields that detail when the
  Leave can be taken.

* The Leave Balance Control section on the Leave Rule record contains fields that detail the ability
  for balances to go over or under particular thresholds.

* The Payroll Controls section on the Leave Rule record contains fields that detail specifics on
  payments and reporting of balances to Payees.

* If Leave Loading is payable, the Loading Pay Code must be populated within the Leave Rule.
  Similarly, if Cash Out is provided, the Cash Out Pay Code must be populated within the Leave Rule.
  To offset Leave Accrual hours each Pay Calendar Period from a Payee’s gross wage, Accrual
  Reduction Pay Code must be populated.

* The Exit Controls section on the Leave Rule record contains fields that detail when the leave is
  payable on Payee Exit.

### **Payee Leave Events**

* When a Payee Leave Event is created from the Timesheet Entry, the Timesheet and Timesheet
  Entry fields are automatically populated.

* When a Leave Take Payee Leave Event is created, the system will review if there is an existing
  Assignment Schedule and it will use the hours indicated in that as the basis for the hours for the
  Leave Event. If there is no Assignment Schedule, then the system will use the hours that have been
  entered on the Payee Leave Event which creates a Pay Transaction that reduces the hours from the
  Leave Balance.

* The Approval Details section on the Payee Leave Event automatically updates with some of the
  details such as Approval Status and Approved By. These fields can also be updated by Payroll Users.

* For a Payee to be eligible to apply for a Leave Cash Out, the related Leave Rule must meet the
  below criteria:
  * Allow Leave Cash Out must = Yes
  * Cash Out Pay Code must be populated

* For a Payee to be paid leave in advance, the below criteria must be met:
  * The Leave Event record must have Pay in Advance = Yes
  * The Leave Rule must have "Allow Pay in Advance" = Yes
  * The Leave Event must span complete Payroll Calendar Periods. Leave Events that cover part Pay Calendar Periods cannot be paid in advance. This means the number of hours paid in advance must be spread across the start and end dates of the Pay Calendar Period.

### **Manage Payee Leave Rules**

* The Payee must have a Payee Leave Rule in order to be entitled to accrue and/or take the Leave
  Rule. The Payee can not be directly entitled to the Leave Rule.

* Upon allocation of a Leave Template within the Payee record, the Payee Leave Rule records are
  automatically created based on the Leave Rules that are grouped within the allocated Leave
  Template (the related Leave Template Items).

* Some of the fields within the Payee Leave Rule record are automatically populated by the system,
  for example:

  * Calendar Period
  * Processing Status

* Some are populated based on the linked Leave Rule, for example:
  * Leave Type

* There are other fields that can be populated manually, for example:
  * Assignment

* Payee Leave Rules do not reference the Pay Code, only the Leave Rule does.

* For Leave Forecast to work, the Payee must have been processed in at least one Finalised Pay
  Batch.

* For a Payee to forecast their Leave Balance:
  * to forecast based on ‘Actual Hours’, the ‘Hours Per Period’ field in the Assignment Rate
    record must be populated if ‘Default Pay Rate’ is ‘Yes’

  * to forecast based on ‘Average Hours’, the process considers the number of hours per period
    / number of weeks to be forecasted and displays the leave balance based on the average
    hours.

Note: The value provided in the Leave Forecast is just an estimated forecast and the actual
balance can vary depending on other factors including a change to hours worked between
now and the forecast date, as well as other Leave Events taken between now and the
forecast date.

* When transferring a Leave Balance from one Payee Leave Rule to another, it is to be noted that
  there would not be any conversion of hours. Only the Leave Credit amount would be added to the
  Payee Leave Rule.

### **Pay Batch Calculation**

Points to be noted about Leave and their relationship to the Pay Batch:

* Only the Leave Accruals and Payee Leave Events that have an Entry Date within the dates of the
  Payee Pay Batch's Calendar Period will be processed .

* Adjustments to Leave Events (that are exclusive of a relationship to Timesheets) can be made at
  any stage prior to the Pay Batch being Finalised. However, any requests made post Pay Batch
  Finalisation will be processed in the next Pay Batch and only the records added during Pay Batch
  Calculation will be processed in the current Pay Batch.

* Only the Payee Leave Events that meet the below criteria are picked up for processing during the
  Pay Batch Calculation/Finalisation:

  * Record Type of Leave Take, Leave Credit or Leave Cashout.
  * Processing Status of New or Part Processed.
  * Time between the Start Date and End Date (inclusive) falls within the Pay Calendar Period of the Pay Batch.
  * Processing Status of Part Processed or Fully Processed and Void field being Yes.

* Before calculation of Payee Leave Events, a check is made to see if the Assignment of the Payee
  Leave Event with record type of Leave Takes has any related Assignment Schedule records which
  are valid for the duration of the Payee Leave Event. This ensures that Leave Events are calculated
  for the correct quantity of hours for the duration of the Leave Event. If there is no Assignment
  Schedule to refer to for the correct quantity of hours, then the hours detailed on the Leave Event
  will be used.

* Leave Accruals are calculated during the Pay Batch Calculation process, however the actual act of
  adding or deducting from a Payee’s Leave Balance happens during the Finalisation process.

* Prior to a Pay Batch being Finalised, if for any reason, a Payee Leave Event falls within the Pay
  Batch Calendar Period and is not picked up during the Pay Batch creation or calculation, they can
  be included using the ‘Bulk Add’ functionality from the Pay Batch Manager interface.

* The Payee’s Closing Leave Balance will be calculated and displayed in Payee Aggregates after the
  Pay Batch is Finalised.

### **Leave Closing Balance Calculation**

For each Pay Batch, the Leave Closing Balance is calculated as follows:
Starting Balance + Opening Balance + Accrued Leave + Credited Leaves - Leave Takes - Leave Cashouts.

Where:

* **Leave Starting Balance**
  The Leave Closing Balance brought forward from the most recently finalised prior Calendar Period.
  If the Payee has no previous Pay Batches or Opening Balances, the Starting Leave Balance will be
  ‘0’ units.

* **Leave Payee Opening Balance**
  The Leave Opening Balance carried forward from prior Payrun calculations of the Payee from any
  previous Payroll systems via Payee Opening Balance records.

* **Leave Accrued**
  Leave accrued during the Calendar Period which is calculated as specified on the related Payee
  Leave Rule/Leave Rule.

* **Leave Credited**
  Leave that was credited to the Payee during the Calendar Period (excluding leave accruals)

* **Leave Taken**
  Leave that was taken during the Calendar Period.

* **Leave Cashed Out**
  Leave that was cashed out during the Calendar Period.

## Further Information

| Document                            | Document Type     | Description                                                                                                                                                                                     |
| ----------------------------------- | ----------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Quick Reference Guide Index - Leave | Index             | An index document that lists and provides links to all Quick Reference Guides relating to Leave                                                                                                 |
| QRG Setup Leave Rules               | Task Instructions | How to set up a Leave Rule that defines when and how each type of Leave will be used and accrued at a system level. This includes creating new and editing existing Leave Rules.                |
| QRG Setup Leave Rule Items          | Task Instructions | How to set up Leave Rule Items to relate to Leave Rules for accruals.                                                                                                                           |
| QRG Setup Leave Templates           | Task Instructions | How to set up a Leave Template. This includes creating new and editing existing Leave Templates.                                                                                                |
| QRG Setup Payee Leave Rules         | Task Instructions | How to set up a Payee Specific Leave Rule (Payee Leave Rule) that defines when and how it will apply to an individual Payee. This includes creating new and editing existing Payee Leave Rules. |
