tbl_leaveentitlment

-1 rows


Description

Module: HRMS Leave Management (Manual Adjustment Audit)
Purpose: Tracks manual leave balance adjustments and corrections performed by HR administrators.
Data: Stores audit records for manual leave additions/deductions with before/after balance snapshots.
Process Usage:
- Records manual balance corrections via HR admin interface.
- Provides audit trail for all manual leave adjustments.
- Supports balance reconciliation and dispute resolution.
Key Points:
- Captures complete context of manual adjustments including remarks and timestamps.
- Integrates with monthly leave tracking and balance rollover processes.
Business Impact: Essential for compliance, audit trails, and transparency in manual leave management operations.

Columns

Column Type Size Nulls Auto Default Children Parents Comments
lentitlmentid serial 10 nextval('tbl_leaveentitlment_lentitlmentid_seq'::regclass)

Primary key
Format: BigSerial (auto-increment)
Used as: Unique identifier for each manual adjustment transaction.

employeeid varchar 20 null
tbl_employee_previous_pf.employeeid Implied Constraint R

FK: public.tbl_employee.employeeid
Meaning: Employee whose leave balance is being manually adjusted.
Usage: Links adjustment to specific employee record.

employeename varchar 60 null
leyear int4 10 null

Calendar year for the adjustment effective period
Format: Integer (4-digit year)
Default: Current year if not specified
Usage: Determines which yearly balance period is affected.

lemonth int4 10 null

Calendar month for the adjustment effective period
Format: Integer (1-12)
Default: Current month if not specified
Usage: Links adjustment to specific monthly leave record.

entitlmentdate timestamp 29,6 null

Exact timestamp when manual adjustment was performed
Format: LocalDateTime
Default: Current timestamp at time of adjustment
Usage: Audit trail for when the manual correction occurred.

entitlmentleave numeric 0 '0'::numeric

Manual adjustment amount (positive or negative)
Format: Float
Unit: Days
Range: -999 to +999 days
Positive Values: Leave credits added to balance
Negative Values: Leave debits deducted from balance
Validation: System prevents adjustments beyond ±999 days.

lediscription varchar 200 null
entitlmentstatus varchar 10 null

Processing status of the manual adjustment
Format: String
Typical Value: “PROCESSED” for successful adjustments
Usage: Tracks workflow state - though most manual adjustments process immediately.

leavemasterid int4 10 null
leavecode varchar 50 null

Leave type name for display and reporting
Format: String
Source: From UpdateLeavesDTO.leaveCodeName
Examples: “Privilege Leave”, “Casual Leave”
Usage: Human-readable identifier for reports and audit trails.

approwperson varchar 60 null

AUDIT FIELD - System populated
Purpose: Tracks which user performed the manual adjustment
Source: Automatically populated with current logged-in user
Usage: Audit trail for responsibility and authorization tracking.

leavecodeid int8 19 null
tbl_leavecodemaster.leavecodeid Implied Constraint R

FK: public.tbl_leavecodemaster.leavecodeid
Meaning: Type of leave being adjusted (PL, CL, SL, etc.).
Usage: Determines which specific leave balance is modified.

isimported bool 1 null

Flag indicating Excel import origin of this record
Type: Boolean (default: false)
TRUE: Record created via Excel bulk import process
FALSE: Record created through manual adjustment interface
Usage: Distinguishes bulk operations from individual adjustments for reporting and auditing.

createdby varchar 50 null
createddate timestamp 29,6 null
modifiedby varchar 50 null
modifieddate timestamp 29,6 null
importedbalance numeric 0 null

Target total balance imported from Excel file
Format: Float
Unit: Days
Source: Directly from Excel column “TotalBalance”
Usage: Stores the desired final balance as specified in the import file.
Calculation Context: Represents the total balance that should exist after import processing.

existingbalance numeric 0 null

Employee’s leave balance BEFORE this manual adjustment
Format: Float
Unit: Days
Source: Queried from tbl_leavecreditdebit.totalblance
Audit Purpose: Preserves pre-adjustment state for complete transaction history.

Indexes

Constraint Name Type Sort Column(s)
tbl_leaveentitlment_pk_tbl_leaveentitlment Primary key Asc lentitlmentid

Relationships