HRM Module

The HRM (Human Resources Management) module provides employee tracking, position management, and organizational structure capabilities.

Purpose

This module handles:

  • Employee record management
  • Job position definitions
  • Salary information tracking
  • Passport and identification data
  • Hire and resignation dates

Key Concepts

Employee

Central entity for HR tracking:

  • Personal info - Name, contact details
  • Salary data - Compensation information
  • Passport - Identification documents
  • Position - Job role assignment
  • Dates - Hire date, resignation date
  • PIN - Tax identification number

Position

Job role definitions:

  • Title - Position name
  • Department - Organizational unit
  • Salary range - Compensation band
  • Reports to - Management hierarchy

Architecture

graph TB
    subgraph "HRM Module Architecture"
        A[Controllers] --> B[Services]
        B --> C[Domain Layer]
        C --> D[Repositories]
        D --> E[(Database)]
        
        subgraph "Domain Aggregates"
            C --> F[Employee]
            C --> G[Position]
        end
        
        subgraph "Value Objects"
            C --> H[Passport]
            C --> I[Salary]
        end
    end
    
    subgraph "External Dependencies"
        B --> J[Core UserService]
    end

Data Flow

Employee Lifecycle

graph LR
    A[Applicant] -->|Hire| B[Active Employee]
    B -->|Promote| C[New Position]
    B -->|Resign| D[Former Employee]
    C --> B

Components

Employees

Employee management:

  • Create/edit employee records
  • Track personal information
  • Manage salary data
  • Store passport/ID documents
  • Record hire/resignation dates

Positions

Job role management:

  • Define position titles
  • Set department assignments
  • Establish reporting hierarchies
  • Manage salary ranges

Organizational Structure

Hierarchy visualization:

  • Department tree view
  • Reporting relationships
  • Position distribution
  • Headcount by department

API Reference

REST Endpoints

EndpointMethodPurpose
/hrm/employeesGETList employees
/hrm/employeesPOSTCreate employee
/hrm/employees/:idGETView employee
/hrm/employees/:idPUTUpdate employee
/hrm/positionsGETList positions
/hrm/positionsPOSTCreate position

Permissions

PermissionDescription
hrm.employees.viewView employee records
hrm.employees.createAdd employees
hrm.employees.editModify employees
hrm.employees.deleteRemove employees
hrm.positions.viewView positions
hrm.positions.manageManage positions
hrm.salary.viewView salary data
hrm.salary.manageManage salaries

Integration

Finance Module

  • Salary expense tracking
  • Payroll integration

Core Module

  • User account linking
  • Access control

Events

EventDescription
EmployeeHiredNew employee added
EmployeeUpdatedEmployee info changed
EmployeeResignedEmployee departure
PositionCreatedNew position defined

Best Practices

  1. Data privacy - Protect sensitive employee data
  2. Regular updates - Keep records current
  3. Access control - Limit salary data visibility
  4. Audit trail - Track all changes
  5. Compliance - Follow labor regulations
Last updated on