• DevPilot's avatar
    feat(accounting): gap tools so finance can close what the scanner won't guess · caca1389
    DevPilot authored
    Six streams were left unbooked because the source records no amount: a
    pool zone with no ticket price and no attendance, a player card with no
    fee column, a booking the code writes as zero. The scanner refuses to
    invent a figure, and should — a wrong number in the books is harder to
    find than a missing one, and it looks settled.
    
    But "the system cannot tell you" is not "nobody knows". Finance knows
    what a lane costs. This adds the screen where they say so.
    
    /accounting/gaps — one card per gap:
    
      see the blocker      what exactly is missing, and why it blocks
      propose a value      a flat rate per unit, or the recorded amount
      see the consequence  "احسبلي هينزل كام" computes without writing
      commit               reason and effective date are mandatory
    
    The reason is required because it is what turns an invented number into
    a management estimate — a legitimate basis to account on, provided it is
    stated, approved and attributable. The effective date is required
    because backdating a rate onto years of history rewrites results for
    periods already reported.
    
    Nothing posts from this screen. It records a decision; the accrual
    scanner acts on it next pass. Four new runners stay silent until a
    decision exists, so the rules ship configured but inert.
    
    Academy settlements get a different tool, because it is a different
    problem: the settlement engine reads `academy_contracts` (empty) while
    the 13 real contracts live in `sa_academy_contracts`. The tables are not
    copies — the settlement table carries settlement_day, grace_period_days
    and penalty_rate_pct, which the engine calculates with and the other
    table lacks. So the tool COPIES rather than moves, with the missing
    terms supplied by the accountant rather than defaulted silently, and the
    source contracts keep working untouched.
    
    Verified: gaps stay silent with no decision; a rate of 25/booking books
    8,800 over 352 bookings and re-running books nothing; switching off
    stops future accrual without reversing what was booked; all four
    validation rules reject bad input; 13 contracts import and re-import is
    a no-op. Trial balance still nets to 0.00.
    Co-Authored-By: 's avatarClaude Opus 5 <noreply@anthropic.com>
    caca1389
Name
Last commit
Last update
..
AccountStatementController.php Loading commit data...
AccrualController.php Loading commit data...
BankAccountController.php Loading commit data...
BankLoanController.php Loading commit data...
BankReconciliationController.php Loading commit data...
BillingController.php Loading commit data...
BudgetController.php Loading commit data...
ChartOfAccountsController.php Loading commit data...
CostCenterController.php Loading commit data...
DailyTransactionController.php Loading commit data...
DimensionController.php Loading commit data...
DocumentaryCreditController.php Loading commit data...
FiscalYearController.php Loading commit data...
GapController.php Loading commit data...
InstrumentPortfolioController.php Loading commit data...
JournalEntryController.php Loading commit data...
JournalTypeController.php Loading commit data...
LetterOfGuaranteeController.php Loading commit data...
NegotiableInstrumentController.php Loading commit data...
OpeningEntryController.php Loading commit data...
PeriodClosingController.php Loading commit data...
PostingChainController.php Loading commit data...
ReportController.php Loading commit data...
RevenueMappingController.php Loading commit data...
SettlementController.php Loading commit data...
VoucherController.php Loading commit data...