问题
I am developing an e-commerce website where we need to have 2 store views. One for the professional customer and another for the retail customer.
We need to have the same inventory but different product description, different attributes, and look and feel for wholesale/retail customer groups.
回答1:
All of Magento, with its catalog management and display tools, along with themes, is designed with this scenario in mind. Generally you attach a store view with its associated catalog, pricing and inventory to a unique URL (e.g. wholesale.store.com and retail.store.com). Here are blog posts on how to do this in Magento v1.3 and v1.4, however you could take a couple of different approaches.
One option for this is to write a custom module that binds an Observer to the customer_login
event, and then sets a redirect to the Store that you have associated with their Customer Group.
There's nice blog post on how to use Observers in Magento, and a cheat sheet of known Events. You can search Stack Overflow for pointers on starting the development of a custom module. That should get headed in the right direction.
来源:https://stackoverflow.com/questions/3742371/filter-store-view-based-on-customer-group-in-magento