- Posts: 4
- Thank you received: 0
Start & End Sale Date
Is there a way to make it so the items are hidden instead? So people won't see the items until they are on sale?
Please Log in or Create an account to join the conversation.
file removed, please use the file in the post #128950
Please Log in or Create an account to join the conversation.
Installed the plugin, I enabled it, it gives this error:
Fatal error: Call to undefined method JDatabaseMySQL::isAdmin() in /home/tfcmain/public_html/copy/plugins/hikashop/hide_products.php on line 10
Maybe this matters: we are on Joomla 1.5.23 and Hikashop Business 1.5.3
Thank you.
Please Log in or Create an account to join the conversation.
$app =& Jfactory::getDBO();
should be :
$app =& Jfactory::getApplication();
in that plugin and that will remove that error.
Please Log in or Create an account to join the conversation.
- Posts: 101
- Thank you received: 4
Maybe it is because of the hikashop version (I use the last one), but the plugin doesn't works fine : when I enable it, the product with an old end sale date disappears from the site (front and back). In front it is perfect, but not in backoffice.
If I disable the plugin, I can see the product. So, there are 'just' hidden when the plugin is enabled. But it would be much better if the plugin hide them in front, but not in backoffice. (it would be perfect if the plugin can unpublised these products...)
Please Log in or Create an account to join the conversation.
The plugin is working fine for me. It hides the products only on the frontend if their start date is in the future of if their end date is in the past. That's it. It doesn't remove them from the backend at all.
Please Log in or Create an account to join the conversation.
- Posts: 101
- Thank you received: 4
Ils ne sont pas supprimés, puisque si je désactive le plugin les produits réapparaissent, et en front et en back.
Please Log in or Create an account to join the conversation.
Toutefois vous pouvez l'éditer afin de changer son comportement, pour qu'il change le status des produits qui ne sont pas dans les dates de vente en désactivé.
Pouvez vous coller les lignes présentes dans la fonction "onBeforeProductListingLoad()" de ce plugin ?
Please Log in or Create an account to join the conversation.
- Posts: 101
- Thank you received: 4
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
- Posts: 101
- Thank you received: 4
Please Log in or Create an account to join the conversation.
Here is a version which is compatible with Joomla 3.
Please log in or register to see it.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
I see in the code that it attempts to return if the use is admin
if($app->isAdmin()) return;
but this doesn't seem to work. We are still on hika 2.0
Thanks
Please Log in or Create an account to join the conversation.
I just checked the plugin code, and that should work fine. Are you sure that you don't have an old override or edition present in your code ?
Please Log in or Create an account to join the conversation.
- latest version of joomla
- hika business 2.0
- hide products plug in
Please Log in or Create an account to join the conversation.
$app =& Jfactory::getDBO();
if($app->isAdmin()) return;
I changed this to
$app = JFactory::getApplication();
if($app->isAdmin()) return;
And it started working correctly.
Please Log in or Create an account to join the conversation.
Thanks for the patch.
The weird thing is that, in my side (when I look at the source code of the plugin in our repository), the variable $app is right initialized with the application and not with the DBO.
Regards,
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
www.hikashop.com/support/forum/4-how-to/...ale-date.html#128950
Best regards,
Wouter
Please Log in or Create an account to join the conversation.