Skip to content

Commit

Permalink
Minor documentation fixes
Browse files Browse the repository at this point in the history
- Updated InvoiceTotals class
- Updated Invoice class
- Updated AllowanceOrCharge class
- Updated CONTRIBUTING.md
  • Loading branch information
josemmo committed Nov 12, 2023
1 parent 2e578a3 commit 4910f27
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
6 changes: 3 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,17 +19,17 @@ The main repository branch is only for stable releases.

### 2. Passes static analysis inspection
```
vendor/bin/phan --testdox
vendor/bin/phan --allow-polyfill-parser
```

### 3. Passes all tests
```
vendor/bin/simple-phpunit
vendor/bin/simple-phpunit --testdox
```

### 4. Complies with EN 16931
Although the most popular European Invoicing CIUS is [PEPPOL BIS Billing 3.0](https://docs.peppol.eu/poacc/billing/3.0/),
the real deal is the "European Standard for Electronic invocing" or EN 16931.
the real deal is the "European Standard for Electronic invoicing" or EN 16931.

This means that, while most users will use the [Peppol](src/Presets/Peppol.php) preset for reading and writing invoices,
there are other CIUS/extensions from various member states and business sectors which might not be an exact match to PEPPOL.
Expand Down
2 changes: 1 addition & 1 deletion src/AllowanceOrCharge.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
class AllowanceOrCharge {
protected $reasonCode = null;
protected $reason = null;
protected $amount = null;
protected $amount = 0;
protected $isPercentage = false;

use VatTrait;
Expand Down
2 changes: 1 addition & 1 deletion src/Invoice.php
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ class Invoice {
/**
* Forwarder's invoice discrepancy report
*
* Document/message reporting invoice discrepancies indentified by the forwarder.
* Document/message reporting invoice discrepancies identified by the forwarder.
*/
const TYPE_FORWARDERS_INVOICE_DISCREPANCY_REPORT = 553;

Expand Down
8 changes: 4 additions & 4 deletions src/Models/InvoiceTotals.php
Original file line number Diff line number Diff line change
Expand Up @@ -160,10 +160,10 @@ static public function fromInvoice(Invoice $inv): InvoiceTotals {

/**
* Update VAT map
* @param VatBreakdown[string] &$vatMap VAT map reference
* @param VatTrait $item Item instance
* @param float|null $rate VAT rate
* @param float $addTaxableAmount Taxable amount to add
* @param array<string,VatBreakdown> &$vatMap VAT map reference
* @param VatTrait $item Item instance
* @param float|null $rate VAT rate
* @param float $addTaxableAmount Taxable amount to add
*/
static private function updateVatMap(array &$vatMap, $item, float $addTaxableAmount) {
$category = $item->getVatCategory();
Expand Down

0 comments on commit 4910f27

Please sign in to comment.