how can I set all associated products in a group product be set 'not visible individually' in bulk?
Magento – Set all associated product not visible individually
massactionproductproducts-management
massactionproductproducts-management
how can I set all associated products in a group product be set 'not visible individually' in bulk?
Best Answer
Just a rough guide as this code has been covered a plenty ;)
You can create a shell script to do this (see the shell folder). For an example look at /shell/log.php, all you'd really need is the run method in your shell script where the work is done.
Have a look at this post: https://stackoverflow.com/questions/8579765/magento-how-do-i-get-associated-products-of-product-group From it you will find how to create a collection (of grouped products), and then get the associated products from that collection.
You then simply iterate over the associated products, and set the visibility of each product.
$product->setVisibility(Mage_Catalog_Model_Product_Visibility::VISIBILITY_BOTH);