reach-digital/magento2-storeresolver
最新稳定版本:1.0.8
Composer 安装命令:
composer require reach-digital/magento2-storeresolver
包简介
README 文档
README
You are running a multi store with a specific catalog per domain.
Installation
composer require reach-digital/magento2-storeresolver
Automatic mapping from Domain > Store View
With the new implementation for the StoreResolverInterface the domains automatically get mapped to the correct store view. This reduces the need to modify code to get new domain names working.
- Register your domain
- Point the A-records to your server
Change index.php, .htaccess or nginx_config file to activate your domain nameStoreResolversolves this for you.
Add Store Code to Base URL
Store code will be removed from URL if added in the Base URL.
Make sure to explicitly set Base URL for Static View Files and Base URL for User Media Files without the store code
| Configuration | Value |
|---|---|
| Base URL | https://www.website.com/de/ |
| Base URL for Static View Files | https://www.website.com/static/ |
| Base URL for User Media Files | https://www.website.com/media/ |
It's not possible to have CMS pages with the same identifier as a store code!
Important note:
Base URLs which have no custom string set after the TLD, must be configured at website level, not on store level, else matching on URL can result in multiple stores, see\Ho\StoreResolver\Model\StoreResolver::getAutoResolvedStore
Store scope definition
| Product | Default | Website | Store Group | Store View |
|---|---|---|---|---|
| Product prices | ✔ | ✔ | ||
| Product tax class | ✔ | ✔ | ||
| Product status | ✔ | ✔ | ||
| Product visibility | ✔ | ✔ | ✔ | |
| Product Inventory | ✔ | |||
| Product attributes / transl. | ✔ | ✔ | ✔ | |
| Base currency | ✔ | ✔ | ||
| (Default) display currency | ✔ | ✔ | ||
| Category settings | ✔ | ✔ | ||
| System configuration settings | ✔ | ✔ | ✔ | |
| Root category configuration | ✔ | |||
| Orders | ✔ | ✔ | ||
| Customers | ✔ | ✔ |
Known issues
Resolving URLs to stores
Store resolving may fail if configured secure/unsecure URLs differ, see \Ho\StoreResolver\Model\StoreUrls::getBaseUrls,
which only uses the unsecure base URL but should probably check the right one depending on Request::isSecure()
统计信息
- 总下载量: 6.78k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 9
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: Unknown
- 更新时间: 2021-07-06