Skip to content

feat(finance): Journal Entry form + List + API#10

Open
projectadmin-dev wants to merge 3 commits intomasterfrom
feature/finance-journal-form
Open

feat(finance): Journal Entry form + List + API#10
projectadmin-dev wants to merge 3 commits intomasterfrom
feature/finance-journal-form

Conversation

@projectadmin-dev
Copy link
Copy Markdown
Owner

Fitur yang diimplementasi:

  • Journal Entry form (multi debit/credit lines, COA picker, PSAK double-entry validation)
  • Journal List page (filter All/Draft/Posted/Void, statistik cards, action buttons Post/Delete)
  • API create journal entry + lines (balanced validation)
  • VPS deployment ready

projectadmin-dev added 3 commits April 22, 2026 20:22
[User-Story] HC-002: HC Master Data & Employee Management
- Add Employment Information section to UserForm with Employee ID, Job Title,
  Employment Type, Join Date, Work Location, Reporting Manager, Is Active
- Update Zod schema to validate new HR form fields
- Update detail page initialData mapping for HR fields (employee_number, role_name,
  employment_status join_date, is_active)
- Extend PATCH API allowedFields to accept all HR fields (nik, employee_number,
  employment_status, join_date, position_id, department_id, grade_id, base_salary,
  bank_account, bank_name, npwp, bpjs_kesehatan, bpjs_ketenagakerjaan,
  emergency_contact_name, emergency_contact_phone, emergency_contact_relation,
  address, city, province, postal_code)
- Add Supabase migration for hr_employee_contracts and hr_employee_documents tables
- Build verified: next build passed successfully
[User-Story] HC-002: Employee Contracts & Documents Management

**Backend:**
- Add repository layer: hr-employee-contracts.ts (6 functions)
  - getEmployeeContracts, getContractById, getActiveContract, createContract,
    updateContract, deactivateContract, generateContractNo
- Add repository layer: hr-employee-documents.ts (8 functions)
  - getEmployeeDocuments, getDocumentById, getDocumentsByType, createDocument,
    updateDocument, deleteDocument, verifyDocument, getDocumentUploadUrl
- Add REST API routes: /api/hc/employee-contracts (GET, POST)
- Add REST API routes: /api/hc/employee-contracts/[id] (GET, PATCH, DELETE)
- Add REST API routes: /api/hc/employee-documents (GET, POST)
- Add REST API routes: /api/hc/employee-documents/[id] (GET, PATCH, DELETE)
- Add types: HrEmployeeContract, HrEmployeeContractInsert, HrEmployeeContractUpdate,
  HrEmployeeDocument, HrEmployeeDocumentInsert, HrEmployeeDocumentUpdate

**Frontend:**
- Add EmployeeContractsTab component (read-only display with badge status)
- Add EmployeeDocumentsTab component (read-only display with verify badges)
- Add Tabs to /users/[id] page: Overview | Contracts | Documents
- Build verified: next build passed successfully
- New Journal Entry form at /finance/journal/new
  - COA account picker with real-time balance validation
  - Debit/credit line entry with PSAK double-entry rules
  - Auto-sum totals with balance indicator ⚠/✓

- Updated Journal List page with:
  - Status filter (all/draft/posted/void)
  - Stats cards (total debit/credit counts)
  - Action buttons: Post (draft only), Delete, View

- API fixes: entry_number auto-generation, tenant_id on lines

User Story: US-FIN-001
@vercel
Copy link
Copy Markdown

vercel Bot commented Apr 22, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
w-system-app Ready Ready Preview, Comment Apr 22, 2026 1:47pm
w-system-web Ready Ready Preview, Comment Apr 22, 2026 1:47pm
w-system-web-zy7n Ready Ready Preview, Comment Apr 22, 2026 1:47pm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant