I'm looking for a solution to make products visibile/invisible per customer. There are some extension to limit the visibility of products per customer group, but I cant find a solution to set the visibility per customer.
Does anyone know a solution for this?
One way is integrating the extension as mentioned in the question itself.
A work-around would be to add a custom product attribute and we can add a code to check the logged-in customer group in the
app/design/frontend/package/theme/template/catalog/product/list.phtml
using
Mage::getSingleton('customer/session')->getCustomerGroupId();
and load the product collection which would filter out the products on the basis of the custom attributes using
$collection->addAttributeToFilter();
In my opinion this would be the easiest way to do this.
Related
I am new to magento and looking for a solution. Is it possible to filter related products based on some of it's attributes on the product view page? I have a product and there are 100s of related products associated with it. I want customers to filter these related products based on their attributes on the product view page itself. Is it possible? Please help me.
Regards, Pallab
The template (Magento 1.9.1.0 version) for this is located in: frontend/your_package/your_theme/template/catalog/product/list/related.phtml template and the Block class associated with this template is: Mage/Catalog/Block/Product/List/Related.php and the method is: protected function _prepareData() where the related products collection is being fetched. You will have to setup your filters as you need, most likely by using JavaScript and finding the products that match the selected (filtered) attributes by the customer.
For more thorough answer, I will need more information about how these filters should look like and work.
Hi we are using magento for a wholesale site, in which every product can be ordered in two ways:
1)carton(small-box)
2)Pallet(larger-one)
Now as per magento rules we achieved the same by creating a bundle product for each product, but in doing so we need to add 3-products for a single product, also the SKU is actually the same for all!
Is there any better solution to this other than bundle?
I tried with the configurable option too, but same problem of adding 3-products for a single product.
Thanks.
Creating a bundle product is the correct way to deal with this. In your case, the carton and the pallet are two separate products (from Magento's point of view).
I had set up a "Store Owner" role in Magento. Users with that role will be able to add/edit/delete products only.
What I need is some one to tell me how can I limit these users to see only their products in the list when they go to Catalog -> Manage Products ?
I want to achieve this with code editing if possible.
Also note that all users are using the same store.
Thanks
This is not an "out of the box" feature in Magento Community Edition (or Enterprise), so you'll need to write some code to make this work.
In general terms you'll want to:
Add a (hidden?) attribute to the product to store the User Id of the product "owner".
Write an event observer for catalog_product_save_before which assigns the current user's User Id field to the new product owner attribute.
Rewrite the _prepareCollection or _addColumnFilterToCollection methods of Mage_Adminhtml_Block_Catalog_Product_Grid to add the product_owner attribute to the collection and filter it to just the current user.
That will ensure that the only products that appear in the grid for a given user are the products they own. However, I would also implement an observer on the controller_action_predispatch_adminhtml_catalog_product_edit and controller_action_predispatch_adminhtml_catalog_product_save events to check the product owner value on products before they're edited/saved to make sure the user hasn't tried to edit a product that doesn't appear on the grid.
If you need any further assistance with adding attributes, setting up block rewrites, or creating event observers, I'm sure those questions have already been answered on SO, this question is a bit too broad to answer at that level of detail.
I have to create filter option, which is related product. But I am not getting an idea about it. I have attach image url for reference. Here are product listing, which are related product. And I have to use related product in filter option
http://www.image-maps.com/uploaded_files/5201307260938309_Capture.PNG
Please help me asap.
The simple way would be to define a new product attribute to filter by. You could do a multiselect with all the potential related products and set Use In Layered Navigation to Yes.
I am working on a Magento project and I need to know if there is a way to make a product's options independent to each other or unrequired. I need to use one of several at a time (I have 6 dropdowns).
I have tried add to cart by query string but all dropdown values were still required. I also tried to make all the options default, then modify the selected options in the observer, but I did not meet with success. See the screenshot below for more details.
Any help will be appreciated
Screenshot http://secure.justhost.com/~sharpwe1/img/imf.png
Configurable Products in Magneto are only parent products of Simple Products. Whatever you have as an attribute of a Configurable - a Simple Product has to be present for each. To do this out of the box in Magento, you should be looking into setting up a Simple Product with Custom Options.