Work Entries from Time Off
Integrate time off with work entries and payroll
The Time Off in Payslips module bridges the Time Off and Work Entries modules. It automatically creates work entries when time off is approved, removes overlapping work entries, and integrates time off into payroll.
The system links time off types with work entry types, automatically regenerates entries when time off is cancelled/refused, and provides the ability to approve time off directly from the Work Entry form (Enterprise version).
Workflow
Steps
1. Employee creates time off request
2. Manager approves
3. System automatically creates time off work entry and removes overlapping work entries
4. Work entries are included in payslip
5. Salary calculated based on work entries
User groups
Permissions by group
| Group | Permissions |
|---|---|
| Regular Employee | Create time off requests, view own work entries |
| HR Officer | Approve time off, view all work entries |
| HR Manager | Full access: configure time off types, work entry types |
| Payroll Manager | View work entries for payroll calculation |
Important terminology
| Fields | Trường dữ liệu | Description |
|---|---|---|
| Time Off | Nghỉ phép | Employee leave request |
| Work Entry | Bút toán công | Record of working time or time off |
| Work Entry Type | Loại bút toán công | Classification: working, time off, etc. |
| Time Off Type | Loại nghỉ phép | Leave classification: annual, sick, unpaid, etc. |
| Leave Work Entry | Bút toán công nghỉ phép | Work entry created from time off |
Time off states
States
| State | Description |
|---|---|
| To Approve | Newly created request |
| Approved | Request accepted |
| Refused | Request rejected |
| Cancelled | Request cancelled |
Configure time off types
Each time off type needs to be linked with a work entry type for accurate salary calculation.
Steps
1. Go to Time Off → Configuration → Time Off Types
2. Open time off type to configure
3. Payroll tab → select Work Entry Type
4. Click Save
Recommended links
| Time Off Type | Work Entry Type |
|---|---|
| Annual Leave | Paid Time Off |
| Sick Leave | Sick Leave |
| Unpaid Leave | Unpaid Leave |
| Maternity Leave | Maternity Leave |
Create work entry type for time off
Steps
1. Go to Payroll → Configuration → Work Entry Types
2. Click New
3. Fill Name (e.g., Annual Leave), Code (e.g., LEAVE100), Display Code (e.g., AL)
4. Check Time Off
5. Enter Rate (e.g., 1.0 = 100%)
6. Click Save
Automatic process when approving time off
When time off is approved, the system automatically performs two actions:
Key points
• Create time off work entry: One entry per day off, work entry type from time off type configuration, duration based on work schedule
• Remove overlapping work entries: Find work entries in time off period, archive (archive) fully overlapping entries, keep partially overlapping entries
Example
Before approving time off: Monday, Tuesday, Wednesday all have work entries (8h each).
After approving time off Monday-Tuesday: Monday and Tuesday have time off work entries (8h), Wednesday keeps work entry (8h).
View work entries from time off
Key points
• Method 1: Time Off → My Time Off → Open approved request → Click Work Entries button
• Method 2: Payroll → Work Entries → Filter by Time Off (has value)
Automatic conflict resolution
The module automatically handles conflict cases between time off and work.
Conflict cases
| Case | Resolution |
|---|---|
| Time off fully overlaps work | Remove work, keep time off |
| Time off partially overlaps | Split work into two parts, keep time off in middle |
| Multiple overlapping time offs | Priority: company-wide holidays, special leave, personal leave |
Approve time off from Work Entry (Enterprise)
Enterprise version allows approving/refusing time off directly from Work Entry form.
Steps
1. Go to Payroll → Work Entries → Filter State = In Conflict
2. Open conflicting Work Entry
3. Check warning and Leave field
4. Click Approve Time Off (approve) or Refuse Time Off (refuse)
Payroll with time off
When creating payslips, system retrieves all work entries in pay period, including time off work entries. Formula: Time off salary = Hours off × Hourly rate × Rate.
Salary calculation example
| Leave type | Hours | Hourly rate | Rate | Salary |
|---|---|---|---|---|
| Annual leave | 8h | $25 | 100% | $200 |
| Sick leave | 8h | $25 | 75% | $150 |
| Unpaid leave | 8h | $25 | 0% | $0 |
Cancel and refuse time off
Can only cancel time off if work entries are not yet in payslip (state ≠ validated).
Key points
• Cancel time off: Time Off → My Time Off → Open request → Cancel → System removes time off work entry and regenerates work entry
• Refuse time off: Time Off → Time Off to Approve → Open request → Refuse → System removes time off work entry
• Cannot cancel if work entry is already In Payslip (validated)
Practical tips
Key points
• Complete linking: Ensure all time off types have work entry types
• Accurate rates: Configure correct pay rates for each leave type
• Approve before payroll: Ensure all time off approved before running payroll
• Check conflicts: View work entries after approval to ensure no conflicts
• Do not approve late: Avoid approving time off after creating payslips