Part 7 — Leave Management

Part 7 — Leave Management

22. Leave Types

What it is

Each kind of leave your company offers (Casual, Sick, Earned, Maternity…) is a leave type with its own rules: how many days per year, paid or unpaid, can it be carried forward, and so on.

The system comes with these types ready (you can edit them): Code Name Paid Yearly quota Accrual
CL Casual Leave Yes 12 Yearly
SL Sick Leave Yes 12 Yearly
EL Earned Leave Yes 15 Monthly
LOP Loss of Pay No 0 None
ML Maternity Leave Yes 182 None (credit manually when needed)
CO Comp Off Yes 0 None (granted as comp-off)

How to create or edit a leave type

Sidebar → Leave → Types → Add (or ✏ to edit):

Field Meaning Example (Earned Leave)
Code Short unique code (capitals). EL
Name Full name. Earned Leave
Annual quota (days) Days per leave year. 15
Accrual How the quota is given: None (manual / comp-off), Monthly (quota ÷ 12 each month), Quarterly (quota ÷ 4 each quarter), Yearly (full quota at year start), Once on joining. Monthly
Carry forward max Max unused days moved to next year. 30
Encash max at year end Max unused days paid as money at year end. 10
Max consecutive days Longest single leave allowed. Blank = no limit. blank
Min service (days) Days employee must have worked before using this leave. 90
Applicable to All employees / Female only / Male only. All
☑ Paid leave Paid (no salary cut) or unpaid (salary cut = LOP). ✔
☑ Allow half day Employees can apply for half days. ✔
☑ Pro-rate quota for mid-year joiners New joiners get a reduced quota. ✔
☐ Encash unused balance at year end Turn on encashment (uses Encash max). ✔
☐ Sandwich rule Week-offs/holidays between leave days are counted as leave. ☐
☐ Requires attachment Employee must upload a document (e.g. medical certificate). ☐
☐ Allow negative balance Can take leave beyond balance. ☐
☑ Active Available to employees. ✔
Type Quota Accrual Carry max Encash Other rules
CL Casual 8 Yearly, pro-rate ✔ 0 (lapses) No Half day ✔, Max consecutive 3
SL Sick 7 Yearly, pro-rate ✔ 7 No Half day ✔, Requires attachment ✔
EL Earned 15 Monthly (1.25/month) 30 Yes, max 10 Min service 90 days
ML Maternity 182 None — credit 182 days with Adjust when an employee needs it 0 No Female only, Min service 80 days
CO Comp Off 0 None 0 No Granted manually
LOP Loss of Pay 0 None — — Paid unticked

What to expect

  • If you delete a leave type that has been used, it is made inactive instead (history is kept).
  • Changing a type's rules affects future requests; already-approved leave stays as it is.

Common mistakes

Mistake Effect Fix
LOP type left as "Paid" Unpaid leave gets paid. Untick Paid leave for LOP.
"Once on joining" type created when staff already exist Every existing active employee (of the allowed gender) gets the full quota once. Use "Yearly" or "Monthly" for normal leave. For maternity, keep accrual None and credit days with Leave → Balances → Adjust when needed.

23. Leave accrual (how balances grow)

What it is

Accrual adds leave to balances automatically based on each type's Accrual setting.

Accrual How it works Example (quota 12)
Yearly Full quota on the first day of the leave year. 12 days on 1 January
Monthly Quota ÷ 12 every month. 1 day each month
Quarterly Quota ÷ 4 every quarter. 3 days each in Jan, Apr, Jul, Oct
Once on joining Full quota once, ever. 12 days once
None Nothing automatic; admin adds manually. —

Mid-year joiners (pro-rate)

When Pro-rate quota for mid-year joiners is ticked:

  • An employee who joins on or before the 15th gets that month counted; after the 15th, counting starts next month.
  • Yearly: quota × remaining months ÷ 12, rounded to the nearest half day.
  • Monthly: months before the joining month are skipped.
