DE solved!

This commit is contained in:
David Bomba 2024-07-18 12:21:24 +10:00
parent 5f0c08e7e9
commit acf73fb6fd
4 changed files with 292 additions and 134 deletions

View File

@ -119,6 +119,8 @@ class Storecove {
$uri = "document_submissions"; $uri = "document_submissions";
nlog($payload);
$r = $this->httpClient($uri, (HttpVerb::POST)->value, $payload, $this->getHeaders()); $r = $this->httpClient($uri, (HttpVerb::POST)->value, $payload, $this->getHeaders());
nlog($r->body()); nlog($r->body());

View File

@ -11,11 +11,13 @@
namespace App\Services\EDocument\Standards; namespace App\Services\EDocument\Standards;
use App\Models\Company;
use App\Models\Invoice; use App\Models\Invoice;
use App\Services\AbstractService; use App\Services\AbstractService;
use App\Helpers\Invoice\InvoiceSum; use App\Helpers\Invoice\InvoiceSum;
use App\Helpers\Invoice\InvoiceSumInclusive;
use InvoiceNinja\EInvoice\EInvoice; use InvoiceNinja\EInvoice\EInvoice;
use App\Helpers\Invoice\InvoiceSumInclusive;
use InvoiceNinja\EInvoice\Models\Peppol\PaymentMeans;
use InvoiceNinja\EInvoice\Models\Peppol\ItemType\Item; use InvoiceNinja\EInvoice\Models\Peppol\ItemType\Item;
use InvoiceNinja\EInvoice\Models\Peppol\PartyType\Party; use InvoiceNinja\EInvoice\Models\Peppol\PartyType\Party;
use InvoiceNinja\EInvoice\Models\Peppol\PriceType\Price; use InvoiceNinja\EInvoice\Models\Peppol\PriceType\Price;
@ -24,9 +26,13 @@ use InvoiceNinja\EInvoice\Models\Peppol\ContactType\Contact;
use InvoiceNinja\EInvoice\Models\Peppol\CountryType\Country; use InvoiceNinja\EInvoice\Models\Peppol\CountryType\Country;
use InvoiceNinja\EInvoice\Models\Peppol\AmountType\TaxAmount; use InvoiceNinja\EInvoice\Models\Peppol\AmountType\TaxAmount;
use InvoiceNinja\EInvoice\Models\Peppol\TaxTotalType\TaxTotal; use InvoiceNinja\EInvoice\Models\Peppol\TaxTotalType\TaxTotal;
use App\Services\EDocument\Standards\Settings\PropertyResolver;
use InvoiceNinja\EInvoice\Models\Peppol\AmountType\PriceAmount;
use InvoiceNinja\EInvoice\Models\Peppol\PartyNameType\PartyName; use InvoiceNinja\EInvoice\Models\Peppol\PartyNameType\PartyName;
use InvoiceNinja\EInvoice\Models\Peppol\TaxSchemeType\TaxScheme; use InvoiceNinja\EInvoice\Models\Peppol\TaxSchemeType\TaxScheme;
use InvoiceNinja\EInvoice\Models\Peppol\AmountType\PayableAmount; use InvoiceNinja\EInvoice\Models\Peppol\AmountType\PayableAmount;
use InvoiceNinja\EInvoice\Models\Peppol\AmountType\TaxableAmount;
use InvoiceNinja\EInvoice\Models\Peppol\TaxTotal as PeppolTaxTotal;
use InvoiceNinja\EInvoice\Models\Peppol\InvoiceLineType\InvoiceLine; use InvoiceNinja\EInvoice\Models\Peppol\InvoiceLineType\InvoiceLine;
use InvoiceNinja\EInvoice\Models\Peppol\TaxCategoryType\TaxCategory; use InvoiceNinja\EInvoice\Models\Peppol\TaxCategoryType\TaxCategory;
use InvoiceNinja\EInvoice\Models\Peppol\TaxSubtotalType\TaxSubtotal; use InvoiceNinja\EInvoice\Models\Peppol\TaxSubtotalType\TaxSubtotal;
@ -34,13 +40,11 @@ use InvoiceNinja\EInvoice\Models\Peppol\TaxScheme as PeppolTaxScheme;
use InvoiceNinja\EInvoice\Models\Peppol\AmountType\TaxExclusiveAmount; use InvoiceNinja\EInvoice\Models\Peppol\AmountType\TaxExclusiveAmount;
use InvoiceNinja\EInvoice\Models\Peppol\AmountType\TaxInclusiveAmount; use InvoiceNinja\EInvoice\Models\Peppol\AmountType\TaxInclusiveAmount;
use InvoiceNinja\EInvoice\Models\Peppol\AmountType\LineExtensionAmount; use InvoiceNinja\EInvoice\Models\Peppol\AmountType\LineExtensionAmount;
use InvoiceNinja\EInvoice\Models\Peppol\AmountType\PriceAmount;
use InvoiceNinja\EInvoice\Models\Peppol\AmountType\TaxableAmount;
use InvoiceNinja\EInvoice\Models\Peppol\MonetaryTotalType\LegalMonetaryTotal; use InvoiceNinja\EInvoice\Models\Peppol\MonetaryTotalType\LegalMonetaryTotal;
use InvoiceNinja\EInvoice\Models\Peppol\TaxCategoryType\ClassifiedTaxCategory; use InvoiceNinja\EInvoice\Models\Peppol\TaxCategoryType\ClassifiedTaxCategory;
use InvoiceNinja\EInvoice\Models\Peppol\CustomerPartyType\AccountingCustomerParty; use InvoiceNinja\EInvoice\Models\Peppol\CustomerPartyType\AccountingCustomerParty;
use InvoiceNinja\EInvoice\Models\Peppol\SupplierPartyType\AccountingSupplierParty; use InvoiceNinja\EInvoice\Models\Peppol\SupplierPartyType\AccountingSupplierParty;
use InvoiceNinja\EInvoice\Models\Peppol\TaxTotal as PeppolTaxTotal; use InvoiceNinja\EInvoice\Models\Peppol\FinancialAccountType\PayeeFinancialAccount;
class Peppol extends AbstractService class Peppol extends AbstractService
{ {
@ -59,16 +63,17 @@ class Peppol extends AbstractService
"896" => "Debit note related to self-billed invoice" "896" => "Debit note related to self-billed invoice"
]; ];
private \InvoiceNinja\EInvoice\Models\Peppol\Invoice $p_invoice; private Company $company;
private InvoiceSum | InvoiceSumInclusive $calc; private InvoiceSum | InvoiceSumInclusive $calc;
/** /**
* @param Invoice $invoice * @param Invoice $invoice
*/ */
public function __construct(public Invoice $invoice) public function __construct(public Invoice $invoice, public ?\InvoiceNinja\EInvoice\Models\Peppol\Invoice $p_invoice = null)
{ {
$this->p_invoice = new \InvoiceNinja\EInvoice\Models\Peppol\Invoice(); $this->p_invoice = $p_invoice ?? new \InvoiceNinja\EInvoice\Models\Peppol\Invoice();
$this->company = $invoice->company;
$this->calc = $this->invoice->calc(); $this->calc = $this->invoice->calc();
} }
@ -95,6 +100,7 @@ class Peppol extends AbstractService
$this->p_invoice->InvoiceLine = $this->getInvoiceLines(); $this->p_invoice->InvoiceLine = $this->getInvoiceLines();
$this->p_invoice->TaxTotal = $this->getTotalTaxes(); $this->p_invoice->TaxTotal = $this->getTotalTaxes();
$this->p_invoice->LegalMonetaryTotal = $this->getLegalMonetaryTotal(); $this->p_invoice->LegalMonetaryTotal = $this->getLegalMonetaryTotal();
// $this->p_invoice->PaymentMeans = $this->getPaymentMeans();
// $payeeFinancialAccount = (new PayeeFinancialAccount()) // $payeeFinancialAccount = (new PayeeFinancialAccount())
// ->setBankId($company->settings->custom_value1) // ->setBankId($company->settings->custom_value1)
@ -107,6 +113,17 @@ class Peppol extends AbstractService
} }
private function getPaymentMeans(): PaymentMeans
{
// $payeeFinancialAccount = new PayeeFinancialAccount()
// $payeeFinancialAccount->
// $ppm = new PaymentMeans();
// $ppm->PayeeFinancialAccount = $payeeFinancialAccount;
// return $ppm;
}
private function getLegalMonetaryTotal(): LegalMonetaryTotal private function getLegalMonetaryTotal(): LegalMonetaryTotal
{ {
$taxable = $this->getTaxable(); $taxable = $this->getTaxable();
@ -310,7 +327,7 @@ class Peppol extends AbstractService
$tax_amount = new TaxAmount(); $tax_amount = new TaxAmount();
$tax_amount->currencyID = $this->invoice->client->currency()->code; $tax_amount->currencyID = $this->invoice->client->currency()->code;
$tax_amount->amount = round(($item->line_total * (1 / $item->tax_rate1)), 2); $tax_amount->amount = round(($item->line_total * ($item->tax_rate1/100)), 2);
$tax_subtotal = new TaxSubtotal(); $tax_subtotal = new TaxSubtotal();
$tax_subtotal->TaxAmount = $tax_amount; $tax_subtotal->TaxAmount = $tax_amount;
@ -339,7 +356,7 @@ class Peppol extends AbstractService
$tax_amount = new TaxAmount(); $tax_amount = new TaxAmount();
$tax_amount->currencyID = $this->invoice->client->currency()->code; $tax_amount->currencyID = $this->invoice->client->currency()->code;
$tax_amount->amount = round(($item->line_total * (1 / $item->tax_rate2)), 2); $tax_amount->amount = round(($item->line_total * ($item->tax_rate2/100)), 2);
$tax_subtotal = new TaxSubtotal(); $tax_subtotal = new TaxSubtotal();
$tax_subtotal->TaxAmount = $tax_amount; $tax_subtotal->TaxAmount = $tax_amount;
@ -372,7 +389,7 @@ class Peppol extends AbstractService
$tax_amount = new TaxAmount(); $tax_amount = new TaxAmount();
$tax_amount->currencyID = $this->invoice->client->currency()->code; $tax_amount->currencyID = $this->invoice->client->currency()->code;
$tax_amount->amount = round(($item->line_total * (1 / $item->tax_rate3)), 2); $tax_amount->amount = round(($item->line_total * ($item->tax_rate3/100)), 2);
$tax_subtotal = new TaxSubtotal(); $tax_subtotal = new TaxSubtotal();
$tax_subtotal->TaxAmount = $tax_amount; $tax_subtotal->TaxAmount = $tax_amount;
@ -520,4 +537,35 @@ class Peppol extends AbstractService
return $total; return $total;
} }
public function setInvoiceDefaults(): self
{
$settings = [
'AccountingCostCode' => 7,
'AccountingCost' => 7,
'BuyerReference' => 6,
'AccountingSupplierParty' => 1,
'AccountingCustomerParty' => 2,
'PayeeParty' => 1,
'BuyerCustomerParty' => 2,
'SellerSupplierParty' => 1,
'TaxRepresentativeParty' => 1,
'Delivery' => 1,
'DeliveryTerms' => 7,
'PaymentMeans' => 7,
'PaymentTerms' => 7,
];
foreach($settings as $prop => $visibility){
if($prop_value = PropertyResolver::resolve($this->invoice->client->e_invoice, $prop))
$this->p_invoice->{$prop} = $prop_value;
elseif($prop_value = PropertyResolver::resolve($this->invoice->company->e_invoice, $prop)) {
$this->p_invoice->{$prop} = $prop_value;
}
}
return $this;
}
} }

