Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
74 changes: 74 additions & 0 deletions packages/hr/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
# @hotcrm/hr - Human Capital Management Module

## Overview

The HR/HCM module provides comprehensive human capital management functionality for HotCRM, enabling customers to manage the entire employee lifecycle from recruitment to retirement.

## Features

### ๐Ÿ“Š Organizational Structure
- Employee master data management
- Position and job role definitions
- Department hierarchy and org charts

### ๐ŸŽฏ Talent Acquisition
- Recruitment pipeline management
- Candidate tracking
- Application processing
- Interview scheduling
- Offer management
- Employee onboarding

### ๐Ÿ“ˆ Performance Management
- Performance reviews
- Goal setting and OKRs
- Performance tracking

### ๐ŸŽ“ Learning & Development
- Training programs
- Professional certifications
- Skill development tracking

### ๐Ÿ“… Time & Attendance
- Leave/time-off management
- Attendance tracking
- Working hours monitoring

### ๐Ÿ’ฐ Compensation Management
- Payroll tracking
- Compensation history

## Objects

- **employee** - Employee master data
- **position** - Job positions and org chart
- **department** - Organizational units
- **recruitment** - Hiring pipeline
- **candidate** - Job applicants
- **application** - Job applications
- **interview** - Interview scheduling
- **offer** - Job offers
- **onboarding** - Employee onboarding
- **performance_review** - Performance management
- **goal** - OKRs and goals
- **training** - Learning & development
- **certification** - Professional certifications
- **time_off** - Leave management
- **attendance** - Time tracking
- **payroll** - Compensation tracking

## AI Enhancements

- Resume parsing and candidate matching
- Interview question generation
- Performance prediction
- Skill gap analysis
- Succession planning recommendations

## Usage

```typescript
import { HRPlugin } from '@hotcrm/hr';

// The plugin will be automatically registered with the ObjectStack runtime
```
33 changes: 33 additions & 0 deletions packages/hr/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
{
"name": "@hotcrm/hr",
"version": "1.0.0",
"description": "Human Capital Management module - Employee lifecycle, recruitment, performance, and payroll",
"main": "dist/index.js",
"types": "dist/index.d.ts",
"scripts": {
"build": "tsc",
"dev": "tsc --watch",
"lint": "eslint src --ext .ts"
},
"keywords": [
"hr",
"hcm",
"human-capital-management",
"recruitment",
"performance",
"payroll"
],
"author": "HotCRM Team",
"license": "MIT",
"dependencies": {
"@hotcrm/core": "workspace:*",
"@objectstack/spec": "^0.8.1",
"typescript": "^5.3.0"
},
"devDependencies": {
"@types/node": "^20.10.0",
"@typescript-eslint/eslint-plugin": "^6.14.0",
"@typescript-eslint/parser": "^6.14.0",
"eslint": "^8.55.0"
}
}
180 changes: 180 additions & 0 deletions packages/hr/src/application.object.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,180 @@

