News:

Support the VirtueMart project and become a member

Main Menu

Override stockable plug-in

Started by Matt_Ginn, January 21, 2014, 16:45:56 PM

Previous topic - Next topic

Matt_Ginn

Hi. I made some changes to stockable.php in plugins/vmcustom/stockable to display stock levels of child products created using the stockable variant plug-in. Is there any way of making this an override so that it doesn't get overwritten when Virtuemart gets updated??

jenkinhill

It is a standard Jpoomla plugin so that is a Joomla issue,  see here.
Kelvyn
Lowestoft, Suffolk, UK

Retired from forum life November 2023

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

mhuebler

hello Matt_Ginn,

do you can share your changes to display the stock level of child products with stockable plugin ? i search a long time for a solutionn :-(

stanza_nate

I know this is an old thread, but this is the only thing I could find when I searched for this problem and I figured it could help future people...

jenkinhill, that answer is totally not helpful, there are no helpful links for this particular file in that search. The reason for that is this plugin is not overridable as it doesn't contain a /tmpl/ folder - it is just in plugins/vmcustom/stockable/ This means the only way to change it is to just edit the file, keep a backup and replace it every time you update Virtuemart/Joomla.

The problem I've run into (which is different to OP's by what I can tell), and how I came across this thread is that there is inline CSS within the stockable.php file, meaning that the product option descriptors (under the div stockableBlockIndex-**-*, where * changes with each item) are set as black by default with no way to override it via template CSS. With a dark background, as I have, it's unreadable and looks terrible.

If anyone comes across this post that can point me in the right direction to contribute some code to fix this problem in a future release, I'd be more than happy to donate some of my time!