razzzila-dev/module-static-block-by-customer-group
最新稳定版本:1.0.0
Composer 安装命令:
composer require razzzila-dev/module-static-block-by-customer-group
包简介
N/A
README 文档
README
Working with clients sometimes you want to add some privileges for some of them over other. Most simple example is to show the dedicated phone number of support for VIP customers. But it could be any content: images, text, even sliders, etc.
So here is the solution for this problem. Since mostly for displaying some content we use the static blocks, I just added new widget which have "Access Controll List" by Customer groups.
Works with FPC as well.
Installation
Package install
Manual installation
Download archive and unzip it.
Then move all files from module-static-block-by-customer-group folder to the <magento_root>/app/code/Razzzila/StaticBlockACL folder.
Using Composer
Change working directory to <magento_root> and run:
composer require razzzila-dev/module-static-block-by-customer-group bin/magento module:enable Razzzila_StaticBlockACL bin/magento cache:flush
Usage
Let's create 2 blocks: one with default support number inside and another one with a dedicated phone number for VIP customers.
For doing so, in the admin panel open Content -> Blocks and click "Add new block" button. Fill fields and click "Save & Duplicate". Enable block, change Identifier, Block title, and Content (replace with a dedicated number) and click "Save".
Now navigate to Block or Page where you want to put a dynamic block (based on the customer group). In the content editor click on "Insert Widget" and choose "Static Block ACL". The first block will be default one, so choose the block with default phone number and choose groups for whom you want to show it (all except VIP group). The second one will be for VIP customers only. Right after the widget from above create another one but here choose the block with dedicated for VIP customers phone number and choose VIP customer group. Save the page/block.
To apply changes navigate to the Cache Management and Refresh the FPC(Full Page Cache).
Support
This module is not my priority, so in time support not guaranteed. But feel free to open new issues and create pull-requests if needed.
License
统计信息
- 总下载量: 1.02k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 2
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: OSL-3.0
- 更新时间: 2020-02-06