loki-checkout / magento2-quote-extended
Store additional quote data in a separate table and link it to the order
Package info
github.com/LokiExtensions/Loki_QuoteExtended
Type:magento2-module
pkg:composer/loki-checkout/magento2-quote-extended
0.0.2
2026-10-29 14:09 UTC
Requires
- php: >=8.2 <8.6
- loki-checkout/magento2-core: ^2.3
- loki/magento2-components: ^2.2
- loki/magento2-field-components: ^2.2
- magento/framework: ^103.0
- magento/module-cron: ^100.4
- magento/module-quote: ^101.2
- magento/module-sales: ^103.0
- magento/module-store: ^101.1
- psr/log: ^1.0 | ^2.0 | ^3.0
Requires (Dev)
- loki/magento2-functional-tests: @dev
- phpunit/phpunit: ^10.5
- yireo/magento2-integration-test-helper: ~0.0
Suggests
None
Provides
None
Conflicts
None
Replaces
None
This package is not auto-updated.
Last update: 2026-11-06 16:33:05 UTC
README
Installation
Install this package via composer:
composer require loki-checkout/magento2-quote-extended
Next, enable this module:
bin/magento module:enable Loki_QuoteExtended
Usage
This module adds a table loki_quote_extended with one row per quote. When the order is placed, the row is linked to the order (order_id).
To store a custom value:
- Add a column to
loki_quote_extendedvia your ownetc/db_schema.xml(plusdb_schema_whitelist.json). - Add a field block to the Loki Checkout whose name ends with the column name (e.g.
loki-checkout.customer.example_field), using the templateLoki_FieldComponents::form/field.phtml. - Register the block in your
etc/loki_components.xmlwith the groupquoteExtendedFields.
To display the value:
- Frontend (current quote):
Loki\QuoteExtended\ViewModel\CheckoutQuoteExtendedView::getValue('example_field') - Admin order and invoice pages:
Loki\QuoteExtended\ViewModel\Adminhtml\OrderQuoteExtendedView::getValue('example_field') - Order and invoice emails:
{{var loki_quote_extended.example_field}}
See Loki_QuoteExtendedExample for a complete example.