Skip to content

feat: [SPE-95] Remove prefix for invoiceFields#27

Open
kevin-carangeot wants to merge 3 commits intoSPE-72/opc-migrationfrom
feat/SPE-95
Open

feat: [SPE-95] Remove prefix for invoiceFields#27
kevin-carangeot wants to merge 3 commits intoSPE-72/opc-migrationfrom
feat/SPE-95

Conversation

@kevin-carangeot
Copy link
Copy Markdown

@kevin-carangeot kevin-carangeot commented Apr 13, 2026

Questions Answers
Description? Previously, billing address fields were distinguished from delivery fields by prefixing their names with invoice_ (e.g. invoice_firstname, invoice_id_country). This prefix is now stripped at the PHP mapping stage (mapFieldsByGroup() in OnePageCheckoutForm), so templates and JS always receive clean, unprefixed field names. Disambiguation is handled by DOM section context instead. This PR must be paired with hummingbirdFork#40 which updates the Smarty templates accordingly.
Type? refacto
BC breaks? yes — external code (custom modules, overrides) relying on invoice_ prefixed field names in form submissions or invoiceFields template variables must be updated.
Deprecations? no
Fixed ticket? SPE-95 (internal)
How to test? 1. Go to checkout with 2+ saved addresses and select different delivery and billing addresses → verify the correct addresses are submitted.
2. Go to checkout with 0 saved addresses → fill in the inline delivery form, then the inline billing form → verify both addresses are correctly created.
3. Open the delivery modal, change the country → verify only the delivery section refreshes.
4. Open the billing modal, change the country → verify only the billing section refreshes.
5. Toggle "use same address" → verify the billing section is correctly enabled/disabled.
6. Delete an address from delivery list, then from billing list → verify the correct address type is deleted.

@kevin-carangeot kevin-carangeot self-assigned this Apr 13, 2026
@ps-jarvis
Copy link
Copy Markdown
Collaborator

Hello @kevin-carangeot!

This is your first pull request on ps_onepagecheckout repository of the PrestaShop project.

Thank you, and welcome to this Open Source community!

@github-project-automation github-project-automation Bot moved this to Ready for review in PR Dashboard Apr 13, 2026
@ThbPS
Copy link
Copy Markdown
Collaborator

ThbPS commented Apr 17, 2026

suggestion(non-blocking)

Je propose de merger cette PR à la fin pour éviter des conflits et effets de bords
Sachant que ce ticket n'est pas bloquant

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Ready for review

Development

Successfully merging this pull request may close these issues.

4 participants