
Back
Finance & Payments
An Admin-First Payroll Automation Platform Integrated With an Internal Worklog System
How Pfactorial Technologies built a payslip management platform that automates salary calculation, bonus and deduction logic, and one-click payslip generation for a payroll team.
August 21, 2026
Share
ENGAGEMENT SNAPSHOT

Figure 1 - Key figures from this engagement, at a glance.
EXECUTIVE SUMMARY
Our client's payroll administrators were generating employee salary slips through manual calculation, pulling performance and attendance data from a separate work-log system by hand and recomputing bonuses and deductions every month.
A simple digital form over the same manual process wouldn't have removed the actual bottleneck: bonus and deduction figures depend on live performance scores and Loss-of-Pay data from a separate system, salary structures vary per employee and change over time, and the output has to be an auditable, per-employee PDF payslip generated correctly the first time, every month.
Pfactorial built Payslip Manager: a React and Flask application that pulls performance and leave data directly from the Worklog system, calculates bonuses and deductions automatically, and generates a batch of payslips for selected employees with a single click.
Why this engagement is representative This engagement demonstrates Pfactorial's approach to automating a recurring, calculation-heavy administrative process by integrating directly with the systems that already hold the source data, rather than asking an administrator to re-enter it.
THE CHALLENGE
Automating payslip generation meant solving problems that only appear once real performance data, real salary structures, and a real monthly cadence are involved.
1. Bonus and deduction figures live in a separate system
Monthly performance scores and Loss-of-Pay information come from the Worklog system, not the payroll database, so the calculation can't happen without a live integration between the two.
2. Not every employee record exists in the payroll database yet
When an employee's record isn't found locally, the system needs a fallback source - a Google Sheets integration - rather than blocking payslip generation entirely.
3. Salary structure isn't fixed per employee
Administrators need to edit individual salary additions and deductions and add new particulars entirely, without every change requiring a database migration.
4. Calculated values have to stay calculated, not editable
Performance-bonus and Loss-of-Pay figures are derived from the Worklog integration, so the interface has to prevent an administrator from overwriting a number that should only ever come from the source calculation.
The real brief Not "digitize the payslip form" but "pull the numbers that already exist elsewhere automatically, and only let an administrator edit the parts of the salary that are genuinely discretionary."
THE SOLUTION
Pfactorial built Payslip Manager as a React frontend over a Flask API, integrating directly with the Worklog database and Google Sheets so payroll data only has to exist in one place.

Figure 1 - Data is aggregated from two source systems before any calculation runs, so payslip generation never re-derives numbers by hand.
Architectural principles
- Integrate with the source system instead of re-entering its data - Performance scores and Loss-of-Pay figures are read live from the Worklog database rather than manually transcribed into payroll, removing an entire category of monthly copy-error.
- Separate calculated fields from editable fields at the interface level - Performance-bonus and LOP values render as read-only in the UI because they're derived, while other salary additions and deductions stay editable - the interface enforces which numbers are discretionary.
- Provide a fallback data source instead of a hard failure - When an employee isn't found in the payroll database, the system falls back to the Google Sheets integration rather than blocking that employee's payslip entirely.
CAPABILITIES DELIVERED
Each capability replaces a manual step in the monthly payroll cycle with one the system handles automatically or semi-automatically.
CAPABILITY | WHAT IT DOES |
|---|---|
Salary detail management | Administrators view general information and salary details filtered by name, month, and year, and edit additions, deductions, and specific salary components. |
Automated bonus & deduction calculation | Performance bonuses and Loss-of-Pay deductions calculate automatically from live Worklog data rather than manual lookup. |
Consolidated salary reporting | A report view shows net addition, net deduction, and net income per employee for a given month and year, with pagination and name search. |
One-click batch payslip generation | Administrators select any set of employees and generate PDF payslips for all of them from a single Submit action. |
Payslip preview before generation | Payslips can be viewed and verified before final generation, using a temporary file and secure server-side PDF transfer. |
Google Sheets fallback for missing records | Employee data not yet present in the payroll database is fetched from a connected Google Sheet rather than blocking the workflow. |

