News:

Looking for documentation? Take a look on our wiki

Main Menu

Copy products -> duplicate media

Started by sandomatyas, August 17, 2017, 10:44:23 AM

Previous topic - Next topic

sandomatyas

When I copy a product VM assigns the image of the original product to it, so there will be 2 records in #__virtuemart_product_medias table with the same virtuemart_media_id but different virtuemart_product_ids.
When I open the second product and change the image title, description, meta etc it will change the media's data so the first product will be changed too
I'm just wondering if there is any disadvantages to duplicate the media entry too when a product is copied? Or what is the good solution to fix that? Downloading and re-uploading is a bit old fashion :)

Studio 42

virtuemart_product_medias is to refer to a media, the media description is same for a media used by many products.
So if you really need to have description per product, you have to reupload the image 2 times so you can change description for each product.
Another solution is to get description from the product, but this need of course some change in the PHP files