accounting modules
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
/**
|
||||
* AccountingEngine
|
||||
*
|
||||
* Core double-entry validation and rules.
|
||||
* Ensures every journal entry balances (total debit = total credit).
|
||||
* All other accounting classes depend on this for validation.
|
||||
*/
|
||||
class AccountingEngine
|
||||
{
|
||||
private PDO $pdo;
|
||||
private int $companyId;
|
||||
|
||||
public function __construct(PDO $pdo, int $company_id)
|
||||
{
|
||||
$this->pdo = $pdo;
|
||||
$this->companyId = $company_id;
|
||||
}
|
||||
|
||||
// TODO: validate journal lines balance (sum debit = sum credit)
|
||||
// TODO: validate account codes exist and are posting accounts
|
||||
// TODO: validate period is open
|
||||
}
|
||||
Reference in New Issue
Block a user