Recommended PrestShop Version

Thanks for choosing Agile.
For customers using our Agile Multiple Seller module and its accessry modules, we highly recommend to use PrestaShop 1.6x or 1.7.5 or lower. PrestaShop has made some changes in versions higher than 1.7.6 that makes it possible or very difficult to implement some of features via hooks, or override, since required hooks or override is not available.

Sept. 05, 2019

PLEASE NOTE:

This is only for prestashop 1.3x. (No chnages are required for PrestaShop 1.4x or higher)

After version 1.2.2, the Agile PrestaShop Pickup Center module has added following feaures (since 2012.03.12):

* You are able to indlude pickup locations in the order confirmation email
* You can set an email for pickup location
* The order confirmation email will also be sent to the pickup locations if there is email address set for the location

Those feature will be available automatically without any changes for PrestaShop 1.4x or higher versions.  However, if you are using PrestaShop 1.3x, you will need to manually make some code changes to enable these new features.

Pickup location inlcuded in order confirmation email, also send to pickup location if there is an email address set for the location:

 

agilepickupcenter-screen6-order-confirmation-eamil

 

 

Please follow the instructions below to modify the PaymentModule.php file.

File location:
YourStoreRoot/classes/PaymentModule.php

Look for the following two lines in the validateOrder() function:


  if (Validate::isEmail($customer->email))
         Mail::Send((int)($order->id_lang), 'order_conf', Mail::l('Order confirmation'), $data, $customer->email, $customer->firstname.' '.$customer->lastname, NULL, NULL, $fileAttachment);

Insert followinfg lines of code BEFORE the above lines of code:

///begin-Agile Pickup center module pickup location hookup

if(Module::isInstalled('agilepickupcenter'))
    {
        require_once(_PS_ROOT_DIR_  . "/modules/agilepickupcenter/agilepickupcenter.php");
        $amodule = new AgilePickupCenter();
        $data = $amodule->transform_mail_data($data);
        if(isset($data['{carrier_email}']) AND Validate::isEmail($data['{carrier_email}']))
            Mail::Send((int)$order->id_lang, 'order_conf', Mail::l('Order confirmation', $order->id_lang), $data, $data['{carrier_email}'], $customer->firstname.' '.$customer->lastname, NULL, NULL, $fileAttachment);
                   
}
///end - Agile Pickup center module pickup location hookup



You should be all set.
The location informaiton will be included with the carrier information in the order confirmation email.