const Application = {
name: 'application',
label: 'ๆฑ‚่Œ็”ณ่ฏท',
labelPlural: 'ๆฑ‚่Œ็”ณ่ฏท',
icon: 'file-alt',
description: 'ๅ€™้€‰ไบบ่Œไฝ็”ณ่ฏท่ฎฐๅฝ•็ฎก็†',
enable: {
searchable: true,
trackHistory: true,
activities: true,
feeds: true,
files: true
},
fields: {
application_number: {
type: 'text',
label: '็”ณ่ฏท็ผ–ๅท',
unique: true,
maxLength: 40
},
candidate_id: {
type: 'lookup',
label: 'ๅ€™้€‰ไบบ',
reference: 'candidate',
required: true
},
recruitment_id: {
type: 'lookup',
label: 'ๆ‹›่˜้œ€ๆฑ‚',
reference: 'recruitment',
required: true
},
applied_date: {
type: 'date',
label: '็”ณ่ฏทๆ—ฅๆœŸ',
required: true,
defaultValue: '$today'
},
status: {
type: 'select',
label: '็Šถๆ€',
defaultValue: 'Submitted',
options: [
{ label: 'ๅทฒๆไบค', value: 'Submitted' },
{ label: '็ญ›้€‰ไธญ', value: 'Screening' },
{ label: 'ๅพ…้ข่ฏ•', value: 'Interview Scheduled' },
{ label: '้ข่ฏ•ไธญ', value: 'Interviewing' },
{ label: '้€š่ฟ‡ๅˆ้€‰', value: 'Shortlisted' },
{ label: 'ๅทฒๅฝ•็”จ', value: 'Offer Extended' },
{ label: 'ๅทฒๆ‹’็ป', value: 'Rejected' },
{ label: 'ๅทฒๆ’คๅ›ž', value: 'Withdrawn' }
]
},
stage: {
type: 'select',
label: 'ๅฝ“ๅ‰้˜ถๆฎต',
options: [
{ label: '็ฎ€ๅކ็ญ›้€‰', value: 'Resume Review' },
{ label: '็”ต่ฏ้ข่ฏ•', value: 'Phone Screen' },
{ label: 'ๅˆ่ฏ•', value: 'First Interview' },
{ label: 'ๅค่ฏ•', value: 'Second Interview' },
{ label: '็ปˆ่ฏ•', value: 'Final Interview' },
{ label: 'OfferๆฒŸ้€š', value: 'Offer Discussion' },
{ label: '่ƒŒๆ™ฏ่ฐƒๆŸฅ', value: 'Background Check' }
]
},
source: {
type: 'select',
label: 'ๆฅๆบๆธ ้“',
options: [
{ label: 'ๆ‹›่˜็ฝ‘็ซ™', value: 'Job Board' },
{ label: 'ๅ†…ๆŽจ', value: 'Employee Referral' },
{ label: '็ŒŽๅคด', value: 'Headhunter' },
{ label: '็คพไบคๅช’ไฝ“', value: 'Social Media' },
{ label: 'ๆ กๅ›ญๆ‹›่˜', value: 'Campus' },
{ label: 'ไธปๅŠจๆŠ•้€’', value: 'Direct Application' },
{ label: 'ๅ…ถไป–', value: 'Other' }
]
},
referrer_id: {
type: 'lookup',
label: 'ๅ†…ๆŽจไบบ',
reference: 'employee',
description: 'ๅฆ‚ๆžœๆ˜ฏๅ†…ๆŽจ๏ผŒ่ฎฐๅฝ•ๆŽจ่ไบบ'
},
rating: {
type: 'rating',
label: '็ปผๅˆ่ฏ„ๅˆ†',
max: 5
},
resume_url: {
type: 'url',
label: '็ฎ€ๅކ้“พๆŽฅ'
},
cover_letter: {
type: 'textarea',
label: 'ๆฑ‚่Œไฟก',
rows: 6
},
rejection_reason: {
type: 'textarea',
label: 'ๆ‹’็ปๅŽŸๅ› ',
rows: 3,
description: 'ๅฆ‚ๆžœ่ขซๆ‹’็ป๏ผŒ่ฎฐๅฝ•ๅŽŸๅ› '
},
notes: {
type: 'textarea',
label: 'ๅค‡ๆณจ',
rows: 4
}
},
relationships: [
{
name: 'Interviews',
type: 'hasMany',
object: 'Interview',
foreignKey: 'application_id',
label: '้ข่ฏ•่ฎฐๅฝ•'
}
],
listViews: [
{
name: 'All',
label: 'ๆ‰€ๆœ‰็”ณ่ฏท',
filters: [],
columns: ['application_number', 'candidate_id', 'recruitment_id', 'applied_date', 'status', 'stage']
},
{
name: 'Screening',
label: '็ญ›้€‰ไธญ',
filters: [['status', '=', 'Screening']],
columns: ['candidate_id', 'recruitment_id', 'applied_date', 'source', 'rating']
},
{
name: 'Interviewing',
label: '้ข่ฏ•ไธญ',
filters: [['status', 'in', ['Interview Scheduled', 'Interviewing']]],
columns: ['candidate_id', 'recruitment_id', 'stage', 'rating', 'applied_date']
},
{
name: 'Shortlisted',
label: 'ๅทฒ้€š่ฟ‡ๅˆ้€‰',
filters: [['status', '=', 'Shortlisted']],
columns: ['candidate_id', 'recruitment_id', 'stage', 'rating', 'applied_date'],
sort: [['rating', 'desc']]
}
],
pageLayout: {
sections: [
{
label: 'ๅŸบๆœฌไฟกๆฏ',
columns: 2,
fields: ['application_number', 'candidate_id', 'recruitment_id', 'applied_date']
},
{
label: '็”ณ่ฏท็Šถๆ€',
columns: 2,
fields: ['status', 'stage', 'rating']
},
{
label: 'ๆฅๆบไฟกๆฏ',
columns: 2,
fields: ['source', 'referrer_id']
},
{
label: '็”ณ่ฏทๆๆ–™',
columns: 1,
fields: ['resume_url', 'cover_letter']
},
{
label: 'ๅ…ถไป–ไฟกๆฏ',
columns: 1,
fields: ['rejection_reason', 'notes']
}
]
}
};

export default Application;
Loading
Loading