Examples (leave year Jan–Dec): Joined CL (Yearly, 12) EL (Monthly, 15 = 1.25/month), as of December
10 March Counting from March → 10 months → 10 days Mar–Dec = 10 months → 12.5 days
20 March Counting from April → 9 months → 9 days Apr–Dec = 9 months → 11.25 days
10 July Jul–Dec = 6 months → 6 days 6 months → 7.5 days

How accrual runs

  • Automatically every day via the leave_accrual automatic job (see section 45).
  • Manually: Leave → Requests → Run Accrual Now → "N accrual credit(s) posted".

Running accrual many times is safe — each credit is added only once. Missed months in the current year are filled in automatically.

Common mistakes

  • Expecting accrual for the previous year → accrual only fills the current leave year. For past years, enter balances manually (section 26).

24. Applying for leave (employee)

How an employee applies

  1. Portal → Apply Leave.
  2. Choose Leave type (paid types show the current balance, e.g. "Casual Leave — balance 5").
  3. Pick From and To dates.
  4. For half days, choose From session / To session: Full day, First half only, Second half only.
  5. Attach a Supporting document (PDF or image, up to 5 MB) if required.
  6. Write a Reason (optional but recommended).
  7. Check the live preview: "2 day(s) will be deducted (current balance 5)".
  8. Click Submit Request → "Leave request submitted (2 day(s))".

How days are counted

  • Week-offs and holidays inside the dates are not counted (unless the sandwich rule applies).
  • A half-day session counts as 0.5.
Examples (employee works Mon–Fri): Request Without sandwich With sandwich
Fri → Mon 2 days (Sat, Sun skipped) 4 days (Sat, Sun sandwiched)
Sat → Mon 1 day 1 day (Sat/Sun not between two leave days)
Wed (first half only) 0.5 day 0.5 day
Mon (second half) → Wed (full) 2.5 days 2.5 days

Validation — messages the employee may see

Message Meaning
"Insufficient Casual Leave balance (available 1)" Not enough balance (pending requests are also counted).
"Overlaps an existing leave request (…)" Already applied for those dates.
"Maternity Leave is only for female employees" Gender restriction.
"Earned Leave needs 90 days of service" Minimum service not completed.
"Half-day is not allowed for …" The type doesn't allow half days.
"Attach a supporting document for Sick Leave" Attachment required.
"Selected dates are all week-offs or holidays" Nothing to deduct.
"Casual Leave allows at most 3 consecutive days" Longer than allowed.
"Attendance is already recorded on 2027-01-12; apply a half day instead" Employee already checked in that day; only half day is possible.

Scenarios

Situation What to do
Sick in the morning, comes to work after lunch Apply SL for that day, First half only. Check in after lunch — late check-in is allowed on a half-day leave day.
Leave in advance for a wedding (Fri to next Wed) Apply EL Fri → Wed. Preview shows 4 days (Sat/Sun skipped).
No balance left but needs leave Apply LOP (unpaid). The days become loss of pay in salary.

My Requests and cancellation

Portal → My Requests shows every request with status (Pending, Approved, Rejected, Cancelled) and HR's remarks. Employees can Cancel:

  • Any pending request, or
  • An approved request whose start date is in the future.

25. Approving, rejecting and cancelling leave (admin)

How to review

  1. Sidebar → Leave → Requests (filter: Pending by default). The dashboard also shows "N leave request(s) pending approval."
  2. Each row shows Employee, Type, From/To (with half-day marks), Days, Balance (a yellow row with "insufficient" means the balance is too low), Reason, Attachment, Status.
  3. Click Approve or Reject → optional remarks → OK.

What happens on approval

  • Attendance for those dates is filled automatically: full days as Leave, half days as Half Day (linked to the leave type).
  • The balance is reduced.
  • In payroll: paid leave days are paid; unpaid leave days become LOP.
  • The employee cannot check in on full-day leave dates.

Admin cancellation

For an approved request, click Cancel → remarks → "Leave cancelled and balance restored". Attendance rows are reversed (days where the employee actually punched are recalculated from the punches).

Scenarios

