mhinspeya/module-checkout-address
Composer 安装命令:
composer require mhinspeya/module-checkout-address
包简介
Splits checkout street address into Street, House Number, and Address Suffix fields and filters payment methods by shipping method.
README 文档
README
Magento 2 module that customises the checkout address forms and filters available payment methods based on the selected shipping method.
Compatibility
| Magento | PHP |
|---|---|
| 2.4.4 – 2.4.8 | 8.2 · 8.3 · 8.4 |
Features
Street Address Splitting
The default Magento street address field is replaced with three dedicated sub-fields on both the shipping and billing address forms:
| Field | Data Scope | Required | Max Length |
|---|---|---|---|
| Street | street[0] | Yes | 255 |
| House Number | street[1] | Yes | 10 |
| Address Suffix | street[2] | No | 255 |
Field Reordering
The following fields are reordered for a more logical European address layout:
| Field | Sort Order |
|---|---|
| Company | 59 |
| Street (group) | 60 |
| Postcode | 65 |
| City | 70–75 |
Payment Method Filtering
The MethodList plugin filters available payment methods based on the active shipping method:
| Shipping Method | Payment Method Hidden |
|---|---|
tablerate_bestway | checkmo (Check / Money Order) |
| (none selected) | checkmo (Check / Money Order) |
flatrate_flatrate | banktransfer (Bank Transfer) |
Installation
Composer (recommended)
composer require mhinspeya/module-checkout-address
bin/magento module:enable MHinspeya_CheckoutAddress
bin/magento setup:upgrade
bin/magento cache:flush
Manual
- Copy the module files to
app/code/MHinspeya/CheckoutAddress/ - Run:
bin/magento module:enable MHinspeya_CheckoutAddress bin/magento setup:upgrade bin/magento cache:flush
Module Structure
MHinspeya/CheckoutAddress/
├── composer.json
├── registration.php
├── changelog.txt
├── etc/
│ ├── module.xml — Module declaration with sequence dependencies
│ ├── di.xml — Plugin registrations
│ └── acl.xml — ACL resource definitions
├── i18n/
│ └── de_DE.csv — German translations
├── Model/
│ └── Checkout/
│ └── LayoutProcessorPlugin.php — Splits street fields & reorders address form
└── Plugin/
└── Model/
└── MethodList.php — Filters payment methods by shipping method
Plugin Details
LayoutProcessorPlugin
- Type: After-plugin on
Magento\Checkout\Block\Checkout\LayoutProcessor::process() - Registered in:
etc/di.xmlasrewrite-street - Scope: Both shipping and all billing address forms (iterates over all payment method forms)
MethodList
- Type: After-plugin on
Magento\Payment\Model\MethodList::getAvailableMethods() - Registered in:
etc/di.xmlasoverride_method - Sort Order: 10
Translations
The following strings are translatable via __():
| Key | de_DE |
|---|---|
Street | Straße |
House number | Hausnummer |
Address suffix | Adresszusatz |
License
Proprietary — © MHinspeya
统计信息
- 总下载量: 0
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: OSL-3.0
- 更新时间: 2026-06-26