33 lines
887 B
PHP
33 lines
887 B
PHP
<?php
|
|
/**
|
|
* Module Partial Shipment - Main file
|
|
*
|
|
* @author My Addons <contact@myaddons.io>
|
|
* @copyright 2017 My Addons
|
|
* @license myaddons.io
|
|
* @version 1.0.0
|
|
* @since File available since Release 1.0
|
|
*/
|
|
|
|
class BtPartialShipmentGenerateDeliverySlipModuleFrontController extends ModuleFrontController
|
|
{
|
|
public function __construct()
|
|
{
|
|
parent::__construct();
|
|
}
|
|
|
|
public function displayAjaxOrder()
|
|
{
|
|
if (!Tools::getValue('token') || Tools::getValue('token') != Tools::getAdminToken('btpartialshipment')) {
|
|
die('error');
|
|
}
|
|
|
|
if (!Tools::getValue('idPartialShipment')) {
|
|
d('Invalid request from:' . $_SERVER["REMOTE_ADDR"]);
|
|
} else {
|
|
$moduleInstance = Module::getInstanceByName('btpartialshipment');
|
|
$moduleInstance->generatePartialPDF();
|
|
}
|
|
}
|
|
}
|