- Posts: 465
- Thank you received: 19
Suggestion plugin reminder
- Reincidente
-
Topic Author
- Offline
Less
More
3 years 11 months ago #345737
by Reincidente
Suggestion plugin reminder was created by Reincidente
Hi Nicolas.
I would like to make a suggestion about the Reminder plugin.
When a user deletes all items from their shopping cart and is left with 0 products, when the Hikashop cron is triggered it also sends a shopping cart reminder, even though the cart contains no products.
Could an "if" be added where if the number of products in the cart is 0, the reminder is not sent?
I would like to make a suggestion about the Reminder plugin.
When a user deletes all items from their shopping cart and is left with 0 products, when the Hikashop cron is triggered it also sends a shopping cart reminder, even though the cart contains no products.
Could an "if" be added where if the number of products in the cart is 0, the reminder is not sent?
Please Log in or Create an account to join the conversation.
3 years 11 months ago #345738
by nicolas
Replied by nicolas on topic Suggestion plugin reminder
Hi,
There is already the code to check that the cart is not empty before sending a reminder notification for it with the code:
in the file plugins/hikashop/reminder/reminder.php of the reminder plugin.
So I'm surprised you're saying this.
There is already the code to check that the cart is not empty before sending a reminder notification for it with the code:
Code:
// skip cart if the cart has no products
$this->db->setQuery('SELECT * FROM #__hikashop_cart_product WHERE cart_id = '.$cart->cart_id);
$products = $this->db->loadObjectList();
if(empty($products))
return false;
$hasProducts = false;
foreach($products as $p) {
if($p->cart_product_quantity>0) {
$hasProducts = true;
break;
}
}
if(!$hasProducts)
return false;
So I'm surprised you're saying this.
Please Log in or Create an account to join the conversation.
- Reincidente
-
Topic Author
- Offline
Less
More
- Posts: 465
- Thank you received: 19
3 years 11 months ago #345774
by Reincidente
Replied by Reincidente on topic Suggestion plugin reminder
attached shipping
Please Log in or Create an account to join the conversation.
3 years 11 months ago #345777
by nicolas
Replied by nicolas on topic Suggestion plugin reminder
Hi,
Could you go in the Customers>Carts menu in your backend and open the details of the cart corresponding to this email and provide a screenshot of what you see there ?
I suppose it must be a special case we forgot about but without knowing more about the cart, it's hard to say what it could be.
Could you go in the Customers>Carts menu in your backend and open the details of the cart corresponding to this email and provide a screenshot of what you see there ?
I suppose it must be a special case we forgot about but without knowing more about the cart, it's hard to say what it could be.
Please Log in or Create an account to join the conversation.
- Reincidente
-
Topic Author
- Offline
Less
More
- Posts: 465
- Thank you received: 19
3 years 11 months ago #345781
by Reincidente
Replied by Reincidente on topic Suggestion plugin reminder
I have deleted this shopping cart.
I try to do this when I see empty shopping carts to avoid the email.
I try to do this when I see empty shopping carts to avoid the email.
Please Log in or Create an account to join the conversation.
Time to create page: 0.211 seconds