You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Parent issue:#126 (UBL 2.1 / Peppol e-invoicing support — implement that first)
SMART Plan — [Invoices] NLCIUS Dutch CIUS profile for UBL 2.1 export
Specific
Once the base UBL 2.1 export from #126 is in place, configure it to emit the Dutch NLCIUS profile when the invoice's customer country is NL. This requires two targeted changes:
recommendedForCountry('NL') (or equivalent resolver) must return UBL_21 as the e-invoicing standard.
The UBL document's <cbc:CustomizationID> element must be set to urn:cen.eu:en16931:2017#compliant#urn:fdc:nen.nl:nlcius:v1.0 for NL invoices.
Measurable
A NL-country invoice exported as UBL 2.1 contains the NLCIUS CustomizationID in the document root.
recommendedForCountry('NL') returns the UBL 2.1 standard (not null or another standard).
PHPUnit asserts both points above.
Achievable
Locate the country→standard resolver in the UBL service layer (likely under Modules/Invoices/Services/Ubl/).
Add 'NL' => UblStandard::UBL_21 (or equivalent) to the country map.
Inject the NLCIUS customizationID into the UBL builder when the resolved standard is UBL_21 and country is NL.
Add a PHPUnit test asserting the CustomizationID value in the generated XML.
Relevant
The Netherlands mandates NLCIUS for B2G e-invoicing and it is the de-facto standard for NL B2B e-invoicing. Without this profile, Dutch users cannot submit via Peppol to government bodies or major enterprise buyers.
The existing scoping plan above is sound. Status: Phase 1 (UBL 2.1 export) is not yet started.
Supporting models/infrastructure confirmed:
Modules/Invoices/Models/Invoice.php — has invoiceItems() relation, company() BelongsTo, customer linked via relation_id to Modules/Clients/Models/Relation.php
Relation model provides billing company name, address, email fields (cf. cac:AccountingCustomerParty EN 16931 requirement)
InvoiceItem has item_name, description, quantity, price, tax_rate_id (cf. cac:InvoiceLine)
Tax model at Modules/Core/Models/TaxRate.php provides VAT percentages (cf. cac:TaxTotal)
Activity
[-]NLCIUS (Dutch CIUS).[/-][+][Invoices]: NLCIUS (Dutch CIUS) e-invoicing standard[/+]nielsdrost7 commentedon Jun 14, 2026
Sprint 5 — Scoping Plan (Epic)
Peppol/NLCIUS is a multi-sprint epic. Full implementation is too large for a single sprint. This comment proposes a phased approach.
Phase 1 — UBL 2.1 Export (Sprint 5 goal)
The smallest shippable piece: generate a valid UBL 2.1 XML from an existing invoice.
Suggested package:
horstoeko/ublor build a raw XML generator using PHP'sDOMDocument.Files to create:
Modules/Invoices/Services/UblExportService.php— converts anInvoicemodel to UBL 2.1 XMLModules/Invoices/Http/Controllers/InvoiceUblController.php— returns the XML as a downloadInvoicesTableandEditInvoiceheader actionsMinimum required UBL fields (EN 16931 mandatory):
cbc:ID(invoice number),cbc:IssueDate,cbc:DueDatecac:AccountingSupplierParty(seller company)cac:AccountingCustomerParty(customer fromRelationmodel)cac:InvoiceLine(fromInvoiceItem)cac:TaxTotal,cac:LegalMonetaryTotalNLCIUS profile: Adds Dutch-specific fields (
cbc:CustomizationID = "urn:cen.eu:en16931:2017#compliant#urn:fdc:nen.nl:nlcius:v1.0").Phase 2 — Validation (Sprint 6+)
horstoeko/zugferdor an external validator APIPhase 3 — Peppol Network (Sprint 7+)
Sprint 5 deliverable: Phase 1 only — generate and download a valid UBL 2.1 XML for any invoice.
Effort: ~8–12 hours for Phase 1.
Note: Issues #487 and #126 describe the same feature. Recommend closing #126 as a duplicate of #487 (the more detailed one).
Generated by Claude Code
[-][Invoices]: NLCIUS (Dutch CIUS) e-invoicing standard[/-][+][Invoices]: NLCIUS (Dutch CIUS) e-invoicing profile for UBL 2.1 export[/+]nielsdrost7 commentedon Jul 24, 2026
Confirmed — NLCIUS/UBL 2.1 Epic Status
The existing scoping plan above is sound. Status: Phase 1 (UBL 2.1 export) is not yet started.
Supporting models/infrastructure confirmed:
Modules/Invoices/Models/Invoice.php— hasinvoiceItems()relation,company()BelongsTo, customer linked viarelation_idtoModules/Clients/Models/Relation.phpRelationmodel provides billing company name, address, email fields (cf.cac:AccountingCustomerPartyEN 16931 requirement)InvoiceItemhasitem_name,description,quantity,price,tax_rate_id(cf.cac:InvoiceLine)Modules/Core/Models/TaxRate.phpprovides VAT percentages (cf.cac:TaxTotal)Phase 1 scope (UBL 2.1 generation + download action):
Modules/Invoices/Services/UblExportService.php— converts Invoice → UBL 2.1 XML (EN 16931 mandatory fields minimum, NLCIUS profile identifier optional for Phase 1)EditInvoiceheader (pattern: lines 96-99download_pdfaction) andInvoicestablehorstoeko/ublpackage (research first) or hand-roll with DOMDocumentNote on issue #126: Appears to request the same feature (Peppol/e-invoicing); recommend consolidation if not yet closed.
Time-bound: Phase 1 aimed for Sprint 5 per the plan above.