Search by

alfasix / alfakit-invoices

faizanakbar10

Invoices, quotes, credit notes and receipts for AlfaKit panels: exact integer money in any currency, inclusive, exclusive and compound taxes, atomic per-tenant numbering, live server-side totals, payments, overdue tracking, a branded print-ready document with a pluggable PDF renderer and a signed cu

Package info

github.com/alfasixbh/alfakit-invoices

Homepage

Issues

pkg:composer/alfasix/alfakit-invoices

Statistics

Installs: 14

Dependents: 0

Suggesters: 0

Stars: 0

v0.1.8 2026-10-21 10:27 UTC

This package is auto-updated.

Last update: 2026-10-22 11:23:05 UTC


README

by Alfa Six

This is a read-only split of the AlfaKit monorepo. Please open issues and pull requests there.

Invoices, quotes, credit notes and receipts for AlfaKit panels. Features:

  • Exact integer money in any currency (JPY, BHD and the rest).
  • Inclusive, exclusive and compound taxes, rounded per line or on the total.
  • Atomic numbering per type and tenant (INV-{YYYY}-{SEQ:5}).
  • Totals recomputed on the server as you edit.
  • Payments, overdue tracking and receivables widgets.
  • A branded, right-to-left-ready document with a pluggable PDF renderer.
  • A signed customer link with an optional "Pay now" hook.

Installation

composer require alfasix/alfakit-invoices
php artisan vendor:publish --tag=alfakit-invoices-migrations
php artisan migrate

Without a PDF library, documents are print-ready HTML files. Install spatie/laravel-pdf or barryvdh/laravel-dompdf to get PDF files; the plugin picks the installed one.

Register

use AlfaSix\AlfakitInvoices\InvoicesPlugin;

$panel->plugin(
    InvoicesPlugin::make()
        ->authorize(fn (User $user): bool => $user->can_bill)
        ->customers(fn (?Team $tenant) => Customer::query()->whereBelongsTo($tenant), titleAttribute: 'company')
        ->seller(['name' => 'Acme W.L.L.', 'tax_id' => 'VAT-123']),
);
$invoice = Invoice::createWithItems(['billable' => $customer, 'currency' => 'BHD'], [
    ['description' => 'Design', 'quantity' => '10', 'unit_price' => 25000, 'tax_ids' => [$vat->id]],
]);

$invoice->markAsSent();
$invoice->recordPayment(100000, method: 'bank_transfer');

php artisan alfakit-invoices:mark-overdue runs daily through the scheduler.

Read the full documentation at alfakit.dev/docs/plugins/invoices.

License

MIT. See LICENSE.md.