Situation Result
Approving when balance became insufficient (another leave was approved meanwhile) "Employee no longer has enough balance for this leave". Ask the employee to change the type to LOP, or adjust the balance.
Cancelling leave for a month whose payroll is finalized "Payroll for these dates is finalized; revert the payroll run first". Revert payroll → cancel → regenerate → finalize.
Employee came to work during approved leave Cancel the leave (or the specific days via a new request), then correct attendance.

26. Leave balances and adjustments

What it is

Leave → Balances shows every active employee's balance for each leave type for a selected leave year.

Entering opening balances when you start using OfficeHRMS

Sunrise Retail starts using OfficeHRMS in July. Ravi already has 6 EL and 3 CL left from his old records.

  1. Leave → Balances → select the current year.
  2. Click Adjust on Ravi's row.
  3. Leave type EL, Entry Opening balance, Days 6, Remarks "Opening balance from old system" → Save.
  4. Repeat for CL with 3.

Other adjustments

Situation Entry
Correct a wrong balance Adjustment, + or − days (e.g. −1).
Give 2 extra days as a reward Adjustment, +2, remarks "Diwali bonus leave".

What employees see

Portal → Leave Balances shows the current-year balance of every leave type. Payslips can also show balances (Company Settings → Payslip → Show leave balances).


27. Compensatory Off (Comp-off)

What it is

When an employee works on a holiday or their week-off, you can give them a day (or half day) of Comp Off (CO) leave to use later.

How to grant

  1. Leave → Requests → Grant Comp-off.
  2. Choose Employee, Date worked (must be a holiday or week-off for that employee), Days to credit (1 or 0.5), Remarks.
  3. Grant → "Comp-off credited". The employee's CO balance increases. They apply for it like any other leave.

Example

Store staff Sameer works on Independence Day (holiday) during a sale. Priya grants him 1 day CO for 15-08-2027. In September he applies for CO on a weekday.

Rules and messages

Situation Message
Date is a normal working day for the employee "2027-08-16 is a scheduled working day for this employee"
Already granted for that date "Comp-off already granted for 2027-08-15"
CO leave type missing "Comp Off leave type (code CO) is missing" — create a type with code CO.

Note: The system does not check whether the employee actually punched on that date — verify in the Attendance Log before granting.


28. Leave Year-End (carry forward, encash, lapse)

What it is

At the end of each leave year, unused paid leave is handled in three ways, according to each type's rules:

  1. Carry forward — moved to next year (up to Carry forward max).
  2. Encash — paid as money in the next payroll (up to Encash max, if encashment is on).
  3. Lapse — the rest is lost.

How to run it

  1. Sidebar → Leave → Year-End.
  2. Choose the Leave year that has ended (the current year cannot be closed until it ends).
  3. Review the policy table and the preview: each employee's balance and how much will be carried, encashed and lapsed.
  4. Click Close leave year 2026 → confirm → "Closed 2026: 38 employee(s), carried 410.0, encashed 95.0, lapsed 120.0 day(s)".

It can also run automatically on the first day of the new leave year (the leave_year_end job).

Worked example

Leave year 2026 ends. Ravi has EL 42 days and CL 5 days left. EL: carry max 30, encash max 10. CL: carry max 0, no encashment.

Type Balance Carried to 2027 Encashed Lapsed
EL 42 30 10 2
CL 5 0 0 5

Ravi is a monthly employee with CTC ₹26,000 and Sunday off. January 2027 has 26 working days for him, so his January payslip shows an extra earning: Leave Encashment (10 days) = 26,000 ÷ 26 × 10 = ₹10,000. It is included in taxable income. (The per-day rate follows your Salary day basis setting; daily-wage staff are paid at their daily rate.)

What to expect

  • Running it twice is safe — already-closed balances are skipped ("N balance(s) in 2026 are already closed").
  • Only paid types with a positive balance are processed.
  • Encashment is paid in the next payroll that is generated for the employee. If that payroll run is deleted or regenerated, the encashment goes back to pending and is paid again in the regenerated run.

Common mistakes

Mistake Fix
Running year-end before entering all approved leave of the year Approve/enter all leave first, then close the year.
Expecting carried leave before closing the year Carried leave appears in the new year only after year-end is run.