Page 1 of 1

Agilemultiseller - low stock alert for sellers

PostPosted: Sat May 21, 2016 1:48 pm
by carlo.macis_15320
Would be good to have an alert email to sellers when stock is running low so they can re-order and update the product

Re: Agilemultiseller - low stock alert for sellers

PostPosted: Mon May 23, 2016 2:36 pm
by shokinro
you may try to customize PrestaaShop mailalert module for that purpose.

1. You can get seller email address by following
$id_seller = AgileSellerManager::getObjectOwnerID('product', $id_product);
$seller = new Employee($id_seller);

2. look for following lines in mailalerts.php, and then try to replace the mail recipient by email address.

Mail::Send(
$id_lang,
'productoutofstock',
Mail::l('Product out of stock', $id_lang),
$template_vars,
$seller->email,
null,.......................