laraveldaily/laravel-invoices
Generate customizable PDF invoices in Laravel with templates, translations, taxes/discounts/shipping, due dates, serial numbers, and flexible currency formatting. Store, download, or stream via any configured filesystem, with global settings and per-invoice overrides.
Invoice::make()->buyer()->addItem()), making it easy to integrate into existing workflows without tight coupling.Party, InvoiceItem, Invoice) implement contracts (PartyContract), enabling custom implementations for specialized use cases (e.g., multi-party invoices, custom tax logic).invoices:install, invoices:update) for setup, aligning with Laravel’s CLI-first approach.Party, InvoiceItem), reducing validation overhead.dompdf/dompdf (for PDF generation) and Laravel core. No heavy ORM dependencies (works with Eloquent or raw arrays).^4.1.1) mitigate compatibility risks.PartyContract) and follows Laravel conventions. Custom logic can be injected where needed.app.php locales are configured for target markets.php artisan invoices:update to refresh templates/assets post-upgrade.InvoiceService) to encapsulate business logic.InvoiceController@generate) or commands (e.g., GenerateInvoiceCommand).InvoiceGenerated) to notify other systems (e.g., email services, analytics).invoices table. Example schema:
Schema::create('invoices', function (Blueprint $table) {
$table->id();
$table->string('serial_number')->unique();
$table->foreignId('buyer_id')->constrained();
$table->foreignId('seller_id')->constrained();
$table->decimal('total_amount', 10, 2);
$table->string('status')->default('draft');
$table->string('pdf_path');
$table->timestamps();
});
config/filesystems.php to use a dedicated disk (e.g., invoices) for PDF storage.'invoices' => [
'driver' => 's3',
'bucket' => 'app-invoices',
'url' => env('AWS_URL'),
],
Invoice::make()->buyer($customer)->addItem($item)->save('invoices')->dispatch();
(Requires custom dispatch() method or a wrapper.)Party/InvoiceItem structures.Invoice::make()) for quick prototyping.resources/views/vendor/invoices/templates/default.blade.php) to your project.dompdf/dompdf is installed (composer require dompdf/dompdf).invoices table.composer require laraveldaily/laravel-invoices:^4.1.1php artisan invoices:installphp artisan vendor:publish --tag=invoices.configParty model extending \LaravelDaily\Invoices\Classes\Party for buyer/seller data.InvoiceService to abstract generation logic.resources/views/vendor/invoices/templates/.How can I help you explore Laravel packages today?