Figure 2 - Data aggregation, calculation, and generation form one continuous monthly cycle.
Design note Salary and deduction records deliberately can't be created through the UI at all - only edited once they exist - because the source of truth for who's an employee and what their base structure is meant to stay anchored to the Google Sheet or a direct database entry, not drift from ad-hoc UI edits.
ENGINEERING FOR SCALE AND RELIABILITY
Four decisions kept the payroll calculation trustworthy enough for administrators to rely on it every month.
Argon2 password hashing for authentication
Sign-in checks a hashed password against Flask Argon2 rather than storing or comparing anything in plaintext, for an application handling salary-adjacent data.
SQLAlchemy ORM over raw queries for the payroll database
Database operations run through SQLAlchemy against MySQL, keeping salary and deduction queries consistent and reducing the surface for hand-written SQL errors in a data model with financial consequences.
Secure server-side PDF transfer instead of a direct file URL
Generated payslips are sent to the frontend through Flask's send_file rather than an exposed direct URL, so a payslip PDF isn't reachable by guessing or sharing a link.
Containerized deployment with no direct server access required
Docker and Docker Compose orchestrate the backend and frontend together, pulling the latest code from the repository so developers don't need direct server access to ship an update.
DELIVERY APPROACH
The engagement built outward from the Worklog integration, since every downstream calculation depended on it being reliable first.
1. Backend & database foundation - standing up the Flask API and MySQL schema for employees, salary, deductions, designations, and payment records.
2. Worklog & Google Sheets integration - wiring the connections that pull performance scores, Loss-of-Pay data, and fallback employee records from their source systems.
3. Calculation logic - implementing automated bonus and deduction calculation against the integrated data, with clear separation from administrator-editable fields.
4. Frontend salary management & reporting - building the React interface for salary detail editing and the consolidated salary report with filtering and pagination.
5. Payslip generation & deployment - wiring one-click batch PDF generation with secure file transfer, then containerizing the app with Docker Compose for controlled deployment.
RESULTS AND IMPACT

- Key outcomes from this engagement.
Payslip Manager is built and in use, giving payroll administrators salary detail management, a consolidated reporting view, and one-click batch payslip generation in place of manual monthly calculation.
Because performance bonuses and Loss-of-Pay deductions are pulled live from the Worklog integration rather than transcribed by hand, and generated payslips are transferred securely rather than exposed at a direct URL, the monthly cycle runs against current source data with less manual reconciliation and less exposure of salary-adjacent files.
What it enabled commercially
The payroll team can now run its full monthly cycle - pulling performance and attendance data, calculating bonuses and deductions, and generating a batch of payslips - from one system, reducing the manual calculation and cross-referencing that previously had to happen every month.
WHY PFACTORIAL
This engagement reflects Pfactorial's approach to automating administrative processes by integrating directly with the systems that already hold the source data, rather than digitizing the manual process on top of a fresh, disconnected data entry layer.

- Service lines this engagement draws on.
Engagement enquiries Pfactorial Technologies works with organisations that need payroll, HR, or other calculation-heavy administrative processes automated and integrated with the systems that already hold the source data. If you're evaluating a payroll or administrative automation platform, we're happy to give you an honest read on scope and risk before anyone commits to anything. · pfactorial.ai
APPENDIX A - TECHNOLOGY STACK
The technology stack underpinning the system, grouped by the layer it serves.

Result and Analysis
ENGAGEMENT SNAPSHOT
How Pfactorial Technologies built a payslip management platform that automates salary calculation, bonus and deduction logic, and one-click payslip generation for a payroll team.
CASE STUDIES
You might also like...

OCR & Document ExtractionRAG & Semantic SearchFinance & Payments
Aug 21, 20267 min readRead

Voice AI & TelephonyFinance & PaymentsE-commerce & Retail
A Reusable Prompt Architecture for Human-Sounding Voice AI Across Industries
Aug 21, 20267 min readRead
-640x480.png&w=3840&q=75)
A Self-Hosted Workforce Administration Platform With Middleware-Enforced, Admin-First Access Control
Aug 21, 20268 min readRead

A Self-Hosted, White-Labeled E-Signature Platform With Full Infrastructure Control
Aug 21, 20267 min readRead

Finance & Payments
A Tiered-Verification Voice & Chat Assistant for Regulated Banking
Aug 21, 20269 min readRead

Finance & Payments
An AI-Powered Market Intelligence Terminal for Faster Investment Research
Aug 21, 20266 min readRead