View File

@ -14,20 +14,23 @@ namespace Tests\Feature\EInvoice;
use Tests\TestCase; use Tests\TestCase;
use App\Models\Client; use App\Models\Client;
use App\Models\Company; use App\Models\Company;
use App\Models\Invoice;
use Tests\MockAccountData; use Tests\MockAccountData;
use App\DataMapper\InvoiceItem;
use App\DataMapper\ClientSettings; use App\DataMapper\ClientSettings;
use App\DataMapper\CompanySettings; use App\DataMapper\CompanySettings;
use App\DataMapper\InvoiceItem; use InvoiceNinja\EInvoice\EInvoice;
use App\Models\Invoice;
use InvoiceNinja\EInvoice\Symfony\Encode; use InvoiceNinja\EInvoice\Symfony\Encode;
use App\Services\EDocument\Standards\FatturaPANew;
use App\Services\EDocument\Standards\Peppol; use App\Services\EDocument\Standards\Peppol;
use App\Services\EDocument\Standards\FatturaPANew;
use Illuminate\Routing\Middleware\ThrottleRequests; use Illuminate\Routing\Middleware\ThrottleRequests;
use Illuminate\Foundation\Testing\DatabaseTransactions; use Illuminate\Foundation\Testing\DatabaseTransactions;
use InvoiceNinja\EInvoice\EInvoice;
use InvoiceNinja\EInvoice\Models\FatturaPA\FatturaElettronica; use InvoiceNinja\EInvoice\Models\FatturaPA\FatturaElettronica;
use InvoiceNinja\EInvoice\Models\Peppol\BranchType\FinancialInstitutionBranch;
use InvoiceNinja\EInvoice\Models\Peppol\FinancialAccountType\PayeeFinancialAccount;
use InvoiceNinja\EInvoice\Models\FatturaPA\FatturaElettronicaBodyType\FatturaElettronicaBody; use InvoiceNinja\EInvoice\Models\FatturaPA\FatturaElettronicaBodyType\FatturaElettronicaBody;
use InvoiceNinja\EInvoice\Models\FatturaPA\FatturaElettronicaHeaderType\FatturaElettronicaHeader; use InvoiceNinja\EInvoice\Models\FatturaPA\FatturaElettronicaHeaderType\FatturaElettronicaHeader;
use InvoiceNinja\EInvoice\Models\Peppol\PaymentMeans;
/** /**
* @test * @test
@ -51,6 +54,120 @@ class PeppolTest extends TestCase
); );
} }
public function testDeInvoice()
{
$settings = CompanySettings::defaults();
$settings->address1 = 'Dudweilerstr. 34b';
$settings->city = 'Ost Alessa';
$settings->state = 'Bayern';
$settings->postal_code = '98060';
$settings->vat_number = 'DE923356489';
$settings->country_id = '276';
$settings->currency_id = '3';
$einvoice = new \InvoiceNinja\EInvoice\Models\Peppol\Invoice();
$fib = new FinancialInstitutionBranch();
$fib->ID = "DEUTDEMMXXX"; //BIC
$fib->Name = 'Deutsche Bank';
$pfa = new PayeeFinancialAccount();
$pfa->ID = 'DE89370400440532013000';
$pfa->Name = 'PFA-NAME';
$pfa->AliasName = 'PFA-Alias';
$pfa->AccountTypeCode = 'CHECKING';
$pfa->AccountFormatCode = 'IBAN';
$pfa->CurrencyCode = 'EUR';
$pfa->FinancialInstitutionBranch = $fib;
$pm = new PaymentMeans();
$pm->PayeeFinancialAccount = $pfa;
$einvoice->PaymentMeans[] = $pm;
$company = Company::factory()->create([
'account_id' => $this->account->id,
'settings' => $settings,
'e_invoice' => $einvoice,
]);
$client_settings = ClientSettings::defaults();
$client_settings->currency_id = '3';
$client = Client::factory()->create([
'company_id' => $company->id,
'user_id' => $this->user->id,
'name' => 'German Client Name',
'address1' => 'Kinderhausen 96b',
'address2' => 'Apt. 842',
'city' => 'Süd Jessestadt',
'state' => 'Bayern',
'postal_code' => '33323',
'country_id' => 276,
'routing_id' => 'ABC1234',
'settings' => $client_settings,
]);
$item = new InvoiceItem();
$item->product_key = "Product Key";
$item->notes = "Product Description";
$item->cost = 10;
$item->quantity = 10;
$item->tax_rate1 = 19;
$item->tax_name1 = 'mwst';
$invoice = Invoice::factory()->create([
'company_id' => $company->id,
'user_id' => $this->user->id,
'client_id' => $client->id,
'discount' => 0,
'uses_inclusive_taxes' => false,
'status_id' => 1,
'tax_rate1' => 0,
'tax_name1' => '',
'tax_rate2' => 0,
'tax_rate3' => 0,
'tax_name2' => '',
'tax_name3' => '',
'line_items' => [$item],
'number' => 'DE-'.rand(1000, 100000),
'date' => now()->format('Y-m-d')
]);
$invoice = $invoice->calc()->getInvoice();
$invoice->service()->markSent()->save();
$this->assertEquals(119, $invoice->amount);
$peppol = new Peppol($invoice);
$peppol->setInvoiceDefaults();
$peppol->run();
$de_invoice = $peppol->getInvoice();
$this->assertNotNull($de_invoice);
$e = new EInvoice();
$xml = $e->encode($de_invoice, 'xml');
$this->assertNotNull($xml);
nlog($xml);
$errors = $e->validate($de_invoice);
if(count($errors) > 0) {
nlog($errors);
}
$this->assertCount(0, $errors);
}
public function testInvoiceBoot() public function testInvoiceBoot()
{ {

View File

@ -105,126 +105,117 @@ class StorecoveTest extends TestCase
$x = ' $x = '
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<Invoice <Invoice
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2"> xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2">
<cbc:ID>0061</cbc:ID> <cbc:ID>DE-77323</cbc:ID>
<cbc:IssueDate>2024-07-15</cbc:IssueDate> <cbc:IssueDate>2024-07-18</cbc:IssueDate>
<cbc:InvoiceTypeCode>380</cbc:InvoiceTypeCode> <cbc:InvoiceTypeCode>380</cbc:InvoiceTypeCode>
<cac:AccountingSupplierParty> <cac:AccountingSupplierParty>
<cac:Party> <cac:Party>
<cac:PartyName> <cac:PartyName>
<cbc:Name>Eladio Ullrich I</cbc:Name> <cbc:Name>Untitled Company</cbc:Name>
</cac:PartyName> </cac:PartyName>
<cac:PostalAddress> <cac:PostalAddress>
<cbc:StreetName>Jasper Brook</cbc:StreetName> <cbc:StreetName>Dudweilerstr. 34b</cbc:StreetName>
<cbc:CityName>Kodychester</cbc:CityName> <cbc:CityName>Ost Alessa</cbc:CityName>
<cbc:PostalZone>73445-5131</cbc:PostalZone> <cbc:PostalZone>98060</cbc:PostalZone>
<cbc:CountrySubentity>South Dakota</cbc:CountrySubentity> <cbc:CountrySubentity>Bayern</cbc:CountrySubentity>
<cac:Country> <cac:Country>
<cbc:IdentificationCode>AT</cbc:IdentificationCode> <cbc:IdentificationCode>DE</cbc:IdentificationCode>
</cac:Country> </cac:Country>
</cac:PostalAddress> </cac:PostalAddress>
<cac:PhysicalLocation> <cac:PhysicalLocation>
<cbc:StreetName>Jasper Brook</cbc:StreetName> <cbc:StreetName>Dudweilerstr. 34b</cbc:StreetName>
<cbc:CityName>Kodychester</cbc:CityName> <cbc:CityName>Ost Alessa</cbc:CityName>
<cbc:PostalZone>73445-5131</cbc:PostalZone> <cbc:PostalZone>98060</cbc:PostalZone>
<cbc:CountrySubentity>South Dakota</cbc:CountrySubentity> <cbc:CountrySubentity>Bayern</cbc:CountrySubentity>
<cac:Country> <cac:Country>
<cbc:IdentificationCode>AT</cbc:IdentificationCode> <cbc:IdentificationCode>DE</cbc:IdentificationCode>
</cac:Country> </cac:Country>
</cac:PhysicalLocation> </cac:PhysicalLocation>
<cac:Contact> <cac:Contact>
<cbc:ElectronicMail>small@example.com</cbc:ElectronicMail> <cbc:ElectronicMail>owner@gmail.com</cbc:ElectronicMail>
</cac:Contact> </cac:Contact>
</cac:Party> </cac:Party>
</cac:AccountingSupplierParty> </cac:AccountingSupplierParty>
<cac:AccountingCustomerParty> <cac:AccountingCustomerParty>
<cac:Party> <cac:Party>
<cac:PartyName> <cac:PartyName>
<cbc:Name>Beispiel GmbH</cbc:Name> <cbc:Name>German Client Name</cbc:Name>
</cac:PartyName> </cac:PartyName>
<cac:PostalAddress> <cac:PostalAddress>
<cbc:StreetName>45 Hauptstra&#xDF;e</cbc:StreetName> <cbc:StreetName>Kinderhausen 96b</cbc:StreetName>
<cbc:CityName>Berlin</cbc:CityName> <cbc:CityName>S&#xFC;d Jessestadt</cbc:CityName>
<cbc:PostalZone>10115</cbc:PostalZone> <cbc:PostalZone>33323</cbc:PostalZone>
<cbc:CountrySubentity>Berlin</cbc:CountrySubentity> <cbc:CountrySubentity>Bayern</cbc:CountrySubentity>
<cac:Country> <cac:Country>
<cbc:IdentificationCode>DE</cbc:IdentificationCode> <cbc:IdentificationCode>DE</cbc:IdentificationCode>
</cac:Country> </cac:Country>
</cac:PostalAddress> </cac:PostalAddress>
<cac:PhysicalLocation> <cac:PhysicalLocation>
<cbc:StreetName>45 Hauptstra&#xDF;e</cbc:StreetName> <cbc:StreetName>Kinderhausen 96b</cbc:StreetName>
<cbc:CityName>Berlin</cbc:CityName> <cbc:CityName>S&#xFC;d Jessestadt</cbc:CityName>
<cbc:PostalZone>10115</cbc:PostalZone> <cbc:PostalZone>33323</cbc:PostalZone>
<cbc:CountrySubentity>Berlin</cbc:CountrySubentity> <cbc:CountrySubentity>Bayern</cbc:CountrySubentity>
<cac:Country> <cac:Country>
<cbc:IdentificationCode>DE</cbc:IdentificationCode> <cbc:IdentificationCode>DE</cbc:IdentificationCode>
</cac:Country> </cac:Country>
</cac:PhysicalLocation> </cac:PhysicalLocation>
<cac:Contact> <cac:Contact>
<cbc:ElectronicMail>TTKGjKW9Rv00LEr@example.com</cbc:ElectronicMail> <cbc:ElectronicMail>No Email Set</cbc:ElectronicMail>
</cac:Contact> </cac:Contact>
</cac:Party> </cac:Party>
</cac:AccountingCustomerParty> </cac:AccountingCustomerParty>
<cac:TaxTotal/> <cac:PaymentMeans>
<cac:LegalMonetaryTotal> <PayeeFinancialAccount>
<cbc:LineExtensionAmount currencyID="EUR">215</cbc:LineExtensionAmount> <ID>DE89370400440532013000</ID>
<cbc:TaxExclusiveAmount currencyID="EUR">215</cbc:TaxExclusiveAmount> <Name>PFA-NAME</Name>
<cbc:TaxInclusiveAmount currencyID="EUR">215.00</cbc:TaxInclusiveAmount> <AliasName>PFA-Alias</AliasName>
<cbc:PayableAmount currencyID="EUR">215.00</cbc:PayableAmount> <AccountTypeCode>CHECKING</AccountTypeCode>
</cac:LegalMonetaryTotal> <AccountFormatCode>IBAN</AccountFormatCode>
<cac:InvoiceLine> <CurrencyCode>EUR</CurrencyCode>
<cbc:ID>1</cbc:ID> <FinancialInstitutionBranch>
<cbc:InvoicedQuantity>1</cbc:InvoicedQuantity> <ID>DEUTDEMMXXX</ID>
<cbc:LineExtensionAmount currencyID="EUR">10</cbc:LineExtensionAmount> <Name>Deutsche Bank</Name>
<cac:TaxTotal> </FinancialInstitutionBranch>
<cbc:TaxAmount currencyID="EUR">0.5</cbc:TaxAmount> </PayeeFinancialAccount>
<cac:TaxSubtotal> </cac:PaymentMeans>
<cbc:TaxableAmount currencyID="EUR">10</cbc:TaxableAmount> <cac:TaxTotal/>
<cbc:TaxAmount currencyID="EUR">0.5</cbc:TaxAmount> <cac:LegalMonetaryTotal>
<cac:TaxCategory> <cbc:LineExtensionAmount currencyID="EUR">100</cbc:LineExtensionAmount>
<cbc:ID>C62</cbc:ID> <cbc:TaxExclusiveAmount currencyID="EUR">100</cbc:TaxExclusiveAmount>
<cbc:Percent>20</cbc:Percent> <cbc:TaxInclusiveAmount currencyID="EUR">119.00</cbc:TaxInclusiveAmount>
<cac:TaxScheme> <cbc:PayableAmount currencyID="EUR">119.00</cbc:PayableAmount>
<cbc:ID>USt</cbc:ID> </cac:LegalMonetaryTotal>
</cac:TaxScheme> <cac:InvoiceLine>
</cac:TaxCategory> <cbc:ID>1</cbc:ID>
</cac:TaxSubtotal> <cbc:InvoicedQuantity>10</cbc:InvoicedQuantity>
</cac:TaxTotal> <cbc:LineExtensionAmount currencyID="EUR">100</cbc:LineExtensionAmount>
<cac:Item> <cac:TaxTotal>
<cbc:Description>The Pro Plan NO MORE</cbc:Description> <cbc:TaxAmount currencyID="EUR">19</cbc:TaxAmount>
<cbc:Name>ee</cbc:Name> <cac:TaxSubtotal>
</cac:Item> <cbc:TaxableAmount currencyID="EUR">100</cbc:TaxableAmount>
<cac:Price> <cbc:TaxAmount currencyID="EUR">19</cbc:TaxAmount>
<cbc:PriceAmount currencyID="EUR">10</cbc:PriceAmount> <cac:TaxCategory>
</cac:Price> <cbc:ID>C62</cbc:ID>
</cac:InvoiceLine> <cbc:Percent>19</cbc:Percent>
<cac:InvoiceLine> <cac:TaxScheme>
<cbc:ID>2</cbc:ID> <cbc:ID>mwst</cbc:ID>
<cbc:InvoicedQuantity>1</cbc:InvoicedQuantity> </cac:TaxScheme>
<cbc:LineExtensionAmount currencyID="EUR">14</cbc:LineExtensionAmount> </cac:TaxCategory>
<cac:Item> </cac:TaxSubtotal>
<cbc:Description>The Enterprise Plan</cbc:Description> </cac:TaxTotal>
<cbc:Name>eee</cbc:Name> <cac:Item>
</cac:Item> <cbc:Description>Product Description</cbc:Description>
<cac:Price> <cbc:Name>Product Key</cbc:Name>
<cbc:PriceAmount currencyID="EUR">14</cbc:PriceAmount> </cac:Item>
</cac:Price> <cac:Price>
</cac:InvoiceLine> <cbc:PriceAmount currencyID="EUR">10</cbc:PriceAmount>
<cac:InvoiceLine> </cac:Price>
<cbc:ID>3</cbc:ID> </cac:InvoiceLine>
<cbc:InvoicedQuantity>1</cbc:InvoicedQuantity> ';
<cbc:LineExtensionAmount currencyID="EUR">191</cbc:LineExtensionAmount>
<cac:Item>
<cbc:Description>Soluta provident.</cbc:Description>
<cbc:Name>k</cbc:Name>
</cac:Item>
<cac:Price>
<cbc:PriceAmount currencyID="EUR">191</cbc:PriceAmount>
</cac:Price>
</cac:InvoiceLine>';
$sc = new \App\Services\EDocument\Gateway\Storecove\Storecove(); $sc = new \App\Services\EDocument\Gateway\Storecove\Storecove();
$sc->sendDocument($x); $sc->sendDocument($x);