-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b3c3751
commit 850ff2f
Showing
2 changed files
with
60 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
--- | ||
title: BillaBear Invoice Events | ||
sidebar_label: Invoice | ||
sidebar_position: 2 | ||
--- | ||
Here is the information relating to events relating to Invoices | ||
|
||
## Invoice Created | ||
|
||
This is triggered when an invoice is created. | ||
|
||
| Name | Constant For Name | | ||
| --- | --- | | ||
| billabear.invoice.created | `BillaBear\Event\Invoice\InvoiceCreated::NAME` | | ||
|
||
### Event Class | ||
|
||
```php | ||
namespace BillaBear\Event\Invoice; | ||
|
||
use BillaBear\Entity\Invoice; | ||
use Symfony\Contracts\EventDispatcher\Event; | ||
|
||
class InvoiceCreated extends Event | ||
{ | ||
public const string NAME = 'billabear.invoice.created'; | ||
|
||
public function __construct(public readonly Invoice $invoice) | ||
{ | ||
} | ||
} | ||
``` | ||
|
||
## Invoice Paid | ||
|
||
This is triggered when an invoice is paid. | ||
|
||
| Name | Constant For Name | | ||
| --- | --- | | ||
| billabear.invoice.paid | `BillaBear\Event\Invoice\InvoicePaid::NAME` | | ||
|
||
### Event Class | ||
|
||
```php | ||
namespace BillaBear\Event\Invoice; | ||
|
||
use BillaBear\Entity\Invoice; | ||
use Symfony\Contracts\EventDispatcher\Event; | ||
|
||
class InvoicePaid extends Event | ||
{ | ||
public const string NAME = 'billabear.invoice.paid'; | ||
|
||
public function __construct(public readonly Invoice $invoice) | ||
{ | ||
} | ||
} | ||
|
||
``` |