tnt
This commit is contained in:
parent
f0c1e7b7eb
commit
dc0edebeb0
Binary file not shown.
167
www/modules/tntofficiel/classes/TNTOfficielCart.php
Normal file
167
www/modules/tntofficiel/classes/TNTOfficielCart.php
Normal file
@ -0,0 +1,167 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
|
||||
/**
|
||||
* Class TNTOfficielCart
|
||||
*/
|
||||
class TNTOfficielCart extends ObjectModel
|
||||
{
|
||||
// id_tntofficiel_cart
|
||||
public $id;
|
||||
|
||||
public $id_cart;
|
||||
public $carrier_code;
|
||||
public $carrier_label;
|
||||
public $delivery_point;
|
||||
public $delivery_price;
|
||||
public $customer_email;
|
||||
public $customer_mobile;
|
||||
public $address_building;
|
||||
public $address_accesscode;
|
||||
public $address_floor;
|
||||
|
||||
public static $definition = array(
|
||||
'table' => 'tntofficiel_cart',
|
||||
'primary' => 'id_tntofficiel_cart',
|
||||
'fields' => array(
|
||||
'id_cart' => array(
|
||||
'type' => ObjectModel::TYPE_INT,
|
||||
'validate' => 'isUnsignedId',
|
||||
'required' => true
|
||||
),
|
||||
'carrier_code' => array(
|
||||
'type' => ObjectModel::TYPE_STRING,
|
||||
'size' => 64
|
||||
),
|
||||
'carrier_label' => array(
|
||||
'type' => ObjectModel::TYPE_STRING,
|
||||
'size' => 255
|
||||
),
|
||||
'delivery_point' => array(
|
||||
'type' => ObjectModel::TYPE_STRING
|
||||
/*, 'validate' => 'isSerializedArray', 'size' => 65000*/
|
||||
),
|
||||
'delivery_price' => array(
|
||||
'type' => ObjectModel::TYPE_FLOAT,
|
||||
'validate' => 'isPrice'
|
||||
),
|
||||
'customer_email' => array(
|
||||
'type' => ObjectModel::TYPE_STRING,
|
||||
'validate' => 'isEmail',
|
||||
'size' => 128
|
||||
),
|
||||
'customer_mobile' => array(
|
||||
'type' => ObjectModel::TYPE_STRING,
|
||||
'validate' => 'isPhoneNumber',
|
||||
'size' => 32
|
||||
),
|
||||
'address_building' => array(
|
||||
'type' => ObjectModel::TYPE_STRING,
|
||||
'size' => 16
|
||||
),
|
||||
'address_accesscode' => array(
|
||||
'type' => ObjectModel::TYPE_STRING,
|
||||
'size' => 16
|
||||
),
|
||||
'address_floor' => array(
|
||||
'type' => ObjectModel::TYPE_STRING,
|
||||
'size' => 16
|
||||
),
|
||||
),
|
||||
);
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*/
|
||||
public function __construct($intArgId = null)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
parent::__construct($intArgId);
|
||||
}
|
||||
|
||||
public static function loadCartID($intArgCartId)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$intCartId = (int)$intArgCartId;
|
||||
|
||||
// No new cart ID.
|
||||
if (!($intCartId > 0)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Search row for cart ID.
|
||||
$objDbQuery = new DbQuery();
|
||||
$objDbQuery->select('*');
|
||||
$objDbQuery->from(TNTOfficielCart::$definition['table']);
|
||||
$objDbQuery->where('id_cart = '.$intCartId);
|
||||
|
||||
$objDB = Db::getInstance();
|
||||
$arrResult = $objDB->executeS($objDbQuery);
|
||||
// If row found and match cart ID.
|
||||
if (count($arrResult)===1 && $intCartId===(int)$arrResult[0]['id_cart']) {
|
||||
// Load existing TNT cart entry.
|
||||
$objTNTCartModel = new TNTOfficielCart((int)$arrResult[0]['id_tntofficiel_cart']);
|
||||
} else {
|
||||
// Create a new TNT cart entry.
|
||||
$objTNTCartModel = new TNTOfficielCart();
|
||||
$objTNTCartModel->id_cart = $intCartId;
|
||||
$objTNTCartModel->save();
|
||||
}
|
||||
|
||||
// Check.
|
||||
if ((int)$objTNTCartModel->id_cart !== $intCartId) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return $objTNTCartModel;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return array
|
||||
*/
|
||||
public function getDeliveryPoint()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$arrDeliveryPoint = Tools::unSerialize($this->delivery_point);
|
||||
if (!is_array($arrDeliveryPoint)) {
|
||||
$arrDeliveryPoint = array();
|
||||
}
|
||||
|
||||
return $arrDeliveryPoint;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $arrArgDeliveryPoint
|
||||
* @return mixed
|
||||
*/
|
||||
public function setDeliveryPoint($arrArgDeliveryPoint)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
if (!is_array($arrArgDeliveryPoint)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (isset($arrArgDeliveryPoint['xett'])) {
|
||||
unset($arrArgDeliveryPoint['pex']);
|
||||
} elseif (isset($arrArgDeliveryPoint['pex'])) {
|
||||
unset($arrArgDeliveryPoint['xett']);
|
||||
} else {
|
||||
$arrArgDeliveryPoint = array();
|
||||
}
|
||||
|
||||
$this->delivery_point = serialize($arrArgDeliveryPoint);
|
||||
return $this->save();
|
||||
}
|
||||
}
|
18
www/modules/tntofficiel/classes/index.php
Normal file
18
www/modules/tntofficiel/classes/index.php
Normal file
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../');
|
||||
exit;
|
@ -0,0 +1,256 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/tntofficiel.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_PasswordManager.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/helper/TNTOfficiel_ShipmentHelper.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/pdf/manifest/TNTOfficiel_ManifestPDF.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/pdf/manifest/TNTOfficiel_ManifestPDFGenerator.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/pdf/manifest/HTMLTemplateTNTOfficielManifest.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/pdf/manifest/TNTOfficiel_ManifestPDFCreator.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/exceptions/TNTOfficiel_MaxPackageWeightException.php';
|
||||
|
||||
// <TABNAME>Controller
|
||||
class AdminTNTOfficielController extends ModuleAdminController
|
||||
{
|
||||
/**
|
||||
* Constructor.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
// _PS_MODULE_DIR_.$this->module->name.'/views/templates/admin/'
|
||||
// default : 'content.tpl';
|
||||
$this->template = 'AdminTNTOfficiel.tpl';
|
||||
|
||||
parent::__construct();
|
||||
}
|
||||
|
||||
/**
|
||||
* Add css files.
|
||||
*/
|
||||
public function setMedia()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->addCSS(_MODULE_DIR_.$this->module->name.'/views/css/AdminTNTOfficiel.css', 'all');
|
||||
$this->addCSS(_MODULE_DIR_.$this->module->name.'/views/css/style.css');
|
||||
parent::setMedia();
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function createTemplate($tpl_name)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->context->smarty->assign(array(
|
||||
'username' => Configuration::get('TNT_CARRIER_USERNAME'),
|
||||
'account' => Configuration::get('TNT_CARRIER_ACCOUNT'),
|
||||
'password' => TNTOfficiel_PasswordManager::getHash(),
|
||||
'middlewareUrl' => Configuration::get('TNT_CARRIER_MIDDLEWARE_SHORT_URL'),
|
||||
));
|
||||
|
||||
if (file_exists($this->getTemplatePath().$tpl_name) && $this->viewAccess()) {
|
||||
return $this->context->smarty->createTemplate($this->getTemplatePath().$tpl_name, $this->context->smarty);
|
||||
}
|
||||
|
||||
return parent::createTemplate($tpl_name);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generate the manifest for an order (download).
|
||||
*/
|
||||
public function processGetManifest()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$objManifestPDF = new TNTOfficiel_ManifestPDFCreator();
|
||||
$intOrderID = (int)Tools::getValue('id_order');
|
||||
$arrOrderIDList = array($intOrderID);
|
||||
$objManifestPDF->createManifest($arrOrderIDList);
|
||||
|
||||
// We want to be sure that displaying PDF is the last thing this controller will do.
|
||||
exit;
|
||||
}
|
||||
|
||||
/**
|
||||
* Downloads an archive containing all the logs files.
|
||||
* /_admin/index.php?controller=AdminTNTOfficiel&action=downloadLogs
|
||||
*/
|
||||
public function processDownloadLogs()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$strLogPath = _PS_MODULE_DIR_.TNTOfficiel::MODULE_NAME.'/'.TNTOfficiel::LOG_DIR;
|
||||
$zipName = 'logs.zip';
|
||||
// Remove Existing.
|
||||
if (file_exists($strLogPath.$zipName)) {
|
||||
unlink($strLogPath.$zipName);
|
||||
}
|
||||
// Create Zip file.
|
||||
TNTOfficiel_Logger::getZip($strLogPath.$zipName);
|
||||
// Download.
|
||||
header('Content-Type: application/zip');
|
||||
header('Content-disposition: attachment; filename='.$zipName);
|
||||
header('Content-Length: '.filesize($strLogPath.$zipName));
|
||||
// Get Content.
|
||||
readfile($strLogPath.$zipName);
|
||||
|
||||
// We want to be sure that displaying PDF is the last thing this controller will do.
|
||||
exit;
|
||||
}
|
||||
|
||||
/**
|
||||
* Add a parcel.
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function displayAjaxAddParcel()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$fltWeight = (float)Tools::getValue('weight');
|
||||
$intOderID = (int)Tools::getValue('orderId');
|
||||
|
||||
$arrResult = array();
|
||||
try {
|
||||
$arrResult['parcel'] = TNTOfficiel_ParcelsHelper::getInstance()->addParcel($intOderID, $fltWeight, false);
|
||||
$arrResult['result'] = true;
|
||||
} catch (TNTOfficiel_MaxPackageWeightException $objException) {
|
||||
$arrResult['result'] = false;
|
||||
$arrResult['error'] = $objException->getMessage();
|
||||
} catch (Exception $objException) {
|
||||
$objFileLogger = new FileLogger();
|
||||
$objFileLogger->setFilename(_PS_ROOT_DIR_.'/log/'.date('Ymd').'_tnt_exception.log');
|
||||
$objFileLogger->logError($objException->getMessage());
|
||||
$arrResult['result'] = false;
|
||||
}
|
||||
|
||||
echo Tools::jsonEncode($arrResult);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Remove a parcel.
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function displayAjaxRemoveParcel()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$intParcelID = (int)Tools::getValue('parcelId');
|
||||
|
||||
$arrResult = array();
|
||||
try {
|
||||
$arrResult['result'] = TNTOfficiel_ParcelsHelper::getInstance()->removeParcel($intParcelID);
|
||||
} catch (Exception $objException) {
|
||||
$objFileLogger = new FileLogger();
|
||||
$objFileLogger->setFilename(_PS_ROOT_DIR_.'/log/'.date('Ymd').'_tnt_exception.log');
|
||||
$objFileLogger->logError($objException->getMessage());
|
||||
$arrResult['result'] = false;
|
||||
}
|
||||
|
||||
echo Tools::jsonEncode($arrResult);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Update a parcel.
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function displayAjaxUpdateParcel()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$intParcelID = (int)Tools::getValue('parcelId');
|
||||
$fltWeight = (float)Tools::getValue('weight');
|
||||
$intOderID = (int)Tools::getValue('orderId');
|
||||
|
||||
try {
|
||||
$arrResult = TNTOfficiel_ParcelsHelper::getInstance()->updateParcel($intParcelID, $fltWeight, $intOderID);
|
||||
} catch (TNTOfficiel_MaxPackageWeightException $objException) {
|
||||
$arrResult['result'] = false;
|
||||
$arrResult['error'] = $objException->getMessage();
|
||||
} catch (Exception $objException) {
|
||||
$objFileLogger = new FileLogger();
|
||||
$objFileLogger->setFilename(_PS_ROOT_DIR_.'/log/'.date('Ymd').'_tnt_exception.log');
|
||||
$objFileLogger->logError($objException->getMessage());
|
||||
$arrResult['result'] = false;
|
||||
}
|
||||
|
||||
echo Tools::jsonEncode($arrResult);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks the shipping.
|
||||
*/
|
||||
public function displayAjaxCheckShippingDateValid()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$intOrderID = (int)Tools::getValue('orderId');
|
||||
$strShippingDate = pSQL(Tools::getValue('shippingDate'));
|
||||
|
||||
$arrPostDate = explode('/', $strShippingDate);
|
||||
$strFormatedShippingDate = $arrPostDate[2].'-'.$arrPostDate[1].'-'.$arrPostDate[0];
|
||||
|
||||
$objTNTShipmentHelper = TNTOfficiel_ShipmentHelper::getInstance();
|
||||
$arrMDWShippingDate = $objTNTShipmentHelper->checkSaveShipmentDate($intOrderID, $strFormatedShippingDate);
|
||||
if (!is_array($arrMDWShippingDate)) {
|
||||
echo Tools::jsonEncode(array('error' => $arrMDWShippingDate));
|
||||
|
||||
return false;
|
||||
}
|
||||
if (array_key_exists('error', $arrMDWShippingDate)) {
|
||||
if ($arrMDWShippingDate['error'] == 1) {
|
||||
echo Tools::jsonEncode(array('error' => $arrMDWShippingDate['message']));
|
||||
|
||||
return false;
|
||||
} else {
|
||||
$arrMDWShippingDate['shippingDate'] = $strFormatedShippingDate;
|
||||
/* $tntDate['dueDate'] = ""; */
|
||||
}
|
||||
}
|
||||
|
||||
$arrTNTOrder = TNTOfficiel_OrderHelper::getInstance()->getOrderData($intOrderID);
|
||||
Db::getInstance()->update(
|
||||
'tntofficiel_order',
|
||||
array(
|
||||
'shipping_date' => pSQL($arrMDWShippingDate['shippingDate']),
|
||||
'due_date' => pSQL($arrMDWShippingDate['dueDate'])
|
||||
),
|
||||
'id_tntofficiel_order = '.(int)$arrTNTOrder['id_tntofficiel_order']
|
||||
);
|
||||
|
||||
if (!$arrMDWShippingDate['dueDate']) {
|
||||
$arrResult = array();
|
||||
} else {
|
||||
$tempDate = explode('-', $arrMDWShippingDate['dueDate']);
|
||||
$arrResult = array('dueDate' => $tempDate[2].'/'.$tempDate[1].'/'.$tempDate[0]);
|
||||
}
|
||||
|
||||
if (array_key_exists('message', $arrMDWShippingDate)) {
|
||||
$arrResult['mdwMessage'] = $arrMDWShippingDate['message'];
|
||||
}
|
||||
|
||||
echo Tools::jsonEncode($arrResult);
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
18
www/modules/tntofficiel/controllers/admin/index.php
Normal file
18
www/modules/tntofficiel/controllers/admin/index.php
Normal file
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../');
|
||||
exit;
|
187
www/modules/tntofficiel/controllers/front/address.php
Normal file
187
www/modules/tntofficiel/controllers/front/address.php
Normal file
@ -0,0 +1,187 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/classes/TNTOfficielCart.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/helper/TNTOfficiel_AddressHelper.php';
|
||||
|
||||
class TNTOfficielAddressModuleFrontController extends ModuleFrontController
|
||||
{
|
||||
/**
|
||||
* These constants are use in cpCityHelper.js
|
||||
* Any change must be impacted in this file as well.
|
||||
*/
|
||||
const CHECK_POSTCODE_KO = 0; // postcode/city is not valid
|
||||
const CHECK_POSTCODE_OK = 1; // postcode/city is valid
|
||||
const CHECK_POSTCODE_NOT_REQUIRED = 2; // postcode/city does not require validation
|
||||
|
||||
/**
|
||||
* TNTOfficielAddressModuleFrontController constructor.
|
||||
* Controller always used for AJAX response.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
parent::__construct();
|
||||
|
||||
// No header/footer.
|
||||
$this->ajax = true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Saves the extra address data.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function displayAjaxStoreDeliveryInfo()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
// Saves the extra address data.
|
||||
$arrFormErrors = TNTOfficiel_Address::validate($_POST);
|
||||
if (count($arrFormErrors)) {
|
||||
echo Tools::jsonEncode(array(
|
||||
'result' => false,
|
||||
'form_errors' => $arrFormErrors,
|
||||
));
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
$objContext = $this->context;
|
||||
$objCart = $objContext->cart;
|
||||
$intCartID = (int)$objCart->id;
|
||||
|
||||
// Load TNT cart info or create a new one for it's ID.
|
||||
$objTNTCartModel = TNTOfficielCart::loadCartID($intCartID);
|
||||
$boolResult = false;
|
||||
if (Validate::isLoadedObject($objTNTCartModel)) {
|
||||
$objTNTCartModel->hydrate(array(
|
||||
'customer_email' => pSQL(Tools::getValue('email')),
|
||||
'customer_mobile' => pSQL(Tools::getValue('mobile_phone')),
|
||||
'address_building' => pSQL(Tools::getValue('building_number')),
|
||||
'address_accesscode' => pSQL(Tools::getValue('intercom_code')),
|
||||
'address_floor' => pSQL(Tools::getValue('floor')),
|
||||
));
|
||||
$boolResult = $objTNTCartModel->save();
|
||||
}
|
||||
|
||||
if (!$boolResult) {
|
||||
echo Tools::jsonEncode(array(
|
||||
'result' => false,
|
||||
'form_errors' => 'Une erreur s\'est produite',
|
||||
));
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
echo Tools::jsonEncode(array(
|
||||
'result' => true,
|
||||
));
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if the city match the.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function displayAjaxCheckPostcodeCity()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$arrResult = array();
|
||||
// check the country
|
||||
$intCountryID = (int)Tools::getValue('countryId');
|
||||
$strPostCode = pSQL(Tools::getValue('postcode'));
|
||||
$strCity = pSQL(Tools::getValue('city'));
|
||||
|
||||
if (Country::getIsoById($intCountryID) != 'FR' || Tools::strlen($strPostCode) != 5) {
|
||||
$arrResult['result'] = false;
|
||||
$arrResult['resultCode'] = TNTOfficielAddressModuleFrontController::CHECK_POSTCODE_NOT_REQUIRED;
|
||||
} else {
|
||||
$objTNTAddressHelper = TNTOfficiel_AddressHelper::getInstance();
|
||||
//check the city/postcode
|
||||
$mdwResult = $objTNTAddressHelper->checkPostcodeCityFromMiddleware(
|
||||
$strPostCode,
|
||||
$strCity,
|
||||
$this->context->shop->id
|
||||
);
|
||||
if (!$mdwResult['response']) {
|
||||
//get cities from the middleware from the given postal code
|
||||
$mdwResult = $objTNTAddressHelper->getCitiesFromMiddleware(
|
||||
$strPostCode,
|
||||
$this->context->shop->id
|
||||
);
|
||||
$arrResult['result'] = false;
|
||||
$arrResult['cities'] = $mdwResult['cities'];
|
||||
$arrResult['resultCode'] = TNTOfficielAddressModuleFrontController::CHECK_POSTCODE_KO;
|
||||
} else {
|
||||
$arrResult['result'] = true;
|
||||
$arrResult['resultCode'] = TNTOfficielAddressModuleFrontController::CHECK_POSTCODE_OK;
|
||||
}
|
||||
}
|
||||
|
||||
echo Tools::jsonEncode($arrResult);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get cities for a postcode.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function displayAjaxGetCities()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$cart = $this->context->cart;
|
||||
$deliveryAddress = new Address($cart->id_address_delivery);
|
||||
$mdwResult = TNTOfficiel_AddressHelper::getInstance()->getCitiesFromMiddleware(
|
||||
$deliveryAddress->postcode,
|
||||
$this->context->shop->id
|
||||
);
|
||||
|
||||
echo Tools::jsonEncode(array(
|
||||
'result' => true,
|
||||
'cities' => $mdwResult['cities'],
|
||||
'postcode' => $deliveryAddress->postcode
|
||||
));
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Update the city for the current delivery address.
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function displayAjaxUpdateDeliveryAddress()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$strCity = pSQL(Tools::getValue('city'));
|
||||
|
||||
if ($strCity) {
|
||||
$objCart = $this->context->cart;
|
||||
$objAddressDelivery = new Address($objCart->id_address_delivery);
|
||||
$objAddressDelivery->city = $strCity;
|
||||
$objAddressDelivery->save();
|
||||
}
|
||||
|
||||
echo Tools::jsonEncode(array(
|
||||
'result' => true
|
||||
));
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
160
www/modules/tntofficiel/controllers/front/carrier.php
Normal file
160
www/modules/tntofficiel/controllers/front/carrier.php
Normal file
@ -0,0 +1,160 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/tntofficiel.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Carrier.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/helper/TNTOfficiel_CarrierHelper.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/classes/TNTOfficielCart.php';
|
||||
|
||||
class TNTOfficielCarrierModuleFrontController extends ModuleFrontController
|
||||
{
|
||||
/**
|
||||
* TNTOfficielCarrierModuleFrontController constructor.
|
||||
* Controller always used for AJAX response.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
parent::__construct();
|
||||
|
||||
// No header/footer.
|
||||
$this->ajax = true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Store in session the tnt carrier name and store its price.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function displayAjaxStoreProductPrice()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$objContext = $this->context;
|
||||
$objCart = $objContext->cart;
|
||||
$intCartID = (int)$objCart->id;
|
||||
|
||||
$strProductCode = pSQL(Tools::getValue('productCode'));
|
||||
|
||||
$objTNTCarrierHelper = TNTOfficiel_CarrierHelper::getInstance();
|
||||
$arrAvailableTNTCarriers = $objTNTCarrierHelper->getMDWTNTCarrierList($objContext->customer);
|
||||
$boolCarrierIsValid = false;
|
||||
$arrTNTCarrier = null;
|
||||
|
||||
if (!empty($arrAvailableTNTCarriers) && !empty($arrAvailableTNTCarriers['products'])) {
|
||||
foreach ($arrAvailableTNTCarriers['products'] as $arrTNTCarrier) {
|
||||
$arrTNTCarrier['label'] = '';
|
||||
if (strpos($arrTNTCarrier['type'], 'ENTERPRISE') !== false) {
|
||||
if (strpos($arrTNTCarrier['code'], 'A') !== false) {
|
||||
$arrTNTCarrier['label'] = '09:00 Express en Entreprise';
|
||||
} elseif (strpos($arrTNTCarrier['code'], 'J') !== false) {
|
||||
$arrTNTCarrier['label'] = 'En entreprise';
|
||||
} elseif (strpos($arrTNTCarrier['code'], 'M') !== false) {
|
||||
$arrTNTCarrier['label'] = '12:00 Express en Entreprise';
|
||||
} elseif (strpos($arrTNTCarrier['code'], 'T') !== false) {
|
||||
$arrTNTCarrier['label'] = '10:00 Express en Entreprise';
|
||||
}
|
||||
} elseif (strpos($arrTNTCarrier['type'], 'INDIVIDUAL') !== false) {
|
||||
if (strpos($arrTNTCarrier['code'], 'AZ') !== false) {
|
||||
$arrTNTCarrier['label'] = '09:00 Express à domicile';
|
||||
} elseif (strpos($arrTNTCarrier['code'], 'JZ') !== false) {
|
||||
$arrTNTCarrier['label'] = 'À domicile';
|
||||
} elseif (strpos($arrTNTCarrier['code'], 'MZ') !== false) {
|
||||
$arrTNTCarrier['label'] = '12:00 Express à domicile';
|
||||
} elseif (strpos($arrTNTCarrier['code'], 'TZ') !== false) {
|
||||
$arrTNTCarrier['label'] = '10:00 Express à domicile';
|
||||
}
|
||||
} elseif (strpos($arrTNTCarrier['type'], 'DROPOFFPOINT') !== false) {
|
||||
$arrTNTCarrier['label'] = 'En Relais Colis®';
|
||||
} elseif (strpos($arrTNTCarrier['type'], 'DEPOT') !== false) {
|
||||
$arrTNTCarrier['label'] = 'Dépôt restant';
|
||||
}
|
||||
|
||||
// Found current TNT carrier code.
|
||||
if ($arrTNTCarrier['code'].'_'.$arrTNTCarrier['type'] == $strProductCode) {
|
||||
// Load TNT cart info or create a new one for it's ID.
|
||||
$objTNTCartModel = TNTOfficielCart::loadCartID($intCartID);
|
||||
$boolResult = false;
|
||||
if (Validate::isLoadedObject($objTNTCartModel)) {
|
||||
$objTNTCartModel->hydrate(array(
|
||||
'carrier_code' => $strProductCode,
|
||||
'carrier_label' => pSQL($arrTNTCarrier['label']),
|
||||
'delivery_price' => pSQL($arrTNTCarrier['price'])
|
||||
));
|
||||
$boolResult = $objTNTCartModel->save();
|
||||
}
|
||||
$boolCarrierIsValid = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
echo Tools::jsonEncode(array(
|
||||
'result' => $boolCarrierIsValid && $boolResult,
|
||||
'product' => $arrTNTCarrier,
|
||||
));
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check TNT data before payment process.
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function displayAjaxCheckProductCode()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$objContext = $this->context;
|
||||
$objCart = $objContext->cart;
|
||||
//$intCartID = (int)$objCart->id;
|
||||
|
||||
//$strCarrierType = pSQL(Tools::getValue('product'));
|
||||
$arrCarrierCode = (array)Tools::getValue('deliveryOptionTnt');
|
||||
|
||||
$strErrorMsg = null;
|
||||
$arrResult = array(
|
||||
'error' => 0,
|
||||
TNTOfficiel::MODULE_NAME => 1
|
||||
);
|
||||
|
||||
if (!$objCart) {
|
||||
$strErrorMsg = 'No cart object';
|
||||
} elseif ($objCart->id_carrier == 0) {
|
||||
$strErrorMsg = 'No carrier selected';
|
||||
} elseif (!$objCart->id_address_delivery) {
|
||||
$strErrorMsg = 'No delivery address selected';
|
||||
}
|
||||
|
||||
// If an error.
|
||||
if ($strErrorMsg !== null) {
|
||||
$arrResult = array('error' => 1, 'msg' => $strErrorMsg);
|
||||
} else {
|
||||
$boolIsTntCarrier = TNTOfficiel_Carrier::isTNTOfficielCarrierID($objCart->id_carrier);
|
||||
|
||||
if (!$boolIsTntCarrier) {
|
||||
// The preselected carrier is not TNT, don't handle.
|
||||
$arrResult = array('error' => 0, TNTOfficiel::MODULE_NAME => 0);
|
||||
} elseif (($boolIsTntCarrier && !Tools::getIsset('product'))
|
||||
|| !$arrCarrierCode
|
||||
|| !$objCart->delivery_option
|
||||
) {
|
||||
// TNT is preselected and no service selected (individual, enterprise, dropoffpoint or depot) -> Error.
|
||||
$arrResult = array('error' => 1);
|
||||
}
|
||||
}
|
||||
|
||||
echo Tools::jsonEncode($arrResult);
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
18
www/modules/tntofficiel/controllers/front/index.php
Normal file
18
www/modules/tntofficiel/controllers/front/index.php
Normal file
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../');
|
||||
exit;
|
240
www/modules/tntofficiel/controllers/front/shippingMethod.php
Normal file
240
www/modules/tntofficiel/controllers/front/shippingMethod.php
Normal file
@ -0,0 +1,240 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/classes/TNTOfficielCart.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/helper/TNTOfficiel_RelayPointsHelper.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/helper/TNTOfficiel_ShippingHelper.php';
|
||||
|
||||
class TNTOfficielShippingMethodModuleFrontController extends ModuleFrontController
|
||||
{
|
||||
/**
|
||||
* TNTOfficielShippingMethodModuleFrontController constructor.
|
||||
* Controller always used for AJAX response.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
parent::__construct();
|
||||
|
||||
// No header/footer.
|
||||
$this->ajax = true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the relay points popup via Ajax.
|
||||
* JD_DROPOFFPOINT (En Relais Colis®) : XETT
|
||||
*/
|
||||
public function displayAjaxBoxRelayPoints()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$objContext = $this->context;
|
||||
$objCart = $objContext->cart;
|
||||
$intCartID = (int)$objCart->id;
|
||||
$objShop = $objContext->shop;
|
||||
|
||||
// Load TNT cart info or create a new one for it's ID.
|
||||
$objTNTCartModel = TNTOfficielCart::loadCartID($intCartID);
|
||||
if (Validate::isLoadedObject($objTNTCartModel)) {
|
||||
// If product code is not "En Relais Colis®".
|
||||
if ($objTNTCartModel->carrier_code !== 'JD_DROPOFFPOINT') {
|
||||
// Clear carrier code and delivery point.
|
||||
$objTNTCartModel->carrier_code = '';
|
||||
$objTNTCartModel->setDeliveryPoint(array());
|
||||
// Unselect carrier from cart.
|
||||
$objCart->setDeliveryOption(null);
|
||||
$objCart->save();
|
||||
}
|
||||
$objTNTCartModel->save();
|
||||
}
|
||||
|
||||
$strPostcode = trim(pSQL(Tools::getValue('tnt_postcode')));
|
||||
$strCity = trim(pSQL(Tools::getValue('tnt_city')));
|
||||
|
||||
if (!$strPostcode && !$strCity) {
|
||||
$objAddress = new Address((int)$objCart->id_address_delivery);
|
||||
$strPostcode = $objAddress->postcode;
|
||||
$strCity = $objAddress->city;
|
||||
}
|
||||
|
||||
// Call API to get list of repositories
|
||||
$objTNTRelayPointsHelper = TNTOfficiel_RelayPointsHelper::getInstance();
|
||||
$arrRelayPoints = $objTNTRelayPointsHelper->getRelayPoints($strPostcode, $strCity, $objShop->id);
|
||||
$arrCities = TNTOfficiel_AddressHelper::getInstance()->getCitiesFromMiddleware($strPostcode, $objShop->id);
|
||||
|
||||
foreach ($arrRelayPoints as $key => $item) {
|
||||
$arrRelayPoints[ $key ]['schedule'] = TNTOfficiel_ShippingHelper::getInstance()->getSchedules($item);
|
||||
}
|
||||
|
||||
/*
|
||||
if (empty($relay) && !empty($cities['cities'])) {
|
||||
$city = $cities['cities'][0];
|
||||
$relay = $obRelayPointsHelper->getRelayPoints($postcode, $city, $objShop->id);
|
||||
}
|
||||
*/
|
||||
|
||||
// Get the relay points
|
||||
$this->context->smarty->assign(
|
||||
array(
|
||||
'method_id' => 'relay_points',
|
||||
'method_name' => 'relay-points',
|
||||
'current_postcode' => $strPostcode,
|
||||
'current_city' => $strCity,
|
||||
'results' => $arrRelayPoints,
|
||||
'cities' => $arrCities['cities'],
|
||||
)
|
||||
);
|
||||
|
||||
$this->context->smarty->display(
|
||||
_PS_MODULE_DIR_.$this->module->name.'/views/templates/hook/displayCarrierList/deliveryPointsBox.tpl'
|
||||
);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the repositories popup via Ajax.
|
||||
* J_DEPOT (Dépôt restant) : PEX
|
||||
*/
|
||||
public function displayAjaxBoxDropOffPoints()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$objContext = $this->context;
|
||||
$objCart = $objContext->cart;
|
||||
$intCartID = (int)$objCart->id;
|
||||
$objShop = $objContext->shop;
|
||||
|
||||
// Load TNT cart info or create a new one for it's ID.
|
||||
$objTNTCartModel = TNTOfficielCart::loadCartID($intCartID);
|
||||
if (Validate::isLoadedObject($objTNTCartModel)) {
|
||||
// If product code is not "Dépôt restant".
|
||||
if ($objTNTCartModel->carrier_code !== 'J_DEPOT') {
|
||||
// Clear carrier code and delivery point.
|
||||
$objTNTCartModel->carrier_code = '';
|
||||
$objTNTCartModel->setDeliveryPoint(array());
|
||||
// Unselect carrier from cart.
|
||||
$objCart->setDeliveryOption(null);
|
||||
$objCart->save();
|
||||
}
|
||||
$objTNTCartModel->save();
|
||||
}
|
||||
|
||||
$strPostCode = trim(pSQL(Tools::getValue('tnt_postcode')));
|
||||
$strCity = trim(pSQL(Tools::getValue('tnt_city')));
|
||||
|
||||
if (!$strPostCode && !$strCity) {
|
||||
$objAddress = new Address((int)$objCart->id_address_delivery);
|
||||
$strPostCode = $objAddress->postcode;
|
||||
$strCity = $objAddress->city;
|
||||
}
|
||||
|
||||
// Call API to get list of repositories
|
||||
$objTNTRelayPointsHelper = TNTOfficiel_RelayPointsHelper::getInstance();
|
||||
$arrRepositories = $objTNTRelayPointsHelper->getRepositories($strPostCode, $objShop->id);
|
||||
$arrCities = TNTOfficiel_AddressHelper::getInstance()->getCitiesFromMiddleware($strPostCode, $objShop->id);
|
||||
|
||||
foreach ($arrRepositories as $key => $repository) {
|
||||
$arrRepositories[ $key ]['schedule'] = TNTOfficiel_ShippingHelper::getInstance()->getSchedules($repository);
|
||||
}
|
||||
|
||||
$this->context->smarty->assign(
|
||||
array(
|
||||
'method_id' => 'repositories',
|
||||
'method_name' => 'repositories',
|
||||
'current_postcode' => $strPostCode,
|
||||
'current_city' => $strCity,
|
||||
'results' => $arrRepositories,
|
||||
'cities' => $arrCities['cities'],
|
||||
)
|
||||
);
|
||||
|
||||
$this->context->smarty->display(
|
||||
_PS_MODULE_DIR_.$this->module->name.'/views/templates/hook/displayCarrierList/deliveryPointsBox.tpl'
|
||||
);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Save delivery point XETT or PEX info.
|
||||
*/
|
||||
public function displayAjaxSaveProductInfo()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$arrDeliveryPoint = (array)Tools::getValue('product');
|
||||
|
||||
// Check code exist.
|
||||
if (!array_key_exists('xett', $arrDeliveryPoint) && !array_key_exists('pex', $arrDeliveryPoint)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$objContext = $this->context;
|
||||
$objCart = $objContext->cart;
|
||||
$intCartID = (int)$objCart->id;
|
||||
|
||||
// Load TNT cart info or create a new one for it's ID.
|
||||
$objTNTCartModel = TNTOfficielCart::loadCartID($intCartID);
|
||||
if (Validate::isLoadedObject($objTNTCartModel)) {
|
||||
$objTNTCartModel->setDeliveryPoint($arrDeliveryPoint);
|
||||
}
|
||||
|
||||
$this->context->smarty->assign(
|
||||
array(
|
||||
'item' => $arrDeliveryPoint,
|
||||
'method_id' => isset($arrDeliveryPoint['xett']) ? 'relay_point' : 'repository',
|
||||
'method_name' => isset($arrDeliveryPoint['xett']) ? 'relay-point' : 'repository',
|
||||
)
|
||||
);
|
||||
|
||||
$this->context->smarty->display(
|
||||
_PS_MODULE_DIR_.$this->module->name.'/views/templates/hook/displayCarrierList/deliveryPointSet.tpl'
|
||||
);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Save current TNT shipping address.
|
||||
*/
|
||||
public function displayAjaxSaveProductCode()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$strProductCode = pSQL(Tools::getValue('productCode'));
|
||||
|
||||
if ($strProductCode) {
|
||||
$objContext = $this->context;
|
||||
$objCart = $objContext->cart;
|
||||
$intCartID = (int)$objCart->id;
|
||||
|
||||
// Load TNT cart info or create a new one for it's ID.
|
||||
$objTNTCartModel = TNTOfficielCart::loadCartID($intCartID);
|
||||
if (Validate::isLoadedObject($objTNTCartModel)) {
|
||||
// Save TNT product code.
|
||||
$objTNTCartModel->carrier_code = $strProductCode;
|
||||
// If product code is not "Dépôt restant" or En "Relais Colis®".
|
||||
if ($strProductCode !== 'JD_DROPOFFPOINT' && $strProductCode !== 'J_DEPOT') {
|
||||
// Clear delivery point.
|
||||
$objTNTCartModel->setDeliveryPoint(array());
|
||||
}
|
||||
$objTNTCartModel->save();
|
||||
}
|
||||
}
|
||||
|
||||
echo Tools::jsonEncode(array(
|
||||
'success' => true
|
||||
));
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
68
www/modules/tntofficiel/controllers/front/tracking.php
Normal file
68
www/modules/tntofficiel/controllers/front/tracking.php
Normal file
@ -0,0 +1,68 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
|
||||
class TNTOfficielTrackingModuleFrontController extends ModuleFrontController
|
||||
{
|
||||
/**
|
||||
* TNTOfficielTrackingModuleFrontController constructor.
|
||||
* Controller always used for AJAX response.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
parent::__construct();
|
||||
|
||||
// No header/footer.
|
||||
$this->ajax = true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Display the tracking popup.
|
||||
*/
|
||||
public function displayAjaxTracking()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$intOrderID = (int)Tools::getValue('orderId');
|
||||
try {
|
||||
$arrTNTOrder = TNTOfficiel_OrderHelper::getInstance()->getOrderData($intOrderID);
|
||||
} catch (Exception $objException) {
|
||||
$objFileLogger = new FileLogger();
|
||||
$objFileLogger->setFilename(_PS_ROOT_DIR_.'/log/'.date('Ymd').'_tnt_exception.log');
|
||||
$objFileLogger->logError($objException->getMessage());
|
||||
|
||||
Controller::getController('PageNotFoundController')->run();
|
||||
//$this->smartyOutputContent(_PS_THEME_DIR_.'404.tpl');
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
//get parcels and for each parcel get its tracking data
|
||||
$parcels = TNTOfficiel_ParcelsHelper::getInstance()->getParcels($intOrderID);
|
||||
foreach ($parcels as &$parcel) {
|
||||
$parcel['trackingData'] = TNTOfficiel_ParcelsHelper::getInstance()->getTrackingData($parcel);
|
||||
}
|
||||
|
||||
$this->context->smarty->assign(
|
||||
array(
|
||||
'order' => $arrTNTOrder,
|
||||
'parcels' => $parcels,
|
||||
)
|
||||
);
|
||||
|
||||
$this->context->smarty->display(
|
||||
_PS_MODULE_DIR_.$this->module->name.'/views/templates/front/displayAjaxTracking.tpl'
|
||||
);
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
18
www/modules/tntofficiel/controllers/index.php
Normal file
18
www/modules/tntofficiel/controllers/index.php
Normal file
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../');
|
||||
exit;
|
18
www/modules/tntofficiel/index.php
Normal file
18
www/modules/tntofficiel/index.php
Normal file
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../');
|
||||
exit;
|
193
www/modules/tntofficiel/libraries/TNTOfficiel_Address.php
Normal file
193
www/modules/tntofficiel/libraries/TNTOfficiel_Address.php
Normal file
@ -0,0 +1,193 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Logger.php';
|
||||
|
||||
class TNTOfficiel_Address
|
||||
{
|
||||
/**
|
||||
* @var TNTOfficiel_Logger
|
||||
*/
|
||||
private $logger;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->logger = new TNTOfficiel_Logger();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Returns the default values for the extra address data fields.
|
||||
*
|
||||
* @param int $intArgAddressID
|
||||
* @param int $intArgCustomerID
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public static function getDefaultValues($intArgAddressID, $intArgCustomerID)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
// Retrieve the customer and address by its id.
|
||||
$arrRowCustomer = Db::getInstance()->getRow(
|
||||
'SELECT * FROM '._DB_PREFIX_.'customer WHERE id_customer = '.(int)$intArgCustomerID
|
||||
);
|
||||
$arrRowAddress = Db::getInstance()->getRow(
|
||||
'SELECT * FROM '._DB_PREFIX_.'address WHERE id_address = '.(int)$intArgAddressID
|
||||
);
|
||||
|
||||
// Get values from the customer and address object according to the configuration.
|
||||
return array(
|
||||
'email' => TNTOfficiel_Address::_getValue(
|
||||
$arrRowAddress,
|
||||
$arrRowCustomer,
|
||||
'TNT_CARRIER_ADDRESS_EMAIL'
|
||||
),
|
||||
'mobile_phone' => TNTOfficiel_Address::_getValue(
|
||||
$arrRowAddress,
|
||||
$arrRowCustomer,
|
||||
'TNT_CARRIER_ADDRESS_PHONE'
|
||||
),
|
||||
'building_number' => TNTOfficiel_Address::_getValue(
|
||||
$arrRowAddress,
|
||||
$arrRowCustomer,
|
||||
'TNT_CARRIER_ADDRESS_BUILDING'
|
||||
),
|
||||
'intercom_code' => TNTOfficiel_Address::_getValue(
|
||||
$arrRowAddress,
|
||||
$arrRowCustomer,
|
||||
'TNT_CARRIER_ADDRESS_INTERCOM'
|
||||
),
|
||||
'floor' => TNTOfficiel_Address::_getValue(
|
||||
$arrRowAddress,
|
||||
$arrRowCustomer,
|
||||
'TNT_CARRIER_ADDRESS_FLOOR'
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the property from a customer or an address.
|
||||
*
|
||||
* @param array $arrAddress
|
||||
* @param array $arrCustomer
|
||||
* @param string $strArgConfigField
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
private static function _getValue($arrAddress, $arrCustomer, $strArgConfigField)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$arrConfigValue = explode('.', Configuration::get($strArgConfigField));
|
||||
$strValue = '';
|
||||
if (count($arrConfigValue) > 1) {
|
||||
$objectName = $arrConfigValue[0];
|
||||
$objectProperty = $arrConfigValue[1];
|
||||
if (in_array($objectProperty, array('id_customer', 'id_address'))) {
|
||||
$objectProperty = 'id';
|
||||
}
|
||||
try {
|
||||
$object = null;
|
||||
if ($objectName == 'customer') {
|
||||
$object = $arrCustomer;
|
||||
}
|
||||
elseif ($objectName == 'address') {
|
||||
$object = $arrAddress;
|
||||
}
|
||||
$strValue = $object[$objectProperty];
|
||||
} catch (Exception $objException) {
|
||||
$objFileLogger = new FileLogger();
|
||||
$objFileLogger->setFilename(_PS_ROOT_DIR_.'/log/'.date('Ymd').'_tnt_exception.log');
|
||||
$objFileLogger->logError($objException->getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
return $strValue;
|
||||
}
|
||||
|
||||
/**
|
||||
* Validate the extra address data form.
|
||||
*
|
||||
* @param $values
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public static function validate($values)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$arrFormErrors = array();
|
||||
|
||||
//check if email is set and not empty
|
||||
if (!isset($values['email']) || trim($values['email']) === '') {
|
||||
$arrFormErrors[] = 'Le champ \'email\' est obligatoire';
|
||||
}
|
||||
|
||||
//check if the email is valid
|
||||
if (!filter_var($values['email'], FILTER_VALIDATE_EMAIL)) {
|
||||
$arrFormErrors[] = 'L\'email saisi n\'est pas valide';
|
||||
}
|
||||
|
||||
//check if mobile phone is set and not empty
|
||||
if (!isset($values['mobile_phone']) || trim($values['mobile_phone']) === '') {
|
||||
$arrFormErrors[] = 'Le champ \'Téléphone portable\' est obligatoire';
|
||||
}
|
||||
|
||||
//check if mobile phone is set 10 digits and start by 06 or 07
|
||||
if (!preg_match('/^((06|07){1}(\d){8})$/', $values['mobile_phone'])) {
|
||||
$arrFormErrors[] = 'Le champ \'Téléphone portable\' doit être composé de 10 chiffres'
|
||||
.' sans espace ni point, et commencer par un 06 ou 07';
|
||||
}
|
||||
|
||||
$arrFieldList = array(
|
||||
array(
|
||||
'name' => 'email',
|
||||
'label' => 'Email de contact',
|
||||
'maxlength' => 80,
|
||||
),
|
||||
array(
|
||||
'name' => 'mobile_phone',
|
||||
'label' => 'Téléphone',
|
||||
'maxlength' => 15,
|
||||
),
|
||||
array(
|
||||
'name' => 'building_number',
|
||||
'label' => 'N° de batiment',
|
||||
'maxlength' => 3,
|
||||
),
|
||||
array(
|
||||
'name' => 'intercom_code',
|
||||
'label' => 'Code interphone',
|
||||
'maxlength' => 7,
|
||||
),
|
||||
array(
|
||||
'name' => 'floor',
|
||||
'label' => 'Etage',
|
||||
'maxlength' => 2,
|
||||
),
|
||||
);
|
||||
|
||||
foreach ($arrFieldList as $arrField) {
|
||||
if ($values[$arrField['name']]) {
|
||||
if ($arrField['maxlength'] < iconv_strlen($values[$arrField['name']])) {
|
||||
$arrFormErrors[] = sprintf('Le champ "%s" doit avoir au maximum %s caractère(s)', $arrField['label'], $arrField['maxlength']);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return $arrFormErrors;
|
||||
}
|
||||
}
|
69
www/modules/tntofficiel/libraries/TNTOfficiel_Cache.php
Normal file
69
www/modules/tntofficiel/libraries/TNTOfficiel_Cache.php
Normal file
@ -0,0 +1,69 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
class TNTOfficiel_Cache
|
||||
{
|
||||
/**
|
||||
* @param $strArgKey
|
||||
* @return bool
|
||||
*/
|
||||
public static function isStored($strArgKey)
|
||||
{
|
||||
$objCache = Cache::getInstance();
|
||||
|
||||
$boolExistL1 = Cache::isStored($strArgKey);
|
||||
$boolExistL2 = false;
|
||||
|
||||
if (_PS_CACHE_ENABLED_ && !$boolExistL1) {
|
||||
$boolExistL2 = $objCache->exists($strArgKey);
|
||||
}
|
||||
|
||||
return $boolExistL1 || $boolExistL2;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $strArgKey
|
||||
* @param $mxdArgValue
|
||||
* @param $intArgTTL
|
||||
* @return bool
|
||||
*/
|
||||
public static function store($strArgKey, $mxdArgValue, $intArgTTL)
|
||||
{
|
||||
$objCache = Cache::getInstance();
|
||||
|
||||
$boolSetL1 = Cache::store($strArgKey, $mxdArgValue);
|
||||
$boolSetL2 = true;
|
||||
|
||||
if (_PS_CACHE_ENABLED_) {
|
||||
$boolSetL2 = $objCache->set($strArgKey, $mxdArgValue, $intArgTTL);
|
||||
}
|
||||
|
||||
return $boolSetL1 && $boolSetL2;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $strArgKey
|
||||
* @return null
|
||||
*/
|
||||
public static function retrieve($strArgKey)
|
||||
{
|
||||
$objCache = Cache::getInstance();
|
||||
|
||||
$mxdGet = null;
|
||||
|
||||
if (Cache::isStored($strArgKey)) {
|
||||
$mxdGet = Cache::retrieve($strArgKey);
|
||||
}
|
||||
elseif (_PS_CACHE_ENABLED_ && $objCache->exists($strArgKey)) {
|
||||
$mxdGet = $objCache->get($strArgKey);
|
||||
}
|
||||
|
||||
return $mxdGet;
|
||||
}
|
||||
}
|
330
www/modules/tntofficiel/libraries/TNTOfficiel_Carrier.php
Normal file
330
www/modules/tntofficiel/libraries/TNTOfficiel_Carrier.php
Normal file
@ -0,0 +1,330 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/tntofficiel.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
|
||||
class TNTOfficiel_Carrier
|
||||
{
|
||||
/**
|
||||
* Configuration name.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
private static $strConfigNameCarrierID = 'TNT_CARRIER_ID';
|
||||
|
||||
|
||||
/**
|
||||
* Create a new TNT global carrier and save it as current one.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public static function createGlobalCarrier()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
// Create new carrier.
|
||||
$objCarrierNew = new Carrier();
|
||||
$objCarrierNew->active = true;
|
||||
$objCarrierNew->deleted = false;
|
||||
// Carrier used for module.
|
||||
$objCarrierNew->is_module = true;
|
||||
$objCarrierNew->external_module_name = TNTOfficiel::MODULE_NAME;
|
||||
// Carrier name.
|
||||
$objCarrierNew->name = 'TNT Express France';
|
||||
// Carrier delay description per language ISO code.
|
||||
// Mandatory, but not used.
|
||||
$objCarrierNew->delay = array(
|
||||
//'fr' => 'Livraison en 1 à 3 jours en France métropolitaine (Intra et Corse)',
|
||||
Configuration::get('PS_LANG_DEFAULT') => 'TNT'
|
||||
);
|
||||
// Disable applying tax rules group.
|
||||
$objCarrierNew->id_tax_rules_group = 0;
|
||||
// Disable adding handling charges from config PS_SHIPPING_HANDLING.
|
||||
$objCarrierNew->shipping_handling = false;
|
||||
// Enable use of Cart getPackageShippingCost, getOrderShippingCost or getOrderShippingCostExternal
|
||||
$objCarrierNew->shipping_external = true;
|
||||
// Enable calculations for the ranges.
|
||||
$objCarrierNew->need_range = true;
|
||||
$objCarrierNew->range_behavior = 0;
|
||||
|
||||
// Unable to create new carrier.
|
||||
if (!$objCarrierNew->add()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$objDB = Db::getInstance();
|
||||
|
||||
$groups = Group::getGroups(true);
|
||||
foreach ($groups as $group) {
|
||||
$objDB->insert(
|
||||
'carrier_group',
|
||||
array(
|
||||
'id_carrier' => (int)$objCarrierNew->id,
|
||||
'id_group' => (int)$group['id_group'],
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
$objRangePrice = new RangePrice();
|
||||
$objRangePrice->id_carrier = $objCarrierNew->id;
|
||||
$objRangePrice->delimiter1 = '0';
|
||||
$objRangePrice->delimiter2 = '1000000';
|
||||
$objRangePrice->add();
|
||||
|
||||
$objRangeWeight = new RangeWeight();
|
||||
$objRangeWeight->id_carrier = $objCarrierNew->id;
|
||||
$objRangeWeight->delimiter1 = '0';
|
||||
$objRangeWeight->delimiter2 = '1000000';
|
||||
$objRangeWeight->add();
|
||||
|
||||
// Get active zones list.
|
||||
$arrZoneList = Zone::getZones(true);
|
||||
foreach ($arrZoneList as $arrZone) {
|
||||
$objDB->insert(
|
||||
'carrier_zone',
|
||||
array(
|
||||
'id_carrier' => (int)$objCarrierNew->id,
|
||||
'id_zone' => (int)$arrZone['id_zone']
|
||||
)
|
||||
);
|
||||
$objDB->insert(
|
||||
'delivery',
|
||||
array(
|
||||
'id_carrier' => (int)$objCarrierNew->id,
|
||||
'id_range_price' => (int)$objRangePrice->id,
|
||||
'id_range_weight' => null,
|
||||
'id_zone' => (int)$arrZone['id_zone'],
|
||||
'price' => '0'
|
||||
),
|
||||
true,
|
||||
false
|
||||
);
|
||||
$objDB->insert(
|
||||
'delivery',
|
||||
array(
|
||||
'id_carrier' => (int)$objCarrierNew->id,
|
||||
'id_range_price' => null,
|
||||
'id_range_weight' => (int)$objRangeWeight->id,
|
||||
'id_zone' => (int)$arrZone['id_zone'],
|
||||
'price' => '0'
|
||||
),
|
||||
true,
|
||||
false
|
||||
);
|
||||
}
|
||||
|
||||
// Save the carrier ID.
|
||||
$boolResult = TNTOfficiel_Carrier::setCarrierID($objCarrierNew->id);
|
||||
|
||||
return $boolResult;
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a logo for a carrier.
|
||||
*
|
||||
* @param string $strArgModuleDir Module absolute Path.
|
||||
* @param int $intArgCarrierIDTNT
|
||||
* @return bool
|
||||
*/
|
||||
public static function createLogo($strArgModuleDir, $intArgCarrierIDTNT)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
// Add carrier logo.
|
||||
$boolResult = copy($strArgModuleDir.'/views/img/carriers/tntofficiel.jpg', _PS_SHIP_IMG_DIR_.(int)$intArgCarrierIDTNT.'.jpg');
|
||||
|
||||
return $boolResult;
|
||||
}
|
||||
|
||||
/**
|
||||
* Undelete the existing current TNT global carrier by setting its flag to not deleted.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public static function undeleteGlobalCarrier()
|
||||
{
|
||||
// Load current TNT carrier object.
|
||||
$objCarrierTNT = TNTOfficiel_Carrier::loadGlobalCarrier();
|
||||
// If TNT carrier object not available.
|
||||
if ($objCarrierTNT === null) {
|
||||
// Unable to undelete.
|
||||
return false;
|
||||
}
|
||||
|
||||
$objCarrierTNT->active = true;
|
||||
$objCarrierTNT->deleted = false;
|
||||
// Always set the right module name.
|
||||
$objCarrierTNT->external_module_name = TNTOfficiel::MODULE_NAME;
|
||||
$boolResult = $objCarrierTNT->save();
|
||||
|
||||
return $boolResult;
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete the existing current TNT global carrier by setting its flag to deleted.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public static function deleteGlobalCarrier()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
// Load current TNT carrier object.
|
||||
$objCarrierTNT = TNTOfficiel_Carrier::loadGlobalCarrier();
|
||||
// If TNT carrier object not available.
|
||||
if ($objCarrierTNT === null) {
|
||||
// Nothing to delete.
|
||||
return true;
|
||||
}
|
||||
|
||||
$objCarrierTNT->active = false;
|
||||
$objCarrierTNT->deleted = true;
|
||||
$boolResult = $objCarrierTNT->save();
|
||||
|
||||
return $boolResult;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the current TNT carrier ID.
|
||||
*
|
||||
* @return int|null
|
||||
*/
|
||||
public static function getGlobalCarrierID()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
// Get current TNT carrier.
|
||||
$intCarrierIDTNT = Configuration::get(TNTOfficiel_Carrier::$strConfigNameCarrierID);
|
||||
// Carrier ID must be an integer greater than 0.
|
||||
if (empty($intCarrierIDTNT) || $intCarrierIDTNT != (int)$intCarrierIDTNT || !((int)$intCarrierIDTNT > 0) ) {
|
||||
return null;
|
||||
}
|
||||
|
||||
return (int)$intCarrierIDTNT;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the current TNT carrier ID.
|
||||
*
|
||||
* @param int $intArgCarrierID
|
||||
* @return bool
|
||||
*/
|
||||
public static function setCarrierID($intArgCarrierID)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
// Carrier ID must be an integer greater than 0.
|
||||
if (empty($intArgCarrierID) || $intArgCarrierID != (int)$intArgCarrierID || !((int)$intArgCarrierID > 0) ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return Configuration::updateValue(TNTOfficiel_Carrier::$strConfigNameCarrierID, $intArgCarrierID);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Load current TNT global carrier object model.
|
||||
*
|
||||
* @return Carrier|null
|
||||
*/
|
||||
public static function loadGlobalCarrier()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
// Get current TNT carrier ID.
|
||||
$intCarrierIDTNT = TNTOfficiel_Carrier::getGlobalCarrierID();
|
||||
// If TNT carrier ID not availaible.
|
||||
if ($intCarrierIDTNT === null) {
|
||||
return null;
|
||||
}
|
||||
|
||||
// Load TNT carrier.
|
||||
$objCarrierTNT = new Carrier($intCarrierIDTNT);
|
||||
|
||||
// If TNT carrier object not available.
|
||||
if (!(Validate::isLoadedObject($objCarrierTNT) && (int)$objCarrierTNT->id === $intCarrierIDTNT)) {
|
||||
return null;
|
||||
}
|
||||
|
||||
return $objCarrierTNT;
|
||||
}
|
||||
|
||||
/**
|
||||
* Force some current carrier settings. Should be removed in the near future.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public static function forceGlobalCarrierDefaultValues()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
// Load current TNT carrier object.
|
||||
$objCarrierTNT = TNTOfficiel_Carrier::loadGlobalCarrier();
|
||||
// If TNT carrier correctly loaded.
|
||||
if ($objCarrierTNT !== null)
|
||||
{
|
||||
// Get all users groups associated with the TNT carrier.
|
||||
$arrCarrierGroups = $objCarrierTNT->getGroups();
|
||||
// If there is currently at least one users groups set.
|
||||
if (is_array($arrCarrierGroups) && count($arrCarrierGroups) > 0)
|
||||
{
|
||||
// Current users groups set.
|
||||
$arrCarrierGroupsSet = array();
|
||||
foreach ($arrCarrierGroups as $arrRowCarrierGroup) {
|
||||
// DB request fail. stop here.
|
||||
if (!array_key_exists( 'id_group', $arrRowCarrierGroup )) {
|
||||
return false;
|
||||
}
|
||||
$arrCarrierGroupsSet[] = (int)$arrRowCarrierGroup['id_group'];
|
||||
}
|
||||
// Users groups to exclude.
|
||||
$arrCarrierGroupsExclude = array(
|
||||
(int)Configuration::get('PS_UNIDENTIFIED_GROUP'),
|
||||
(int)Configuration::get('PS_GUEST_GROUP')
|
||||
// PS_CUSTOMER_GROUP (default) preserved
|
||||
// CUSTOM GROUP preserved
|
||||
);
|
||||
|
||||
// Get groups previously set, minus groups to exclude.
|
||||
$arrCarrierGroupsApply = array_diff($arrCarrierGroupsSet, $arrCarrierGroupsExclude);
|
||||
|
||||
// If groups change.
|
||||
if(count(array_diff($arrCarrierGroupsSet, $arrCarrierGroupsApply)) > 0) {
|
||||
// Force carrier users groups (delete all, then set).
|
||||
$objCarrierTNT->setGroups($arrCarrierGroupsApply, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if a carrier ID is a TNT one.
|
||||
*
|
||||
* @param int $intArgCarrierID
|
||||
* @return boolean
|
||||
*/
|
||||
public static function isTNTOfficielCarrierID($intArgCarrierID)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
// Carrier ID must be an integer greater than 0.
|
||||
if (empty($intArgCarrierID) || $intArgCarrierID != (int)$intArgCarrierID || !((int)$intArgCarrierID > 0) ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$intCarrierID = (int)$intArgCarrierID;
|
||||
|
||||
$obCarrier = new Carrier($intCarrierID);
|
||||
|
||||
return $obCarrier->external_module_name === TNTOfficiel::MODULE_NAME;
|
||||
}
|
||||
}
|
121
www/modules/tntofficiel/libraries/TNTOfficiel_Cart.php
Normal file
121
www/modules/tntofficiel/libraries/TNTOfficiel_Cart.php
Normal file
@ -0,0 +1,121 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/tntofficiel.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
|
||||
class TNTOfficiel_Cart
|
||||
{
|
||||
/**
|
||||
* Is shipping free for cart, through configuration.
|
||||
*
|
||||
* @param $objArgCart
|
||||
* @return bool
|
||||
*/
|
||||
public static function isCartShippingFree($objArgCart)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$arrConfigShipping = Configuration::getMultiple(array(
|
||||
'PS_SHIPPING_FREE_PRICE',
|
||||
'PS_SHIPPING_FREE_WEIGHT'
|
||||
));
|
||||
|
||||
// Load current TNT carrier object.
|
||||
$objCarrierTNT = TNTOfficiel_Carrier::loadGlobalCarrier();
|
||||
// If TNT carrier object not available.
|
||||
if ($objCarrierTNT === null) {
|
||||
return true;
|
||||
}
|
||||
|
||||
// If TNT carrier is inactive or free.
|
||||
if (!$objCarrierTNT->active || $objCarrierTNT->getShippingMethod() == Carrier::SHIPPING_METHOD_FREE) {
|
||||
return true;
|
||||
}
|
||||
|
||||
// Get cart amount to reach for free shipping.
|
||||
$fltFreeFeesPrice = 0;
|
||||
if (isset($arrConfigShipping['PS_SHIPPING_FREE_PRICE'])) {
|
||||
$fltFreeFeesPrice = (float)Tools::convertPrice(
|
||||
(float)$arrConfigShipping['PS_SHIPPING_FREE_PRICE'],
|
||||
Currency::getCurrencyInstance((int)$objArgCart->id_currency)
|
||||
);
|
||||
}
|
||||
// Free shipping if cart amount, inc. taxes, inc. product & discount, exc. shipping > PS_SHIPPING_FREE_PRICE
|
||||
if ($fltFreeFeesPrice > 0
|
||||
&& $objArgCart->getOrderTotal(true, Cart::BOTH_WITHOUT_SHIPPING, null, null, false) >= $fltFreeFeesPrice
|
||||
) {
|
||||
return true;
|
||||
}
|
||||
|
||||
// Free shipping if cart weight > PS_SHIPPING_FREE_WEIGHT
|
||||
if (isset($arrConfigShipping['PS_SHIPPING_FREE_WEIGHT'])
|
||||
&& $objArgCart->getTotalWeight() >= (float)$arrConfigShipping['PS_SHIPPING_FREE_WEIGHT']
|
||||
&& (float)$arrConfigShipping['PS_SHIPPING_FREE_WEIGHT'] > 0
|
||||
) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get additional shipping cost for cart (exc. taxes).
|
||||
*
|
||||
* @param $objArgCart
|
||||
* @return float
|
||||
*/
|
||||
public static function getCartExtraShippingCost($objArgCart)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$fltShippingCost = 0;
|
||||
$arrProducts = $objArgCart->getProducts();
|
||||
|
||||
// If no product, no shipping extra cost.
|
||||
if (!count($arrProducts)) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// If only virtual products in cart, no extra shipping cost.
|
||||
if ($objArgCart->isVirtualCart()) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// If TNT carrier is free.
|
||||
$boolIsCartShippingFree = TNTOfficiel_Cart::isCartShippingFree($objArgCart);
|
||||
if ($boolIsCartShippingFree) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Load current TNT carrier object.
|
||||
$objCarrierTNT = TNTOfficiel_Carrier::loadGlobalCarrier();
|
||||
// If TNT carrier object not available, no extra shipping cost.
|
||||
if ($objCarrierTNT === null) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Adding handling charges.
|
||||
$shipping_handling = Configuration::get('PS_SHIPPING_HANDLING');
|
||||
if (isset($shipping_handling) && $objCarrierTNT->shipping_handling) {
|
||||
$fltShippingCost += (float)$shipping_handling;
|
||||
}
|
||||
|
||||
// Adding additional shipping cost per product.
|
||||
foreach ($arrProducts as $product) {
|
||||
if (!$product['is_virtual']) {
|
||||
$fltShippingCost += $product['additional_shipping_cost'] * $product['cart_quantity'];
|
||||
}
|
||||
}
|
||||
|
||||
$fltShippingCost = (float)Tools::convertPrice($fltShippingCost, Currency::getCurrencyInstance((int)$objArgCart->id_currency));
|
||||
|
||||
return $fltShippingCost;
|
||||
}
|
||||
}
|
33
www/modules/tntofficiel/libraries/TNTOfficiel_DbUtils.php
Normal file
33
www/modules/tntofficiel/libraries/TNTOfficiel_DbUtils.php
Normal file
@ -0,0 +1,33 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
|
||||
class TNTOfficiel_DbUtils
|
||||
{
|
||||
/**
|
||||
* Gets all the columns name for the given table
|
||||
* @param string $tableName
|
||||
* @return array
|
||||
* @throws PrestaShopDatabaseException
|
||||
*/
|
||||
public static function getColumnsFromTable($tableName)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$sql = 'DESC '._DB_PREFIX_.pSQL($tableName);
|
||||
$results = Db::getInstance()->executeS($sql);
|
||||
$fields = array();
|
||||
foreach ($results as $field) {
|
||||
$fields[] = $field['Field'];
|
||||
}
|
||||
return $fields;
|
||||
}
|
||||
|
||||
}
|
604
www/modules/tntofficiel/libraries/TNTOfficiel_Debug.php
Normal file
604
www/modules/tntofficiel/libraries/TNTOfficiel_Debug.php
Normal file
@ -0,0 +1,604 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/tntofficiel.php';
|
||||
|
||||
class TNTOfficiel_Debug
|
||||
{
|
||||
/**
|
||||
* @var bool Is debugging enabled ?
|
||||
*/
|
||||
private static $boolEnabled = false;
|
||||
/**
|
||||
* @var array List of allowed client IP. No client IP means all allowed.
|
||||
*/
|
||||
private static $arrRemoteIPAddressAllowed = array();
|
||||
|
||||
/**
|
||||
* @var bool Backtrace auto added.
|
||||
*/
|
||||
private static $boolBackTraceAuto = true;
|
||||
/**
|
||||
* @var int Backtrace maximum items.
|
||||
*/
|
||||
private static $intBackTraceMaxDeep = 1; //64;
|
||||
/**
|
||||
* @var bool Backtrace arguments detail at maximum.
|
||||
*/
|
||||
private static $boolBackTraceArgsDetail = false;
|
||||
|
||||
/**
|
||||
* @var array
|
||||
*/
|
||||
private static $arrPHPErrorExclude = array(
|
||||
E_WARNING => array(
|
||||
'/^filemtime\(\): stat failed for/ui'
|
||||
),
|
||||
//E_NOTICE => array()
|
||||
);
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* @var array PHP Errors constant name list.
|
||||
*/
|
||||
private static $arrPHPErrorNames = array(
|
||||
'E_ERROR',
|
||||
'E_RECOVERABLE_ERROR',
|
||||
'E_WARNING',
|
||||
'E_PARSE',
|
||||
'E_NOTICE',
|
||||
'E_STRICT',
|
||||
'E_DEPRECATED', // PHP 5.3+
|
||||
'E_CORE_ERROR',
|
||||
'E_CORE_WARNING',
|
||||
'E_COMPILE_ERROR',
|
||||
'E_COMPILE_WARNING',
|
||||
'E_USER_ERROR',
|
||||
'E_USER_WARNING',
|
||||
'E_USER_NOTICE',
|
||||
'E_USER_DEPRECATED' // PHP 5.3+
|
||||
);
|
||||
/**
|
||||
* @var array PHP Errors map
|
||||
*/
|
||||
private static $arrPHPErrorMap = null;
|
||||
|
||||
/**
|
||||
* @var array JSON Errors constant name list. PHP 5.3.0+.
|
||||
*/
|
||||
private static $arrJSONErrorNames = array(
|
||||
'JSON_ERROR_NONE',
|
||||
'JSON_ERROR_DEPTH',
|
||||
'JSON_ERROR_STATE_MISMATCH',
|
||||
'JSON_ERROR_CTRL_CHAR',
|
||||
'JSON_ERROR_SYNTAX',
|
||||
'JSON_ERROR_UTF8', // PHP 5.3.3+
|
||||
'JSON_ERROR_RECURSION', // PHP 5.5.0+
|
||||
'JSON_ERROR_INF_OR_NAN', // PHP 5.5.0+
|
||||
'JSON_ERROR_UNSUPPORTED_TYPE', // PHP 5.5.0+
|
||||
);
|
||||
/**
|
||||
* @var array JSON Errors map. PHP 5.3.0+.
|
||||
*/
|
||||
private static $arrJSONErrorMap = null;
|
||||
|
||||
|
||||
/**
|
||||
* @var bool
|
||||
*/
|
||||
private static $boolHandlerRegistered = false;
|
||||
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
private static $strRoot = null;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
private static $strFileName = null;
|
||||
|
||||
|
||||
/**
|
||||
* Prevent Construct.
|
||||
*/
|
||||
final private function __construct()
|
||||
{
|
||||
trigger_error(sprintf('%s() %s is static.', __FUNCTION__, get_class($this)), E_USER_ERROR);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if client IP address allowed to use debug.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public static function isClientIPAddressAllowed()
|
||||
{
|
||||
$strRemoteIPAddress = array_key_exists('REMOTE_ADDR', $_SERVER) ? $_SERVER['REMOTE_ADDR'] : null;
|
||||
|
||||
$boolIPAllowed = count(TNTOfficiel_Debug::$arrRemoteIPAddressAllowed) === 0
|
||||
|| in_array($strRemoteIPAddress, TNTOfficiel_Debug::$arrRemoteIPAddressAllowed, true) === true;
|
||||
|
||||
return $boolIPAllowed;
|
||||
}
|
||||
|
||||
/**
|
||||
* Encode to JSON.
|
||||
* @param $arrDebugInfo
|
||||
* @return string
|
||||
*/
|
||||
public static function encJSON($arrDebugInfo)
|
||||
{
|
||||
$flagJSONEncode = 0;
|
||||
$flagJSONEncode |= defined('JSON_PRETTY_PRINT') ? JSON_PRETTY_PRINT : 0;
|
||||
$flagJSONEncode |= defined('JSON_UNESCAPED_UNICODE') ? JSON_UNESCAPED_UNICODE : 0;
|
||||
$flagJSONEncode |= defined('JSON_UNESCAPED_SLASHES') ? JSON_UNESCAPED_SLASHES : 0;
|
||||
|
||||
// PHP < 5.3 return null if second parameter is used.
|
||||
return $flagJSONEncode === 0 ? json_encode($arrDebugInfo) : json_encode($arrDebugInfo, $flagJSONEncode);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $intArgType
|
||||
* @return string
|
||||
*/
|
||||
public static function getPHPErrorType($intArgType)
|
||||
{
|
||||
// Generate constant name mapping.
|
||||
if (TNTOfficiel_Debug::$arrPHPErrorMap === null) {
|
||||
TNTOfficiel_Debug::$arrPHPErrorMap = array();
|
||||
foreach (TNTOfficiel_Debug::$arrPHPErrorNames as $strPHPErrorTypeName) {
|
||||
if (defined($strPHPErrorTypeName)) {
|
||||
$intPHPErrorType = constant($strPHPErrorTypeName);
|
||||
TNTOfficiel_Debug::$arrPHPErrorMap[ $intPHPErrorType ] = $strPHPErrorTypeName;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$strPHPErrorType = array_key_exists($intArgType, TNTOfficiel_Debug::$arrPHPErrorMap) ? TNTOfficiel_Debug::$arrPHPErrorMap[ $intArgType ] : (string)$intArgType;
|
||||
|
||||
return $strPHPErrorType;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @param int $intArgType
|
||||
* @return string
|
||||
*/
|
||||
public static function getJSONErrorType($intArgType)
|
||||
{
|
||||
// Generate constant name mapping.
|
||||
if (TNTOfficiel_Debug::$arrJSONErrorMap === null) {
|
||||
TNTOfficiel_Debug::$arrJSONErrorMap = array();
|
||||
foreach (TNTOfficiel_Debug::$arrJSONErrorNames as $strJSONErrorTypeName) {
|
||||
if (defined($strJSONErrorTypeName)) {
|
||||
$intJSONErrorType = constant($strJSONErrorTypeName);
|
||||
TNTOfficiel_Debug::$arrJSONErrorMap[ $intJSONErrorType ] = $strJSONErrorTypeName;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$strJSONErrorType = array_key_exists($intArgType, TNTOfficiel_Debug::$arrJSONErrorMap) ? TNTOfficiel_Debug::$arrJSONErrorMap[ $intArgType ] : (string)$intArgType;
|
||||
|
||||
return $strJSONErrorType;
|
||||
}
|
||||
|
||||
/**
|
||||
* Capture an Error.
|
||||
*
|
||||
* @param int $intArgType
|
||||
* @param string $strArgMessage
|
||||
* @param string $strArgFile
|
||||
* @param int $intArgLine
|
||||
* @param bool $boolArgIsLast
|
||||
* @return boolean
|
||||
*/
|
||||
public static function captureError($intArgType, $strArgMessage, $strArgFile = null, $intArgLine = 0, $arrArgContext = array(), $boolArgIsLast = false)
|
||||
{
|
||||
$arrLogError = array(
|
||||
'type' => $boolArgIsLast ? 'LastError' : 'Error'
|
||||
);
|
||||
|
||||
if ($strArgFile !== null) {
|
||||
$arrLogError['file'] = $strArgFile;
|
||||
$arrLogError['line'] = $intArgLine;
|
||||
}
|
||||
|
||||
if ($boolArgIsLast) {
|
||||
$arrLogError['trace'] = array();
|
||||
}
|
||||
|
||||
$strType = TNTOfficiel_Debug::getPHPErrorType($intArgType);
|
||||
$arrLogError['msg'] = 'Type '.$strType.': '.$strArgMessage;
|
||||
|
||||
if (array_key_exists($intArgType, TNTOfficiel_Debug::$arrPHPErrorExclude) && is_array(TNTOfficiel_Debug::$arrPHPErrorExclude[$intArgType])) {
|
||||
if (count(TNTOfficiel_Debug::$arrPHPErrorExclude[$intArgType]) === 0) {
|
||||
return false;
|
||||
}
|
||||
foreach (TNTOfficiel_Debug::$arrPHPErrorExclude[$intArgType] as $k => $r) {
|
||||
if (preg_match($r, $strArgMessage) === 1) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
TNTOfficiel_Debug::log($arrLogError);
|
||||
|
||||
// Internal error handler continues (displays/log error, …)
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Capture last Error.
|
||||
* Useful at script end for E_ERROR, E_CORE_ERROR, E_COMPILE_ERROR, E_PARSE, …
|
||||
*/
|
||||
public static function captureLastError()
|
||||
{
|
||||
$arrPHPLastError = error_get_last();
|
||||
|
||||
if (is_array($arrPHPLastError)) {
|
||||
TNTOfficiel_Debug::captureError(
|
||||
$arrPHPLastError['type'],
|
||||
$arrPHPLastError['message'],
|
||||
$arrPHPLastError['file'],
|
||||
$arrPHPLastError['line'],
|
||||
array(),
|
||||
true
|
||||
);
|
||||
}
|
||||
|
||||
// PHP 5.3.0+
|
||||
if (function_exists('json_last_error')) {
|
||||
$intTypeJSONLastError = json_last_error();
|
||||
$strJSONLastErrorType = TNTOfficiel_Debug::getJSONErrorType($intTypeJSONLastError);
|
||||
// PHP 5.5.0+
|
||||
$strJSONLastErrorMessage = function_exists('json_last_error_msg') ? json_last_error_msg() : 'N/A';
|
||||
TNTOfficiel_Debug::captureError($strJSONLastErrorType, $strJSONLastErrorMessage, null, 0, array(), true);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Capture an Exception.
|
||||
*
|
||||
* @param \Exception $objArgException
|
||||
*/
|
||||
public static function captureException($objArgException)
|
||||
{
|
||||
$arrLogException = array(
|
||||
'type' => 'Exception'
|
||||
);
|
||||
|
||||
if ($objArgException->getFile() !== null) {
|
||||
$arrLogException['file'] = $objArgException->getFile();
|
||||
$arrLogException['line'] = $objArgException->getLine();
|
||||
}
|
||||
|
||||
$arrLogException['msg'] = 'Code '.$objArgException->getCode().': '.$objArgException->getMessage();
|
||||
$arrLogException['trace'] = $objArgException->getTrace();
|
||||
|
||||
TNTOfficiel_Debug::log($arrLogException);
|
||||
}
|
||||
|
||||
/**
|
||||
* Capture connection status.
|
||||
*/
|
||||
public static function captureConnectionStatus()
|
||||
{
|
||||
// is non normal connection status.
|
||||
$intStatus = connection_status();
|
||||
// connection_aborted()
|
||||
if ($intStatus & 1) {
|
||||
TNTOfficiel_Debug::log(array(
|
||||
'type' => 'Shutdown',
|
||||
'msg' => sprintf('Connection was aborted by user.')
|
||||
));
|
||||
}
|
||||
if ($intStatus & 2) {
|
||||
TNTOfficiel_Debug::log(array(
|
||||
'type' => 'Shutdown',
|
||||
'msg' => sprintf('Script exceeded maximum execution time.')
|
||||
));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Capture output buffer status.
|
||||
*/
|
||||
public static function captureOutPutBufferStatus()
|
||||
{
|
||||
$msg = 'Output was not sent yet.';
|
||||
|
||||
// is output buffer was sent
|
||||
$strOutputBufferFile = null;
|
||||
$intOutputBufferLine = null;
|
||||
$boolOutputBufferSent = headers_sent($strOutputBufferFile, $intOutputBufferLine);
|
||||
if ($boolOutputBufferSent) {
|
||||
$msg = sprintf('Output was sent in \'%s\' on line %s.', $strOutputBufferFile, $intOutputBufferLine);
|
||||
}
|
||||
|
||||
TNTOfficiel_Debug::log(array(
|
||||
'type' => 'Shutdown',
|
||||
'msg' => $msg,
|
||||
'headers' => headers_list(),
|
||||
'level' => ob_get_level(),
|
||||
'trace' => array()
|
||||
));
|
||||
}
|
||||
|
||||
/**
|
||||
* Capture at shutdown.
|
||||
*/
|
||||
public static function captureAtShutdown()
|
||||
{
|
||||
TNTOfficiel_Debug::captureLastError();
|
||||
TNTOfficiel_Debug::captureConnectionStatus();
|
||||
TNTOfficiel_Debug::captureOutPutBufferStatus();
|
||||
TNTOfficiel_Debug::addLogContent(']');
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Register capture handlers once.
|
||||
*/
|
||||
public static function registerHandlers()
|
||||
{
|
||||
if (TNTOfficiel_Debug::$boolHandlerRegistered !== true) {
|
||||
TNTOfficiel_Debug::$boolHandlerRegistered = true;
|
||||
set_error_handler(array('TNTOfficiel_Debug', 'captureError'));
|
||||
set_exception_handler(array('TNTOfficiel_Debug', 'captureException'));
|
||||
register_shutdown_function(array('TNTOfficiel_Debug', 'captureAtShutdown'));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the script start time.
|
||||
*
|
||||
* @return float
|
||||
*/
|
||||
public static function getStartTime()
|
||||
{
|
||||
return (float)(array_key_exists('REQUEST_TIME_FLOAT', $_SERVER) ? $_SERVER['REQUEST_TIME_FLOAT'] :
|
||||
$_SERVER['REQUEST_TIME']);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Set log root directory.
|
||||
*
|
||||
* @param $strArgRoot
|
||||
*/
|
||||
public static function setRootDirectory($strArgRoot)
|
||||
{
|
||||
TNTOfficiel_Debug::$strRoot = null;
|
||||
|
||||
$strRealpath = realpath($strArgRoot);
|
||||
|
||||
// If not a writable directory.
|
||||
if ($strRealpath === false || !is_dir($strRealpath) || !is_writable($strRealpath)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Add final separator.
|
||||
if (mb_substr($strRealpath, -1) !== DIRECTORY_SEPARATOR) {
|
||||
$strRealpath .= DIRECTORY_SEPARATOR;
|
||||
}
|
||||
|
||||
// Save.
|
||||
TNTOfficiel_Debug::$strRoot = $strRealpath;
|
||||
|
||||
return true;
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Get log filename.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public static function getFilename()
|
||||
{
|
||||
// If root directory is defined, but not the filename.
|
||||
if (TNTOfficiel_Debug::$strRoot !== null && TNTOfficiel_Debug::$strFileName === null) {
|
||||
$floatScriptTime = TNTOfficiel_Debug::getStartTime();
|
||||
$strTimeStamp = var_export($floatScriptTime, true);
|
||||
$strTimeStamp = preg_replace('/^([0-9]+(?:\.[0-9]{1,6}))[0-9]*$/ui', '$1', $strTimeStamp);
|
||||
$strTimeStamp = preg_replace('/\./ui', '', $strTimeStamp);
|
||||
$strTimeStamp = sprintf('%-016s',$strTimeStamp);
|
||||
$strFileNameSuffix = $strTimeStamp.'_'.preg_replace('/[^a-z0-9_]+/ui', '-', parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH));
|
||||
TNTOfficiel_Debug::$strFileName = TNTOfficiel_Debug::$strRoot.'debug_'.$strFileNameSuffix.'.json';
|
||||
}
|
||||
|
||||
return TNTOfficiel_Debug::$strFileName;
|
||||
}
|
||||
|
||||
/**
|
||||
* Create log file if do not exist.
|
||||
* Log global info at creation.
|
||||
*
|
||||
* @param string $strArgDebugInfo
|
||||
* @return bool
|
||||
*/
|
||||
public static function addLogContent($strArgDebugInfo = '')
|
||||
{
|
||||
$strFileName = TNTOfficiel_Debug::getFilename();
|
||||
|
||||
if ($strFileName === null) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// If file don't already exist.
|
||||
if (!file_exists($strFileName)) {
|
||||
$arrDebugInfo = array(
|
||||
'type' => 'StartInfo',
|
||||
'uri' => array_key_exists('REQUEST_URI', $_SERVER) ? $_SERVER['REQUEST_URI'] : null,
|
||||
'referer' => array_key_exists('HTTP_REFERER', $_SERVER) ? $_SERVER['HTTP_REFERER'] : null,
|
||||
'client' => array_key_exists('REMOTE_ADDR', $_SERVER) ? $_SERVER['REMOTE_ADDR'] : null,
|
||||
'post' => $_POST,
|
||||
'get' => $_GET,
|
||||
'cookie' => $_COOKIE
|
||||
);
|
||||
|
||||
$strDebugInfo = '['.TNTOfficiel_Debug::encJSON($arrDebugInfo).',';
|
||||
|
||||
$strArgDebugInfo = $strDebugInfo.$strArgDebugInfo;
|
||||
}
|
||||
|
||||
file_put_contents($strFileName, $strArgDebugInfo, FILE_APPEND);
|
||||
}
|
||||
|
||||
/**
|
||||
* Append log info.
|
||||
*
|
||||
* @param null $arrArg
|
||||
*/
|
||||
public static function log($arrArg = null)
|
||||
{
|
||||
// If not enabled or client IP not allowed.
|
||||
if (TNTOfficiel_Debug::$boolEnabled !== true || TNTOfficiel_Debug::isClientIPAddressAllowed() !== true) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Set default path.
|
||||
//TNTOfficiel_Debug::setRootDirectory(_PS_ROOT_DIR_.'/log/');
|
||||
TNTOfficiel_Debug::setRootDirectory(_PS_MODULE_DIR_.TNTOfficiel::MODULE_NAME.'/'.TNTOfficiel::LOG_DIR);
|
||||
|
||||
// Register handlers if not.
|
||||
TNTOfficiel_Debug::registerHandlers();
|
||||
|
||||
if (!is_array($arrArg)) {
|
||||
$arrArg = array('raw' => $arrArg);
|
||||
}
|
||||
|
||||
// If message, file and line exist, then concat.
|
||||
if (array_key_exists('msg', $arrArg) && array_key_exists('file', $arrArg) && array_key_exists('line', $arrArg)) {
|
||||
$arrArg['msg'] .= ' \''.$arrArg['file'].'\' on line '.$arrArg['line'];
|
||||
unset($arrArg['file']);
|
||||
unset($arrArg['line']);
|
||||
}
|
||||
|
||||
// If no backtrace and auto backtrace set.
|
||||
if (TNTOfficiel_Debug::$boolBackTraceAuto === true
|
||||
&& (!array_key_exists('trace', $arrArg) || !is_array($arrArg['trace']))
|
||||
) {
|
||||
// Get current one.
|
||||
$arrArg['trace'] = debug_backtrace();
|
||||
// Remove trace from this current method.
|
||||
array_shift($arrArg['trace']);
|
||||
}
|
||||
|
||||
// Process backtrace.
|
||||
if (array_key_exists('trace', $arrArg) && is_array($arrArg['trace'])) {
|
||||
|
||||
// Final backtrace.
|
||||
$arrTraceStack = array();
|
||||
|
||||
// Get each trace, deeper first.
|
||||
while ($arrTrace = array_shift($arrArg['trace'])) {
|
||||
|
||||
$intDeepIndex = count($arrTraceStack);
|
||||
// Get stack with maximum items.
|
||||
if ($intDeepIndex >= TNTOfficiel_Debug::$intBackTraceMaxDeep) {
|
||||
break;
|
||||
}
|
||||
|
||||
// function
|
||||
if (array_key_exists('class', $arrTrace) && is_string($arrTrace['class'])) {
|
||||
// Exclude this class.
|
||||
if (in_array($arrTrace['class'], array(__CLASS__), true)) {
|
||||
continue;
|
||||
}
|
||||
$arrTrace['function'] = $arrTrace['class'].$arrTrace['type'].$arrTrace['function'];
|
||||
}
|
||||
// file
|
||||
if (array_key_exists('file', $arrTrace) && is_string($arrTrace['file'])) {
|
||||
$arrTrace['file'] = '\''.$arrTrace['file'].'\' on line '.$arrTrace['line'];
|
||||
} else {
|
||||
$arrTrace['file'] = '[Internal]';
|
||||
}
|
||||
|
||||
// arguments
|
||||
$arrCallerArgs = array();
|
||||
if (array_key_exists('args', $arrTrace) && is_array($arrTrace['args'])) {
|
||||
foreach ($arrTrace['args'] as $k => $mxdTraceArg) {
|
||||
if (is_scalar($mxdTraceArg) || $mxdTraceArg === null) {
|
||||
$arrCallerArgs[ $k ] = $mxdTraceArg;
|
||||
} else {
|
||||
$arrCallerArgs[ $k ] = '('.gettype($mxdTraceArg).')';
|
||||
if (is_object($mxdTraceArg)) {
|
||||
$arrCallerArgs[ $k ] .= get_class($mxdTraceArg);
|
||||
}
|
||||
}
|
||||
}
|
||||
$arrTrace['function'] .= '('.count($arrCallerArgs).')';
|
||||
}
|
||||
|
||||
unset($arrTrace['line']);
|
||||
unset($arrTrace['class']);
|
||||
unset($arrTrace['type']);
|
||||
unset($arrTrace['object']);
|
||||
|
||||
if (TNTOfficiel_Debug::$boolBackTraceArgsDetail === true) {
|
||||
|
||||
// Detecting circular reference, etc ...
|
||||
try {
|
||||
serialize($arrTrace['args']);
|
||||
} catch (Exception $e) {
|
||||
$arrTrace['args'] = $arrCallerArgs;
|
||||
}
|
||||
|
||||
$strArgsJSON = TNTOfficiel_Debug::encJSON($arrTrace['args']);
|
||||
// If unable to encode.
|
||||
if (mb_strlen($strArgsJSON) == 0) {
|
||||
$arrTrace['args'] = $arrCallerArgs;
|
||||
}
|
||||
} else {
|
||||
$arrTrace['args'] = $arrCallerArgs;
|
||||
}
|
||||
|
||||
// If no arguments.
|
||||
if (count($arrCallerArgs) === 0) {
|
||||
// Remove key (no line output).
|
||||
unset($arrTrace['args']);
|
||||
}
|
||||
|
||||
// Add trace.
|
||||
$arrTraceStack[ $intDeepIndex ] = $arrTrace;
|
||||
}
|
||||
|
||||
// Save processed backtrace.
|
||||
$arrArg['trace'] = $arrTraceStack;
|
||||
|
||||
// Remove backtrace key if empty.
|
||||
if (count($arrArg['trace']) === 0) {
|
||||
unset($arrArg['trace']);
|
||||
}
|
||||
}
|
||||
|
||||
// Append time and memory consumption.
|
||||
$arrArg += array(
|
||||
'time' => microtime(true) - TNTOfficiel_Debug::getStartTime(),
|
||||
'mem' => memory_get_peak_usage() / 1024 / 1024,
|
||||
);
|
||||
|
||||
// List of sorted selected key.
|
||||
$arrKeyExistSort = array_intersect_key(array_flip(
|
||||
array('time', 'mem', 'type', 'msg', 'file', 'line', 'trace', 'dump')
|
||||
), $arrArg);
|
||||
// List of unsorted key left.
|
||||
$arrKeyUnExistUnSort = array_diff_key($arrArg, $arrKeyExistSort);
|
||||
// Append unsorted list to sorted.
|
||||
$arrArg = array_merge($arrKeyExistSort, $arrArg) + $arrKeyUnExistUnSort;
|
||||
|
||||
$strDebugInfo = TNTOfficiel_Debug::encJSON($arrArg).',';
|
||||
$strDebugInfo = preg_replace('/}\s*,\s*{/ui', '},{', $strDebugInfo);
|
||||
|
||||
TNTOfficiel_Debug::addLogContent($strDebugInfo);
|
||||
}
|
||||
}
|
578
www/modules/tntofficiel/libraries/TNTOfficiel_Install.php
Normal file
578
www/modules/tntofficiel/libraries/TNTOfficiel_Install.php
Normal file
@ -0,0 +1,578 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/tntofficiel.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Logger.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Carrier.php';
|
||||
|
||||
class TNTOfficiel_Install
|
||||
{
|
||||
/** @var array */
|
||||
public static $arrHookList = array(
|
||||
// Header
|
||||
'displayBackOfficeHeader',
|
||||
'actionAdminControllerSetMedia',
|
||||
'displayHeader',
|
||||
// Front-Office display carrier.
|
||||
'displayBeforeCarrier',
|
||||
'displayCarrierList',
|
||||
// Front-Office display Order created.
|
||||
//'displayOrderConfirmation',
|
||||
// Front-Office order detail.
|
||||
'displayOrderDetail',
|
||||
|
||||
// Back-Office order detail.
|
||||
'displayAdminOrder',
|
||||
|
||||
// Carrier updated.
|
||||
'actionCarrierUpdate',
|
||||
// Order status before changed.
|
||||
'actionOrderStatusUpdate',
|
||||
'actionOrderStatusPostUpdate',
|
||||
// Order created.
|
||||
'actionValidateOrder',
|
||||
|
||||
//
|
||||
//'actionDeliveryPriceByWeight',
|
||||
//'actionDeliveryPriceByPrice',
|
||||
//
|
||||
//'displayPayment',
|
||||
//'displayPaymentReturn',
|
||||
//'actionPaymentConfirmation',
|
||||
//'actionCartSave',
|
||||
//'actionCarrierProcess',
|
||||
//
|
||||
//'actionObjectAddBefore',
|
||||
//'actionObjectAddAfter',
|
||||
//'actionObjectUpdateBefore',
|
||||
//'actionObjectUpdateAfter',
|
||||
//'actionObjectDeleteBefore',
|
||||
//'actionObjectDeleteAfter',
|
||||
//'actionObjectOrderAddBefore',
|
||||
//'actionObjectOrderAddAfter',
|
||||
//'actionObjectOrderUpdateBefore',
|
||||
//'actionObjectOrderUpdateAfter',
|
||||
//'actionObjectOrderDeleteBefore',
|
||||
//'actionObjectOrderDeleteAfter',
|
||||
);
|
||||
|
||||
/** @var array */
|
||||
public static $arrConfigUpdateDeleteList = array(
|
||||
//'TNT_CARRIER_ID' Carrier ID is created on installCarrier, then preserved.
|
||||
//'TNT_GOOGLE_MAP_API_KEY' Google Map API Key is created on config form submit, then preserved.
|
||||
// Authentication information.
|
||||
'TNT_CARRIER_USERNAME' => '',
|
||||
'TNT_CARRIER_ACCOUNT' => '',
|
||||
'TNT_CARRIER_PASSWORD' => '',
|
||||
// Is Authentication information validated.
|
||||
'TNT_CARRIER_ACTIVATED' => false,
|
||||
// Show pickup number in AdminOrdersController.
|
||||
'TNT_CARRIER_PICKUP_NUMBER_SHOW' => '',
|
||||
// Max weight (kg) per parcel.
|
||||
'TNT_CARRIER_MAX_PACKAGE_B2B' => '30.0',
|
||||
'TNT_CARRIER_MAX_PACKAGE_B2C' => '20.0',
|
||||
// Comma separated list of item cart attributes.
|
||||
'TNT_CARRIER_ASSOCIATIONS' => '',
|
||||
// MiddleWare JSON-RPC URL.
|
||||
'TNT_CARRIER_MIDDLEWARE_URL' => 'https://solutions-ecommerce.tnt.fr/api/handler',
|
||||
// MiddleWare IFrame URL.
|
||||
'TNT_CARRIER_MIDDLEWARE_SHORT_URL' => 'https://solutions-ecommerce.tnt.fr/login',
|
||||
'TNT_CARRIER_SOAP_WSDL' => 'https://www.tnt.fr/service/?wsdl',
|
||||
// <TABLE>.<ROW> for ./libraries/TNTOfficiel_Address.php
|
||||
// DB fields used as default values for delivery address extra data.
|
||||
'TNT_CARRIER_ADDRESS_EMAIL' => 'customer.email',
|
||||
'TNT_CARRIER_ADDRESS_PHONE' => 'address.phone_mobile',
|
||||
'TNT_CARRIER_ADDRESS_BUILDING' => '',
|
||||
'TNT_CARRIER_ADDRESS_INTERCOM' => '',
|
||||
'TNT_CARRIER_ADDRESS_FLOOR' => ''
|
||||
);
|
||||
|
||||
/** @var array */
|
||||
public static $arrTemplateOverrideList = array(
|
||||
array(
|
||||
'fileName' => 'view.tpl',
|
||||
'directorySrc' => 'views/templates/admin/override/controllers/admin/templates/orders/helpers/view/',
|
||||
'directoryDst' => 'controllers/admin/templates/orders/helpers/view/',
|
||||
),
|
||||
);
|
||||
|
||||
/**
|
||||
* Prevent Construct.
|
||||
*/
|
||||
final private function __construct()
|
||||
{
|
||||
trigger_error(sprintf('%s() %s is static.', __FUNCTION__, get_class($this)), E_USER_ERROR);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a new directory with default index.php file.
|
||||
*
|
||||
* @param $arrArgDirectoryList an array of directories.
|
||||
*/
|
||||
public static function makeModuleDir($arrArgDirectoryList)
|
||||
{
|
||||
$strIndexFileContent = <<<PHP
|
||||
<?php
|
||||
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
|
||||
header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT");
|
||||
header("Cache-Control: no-store, no-cache, must-revalidate");
|
||||
header("Cache-Control: post-check=0, pre-check=0", false);
|
||||
header("Pragma: no-cache");
|
||||
header("Location: ../");
|
||||
exit;
|
||||
PHP;
|
||||
|
||||
foreach ($arrArgDirectoryList as $strDirectory) {
|
||||
// If directory do not exist, create it.
|
||||
if (!is_dir(_PS_MODULE_DIR_.$strDirectory)) {
|
||||
if (!mkdir(_PS_MODULE_DIR_.$strDirectory, 0777, true)) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
$rscFile = fopen(_PS_MODULE_DIR_.$strDirectory.'index.php', 'w');
|
||||
if ($rscFile === false) {
|
||||
return false;
|
||||
}
|
||||
fwrite($rscFile, $strIndexFileContent);
|
||||
fclose($rscFile);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
public static function clearCache()
|
||||
{
|
||||
// Clear Smarty cache.
|
||||
Tools::clearSmartyCache();
|
||||
// Clear XML cache ('/config/xml/').
|
||||
Tools::clearXMLCache();
|
||||
// Clear current theme cache (/themes/<THEME>/cache/').
|
||||
Media::clearCache();
|
||||
// Clear class index cache for PrestaShopAutoload ('/cache/class_index.php').
|
||||
Tools::generateIndex();
|
||||
/*
|
||||
// Check cache '/cache/class_index.php'
|
||||
$objPSAutoload = PrestaShopAutoload::getInstance();
|
||||
if (
|
||||
!$objPSAutoload->_include_override_path ||
|
||||
//!Configuration::get('PS_DISABLE_OVERRIDES') ||
|
||||
$objPSAutoload->getClassPath('AdminOrdersController') !== 'override/controllers/admin/AdminOrdersController.php' ||
|
||||
$objPSAutoload->getClassPath('Order') !== 'override/classes/order/Order.php' ||
|
||||
$objPSAutoload->getClassPath('OrderHistory') !== 'override/classes/order/OrderHistory.php'
|
||||
) {
|
||||
// Warning !!
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
/**
|
||||
* Update settings fields.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public static function updateSettings()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$boolUpdated = true;
|
||||
|
||||
foreach (TNTOfficiel_Install::$arrConfigUpdateDeleteList as $strCfgName => $mxdValue) {
|
||||
$boolUpdated = $boolUpdated && Configuration::updateValue($strCfgName, $mxdValue);
|
||||
}
|
||||
|
||||
return $boolUpdated;
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete settings fields.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public static function deleteSettings()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$boolDeleted = true;
|
||||
|
||||
foreach (TNTOfficiel_Install::$arrConfigUpdateDeleteList as $strCfgName => $mxdValue) {
|
||||
$boolDeleted = $boolDeleted && Configuration::deleteByName($strCfgName);
|
||||
}
|
||||
|
||||
return $boolDeleted;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Creates the admin Tab.
|
||||
*
|
||||
* @param $arrArgTabNameLang Module name displayed.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public static function createTab($arrArgTabNameLang)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
// Creates the parent tab
|
||||
$parentTab = new Tab();
|
||||
$parentTab->class_name = 'AdminTNTOfficiel';
|
||||
$parentTab->name = $arrArgTabNameLang;
|
||||
$parentTab->module = TNTOfficiel::MODULE_NAME;
|
||||
$parentTab->id_parent = 0;
|
||||
// TODO : AdminParentShipping as parent ?
|
||||
//$parentTab->id_parent = Tab::getIdFromClassName('AdminParentShipping');
|
||||
$boolResult = (bool)($parentTab->add());
|
||||
|
||||
/*
|
||||
if (version_compare(_PS_VERSION_, '1.6', '<')) {
|
||||
$childrenTab = new Tab();
|
||||
$childrenTab->class_name = 'AdminTNTOfficiel';
|
||||
$childrenTab->name = $arrTabNameLang;
|
||||
$childrenTab->module = $strModuleName;
|
||||
$childrenTab->id_parent = Tab::getIdFromClassName('AdminTNTOfficiel');
|
||||
$boolResult15 = (bool)($childrenTab->add());
|
||||
|
||||
return $boolResult && $boolResult15;
|
||||
}
|
||||
*/
|
||||
return $boolResult;
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete the admin Tab.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public static function deleteTab()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$objTabsPSCollection = Tab::getCollectionFromModule(TNTOfficiel::MODULE_NAME)->getAll();
|
||||
foreach ($objTabsPSCollection as $tab) {
|
||||
if (!$tab->delete()) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Update table.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public static function upgradeTables_1_2_20()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$strTablePrefix = _DB_PREFIX_;
|
||||
|
||||
// Test if table tnt_extra_address_data exist.
|
||||
$strSQLTableExtraExist = <<<SQL
|
||||
SHOW TABLES LIKE '${strTablePrefix}tnt_extra_address_data';
|
||||
SQL;
|
||||
// Test if table tnt_order exist.
|
||||
$strSQLTableOrderExist = <<<SQL
|
||||
SHOW TABLES LIKE '${strTablePrefix}tnt_order';
|
||||
SQL;
|
||||
// Test if table tnt_parcel exist.
|
||||
$strSQLTableParcelExist = <<<SQL
|
||||
SHOW TABLES LIKE '${strTablePrefix}tnt_parcel';
|
||||
SQL;
|
||||
|
||||
|
||||
// Dop unused log table.
|
||||
$strSQLTableLogDropTable = <<<SQL
|
||||
DROP TABLE IF EXISTS `${strTablePrefix}tnt_log`;
|
||||
SQL;
|
||||
|
||||
// Add column to tnt_extra_address_data table.
|
||||
$strSQLTableExtraAddColumns = <<<SQL
|
||||
ALTER TABLE `${strTablePrefix}tnt_extra_address_data`
|
||||
ADD COLUMN `carrier_code` VARCHAR(64) NOT NULL DEFAULT '' AFTER `id_address`,
|
||||
ADD COLUMN `carrier_label` VARCHAR(255) NOT NULL DEFAULT '' AFTER `carrier_code`,
|
||||
ADD COLUMN `delivery_point` TEXT NULL AFTER `carrier_label`,
|
||||
ADD COLUMN `delivery_price` DECIMAL(20,6) NOT NULL DEFAULT '0.000000' AFTER `delivery_point`;
|
||||
SQL;
|
||||
// Rename and change existing columns to tnt_extra_address_data table.
|
||||
$strSQLTableExtraChangeColumns = <<<SQL
|
||||
ALTER TABLE `${strTablePrefix}tnt_extra_address_data`
|
||||
CHANGE COLUMN `id_extra_address_data` `id_tntofficiel_cart` INT(10) UNSIGNED NOT NULL AUTO_INCREMENT FIRST,
|
||||
CHANGE COLUMN `id_address` `id_cart` INT(10) UNSIGNED NOT NULL AFTER `id_tntofficiel_cart`,
|
||||
CHANGE COLUMN `email` `customer_email` VARCHAR(128) NOT NULL DEFAULT '' AFTER `delivery_price`,
|
||||
CHANGE COLUMN `mobile_phone` `customer_mobile` VARCHAR(32) NOT NULL DEFAULT '' AFTER `customer_email`,
|
||||
CHANGE COLUMN `building_number` `address_building` VARCHAR(16) NOT NULL DEFAULT '' AFTER `customer_mobile`,
|
||||
CHANGE COLUMN `intercom_code` `address_accesscode` VARCHAR(16) NOT NULL DEFAULT '' AFTER `address_building`,
|
||||
CHANGE COLUMN `floor` `address_floor` VARCHAR(16) NOT NULL DEFAULT '' AFTER `address_accesscode`;
|
||||
SQL;
|
||||
// Rename tnt_extra_address_data table to tntofficiel_cart.
|
||||
$strSQLTableExtraRenameTable = <<<SQL
|
||||
ALTER TABLE `${strTablePrefix}tnt_extra_address_data`
|
||||
RENAME `${strTablePrefix}tntofficiel_cart`;
|
||||
SQL;
|
||||
|
||||
// Rename and change existing columns to tnt_order table.
|
||||
$strSQLTableOrderChangeColumns = <<<SQL
|
||||
ALTER TABLE `${strTablePrefix}tnt_order`
|
||||
CHANGE COLUMN `id_tnt_order` `id_tntofficiel_order` INT(10) UNSIGNED NOT NULL AUTO_INCREMENT FIRST,
|
||||
CHANGE COLUMN `id_order` `id_order` INT(10) UNSIGNED NOT NULL AFTER `id_tntofficiel_order`,
|
||||
CHANGE COLUMN `tnt_product_code` `carrier_code` VARCHAR(64) NOT NULL DEFAULT '' AFTER `id_order`,
|
||||
CHANGE COLUMN `tnt_product_label` `carrier_label` VARCHAR(255) NOT NULL DEFAULT '' AFTER `carrier_code`,
|
||||
CHANGE COLUMN `tnt_xett` `carrier_xett` VARCHAR(5) NOT NULL DEFAULT '' AFTER `carrier_label`,
|
||||
CHANGE COLUMN `tnt_pex` `carrier_pex` VARCHAR(4) NOT NULL DEFAULT '' AFTER `carrier_xett`,
|
||||
CHANGE COLUMN `bt` `bt_filename` VARCHAR(64) NOT NULL DEFAULT '' AFTER `carrier_pex`,
|
||||
CHANGE COLUMN `shipped` `is_shipped` TINYINT(1) NOT NULL DEFAULT '0' AFTER `bt_filename`,
|
||||
CHANGE COLUMN `previous_state` `previous_state` INT(10) UNSIGNED NULL DEFAULT NULL AFTER `is_shipped`,
|
||||
CHANGE COLUMN `pickup_number` `pickup_number` VARCHAR(50) NOT NULL DEFAULT '' AFTER `previous_state`,
|
||||
CHANGE COLUMN `shipping_date` `shipping_date` VARCHAR(10) NOT NULL DEFAULT '' AFTER `pickup_number`,
|
||||
CHANGE COLUMN `due_date` `due_date` VARCHAR(10) NOT NULL DEFAULT '' AFTER `shipping_date`,
|
||||
CHANGE COLUMN `start_date` `start_date` VARCHAR(10) NOT NULL DEFAULT '' AFTER `due_date`;
|
||||
SQL;
|
||||
// Rename tnt_order table to tntofficiel_order.
|
||||
$strSQLTableOrderRenameTable = <<<SQL
|
||||
ALTER TABLE `${strTablePrefix}tnt_order`
|
||||
RENAME `${strTablePrefix}tntofficiel_order`;
|
||||
SQL;
|
||||
|
||||
|
||||
// Change columns.
|
||||
$strSQLTableParcelChangeColumns = <<<SQL
|
||||
ALTER TABLE `${strTablePrefix}tnt_parcels`
|
||||
CHANGE COLUMN `id_parcel` `id_parcel` INT(10) UNSIGNED NOT NULL AUTO_INCREMENT FIRST,
|
||||
CHANGE COLUMN `id_order` `id_order` INT(10) UNSIGNED NOT NULL AFTER `id_parcel`,
|
||||
CHANGE COLUMN `weight` `weight` DECIMAL(20,6) NOT NULL DEFAULT '0.000000';
|
||||
SQL;
|
||||
// Rename tnt_parcels table to tntofficiel_order_parcels.
|
||||
$strSQLTableParcelRenameTable = <<<SQL
|
||||
ALTER TABLE `${strTablePrefix}tnt_parcels`
|
||||
RENAME `${strTablePrefix}tntofficiel_order_parcels`;
|
||||
SQL;
|
||||
|
||||
$objDB = Db::getInstance();
|
||||
|
||||
// Delete table log.
|
||||
if (!$objDB->execute($strSQLTableLogDropTable)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Update table tnt_extra_address_data if exist.
|
||||
$arrDBResult = $objDB->executeS($strSQLTableExtraExist);
|
||||
if(count($arrDBResult) === 1) {
|
||||
if (!$objDB->execute($strSQLTableExtraAddColumns)
|
||||
|| !$objDB->execute($strSQLTableExtraChangeColumns)
|
||||
|| !$objDB->execute($strSQLTableExtraRenameTable)
|
||||
) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
// Update tnt_order if exist.
|
||||
$arrDBResult = $objDB->executeS($strSQLTableOrderExist);
|
||||
if(count($arrDBResult) === 1) {
|
||||
if (!$objDB->execute($strSQLTableOrderChangeColumns)
|
||||
|| !$objDB->execute($strSQLTableOrderRenameTable)
|
||||
) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
// Update tnt_parcel if exist.
|
||||
$arrDBResult = $objDB->executeS($strSQLTableParcelExist);
|
||||
if(count($arrDBResult) === 1) {
|
||||
if (!$objDB->execute($strSQLTableParcelChangeColumns)
|
||||
|| !$objDB->execute($strSQLTableParcelRenameTable)
|
||||
) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates the tables needed by the module.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public static function createTables()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
// Update if required.
|
||||
TNTOfficiel_Install::upgradeTables_1_2_20();
|
||||
|
||||
$strTablePrefix = _DB_PREFIX_;
|
||||
$strTableEngine = _MYSQL_ENGINE_;
|
||||
|
||||
// Create tntofficiel_cart table.
|
||||
$strSQLCreateCart = <<<SQL
|
||||
CREATE TABLE IF NOT EXISTS `${strTablePrefix}tntofficiel_cart` (
|
||||
`id_tntofficiel_cart` INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
|
||||
`id_cart` INT(10) UNSIGNED NOT NULL,
|
||||
`carrier_code` VARCHAR(64) NOT NULL DEFAULT '',
|
||||
`carrier_label` VARCHAR(255) NOT NULL DEFAULT '',
|
||||
`delivery_point` TEXT NULL,
|
||||
`delivery_price` DECIMAL(20,6) NOT NULL DEFAULT '0.000000',
|
||||
`customer_email` VARCHAR(128) NOT NULL DEFAULT '',
|
||||
`customer_mobile` VARCHAR(32) NOT NULL DEFAULT '',
|
||||
`address_building` VARCHAR(16) NOT NULL DEFAULT '',
|
||||
`address_accesscode` VARCHAR(16) NOT NULL DEFAULT '',
|
||||
`address_floor` VARCHAR(16) NOT NULL DEFAULT '',
|
||||
PRIMARY KEY (`id_tntofficiel_cart`)
|
||||
) ENGINE = ${strTableEngine} DEFAULT CHARSET='utf8' COLLATE='utf8_general_ci';
|
||||
SQL;
|
||||
|
||||
// Create tntofficiel_order table.
|
||||
$strSQLCreateOrder = <<<SQL
|
||||
CREATE TABLE IF NOT EXISTS `${strTablePrefix}tntofficiel_order` (
|
||||
`id_tntofficiel_order` INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
|
||||
`id_order` INT(10) UNSIGNED NOT NULL,
|
||||
`carrier_code` VARCHAR(64) NOT NULL DEFAULT '',
|
||||
`carrier_label` VARCHAR(255) NOT NULL DEFAULT '',
|
||||
`carrier_xett` VARCHAR(5) NOT NULL DEFAULT '',
|
||||
`carrier_pex` VARCHAR(4) NOT NULL DEFAULT '',
|
||||
`bt_filename` VARCHAR(64) NOT NULL DEFAULT '',
|
||||
`is_shipped` TINYINT(1) NOT NULL DEFAULT '0',
|
||||
`previous_state` INT(10) UNSIGNED NULL DEFAULT NULL,
|
||||
`pickup_number` VARCHAR(50) NOT NULL DEFAULT '',
|
||||
`shipping_date` VARCHAR(10) NOT NULL DEFAULT '', -- DATETIME NOT NULL,
|
||||
`due_date` VARCHAR(10) NOT NULL DEFAULT '',
|
||||
`start_date` VARCHAR(10) NOT NULL DEFAULT '',
|
||||
PRIMARY KEY (`id_tntofficiel_order`)
|
||||
) ENGINE = ${strTableEngine} DEFAULT CHARSET='utf8' COLLATE='utf8_general_ci';
|
||||
SQL;
|
||||
|
||||
// Create tntofficiel_order_parcels table.
|
||||
$strSQLCreateParcels = <<<SQL
|
||||
CREATE TABLE IF NOT EXISTS `${strTablePrefix}tntofficiel_order_parcels` (
|
||||
`id_parcel` INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
|
||||
`id_order` INT(10) UNSIGNED NOT NULL,
|
||||
`weight` DECIMAL(20,6) NOT NULL DEFAULT '0.000000',
|
||||
`tracking_url` TEXT,
|
||||
`parcel_number` VARCHAR(16),
|
||||
`pdl` TEXT,
|
||||
PRIMARY KEY (`id_parcel`)
|
||||
) ENGINE = ${strTableEngine} DEFAULT CHARSET='utf8' COLLATE='utf8_general_ci';
|
||||
SQL;
|
||||
|
||||
$objDB = Db::getInstance();
|
||||
|
||||
if (!$objDB->execute($strSQLCreateCart)
|
||||
|| !$objDB->execute($strSQLCreateOrder)
|
||||
|| !$objDB->execute($strSQLCreateParcels)
|
||||
) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Create or Restore an existing TNT carrier.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public static function installCarrier()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
// Try to undelete previously deleted carrier.
|
||||
$boolResult = TNTOfficiel_Carrier::undeleteGlobalCarrier();
|
||||
// If not succeed.
|
||||
if (!$boolResult) {
|
||||
// Create a new one.
|
||||
$boolResult = TNTOfficiel_Carrier::createGlobalCarrier();
|
||||
}
|
||||
|
||||
return $boolResult;
|
||||
}
|
||||
|
||||
/**
|
||||
* Add a template override in the override directory.
|
||||
*
|
||||
* @param $strArgModuleDir Module absolute Path.
|
||||
* @return array
|
||||
*/
|
||||
public static function overrideTemplates($strArgModuleDir)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$arrErrors = array();
|
||||
|
||||
foreach (TNTOfficiel_Install::$arrTemplateOverrideList as $arrTemplateOverride) {
|
||||
|
||||
$strPathTemplateSrc = $strArgModuleDir.$arrTemplateOverride['directorySrc'];
|
||||
$strFileTemplateSrc = $strPathTemplateSrc.$arrTemplateOverride['fileName'];
|
||||
$strPathTemplateDst = _PS_OVERRIDE_DIR_.$arrTemplateOverride['directoryDst'];
|
||||
$strFileTemplateDst = $strPathTemplateDst.$arrTemplateOverride['fileName'];
|
||||
|
||||
try {
|
||||
// Create directory if unexist.
|
||||
if (!is_dir($strPathTemplateDst)) {
|
||||
mkdir($strPathTemplateDst, 0777, true);
|
||||
}
|
||||
// Copy new template file.
|
||||
if (!copy($strFileTemplateSrc, $strFileTemplateDst)) {
|
||||
$arrErrors[] = sprintf(Tools::displayError('Impossible d\'installer la surcharge "%s"'), $arrTemplateOverride['fileName']);
|
||||
}
|
||||
} catch (Exception $objException) {
|
||||
$objFileLogger = new FileLogger();
|
||||
$objFileLogger->setFilename(_PS_ROOT_DIR_.'/log/'.date('Ymd').'_tnt_exception.log');
|
||||
$objFileLogger->logError($objException->getMessage());
|
||||
|
||||
$arrErrors[] = sprintf(Tools::displayError('Impossible d\'installer la surcharge "%s"'), $arrTemplateOverride['fileName']);
|
||||
}
|
||||
}
|
||||
|
||||
return $arrErrors;
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete a template override in the override directory.
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public static function unOverrideTemplates()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$arrErrors = array();
|
||||
|
||||
// Unoverride templates.
|
||||
foreach (TNTOfficiel_Install::$arrTemplateOverrideList as $arrTemplateOverride) {
|
||||
$strPathTemplateDst = _PS_OVERRIDE_DIR_.$arrTemplateOverride['directoryDst'];
|
||||
$strFileTemplateDst = $strPathTemplateDst.$arrTemplateOverride['fileName'];
|
||||
|
||||
try {
|
||||
// Create directory if not found.
|
||||
if (!is_dir($strPathTemplateDst)) {
|
||||
mkdir($strPathTemplateDst, 0777, true);
|
||||
}
|
||||
// Delete previous template file if exist.
|
||||
if (file_exists($strFileTemplateDst)) {
|
||||
if(!unlink($strFileTemplateDst)) {
|
||||
$arrErrors[] = sprintf(Tools::displayError('Impossible de supprimer la surcharge "%s"'), $arrTemplateOverride['fileName']);
|
||||
}
|
||||
}
|
||||
} catch (Exception $objException) {
|
||||
$objFileLogger = new FileLogger();
|
||||
$objFileLogger->setFilename(_PS_ROOT_DIR_.'/log/'.date('Ymd').'_tnt_exception.log');
|
||||
$objFileLogger->logError($objException->getMessage());
|
||||
|
||||
$arrErrors[] = sprintf(Tools::displayError('Impossible de supprimer la surcharge "%s"'), $arrTemplateOverride['fileName']);
|
||||
}
|
||||
}
|
||||
|
||||
return $arrErrors;
|
||||
}
|
||||
}
|
410
www/modules/tntofficiel/libraries/TNTOfficiel_JsonRPCClient.php
Normal file
410
www/modules/tntofficiel/libraries/TNTOfficiel_JsonRPCClient.php
Normal file
@ -0,0 +1,410 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
|
||||
class TNTOfficiel_AccessDeniedException extends Exception {}
|
||||
class TNTOfficiel_ConnectionFailureException extends Exception {}
|
||||
class TNTOfficiel_ServerErrorException extends Exception {}
|
||||
|
||||
/**
|
||||
* JsonRPC client class
|
||||
*
|
||||
* @package JsonRPC
|
||||
* @author Frederic Guillot
|
||||
*/
|
||||
class TNTOfficiel_JsonRPCClient
|
||||
{
|
||||
/**
|
||||
* URL of the server
|
||||
*
|
||||
* @access private
|
||||
* @var string
|
||||
*/
|
||||
private $url;
|
||||
/**
|
||||
* If the only argument passed to a function is an array
|
||||
* assume it contains named arguments
|
||||
*
|
||||
* @access public
|
||||
* @var boolean
|
||||
*/
|
||||
public $named_arguments = true;
|
||||
/**
|
||||
* HTTP client timeout
|
||||
*
|
||||
* @access private
|
||||
* @var integer
|
||||
*/
|
||||
private $timeout;
|
||||
/**
|
||||
* Username for authentication
|
||||
*
|
||||
* @access private
|
||||
* @var string
|
||||
*/
|
||||
private $username;
|
||||
/**
|
||||
* Password for authentication
|
||||
*
|
||||
* @access private
|
||||
* @var string
|
||||
*/
|
||||
private $password;
|
||||
/**
|
||||
* True for a batch request
|
||||
*
|
||||
* @access public
|
||||
* @var boolean
|
||||
*/
|
||||
public $is_batch = false;
|
||||
/**
|
||||
* Batch payload
|
||||
*
|
||||
* @access public
|
||||
* @var array
|
||||
*/
|
||||
public $batch = array();
|
||||
/**
|
||||
* Enable debug output to the php error log
|
||||
*
|
||||
* @access public
|
||||
* @var boolean
|
||||
*/
|
||||
public $debug = false;
|
||||
/**
|
||||
* Default HTTP headers to send to the server
|
||||
*
|
||||
* @access private
|
||||
* @var array
|
||||
*/
|
||||
private $headers = array(
|
||||
'User-Agent: JSON-RPC PHP Client <https://github.com/fguillot/JsonRPC>',
|
||||
'Content-Type: application/json',
|
||||
'Accept: application/json',
|
||||
'Connection: close',
|
||||
);
|
||||
/**
|
||||
* SSL certificates verification
|
||||
*
|
||||
* @access public
|
||||
* @var boolean
|
||||
*/
|
||||
public $ssl_verify_peer = true;
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
*
|
||||
* @access public
|
||||
* @param string $url Server URL
|
||||
* @param integer $timeout HTTP timeout
|
||||
* @param array $headers Custom HTTP headers
|
||||
*/
|
||||
public function __construct($url, $timeout = 3, $headers = array())
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->url = $url;
|
||||
$this->timeout = $timeout;
|
||||
$this->headers = array_merge($this->headers, $headers);
|
||||
}
|
||||
|
||||
/**
|
||||
* Automatic mapping of procedures
|
||||
*
|
||||
* @access public
|
||||
* @param string $method Procedure name
|
||||
* @param array $params Procedure arguments
|
||||
* @return mixed
|
||||
*/
|
||||
public function __call($method, array $params)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
// Allow to pass an array and use named arguments
|
||||
if ($this->named_arguments && count($params) === 1 && is_array($params[0])) {
|
||||
$params = $params[0];
|
||||
}
|
||||
return $this->execute($method, $params);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set authentication parameters
|
||||
*
|
||||
* @access public
|
||||
* @param string $username Username
|
||||
* @param string $password Password
|
||||
* @return Client
|
||||
*/
|
||||
public function authentication($username, $password)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->username = $username;
|
||||
$this->password = $password;
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Start a batch request
|
||||
*
|
||||
* @access public
|
||||
* @return Client
|
||||
*/
|
||||
public function batch()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->is_batch = true;
|
||||
$this->batch = array();
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Send a batch request
|
||||
*
|
||||
* @access public
|
||||
* @return array
|
||||
*/
|
||||
public function send()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->is_batch = false;
|
||||
return $this->parseResponse(
|
||||
$this->doRequest($this->batch)
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Execute a procedure
|
||||
*
|
||||
* @access public
|
||||
* @param string $procedure Procedure name
|
||||
* @param array $params Procedure arguments
|
||||
* @return mixed
|
||||
*/
|
||||
public function execute($procedure, array $params = array())
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$params['date'] = time();
|
||||
if ($this->is_batch) {
|
||||
$this->batch[] = $this->prepareRequest($procedure, $params);
|
||||
return $this;
|
||||
}
|
||||
return $this->parseResponse(
|
||||
$this->_doRequest($this->prepareRequest($procedure, $params))
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Prepare the payload
|
||||
*
|
||||
* @access public
|
||||
* @param string $procedure Procedure name
|
||||
* @param array $params Procedure arguments
|
||||
* @return array
|
||||
*/
|
||||
public function prepareRequest($procedure, array $params = array())
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$payload = array(
|
||||
'jsonrpc' => '2.0',
|
||||
'method' => $procedure,
|
||||
'id' => mt_rand()
|
||||
);
|
||||
if (! empty($params)) {
|
||||
$payload['params'] = $params;
|
||||
}
|
||||
return $payload;
|
||||
}
|
||||
|
||||
/**
|
||||
* Parse the response and return the procedure result
|
||||
*
|
||||
* @access public
|
||||
* @param array $payload
|
||||
* @return mixed
|
||||
*/
|
||||
public function parseResponse(array $payload)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
if ($this->isBatchResponse($payload)) {
|
||||
$results = array();
|
||||
foreach ($payload as $response) {
|
||||
$results[] = $this->getResult($response);
|
||||
}
|
||||
return $results;
|
||||
}
|
||||
return $this->getResult($payload);
|
||||
}
|
||||
|
||||
/**
|
||||
* Throw an exception according the RPC error
|
||||
*
|
||||
* @access public
|
||||
* @param array $error
|
||||
* @throws BadFunctionCallException
|
||||
* @throws InvalidArgumentException
|
||||
* @throws RuntimeException
|
||||
*/
|
||||
public function handleRpcErrors(array $error)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
switch ($error['code']) {
|
||||
case -32601:
|
||||
throw new BadFunctionCallException('Procedure not found: '. $error['message']);
|
||||
case -32602:
|
||||
throw new InvalidArgumentException('Invalid arguments: '. $error['message']);
|
||||
default:
|
||||
throw new RuntimeException('Invalid request/response: '. $error['message'], $error['code']);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Throw an exception according the HTTP response
|
||||
*
|
||||
* @access public
|
||||
* @param array $headers
|
||||
* @throws TNTOfficiel_AccessDeniedException
|
||||
* @throws TNTOfficiel_ServerErrorException
|
||||
*/
|
||||
public function handleHttpErrors(array $headers)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$exceptions = array(
|
||||
'401' => 'TNTOfficiel_AccessDeniedException',
|
||||
'403' => 'TNTOfficiel_AccessDeniedException',
|
||||
'404' => 'TNTOfficiel_ConnectionFailureException',
|
||||
'500' => 'TNTOfficiel_ServerErrorException',
|
||||
);
|
||||
foreach ($headers as $header) {
|
||||
foreach ($exceptions as $code => $exception) {
|
||||
if (strpos($header, 'HTTP/1.0 '.$code) !== false || strpos($header, 'HTTP/1.1 '.$code) !== false) {
|
||||
throw new $exception('Response: '.$header);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Do the HTTP request
|
||||
*
|
||||
* @access private
|
||||
* @param array $payload
|
||||
* @return array
|
||||
* @throws TNTOfficiel_ConnectionFailureException
|
||||
*/
|
||||
private function _doRequest(array $payload)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
if (extension_loaded('curl')) {
|
||||
$ch = curl_init(trim($this->url));
|
||||
curl_setopt_array($ch, array(
|
||||
CURLOPT_RETURNTRANSFER => true,
|
||||
CURLOPT_HTTPHEADER => $this->headers,
|
||||
CURLOPT_POST => true,
|
||||
CURLOPT_POSTFIELDS => Tools::jsonEncode($payload),
|
||||
CURLOPT_RETURNTRANSFER => true,
|
||||
));
|
||||
|
||||
$response = Tools::jsonDecode(curl_exec($ch), true);
|
||||
curl_close($ch);
|
||||
if (!$response) {
|
||||
throw new TNTOfficiel_ConnectionFailureException('Unable to establish a connection');
|
||||
}
|
||||
} else {
|
||||
$stream = @fopen(trim($this->url), 'r', false, $this->_getContext($payload));
|
||||
if (!is_resource($stream)) {
|
||||
throw new TNTOfficiel_ConnectionFailureException('Unable to establish a connection');
|
||||
}
|
||||
$metadata = stream_get_meta_data($stream);
|
||||
$this->handleHttpErrors($metadata['wrapper_data']);
|
||||
$response = Tools::jsonDecode(stream_get_contents($stream), true);
|
||||
}
|
||||
|
||||
if ($this->debug) {
|
||||
error_log('==> Request: ' . PHP_EOL . Tools::jsonEncode($payload, JSON_PRETTY_PRINT));
|
||||
error_log('==> Response: ' . PHP_EOL . Tools::jsonEncode($response, JSON_PRETTY_PRINT));
|
||||
}
|
||||
|
||||
TNTOfficiel_Debug::log(array('msg' => '<<', 'file' => __FILE__, 'line' => __LINE__, 'dump' => array('request' => $payload, 'response' => $response)));
|
||||
|
||||
return is_array($response) ? $response : array();
|
||||
}
|
||||
|
||||
/**
|
||||
* Prepare stream context
|
||||
*
|
||||
* @access private
|
||||
* @param array $payload
|
||||
* @return resource
|
||||
*/
|
||||
private function getContext(array $payload)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$headers = $this->headers;
|
||||
if (! empty($this->username) && ! empty($this->password)) {
|
||||
$headers[] = 'Authorization: Basic '.base64_encode($this->username.':'.$this->password);
|
||||
}
|
||||
return stream_context_create(array(
|
||||
'http' => array(
|
||||
'method' => 'POST',
|
||||
'protocol_version' => 1.1,
|
||||
'timeout' => $this->timeout,
|
||||
'max_redirects' => 2,
|
||||
'header' => implode("\r\n", $headers),
|
||||
'content' => Tools::jsonEncode($payload),
|
||||
'ignore_errors' => true,
|
||||
),
|
||||
"ssl" => array(
|
||||
"verify_peer" => $this->ssl_verify_peer,
|
||||
"verify_peer_name" => $this->ssl_verify_peer,
|
||||
)
|
||||
));
|
||||
}
|
||||
|
||||
/**
|
||||
* Return true if we have a batch response
|
||||
*
|
||||
* @access public
|
||||
* @param array $payload
|
||||
* @return boolean
|
||||
*/
|
||||
private function isBatchResponse(array $payload)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
return array_keys($payload) === range(0, count($payload) - 1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get a RPC call result
|
||||
*
|
||||
* @access private
|
||||
* @param array $payload
|
||||
* @return mixed
|
||||
*/
|
||||
private function getResult(array $payload)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
if (isset($payload['error']['code'])) {
|
||||
$this->handleRpcErrors($payload['error']);
|
||||
}
|
||||
return isset($payload['result']) ? $payload['result'] : null;
|
||||
}
|
||||
}
|
181
www/modules/tntofficiel/libraries/TNTOfficiel_Logger.php
Normal file
181
www/modules/tntofficiel/libraries/TNTOfficiel_Logger.php
Normal file
@ -0,0 +1,181 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/tntofficiel.php';
|
||||
|
||||
class TNTOfficiel_Logger extends AbstractLogger
|
||||
{
|
||||
/**
|
||||
* @param $request
|
||||
* @param null $message
|
||||
* @param string $format
|
||||
* @param bool|false $isRequest
|
||||
* @param null $status
|
||||
* @param null $data
|
||||
* @return bool
|
||||
*/
|
||||
public function logMessageTnt($request, $message = null, $format = 'JSON', $isRequest = false, $status = null, $data = null)
|
||||
{
|
||||
try {
|
||||
$this->_createLogFolder();
|
||||
if ($isRequest) {
|
||||
$formattedMessage = $this->_formatMessageRequest($status, $format, $request);
|
||||
} else {
|
||||
$formattedMessage = $this->_formatErrorMessage($message, $format, $request, $data);
|
||||
}
|
||||
} catch (Exception $objException) {
|
||||
$objFileLogger = new FileLogger();
|
||||
$objFileLogger->setFilename(_PS_ROOT_DIR_.'/log/'.date('Ymd').'_tnt_exception.log');
|
||||
$objFileLogger->logError($objException->getMessage());
|
||||
}
|
||||
|
||||
$strLogPath = _PS_MODULE_DIR_.TNTOfficiel::MODULE_NAME.'/'.TNTOfficiel::LOG_DIR;
|
||||
return (bool)file_put_contents($strLogPath.$this->_getFileName($isRequest), $formattedMessage, FILE_APPEND);
|
||||
}
|
||||
|
||||
public function logMessage($message, $level)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates the log folder if not exist
|
||||
*/
|
||||
private function _createLogFolder()
|
||||
{
|
||||
$strLogPath = _PS_MODULE_DIR_.TNTOfficiel::MODULE_NAME.'/'.TNTOfficiel::LOG_DIR;
|
||||
if (!is_dir($strLogPath)) {
|
||||
mkdir($strLogPath, 0777, true);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the log file name
|
||||
* @param $isRequest
|
||||
* @return string
|
||||
*/
|
||||
private function _getFileName($isRequest)
|
||||
{
|
||||
$dateTime = new DateTime();
|
||||
$date = $dateTime->format('Ymd');
|
||||
if ($isRequest) {
|
||||
$fileName = sprintf('TNT-request-%s', $date);
|
||||
} else {
|
||||
$fileName = sprintf('TNT-errors-%s', $date);
|
||||
}
|
||||
|
||||
return $fileName.'.log';
|
||||
}
|
||||
|
||||
/**
|
||||
* Format the message for a request log
|
||||
* @param $status
|
||||
* @param $format
|
||||
* @param $request
|
||||
* @return string
|
||||
*/
|
||||
private function _formatMessageRequest($status, $format, $request)
|
||||
{
|
||||
$dateTime = new DateTime();
|
||||
$date = $dateTime->format('Ymd H:i:s');
|
||||
$account = Configuration::get('TNT_CARRIER_ACCOUNT');
|
||||
$formattedMessage = sprintf('%s - %s %s %s:%s %s', $date, $account, $status, $format, $request, chr(10));
|
||||
|
||||
return $formattedMessage;
|
||||
}
|
||||
|
||||
/**
|
||||
* Format the message for an error log
|
||||
* @param $message
|
||||
* @param $format
|
||||
* @param $request
|
||||
* @param $data
|
||||
* @return string
|
||||
*/
|
||||
private function _formatErrorMessage($message, $format, $request, $data)
|
||||
{
|
||||
$dateTime = new DateTime();
|
||||
$date = $dateTime->format('Ymd H:i:s');
|
||||
$account = Configuration::get('TNT_CARRIER_ACCOUNT');
|
||||
$formattedMessage = sprintf('%s - %s %s:%s Error %s || %s %s', $date, $account, $format, $request, $message, $data, chr(10));
|
||||
|
||||
return $formattedMessage;
|
||||
}
|
||||
|
||||
/**
|
||||
* Log install and uninstall steps
|
||||
* @param $message
|
||||
* @return bool
|
||||
*/
|
||||
public function logInstall($message)
|
||||
{
|
||||
$dateTime = new DateTime();
|
||||
$date = $dateTime->format('Ymd H:i:s');
|
||||
$logMessage = sprintf('%s %s %s', $date, $message, chr(10));
|
||||
$filename = 'install.log';
|
||||
try {
|
||||
$this->_createLogFolder();
|
||||
} catch (Exception $objException) {
|
||||
$objFileLogger = new FileLogger();
|
||||
$objFileLogger->setFilename(_PS_ROOT_DIR_.'/log/'.date('Ymd').'_tnt_exception.log');
|
||||
$objFileLogger->logError($objException->getMessage());
|
||||
}
|
||||
|
||||
$strLogPath = _PS_MODULE_DIR_.TNTOfficiel::MODULE_NAME.'/'.TNTOfficiel::LOG_DIR;
|
||||
return (bool)file_put_contents($strLogPath.$filename, $logMessage, FILE_APPEND);
|
||||
}
|
||||
|
||||
/**
|
||||
* Log install and uninstall steps
|
||||
* @param $message
|
||||
* @return bool
|
||||
*/
|
||||
public function logUninstall($message)
|
||||
{
|
||||
$dateTime = new DateTime();
|
||||
$date = $dateTime->format('Ymd H:i:s');
|
||||
$logMessage = sprintf('%s %s %s', $date, $message, chr(10));
|
||||
$filename = 'uninstall.log';
|
||||
try {
|
||||
$this->_createLogFolder();
|
||||
} catch (Exception $objException) {
|
||||
$objFileLogger = new FileLogger();
|
||||
$objFileLogger->setFilename(_PS_ROOT_DIR_.'/log/'.date('Ymd').'_tnt_exception.log');
|
||||
$objFileLogger->logError($objException->getMessage());
|
||||
}
|
||||
|
||||
$strLogPath = _PS_MODULE_DIR_.TNTOfficiel::MODULE_NAME.'/'.TNTOfficiel::LOG_DIR;
|
||||
return (bool)file_put_contents($strLogPath.$filename, $logMessage, FILE_APPEND);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generate an archive containing all the logs files
|
||||
*
|
||||
* @param $zipName
|
||||
* @return ZipArchive
|
||||
*/
|
||||
public static function getZip($zipName)
|
||||
{
|
||||
$strLogPath = _PS_MODULE_DIR_.TNTOfficiel::MODULE_NAME.'/'.TNTOfficiel::LOG_DIR;
|
||||
$files = scandir($strLogPath);
|
||||
|
||||
$zip = new ZipArchive();
|
||||
$zip->open($zipName, ZipArchive::CREATE);
|
||||
foreach ($files as $file) {
|
||||
$filePath = $strLogPath.$file;
|
||||
$strExt = pathinfo($file, PATHINFO_EXTENSION);
|
||||
if (in_array($strExt, array('log', 'json'), true) && file_exists($filePath)) {
|
||||
$zip->addFromString(basename($filePath), Tools::file_get_contents($filePath));
|
||||
}
|
||||
}
|
||||
$zip->close();
|
||||
return $zip;
|
||||
}
|
||||
|
||||
}
|
95
www/modules/tntofficiel/libraries/TNTOfficiel_Parcel.php
Normal file
95
www/modules/tntofficiel/libraries/TNTOfficiel_Parcel.php
Normal file
@ -0,0 +1,95 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
|
||||
class TNTOfficiel_Parcel
|
||||
{
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
private $parcelId;
|
||||
|
||||
/**
|
||||
* @var array
|
||||
*/
|
||||
private $productList;
|
||||
|
||||
/**
|
||||
* @var float
|
||||
*/
|
||||
private $weight = 0;
|
||||
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
private $lastAddedProductId;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
}
|
||||
|
||||
/**
|
||||
* @return int
|
||||
*/
|
||||
public function getParcelId()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
return $this->parcelId;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $parcelId
|
||||
*/
|
||||
public function setParcelId($parcelId)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->parcelId = $parcelId;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return array
|
||||
*/
|
||||
public function getProductList()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
return $this->productList;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return float
|
||||
*/
|
||||
public function getWeight()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
return $this->weight;
|
||||
}
|
||||
|
||||
/**
|
||||
* Add a product to the product list and update the weight;.
|
||||
*
|
||||
* @param $product
|
||||
*/
|
||||
public function addProduct($product)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->productList[$product['id_product']] = $product; //add the product
|
||||
$this->weight += $product['weight']; //update the parcel's weight
|
||||
$this->lastAddedProductId = $product['id_product']; //save the last added product id
|
||||
}
|
||||
}
|
@ -0,0 +1,63 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
|
||||
class TNTOfficiel_PasswordManager
|
||||
{
|
||||
static $salt = '0hp6df7j46df4gc6df42nfhf6i9gfdzz';
|
||||
|
||||
/**
|
||||
* Encrypt password
|
||||
* @param $password
|
||||
* @return string
|
||||
*/
|
||||
public static function encrypt($password)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$encryptedPwd = trim(base64_encode(mcrypt_encrypt(
|
||||
MCRYPT_RIJNDAEL_256, TNTOfficiel_PasswordManager::$salt, $password, MCRYPT_MODE_ECB,
|
||||
mcrypt_create_iv(mcrypt_get_iv_size(MCRYPT_RIJNDAEL_256, MCRYPT_MODE_ECB), MCRYPT_RAND)
|
||||
)));
|
||||
|
||||
return $encryptedPwd;
|
||||
}
|
||||
|
||||
/**
|
||||
* Decrypt password
|
||||
* @param $password
|
||||
* @return string
|
||||
*/
|
||||
public static function decrypt($password)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$decryptedPwd = trim(mcrypt_decrypt(
|
||||
MCRYPT_RIJNDAEL_256, TNTOfficiel_PasswordManager::$salt, base64_decode($password), MCRYPT_MODE_ECB,
|
||||
mcrypt_create_iv(mcrypt_get_iv_size(MCRYPT_RIJNDAEL_256, MCRYPT_MODE_ECB), MCRYPT_RAND)
|
||||
));
|
||||
|
||||
return $decryptedPwd;
|
||||
}
|
||||
|
||||
/**
|
||||
* get a sha1 hash of the password
|
||||
* @return string
|
||||
*/
|
||||
public static function getHash()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$hashedPwd = sha1(TNTOfficiel_PasswordManager::decrypt(Configuration::get('TNT_CARRIER_PASSWORD')));
|
||||
|
||||
return $hashedPwd;
|
||||
}
|
||||
|
||||
}
|
50
www/modules/tntofficiel/libraries/TNTOfficiel_Product.php
Normal file
50
www/modules/tntofficiel/libraries/TNTOfficiel_Product.php
Normal file
@ -0,0 +1,50 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_DbUtils.php';
|
||||
|
||||
class TNTOfficiel_Product
|
||||
{
|
||||
/**
|
||||
* Get the configured attributes for a product.
|
||||
*
|
||||
* @param int $productId
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public static function getProductAttributes($productId)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
//configured attributes
|
||||
$tntCarrierAssociations = Configuration::get('TNT_CARRIER_ASSOCIATIONS');
|
||||
$attributesNames = array();
|
||||
if (!empty($tntCarrierAssociations)) {
|
||||
$attributesNames = explode(',', $tntCarrierAssociations);
|
||||
}
|
||||
|
||||
//columns from the product table
|
||||
$productColumns = TNTOfficiel_DbUtils::getColumnsFromTable('product');
|
||||
$attributes = array();
|
||||
$attribute = array();
|
||||
//product
|
||||
$product = Db::getInstance()->getRow('SELECT * FROM '._DB_PREFIX_.'product WHERE id_product = '.(int)$productId);
|
||||
|
||||
foreach ($attributesNames as $attributeName) {
|
||||
if (in_array($attributeName, $productColumns)) {
|
||||
$attribute['code'] = $attributeName;
|
||||
$attribute['value'] = $product[$attributeName];
|
||||
$attributes[] = $attribute;
|
||||
}
|
||||
}
|
||||
|
||||
return $attributes;
|
||||
}
|
||||
}
|
@ -0,0 +1,30 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
|
||||
|
||||
class TNTOfficiel_ServiceCache
|
||||
{
|
||||
/**
|
||||
* Gets the number of seconds between the current time and next midnight
|
||||
* @return int
|
||||
*/
|
||||
public static function getSecondsUntilMidnight()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$now = time();
|
||||
$midnight = strtotime('tomorrow midnight');
|
||||
$secondsUntilMidnight = $midnight - $now;
|
||||
|
||||
return $secondsUntilMidnight;
|
||||
}
|
||||
|
||||
}
|
115
www/modules/tntofficiel/libraries/TNTOfficiel_SoapClient.php
Normal file
115
www/modules/tntofficiel/libraries/TNTOfficiel_SoapClient.php
Normal file
@ -0,0 +1,115 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_PasswordManager.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Logger.php';
|
||||
|
||||
class TNTOfficiel_SoapClient
|
||||
{
|
||||
protected $_username;
|
||||
protected $_password;
|
||||
protected $_account;
|
||||
protected $_wsdl;
|
||||
private $logger;
|
||||
|
||||
/**
|
||||
* Constructor : Set Data
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->_username = Configuration::get('TNT_CARRIER_USERNAME');
|
||||
$this->_password = TNTOfficiel_PasswordManager::decrypt(Configuration::get('TNT_CARRIER_PASSWORD'));
|
||||
$this->_account = Configuration::get('TNT_CARRIER_ACCOUNT');
|
||||
$this->_wsdl = Configuration::get('TNT_CARRIER_SOAP_WSDL');
|
||||
|
||||
$this->logger = new TNTOfficiel_Logger();
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $reference
|
||||
* @return bool|array
|
||||
*/
|
||||
public function trackingByConsignment($reference)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
try {
|
||||
$client = $this->createClient();
|
||||
$response = $client->trackingByConsignment(array('parcelNumber' => $reference));
|
||||
$this->logger->logMessageTnt('trackingByConsignment', null, 'JSON', true, 'SUCCESS');
|
||||
} catch (Exception $objException) {
|
||||
$strStatus = ($objException->getCode() == 500) ? 'FATAL' : 'ERROR';
|
||||
$strMsg = $objException->getMessage();
|
||||
$this->logger->logMessageTnt('trackingByConsignment', $strMsg, 'JSON', false, $strStatus);
|
||||
return false;
|
||||
}
|
||||
|
||||
return $response;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return an instance of SoapHeader for WS Security
|
||||
*
|
||||
* @param string $login
|
||||
* @param string $password
|
||||
*
|
||||
* @return \SoapHeader
|
||||
*/
|
||||
public function getSecurityHeader($login, $password)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$authHeader = sprintf(
|
||||
$this->getSecurityHeaderTemplate(), htmlspecialchars($login), htmlspecialchars($password)
|
||||
);
|
||||
|
||||
return $authHeader;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return template for WS Security header
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
protected function getSecurityHeaderTemplate()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
return '<wsse:Security xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd">
|
||||
<wsse:UsernameToken>
|
||||
<wsse:Username>%s</wsse:Username>
|
||||
<wsse:Password>%s</wsse:Password>
|
||||
</wsse:UsernameToken>
|
||||
</wsse:Security>';
|
||||
}
|
||||
|
||||
/**
|
||||
* Return a new instance of SoapClient
|
||||
*
|
||||
* @return \SoapClient
|
||||
*/
|
||||
public function createClient()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$client = new SoapClient($this->_wsdl, array(
|
||||
'soap_version' => SOAP_1_1,
|
||||
'trace' => 1,
|
||||
));
|
||||
$authvars = new SoapVar($this->getSecurityHeader($this->_username, $this->_password), XSD_ANYXML);
|
||||
$soapHeaders = new SoapHeader("http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd", "Security", $authvars);
|
||||
$client->__setSOAPHeaders($soapHeaders);
|
||||
|
||||
return $client;
|
||||
}
|
||||
|
||||
}
|
256
www/modules/tntofficiel/libraries/TNTOfficiel_SysCheck.php
Normal file
256
www/modules/tntofficiel/libraries/TNTOfficiel_SysCheck.php
Normal file
@ -0,0 +1,256 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/tntofficiel.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_PasswordManager.php';
|
||||
|
||||
class TNTOfficiel_SysCheck
|
||||
{
|
||||
public static function getPHPConfig()
|
||||
{
|
||||
$arrUser = posix_getpwuid(posix_geteuid());
|
||||
|
||||
$arrEnv = array(
|
||||
'http_proxy' => getenv('http_proxy'),
|
||||
'https_proxy' => getenv('https_proxy'),
|
||||
'ftp_proxy' => getenv('ftp_proxy')
|
||||
);
|
||||
|
||||
$arrPHPConstants = array(
|
||||
'PHP_OS' => PHP_OS,
|
||||
'PHP_VERSION' => PHP_VERSION,
|
||||
'PHP_SAPI' => PHP_SAPI,
|
||||
'PHP_INT_SIZE (bits)' => PHP_INT_SIZE * 8
|
||||
);
|
||||
|
||||
$arrPHPExtensions = array_intersect_key(array_flip(get_loaded_extensions()), array(
|
||||
'curl' => true,
|
||||
'session' => true,
|
||||
'mcrypt' => true,
|
||||
'mhash' => true,
|
||||
'mbstring' => true,
|
||||
'iconv' => true,
|
||||
'zip' => true,
|
||||
'zlib' => true,
|
||||
'dom' => true,
|
||||
'xml' => true,
|
||||
'SimpleXML' => true,
|
||||
'Zend OPcache' => true,
|
||||
'ionCube Loader' => true
|
||||
));
|
||||
|
||||
$arrPHPConfiguration = array_intersect_key(ini_get_all(null, false), array(
|
||||
// php
|
||||
'magic_quotes' => 'Off',
|
||||
'magic_quotes_gpc' => 'Off',
|
||||
'max_input_vars' => '8192',
|
||||
// core - file uploads
|
||||
'upload_max_filesize' => '4M',
|
||||
// core - language options
|
||||
'disable_functions' => '',
|
||||
'disable_classes' => '',
|
||||
// core - paths and directories
|
||||
'open_basedir' => '',
|
||||
// core - data handling
|
||||
'register_globals' => 'Off',
|
||||
// safe mode
|
||||
'safe_mode' => '',
|
||||
'safe_mode_gid' => '',
|
||||
'safe_mode_exec_dir' => '',
|
||||
'safe_mode_include_dir' => '',
|
||||
// filesystem
|
||||
'allow_url_fopen' => 'On',
|
||||
'allow_url_include' => 'Off',
|
||||
'default_socket_timeout' => '60',
|
||||
// opcache
|
||||
'opcache.enable' => 'true'
|
||||
));
|
||||
|
||||
if (array_key_exists('open_basedir', $arrPHPConfiguration)) {
|
||||
$arrPHPConfiguration['open_basedir'] = explode(PATH_SEPARATOR, $arrPHPConfiguration['open_basedir']);
|
||||
}
|
||||
|
||||
return array(
|
||||
'user' => $arrUser,
|
||||
'env' => $arrEnv,
|
||||
'constants' => $arrPHPConstants,
|
||||
'extensions' => $arrPHPExtensions,
|
||||
'configuration' => $arrPHPConfiguration
|
||||
);
|
||||
}
|
||||
|
||||
public static function getPSConfig()
|
||||
{
|
||||
//$__constants = get_defined_constants(true);
|
||||
$arrPSConstant = array(
|
||||
'_PS_VERSION_' => _PS_VERSION_,
|
||||
'_PS_JQUERY_VERSION_' => _PS_JQUERY_VERSION_,
|
||||
|
||||
'_PS_MODE_DEV_' => _PS_MODE_DEV_,
|
||||
'_PS_DEBUG_PROFILING_' => _PS_DEBUG_PROFILING_,
|
||||
|
||||
'_PS_MAGIC_QUOTES_GPC_' => _PS_MAGIC_QUOTES_GPC_,
|
||||
'_PS_USE_SQL_SLAVE_' => _PS_USE_SQL_SLAVE_,
|
||||
|
||||
'_PS_CACHE_ENABLED_' => _PS_CACHE_ENABLED_,
|
||||
'_PS_CACHING_SYSTEM_' => _PS_CACHING_SYSTEM_,
|
||||
|
||||
'_PS_DEFAULT_THEME_NAME_' => _PS_DEFAULT_THEME_NAME_,
|
||||
'_PS_THEME_DIR_' => _PS_THEME_DIR_,
|
||||
'_PS_THEME_OVERRIDE_DIR_' => _PS_THEME_OVERRIDE_DIR_,
|
||||
'_PS_THEME_MOBILE_DIR_' => _PS_THEME_MOBILE_DIR_,
|
||||
'_PS_THEME_MOBILE_OVERRIDE_DIR_' => _PS_THEME_MOBILE_OVERRIDE_DIR_,
|
||||
'_PS_THEME_TOUCHPAD_DIR_' => _PS_THEME_MOBILE_OVERRIDE_DIR_
|
||||
);
|
||||
|
||||
$arrPSConfig = Configuration::getMultiple(array(
|
||||
// TNT
|
||||
'TNT_CARRIER_ACTIVATED',
|
||||
'TNT_CARRIER_ID',
|
||||
'TNT_CARRIER_USERNAME',
|
||||
'TNT_CARRIER_ACCOUNT',
|
||||
'TNT_CARRIER_PASSWORD',
|
||||
'TNT_CARRIER_PICKUP_NUMBER_SHOW',
|
||||
'TNT_GOOGLE_MAP_API_KEY',
|
||||
'TNT_CARRIER_MAX_PACKAGE_B2B',
|
||||
'TNT_CARRIER_MAX_PACKAGE_B2C',
|
||||
'TNT_CARRIER_ASSOCIATIONS',
|
||||
'TNT_CARRIER_MIDDLEWARE_URL',
|
||||
'TNT_CARRIER_MIDDLEWARE_SHORT_URL',
|
||||
'TNT_CARRIER_SOAP_WSDL',
|
||||
'TNT_CARRIER_ADDRESS_EMAIL',
|
||||
'TNT_CARRIER_ADDRESS_PHONE',
|
||||
'TNT_CARRIER_ADDRESS_BUILDING',
|
||||
'TNT_CARRIER_ADDRESS_INTERCOM',
|
||||
'TNT_CARRIER_ADDRESS_FLOOR',
|
||||
|
||||
'PS_DISABLE_OVERRIDES',
|
||||
|
||||
'PS_MULTISHOP_FEATURE_ACTIVE',
|
||||
'PS_STOCK_MANAGEMENT',
|
||||
'PS_ADVANCED_STOCK_MANAGEMENT',
|
||||
'PS_ALLOW_MULTISHIPPING',
|
||||
'PS_ORDER_PROCESS_TYPE',
|
||||
|
||||
'PS_SSL_ENABLED',
|
||||
'PS_SSL_ENABLED_EVERYWHERE',
|
||||
|
||||
'PS_LANG_DEFAULT',
|
||||
'PS_SHOP_NAME',
|
||||
'PS_SHOP_EMAIL',
|
||||
'PS_SHOP_PHONE',
|
||||
'PS_DISTANCE_UNIT'
|
||||
));
|
||||
|
||||
return array(
|
||||
'constants' => $arrPSConstant,
|
||||
'configuration' => $arrPSConfig
|
||||
);
|
||||
}
|
||||
|
||||
public static function getShopContext()
|
||||
{
|
||||
$flagShopContext = Shop::getContext();
|
||||
$arrConstShopContext = array();
|
||||
|
||||
if ($flagShopContext & Shop::CONTEXT_SHOP) {
|
||||
$arrConstShopContext[] = 'Shop::CONTEXT_SHOP';
|
||||
}
|
||||
if ($flagShopContext & Shop::CONTEXT_GROUP) {
|
||||
$arrConstShopContext[] = 'Shop::CONTEXT_GROUP';
|
||||
}
|
||||
if ($flagShopContext & Shop::CONTEXT_ALL) {
|
||||
$arrConstShopContext[] = 'Shop::CONTEXT_ALL';
|
||||
}
|
||||
|
||||
return array(
|
||||
'Context::getContext()->shop' => Context::getContext()->shop,
|
||||
'Shop::getContext()' => $arrConstShopContext,
|
||||
'Shop::isFeatureActive()' => Shop::isFeatureActive(),
|
||||
'Shop::getContextShopGroupID(true)' => Shop::getContextShopGroupID(true),
|
||||
'Shop::getContextShopID(true)' => Shop::getContextShopID(true)
|
||||
);
|
||||
}
|
||||
|
||||
public static function getModule()
|
||||
{
|
||||
$objModule = Module::getInstanceByName(TNTOfficiel::MODULE_NAME);
|
||||
|
||||
return array(
|
||||
'Module::isInstalled()' => Module::isInstalled(TNTOfficiel::MODULE_NAME),
|
||||
'Module::isEnabled()' => Module::isEnabled(TNTOfficiel::MODULE_NAME),
|
||||
'Module::isModuleTrusted()' => Module::isModuleTrusted(TNTOfficiel::MODULE_NAME),
|
||||
'Module::getInstanceByName()' => $objModule,
|
||||
'$objModule->isEnabledForShopContext()' => $objModule->isEnabledForShopContext()
|
||||
//'$objModule->getPossibleHooksList()' => $objModule->getPossibleHooksList()
|
||||
);
|
||||
}
|
||||
|
||||
public static function getAccount()
|
||||
{
|
||||
return array(
|
||||
'MyTNTLogin' => (Configuration::get('TNT_CARRIER_USERNAME')),
|
||||
'TNTAccount' => (Configuration::get('TNT_CARRIER_ACCOUNT'))
|
||||
//'MyTNTPassword' => TNTOfficiel_PasswordManager::decrypt(Configuration::get('TNT_CARRIER_PASSWORD'))
|
||||
);
|
||||
}
|
||||
|
||||
public static function cURLRequest($strURL, $arrOptions = null)
|
||||
{
|
||||
$arrcURL = array(
|
||||
'options' => array(
|
||||
//CURLOPT_URL => $strURL,
|
||||
CURLOPT_SSL_VERIFYHOST => false,
|
||||
//CURLOPT_SSL_VERIFYPEER => false,
|
||||
CURLOPT_COOKIESESSION => true,
|
||||
// follow redirect.
|
||||
CURLOPT_FOLLOWLOCATION => true,
|
||||
// max redirection.
|
||||
CURLOPT_MAXREDIRS => 10,
|
||||
// return response with curl_exec (no direct output).
|
||||
CURLOPT_RETURNTRANSFER => true,
|
||||
// include response header?
|
||||
//CURLOPT_HEADER => false,
|
||||
// include request header?
|
||||
//CURLINFO_HEADER_OUT => false,
|
||||
// timeout for connection to the server.
|
||||
CURLOPT_CONNECTTIMEOUT => 3,
|
||||
// timout global.
|
||||
CURLOPT_TIMEOUT => 5
|
||||
)
|
||||
);
|
||||
|
||||
//CURLOPT_PROXY => $strProxy
|
||||
//CURLOPT_PROXYUSERPWD => 'user:password',
|
||||
//CURLOPT_PROXYAUTH => 1,
|
||||
//CURLOPT_PROXYPORT => 80,
|
||||
//CURLOPT_PROXYTYPE => CURLPROXY_HTTP,
|
||||
|
||||
|
||||
if (is_array($arrOptions)) {
|
||||
$arrcURL['options'] += $arrOptions;
|
||||
}
|
||||
|
||||
$hdleCURL = curl_init();
|
||||
|
||||
foreach($arrcURL['options'] as $k => $o) {
|
||||
curl_setopt($hdleCURL, $k, $o);
|
||||
}
|
||||
curl_setopt($hdleCURL, CURLOPT_URL, $strURL);
|
||||
|
||||
|
||||
$arrcURL['response'] = curl_exec($hdleCURL);
|
||||
//CURLINFO_HEADER_OUT
|
||||
$arrcURL['info'] = curl_getinfo($hdleCURL);
|
||||
|
||||
curl_close($hdleCURL);
|
||||
|
||||
return $arrcURL;
|
||||
}
|
||||
}
|
@ -0,0 +1,12 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
class TNTOfficiel_MaxPackageWeightException extends Exception
|
||||
{
|
||||
}
|
@ -0,0 +1,12 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
class TNTOfficiel_OrderAlreadyShippedException extends Exception
|
||||
{
|
||||
}
|
18
www/modules/tntofficiel/libraries/exceptions/index.php
Normal file
18
www/modules/tntofficiel/libraries/exceptions/index.php
Normal file
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../');
|
||||
exit;
|
@ -0,0 +1,224 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Logger.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_ServiceCache.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_JsonRPCClient.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_PasswordManager.php';
|
||||
|
||||
class TNTOfficiel_AddressHelper
|
||||
{
|
||||
/**
|
||||
* @var Singleton
|
||||
*/
|
||||
private static $_instance = null;
|
||||
|
||||
/**
|
||||
* @var TNTOfficiel_Logger
|
||||
*/
|
||||
private $logger;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->logger = new TNTOfficiel_Logger();
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a singleton.
|
||||
*
|
||||
* @param void
|
||||
*
|
||||
* @return TNTOfficiel_AddressHelper
|
||||
*/
|
||||
public static function getInstance()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
if (is_null(TNTOfficiel_AddressHelper::$_instance)) {
|
||||
TNTOfficiel_AddressHelper::$_instance = new TNTOfficiel_AddressHelper();
|
||||
}
|
||||
|
||||
return TNTOfficiel_AddressHelper::$_instance;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get cities from the middleware for the given CP
|
||||
* Store the result in cache until midnight.
|
||||
*
|
||||
* @param string $postcode the postal code
|
||||
* @param int $idShop the shop id
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function getCitiesFromMiddleware($postcode, $idShop)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$objCache = Cache::getInstance();
|
||||
// get params without timestamp
|
||||
$params = $this->_getCitiesParams($postcode, $idShop);
|
||||
$cache_key = 'middleware::getCities_'.md5(serialize($params));
|
||||
//check if already in cache
|
||||
if (!$objCache->exists($cache_key)) {
|
||||
$client = new TNTOfficiel_JsonRPCClient(Configuration::get('TNT_CARRIER_MIDDLEWARE_URL'));
|
||||
try {
|
||||
$cities = $client->execute('getCities', $params);
|
||||
$this->logger->logMessageTnt('getCities', null, 'JSON', true, 'SUCCESS');
|
||||
} catch (Exception $objException) {
|
||||
$strStatus = ($objException->getCode() == 500) ? 'FATAL' : 'ERROR';
|
||||
$strMsg = $objException->getMessage();
|
||||
$this->logger->logMessageTnt('getCities', $strMsg, 'JSON', false, $strStatus);
|
||||
return false;
|
||||
}
|
||||
//add in cache until midnight
|
||||
$objCache->set($cache_key, Tools::jsonEncode($cities), TNTOfficiel_ServiceCache::getSecondsUntilMidnight());
|
||||
|
||||
return $cities;
|
||||
}
|
||||
$cities = Tools::jsonDecode($objCache->get($cache_key), true);
|
||||
|
||||
return $cities;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the data needed by the middleware.
|
||||
*
|
||||
* @param string $postcode the postal code
|
||||
* @param int $idShop the shop id
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
private function _getCitiesParams($postcode, $idShop)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$data = array(
|
||||
'store' => $idShop,
|
||||
'merchant' => array(
|
||||
'identity' => Configuration::get('TNT_CARRIER_USERNAME'),
|
||||
'password' => TNTOfficiel_PasswordManager::getHash(),
|
||||
'merchant_number' => Configuration::get('TNT_CARRIER_ACCOUNT'),
|
||||
),
|
||||
'postcode' => $postcode,
|
||||
);
|
||||
|
||||
return $data;
|
||||
}
|
||||
|
||||
/**
|
||||
* ask the middleware to check if the city match the postcode.
|
||||
*
|
||||
* @param $postcode
|
||||
* @param $city
|
||||
* @param $idShop
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
public function checkPostcodeCityFromMiddleware($postcode, $city, $idShop)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$objCache = Cache::getInstance();
|
||||
// get params without timestamp
|
||||
$params = $this->_getTestCityParams($postcode, $city, $idShop);
|
||||
$cache_key = 'middleware::testCity_'.md5(serialize($params));
|
||||
//check if already in cache
|
||||
if (!$objCache->exists($cache_key)) {
|
||||
$client = new TNTOfficiel_JsonRPCClient(Configuration::get('TNT_CARRIER_MIDDLEWARE_URL'));
|
||||
try {
|
||||
$result = $client->execute('testCity', $params);
|
||||
$this->logger->logMessageTnt('testCity', null, 'JSON', true, 'SUCCESS');
|
||||
} catch (Exception $objException) {
|
||||
$strStatus = ($objException->getCode() == 500) ? 'FATAL' : 'ERROR';
|
||||
$strMsg = $objException->getMessage();
|
||||
$this->logger->logMessageTnt('testCity', $strMsg, 'JSON', false, $strStatus);
|
||||
return false;
|
||||
}
|
||||
//add in cache until midnight
|
||||
$objCache->set($cache_key, Tools::jsonEncode($result), TNTOfficiel_ServiceCache::getSecondsUntilMidnight());
|
||||
|
||||
return $result;
|
||||
}
|
||||
$result = Tools::jsonDecode($objCache->get($cache_key), true);
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
public function getAddressData($addressId, $cartId)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$strSQL = '
|
||||
SELECT a.*, tc.*
|
||||
FROM '._DB_PREFIX_.'orders o
|
||||
INNER JOIN '._DB_PREFIX_.'address a on a.id_address = o.id_address_delivery
|
||||
INNER JOIN '._DB_PREFIX_.'tntofficiel_cart tc on tc.id_cart = o.id_cart
|
||||
WHERE a.id_address = '.(int)$addressId.' and tc.id_cart = '.(int)$cartId;
|
||||
|
||||
$result = Db::getInstance()->getRow($strSQL, false);
|
||||
if (!$result || count($result) == 0) {
|
||||
throw new Exception('No address was found for the address '.$addressId.' - '.$cartId);
|
||||
}
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the data needed by the middleware to check the city/postcode.
|
||||
*
|
||||
* @param $postcode
|
||||
* @param $city
|
||||
* @param $idShop
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
private function _getTestCityParams($postcode, $city, $idShop)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$data = $this->_getCitiesParams($postcode, $idShop);
|
||||
$data['city'] = $city;
|
||||
|
||||
return $data;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check the postcode/city validity for a cart.
|
||||
*
|
||||
* @param $cart
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function checkPostCodeCityForCart($cart)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$deliveryAddress = new Address($cart->id_address_delivery);
|
||||
$countryIsoCode = Country::getIsoById($deliveryAddress->id_country);
|
||||
$idShop = (int) Context::getContext()->shop->id;
|
||||
//do not check if the address is not in france
|
||||
if ($countryIsoCode == 'FR') {
|
||||
$result = $this->checkPostcodeCityFromMiddleware(
|
||||
$deliveryAddress->postcode,
|
||||
$deliveryAddress->city,
|
||||
$idShop
|
||||
);
|
||||
|
||||
return $result['response'];
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
@ -0,0 +1,284 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Cache.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Product.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Logger.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_JsonRPCClient.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_PasswordManager.php';
|
||||
|
||||
class TNTOfficiel_CarrierHelper
|
||||
{
|
||||
/** @var Singleton */
|
||||
private static $_instance = null;
|
||||
|
||||
/** @var TNTOfficiel_Logger */
|
||||
private $logger;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->logger = new TNTOfficiel_Logger();
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a singleton.
|
||||
*
|
||||
* @param void
|
||||
*
|
||||
* @return TNTOfficiel_CarrierHelper
|
||||
*/
|
||||
public static function getInstance()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
if (is_null(TNTOfficiel_CarrierHelper::$_instance)) {
|
||||
TNTOfficiel_CarrierHelper::$_instance = new TNTOfficiel_CarrierHelper();
|
||||
}
|
||||
|
||||
return TNTOfficiel_CarrierHelper::$_instance;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the carriers from the middleware or from cache.
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function getMDWTNTCarrierList($objArgCustomer)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$objContext = Context::getContext();
|
||||
$objCart = $objContext->cart;
|
||||
|
||||
$arrTNTCarrierList = array();
|
||||
|
||||
// Validated account is required.
|
||||
if (!Configuration::get('TNT_CARRIER_ACTIVATED')) {
|
||||
return $arrTNTCarrierList;
|
||||
}
|
||||
|
||||
// A shipping address is required.
|
||||
if ($objCart->id_address_delivery == 0) {
|
||||
return $arrTNTCarrierList;
|
||||
}
|
||||
|
||||
// get params without timestamp
|
||||
$params = $this->_getCartData($objArgCustomer);
|
||||
|
||||
$maxPackageWeightBtoB = (float)Configuration::get('TNT_CARRIER_MAX_PACKAGE_B2B');
|
||||
$maxPackageWeightBtoC = (float)Configuration::get('TNT_CARRIER_MAX_PACKAGE_B2C');
|
||||
|
||||
$onlyBtoBServices = false;
|
||||
foreach ($params['quote']['items'] as $item) {
|
||||
if ($item['weight'] > $maxPackageWeightBtoB) {
|
||||
return;
|
||||
}
|
||||
if ($item['weight'] > $maxPackageWeightBtoC) {
|
||||
$onlyBtoBServices = true;
|
||||
}
|
||||
}
|
||||
|
||||
$cache_key = 'middleware::getCarrierData_'.md5(serialize($params));
|
||||
|
||||
//check if already in cache
|
||||
if (!TNTOfficiel_Cache::isStored($cache_key)) {
|
||||
$client = new TNTOfficiel_JsonRPCClient(Configuration::get('TNT_CARRIER_MIDDLEWARE_URL'));
|
||||
$arrTNTCarrierList = null;
|
||||
try {
|
||||
$arrTNTCarrierList = $client->execute('getCarrierQuote', $params);
|
||||
$this->logger->logMessageTnt('getCarrierQuote', null, 'JSON', true, 'SUCCESS');
|
||||
} catch (Exception $objException) {
|
||||
$strStatus = ($objException->getCode() == 500) ? 'FATAL' : 'ERROR';
|
||||
$strMsg = $objException->getMessage();
|
||||
$this->logger->logMessageTnt('getCarrierQuote', $strMsg, 'JSON', false, $strStatus);
|
||||
}
|
||||
|
||||
if (!is_array($arrTNTCarrierList) || !array_key_exists('products', $arrTNTCarrierList)) {
|
||||
return;
|
||||
}
|
||||
|
||||
$arrServiceEnable = array('ENTERPRISE', 'DEPOT');
|
||||
foreach ($arrTNTCarrierList['products'] as $key => $product) {
|
||||
if ($onlyBtoBServices && !in_array($product['type'], $arrServiceEnable)) {
|
||||
unset($arrTNTCarrierList['products'][$key]);
|
||||
if (array_key_exists('relay_points', $arrTNTCarrierList)) {
|
||||
unset($arrTNTCarrierList['relay_points']);
|
||||
}
|
||||
continue;
|
||||
}
|
||||
$arrTNTCarrierList['products'][$key]['id'] = $product['code'].'_'.$product['type'];
|
||||
|
||||
$arrTNTCarrierList['products'][$key]['due_date'] = null;
|
||||
if ($product['due_date']) {
|
||||
$arrTNTCarrierList['products'][$key]['due_date'] = date('d/m/Y', strtotime($product['due_date']));
|
||||
}
|
||||
}
|
||||
|
||||
// add in cache for 600 seconds
|
||||
TNTOfficiel_Cache::store($cache_key, Tools::jsonEncode($arrTNTCarrierList), 600);
|
||||
|
||||
return $arrTNTCarrierList;
|
||||
}
|
||||
$arrTNTCarrierList = Tools::jsonDecode(TNTOfficiel_Cache::retrieve($cache_key), true);
|
||||
|
||||
return $arrTNTCarrierList;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get all the data needed by the middleware from the cart.
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
private function _getCartData($objCustomer)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$objContext = Context::getContext();
|
||||
$objCart = $objContext->cart;
|
||||
|
||||
//get the checkout step if in checkout else set it to 0
|
||||
$step = 0;
|
||||
if (property_exists($objContext->controller, 'step')) {
|
||||
$step = $objContext->controller->step;
|
||||
}
|
||||
|
||||
//check if user is logged in
|
||||
$loggedIn = $objContext->controller->auth;
|
||||
|
||||
//shipping address
|
||||
$shippingAddress = new Address((int)$objCart->id_address_delivery);
|
||||
|
||||
//total discount
|
||||
$totalDiscount = 0;
|
||||
|
||||
//items
|
||||
$items = array();
|
||||
foreach ($objCart->getProducts() as $product) {
|
||||
//reduction amount
|
||||
$totalDiscount += $discount = Product::getPriceStatic($product['id_product'], false, $product['id_product_attribute'], 6, null, true);
|
||||
|
||||
$attributes = TNTOfficiel_Product::getProductAttributes($product['id_product']);
|
||||
$items[] = array(
|
||||
'qty' => $product['cart_quantity'],
|
||||
'price' => $product['price'] + $discount,
|
||||
'row_total' => $product['price_wt'] * $product['cart_quantity'],
|
||||
'tax' => $product['cart_quantity'] * $product['price'] * $product['rate'] / 100,
|
||||
'discount' => $discount,
|
||||
'attributes' => $attributes,
|
||||
'options' => (isset($product['attributes'])) ? $this->_attributesToArray($product['attributes']) : '',
|
||||
'weight' => $product['weight'],
|
||||
);
|
||||
}
|
||||
|
||||
$data = array(
|
||||
'store' => $objCart->id_shop,
|
||||
'context' => ($step == 2) ? 'CHECKOUT' : 'QUOTE',
|
||||
'merchant' => array(
|
||||
'identity' => Configuration::get('TNT_CARRIER_USERNAME'),
|
||||
'password' => TNTOfficiel_PasswordManager::getHash(),
|
||||
'merchant_number' => Configuration::get('TNT_CARRIER_ACCOUNT'),
|
||||
),
|
||||
'customer' => array(
|
||||
'name' => ($loggedIn == true) ? $objCustomer->firstname.' '.$objCustomer->lastname : null,
|
||||
'email' => ($loggedIn == true) ? $objCustomer->email : '',
|
||||
'group_id' => ($loggedIn == true) ? Customer::getDefaultGroupId((int)$objCustomer->id) : null,
|
||||
'dob' => ($loggedIn == true) ? Customer::getDefaultGroupId((int)$objCustomer->birthday) : null,
|
||||
'name' => $shippingAddress->company,
|
||||
),
|
||||
'shipping' => array(
|
||||
'country_code' => Country::getIsoById($shippingAddress->id_country),
|
||||
'region_code' => Tools::substr($shippingAddress->postcode, 0, 2),
|
||||
'post_code' => $shippingAddress->postcode,
|
||||
'city' => $shippingAddress->city,
|
||||
),
|
||||
'quote' => array(
|
||||
'items' => $items,
|
||||
'subtotal' => $objCart->getOrderTotal(false, Cart::ONLY_PRODUCTS_WITHOUT_SHIPPING),
|
||||
'tax' => $objCart->getOrderTotal(true, Cart::BOTH_WITHOUT_SHIPPING)
|
||||
- $objCart->getOrderTotal(false, Cart::BOTH_WITHOUT_SHIPPING),
|
||||
'discount' => -($objCart->getOrderTotal(false, Cart::BOTH_WITHOUT_SHIPPING)
|
||||
- $objCart->getOrderTotal(false, Cart::ONLY_PRODUCTS_WITHOUT_SHIPPING)),
|
||||
'coupon_code' => $this->_getDiscountCodes($objCart),
|
||||
'freeshipping' => '',
|
||||
),
|
||||
);
|
||||
|
||||
return $data;
|
||||
}
|
||||
|
||||
/**
|
||||
* Transform a string containing attributes data into an array.
|
||||
*
|
||||
* @param string $attributes
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
private function _attributesToArray($attributes)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$attributesArray = array();
|
||||
$attributesTemp = explode(',', preg_replace('/\s+/', '', $attributes));
|
||||
foreach ($attributesTemp as $attribute) {
|
||||
$temp = array();
|
||||
$attributeArray = explode(':', $attribute);
|
||||
$temp['code'] = $attributeArray[0];
|
||||
$temp['value'] = $attributeArray[1];
|
||||
$attributesArray[] = $temp;
|
||||
}
|
||||
|
||||
return $attributesArray;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets all the cart discount codes separated by '|'.
|
||||
* Note: using Cart->getDiscounts() may cause infinite loop through Module->getOrderShippingCost().
|
||||
* Note: Cart->getOrderedCartRulesIds() unavailable in Prestashop 1.6.0.5.
|
||||
*
|
||||
* @param CartCore $objArgCart
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
private function _getDiscountCodes($objArgCart)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$strKeyCache = 'TNTOfficiel_CarrierHelper::_getDiscountCodes'.$objArgCart->id.'-ids';
|
||||
if (!Cache::isStored($strKeyCache)) {
|
||||
$arrCartRulesIdList = Db::getInstance()->executeS('
|
||||
SELECT cr.`id_cart_rule`
|
||||
FROM `'._DB_PREFIX_.'cart_cart_rule` cd
|
||||
LEFT JOIN `'._DB_PREFIX_.'cart_rule` cr ON cd.`id_cart_rule` = cr.`id_cart_rule`
|
||||
LEFT JOIN `'._DB_PREFIX_.'cart_rule_lang` crl ON (
|
||||
cd.`id_cart_rule` = crl.`id_cart_rule`
|
||||
AND crl.id_lang = '.(int)$objArgCart->id_lang.'
|
||||
)
|
||||
WHERE `id_cart` = '.(int)$objArgCart->id.'
|
||||
ORDER BY cr.priority ASC
|
||||
');
|
||||
Cache::store($strKeyCache, $arrCartRulesIdList);
|
||||
} else {
|
||||
$arrCartRulesIdList = Cache::retrieve($strKeyCache);
|
||||
}
|
||||
|
||||
$arrDiscountCodes = array();
|
||||
foreach ($arrCartRulesIdList as $arrCartRulesRow) {
|
||||
$objCartRule = new CartRule($arrCartRulesRow['id_cart_rule']);
|
||||
$arrDiscountCodes[] = $objCartRule->code;
|
||||
}
|
||||
|
||||
return implode('|', $arrDiscountCodes);
|
||||
}
|
||||
}
|
@ -0,0 +1,195 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/tntofficiel.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/helper/TNTOfficiel_ShipmentHelper.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Logger.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/pdf/TNTOfficiel_PDFMerger.php';
|
||||
|
||||
class TNTOfficiel_OrderHelper
|
||||
{
|
||||
/** @var TNTOfficiel_OrderHelper */
|
||||
private static $_instance = null;
|
||||
|
||||
/** @var TNTOfficiel_Logger */
|
||||
private $logger;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->logger = new TNTOfficiel_Logger();
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a singleton.
|
||||
*
|
||||
* @param void
|
||||
*
|
||||
* @return TNTOfficiel_OrderHelper
|
||||
*/
|
||||
public static function getInstance()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
if (is_null(TNTOfficiel_OrderHelper::$_instance)) {
|
||||
TNTOfficiel_OrderHelper::$_instance = new TNTOfficiel_OrderHelper();
|
||||
}
|
||||
|
||||
return TNTOfficiel_OrderHelper::$_instance;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the tnt product code for an order.
|
||||
*
|
||||
* @param $orderId
|
||||
*
|
||||
* @return string
|
||||
*
|
||||
* @throws Exception
|
||||
*/
|
||||
public function getOrderData($orderId, $stopOnException = true)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$sql = 'SELECT * FROM '._DB_PREFIX_.'tntofficiel_order WHERE id_order = '.(int)$orderId;
|
||||
$result = Db::getInstance()->getRow($sql, false);
|
||||
if (!$result && $stopOnException) {
|
||||
throw new Exception('No tnt product was found for the order '.$orderId);
|
||||
}
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Revert the order state to its previous state.
|
||||
*
|
||||
* @param $orderId
|
||||
*
|
||||
* @throws Exception
|
||||
*/
|
||||
public function revertState($orderId)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$arrTNTOrder = $this->getOrderData($orderId);
|
||||
$orderState = new OrderState($arrTNTOrder['previous_state']);
|
||||
$history = new OrderHistory();
|
||||
$history->id_order = (int)$orderId;
|
||||
$history->changeIdOrderState((int)$orderState, (int)$orderId);
|
||||
$history->save();
|
||||
}
|
||||
|
||||
/**
|
||||
* Change the order state to the prestashop default shipping state.
|
||||
*
|
||||
* @param $orderId
|
||||
*/
|
||||
public function validateShippedState($orderId)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$history = new OrderHistory();
|
||||
$history->id_order = (int)$orderId;
|
||||
$history->changeIdOrderState((int)(Configuration::get('PS_OS_SHIPPING')), (int)$orderId);
|
||||
$history->save();
|
||||
}
|
||||
|
||||
/**
|
||||
* Get all the tnt orders.
|
||||
*
|
||||
* @return array
|
||||
*
|
||||
* @throws PrestaShopDatabaseException
|
||||
*/
|
||||
public function getTntOrders()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$sql = 'SELECT * FROM '._DB_PREFIX_.'orders o ';
|
||||
$sql .= 'JOIN '._DB_PREFIX_.'tntofficiel_order t ON o.id_order = t.id_order';
|
||||
$orders = Db::getInstance()->executeS($sql);
|
||||
|
||||
return $orders;
|
||||
}
|
||||
|
||||
/**
|
||||
* Concatenate all the bt for the given orders.
|
||||
*
|
||||
* @param $orderList
|
||||
*
|
||||
* @return string
|
||||
*
|
||||
* @throws Exception
|
||||
*/
|
||||
public function getBt($orderList)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$pdf = new TNTOfficiel_PDFMerger();
|
||||
$btCounter = 0;
|
||||
foreach ($orderList as $orderId) {
|
||||
try {
|
||||
$arrTNTOrder = $this->getOrderData($orderId, false);
|
||||
$strBTFilename = $arrTNTOrder['bt_filename'];
|
||||
if ($strBTFilename && filesize(_PS_MODULE_DIR_.'tnt_media/media/bt/'.$strBTFilename) > 0) {
|
||||
++$btCounter;
|
||||
$pdf->addPDF(_PS_MODULE_DIR_.'tnt_media/media/bt/'.$strBTFilename);
|
||||
}
|
||||
} catch (Exception $objException) {
|
||||
$objFileLogger = new FileLogger();
|
||||
$objFileLogger->setFilename(_PS_ROOT_DIR_.'/log/'.date('Ymd').'_tnt_exception.log');
|
||||
$objFileLogger->logError($objException->getMessage());
|
||||
}
|
||||
}
|
||||
if ($btCounter > 0) {
|
||||
return $pdf->merge('download', 'bt_list.pdf');
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a new address and assign it to the order as the deliveray address.
|
||||
*
|
||||
* @param $arrProduct
|
||||
* @param $orderId
|
||||
*/
|
||||
public static function createNewAddress($arrProduct, $orderId)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$strRepoType = (array_key_exists('xett', $arrProduct) && isset($arrProduct['xett'])) ? 'xett' : 'pex';
|
||||
|
||||
$order = new Order($orderId);
|
||||
$oldAddress = new Address($order->id_address_delivery);
|
||||
$address = new Address();
|
||||
$address->id_country = (int)Context::getContext()->country->id;
|
||||
$address->id_customer = 0;
|
||||
$address->id_manufacturer = 0;
|
||||
$address->id_supplier = 0;
|
||||
$address->id_warehouse = 0;
|
||||
$address->alias = TNTOfficiel::MODULE_NAME;
|
||||
$address->lastname = $oldAddress->lastname; //lastname cannot be empty
|
||||
$address->firstname = $oldAddress->firstname; //firstname cannot be empty
|
||||
$address->company = sprintf('%s - %s', $arrProduct[ $strRepoType ], $arrProduct['name']);
|
||||
$address->address1 = ($strRepoType === 'xett') ? $arrProduct['address'] : $arrProduct['address1'];
|
||||
$address->address2 = ($strRepoType === 'xett') ? '' : $arrProduct['address2'];
|
||||
$address->city = $arrProduct['city'];
|
||||
$address->postcode = $arrProduct['postcode'];
|
||||
$address->save();
|
||||
//assign the new delivery address to the order
|
||||
$order->id_address_delivery = (int)$address->id;
|
||||
$order->save();
|
||||
//Db::getInstance()->update('orders', array('id_address_delivery' => $address->id), 'id_order = '.(int) $orderId);
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,492 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/tntofficiel.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/classes/TNTOfficielCart.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Parcel.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_SoapClient.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/helper/TNTOfficiel_OrderHelper.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/exceptions/TNTOfficiel_MaxPackageWeightException.php';
|
||||
|
||||
class TNTOfficiel_ParcelsHelper
|
||||
{
|
||||
/** @var TNTOfficiel_ParcelsHelper */
|
||||
private static $_instance = null;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a singleton.
|
||||
*
|
||||
* @param void
|
||||
*
|
||||
* @return TNTOfficiel_ParcelsHelper
|
||||
*/
|
||||
public static function getInstance()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
if (is_null(TNTOfficiel_ParcelsHelper::$_instance)) {
|
||||
TNTOfficiel_ParcelsHelper::$_instance = new TNTOfficiel_ParcelsHelper();
|
||||
}
|
||||
|
||||
return TNTOfficiel_ParcelsHelper::$_instance;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates the parcels for an order.
|
||||
*
|
||||
* @param $objCart
|
||||
* @param $intArgOrderID
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function createParcels($objCart, $intArgOrderID)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$orderedProducts = $this->_getProductsOrderedByWeight($objCart->getProducts());
|
||||
$fltMaxParcelWeight = $this->_getMaxPackageWeight($intArgOrderID);
|
||||
$parcels = array();
|
||||
$parcel = new TNTOfficiel_Parcel();
|
||||
foreach ($orderedProducts as $product) {
|
||||
$productQuantity = $product['quantity'];
|
||||
for ($i = 0; $i < $productQuantity; ++$i) {
|
||||
//check if parcel's weight exceeds the maximum parcel weight
|
||||
//and remove the last added product in the parcel if it's not the only product in it
|
||||
if (($parcel->getWeight() + $product['weight']) <= $fltMaxParcelWeight) {
|
||||
$parcel->addProduct($product);
|
||||
} else {
|
||||
$parcels[] = $parcel;
|
||||
$parcel = new TNTOfficiel_Parcel();
|
||||
$parcel->addProduct($product);
|
||||
}
|
||||
}
|
||||
}
|
||||
//if the parcels contains at least one product we add it to the list
|
||||
if (count($parcel->getProductList())) {
|
||||
$parcels[] = $parcel;
|
||||
}
|
||||
|
||||
//save the parcels
|
||||
$this->_saveParcels($parcels, $intArgOrderID);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Order a list of products by weight.
|
||||
*
|
||||
* @param $products
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
private function _getProductsOrderedByWeight($products)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
usort($products, array(__CLASS__, 'compareProductByWeight'));
|
||||
|
||||
return $products;
|
||||
}
|
||||
|
||||
/**
|
||||
* Compare two products by their weight.
|
||||
*
|
||||
* @param $productA
|
||||
* @param $productB
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public static function compareProductByWeight($productA, $productB)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
if ($productA['weight'] == $productB['weight']) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
return ($productA['weight'] < $productB['weight']) ? -1 : 1;
|
||||
}
|
||||
|
||||
/**
|
||||
* Save the parcels in the database.
|
||||
*
|
||||
* @param $parcels array
|
||||
* @param $orderId int
|
||||
*/
|
||||
private function _saveParcels($parcels, $orderId)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
foreach ($parcels as $parcel) {
|
||||
//insert into the parcel table
|
||||
$this->addParcel($orderId, $parcel->getWeight(), true);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the parcels of an order.
|
||||
*
|
||||
* @param $orderId int
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function getParcels($orderId)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$sql = 'SELECT * FROM '._DB_PREFIX_.'tntofficiel_order_parcels WHERE id_order ='.(int)$orderId;
|
||||
$parcels = Db::getInstance()->executeS($sql);
|
||||
|
||||
return $parcels;
|
||||
}
|
||||
|
||||
/**
|
||||
* Remove a parcel.
|
||||
*
|
||||
* @param $parcelId int
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function removeParcel($parcelId)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
return Db::getInstance()->delete('tntofficiel_order_parcels', 'id_parcel = '.(int)$parcelId);
|
||||
}
|
||||
|
||||
/**
|
||||
* Add a parcel.
|
||||
*
|
||||
* @param $intArgOrderID int
|
||||
* @param $fltArgWeight float
|
||||
* @param $isOrderCreation
|
||||
*
|
||||
* @return array
|
||||
*
|
||||
* @throws TNTOfficiel_MaxPackageWeightException
|
||||
*/
|
||||
public function addParcel($intArgOrderID, $fltArgWeight, $isOrderCreation = true)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$fltMaxPackageWeight = $this->_getMaxPackageWeight($intArgOrderID);
|
||||
//Does not throw an exception when this is an order creation
|
||||
//the parcel can contains one product which weight exceeds the maximum weight
|
||||
if ((float)$fltArgWeight > $fltMaxPackageWeight && !$isOrderCreation) {
|
||||
throw new TNTOfficiel_MaxPackageWeightException('Le poids d\'un colis ne peut dépasser '.$fltMaxPackageWeight.'Kg');
|
||||
}
|
||||
|
||||
Db::getInstance()->insert('tntofficiel_order_parcels', array(
|
||||
'id_order' => (int)$intArgOrderID,
|
||||
'weight' => max(round((float)$fltArgWeight, 1, PHP_ROUND_HALF_UP), 0.1),
|
||||
));
|
||||
$sql = 'SELECT * FROM '._DB_PREFIX_.'tntofficiel_order_parcels WHERE id_parcel ='.Db::getInstance()->Insert_ID();
|
||||
|
||||
return Db::getInstance()->executeS($sql);
|
||||
}
|
||||
|
||||
/**
|
||||
* Update a parcel.
|
||||
*
|
||||
* @param $parcelId int
|
||||
* @param $weight float
|
||||
* @param $intArgOrderID int
|
||||
*
|
||||
* @return bool
|
||||
*
|
||||
* @throws TNTOfficiel_MaxPackageWeightException
|
||||
*/
|
||||
public function updateParcel($parcelId, $weight, $intArgOrderID)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$fltMaxPackageWeight = $this->_getMaxPackageWeight($intArgOrderID);
|
||||
if ((float)$weight > $fltMaxPackageWeight) {
|
||||
throw new TNTOfficiel_MaxPackageWeightException('Le poids d\'un colis ne peut dépasser '.$fltMaxPackageWeight.'Kg');
|
||||
}
|
||||
$weight = max(round($weight, 1, PHP_ROUND_HALF_UP), 0.1);
|
||||
$result = array();
|
||||
$result['result'] = Db::getInstance()->update(
|
||||
'tntofficiel_order_parcels',
|
||||
array('weight' => (float)$weight),
|
||||
'id_parcel = '.(int)$parcelId
|
||||
);
|
||||
$result['weight'] = $weight;
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $parcel array
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function getTrackingData($parcel)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$response = $this->_callTntWs($parcel['parcel_number']);
|
||||
|
||||
$response = (array)$response;
|
||||
$returnData = '';
|
||||
if (count($response) && isset($response['Parcel'])) {
|
||||
$returnData = $response['Parcel'];
|
||||
}
|
||||
if ($returnData) {
|
||||
$this->_savePdl($returnData, $parcel['id_parcel']);
|
||||
$returnData = array(
|
||||
'history' => $this->_getHistory($returnData),
|
||||
'status' => $this->_getStatus($returnData),
|
||||
'allStatus' => $this->_getAllStatus($this->_getStatus($returnData)),
|
||||
);
|
||||
}
|
||||
|
||||
return $returnData;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the maximum package weight for the order.
|
||||
*
|
||||
* @param $intArgOrderID
|
||||
*
|
||||
* @return float
|
||||
*
|
||||
* @throws Exception
|
||||
*/
|
||||
private function _getMaxPackageWeight($intArgOrderID)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
try {
|
||||
$arrTNTOrder = TNTOfficiel_OrderHelper::getInstance()->getOrderData($intArgOrderID);
|
||||
$strCarrierCode = $arrTNTOrder['carrier_code'];
|
||||
} catch (Exception $objException) {
|
||||
|
||||
// TODO : Should not happen ! Why using carrier code from cart ??
|
||||
|
||||
$objContext = Context::getContext();
|
||||
$objCart = $objContext->cart;
|
||||
$intCartID = (int)$objCart->id;
|
||||
|
||||
// Load TNT cart info or create a new one for it's ID.
|
||||
$objTNTCartModel = TNTOfficielCart::loadCartID($intCartID);
|
||||
if(Validate::isLoadedObject($objTNTCartModel)) {
|
||||
$strCarrierCode = $objTNTCartModel->carrier_code;
|
||||
}
|
||||
|
||||
// throw $objException;
|
||||
|
||||
}
|
||||
// If carrier code is B2B.
|
||||
if (strpos($strCarrierCode, 'ENTERPRISE')) {
|
||||
$fltMaxPackageWeight = (float)Configuration::get('TNT_CARRIER_MAX_PACKAGE_B2B');
|
||||
} else {
|
||||
$fltMaxPackageWeight = (float)Configuration::get('TNT_CARRIER_MAX_PACKAGE_B2C');
|
||||
}
|
||||
|
||||
return $fltMaxPackageWeight;
|
||||
}
|
||||
|
||||
/**
|
||||
* Call the tnt.
|
||||
*
|
||||
* @param $parcelNumber
|
||||
*
|
||||
* @return stdClass
|
||||
*/
|
||||
private function _callTntWs($parcelNumber)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$client = new TNTOfficiel_SoapClient();
|
||||
$result = $client->trackingByConsignment($parcelNumber);
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return All Status de display : depends on status -> maximum 5 status.
|
||||
*
|
||||
* @param $status
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
protected function _getAllStatus($status)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$statusArray = array(
|
||||
1 => TNTOfficiel_ParcelsHelper::translate('Colis chez l’expéditeur'),
|
||||
2 => TNTOfficiel_ParcelsHelper::translate('Ramassage du Colis'),
|
||||
3 => TNTOfficiel_ParcelsHelper::translate('Acheminement'),
|
||||
4 => TNTOfficiel_ParcelsHelper::translate('Livraison en cours'),
|
||||
5 => TNTOfficiel_ParcelsHelper::translate('Livré'),
|
||||
);
|
||||
|
||||
switch ($status) {
|
||||
case 6:
|
||||
$statusArray[5] = TNTOfficiel_ParcelsHelper::translate('Incident');
|
||||
break;
|
||||
case 7:
|
||||
$statusArray[5] = TNTOfficiel_ParcelsHelper::translate("Retourné à l'expéditeur");
|
||||
break;
|
||||
}
|
||||
|
||||
return $statusArray;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $parcel
|
||||
*
|
||||
* @return bool|int
|
||||
*/
|
||||
protected function _getStatus($parcel)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$parcel = (array)$parcel;
|
||||
$statusLabel = isset($parcel['shortStatus']) ? $parcel['shortStatus'] : false;
|
||||
if (!$statusLabel) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$mapping = array(
|
||||
TNTOfficiel_ParcelsHelper::translate('En attente') => 1,
|
||||
'--' => 2,
|
||||
TNTOfficiel_ParcelsHelper::translate('En cours d\'acheminement') => 3,
|
||||
TNTOfficiel_ParcelsHelper::translate('En cours de livraison') => 4,
|
||||
TNTOfficiel_ParcelsHelper::translate('En agence TNT') => 4,
|
||||
TNTOfficiel_ParcelsHelper::translate('Récupéré à l\'agence TNT') => 5,
|
||||
TNTOfficiel_ParcelsHelper::translate('Livré') => 5,
|
||||
TNTOfficiel_ParcelsHelper::translate('En attente de vos instructions') => 6,
|
||||
TNTOfficiel_ParcelsHelper::translate('En attente d\'instructions') => 6,
|
||||
TNTOfficiel_ParcelsHelper::translate('En attente d\'instructions') => 6,
|
||||
TNTOfficiel_ParcelsHelper::translate('Incident de livraison') => 6,
|
||||
TNTOfficiel_ParcelsHelper::translate('Incident intervention') => 6,
|
||||
TNTOfficiel_ParcelsHelper::translate('Colis refusé par le destinataire') => 6,
|
||||
TNTOfficiel_ParcelsHelper::translate('Livraison reprogrammée') => 6,
|
||||
TNTOfficiel_ParcelsHelper::translate('Prise de rendez-vous en cours') => 6,
|
||||
TNTOfficiel_ParcelsHelper::translate('Prise de rendez-vous en cours') => 6,
|
||||
TNTOfficiel_ParcelsHelper::translate('Problème douane') => 6,
|
||||
TNTOfficiel_ParcelsHelper::translate('Enlevé au dépôt') => 3,
|
||||
TNTOfficiel_ParcelsHelper::translate('En dépôt restant') => 3,
|
||||
TNTOfficiel_ParcelsHelper::translate('Retourné à l\'expéditeur') => 7,
|
||||
);
|
||||
|
||||
return isset($mapping[$statusLabel]) ? $mapping[$statusLabel] : 1;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $parcel
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
protected function _getHistory($parcel)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
if (!$parcel->events) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$history = array();
|
||||
$states = array(1 => 'request', 2 => 'process', 3 => 'arrival', 4 => 'deliveryDeparture', 5 => 'delivery');
|
||||
$events = (array)$parcel->events;
|
||||
foreach ($states as $idx => $state) {
|
||||
if ((isset($events[$state.'Center']) || isset($events[$state.'Date']))
|
||||
&& Tools::strlen($events[$state.'Date'])
|
||||
) {
|
||||
$history[$idx] = array(
|
||||
'label' => $this->_getLabel($state),
|
||||
'date' => isset($events[$state.'Date']) ? $events[$state.'Date'] : '',
|
||||
'center' => isset($events[$state.'Center']) ? $events[$state.'Center'] : '',
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
return $history;
|
||||
}
|
||||
|
||||
protected function _getLabel($state)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$labels = array(
|
||||
'request' => TNTOfficiel_ParcelsHelper::translate('Colis chez l’expéditeur'),
|
||||
'process' => TNTOfficiel_ParcelsHelper::translate('Ramassage du colis'),
|
||||
'arrival' => TNTOfficiel_ParcelsHelper::translate('Acheminement du colis'),
|
||||
'deliveryDeparture' => TNTOfficiel_ParcelsHelper::translate('Livraison du colis en cours'),
|
||||
'delivery' => TNTOfficiel_ParcelsHelper::translate('Livraison du colis'),
|
||||
);
|
||||
|
||||
return isset($labels[$state]) ? $labels[$state] : '';
|
||||
}
|
||||
|
||||
/**
|
||||
* Save the PDL.
|
||||
*
|
||||
* @param $data
|
||||
* @param $parcelId
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
protected function _savePdl($data, $parcelId)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$result = false;
|
||||
$pdl = $this->_getPdl($data);
|
||||
if ($pdl) {
|
||||
$result = Db::getInstance()->update('tntofficiel_order_parcels', array('pdl' => pSQL($pdl)), 'id_parcel = '.(int)$parcelId);
|
||||
}
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get POD Url from parcel data.
|
||||
*
|
||||
* @param $data
|
||||
*
|
||||
* @return bool|string
|
||||
*/
|
||||
protected function _getPdl($data)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$data = (array)$data;
|
||||
|
||||
return isset($data['primaryPODUrl']) && $data['primaryPODUrl'] ? $data['primaryPODUrl'] :
|
||||
(isset($data['secondaryPODUrl']) && $data['secondaryPODUrl'] ? $data['secondaryPODUrl'] : false);
|
||||
}
|
||||
|
||||
/**
|
||||
* get translation.
|
||||
*
|
||||
* @param $string
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public static function translate($string)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
// TODO
|
||||
return Translate::getModuleTranslation(TNTOfficiel::MODULE_NAME, $string, 'parcelshelper');
|
||||
}
|
||||
}
|
@ -0,0 +1,178 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Logger.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_JsonRPCClient.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_ServiceCache.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_PasswordManager.php';
|
||||
|
||||
final class TNTOfficiel_RelayPointsHelper
|
||||
{
|
||||
/** @var Singleton */
|
||||
private static $_instance = null;
|
||||
|
||||
/** @var TNTOfficiel_Logger */
|
||||
private $objLogger;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->objLogger = new TNTOfficiel_Logger();
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a singleton.
|
||||
*
|
||||
* @param void
|
||||
*
|
||||
* @return Singleton
|
||||
*/
|
||||
public static function getInstance()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
if (is_null(TNTOfficiel_RelayPointsHelper::$_instance)) {
|
||||
TNTOfficiel_RelayPointsHelper::$_instance = new TNTOfficiel_RelayPointsHelper();
|
||||
}
|
||||
|
||||
return TNTOfficiel_RelayPointsHelper::$_instance;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the relay points for the given postcode/city from the middleware or from the cache.
|
||||
*
|
||||
* @param $postcode
|
||||
* @param $city
|
||||
* @param $idShop
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function getRelayPoints($postcode, $city, $idShop)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$objCache = Cache::getInstance();
|
||||
|
||||
// Get params without timestamp
|
||||
$arrRequestData = $this->_getParams($postcode, $idShop, $city);
|
||||
$strCacheKey = 'middleware::getRelayPoints_'.md5(serialize($arrRequestData));
|
||||
|
||||
// Retrieve from cache if exist.
|
||||
if ($objCache->exists($strCacheKey)) {
|
||||
return Tools::jsonDecode($objCache->get($strCacheKey), true);
|
||||
}
|
||||
|
||||
// JSON RPC Request to Middleware.
|
||||
$client = new TNTOfficiel_JsonRPCClient(Configuration::get('TNT_CARRIER_MIDDLEWARE_URL'));
|
||||
try {
|
||||
$arrResponse = $client->execute('getRelayPoints', $arrRequestData);
|
||||
$this->objLogger->logMessageTnt('getRelayPoints', null, 'JSON', true, 'SUCCESS');
|
||||
} catch (Exception $objException) {
|
||||
$strStatus = ($objException->getCode() == 500) ? 'FATAL' : 'ERROR';
|
||||
$strMsg = $objException->getMessage();
|
||||
$this->objLogger->logMessageTnt('getRelayPoints', $strMsg, 'JSON', false, $strStatus);
|
||||
|
||||
return array();
|
||||
}
|
||||
|
||||
// If no RelayPoints
|
||||
if ($arrResponse['relay_points'] === false) {
|
||||
$arrResponse['relay_points'] = array();
|
||||
}
|
||||
|
||||
// Store in cache until midnight.
|
||||
$objCache->set($strCacheKey, Tools::jsonEncode($arrResponse['relay_points']), TNTOfficiel_ServiceCache::getSecondsUntilMidnight());
|
||||
|
||||
|
||||
return $arrResponse['relay_points'];
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the repositories for the given postcode from the middleware or from the cache.
|
||||
*
|
||||
* @param $postcode
|
||||
* @param $idShop
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function getRepositories($postcode, $idShop)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$objCache = Cache::getInstance();
|
||||
|
||||
// Get params without timestamp
|
||||
$arrRequestData = $this->_getParams($postcode, $idShop);
|
||||
$strCacheKey = 'middleware::getRepositories_'.md5(serialize($arrRequestData));
|
||||
|
||||
// Retrieve from cache if exist.
|
||||
if ($objCache->exists($strCacheKey)) {
|
||||
return Tools::jsonDecode($objCache->get($strCacheKey), true);
|
||||
}
|
||||
|
||||
// JSON RPC Request to Middleware.
|
||||
$client = new TNTOfficiel_JsonRPCClient(Configuration::get('TNT_CARRIER_MIDDLEWARE_URL'));
|
||||
try {
|
||||
$arrResponse = $client->execute('getRepositories', $arrRequestData);
|
||||
$this->objLogger->logMessageTnt('getRepositories', null, 'JSON', true, 'SUCCESS');
|
||||
} catch (Exception $objException) {
|
||||
$strStatus = ($objException->getCode() == 500) ? 'FATAL' : 'ERROR';
|
||||
$strMsg = $objException->getMessage();
|
||||
$this->objLogger->logMessageTnt('getRepository', $strMsg, 'JSON', false, $strStatus);
|
||||
|
||||
return array();
|
||||
}
|
||||
|
||||
// If no Repositories.
|
||||
if ($arrResponse['repositories'] === false) {
|
||||
$arrResponse['repositories'] = array();
|
||||
}
|
||||
|
||||
// Store in cache until midnight.
|
||||
$objCache->set($strCacheKey, Tools::jsonEncode($arrResponse['repositories']), TNTOfficiel_ServiceCache::getSecondsUntilMidnight());
|
||||
|
||||
return $arrResponse['repositories'];
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the params needed by the middleware.
|
||||
*
|
||||
* @param $postcode
|
||||
* @param $idShop
|
||||
* @param null $city
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
private function _getParams($postcode, $idShop, $city = null)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$arrData = array(
|
||||
'store' => $idShop,
|
||||
'merchant' => array(
|
||||
'identity' => Configuration::get('TNT_CARRIER_USERNAME'),
|
||||
'password' => TNTOfficiel_PasswordManager::getHash(),
|
||||
'merchant_number' => Configuration::get('TNT_CARRIER_ACCOUNT'),
|
||||
),
|
||||
'postcode' => $postcode,
|
||||
'city' => $city,
|
||||
);
|
||||
//add the city if not null
|
||||
if ($city != null) {
|
||||
$arrData['city'] = $city;
|
||||
}
|
||||
|
||||
return $arrData;
|
||||
}
|
||||
}
|
@ -0,0 +1,440 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Logger.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_JsonRPCClient.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_PasswordManager.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/helper/TNTOfficiel_OrderHelper.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/helper/TNTOfficiel_AddressHelper.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/helper/TNTOfficiel_ParcelsHelper.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/exceptions/TNTOfficiel_OrderAlreadyShippedException.php';
|
||||
|
||||
class TNTOfficiel_ShipmentHelper
|
||||
{
|
||||
/**
|
||||
* The directory where the BT are stored.
|
||||
*/
|
||||
const BT_DIR = 'tnt_media/media/bt';
|
||||
|
||||
/** @var Singleton */
|
||||
private static $_instance = null;
|
||||
|
||||
/** @var TNTOfficiel_Logger */
|
||||
private $logger;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->logger = new TNTOfficiel_Logger();
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a singleton.
|
||||
*
|
||||
* @param void
|
||||
*
|
||||
* @return TNTOfficiel_ShipmentHelper
|
||||
*/
|
||||
public static function getInstance()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
if (is_null(TNTOfficiel_ShipmentHelper::$_instance)) {
|
||||
TNTOfficiel_ShipmentHelper::$_instance = new TNTOfficiel_ShipmentHelper();
|
||||
}
|
||||
|
||||
return TNTOfficiel_ShipmentHelper::$_instance;
|
||||
}
|
||||
|
||||
/**
|
||||
* Send a shipment request to the middleware.
|
||||
*
|
||||
* @param $cart
|
||||
* @param $orderId
|
||||
*
|
||||
* @return bool
|
||||
*
|
||||
* @throws Exception
|
||||
*/
|
||||
public function saveShipment($cart, $orderId)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$order = new Order($orderId);
|
||||
try {
|
||||
$arrTNTOrder = TNTOfficiel_OrderHelper::getInstance()->getOrderData($orderId);
|
||||
if ($arrTNTOrder['is_shipped']) {
|
||||
throw new TNTOfficiel_OrderAlreadyShippedException('The shipment has already been created for the order ' + $orderId);
|
||||
}
|
||||
$arrTNTAddress = TNTOfficiel_AddressHelper::getInstance()->getAddressData($order->id_address_delivery, $order->id_cart);
|
||||
$parcels = TNTOfficiel_ParcelsHelper::getInstance()->getParcels($orderId);
|
||||
} catch (Exception $objException) {
|
||||
$objFileLogger = new FileLogger();
|
||||
$objFileLogger->setFilename(_PS_ROOT_DIR_.'/log/'.date('Ymd').'_tnt_exception.log');
|
||||
$objFileLogger->logError($objException->getMessage());
|
||||
throw $objException;
|
||||
}
|
||||
|
||||
//call the middleware
|
||||
$arrParams = $this->_getParams(
|
||||
$cart->id_shop,
|
||||
$arrTNTOrder,
|
||||
$arrTNTAddress,
|
||||
$this->_getParcelsData($parcels, $order->reference),
|
||||
$arrTNTOrder['shipping_date']
|
||||
);
|
||||
$response = $this->_callMiddleware($arrParams);
|
||||
if (is_string($response)) {
|
||||
throw new PrestaShopException($response);
|
||||
}
|
||||
|
||||
//save the BT
|
||||
if ($response) {
|
||||
$this->_saveBT($response['bt'], $order);
|
||||
$this->_saveTrackingUrls($response['parcels'], $orderId);
|
||||
$this->_savePickupNumber($response['pickUpNumber'], $orderId);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if a shipment was successfully done for an order.
|
||||
*
|
||||
* @param $orderId
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function isShipmentSaved($orderId)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$sql = 'SELECT * FROM '._DB_PREFIX_.'tntofficiel_order WHERE id_order = '.(int)$orderId;
|
||||
$arrOrder = Db::getInstance()->getRow($sql, false);
|
||||
|
||||
return (bool)$arrOrder['is_shipped'];
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the params.
|
||||
*
|
||||
* @param $intArgShopID
|
||||
* @param $arrArgTNTOrder
|
||||
* @param $arrArgTNTAddress
|
||||
* @param $parcelsData
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
private function _getParams($intArgShopID, $arrArgTNTOrder, $arrArgTNTAddress, $parcelsData, $shippingDate = false)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$productCode = $arrArgTNTOrder['carrier_code'];
|
||||
|
||||
$typeId = (empty($arrArgTNTOrder['carrier_xett'])) ? $arrArgTNTOrder['carrier_pex'] : $arrArgTNTOrder['carrier_xett'];
|
||||
$arrParams = array(
|
||||
'store' => $intArgShopID,
|
||||
'merchant' => array(
|
||||
'identity' => Configuration::get('TNT_CARRIER_USERNAME'),
|
||||
'password' => TNTOfficiel_PasswordManager::getHash(),
|
||||
'merchant_number' => Configuration::get('TNT_CARRIER_ACCOUNT'),
|
||||
),
|
||||
'product' => $productCode,
|
||||
'recipient' => array(
|
||||
'xett' => $arrArgTNTOrder['carrier_xett'],
|
||||
'pex' => $arrArgTNTOrder['carrier_pex'],
|
||||
'firstname' => $arrArgTNTAddress['firstname'],
|
||||
'lastname' => $arrArgTNTAddress['lastname'],
|
||||
'address1' => Tools::substr($arrArgTNTAddress['address1'], 0, 32),
|
||||
'address2' => Tools::substr($arrArgTNTAddress['address2'], 0, 32),
|
||||
'post_code' => $arrArgTNTAddress['postcode'],
|
||||
'city' => $arrArgTNTAddress['city'],
|
||||
'email' => $arrArgTNTAddress['customer_email'],
|
||||
'phone' => $arrArgTNTAddress['customer_mobile'],
|
||||
'access_code' => $arrArgTNTAddress['address_accesscode'],
|
||||
'floor' => $arrArgTNTAddress['address_floor'],
|
||||
'building' => $arrArgTNTAddress['address_building'],
|
||||
'name' => $arrArgTNTAddress['company'],
|
||||
'typeId' => $typeId,
|
||||
),
|
||||
'parcels' => $parcelsData,
|
||||
);
|
||||
|
||||
if ($shippingDate) {
|
||||
$arrParams['shipping_date'] = $shippingDate;
|
||||
}
|
||||
|
||||
return $arrParams;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get parcels data.
|
||||
*
|
||||
* @param $parcels array
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
private function _getParcelsData($parcels, $orderReference)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$parcelsData = array();
|
||||
foreach ($parcels as $parcel) {
|
||||
$parcelsData[] = array(
|
||||
'reference' => $orderReference,
|
||||
'weight' => $parcel['weight'],
|
||||
);
|
||||
}
|
||||
|
||||
return $parcelsData;
|
||||
}
|
||||
|
||||
/**
|
||||
* Call the middleware to save the shipment.
|
||||
*
|
||||
* @param $params
|
||||
*
|
||||
* @return mixed
|
||||
*
|
||||
* @throws Exception
|
||||
*/
|
||||
private function _callMiddleware($params)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$client = new TNTOfficiel_JsonRPCClient(Configuration::get('TNT_CARRIER_MIDDLEWARE_URL'));
|
||||
try {
|
||||
$result = $client->execute('saveShipment', $params);
|
||||
$this->logger->logMessageTnt('saveShipment', null, 'JSON', true, 'SUCCESS');
|
||||
} catch (Exception $objException) {
|
||||
$strStatus = ($objException->getCode() == 500) ? 'FATAL' : 'ERROR';
|
||||
$strMsg = $objException->getMessage();
|
||||
$this->logger->logMessageTnt('saveShipment', $strMsg, 'JSON', false, $strStatus);
|
||||
throw $objException;
|
||||
}
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Call the middleware to save the shipment.
|
||||
*
|
||||
* @param $params
|
||||
*
|
||||
* @return mixed
|
||||
*
|
||||
* @throws Exception
|
||||
*/
|
||||
private function _callMiddlewareWithService($params, $service)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$client = new TNTOfficiel_JsonRPCClient(Configuration::get('TNT_CARRIER_MIDDLEWARE_URL'));
|
||||
try {
|
||||
$result = $client->execute($service, $params);
|
||||
$this->logger->logMessageTnt($service, null, 'JSON', true, 'SUCCESS');
|
||||
} catch (Exception $objException) {
|
||||
$strStatus = ($objException->getCode() == 500) ? 'FATAL' : 'ERROR';
|
||||
$strMsg = $objException->getMessage();
|
||||
$this->logger->logMessageTnt($service, $strMsg, 'JSON', false, $strStatus);
|
||||
throw $objException;
|
||||
}
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Saves the BT in the file system.
|
||||
*
|
||||
* @param $strBTContent
|
||||
* @param $order
|
||||
*
|
||||
* @throws Exception
|
||||
*/
|
||||
private function _saveBT($strBTContent, $order)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
//creates the directory if not exists
|
||||
if (!is_dir(_PS_MODULE_DIR_.TNTOfficiel_ShipmentHelper::BT_DIR)) {
|
||||
mkdir(_PS_MODULE_DIR_.TNTOfficiel_ShipmentHelper::BT_DIR, 0777, true);
|
||||
}
|
||||
$date = date('Y-m-d_H-i-s');
|
||||
$strBTFilename = sprintf('BT_%s_%s.pdf', $order->reference, $date);
|
||||
//create the file
|
||||
try {
|
||||
file_put_contents(_PS_MODULE_DIR_.TNTOfficiel_ShipmentHelper::BT_DIR.'/'.$strBTFilename, utf8_decode($strBTContent));
|
||||
Db::getInstance()->update(
|
||||
'tntofficiel_order',
|
||||
array('bt_filename' => pSQL($strBTFilename), 'is_shipped' => true, 'previous_state' => (int)$order->current_state),
|
||||
'id_order = '.(int)$order->id
|
||||
);
|
||||
} catch (Exception $objException) {
|
||||
$objFileLogger = new FileLogger();
|
||||
$objFileLogger->setFilename(_PS_ROOT_DIR_.'/log/'.date('Ymd').'_tnt_exception.log');
|
||||
$objFileLogger->logError($objException->getMessage());
|
||||
throw $objException;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Saves the tracking url for each parcel.
|
||||
*
|
||||
* @param $tntParcels
|
||||
* @param $orderId
|
||||
*
|
||||
* @throws Exception
|
||||
*/
|
||||
private function _saveTrackingUrls($tntParcels, $orderId)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$sql = 'SELECT * FROM '._DB_PREFIX_.'tntofficiel_order_parcels where id_order = '.(int)$orderId;
|
||||
$parcels = Db::getInstance()->executeS($sql);
|
||||
$i = 0;
|
||||
foreach ($tntParcels as $tntParcel) {
|
||||
try {
|
||||
Db::getInstance()->update(
|
||||
'tntofficiel_order_parcels',
|
||||
array(
|
||||
'tracking_url' => pSQL($tntParcel['tracking_url']),
|
||||
'parcel_number' => pSQL($tntParcel['number']),
|
||||
),
|
||||
'id_parcel = '.pSQL($parcels[$i]['id_parcel'])
|
||||
);
|
||||
} catch (Exception $objException) {
|
||||
$objFileLogger = new FileLogger();
|
||||
$objFileLogger->setFilename(_PS_ROOT_DIR_.'/log/'.date('Ymd').'_tnt_exception.log');
|
||||
$objFileLogger->logError($objException->getMessage());
|
||||
throw $objException;
|
||||
}
|
||||
++$i;
|
||||
}
|
||||
}
|
||||
|
||||
private function _savePickupNumber($pickupNumber, $orderId)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$sql = 'SELECT * FROM '._DB_PREFIX_.'tntofficiel_order where id_order = '.(int)$orderId;
|
||||
$orders = Db::getInstance()->executeS($sql);
|
||||
foreach ($orders as $order) {
|
||||
Db::getInstance()->update(
|
||||
'tntofficiel_order',
|
||||
array('pickup_number' => pSQL($pickupNumber)),
|
||||
'id_tntofficiel_order = '.(int)$order['id_tntofficiel_order']
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the first available shipping date.
|
||||
*
|
||||
* @param $cart
|
||||
* @param $intArgOrderID
|
||||
*
|
||||
* @return string|bool
|
||||
*
|
||||
* @throws Exception
|
||||
*/
|
||||
public function getShippingDate($intArgOrderID)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$objOrder = new Order($intArgOrderID);
|
||||
try {
|
||||
$arrTNTOrder = TNTOfficiel_OrderHelper::getInstance()->getOrderData($intArgOrderID);
|
||||
if ($arrTNTOrder['is_shipped']) {
|
||||
throw new TNTOfficiel_OrderAlreadyShippedException('The shipment has already been created for the order ' + $intArgOrderID);
|
||||
}
|
||||
$arrTNTAddress = TNTOfficiel_AddressHelper::getInstance()->getAddressData($objOrder->id_address_delivery, $objOrder->id_cart);
|
||||
$parcels = TNTOfficiel_ParcelsHelper::getInstance()->getParcels($intArgOrderID);
|
||||
} catch (Exception $objException) {
|
||||
$objFileLogger = new FileLogger();
|
||||
$objFileLogger->setFilename(_PS_ROOT_DIR_.'/log/'.date('Ymd').'_tnt_exception.log');
|
||||
$objFileLogger->logError($objException->getMessage());
|
||||
throw $objException;
|
||||
}
|
||||
|
||||
//call the middleware
|
||||
$arrParams = $this->_getParams(
|
||||
$objOrder->id_shop,
|
||||
$arrTNTOrder,
|
||||
$arrTNTAddress,
|
||||
$this->_getParcelsData($parcels, $objOrder->reference)
|
||||
);
|
||||
$arrMDWResponse = $this->_callMiddlewareWithService($arrParams, 'getShippingDate');
|
||||
if (is_string($arrMDWResponse)) {
|
||||
throw new PrestaShopException($arrMDWResponse);
|
||||
}
|
||||
|
||||
return $arrMDWResponse;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the first available shipping date.
|
||||
*
|
||||
* @param $cart
|
||||
* @param $orderId
|
||||
*
|
||||
* @return string|bool
|
||||
*
|
||||
* @throws Exception
|
||||
*/
|
||||
public function checkSaveShipmentDate($orderId, $shippingDate)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$order = new Order($orderId);
|
||||
try {
|
||||
$arrTNTOrder = TNTOfficiel_OrderHelper::getInstance()->getOrderData($orderId);
|
||||
$arrTNTAddress = TNTOfficiel_AddressHelper::getInstance()->getAddressData($order->id_address_delivery, $order->id_cart);
|
||||
$parcels = TNTOfficiel_ParcelsHelper::getInstance()->getParcels($orderId);
|
||||
} catch (Exception $objException) {
|
||||
$objFileLogger = new FileLogger();
|
||||
$objFileLogger->setFilename(_PS_ROOT_DIR_.'/log/'.date('Ymd').'_tnt_exception.log');
|
||||
$objFileLogger->logError($objException->getMessage());
|
||||
throw $objException;
|
||||
}
|
||||
|
||||
//call the middleware
|
||||
$arrParams = $this->_getParams(
|
||||
$order->id_shop,
|
||||
$arrTNTOrder,
|
||||
$arrTNTAddress,
|
||||
$this->_getParcelsData($parcels, $order->reference),
|
||||
$shippingDate
|
||||
);
|
||||
$arrMDWResponse = $this->_callMiddlewareWithService($arrParams, 'checkSaveShipment');
|
||||
|
||||
return $arrMDWResponse;
|
||||
}
|
||||
|
||||
public function getNewShippingDate($intArgOrderID)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$arrMDWShippingDate = TNTOfficiel_ShipmentHelper::getInstance()->getShippingDate($intArgOrderID);
|
||||
//$shippingDatePrepa = $response['shippingDatePrepa'];
|
||||
$shippingDatePrepa = $arrMDWShippingDate['shippingDate'];
|
||||
|
||||
$arrMDWShippingDate = TNTOfficiel_ShipmentHelper::getInstance()->checkSaveShipmentDate($intArgOrderID, $shippingDatePrepa);
|
||||
|
||||
if (!array_key_exists('shippingDate', $arrMDWShippingDate)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return $arrMDWShippingDate;
|
||||
}
|
||||
}
|
@ -0,0 +1,119 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
|
||||
/**
|
||||
* Class TNTOfficiel_ShippingHelper.
|
||||
*/
|
||||
class TNTOfficiel_ShippingHelper
|
||||
{
|
||||
/**
|
||||
* @var Singleton
|
||||
*/
|
||||
private static $_instance = null;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a singleton.
|
||||
*
|
||||
* @param void
|
||||
*
|
||||
* @return TNTOfficiel_ShippingHelper
|
||||
*/
|
||||
public static function getInstance()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
if (is_null(TNTOfficiel_ShippingHelper::$_instance)) {
|
||||
TNTOfficiel_ShippingHelper::$_instance = new TNTOfficiel_ShippingHelper();
|
||||
}
|
||||
|
||||
return TNTOfficiel_ShippingHelper::$_instance;
|
||||
}
|
||||
|
||||
/**
|
||||
* @var array
|
||||
*/
|
||||
protected $_days = array(
|
||||
'Monday',
|
||||
'Tuesday',
|
||||
'Wednesday',
|
||||
'Thursday',
|
||||
'Friday',
|
||||
'Saturday',
|
||||
'Sunday',
|
||||
);
|
||||
|
||||
/**
|
||||
* Returns an array with schedules for each days.
|
||||
*
|
||||
* @param array $params Parameters of the function
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function getSchedules(array $params = array())
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$schedules = array();
|
||||
|
||||
if ($hours = $params['hours']) {
|
||||
$index = 0;
|
||||
// Position corresponds to the number of the day
|
||||
$position = 0;
|
||||
// Current day
|
||||
$day = null;
|
||||
// Part of the day
|
||||
$part = null;
|
||||
|
||||
foreach ($hours as $hour) {
|
||||
$hour = trim($hour);
|
||||
$day = $this->_days[$position];
|
||||
|
||||
if (($index % 2 === 0) && ($index % 4 === 0)) {
|
||||
$part = 'AM';
|
||||
} elseif (($index % 2 === 0) && ($index % 4 === 2)) {
|
||||
$part = 'PM';
|
||||
}
|
||||
|
||||
// Prepare the current Day
|
||||
if (!isset($schedules[$day])) {
|
||||
$schedules[$day] = array();
|
||||
}
|
||||
|
||||
// Prepare the current period of the current dya
|
||||
if (!isset($schedules[$day][$part]) && $hour) {
|
||||
$schedules[$day][$part] = array();
|
||||
}
|
||||
|
||||
// If hours different from 0
|
||||
if ($hour) {
|
||||
// Add hour
|
||||
$schedules[$day][$part][] = $hour;
|
||||
}
|
||||
|
||||
++$index;
|
||||
|
||||
if ($index % 4 == 0) {
|
||||
++$position;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return $schedules;
|
||||
}
|
||||
}
|
18
www/modules/tntofficiel/libraries/helper/index.php
Normal file
18
www/modules/tntofficiel/libraries/helper/index.php
Normal file
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../');
|
||||
exit;
|
18
www/modules/tntofficiel/libraries/index.php
Normal file
18
www/modules/tntofficiel/libraries/index.php
Normal file
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../');
|
||||
exit;
|
202
www/modules/tntofficiel/libraries/pdf/TNTOfficiel_PDFMerger.php
Normal file
202
www/modules/tntofficiel/libraries/pdf/TNTOfficiel_PDFMerger.php
Normal file
@ -0,0 +1,202 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
/**
|
||||
* PDFMerger created by Jarrod Nettles December 2009
|
||||
* jarrod@squarecrow.com
|
||||
*
|
||||
* v1.0
|
||||
*
|
||||
* Class for easily merging PDFs (or specific pages of PDFs) together into one. Output to a file, browser, download, or return as a string.
|
||||
* Unfortunately, this class does not preserve many of the enhancements your original PDF might contain. It treats
|
||||
* your PDF page as an image and then concatenates them all together.
|
||||
*
|
||||
* Note that your PDFs are merged in the order that you provide them using the addPDF function, same as the pages.
|
||||
* If you put pages 12-14 before 1-5 then 12-15 will be placed first in the output.
|
||||
*
|
||||
*
|
||||
* Uses FPDI 1.3.1 from Setasign
|
||||
* Uses FPDF 1.6 by Olivier Plathey with FPDF_TPL extension 1.1.3 by Setasign
|
||||
*
|
||||
* Both of these packages are free and open source software, bundled with this class for ease of use.
|
||||
* They are not modified in any way. PDFMerger has all the limitations of the FPDI package - essentially, it cannot import dynamic content
|
||||
* such as form fields, links or page annotations (anything not a part of the page content stream).
|
||||
*
|
||||
*/
|
||||
class TNTOfficiel_PDFMerger
|
||||
{
|
||||
private $_files; //['form.pdf'] ["1,2,4, 5-19"]
|
||||
private $_fpdi;
|
||||
|
||||
/**
|
||||
* Merge PDFs.
|
||||
* @return void
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
require_once('fpdf/TNTOfficiel_FPDF.php');
|
||||
require_once('fpdi/TNTOfficiel_FPDI.php');
|
||||
}
|
||||
|
||||
/**
|
||||
* Add a PDF for inclusion in the merge with a valid file path. Pages should be formatted: 1,3,6, 12-16.
|
||||
* @param $filepath
|
||||
* @param $pages
|
||||
* @return void
|
||||
*/
|
||||
public function addPDF($filepath, $pages = 'all')
|
||||
{
|
||||
if(file_exists($filepath))
|
||||
{
|
||||
if(strtolower($pages) != 'all')
|
||||
{
|
||||
$pages = $this->_rewritepages($pages);
|
||||
}
|
||||
|
||||
$this->_files[] = array($filepath, $pages);
|
||||
}
|
||||
else
|
||||
{
|
||||
throw new exception("Could not locate PDF on '$filepath'");
|
||||
}
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Merges your provided PDFs and outputs to specified location.
|
||||
* @param $outputmode
|
||||
* @param $outputname
|
||||
* @return PDF
|
||||
*/
|
||||
public function merge($outputmode = 'browser', $outputpath = 'newfile.pdf')
|
||||
{
|
||||
if(!isset($this->_files) || !is_array($this->_files)): throw new exception("No PDFs to merge."); endif;
|
||||
|
||||
$fpdi = new TNTOfficiel_FPDI;
|
||||
|
||||
//merger operations
|
||||
foreach($this->_files as $file)
|
||||
{
|
||||
$filename = $file[0];
|
||||
$filepages = $file[1];
|
||||
|
||||
$count = $fpdi->setSourceFile($filename);
|
||||
|
||||
//add the pages
|
||||
if($filepages == 'all')
|
||||
{
|
||||
for($i=1; $i<=$count; $i++)
|
||||
{
|
||||
$template = $fpdi->importPage($i);
|
||||
$size = $fpdi->getTemplateSize($template);
|
||||
$orientation = ($size['h'] > $size['w']) ? 'P' : 'L';
|
||||
|
||||
$fpdi->AddPage($orientation, array($size['w'], $size['h']));
|
||||
$fpdi->useTemplate($template);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
foreach($filepages as $page)
|
||||
{
|
||||
if(!$template = $fpdi->importPage($page)): throw new exception("Could not load page '$page' in PDF '$filename'. Check that the page exists."); endif;
|
||||
$size = $fpdi->getTemplateSize($template);
|
||||
$orientation = ($size['h'] > $size['w']) ? 'P' : 'L';
|
||||
|
||||
$fpdi->AddPage($orientation, array($size['w'], $size['h']));
|
||||
$fpdi->useTemplate($template);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//output operations
|
||||
$mode = $this->_switchmode($outputmode);
|
||||
|
||||
if($mode == 'S')
|
||||
{
|
||||
return $fpdi->Output($outputpath, 'S');
|
||||
}
|
||||
else
|
||||
{
|
||||
if($fpdi->Output($outputpath, $mode) == '')
|
||||
{
|
||||
return true;
|
||||
}
|
||||
else
|
||||
{
|
||||
throw new exception("Error outputting PDF to '$outputmode'.");
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* FPDI uses single characters for specifying the output location. Change our more descriptive string into proper format.
|
||||
* @param $mode
|
||||
* @return Character
|
||||
*/
|
||||
private function _switchmode($mode)
|
||||
{
|
||||
switch(strtolower($mode))
|
||||
{
|
||||
case 'download':
|
||||
return 'D';
|
||||
break;
|
||||
case 'browser':
|
||||
return 'I';
|
||||
break;
|
||||
case 'file':
|
||||
return 'F';
|
||||
break;
|
||||
case 'string':
|
||||
return 'S';
|
||||
break;
|
||||
default:
|
||||
return 'I';
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Takes our provided pages in the form of 1,3,4,16-50 and creates an array of all pages
|
||||
* @param $pages
|
||||
* @return unknown_type
|
||||
*/
|
||||
private function _rewritepages($pages)
|
||||
{
|
||||
$pages = str_replace(' ', '', $pages);
|
||||
$part = explode(',', $pages);
|
||||
|
||||
//parse hyphens
|
||||
foreach($part as $i)
|
||||
{
|
||||
$ind = explode('-', $i);
|
||||
|
||||
if(count($ind) == 2)
|
||||
{
|
||||
$x = $ind[0]; //start page
|
||||
$y = $ind[1]; //end page
|
||||
|
||||
if($x > $y): throw new exception("Starting page, '$x' is greater than ending page '$y'."); return false; endif;
|
||||
|
||||
//add middle pages
|
||||
while($x <= $y): $newpages[] = (int) $x; $x++; endwhile;
|
||||
}
|
||||
else
|
||||
{
|
||||
$newpages[] = (int) $ind[0];
|
||||
}
|
||||
}
|
||||
|
||||
return $newpages;
|
||||
}
|
||||
}
|
1641
www/modules/tntofficiel/libraries/pdf/fpdf/TNTOfficiel_FPDF.php
Normal file
1641
www/modules/tntofficiel/libraries/pdf/fpdf/TNTOfficiel_FPDF.php
Normal file
File diff suppressed because it is too large
Load Diff
15
www/modules/tntofficiel/libraries/pdf/fpdf/font/courier.php
Normal file
15
www/modules/tntofficiel/libraries/pdf/fpdf/font/courier.php
Normal file
@ -0,0 +1,15 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
for ($i=0;$i<=255;$i++) {
|
||||
$tntofficiel_fpdf_charwidths['courier'][chr($i)]=600;
|
||||
}
|
||||
$tntofficiel_fpdf_charwidths['courierB']=$tntofficiel_fpdf_charwidths['courier'];
|
||||
$tntofficiel_fpdf_charwidths['courierI']=$tntofficiel_fpdf_charwidths['courier'];
|
||||
$tntofficiel_fpdf_charwidths['courierBI']=$tntofficiel_fpdf_charwidths['courier'];
|
@ -0,0 +1,43 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
$tntofficiel_fpdf_charwidths['helvetica'] = array(
|
||||
chr(0) => 278, chr(1) => 278, chr(2) => 278, chr(3) => 278, chr(4) => 278, chr(5) => 278, chr(6) => 278, chr(7) => 278,
|
||||
chr(8) => 278, chr(9) => 278, chr(10) => 278, chr(11) => 278, chr(12) => 278, chr(13) => 278, chr(14) => 278, chr(15) => 278,
|
||||
chr(16) => 278, chr(17) => 278, chr(18) => 278, chr(19) => 278, chr(20) => 278, chr(21) => 278, chr(22) => 278, chr(23) => 278,
|
||||
chr(24) => 278, chr(25) => 278, chr(26) => 278, chr(27) => 278, chr(28) => 278, chr(29) => 278, chr(30) => 278, chr(31) => 278,
|
||||
' ' => 278, '!' => 278, '"' => 355, '#' => 556, '$' => 556, '%' => 889, '&' => 667, '\'' => 191,
|
||||
'(' => 333, ')' => 333, '*' => 389, '+' => 584, ',' => 278, '-' => 333, '.' => 278, '/' => 278,
|
||||
'0' => 556, '1' => 556, '2' => 556, '3' => 556, '4' => 556, '5' => 556, '6' => 556, '7' => 556,
|
||||
'8' => 556, '9' => 556, ':' => 278, ';' => 278, '<' => 584, '=' => 584, '>' => 584, '?' => 556,
|
||||
'@' => 1015, 'A' => 667, 'B' => 667, 'C' => 722, 'D' => 722, 'E' => 667, 'F' => 611, 'G' => 778,
|
||||
'H' => 722, 'I' => 278, 'J' => 500, 'K' => 667, 'L' => 556, 'M' => 833, 'N' => 722, 'O' => 778,
|
||||
'P' => 667, 'Q' => 778, 'R' => 722, 'S' => 667, 'T' => 611, 'U' => 722, 'V' => 667, 'W' => 944,
|
||||
'X' => 667, 'Y' => 667, 'Z' => 611, '[' => 278, '\\' => 278, ']' => 278, '^' => 469, '_' => 556,
|
||||
'`' => 333, 'a' => 556, 'b' => 556, 'c' => 500, 'd' => 556, 'e' => 556, 'f' => 278, 'g' => 556,
|
||||
'h' => 556, 'i' => 222, 'j' => 222, 'k' => 500, 'l' => 222, 'm' => 833, 'n' => 556, 'o' => 556,
|
||||
'p' => 556, 'q' => 556, 'r' => 333, 's' => 500, 't' => 278, 'u' => 556, 'v' => 500, 'w' => 722,
|
||||
'x' => 500, 'y' => 500, 'z' => 500, '{' => 334, '|' => 260, '}' => 334, '~' => 584, chr(127) => 350,
|
||||
chr(128) => 556, chr(129) => 350, chr(130) => 222, chr(131) => 556, chr(132) => 333, chr(133) => 1000, chr(134) => 556, chr(135) => 556,
|
||||
chr(136) => 333, chr(137) => 1000, chr(138) => 667, chr(139) => 333, chr(140) => 1000, chr(141) => 350, chr(142) => 611, chr(143) => 350,
|
||||
chr(144) => 350, chr(145) => 222, chr(146) => 222, chr(147) => 333, chr(148) => 333, chr(149) => 350, chr(150) => 556, chr(151) => 1000,
|
||||
chr(152) => 333, chr(153) => 1000, chr(154) => 500, chr(155) => 333, chr(156) => 944, chr(157) => 350, chr(158) => 500, chr(159) => 667,
|
||||
chr(160) => 278, chr(161) => 333, chr(162) => 556, chr(163) => 556, chr(164) => 556, chr(165) => 556, chr(166) => 260, chr(167) => 556,
|
||||
chr(168) => 333, chr(169) => 737, chr(170) => 370, chr(171) => 556, chr(172) => 584, chr(173) => 333, chr(174) => 737, chr(175) => 333,
|
||||
chr(176) => 400, chr(177) => 584, chr(178) => 333, chr(179) => 333, chr(180) => 333, chr(181) => 556, chr(182) => 537, chr(183) => 278,
|
||||
chr(184) => 333, chr(185) => 333, chr(186) => 365, chr(187) => 556, chr(188) => 834, chr(189) => 834, chr(190) => 834, chr(191) => 611,
|
||||
chr(192) => 667, chr(193) => 667, chr(194) => 667, chr(195) => 667, chr(196) => 667, chr(197) => 667, chr(198) => 1000, chr(199) => 722,
|
||||
chr(200) => 667, chr(201) => 667, chr(202) => 667, chr(203) => 667, chr(204) => 278, chr(205) => 278, chr(206) => 278, chr(207) => 278,
|
||||
chr(208) => 722, chr(209) => 722, chr(210) => 778, chr(211) => 778, chr(212) => 778, chr(213) => 778, chr(214) => 778, chr(215) => 584,
|
||||
chr(216) => 778, chr(217) => 722, chr(218) => 722, chr(219) => 722, chr(220) => 722, chr(221) => 667, chr(222) => 667, chr(223) => 611,
|
||||
chr(224) => 556, chr(225) => 556, chr(226) => 556, chr(227) => 556, chr(228) => 556, chr(229) => 556, chr(230) => 889, chr(231) => 500,
|
||||
chr(232) => 556, chr(233) => 556, chr(234) => 556, chr(235) => 556, chr(236) => 278, chr(237) => 278, chr(238) => 278, chr(239) => 278,
|
||||
chr(240) => 556, chr(241) => 556, chr(242) => 556, chr(243) => 556, chr(244) => 556, chr(245) => 556, chr(246) => 556, chr(247) => 584,
|
||||
chr(248) => 611, chr(249) => 556, chr(250) => 556, chr(251) => 556, chr(252) => 556, chr(253) => 500, chr(254) => 556, chr(255) => 500
|
||||
);
|
@ -0,0 +1,23 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
$tntofficiel_fpdf_charwidths['helveticaB']=array(
|
||||
chr(0)=>278,chr(1)=>278,chr(2)=>278,chr(3)=>278,chr(4)=>278,chr(5)=>278,chr(6)=>278,chr(7)=>278,chr(8)=>278,chr(9)=>278,chr(10)=>278,chr(11)=>278,chr(12)=>278,chr(13)=>278,chr(14)=>278,chr(15)=>278,chr(16)=>278,chr(17)=>278,chr(18)=>278,chr(19)=>278,chr(20)=>278,chr(21)=>278,
|
||||
chr(22)=>278,chr(23)=>278,chr(24)=>278,chr(25)=>278,chr(26)=>278,chr(27)=>278,chr(28)=>278,chr(29)=>278,chr(30)=>278,chr(31)=>278,' '=>278,'!'=>333,'"'=>474,'#'=>556,'$'=>556,'%'=>889,'&'=>722,'\''=>238,'('=>333,')'=>333,'*'=>389,'+'=>584,
|
||||
','=>278,'-'=>333,'.'=>278,'/'=>278,'0'=>556,'1'=>556,'2'=>556,'3'=>556,'4'=>556,'5'=>556,'6'=>556,'7'=>556,'8'=>556,'9'=>556,':'=>333,';'=>333,'<'=>584,'='=>584,'>'=>584,'?'=>611,'@'=>975,'A'=>722,
|
||||
'B'=>722,'C'=>722,'D'=>722,'E'=>667,'F'=>611,'G'=>778,'H'=>722,'I'=>278,'J'=>556,'K'=>722,'L'=>611,'M'=>833,'N'=>722,'O'=>778,'P'=>667,'Q'=>778,'R'=>722,'S'=>667,'T'=>611,'U'=>722,'V'=>667,'W'=>944,
|
||||
'X'=>667,'Y'=>667,'Z'=>611,'['=>333,'\\'=>278,']'=>333,'^'=>584,'_'=>556,'`'=>333,'a'=>556,'b'=>611,'c'=>556,'d'=>611,'e'=>556,'f'=>333,'g'=>611,'h'=>611,'i'=>278,'j'=>278,'k'=>556,'l'=>278,'m'=>889,
|
||||
'n'=>611,'o'=>611,'p'=>611,'q'=>611,'r'=>389,'s'=>556,'t'=>333,'u'=>611,'v'=>556,'w'=>778,'x'=>556,'y'=>556,'z'=>500,'{'=>389,'|'=>280,'}'=>389,'~'=>584,chr(127)=>350,chr(128)=>556,chr(129)=>350,chr(130)=>278,chr(131)=>556,
|
||||
chr(132)=>500,chr(133)=>1000,chr(134)=>556,chr(135)=>556,chr(136)=>333,chr(137)=>1000,chr(138)=>667,chr(139)=>333,chr(140)=>1000,chr(141)=>350,chr(142)=>611,chr(143)=>350,chr(144)=>350,chr(145)=>278,chr(146)=>278,chr(147)=>500,chr(148)=>500,chr(149)=>350,chr(150)=>556,chr(151)=>1000,chr(152)=>333,chr(153)=>1000,
|
||||
chr(154)=>556,chr(155)=>333,chr(156)=>944,chr(157)=>350,chr(158)=>500,chr(159)=>667,chr(160)=>278,chr(161)=>333,chr(162)=>556,chr(163)=>556,chr(164)=>556,chr(165)=>556,chr(166)=>280,chr(167)=>556,chr(168)=>333,chr(169)=>737,chr(170)=>370,chr(171)=>556,chr(172)=>584,chr(173)=>333,chr(174)=>737,chr(175)=>333,
|
||||
chr(176)=>400,chr(177)=>584,chr(178)=>333,chr(179)=>333,chr(180)=>333,chr(181)=>611,chr(182)=>556,chr(183)=>278,chr(184)=>333,chr(185)=>333,chr(186)=>365,chr(187)=>556,chr(188)=>834,chr(189)=>834,chr(190)=>834,chr(191)=>611,chr(192)=>722,chr(193)=>722,chr(194)=>722,chr(195)=>722,chr(196)=>722,chr(197)=>722,
|
||||
chr(198)=>1000,chr(199)=>722,chr(200)=>667,chr(201)=>667,chr(202)=>667,chr(203)=>667,chr(204)=>278,chr(205)=>278,chr(206)=>278,chr(207)=>278,chr(208)=>722,chr(209)=>722,chr(210)=>778,chr(211)=>778,chr(212)=>778,chr(213)=>778,chr(214)=>778,chr(215)=>584,chr(216)=>778,chr(217)=>722,chr(218)=>722,chr(219)=>722,
|
||||
chr(220)=>722,chr(221)=>667,chr(222)=>667,chr(223)=>611,chr(224)=>556,chr(225)=>556,chr(226)=>556,chr(227)=>556,chr(228)=>556,chr(229)=>556,chr(230)=>889,chr(231)=>556,chr(232)=>556,chr(233)=>556,chr(234)=>556,chr(235)=>556,chr(236)=>278,chr(237)=>278,chr(238)=>278,chr(239)=>278,chr(240)=>611,chr(241)=>611,
|
||||
chr(242)=>611,chr(243)=>611,chr(244)=>611,chr(245)=>611,chr(246)=>611,chr(247)=>584,chr(248)=>611,chr(249)=>611,chr(250)=>611,chr(251)=>611,chr(252)=>611,chr(253)=>556,chr(254)=>611,chr(255)=>556
|
||||
);
|
@ -0,0 +1,23 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
$tntofficiel_fpdf_charwidths['helveticaBI']=array(
|
||||
chr(0)=>278,chr(1)=>278,chr(2)=>278,chr(3)=>278,chr(4)=>278,chr(5)=>278,chr(6)=>278,chr(7)=>278,chr(8)=>278,chr(9)=>278,chr(10)=>278,chr(11)=>278,chr(12)=>278,chr(13)=>278,chr(14)=>278,chr(15)=>278,chr(16)=>278,chr(17)=>278,chr(18)=>278,chr(19)=>278,chr(20)=>278,chr(21)=>278,
|
||||
chr(22)=>278,chr(23)=>278,chr(24)=>278,chr(25)=>278,chr(26)=>278,chr(27)=>278,chr(28)=>278,chr(29)=>278,chr(30)=>278,chr(31)=>278,' '=>278,'!'=>333,'"'=>474,'#'=>556,'$'=>556,'%'=>889,'&'=>722,'\''=>238,'('=>333,')'=>333,'*'=>389,'+'=>584,
|
||||
','=>278,'-'=>333,'.'=>278,'/'=>278,'0'=>556,'1'=>556,'2'=>556,'3'=>556,'4'=>556,'5'=>556,'6'=>556,'7'=>556,'8'=>556,'9'=>556,':'=>333,';'=>333,'<'=>584,'='=>584,'>'=>584,'?'=>611,'@'=>975,'A'=>722,
|
||||
'B'=>722,'C'=>722,'D'=>722,'E'=>667,'F'=>611,'G'=>778,'H'=>722,'I'=>278,'J'=>556,'K'=>722,'L'=>611,'M'=>833,'N'=>722,'O'=>778,'P'=>667,'Q'=>778,'R'=>722,'S'=>667,'T'=>611,'U'=>722,'V'=>667,'W'=>944,
|
||||
'X'=>667,'Y'=>667,'Z'=>611,'['=>333,'\\'=>278,']'=>333,'^'=>584,'_'=>556,'`'=>333,'a'=>556,'b'=>611,'c'=>556,'d'=>611,'e'=>556,'f'=>333,'g'=>611,'h'=>611,'i'=>278,'j'=>278,'k'=>556,'l'=>278,'m'=>889,
|
||||
'n'=>611,'o'=>611,'p'=>611,'q'=>611,'r'=>389,'s'=>556,'t'=>333,'u'=>611,'v'=>556,'w'=>778,'x'=>556,'y'=>556,'z'=>500,'{'=>389,'|'=>280,'}'=>389,'~'=>584,chr(127)=>350,chr(128)=>556,chr(129)=>350,chr(130)=>278,chr(131)=>556,
|
||||
chr(132)=>500,chr(133)=>1000,chr(134)=>556,chr(135)=>556,chr(136)=>333,chr(137)=>1000,chr(138)=>667,chr(139)=>333,chr(140)=>1000,chr(141)=>350,chr(142)=>611,chr(143)=>350,chr(144)=>350,chr(145)=>278,chr(146)=>278,chr(147)=>500,chr(148)=>500,chr(149)=>350,chr(150)=>556,chr(151)=>1000,chr(152)=>333,chr(153)=>1000,
|
||||
chr(154)=>556,chr(155)=>333,chr(156)=>944,chr(157)=>350,chr(158)=>500,chr(159)=>667,chr(160)=>278,chr(161)=>333,chr(162)=>556,chr(163)=>556,chr(164)=>556,chr(165)=>556,chr(166)=>280,chr(167)=>556,chr(168)=>333,chr(169)=>737,chr(170)=>370,chr(171)=>556,chr(172)=>584,chr(173)=>333,chr(174)=>737,chr(175)=>333,
|
||||
chr(176)=>400,chr(177)=>584,chr(178)=>333,chr(179)=>333,chr(180)=>333,chr(181)=>611,chr(182)=>556,chr(183)=>278,chr(184)=>333,chr(185)=>333,chr(186)=>365,chr(187)=>556,chr(188)=>834,chr(189)=>834,chr(190)=>834,chr(191)=>611,chr(192)=>722,chr(193)=>722,chr(194)=>722,chr(195)=>722,chr(196)=>722,chr(197)=>722,
|
||||
chr(198)=>1000,chr(199)=>722,chr(200)=>667,chr(201)=>667,chr(202)=>667,chr(203)=>667,chr(204)=>278,chr(205)=>278,chr(206)=>278,chr(207)=>278,chr(208)=>722,chr(209)=>722,chr(210)=>778,chr(211)=>778,chr(212)=>778,chr(213)=>778,chr(214)=>778,chr(215)=>584,chr(216)=>778,chr(217)=>722,chr(218)=>722,chr(219)=>722,
|
||||
chr(220)=>722,chr(221)=>667,chr(222)=>667,chr(223)=>611,chr(224)=>556,chr(225)=>556,chr(226)=>556,chr(227)=>556,chr(228)=>556,chr(229)=>556,chr(230)=>889,chr(231)=>556,chr(232)=>556,chr(233)=>556,chr(234)=>556,chr(235)=>556,chr(236)=>278,chr(237)=>278,chr(238)=>278,chr(239)=>278,chr(240)=>611,chr(241)=>611,
|
||||
chr(242)=>611,chr(243)=>611,chr(244)=>611,chr(245)=>611,chr(246)=>611,chr(247)=>584,chr(248)=>611,chr(249)=>611,chr(250)=>611,chr(251)=>611,chr(252)=>611,chr(253)=>556,chr(254)=>611,chr(255)=>556
|
||||
);
|
@ -0,0 +1,23 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
$tntofficiel_fpdf_charwidths['helveticaI']=array(
|
||||
chr(0)=>278,chr(1)=>278,chr(2)=>278,chr(3)=>278,chr(4)=>278,chr(5)=>278,chr(6)=>278,chr(7)=>278,chr(8)=>278,chr(9)=>278,chr(10)=>278,chr(11)=>278,chr(12)=>278,chr(13)=>278,chr(14)=>278,chr(15)=>278,chr(16)=>278,chr(17)=>278,chr(18)=>278,chr(19)=>278,chr(20)=>278,chr(21)=>278,
|
||||
chr(22)=>278,chr(23)=>278,chr(24)=>278,chr(25)=>278,chr(26)=>278,chr(27)=>278,chr(28)=>278,chr(29)=>278,chr(30)=>278,chr(31)=>278,' '=>278,'!'=>278,'"'=>355,'#'=>556,'$'=>556,'%'=>889,'&'=>667,'\''=>191,'('=>333,')'=>333,'*'=>389,'+'=>584,
|
||||
','=>278,'-'=>333,'.'=>278,'/'=>278,'0'=>556,'1'=>556,'2'=>556,'3'=>556,'4'=>556,'5'=>556,'6'=>556,'7'=>556,'8'=>556,'9'=>556,':'=>278,';'=>278,'<'=>584,'='=>584,'>'=>584,'?'=>556,'@'=>1015,'A'=>667,
|
||||
'B'=>667,'C'=>722,'D'=>722,'E'=>667,'F'=>611,'G'=>778,'H'=>722,'I'=>278,'J'=>500,'K'=>667,'L'=>556,'M'=>833,'N'=>722,'O'=>778,'P'=>667,'Q'=>778,'R'=>722,'S'=>667,'T'=>611,'U'=>722,'V'=>667,'W'=>944,
|
||||
'X'=>667,'Y'=>667,'Z'=>611,'['=>278,'\\'=>278,']'=>278,'^'=>469,'_'=>556,'`'=>333,'a'=>556,'b'=>556,'c'=>500,'d'=>556,'e'=>556,'f'=>278,'g'=>556,'h'=>556,'i'=>222,'j'=>222,'k'=>500,'l'=>222,'m'=>833,
|
||||
'n'=>556,'o'=>556,'p'=>556,'q'=>556,'r'=>333,'s'=>500,'t'=>278,'u'=>556,'v'=>500,'w'=>722,'x'=>500,'y'=>500,'z'=>500,'{'=>334,'|'=>260,'}'=>334,'~'=>584,chr(127)=>350,chr(128)=>556,chr(129)=>350,chr(130)=>222,chr(131)=>556,
|
||||
chr(132)=>333,chr(133)=>1000,chr(134)=>556,chr(135)=>556,chr(136)=>333,chr(137)=>1000,chr(138)=>667,chr(139)=>333,chr(140)=>1000,chr(141)=>350,chr(142)=>611,chr(143)=>350,chr(144)=>350,chr(145)=>222,chr(146)=>222,chr(147)=>333,chr(148)=>333,chr(149)=>350,chr(150)=>556,chr(151)=>1000,chr(152)=>333,chr(153)=>1000,
|
||||
chr(154)=>500,chr(155)=>333,chr(156)=>944,chr(157)=>350,chr(158)=>500,chr(159)=>667,chr(160)=>278,chr(161)=>333,chr(162)=>556,chr(163)=>556,chr(164)=>556,chr(165)=>556,chr(166)=>260,chr(167)=>556,chr(168)=>333,chr(169)=>737,chr(170)=>370,chr(171)=>556,chr(172)=>584,chr(173)=>333,chr(174)=>737,chr(175)=>333,
|
||||
chr(176)=>400,chr(177)=>584,chr(178)=>333,chr(179)=>333,chr(180)=>333,chr(181)=>556,chr(182)=>537,chr(183)=>278,chr(184)=>333,chr(185)=>333,chr(186)=>365,chr(187)=>556,chr(188)=>834,chr(189)=>834,chr(190)=>834,chr(191)=>611,chr(192)=>667,chr(193)=>667,chr(194)=>667,chr(195)=>667,chr(196)=>667,chr(197)=>667,
|
||||
chr(198)=>1000,chr(199)=>722,chr(200)=>667,chr(201)=>667,chr(202)=>667,chr(203)=>667,chr(204)=>278,chr(205)=>278,chr(206)=>278,chr(207)=>278,chr(208)=>722,chr(209)=>722,chr(210)=>778,chr(211)=>778,chr(212)=>778,chr(213)=>778,chr(214)=>778,chr(215)=>584,chr(216)=>778,chr(217)=>722,chr(218)=>722,chr(219)=>722,
|
||||
chr(220)=>722,chr(221)=>667,chr(222)=>667,chr(223)=>611,chr(224)=>556,chr(225)=>556,chr(226)=>556,chr(227)=>556,chr(228)=>556,chr(229)=>556,chr(230)=>889,chr(231)=>500,chr(232)=>556,chr(233)=>556,chr(234)=>556,chr(235)=>556,chr(236)=>278,chr(237)=>278,chr(238)=>278,chr(239)=>278,chr(240)=>556,chr(241)=>556,
|
||||
chr(242)=>556,chr(243)=>556,chr(244)=>556,chr(245)=>556,chr(246)=>556,chr(247)=>584,chr(248)=>611,chr(249)=>556,chr(250)=>556,chr(251)=>556,chr(252)=>556,chr(253)=>500,chr(254)=>556,chr(255)=>500
|
||||
);
|
18
www/modules/tntofficiel/libraries/pdf/fpdf/font/index.php
Normal file
18
www/modules/tntofficiel/libraries/pdf/fpdf/font/index.php
Normal file
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../');
|
||||
exit;
|
@ -0,0 +1,251 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+20AC Euro
|
||||
!82 U+201A quotesinglbase
|
||||
!84 U+201E quotedblbase
|
||||
!85 U+2026 ellipsis
|
||||
!86 U+2020 dagger
|
||||
!87 U+2021 daggerdbl
|
||||
!89 U+2030 perthousand
|
||||
!8A U+0160 Scaron
|
||||
!8B U+2039 guilsinglleft
|
||||
!8C U+015A Sacute
|
||||
!8D U+0164 Tcaron
|
||||
!8E U+017D Zcaron
|
||||
!8F U+0179 Zacute
|
||||
!91 U+2018 quoteleft
|
||||
!92 U+2019 quoteright
|
||||
!93 U+201C quotedblleft
|
||||
!94 U+201D quotedblright
|
||||
!95 U+2022 bullet
|
||||
!96 U+2013 endash
|
||||
!97 U+2014 emdash
|
||||
!99 U+2122 trademark
|
||||
!9A U+0161 scaron
|
||||
!9B U+203A guilsinglright
|
||||
!9C U+015B sacute
|
||||
!9D U+0165 tcaron
|
||||
!9E U+017E zcaron
|
||||
!9F U+017A zacute
|
||||
!A0 U+00A0 space
|
||||
!A1 U+02C7 caron
|
||||
!A2 U+02D8 breve
|
||||
!A3 U+0141 Lslash
|
||||
!A4 U+00A4 currency
|
||||
!A5 U+0104 Aogonek
|
||||
!A6 U+00A6 brokenbar
|
||||
!A7 U+00A7 section
|
||||
!A8 U+00A8 dieresis
|
||||
!A9 U+00A9 copyright
|
||||
!AA U+015E Scedilla
|
||||
!AB U+00AB guillemotleft
|
||||
!AC U+00AC logicalnot
|
||||
!AD U+00AD hyphen
|
||||
!AE U+00AE registered
|
||||
!AF U+017B Zdotaccent
|
||||
!B0 U+00B0 degree
|
||||
!B1 U+00B1 plusminus
|
||||
!B2 U+02DB ogonek
|
||||
!B3 U+0142 lslash
|
||||
!B4 U+00B4 acute
|
||||
!B5 U+00B5 mu
|
||||
!B6 U+00B6 paragraph
|
||||
!B7 U+00B7 periodcentered
|
||||
!B8 U+00B8 cedilla
|
||||
!B9 U+0105 aogonek
|
||||
!BA U+015F scedilla
|
||||
!BB U+00BB guillemotright
|
||||
!BC U+013D Lcaron
|
||||
!BD U+02DD hungarumlaut
|
||||
!BE U+013E lcaron
|
||||
!BF U+017C zdotaccent
|
||||
!C0 U+0154 Racute
|
||||
!C1 U+00C1 Aacute
|
||||
!C2 U+00C2 Acircumflex
|
||||
!C3 U+0102 Abreve
|
||||
!C4 U+00C4 Adieresis
|
||||
!C5 U+0139 Lacute
|
||||
!C6 U+0106 Cacute
|
||||
!C7 U+00C7 Ccedilla
|
||||
!C8 U+010C Ccaron
|
||||
!C9 U+00C9 Eacute
|
||||
!CA U+0118 Eogonek
|
||||
!CB U+00CB Edieresis
|
||||
!CC U+011A Ecaron
|
||||
!CD U+00CD Iacute
|
||||
!CE U+00CE Icircumflex
|
||||
!CF U+010E Dcaron
|
||||
!D0 U+0110 Dcroat
|
||||
!D1 U+0143 Nacute
|
||||
!D2 U+0147 Ncaron
|
||||
!D3 U+00D3 Oacute
|
||||
!D4 U+00D4 Ocircumflex
|
||||
!D5 U+0150 Ohungarumlaut
|
||||
!D6 U+00D6 Odieresis
|
||||
!D7 U+00D7 multiply
|
||||
!D8 U+0158 Rcaron
|
||||
!D9 U+016E Uring
|
||||
!DA U+00DA Uacute
|
||||
!DB U+0170 Uhungarumlaut
|
||||
!DC U+00DC Udieresis
|
||||
!DD U+00DD Yacute
|
||||
!DE U+0162 Tcommaaccent
|
||||
!DF U+00DF germandbls
|
||||
!E0 U+0155 racute
|
||||
!E1 U+00E1 aacute
|
||||
!E2 U+00E2 acircumflex
|
||||
!E3 U+0103 abreve
|
||||
!E4 U+00E4 adieresis
|
||||
!E5 U+013A lacute
|
||||
!E6 U+0107 cacute
|
||||
!E7 U+00E7 ccedilla
|
||||
!E8 U+010D ccaron
|
||||
!E9 U+00E9 eacute
|
||||
!EA U+0119 eogonek
|
||||
!EB U+00EB edieresis
|
||||
!EC U+011B ecaron
|
||||
!ED U+00ED iacute
|
||||
!EE U+00EE icircumflex
|
||||
!EF U+010F dcaron
|
||||
!F0 U+0111 dcroat
|
||||
!F1 U+0144 nacute
|
||||
!F2 U+0148 ncaron
|
||||
!F3 U+00F3 oacute
|
||||
!F4 U+00F4 ocircumflex
|
||||
!F5 U+0151 ohungarumlaut
|
||||
!F6 U+00F6 odieresis
|
||||
!F7 U+00F7 divide
|
||||
!F8 U+0159 rcaron
|
||||
!F9 U+016F uring
|
||||
!FA U+00FA uacute
|
||||
!FB U+0171 uhungarumlaut
|
||||
!FC U+00FC udieresis
|
||||
!FD U+00FD yacute
|
||||
!FE U+0163 tcommaaccent
|
||||
!FF U+02D9 dotaccent
|
@ -0,0 +1,255 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+0402 afii10051
|
||||
!81 U+0403 afii10052
|
||||
!82 U+201A quotesinglbase
|
||||
!83 U+0453 afii10100
|
||||
!84 U+201E quotedblbase
|
||||
!85 U+2026 ellipsis
|
||||
!86 U+2020 dagger
|
||||
!87 U+2021 daggerdbl
|
||||
!88 U+20AC Euro
|
||||
!89 U+2030 perthousand
|
||||
!8A U+0409 afii10058
|
||||
!8B U+2039 guilsinglleft
|
||||
!8C U+040A afii10059
|
||||
!8D U+040C afii10061
|
||||
!8E U+040B afii10060
|
||||
!8F U+040F afii10145
|
||||
!90 U+0452 afii10099
|
||||
!91 U+2018 quoteleft
|
||||
!92 U+2019 quoteright
|
||||
!93 U+201C quotedblleft
|
||||
!94 U+201D quotedblright
|
||||
!95 U+2022 bullet
|
||||
!96 U+2013 endash
|
||||
!97 U+2014 emdash
|
||||
!99 U+2122 trademark
|
||||
!9A U+0459 afii10106
|
||||
!9B U+203A guilsinglright
|
||||
!9C U+045A afii10107
|
||||
!9D U+045C afii10109
|
||||
!9E U+045B afii10108
|
||||
!9F U+045F afii10193
|
||||
!A0 U+00A0 space
|
||||
!A1 U+040E afii10062
|
||||
!A2 U+045E afii10110
|
||||
!A3 U+0408 afii10057
|
||||
!A4 U+00A4 currency
|
||||
!A5 U+0490 afii10050
|
||||
!A6 U+00A6 brokenbar
|
||||
!A7 U+00A7 section
|
||||
!A8 U+0401 afii10023
|
||||
!A9 U+00A9 copyright
|
||||
!AA U+0404 afii10053
|
||||
!AB U+00AB guillemotleft
|
||||
!AC U+00AC logicalnot
|
||||
!AD U+00AD hyphen
|
||||
!AE U+00AE registered
|
||||
!AF U+0407 afii10056
|
||||
!B0 U+00B0 degree
|
||||
!B1 U+00B1 plusminus
|
||||
!B2 U+0406 afii10055
|
||||
!B3 U+0456 afii10103
|
||||
!B4 U+0491 afii10098
|
||||
!B5 U+00B5 mu
|
||||
!B6 U+00B6 paragraph
|
||||
!B7 U+00B7 periodcentered
|
||||
!B8 U+0451 afii10071
|
||||
!B9 U+2116 afii61352
|
||||
!BA U+0454 afii10101
|
||||
!BB U+00BB guillemotright
|
||||
!BC U+0458 afii10105
|
||||
!BD U+0405 afii10054
|
||||
!BE U+0455 afii10102
|
||||
!BF U+0457 afii10104
|
||||
!C0 U+0410 afii10017
|
||||
!C1 U+0411 afii10018
|
||||
!C2 U+0412 afii10019
|
||||
!C3 U+0413 afii10020
|
||||
!C4 U+0414 afii10021
|
||||
!C5 U+0415 afii10022
|
||||
!C6 U+0416 afii10024
|
||||
!C7 U+0417 afii10025
|
||||
!C8 U+0418 afii10026
|
||||
!C9 U+0419 afii10027
|
||||
!CA U+041A afii10028
|
||||
!CB U+041B afii10029
|
||||
!CC U+041C afii10030
|
||||
!CD U+041D afii10031
|
||||
!CE U+041E afii10032
|
||||
!CF U+041F afii10033
|
||||
!D0 U+0420 afii10034
|
||||
!D1 U+0421 afii10035
|
||||
!D2 U+0422 afii10036
|
||||
!D3 U+0423 afii10037
|
||||
!D4 U+0424 afii10038
|
||||
!D5 U+0425 afii10039
|
||||
!D6 U+0426 afii10040
|
||||
!D7 U+0427 afii10041
|
||||
!D8 U+0428 afii10042
|
||||
!D9 U+0429 afii10043
|
||||
!DA U+042A afii10044
|
||||
!DB U+042B afii10045
|
||||
!DC U+042C afii10046
|
||||
!DD U+042D afii10047
|
||||
!DE U+042E afii10048
|
||||
!DF U+042F afii10049
|
||||
!E0 U+0430 afii10065
|
||||
!E1 U+0431 afii10066
|
||||
!E2 U+0432 afii10067
|
||||
!E3 U+0433 afii10068
|
||||
!E4 U+0434 afii10069
|
||||
!E5 U+0435 afii10070
|
||||
!E6 U+0436 afii10072
|
||||
!E7 U+0437 afii10073
|
||||
!E8 U+0438 afii10074
|
||||
!E9 U+0439 afii10075
|
||||
!EA U+043A afii10076
|
||||
!EB U+043B afii10077
|
||||
!EC U+043C afii10078
|
||||
!ED U+043D afii10079
|
||||
!EE U+043E afii10080
|
||||
!EF U+043F afii10081
|
||||
!F0 U+0440 afii10082
|
||||
!F1 U+0441 afii10083
|
||||
!F2 U+0442 afii10084
|
||||
!F3 U+0443 afii10085
|
||||
!F4 U+0444 afii10086
|
||||
!F5 U+0445 afii10087
|
||||
!F6 U+0446 afii10088
|
||||
!F7 U+0447 afii10089
|
||||
!F8 U+0448 afii10090
|
||||
!F9 U+0449 afii10091
|
||||
!FA U+044A afii10092
|
||||
!FB U+044B afii10093
|
||||
!FC U+044C afii10094
|
||||
!FD U+044D afii10095
|
||||
!FE U+044E afii10096
|
||||
!FF U+044F afii10097
|
@ -0,0 +1,251 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+20AC Euro
|
||||
!82 U+201A quotesinglbase
|
||||
!83 U+0192 florin
|
||||
!84 U+201E quotedblbase
|
||||
!85 U+2026 ellipsis
|
||||
!86 U+2020 dagger
|
||||
!87 U+2021 daggerdbl
|
||||
!88 U+02C6 circumflex
|
||||
!89 U+2030 perthousand
|
||||
!8A U+0160 Scaron
|
||||
!8B U+2039 guilsinglleft
|
||||
!8C U+0152 OE
|
||||
!8E U+017D Zcaron
|
||||
!91 U+2018 quoteleft
|
||||
!92 U+2019 quoteright
|
||||
!93 U+201C quotedblleft
|
||||
!94 U+201D quotedblright
|
||||
!95 U+2022 bullet
|
||||
!96 U+2013 endash
|
||||
!97 U+2014 emdash
|
||||
!98 U+02DC tilde
|
||||
!99 U+2122 trademark
|
||||
!9A U+0161 scaron
|
||||
!9B U+203A guilsinglright
|
||||
!9C U+0153 oe
|
||||
!9E U+017E zcaron
|
||||
!9F U+0178 Ydieresis
|
||||
!A0 U+00A0 space
|
||||
!A1 U+00A1 exclamdown
|
||||
!A2 U+00A2 cent
|
||||
!A3 U+00A3 sterling
|
||||
!A4 U+00A4 currency
|
||||
!A5 U+00A5 yen
|
||||
!A6 U+00A6 brokenbar
|
||||
!A7 U+00A7 section
|
||||
!A8 U+00A8 dieresis
|
||||
!A9 U+00A9 copyright
|
||||
!AA U+00AA ordfeminine
|
||||
!AB U+00AB guillemotleft
|
||||
!AC U+00AC logicalnot
|
||||
!AD U+00AD hyphen
|
||||
!AE U+00AE registered
|
||||
!AF U+00AF macron
|
||||
!B0 U+00B0 degree
|
||||
!B1 U+00B1 plusminus
|
||||
!B2 U+00B2 twosuperior
|
||||
!B3 U+00B3 threesuperior
|
||||
!B4 U+00B4 acute
|
||||
!B5 U+00B5 mu
|
||||
!B6 U+00B6 paragraph
|
||||
!B7 U+00B7 periodcentered
|
||||
!B8 U+00B8 cedilla
|
||||
!B9 U+00B9 onesuperior
|
||||
!BA U+00BA ordmasculine
|
||||
!BB U+00BB guillemotright
|
||||
!BC U+00BC onequarter
|
||||
!BD U+00BD onehalf
|
||||
!BE U+00BE threequarters
|
||||
!BF U+00BF questiondown
|
||||
!C0 U+00C0 Agrave
|
||||
!C1 U+00C1 Aacute
|
||||
!C2 U+00C2 Acircumflex
|
||||
!C3 U+00C3 Atilde
|
||||
!C4 U+00C4 Adieresis
|
||||
!C5 U+00C5 Aring
|
||||
!C6 U+00C6 AE
|
||||
!C7 U+00C7 Ccedilla
|
||||
!C8 U+00C8 Egrave
|
||||
!C9 U+00C9 Eacute
|
||||
!CA U+00CA Ecircumflex
|
||||
!CB U+00CB Edieresis
|
||||
!CC U+00CC Igrave
|
||||
!CD U+00CD Iacute
|
||||
!CE U+00CE Icircumflex
|
||||
!CF U+00CF Idieresis
|
||||
!D0 U+00D0 Eth
|
||||
!D1 U+00D1 Ntilde
|
||||
!D2 U+00D2 Ograve
|
||||
!D3 U+00D3 Oacute
|
||||
!D4 U+00D4 Ocircumflex
|
||||
!D5 U+00D5 Otilde
|
||||
!D6 U+00D6 Odieresis
|
||||
!D7 U+00D7 multiply
|
||||
!D8 U+00D8 Oslash
|
||||
!D9 U+00D9 Ugrave
|
||||
!DA U+00DA Uacute
|
||||
!DB U+00DB Ucircumflex
|
||||
!DC U+00DC Udieresis
|
||||
!DD U+00DD Yacute
|
||||
!DE U+00DE Thorn
|
||||
!DF U+00DF germandbls
|
||||
!E0 U+00E0 agrave
|
||||
!E1 U+00E1 aacute
|
||||
!E2 U+00E2 acircumflex
|
||||
!E3 U+00E3 atilde
|
||||
!E4 U+00E4 adieresis
|
||||
!E5 U+00E5 aring
|
||||
!E6 U+00E6 ae
|
||||
!E7 U+00E7 ccedilla
|
||||
!E8 U+00E8 egrave
|
||||
!E9 U+00E9 eacute
|
||||
!EA U+00EA ecircumflex
|
||||
!EB U+00EB edieresis
|
||||
!EC U+00EC igrave
|
||||
!ED U+00ED iacute
|
||||
!EE U+00EE icircumflex
|
||||
!EF U+00EF idieresis
|
||||
!F0 U+00F0 eth
|
||||
!F1 U+00F1 ntilde
|
||||
!F2 U+00F2 ograve
|
||||
!F3 U+00F3 oacute
|
||||
!F4 U+00F4 ocircumflex
|
||||
!F5 U+00F5 otilde
|
||||
!F6 U+00F6 odieresis
|
||||
!F7 U+00F7 divide
|
||||
!F8 U+00F8 oslash
|
||||
!F9 U+00F9 ugrave
|
||||
!FA U+00FA uacute
|
||||
!FB U+00FB ucircumflex
|
||||
!FC U+00FC udieresis
|
||||
!FD U+00FD yacute
|
||||
!FE U+00FE thorn
|
||||
!FF U+00FF ydieresis
|
@ -0,0 +1,239 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+20AC Euro
|
||||
!82 U+201A quotesinglbase
|
||||
!83 U+0192 florin
|
||||
!84 U+201E quotedblbase
|
||||
!85 U+2026 ellipsis
|
||||
!86 U+2020 dagger
|
||||
!87 U+2021 daggerdbl
|
||||
!89 U+2030 perthousand
|
||||
!8B U+2039 guilsinglleft
|
||||
!91 U+2018 quoteleft
|
||||
!92 U+2019 quoteright
|
||||
!93 U+201C quotedblleft
|
||||
!94 U+201D quotedblright
|
||||
!95 U+2022 bullet
|
||||
!96 U+2013 endash
|
||||
!97 U+2014 emdash
|
||||
!99 U+2122 trademark
|
||||
!9B U+203A guilsinglright
|
||||
!A0 U+00A0 space
|
||||
!A1 U+0385 dieresistonos
|
||||
!A2 U+0386 Alphatonos
|
||||
!A3 U+00A3 sterling
|
||||
!A4 U+00A4 currency
|
||||
!A5 U+00A5 yen
|
||||
!A6 U+00A6 brokenbar
|
||||
!A7 U+00A7 section
|
||||
!A8 U+00A8 dieresis
|
||||
!A9 U+00A9 copyright
|
||||
!AB U+00AB guillemotleft
|
||||
!AC U+00AC logicalnot
|
||||
!AD U+00AD hyphen
|
||||
!AE U+00AE registered
|
||||
!AF U+2015 afii00208
|
||||
!B0 U+00B0 degree
|
||||
!B1 U+00B1 plusminus
|
||||
!B2 U+00B2 twosuperior
|
||||
!B3 U+00B3 threesuperior
|
||||
!B4 U+0384 tonos
|
||||
!B5 U+00B5 mu
|
||||
!B6 U+00B6 paragraph
|
||||
!B7 U+00B7 periodcentered
|
||||
!B8 U+0388 Epsilontonos
|
||||
!B9 U+0389 Etatonos
|
||||
!BA U+038A Iotatonos
|
||||
!BB U+00BB guillemotright
|
||||
!BC U+038C Omicrontonos
|
||||
!BD U+00BD onehalf
|
||||
!BE U+038E Upsilontonos
|
||||
!BF U+038F Omegatonos
|
||||
!C0 U+0390 iotadieresistonos
|
||||
!C1 U+0391 Alpha
|
||||
!C2 U+0392 Beta
|
||||
!C3 U+0393 Gamma
|
||||
!C4 U+0394 Delta
|
||||
!C5 U+0395 Epsilon
|
||||
!C6 U+0396 Zeta
|
||||
!C7 U+0397 Eta
|
||||
!C8 U+0398 Theta
|
||||
!C9 U+0399 Iota
|
||||
!CA U+039A Kappa
|
||||
!CB U+039B Lambda
|
||||
!CC U+039C Mu
|
||||
!CD U+039D Nu
|
||||
!CE U+039E Xi
|
||||
!CF U+039F Omicron
|
||||
!D0 U+03A0 Pi
|
||||
!D1 U+03A1 Rho
|
||||
!D3 U+03A3 Sigma
|
||||
!D4 U+03A4 Tau
|
||||
!D5 U+03A5 Upsilon
|
||||
!D6 U+03A6 Phi
|
||||
!D7 U+03A7 Chi
|
||||
!D8 U+03A8 Psi
|
||||
!D9 U+03A9 Omega
|
||||
!DA U+03AA Iotadieresis
|
||||
!DB U+03AB Upsilondieresis
|
||||
!DC U+03AC alphatonos
|
||||
!DD U+03AD epsilontonos
|
||||
!DE U+03AE etatonos
|
||||
!DF U+03AF iotatonos
|
||||
!E0 U+03B0 upsilondieresistonos
|
||||
!E1 U+03B1 alpha
|
||||
!E2 U+03B2 beta
|
||||
!E3 U+03B3 gamma
|
||||
!E4 U+03B4 delta
|
||||
!E5 U+03B5 epsilon
|
||||
!E6 U+03B6 zeta
|
||||
!E7 U+03B7 eta
|
||||
!E8 U+03B8 theta
|
||||
!E9 U+03B9 iota
|
||||
!EA U+03BA kappa
|
||||
!EB U+03BB lambda
|
||||
!EC U+03BC mu
|
||||
!ED U+03BD nu
|
||||
!EE U+03BE xi
|
||||
!EF U+03BF omicron
|
||||
!F0 U+03C0 pi
|
||||
!F1 U+03C1 rho
|
||||
!F2 U+03C2 sigma1
|
||||
!F3 U+03C3 sigma
|
||||
!F4 U+03C4 tau
|
||||
!F5 U+03C5 upsilon
|
||||
!F6 U+03C6 phi
|
||||
!F7 U+03C7 chi
|
||||
!F8 U+03C8 psi
|
||||
!F9 U+03C9 omega
|
||||
!FA U+03CA iotadieresis
|
||||
!FB U+03CB upsilondieresis
|
||||
!FC U+03CC omicrontonos
|
||||
!FD U+03CD upsilontonos
|
||||
!FE U+03CE omegatonos
|
@ -0,0 +1,249 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+20AC Euro
|
||||
!82 U+201A quotesinglbase
|
||||
!83 U+0192 florin
|
||||
!84 U+201E quotedblbase
|
||||
!85 U+2026 ellipsis
|
||||
!86 U+2020 dagger
|
||||
!87 U+2021 daggerdbl
|
||||
!88 U+02C6 circumflex
|
||||
!89 U+2030 perthousand
|
||||
!8A U+0160 Scaron
|
||||
!8B U+2039 guilsinglleft
|
||||
!8C U+0152 OE
|
||||
!91 U+2018 quoteleft
|
||||
!92 U+2019 quoteright
|
||||
!93 U+201C quotedblleft
|
||||
!94 U+201D quotedblright
|
||||
!95 U+2022 bullet
|
||||
!96 U+2013 endash
|
||||
!97 U+2014 emdash
|
||||
!98 U+02DC tilde
|
||||
!99 U+2122 trademark
|
||||
!9A U+0161 scaron
|
||||
!9B U+203A guilsinglright
|
||||
!9C U+0153 oe
|
||||
!9F U+0178 Ydieresis
|
||||
!A0 U+00A0 space
|
||||
!A1 U+00A1 exclamdown
|
||||
!A2 U+00A2 cent
|
||||
!A3 U+00A3 sterling
|
||||
!A4 U+00A4 currency
|
||||
!A5 U+00A5 yen
|
||||
!A6 U+00A6 brokenbar
|
||||
!A7 U+00A7 section
|
||||
!A8 U+00A8 dieresis
|
||||
!A9 U+00A9 copyright
|
||||
!AA U+00AA ordfeminine
|
||||
!AB U+00AB guillemotleft
|
||||
!AC U+00AC logicalnot
|
||||
!AD U+00AD hyphen
|
||||
!AE U+00AE registered
|
||||
!AF U+00AF macron
|
||||
!B0 U+00B0 degree
|
||||
!B1 U+00B1 plusminus
|
||||
!B2 U+00B2 twosuperior
|
||||
!B3 U+00B3 threesuperior
|
||||
!B4 U+00B4 acute
|
||||
!B5 U+00B5 mu
|
||||
!B6 U+00B6 paragraph
|
||||
!B7 U+00B7 periodcentered
|
||||
!B8 U+00B8 cedilla
|
||||
!B9 U+00B9 onesuperior
|
||||
!BA U+00BA ordmasculine
|
||||
!BB U+00BB guillemotright
|
||||
!BC U+00BC onequarter
|
||||
!BD U+00BD onehalf
|
||||
!BE U+00BE threequarters
|
||||
!BF U+00BF questiondown
|
||||
!C0 U+00C0 Agrave
|
||||
!C1 U+00C1 Aacute
|
||||
!C2 U+00C2 Acircumflex
|
||||
!C3 U+00C3 Atilde
|
||||
!C4 U+00C4 Adieresis
|
||||
!C5 U+00C5 Aring
|
||||
!C6 U+00C6 AE
|
||||
!C7 U+00C7 Ccedilla
|
||||
!C8 U+00C8 Egrave
|
||||
!C9 U+00C9 Eacute
|
||||
!CA U+00CA Ecircumflex
|
||||
!CB U+00CB Edieresis
|
||||
!CC U+00CC Igrave
|
||||
!CD U+00CD Iacute
|
||||
!CE U+00CE Icircumflex
|
||||
!CF U+00CF Idieresis
|
||||
!D0 U+011E Gbreve
|
||||
!D1 U+00D1 Ntilde
|
||||
!D2 U+00D2 Ograve
|
||||
!D3 U+00D3 Oacute
|
||||
!D4 U+00D4 Ocircumflex
|
||||
!D5 U+00D5 Otilde
|
||||
!D6 U+00D6 Odieresis
|
||||
!D7 U+00D7 multiply
|
||||
!D8 U+00D8 Oslash
|
||||
!D9 U+00D9 Ugrave
|
||||
!DA U+00DA Uacute
|
||||
!DB U+00DB Ucircumflex
|
||||
!DC U+00DC Udieresis
|
||||
!DD U+0130 Idotaccent
|
||||
!DE U+015E Scedilla
|
||||
!DF U+00DF germandbls
|
||||
!E0 U+00E0 agrave
|
||||
!E1 U+00E1 aacute
|
||||
!E2 U+00E2 acircumflex
|
||||
!E3 U+00E3 atilde
|
||||
!E4 U+00E4 adieresis
|
||||
!E5 U+00E5 aring
|
||||
!E6 U+00E6 ae
|
||||
!E7 U+00E7 ccedilla
|
||||
!E8 U+00E8 egrave
|
||||
!E9 U+00E9 eacute
|
||||
!EA U+00EA ecircumflex
|
||||
!EB U+00EB edieresis
|
||||
!EC U+00EC igrave
|
||||
!ED U+00ED iacute
|
||||
!EE U+00EE icircumflex
|
||||
!EF U+00EF idieresis
|
||||
!F0 U+011F gbreve
|
||||
!F1 U+00F1 ntilde
|
||||
!F2 U+00F2 ograve
|
||||
!F3 U+00F3 oacute
|
||||
!F4 U+00F4 ocircumflex
|
||||
!F5 U+00F5 otilde
|
||||
!F6 U+00F6 odieresis
|
||||
!F7 U+00F7 divide
|
||||
!F8 U+00F8 oslash
|
||||
!F9 U+00F9 ugrave
|
||||
!FA U+00FA uacute
|
||||
!FB U+00FB ucircumflex
|
||||
!FC U+00FC udieresis
|
||||
!FD U+0131 dotlessi
|
||||
!FE U+015F scedilla
|
||||
!FF U+00FF ydieresis
|
@ -0,0 +1,233 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+20AC Euro
|
||||
!82 U+201A quotesinglbase
|
||||
!83 U+0192 florin
|
||||
!84 U+201E quotedblbase
|
||||
!85 U+2026 ellipsis
|
||||
!86 U+2020 dagger
|
||||
!87 U+2021 daggerdbl
|
||||
!88 U+02C6 circumflex
|
||||
!89 U+2030 perthousand
|
||||
!8B U+2039 guilsinglleft
|
||||
!91 U+2018 quoteleft
|
||||
!92 U+2019 quoteright
|
||||
!93 U+201C quotedblleft
|
||||
!94 U+201D quotedblright
|
||||
!95 U+2022 bullet
|
||||
!96 U+2013 endash
|
||||
!97 U+2014 emdash
|
||||
!98 U+02DC tilde
|
||||
!99 U+2122 trademark
|
||||
!9B U+203A guilsinglright
|
||||
!A0 U+00A0 space
|
||||
!A1 U+00A1 exclamdown
|
||||
!A2 U+00A2 cent
|
||||
!A3 U+00A3 sterling
|
||||
!A4 U+20AA afii57636
|
||||
!A5 U+00A5 yen
|
||||
!A6 U+00A6 brokenbar
|
||||
!A7 U+00A7 section
|
||||
!A8 U+00A8 dieresis
|
||||
!A9 U+00A9 copyright
|
||||
!AA U+00D7 multiply
|
||||
!AB U+00AB guillemotleft
|
||||
!AC U+00AC logicalnot
|
||||
!AD U+00AD sfthyphen
|
||||
!AE U+00AE registered
|
||||
!AF U+00AF macron
|
||||
!B0 U+00B0 degree
|
||||
!B1 U+00B1 plusminus
|
||||
!B2 U+00B2 twosuperior
|
||||
!B3 U+00B3 threesuperior
|
||||
!B4 U+00B4 acute
|
||||
!B5 U+00B5 mu
|
||||
!B6 U+00B6 paragraph
|
||||
!B7 U+00B7 middot
|
||||
!B8 U+00B8 cedilla
|
||||
!B9 U+00B9 onesuperior
|
||||
!BA U+00F7 divide
|
||||
!BB U+00BB guillemotright
|
||||
!BC U+00BC onequarter
|
||||
!BD U+00BD onehalf
|
||||
!BE U+00BE threequarters
|
||||
!BF U+00BF questiondown
|
||||
!C0 U+05B0 afii57799
|
||||
!C1 U+05B1 afii57801
|
||||
!C2 U+05B2 afii57800
|
||||
!C3 U+05B3 afii57802
|
||||
!C4 U+05B4 afii57793
|
||||
!C5 U+05B5 afii57794
|
||||
!C6 U+05B6 afii57795
|
||||
!C7 U+05B7 afii57798
|
||||
!C8 U+05B8 afii57797
|
||||
!C9 U+05B9 afii57806
|
||||
!CB U+05BB afii57796
|
||||
!CC U+05BC afii57807
|
||||
!CD U+05BD afii57839
|
||||
!CE U+05BE afii57645
|
||||
!CF U+05BF afii57841
|
||||
!D0 U+05C0 afii57842
|
||||
!D1 U+05C1 afii57804
|
||||
!D2 U+05C2 afii57803
|
||||
!D3 U+05C3 afii57658
|
||||
!D4 U+05F0 afii57716
|
||||
!D5 U+05F1 afii57717
|
||||
!D6 U+05F2 afii57718
|
||||
!D7 U+05F3 gereshhebrew
|
||||
!D8 U+05F4 gershayimhebrew
|
||||
!E0 U+05D0 afii57664
|
||||
!E1 U+05D1 afii57665
|
||||
!E2 U+05D2 afii57666
|
||||
!E3 U+05D3 afii57667
|
||||
!E4 U+05D4 afii57668
|
||||
!E5 U+05D5 afii57669
|
||||
!E6 U+05D6 afii57670
|
||||
!E7 U+05D7 afii57671
|
||||
!E8 U+05D8 afii57672
|
||||
!E9 U+05D9 afii57673
|
||||
!EA U+05DA afii57674
|
||||
!EB U+05DB afii57675
|
||||
!EC U+05DC afii57676
|
||||
!ED U+05DD afii57677
|
||||
!EE U+05DE afii57678
|
||||
!EF U+05DF afii57679
|
||||
!F0 U+05E0 afii57680
|
||||
!F1 U+05E1 afii57681
|
||||
!F2 U+05E2 afii57682
|
||||
!F3 U+05E3 afii57683
|
||||
!F4 U+05E4 afii57684
|
||||
!F5 U+05E5 afii57685
|
||||
!F6 U+05E6 afii57686
|
||||
!F7 U+05E7 afii57687
|
||||
!F8 U+05E8 afii57688
|
||||
!F9 U+05E9 afii57689
|
||||
!FA U+05EA afii57690
|
||||
!FD U+200E afii299
|
||||
!FE U+200F afii300
|
@ -0,0 +1,244 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+20AC Euro
|
||||
!82 U+201A quotesinglbase
|
||||
!84 U+201E quotedblbase
|
||||
!85 U+2026 ellipsis
|
||||
!86 U+2020 dagger
|
||||
!87 U+2021 daggerdbl
|
||||
!89 U+2030 perthousand
|
||||
!8B U+2039 guilsinglleft
|
||||
!8D U+00A8 dieresis
|
||||
!8E U+02C7 caron
|
||||
!8F U+00B8 cedilla
|
||||
!91 U+2018 quoteleft
|
||||
!92 U+2019 quoteright
|
||||
!93 U+201C quotedblleft
|
||||
!94 U+201D quotedblright
|
||||
!95 U+2022 bullet
|
||||
!96 U+2013 endash
|
||||
!97 U+2014 emdash
|
||||
!99 U+2122 trademark
|
||||
!9B U+203A guilsinglright
|
||||
!9D U+00AF macron
|
||||
!9E U+02DB ogonek
|
||||
!A0 U+00A0 space
|
||||
!A2 U+00A2 cent
|
||||
!A3 U+00A3 sterling
|
||||
!A4 U+00A4 currency
|
||||
!A6 U+00A6 brokenbar
|
||||
!A7 U+00A7 section
|
||||
!A8 U+00D8 Oslash
|
||||
!A9 U+00A9 copyright
|
||||
!AA U+0156 Rcommaaccent
|
||||
!AB U+00AB guillemotleft
|
||||
!AC U+00AC logicalnot
|
||||
!AD U+00AD hyphen
|
||||
!AE U+00AE registered
|
||||
!AF U+00C6 AE
|
||||
!B0 U+00B0 degree
|
||||
!B1 U+00B1 plusminus
|
||||
!B2 U+00B2 twosuperior
|
||||
!B3 U+00B3 threesuperior
|
||||
!B4 U+00B4 acute
|
||||
!B5 U+00B5 mu
|
||||
!B6 U+00B6 paragraph
|
||||
!B7 U+00B7 periodcentered
|
||||
!B8 U+00F8 oslash
|
||||
!B9 U+00B9 onesuperior
|
||||
!BA U+0157 rcommaaccent
|
||||
!BB U+00BB guillemotright
|
||||
!BC U+00BC onequarter
|
||||
!BD U+00BD onehalf
|
||||
!BE U+00BE threequarters
|
||||
!BF U+00E6 ae
|
||||
!C0 U+0104 Aogonek
|
||||
!C1 U+012E Iogonek
|
||||
!C2 U+0100 Amacron
|
||||
!C3 U+0106 Cacute
|
||||
!C4 U+00C4 Adieresis
|
||||
!C5 U+00C5 Aring
|
||||
!C6 U+0118 Eogonek
|
||||
!C7 U+0112 Emacron
|
||||
!C8 U+010C Ccaron
|
||||
!C9 U+00C9 Eacute
|
||||
!CA U+0179 Zacute
|
||||
!CB U+0116 Edotaccent
|
||||
!CC U+0122 Gcommaaccent
|
||||
!CD U+0136 Kcommaaccent
|
||||
!CE U+012A Imacron
|
||||
!CF U+013B Lcommaaccent
|
||||
!D0 U+0160 Scaron
|
||||
!D1 U+0143 Nacute
|
||||
!D2 U+0145 Ncommaaccent
|
||||
!D3 U+00D3 Oacute
|
||||
!D4 U+014C Omacron
|
||||
!D5 U+00D5 Otilde
|
||||
!D6 U+00D6 Odieresis
|
||||
!D7 U+00D7 multiply
|
||||
!D8 U+0172 Uogonek
|
||||
!D9 U+0141 Lslash
|
||||
!DA U+015A Sacute
|
||||
!DB U+016A Umacron
|
||||
!DC U+00DC Udieresis
|
||||
!DD U+017B Zdotaccent
|
||||
!DE U+017D Zcaron
|
||||
!DF U+00DF germandbls
|
||||
!E0 U+0105 aogonek
|
||||
!E1 U+012F iogonek
|
||||
!E2 U+0101 amacron
|
||||
!E3 U+0107 cacute
|
||||
!E4 U+00E4 adieresis
|
||||
!E5 U+00E5 aring
|
||||
!E6 U+0119 eogonek
|
||||
!E7 U+0113 emacron
|
||||
!E8 U+010D ccaron
|
||||
!E9 U+00E9 eacute
|
||||
!EA U+017A zacute
|
||||
!EB U+0117 edotaccent
|
||||
!EC U+0123 gcommaaccent
|
||||
!ED U+0137 kcommaaccent
|
||||
!EE U+012B imacron
|
||||
!EF U+013C lcommaaccent
|
||||
!F0 U+0161 scaron
|
||||
!F1 U+0144 nacute
|
||||
!F2 U+0146 ncommaaccent
|
||||
!F3 U+00F3 oacute
|
||||
!F4 U+014D omacron
|
||||
!F5 U+00F5 otilde
|
||||
!F6 U+00F6 odieresis
|
||||
!F7 U+00F7 divide
|
||||
!F8 U+0173 uogonek
|
||||
!F9 U+0142 lslash
|
||||
!FA U+015B sacute
|
||||
!FB U+016B umacron
|
||||
!FC U+00FC udieresis
|
||||
!FD U+017C zdotaccent
|
||||
!FE U+017E zcaron
|
||||
!FF U+02D9 dotaccent
|
@ -0,0 +1,247 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+20AC Euro
|
||||
!82 U+201A quotesinglbase
|
||||
!83 U+0192 florin
|
||||
!84 U+201E quotedblbase
|
||||
!85 U+2026 ellipsis
|
||||
!86 U+2020 dagger
|
||||
!87 U+2021 daggerdbl
|
||||
!88 U+02C6 circumflex
|
||||
!89 U+2030 perthousand
|
||||
!8B U+2039 guilsinglleft
|
||||
!8C U+0152 OE
|
||||
!91 U+2018 quoteleft
|
||||
!92 U+2019 quoteright
|
||||
!93 U+201C quotedblleft
|
||||
!94 U+201D quotedblright
|
||||
!95 U+2022 bullet
|
||||
!96 U+2013 endash
|
||||
!97 U+2014 emdash
|
||||
!98 U+02DC tilde
|
||||
!99 U+2122 trademark
|
||||
!9B U+203A guilsinglright
|
||||
!9C U+0153 oe
|
||||
!9F U+0178 Ydieresis
|
||||
!A0 U+00A0 space
|
||||
!A1 U+00A1 exclamdown
|
||||
!A2 U+00A2 cent
|
||||
!A3 U+00A3 sterling
|
||||
!A4 U+00A4 currency
|
||||
!A5 U+00A5 yen
|
||||
!A6 U+00A6 brokenbar
|
||||
!A7 U+00A7 section
|
||||
!A8 U+00A8 dieresis
|
||||
!A9 U+00A9 copyright
|
||||
!AA U+00AA ordfeminine
|
||||
!AB U+00AB guillemotleft
|
||||
!AC U+00AC logicalnot
|
||||
!AD U+00AD hyphen
|
||||
!AE U+00AE registered
|
||||
!AF U+00AF macron
|
||||
!B0 U+00B0 degree
|
||||
!B1 U+00B1 plusminus
|
||||
!B2 U+00B2 twosuperior
|
||||
!B3 U+00B3 threesuperior
|
||||
!B4 U+00B4 acute
|
||||
!B5 U+00B5 mu
|
||||
!B6 U+00B6 paragraph
|
||||
!B7 U+00B7 periodcentered
|
||||
!B8 U+00B8 cedilla
|
||||
!B9 U+00B9 onesuperior
|
||||
!BA U+00BA ordmasculine
|
||||
!BB U+00BB guillemotright
|
||||
!BC U+00BC onequarter
|
||||
!BD U+00BD onehalf
|
||||
!BE U+00BE threequarters
|
||||
!BF U+00BF questiondown
|
||||
!C0 U+00C0 Agrave
|
||||
!C1 U+00C1 Aacute
|
||||
!C2 U+00C2 Acircumflex
|
||||
!C3 U+0102 Abreve
|
||||
!C4 U+00C4 Adieresis
|
||||
!C5 U+00C5 Aring
|
||||
!C6 U+00C6 AE
|
||||
!C7 U+00C7 Ccedilla
|
||||
!C8 U+00C8 Egrave
|
||||
!C9 U+00C9 Eacute
|
||||
!CA U+00CA Ecircumflex
|
||||
!CB U+00CB Edieresis
|
||||
!CC U+0300 gravecomb
|
||||
!CD U+00CD Iacute
|
||||
!CE U+00CE Icircumflex
|
||||
!CF U+00CF Idieresis
|
||||
!D0 U+0110 Dcroat
|
||||
!D1 U+00D1 Ntilde
|
||||
!D2 U+0309 hookabovecomb
|
||||
!D3 U+00D3 Oacute
|
||||
!D4 U+00D4 Ocircumflex
|
||||
!D5 U+01A0 Ohorn
|
||||
!D6 U+00D6 Odieresis
|
||||
!D7 U+00D7 multiply
|
||||
!D8 U+00D8 Oslash
|
||||
!D9 U+00D9 Ugrave
|
||||
!DA U+00DA Uacute
|
||||
!DB U+00DB Ucircumflex
|
||||
!DC U+00DC Udieresis
|
||||
!DD U+01AF Uhorn
|
||||
!DE U+0303 tildecomb
|
||||
!DF U+00DF germandbls
|
||||
!E0 U+00E0 agrave
|
||||
!E1 U+00E1 aacute
|
||||
!E2 U+00E2 acircumflex
|
||||
!E3 U+0103 abreve
|
||||
!E4 U+00E4 adieresis
|
||||
!E5 U+00E5 aring
|
||||
!E6 U+00E6 ae
|
||||
!E7 U+00E7 ccedilla
|
||||
!E8 U+00E8 egrave
|
||||
!E9 U+00E9 eacute
|
||||
!EA U+00EA ecircumflex
|
||||
!EB U+00EB edieresis
|
||||
!EC U+0301 acutecomb
|
||||
!ED U+00ED iacute
|
||||
!EE U+00EE icircumflex
|
||||
!EF U+00EF idieresis
|
||||
!F0 U+0111 dcroat
|
||||
!F1 U+00F1 ntilde
|
||||
!F2 U+0323 dotbelowcomb
|
||||
!F3 U+00F3 oacute
|
||||
!F4 U+00F4 ocircumflex
|
||||
!F5 U+01A1 ohorn
|
||||
!F6 U+00F6 odieresis
|
||||
!F7 U+00F7 divide
|
||||
!F8 U+00F8 oslash
|
||||
!F9 U+00F9 ugrave
|
||||
!FA U+00FA uacute
|
||||
!FB U+00FB ucircumflex
|
||||
!FC U+00FC udieresis
|
||||
!FD U+01B0 uhorn
|
||||
!FE U+20AB dong
|
||||
!FF U+00FF ydieresis
|
@ -0,0 +1,225 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+20AC Euro
|
||||
!85 U+2026 ellipsis
|
||||
!91 U+2018 quoteleft
|
||||
!92 U+2019 quoteright
|
||||
!93 U+201C quotedblleft
|
||||
!94 U+201D quotedblright
|
||||
!95 U+2022 bullet
|
||||
!96 U+2013 endash
|
||||
!97 U+2014 emdash
|
||||
!A0 U+00A0 space
|
||||
!A1 U+0E01 kokaithai
|
||||
!A2 U+0E02 khokhaithai
|
||||
!A3 U+0E03 khokhuatthai
|
||||
!A4 U+0E04 khokhwaithai
|
||||
!A5 U+0E05 khokhonthai
|
||||
!A6 U+0E06 khorakhangthai
|
||||
!A7 U+0E07 ngonguthai
|
||||
!A8 U+0E08 chochanthai
|
||||
!A9 U+0E09 chochingthai
|
||||
!AA U+0E0A chochangthai
|
||||
!AB U+0E0B sosothai
|
||||
!AC U+0E0C chochoethai
|
||||
!AD U+0E0D yoyingthai
|
||||
!AE U+0E0E dochadathai
|
||||
!AF U+0E0F topatakthai
|
||||
!B0 U+0E10 thothanthai
|
||||
!B1 U+0E11 thonangmonthothai
|
||||
!B2 U+0E12 thophuthaothai
|
||||
!B3 U+0E13 nonenthai
|
||||
!B4 U+0E14 dodekthai
|
||||
!B5 U+0E15 totaothai
|
||||
!B6 U+0E16 thothungthai
|
||||
!B7 U+0E17 thothahanthai
|
||||
!B8 U+0E18 thothongthai
|
||||
!B9 U+0E19 nonuthai
|
||||
!BA U+0E1A bobaimaithai
|
||||
!BB U+0E1B poplathai
|
||||
!BC U+0E1C phophungthai
|
||||
!BD U+0E1D fofathai
|
||||
!BE U+0E1E phophanthai
|
||||
!BF U+0E1F fofanthai
|
||||
!C0 U+0E20 phosamphaothai
|
||||
!C1 U+0E21 momathai
|
||||
!C2 U+0E22 yoyakthai
|
||||
!C3 U+0E23 roruathai
|
||||
!C4 U+0E24 ruthai
|
||||
!C5 U+0E25 lolingthai
|
||||
!C6 U+0E26 luthai
|
||||
!C7 U+0E27 wowaenthai
|
||||
!C8 U+0E28 sosalathai
|
||||
!C9 U+0E29 sorusithai
|
||||
!CA U+0E2A sosuathai
|
||||
!CB U+0E2B hohipthai
|
||||
!CC U+0E2C lochulathai
|
||||
!CD U+0E2D oangthai
|
||||
!CE U+0E2E honokhukthai
|
||||
!CF U+0E2F paiyannoithai
|
||||
!D0 U+0E30 saraathai
|
||||
!D1 U+0E31 maihanakatthai
|
||||
!D2 U+0E32 saraaathai
|
||||
!D3 U+0E33 saraamthai
|
||||
!D4 U+0E34 saraithai
|
||||
!D5 U+0E35 saraiithai
|
||||
!D6 U+0E36 sarauethai
|
||||
!D7 U+0E37 saraueethai
|
||||
!D8 U+0E38 sarauthai
|
||||
!D9 U+0E39 sarauuthai
|
||||
!DA U+0E3A phinthuthai
|
||||
!DF U+0E3F bahtthai
|
||||
!E0 U+0E40 saraethai
|
||||
!E1 U+0E41 saraaethai
|
||||
!E2 U+0E42 saraothai
|
||||
!E3 U+0E43 saraaimaimuanthai
|
||||
!E4 U+0E44 saraaimaimalaithai
|
||||
!E5 U+0E45 lakkhangyaothai
|
||||
!E6 U+0E46 maiyamokthai
|
||||
!E7 U+0E47 maitaikhuthai
|
||||
!E8 U+0E48 maiekthai
|
||||
!E9 U+0E49 maithothai
|
||||
!EA U+0E4A maitrithai
|
||||
!EB U+0E4B maichattawathai
|
||||
!EC U+0E4C thanthakhatthai
|
||||
!ED U+0E4D nikhahitthai
|
||||
!EE U+0E4E yamakkanthai
|
||||
!EF U+0E4F fongmanthai
|
||||
!F0 U+0E50 zerothai
|
||||
!F1 U+0E51 onethai
|
||||
!F2 U+0E52 twothai
|
||||
!F3 U+0E53 threethai
|
||||
!F4 U+0E54 fourthai
|
||||
!F5 U+0E55 fivethai
|
||||
!F6 U+0E56 sixthai
|
||||
!F7 U+0E57 seventhai
|
||||
!F8 U+0E58 eightthai
|
||||
!F9 U+0E59 ninethai
|
||||
!FA U+0E5A angkhankhuthai
|
||||
!FB U+0E5B khomutthai
|
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../');
|
||||
exit;
|
@ -0,0 +1,256 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+0080 .notdef
|
||||
!81 U+0081 .notdef
|
||||
!82 U+0082 .notdef
|
||||
!83 U+0083 .notdef
|
||||
!84 U+0084 .notdef
|
||||
!85 U+0085 .notdef
|
||||
!86 U+0086 .notdef
|
||||
!87 U+0087 .notdef
|
||||
!88 U+0088 .notdef
|
||||
!89 U+0089 .notdef
|
||||
!8A U+008A .notdef
|
||||
!8B U+008B .notdef
|
||||
!8C U+008C .notdef
|
||||
!8D U+008D .notdef
|
||||
!8E U+008E .notdef
|
||||
!8F U+008F .notdef
|
||||
!90 U+0090 .notdef
|
||||
!91 U+0091 .notdef
|
||||
!92 U+0092 .notdef
|
||||
!93 U+0093 .notdef
|
||||
!94 U+0094 .notdef
|
||||
!95 U+0095 .notdef
|
||||
!96 U+0096 .notdef
|
||||
!97 U+0097 .notdef
|
||||
!98 U+0098 .notdef
|
||||
!99 U+0099 .notdef
|
||||
!9A U+009A .notdef
|
||||
!9B U+009B .notdef
|
||||
!9C U+009C .notdef
|
||||
!9D U+009D .notdef
|
||||
!9E U+009E .notdef
|
||||
!9F U+009F .notdef
|
||||
!A0 U+00A0 space
|
||||
!A1 U+00A1 exclamdown
|
||||
!A2 U+00A2 cent
|
||||
!A3 U+00A3 sterling
|
||||
!A4 U+00A4 currency
|
||||
!A5 U+00A5 yen
|
||||
!A6 U+00A6 brokenbar
|
||||
!A7 U+00A7 section
|
||||
!A8 U+00A8 dieresis
|
||||
!A9 U+00A9 copyright
|
||||
!AA U+00AA ordfeminine
|
||||
!AB U+00AB guillemotleft
|
||||
!AC U+00AC logicalnot
|
||||
!AD U+00AD hyphen
|
||||
!AE U+00AE registered
|
||||
!AF U+00AF macron
|
||||
!B0 U+00B0 degree
|
||||
!B1 U+00B1 plusminus
|
||||
!B2 U+00B2 twosuperior
|
||||
!B3 U+00B3 threesuperior
|
||||
!B4 U+00B4 acute
|
||||
!B5 U+00B5 mu
|
||||
!B6 U+00B6 paragraph
|
||||
!B7 U+00B7 periodcentered
|
||||
!B8 U+00B8 cedilla
|
||||
!B9 U+00B9 onesuperior
|
||||
!BA U+00BA ordmasculine
|
||||
!BB U+00BB guillemotright
|
||||
!BC U+00BC onequarter
|
||||
!BD U+00BD onehalf
|
||||
!BE U+00BE threequarters
|
||||
!BF U+00BF questiondown
|
||||
!C0 U+00C0 Agrave
|
||||
!C1 U+00C1 Aacute
|
||||
!C2 U+00C2 Acircumflex
|
||||
!C3 U+00C3 Atilde
|
||||
!C4 U+00C4 Adieresis
|
||||
!C5 U+00C5 Aring
|
||||
!C6 U+00C6 AE
|
||||
!C7 U+00C7 Ccedilla
|
||||
!C8 U+00C8 Egrave
|
||||
!C9 U+00C9 Eacute
|
||||
!CA U+00CA Ecircumflex
|
||||
!CB U+00CB Edieresis
|
||||
!CC U+00CC Igrave
|
||||
!CD U+00CD Iacute
|
||||
!CE U+00CE Icircumflex
|
||||
!CF U+00CF Idieresis
|
||||
!D0 U+00D0 Eth
|
||||
!D1 U+00D1 Ntilde
|
||||
!D2 U+00D2 Ograve
|
||||
!D3 U+00D3 Oacute
|
||||
!D4 U+00D4 Ocircumflex
|
||||
!D5 U+00D5 Otilde
|
||||
!D6 U+00D6 Odieresis
|
||||
!D7 U+00D7 multiply
|
||||
!D8 U+00D8 Oslash
|
||||
!D9 U+00D9 Ugrave
|
||||
!DA U+00DA Uacute
|
||||
!DB U+00DB Ucircumflex
|
||||
!DC U+00DC Udieresis
|
||||
!DD U+00DD Yacute
|
||||
!DE U+00DE Thorn
|
||||
!DF U+00DF germandbls
|
||||
!E0 U+00E0 agrave
|
||||
!E1 U+00E1 aacute
|
||||
!E2 U+00E2 acircumflex
|
||||
!E3 U+00E3 atilde
|
||||
!E4 U+00E4 adieresis
|
||||
!E5 U+00E5 aring
|
||||
!E6 U+00E6 ae
|
||||
!E7 U+00E7 ccedilla
|
||||
!E8 U+00E8 egrave
|
||||
!E9 U+00E9 eacute
|
||||
!EA U+00EA ecircumflex
|
||||
!EB U+00EB edieresis
|
||||
!EC U+00EC igrave
|
||||
!ED U+00ED iacute
|
||||
!EE U+00EE icircumflex
|
||||
!EF U+00EF idieresis
|
||||
!F0 U+00F0 eth
|
||||
!F1 U+00F1 ntilde
|
||||
!F2 U+00F2 ograve
|
||||
!F3 U+00F3 oacute
|
||||
!F4 U+00F4 ocircumflex
|
||||
!F5 U+00F5 otilde
|
||||
!F6 U+00F6 odieresis
|
||||
!F7 U+00F7 divide
|
||||
!F8 U+00F8 oslash
|
||||
!F9 U+00F9 ugrave
|
||||
!FA U+00FA uacute
|
||||
!FB U+00FB ucircumflex
|
||||
!FC U+00FC udieresis
|
||||
!FD U+00FD yacute
|
||||
!FE U+00FE thorn
|
||||
!FF U+00FF ydieresis
|
@ -0,0 +1,248 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+0080 .notdef
|
||||
!81 U+0081 .notdef
|
||||
!82 U+0082 .notdef
|
||||
!83 U+0083 .notdef
|
||||
!84 U+0084 .notdef
|
||||
!85 U+0085 .notdef
|
||||
!86 U+0086 .notdef
|
||||
!87 U+0087 .notdef
|
||||
!88 U+0088 .notdef
|
||||
!89 U+0089 .notdef
|
||||
!8A U+008A .notdef
|
||||
!8B U+008B .notdef
|
||||
!8C U+008C .notdef
|
||||
!8D U+008D .notdef
|
||||
!8E U+008E .notdef
|
||||
!8F U+008F .notdef
|
||||
!90 U+0090 .notdef
|
||||
!91 U+0091 .notdef
|
||||
!92 U+0092 .notdef
|
||||
!93 U+0093 .notdef
|
||||
!94 U+0094 .notdef
|
||||
!95 U+0095 .notdef
|
||||
!96 U+0096 .notdef
|
||||
!97 U+0097 .notdef
|
||||
!98 U+0098 .notdef
|
||||
!99 U+0099 .notdef
|
||||
!9A U+009A .notdef
|
||||
!9B U+009B .notdef
|
||||
!9C U+009C .notdef
|
||||
!9D U+009D .notdef
|
||||
!9E U+009E .notdef
|
||||
!9F U+009F .notdef
|
||||
!A0 U+00A0 space
|
||||
!A1 U+0E01 kokaithai
|
||||
!A2 U+0E02 khokhaithai
|
||||
!A3 U+0E03 khokhuatthai
|
||||
!A4 U+0E04 khokhwaithai
|
||||
!A5 U+0E05 khokhonthai
|
||||
!A6 U+0E06 khorakhangthai
|
||||
!A7 U+0E07 ngonguthai
|
||||
!A8 U+0E08 chochanthai
|
||||
!A9 U+0E09 chochingthai
|
||||
!AA U+0E0A chochangthai
|
||||
!AB U+0E0B sosothai
|
||||
!AC U+0E0C chochoethai
|
||||
!AD U+0E0D yoyingthai
|
||||
!AE U+0E0E dochadathai
|
||||
!AF U+0E0F topatakthai
|
||||
!B0 U+0E10 thothanthai
|
||||
!B1 U+0E11 thonangmonthothai
|
||||
!B2 U+0E12 thophuthaothai
|
||||
!B3 U+0E13 nonenthai
|
||||
!B4 U+0E14 dodekthai
|
||||
!B5 U+0E15 totaothai
|
||||
!B6 U+0E16 thothungthai
|
||||
!B7 U+0E17 thothahanthai
|
||||
!B8 U+0E18 thothongthai
|
||||
!B9 U+0E19 nonuthai
|
||||
!BA U+0E1A bobaimaithai
|
||||
!BB U+0E1B poplathai
|
||||
!BC U+0E1C phophungthai
|
||||
!BD U+0E1D fofathai
|
||||
!BE U+0E1E phophanthai
|
||||
!BF U+0E1F fofanthai
|
||||
!C0 U+0E20 phosamphaothai
|
||||
!C1 U+0E21 momathai
|
||||
!C2 U+0E22 yoyakthai
|
||||
!C3 U+0E23 roruathai
|
||||
!C4 U+0E24 ruthai
|
||||
!C5 U+0E25 lolingthai
|
||||
!C6 U+0E26 luthai
|
||||
!C7 U+0E27 wowaenthai
|
||||
!C8 U+0E28 sosalathai
|
||||
!C9 U+0E29 sorusithai
|
||||
!CA U+0E2A sosuathai
|
||||
!CB U+0E2B hohipthai
|
||||
!CC U+0E2C lochulathai
|
||||
!CD U+0E2D oangthai
|
||||
!CE U+0E2E honokhukthai
|
||||
!CF U+0E2F paiyannoithai
|
||||
!D0 U+0E30 saraathai
|
||||
!D1 U+0E31 maihanakatthai
|
||||
!D2 U+0E32 saraaathai
|
||||
!D3 U+0E33 saraamthai
|
||||
!D4 U+0E34 saraithai
|
||||
!D5 U+0E35 saraiithai
|
||||
!D6 U+0E36 sarauethai
|
||||
!D7 U+0E37 saraueethai
|
||||
!D8 U+0E38 sarauthai
|
||||
!D9 U+0E39 sarauuthai
|
||||
!DA U+0E3A phinthuthai
|
||||
!DF U+0E3F bahtthai
|
||||
!E0 U+0E40 saraethai
|
||||
!E1 U+0E41 saraaethai
|
||||
!E2 U+0E42 saraothai
|
||||
!E3 U+0E43 saraaimaimuanthai
|
||||
!E4 U+0E44 saraaimaimalaithai
|
||||
!E5 U+0E45 lakkhangyaothai
|
||||
!E6 U+0E46 maiyamokthai
|
||||
!E7 U+0E47 maitaikhuthai
|
||||
!E8 U+0E48 maiekthai
|
||||
!E9 U+0E49 maithothai
|
||||
!EA U+0E4A maitrithai
|
||||
!EB U+0E4B maichattawathai
|
||||
!EC U+0E4C thanthakhatthai
|
||||
!ED U+0E4D nikhahitthai
|
||||
!EE U+0E4E yamakkanthai
|
||||
!EF U+0E4F fongmanthai
|
||||
!F0 U+0E50 zerothai
|
||||
!F1 U+0E51 onethai
|
||||
!F2 U+0E52 twothai
|
||||
!F3 U+0E53 threethai
|
||||
!F4 U+0E54 fourthai
|
||||
!F5 U+0E55 fivethai
|
||||
!F6 U+0E56 sixthai
|
||||
!F7 U+0E57 seventhai
|
||||
!F8 U+0E58 eightthai
|
||||
!F9 U+0E59 ninethai
|
||||
!FA U+0E5A angkhankhuthai
|
||||
!FB U+0E5B khomutthai
|
@ -0,0 +1,256 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+0080 .notdef
|
||||
!81 U+0081 .notdef
|
||||
!82 U+0082 .notdef
|
||||
!83 U+0083 .notdef
|
||||
!84 U+0084 .notdef
|
||||
!85 U+0085 .notdef
|
||||
!86 U+0086 .notdef
|
||||
!87 U+0087 .notdef
|
||||
!88 U+0088 .notdef
|
||||
!89 U+0089 .notdef
|
||||
!8A U+008A .notdef
|
||||
!8B U+008B .notdef
|
||||
!8C U+008C .notdef
|
||||
!8D U+008D .notdef
|
||||
!8E U+008E .notdef
|
||||
!8F U+008F .notdef
|
||||
!90 U+0090 .notdef
|
||||
!91 U+0091 .notdef
|
||||
!92 U+0092 .notdef
|
||||
!93 U+0093 .notdef
|
||||
!94 U+0094 .notdef
|
||||
!95 U+0095 .notdef
|
||||
!96 U+0096 .notdef
|
||||
!97 U+0097 .notdef
|
||||
!98 U+0098 .notdef
|
||||
!99 U+0099 .notdef
|
||||
!9A U+009A .notdef
|
||||
!9B U+009B .notdef
|
||||
!9C U+009C .notdef
|
||||
!9D U+009D .notdef
|
||||
!9E U+009E .notdef
|
||||
!9F U+009F .notdef
|
||||
!A0 U+00A0 space
|
||||
!A1 U+00A1 exclamdown
|
||||
!A2 U+00A2 cent
|
||||
!A3 U+00A3 sterling
|
||||
!A4 U+20AC Euro
|
||||
!A5 U+00A5 yen
|
||||
!A6 U+0160 Scaron
|
||||
!A7 U+00A7 section
|
||||
!A8 U+0161 scaron
|
||||
!A9 U+00A9 copyright
|
||||
!AA U+00AA ordfeminine
|
||||
!AB U+00AB guillemotleft
|
||||
!AC U+00AC logicalnot
|
||||
!AD U+00AD hyphen
|
||||
!AE U+00AE registered
|
||||
!AF U+00AF macron
|
||||
!B0 U+00B0 degree
|
||||
!B1 U+00B1 plusminus
|
||||
!B2 U+00B2 twosuperior
|
||||
!B3 U+00B3 threesuperior
|
||||
!B4 U+017D Zcaron
|
||||
!B5 U+00B5 mu
|
||||
!B6 U+00B6 paragraph
|
||||
!B7 U+00B7 periodcentered
|
||||
!B8 U+017E zcaron
|
||||
!B9 U+00B9 onesuperior
|
||||
!BA U+00BA ordmasculine
|
||||
!BB U+00BB guillemotright
|
||||
!BC U+0152 OE
|
||||
!BD U+0153 oe
|
||||
!BE U+0178 Ydieresis
|
||||
!BF U+00BF questiondown
|
||||
!C0 U+00C0 Agrave
|
||||
!C1 U+00C1 Aacute
|
||||
!C2 U+00C2 Acircumflex
|
||||
!C3 U+00C3 Atilde
|
||||
!C4 U+00C4 Adieresis
|
||||
!C5 U+00C5 Aring
|
||||
!C6 U+00C6 AE
|
||||
!C7 U+00C7 Ccedilla
|
||||
!C8 U+00C8 Egrave
|
||||
!C9 U+00C9 Eacute
|
||||
!CA U+00CA Ecircumflex
|
||||
!CB U+00CB Edieresis
|
||||
!CC U+00CC Igrave
|
||||
!CD U+00CD Iacute
|
||||
!CE U+00CE Icircumflex
|
||||
!CF U+00CF Idieresis
|
||||
!D0 U+00D0 Eth
|
||||
!D1 U+00D1 Ntilde
|
||||
!D2 U+00D2 Ograve
|
||||
!D3 U+00D3 Oacute
|
||||
!D4 U+00D4 Ocircumflex
|
||||
!D5 U+00D5 Otilde
|
||||
!D6 U+00D6 Odieresis
|
||||
!D7 U+00D7 multiply
|
||||
!D8 U+00D8 Oslash
|
||||
!D9 U+00D9 Ugrave
|
||||
!DA U+00DA Uacute
|
||||
!DB U+00DB Ucircumflex
|
||||
!DC U+00DC Udieresis
|
||||
!DD U+00DD Yacute
|
||||
!DE U+00DE Thorn
|
||||
!DF U+00DF germandbls
|
||||
!E0 U+00E0 agrave
|
||||
!E1 U+00E1 aacute
|
||||
!E2 U+00E2 acircumflex
|
||||
!E3 U+00E3 atilde
|
||||
!E4 U+00E4 adieresis
|
||||
!E5 U+00E5 aring
|
||||
!E6 U+00E6 ae
|
||||
!E7 U+00E7 ccedilla
|
||||
!E8 U+00E8 egrave
|
||||
!E9 U+00E9 eacute
|
||||
!EA U+00EA ecircumflex
|
||||
!EB U+00EB edieresis
|
||||
!EC U+00EC igrave
|
||||
!ED U+00ED iacute
|
||||
!EE U+00EE icircumflex
|
||||
!EF U+00EF idieresis
|
||||
!F0 U+00F0 eth
|
||||
!F1 U+00F1 ntilde
|
||||
!F2 U+00F2 ograve
|
||||
!F3 U+00F3 oacute
|
||||
!F4 U+00F4 ocircumflex
|
||||
!F5 U+00F5 otilde
|
||||
!F6 U+00F6 odieresis
|
||||
!F7 U+00F7 divide
|
||||
!F8 U+00F8 oslash
|
||||
!F9 U+00F9 ugrave
|
||||
!FA U+00FA uacute
|
||||
!FB U+00FB ucircumflex
|
||||
!FC U+00FC udieresis
|
||||
!FD U+00FD yacute
|
||||
!FE U+00FE thorn
|
||||
!FF U+00FF ydieresis
|
@ -0,0 +1,256 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+0080 .notdef
|
||||
!81 U+0081 .notdef
|
||||
!82 U+0082 .notdef
|
||||
!83 U+0083 .notdef
|
||||
!84 U+0084 .notdef
|
||||
!85 U+0085 .notdef
|
||||
!86 U+0086 .notdef
|
||||
!87 U+0087 .notdef
|
||||
!88 U+0088 .notdef
|
||||
!89 U+0089 .notdef
|
||||
!8A U+008A .notdef
|
||||
!8B U+008B .notdef
|
||||
!8C U+008C .notdef
|
||||
!8D U+008D .notdef
|
||||
!8E U+008E .notdef
|
||||
!8F U+008F .notdef
|
||||
!90 U+0090 .notdef
|
||||
!91 U+0091 .notdef
|
||||
!92 U+0092 .notdef
|
||||
!93 U+0093 .notdef
|
||||
!94 U+0094 .notdef
|
||||
!95 U+0095 .notdef
|
||||
!96 U+0096 .notdef
|
||||
!97 U+0097 .notdef
|
||||
!98 U+0098 .notdef
|
||||
!99 U+0099 .notdef
|
||||
!9A U+009A .notdef
|
||||
!9B U+009B .notdef
|
||||
!9C U+009C .notdef
|
||||
!9D U+009D .notdef
|
||||
!9E U+009E .notdef
|
||||
!9F U+009F .notdef
|
||||
!A0 U+00A0 space
|
||||
!A1 U+0104 Aogonek
|
||||
!A2 U+0105 aogonek
|
||||
!A3 U+0141 Lslash
|
||||
!A4 U+20AC Euro
|
||||
!A5 U+201E quotedblbase
|
||||
!A6 U+0160 Scaron
|
||||
!A7 U+00A7 section
|
||||
!A8 U+0161 scaron
|
||||
!A9 U+00A9 copyright
|
||||
!AA U+0218 Scommaaccent
|
||||
!AB U+00AB guillemotleft
|
||||
!AC U+0179 Zacute
|
||||
!AD U+00AD hyphen
|
||||
!AE U+017A zacute
|
||||
!AF U+017B Zdotaccent
|
||||
!B0 U+00B0 degree
|
||||
!B1 U+00B1 plusminus
|
||||
!B2 U+010C Ccaron
|
||||
!B3 U+0142 lslash
|
||||
!B4 U+017D Zcaron
|
||||
!B5 U+201D quotedblright
|
||||
!B6 U+00B6 paragraph
|
||||
!B7 U+00B7 periodcentered
|
||||
!B8 U+017E zcaron
|
||||
!B9 U+010D ccaron
|
||||
!BA U+0219 scommaaccent
|
||||
!BB U+00BB guillemotright
|
||||
!BC U+0152 OE
|
||||
!BD U+0153 oe
|
||||
!BE U+0178 Ydieresis
|
||||
!BF U+017C zdotaccent
|
||||
!C0 U+00C0 Agrave
|
||||
!C1 U+00C1 Aacute
|
||||
!C2 U+00C2 Acircumflex
|
||||
!C3 U+0102 Abreve
|
||||
!C4 U+00C4 Adieresis
|
||||
!C5 U+0106 Cacute
|
||||
!C6 U+00C6 AE
|
||||
!C7 U+00C7 Ccedilla
|
||||
!C8 U+00C8 Egrave
|
||||
!C9 U+00C9 Eacute
|
||||
!CA U+00CA Ecircumflex
|
||||
!CB U+00CB Edieresis
|
||||
!CC U+00CC Igrave
|
||||
!CD U+00CD Iacute
|
||||
!CE U+00CE Icircumflex
|
||||
!CF U+00CF Idieresis
|
||||
!D0 U+0110 Dcroat
|
||||
!D1 U+0143 Nacute
|
||||
!D2 U+00D2 Ograve
|
||||
!D3 U+00D3 Oacute
|
||||
!D4 U+00D4 Ocircumflex
|
||||
!D5 U+0150 Ohungarumlaut
|
||||
!D6 U+00D6 Odieresis
|
||||
!D7 U+015A Sacute
|
||||
!D8 U+0170 Uhungarumlaut
|
||||
!D9 U+00D9 Ugrave
|
||||
!DA U+00DA Uacute
|
||||
!DB U+00DB Ucircumflex
|
||||
!DC U+00DC Udieresis
|
||||
!DD U+0118 Eogonek
|
||||
!DE U+021A Tcommaaccent
|
||||
!DF U+00DF germandbls
|
||||
!E0 U+00E0 agrave
|
||||
!E1 U+00E1 aacute
|
||||
!E2 U+00E2 acircumflex
|
||||
!E3 U+0103 abreve
|
||||
!E4 U+00E4 adieresis
|
||||
!E5 U+0107 cacute
|
||||
!E6 U+00E6 ae
|
||||
!E7 U+00E7 ccedilla
|
||||
!E8 U+00E8 egrave
|
||||
!E9 U+00E9 eacute
|
||||
!EA U+00EA ecircumflex
|
||||
!EB U+00EB edieresis
|
||||
!EC U+00EC igrave
|
||||
!ED U+00ED iacute
|
||||
!EE U+00EE icircumflex
|
||||
!EF U+00EF idieresis
|
||||
!F0 U+0111 dcroat
|
||||
!F1 U+0144 nacute
|
||||
!F2 U+00F2 ograve
|
||||
!F3 U+00F3 oacute
|
||||
!F4 U+00F4 ocircumflex
|
||||
!F5 U+0151 ohungarumlaut
|
||||
!F6 U+00F6 odieresis
|
||||
!F7 U+015B sacute
|
||||
!F8 U+0171 uhungarumlaut
|
||||
!F9 U+00F9 ugrave
|
||||
!FA U+00FA uacute
|
||||
!FB U+00FB ucircumflex
|
||||
!FC U+00FC udieresis
|
||||
!FD U+0119 eogonek
|
||||
!FE U+021B tcommaaccent
|
||||
!FF U+00FF ydieresis
|
@ -0,0 +1,256 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+0080 .notdef
|
||||
!81 U+0081 .notdef
|
||||
!82 U+0082 .notdef
|
||||
!83 U+0083 .notdef
|
||||
!84 U+0084 .notdef
|
||||
!85 U+0085 .notdef
|
||||
!86 U+0086 .notdef
|
||||
!87 U+0087 .notdef
|
||||
!88 U+0088 .notdef
|
||||
!89 U+0089 .notdef
|
||||
!8A U+008A .notdef
|
||||
!8B U+008B .notdef
|
||||
!8C U+008C .notdef
|
||||
!8D U+008D .notdef
|
||||
!8E U+008E .notdef
|
||||
!8F U+008F .notdef
|
||||
!90 U+0090 .notdef
|
||||
!91 U+0091 .notdef
|
||||
!92 U+0092 .notdef
|
||||
!93 U+0093 .notdef
|
||||
!94 U+0094 .notdef
|
||||
!95 U+0095 .notdef
|
||||
!96 U+0096 .notdef
|
||||
!97 U+0097 .notdef
|
||||
!98 U+0098 .notdef
|
||||
!99 U+0099 .notdef
|
||||
!9A U+009A .notdef
|
||||
!9B U+009B .notdef
|
||||
!9C U+009C .notdef
|
||||
!9D U+009D .notdef
|
||||
!9E U+009E .notdef
|
||||
!9F U+009F .notdef
|
||||
!A0 U+00A0 space
|
||||
!A1 U+0104 Aogonek
|
||||
!A2 U+02D8 breve
|
||||
!A3 U+0141 Lslash
|
||||
!A4 U+00A4 currency
|
||||
!A5 U+013D Lcaron
|
||||
!A6 U+015A Sacute
|
||||
!A7 U+00A7 section
|
||||
!A8 U+00A8 dieresis
|
||||
!A9 U+0160 Scaron
|
||||
!AA U+015E Scedilla
|
||||
!AB U+0164 Tcaron
|
||||
!AC U+0179 Zacute
|
||||
!AD U+00AD hyphen
|
||||
!AE U+017D Zcaron
|
||||
!AF U+017B Zdotaccent
|
||||
!B0 U+00B0 degree
|
||||
!B1 U+0105 aogonek
|
||||
!B2 U+02DB ogonek
|
||||
!B3 U+0142 lslash
|
||||
!B4 U+00B4 acute
|
||||
!B5 U+013E lcaron
|
||||
!B6 U+015B sacute
|
||||
!B7 U+02C7 caron
|
||||
!B8 U+00B8 cedilla
|
||||
!B9 U+0161 scaron
|
||||
!BA U+015F scedilla
|
||||
!BB U+0165 tcaron
|
||||
!BC U+017A zacute
|
||||
!BD U+02DD hungarumlaut
|
||||
!BE U+017E zcaron
|
||||
!BF U+017C zdotaccent
|
||||
!C0 U+0154 Racute
|
||||
!C1 U+00C1 Aacute
|
||||
!C2 U+00C2 Acircumflex
|
||||
!C3 U+0102 Abreve
|
||||
!C4 U+00C4 Adieresis
|
||||
!C5 U+0139 Lacute
|
||||
!C6 U+0106 Cacute
|
||||
!C7 U+00C7 Ccedilla
|
||||
!C8 U+010C Ccaron
|
||||
!C9 U+00C9 Eacute
|
||||
!CA U+0118 Eogonek
|
||||
!CB U+00CB Edieresis
|
||||
!CC U+011A Ecaron
|
||||
!CD U+00CD Iacute
|
||||
!CE U+00CE Icircumflex
|
||||
!CF U+010E Dcaron
|
||||
!D0 U+0110 Dcroat
|
||||
!D1 U+0143 Nacute
|
||||
!D2 U+0147 Ncaron
|
||||
!D3 U+00D3 Oacute
|
||||
!D4 U+00D4 Ocircumflex
|
||||
!D5 U+0150 Ohungarumlaut
|
||||
!D6 U+00D6 Odieresis
|
||||
!D7 U+00D7 multiply
|
||||
!D8 U+0158 Rcaron
|
||||
!D9 U+016E Uring
|
||||
!DA U+00DA Uacute
|
||||
!DB U+0170 Uhungarumlaut
|
||||
!DC U+00DC Udieresis
|
||||
!DD U+00DD Yacute
|
||||
!DE U+0162 Tcommaaccent
|
||||
!DF U+00DF germandbls
|
||||
!E0 U+0155 racute
|
||||
!E1 U+00E1 aacute
|
||||
!E2 U+00E2 acircumflex
|
||||
!E3 U+0103 abreve
|
||||
!E4 U+00E4 adieresis
|
||||
!E5 U+013A lacute
|
||||
!E6 U+0107 cacute
|
||||
!E7 U+00E7 ccedilla
|
||||
!E8 U+010D ccaron
|
||||
!E9 U+00E9 eacute
|
||||
!EA U+0119 eogonek
|
||||
!EB U+00EB edieresis
|
||||
!EC U+011B ecaron
|
||||
!ED U+00ED iacute
|
||||
!EE U+00EE icircumflex
|
||||
!EF U+010F dcaron
|
||||
!F0 U+0111 dcroat
|
||||
!F1 U+0144 nacute
|
||||
!F2 U+0148 ncaron
|
||||
!F3 U+00F3 oacute
|
||||
!F4 U+00F4 ocircumflex
|
||||
!F5 U+0151 ohungarumlaut
|
||||
!F6 U+00F6 odieresis
|
||||
!F7 U+00F7 divide
|
||||
!F8 U+0159 rcaron
|
||||
!F9 U+016F uring
|
||||
!FA U+00FA uacute
|
||||
!FB U+0171 uhungarumlaut
|
||||
!FC U+00FC udieresis
|
||||
!FD U+00FD yacute
|
||||
!FE U+0163 tcommaaccent
|
||||
!FF U+02D9 dotaccent
|
@ -0,0 +1,256 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+0080 .notdef
|
||||
!81 U+0081 .notdef
|
||||
!82 U+0082 .notdef
|
||||
!83 U+0083 .notdef
|
||||
!84 U+0084 .notdef
|
||||
!85 U+0085 .notdef
|
||||
!86 U+0086 .notdef
|
||||
!87 U+0087 .notdef
|
||||
!88 U+0088 .notdef
|
||||
!89 U+0089 .notdef
|
||||
!8A U+008A .notdef
|
||||
!8B U+008B .notdef
|
||||
!8C U+008C .notdef
|
||||
!8D U+008D .notdef
|
||||
!8E U+008E .notdef
|
||||
!8F U+008F .notdef
|
||||
!90 U+0090 .notdef
|
||||
!91 U+0091 .notdef
|
||||
!92 U+0092 .notdef
|
||||
!93 U+0093 .notdef
|
||||
!94 U+0094 .notdef
|
||||
!95 U+0095 .notdef
|
||||
!96 U+0096 .notdef
|
||||
!97 U+0097 .notdef
|
||||
!98 U+0098 .notdef
|
||||
!99 U+0099 .notdef
|
||||
!9A U+009A .notdef
|
||||
!9B U+009B .notdef
|
||||
!9C U+009C .notdef
|
||||
!9D U+009D .notdef
|
||||
!9E U+009E .notdef
|
||||
!9F U+009F .notdef
|
||||
!A0 U+00A0 space
|
||||
!A1 U+0104 Aogonek
|
||||
!A2 U+0138 kgreenlandic
|
||||
!A3 U+0156 Rcommaaccent
|
||||
!A4 U+00A4 currency
|
||||
!A5 U+0128 Itilde
|
||||
!A6 U+013B Lcommaaccent
|
||||
!A7 U+00A7 section
|
||||
!A8 U+00A8 dieresis
|
||||
!A9 U+0160 Scaron
|
||||
!AA U+0112 Emacron
|
||||
!AB U+0122 Gcommaaccent
|
||||
!AC U+0166 Tbar
|
||||
!AD U+00AD hyphen
|
||||
!AE U+017D Zcaron
|
||||
!AF U+00AF macron
|
||||
!B0 U+00B0 degree
|
||||
!B1 U+0105 aogonek
|
||||
!B2 U+02DB ogonek
|
||||
!B3 U+0157 rcommaaccent
|
||||
!B4 U+00B4 acute
|
||||
!B5 U+0129 itilde
|
||||
!B6 U+013C lcommaaccent
|
||||
!B7 U+02C7 caron
|
||||
!B8 U+00B8 cedilla
|
||||
!B9 U+0161 scaron
|
||||
!BA U+0113 emacron
|
||||
!BB U+0123 gcommaaccent
|
||||
!BC U+0167 tbar
|
||||
!BD U+014A Eng
|
||||
!BE U+017E zcaron
|
||||
!BF U+014B eng
|
||||
!C0 U+0100 Amacron
|
||||
!C1 U+00C1 Aacute
|
||||
!C2 U+00C2 Acircumflex
|
||||
!C3 U+00C3 Atilde
|
||||
!C4 U+00C4 Adieresis
|
||||
!C5 U+00C5 Aring
|
||||
!C6 U+00C6 AE
|
||||
!C7 U+012E Iogonek
|
||||
!C8 U+010C Ccaron
|
||||
!C9 U+00C9 Eacute
|
||||
!CA U+0118 Eogonek
|
||||
!CB U+00CB Edieresis
|
||||
!CC U+0116 Edotaccent
|
||||
!CD U+00CD Iacute
|
||||
!CE U+00CE Icircumflex
|
||||
!CF U+012A Imacron
|
||||
!D0 U+0110 Dcroat
|
||||
!D1 U+0145 Ncommaaccent
|
||||
!D2 U+014C Omacron
|
||||
!D3 U+0136 Kcommaaccent
|
||||
!D4 U+00D4 Ocircumflex
|
||||
!D5 U+00D5 Otilde
|
||||
!D6 U+00D6 Odieresis
|
||||
!D7 U+00D7 multiply
|
||||
!D8 U+00D8 Oslash
|
||||
!D9 U+0172 Uogonek
|
||||
!DA U+00DA Uacute
|
||||
!DB U+00DB Ucircumflex
|
||||
!DC U+00DC Udieresis
|
||||
!DD U+0168 Utilde
|
||||
!DE U+016A Umacron
|
||||
!DF U+00DF germandbls
|
||||
!E0 U+0101 amacron
|
||||
!E1 U+00E1 aacute
|
||||
!E2 U+00E2 acircumflex
|
||||
!E3 U+00E3 atilde
|
||||
!E4 U+00E4 adieresis
|
||||
!E5 U+00E5 aring
|
||||
!E6 U+00E6 ae
|
||||
!E7 U+012F iogonek
|
||||
!E8 U+010D ccaron
|
||||
!E9 U+00E9 eacute
|
||||
!EA U+0119 eogonek
|
||||
!EB U+00EB edieresis
|
||||
!EC U+0117 edotaccent
|
||||
!ED U+00ED iacute
|
||||
!EE U+00EE icircumflex
|
||||
!EF U+012B imacron
|
||||
!F0 U+0111 dcroat
|
||||
!F1 U+0146 ncommaaccent
|
||||
!F2 U+014D omacron
|
||||
!F3 U+0137 kcommaaccent
|
||||
!F4 U+00F4 ocircumflex
|
||||
!F5 U+00F5 otilde
|
||||
!F6 U+00F6 odieresis
|
||||
!F7 U+00F7 divide
|
||||
!F8 U+00F8 oslash
|
||||
!F9 U+0173 uogonek
|
||||
!FA U+00FA uacute
|
||||
!FB U+00FB ucircumflex
|
||||
!FC U+00FC udieresis
|
||||
!FD U+0169 utilde
|
||||
!FE U+016B umacron
|
||||
!FF U+02D9 dotaccent
|
@ -0,0 +1,256 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+0080 .notdef
|
||||
!81 U+0081 .notdef
|
||||
!82 U+0082 .notdef
|
||||
!83 U+0083 .notdef
|
||||
!84 U+0084 .notdef
|
||||
!85 U+0085 .notdef
|
||||
!86 U+0086 .notdef
|
||||
!87 U+0087 .notdef
|
||||
!88 U+0088 .notdef
|
||||
!89 U+0089 .notdef
|
||||
!8A U+008A .notdef
|
||||
!8B U+008B .notdef
|
||||
!8C U+008C .notdef
|
||||
!8D U+008D .notdef
|
||||
!8E U+008E .notdef
|
||||
!8F U+008F .notdef
|
||||
!90 U+0090 .notdef
|
||||
!91 U+0091 .notdef
|
||||
!92 U+0092 .notdef
|
||||
!93 U+0093 .notdef
|
||||
!94 U+0094 .notdef
|
||||
!95 U+0095 .notdef
|
||||
!96 U+0096 .notdef
|
||||
!97 U+0097 .notdef
|
||||
!98 U+0098 .notdef
|
||||
!99 U+0099 .notdef
|
||||
!9A U+009A .notdef
|
||||
!9B U+009B .notdef
|
||||
!9C U+009C .notdef
|
||||
!9D U+009D .notdef
|
||||
!9E U+009E .notdef
|
||||
!9F U+009F .notdef
|
||||
!A0 U+00A0 space
|
||||
!A1 U+0401 afii10023
|
||||
!A2 U+0402 afii10051
|
||||
!A3 U+0403 afii10052
|
||||
!A4 U+0404 afii10053
|
||||
!A5 U+0405 afii10054
|
||||
!A6 U+0406 afii10055
|
||||
!A7 U+0407 afii10056
|
||||
!A8 U+0408 afii10057
|
||||
!A9 U+0409 afii10058
|
||||
!AA U+040A afii10059
|
||||
!AB U+040B afii10060
|
||||
!AC U+040C afii10061
|
||||
!AD U+00AD hyphen
|
||||
!AE U+040E afii10062
|
||||
!AF U+040F afii10145
|
||||
!B0 U+0410 afii10017
|
||||
!B1 U+0411 afii10018
|
||||
!B2 U+0412 afii10019
|
||||
!B3 U+0413 afii10020
|
||||
!B4 U+0414 afii10021
|
||||
!B5 U+0415 afii10022
|
||||
!B6 U+0416 afii10024
|
||||
!B7 U+0417 afii10025
|
||||
!B8 U+0418 afii10026
|
||||
!B9 U+0419 afii10027
|
||||
!BA U+041A afii10028
|
||||
!BB U+041B afii10029
|
||||
!BC U+041C afii10030
|
||||
!BD U+041D afii10031
|
||||
!BE U+041E afii10032
|
||||
!BF U+041F afii10033
|
||||
!C0 U+0420 afii10034
|
||||
!C1 U+0421 afii10035
|
||||
!C2 U+0422 afii10036
|
||||
!C3 U+0423 afii10037
|
||||
!C4 U+0424 afii10038
|
||||
!C5 U+0425 afii10039
|
||||
!C6 U+0426 afii10040
|
||||
!C7 U+0427 afii10041
|
||||
!C8 U+0428 afii10042
|
||||
!C9 U+0429 afii10043
|
||||
!CA U+042A afii10044
|
||||
!CB U+042B afii10045
|
||||
!CC U+042C afii10046
|
||||
!CD U+042D afii10047
|
||||
!CE U+042E afii10048
|
||||
!CF U+042F afii10049
|
||||
!D0 U+0430 afii10065
|
||||
!D1 U+0431 afii10066
|
||||
!D2 U+0432 afii10067
|
||||
!D3 U+0433 afii10068
|
||||
!D4 U+0434 afii10069
|
||||
!D5 U+0435 afii10070
|
||||
!D6 U+0436 afii10072
|
||||
!D7 U+0437 afii10073
|
||||
!D8 U+0438 afii10074
|
||||
!D9 U+0439 afii10075
|
||||
!DA U+043A afii10076
|
||||
!DB U+043B afii10077
|
||||
!DC U+043C afii10078
|
||||
!DD U+043D afii10079
|
||||
!DE U+043E afii10080
|
||||
!DF U+043F afii10081
|
||||
!E0 U+0440 afii10082
|
||||
!E1 U+0441 afii10083
|
||||
!E2 U+0442 afii10084
|
||||
!E3 U+0443 afii10085
|
||||
!E4 U+0444 afii10086
|
||||
!E5 U+0445 afii10087
|
||||
!E6 U+0446 afii10088
|
||||
!E7 U+0447 afii10089
|
||||
!E8 U+0448 afii10090
|
||||
!E9 U+0449 afii10091
|
||||
!EA U+044A afii10092
|
||||
!EB U+044B afii10093
|
||||
!EC U+044C afii10094
|
||||
!ED U+044D afii10095
|
||||
!EE U+044E afii10096
|
||||
!EF U+044F afii10097
|
||||
!F0 U+2116 afii61352
|
||||
!F1 U+0451 afii10071
|
||||
!F2 U+0452 afii10099
|
||||
!F3 U+0453 afii10100
|
||||
!F4 U+0454 afii10101
|
||||
!F5 U+0455 afii10102
|
||||
!F6 U+0456 afii10103
|
||||
!F7 U+0457 afii10104
|
||||
!F8 U+0458 afii10105
|
||||
!F9 U+0459 afii10106
|
||||
!FA U+045A afii10107
|
||||
!FB U+045B afii10108
|
||||
!FC U+045C afii10109
|
||||
!FD U+00A7 section
|
||||
!FE U+045E afii10110
|
||||
!FF U+045F afii10193
|
@ -0,0 +1,250 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+0080 .notdef
|
||||
!81 U+0081 .notdef
|
||||
!82 U+0082 .notdef
|
||||
!83 U+0083 .notdef
|
||||
!84 U+0084 .notdef
|
||||
!85 U+0085 .notdef
|
||||
!86 U+0086 .notdef
|
||||
!87 U+0087 .notdef
|
||||
!88 U+0088 .notdef
|
||||
!89 U+0089 .notdef
|
||||
!8A U+008A .notdef
|
||||
!8B U+008B .notdef
|
||||
!8C U+008C .notdef
|
||||
!8D U+008D .notdef
|
||||
!8E U+008E .notdef
|
||||
!8F U+008F .notdef
|
||||
!90 U+0090 .notdef
|
||||
!91 U+0091 .notdef
|
||||
!92 U+0092 .notdef
|
||||
!93 U+0093 .notdef
|
||||
!94 U+0094 .notdef
|
||||
!95 U+0095 .notdef
|
||||
!96 U+0096 .notdef
|
||||
!97 U+0097 .notdef
|
||||
!98 U+0098 .notdef
|
||||
!99 U+0099 .notdef
|
||||
!9A U+009A .notdef
|
||||
!9B U+009B .notdef
|
||||
!9C U+009C .notdef
|
||||
!9D U+009D .notdef
|
||||
!9E U+009E .notdef
|
||||
!9F U+009F .notdef
|
||||
!A0 U+00A0 space
|
||||
!A1 U+2018 quoteleft
|
||||
!A2 U+2019 quoteright
|
||||
!A3 U+00A3 sterling
|
||||
!A6 U+00A6 brokenbar
|
||||
!A7 U+00A7 section
|
||||
!A8 U+00A8 dieresis
|
||||
!A9 U+00A9 copyright
|
||||
!AB U+00AB guillemotleft
|
||||
!AC U+00AC logicalnot
|
||||
!AD U+00AD hyphen
|
||||
!AF U+2015 afii00208
|
||||
!B0 U+00B0 degree
|
||||
!B1 U+00B1 plusminus
|
||||
!B2 U+00B2 twosuperior
|
||||
!B3 U+00B3 threesuperior
|
||||
!B4 U+0384 tonos
|
||||
!B5 U+0385 dieresistonos
|
||||
!B6 U+0386 Alphatonos
|
||||
!B7 U+00B7 periodcentered
|
||||
!B8 U+0388 Epsilontonos
|
||||
!B9 U+0389 Etatonos
|
||||
!BA U+038A Iotatonos
|
||||
!BB U+00BB guillemotright
|
||||
!BC U+038C Omicrontonos
|
||||
!BD U+00BD onehalf
|
||||
!BE U+038E Upsilontonos
|
||||
!BF U+038F Omegatonos
|
||||
!C0 U+0390 iotadieresistonos
|
||||
!C1 U+0391 Alpha
|
||||
!C2 U+0392 Beta
|
||||
!C3 U+0393 Gamma
|
||||
!C4 U+0394 Delta
|
||||
!C5 U+0395 Epsilon
|
||||
!C6 U+0396 Zeta
|
||||
!C7 U+0397 Eta
|
||||
!C8 U+0398 Theta
|
||||
!C9 U+0399 Iota
|
||||
!CA U+039A Kappa
|
||||
!CB U+039B Lambda
|
||||
!CC U+039C Mu
|
||||
!CD U+039D Nu
|
||||
!CE U+039E Xi
|
||||
!CF U+039F Omicron
|
||||
!D0 U+03A0 Pi
|
||||
!D1 U+03A1 Rho
|
||||
!D3 U+03A3 Sigma
|
||||
!D4 U+03A4 Tau
|
||||
!D5 U+03A5 Upsilon
|
||||
!D6 U+03A6 Phi
|
||||
!D7 U+03A7 Chi
|
||||
!D8 U+03A8 Psi
|
||||
!D9 U+03A9 Omega
|
||||
!DA U+03AA Iotadieresis
|
||||
!DB U+03AB Upsilondieresis
|
||||
!DC U+03AC alphatonos
|
||||
!DD U+03AD epsilontonos
|
||||
!DE U+03AE etatonos
|
||||
!DF U+03AF iotatonos
|
||||
!E0 U+03B0 upsilondieresistonos
|
||||
!E1 U+03B1 alpha
|
||||
!E2 U+03B2 beta
|
||||
!E3 U+03B3 gamma
|
||||
!E4 U+03B4 delta
|
||||
!E5 U+03B5 epsilon
|
||||
!E6 U+03B6 zeta
|
||||
!E7 U+03B7 eta
|
||||
!E8 U+03B8 theta
|
||||
!E9 U+03B9 iota
|
||||
!EA U+03BA kappa
|
||||
!EB U+03BB lambda
|
||||
!EC U+03BC mu
|
||||
!ED U+03BD nu
|
||||
!EE U+03BE xi
|
||||
!EF U+03BF omicron
|
||||
!F0 U+03C0 pi
|
||||
!F1 U+03C1 rho
|
||||
!F2 U+03C2 sigma1
|
||||
!F3 U+03C3 sigma
|
||||
!F4 U+03C4 tau
|
||||
!F5 U+03C5 upsilon
|
||||
!F6 U+03C6 phi
|
||||
!F7 U+03C7 chi
|
||||
!F8 U+03C8 psi
|
||||
!F9 U+03C9 omega
|
||||
!FA U+03CA iotadieresis
|
||||
!FB U+03CB upsilondieresis
|
||||
!FC U+03CC omicrontonos
|
||||
!FD U+03CD upsilontonos
|
||||
!FE U+03CE omegatonos
|
@ -0,0 +1,256 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+0080 .notdef
|
||||
!81 U+0081 .notdef
|
||||
!82 U+0082 .notdef
|
||||
!83 U+0083 .notdef
|
||||
!84 U+0084 .notdef
|
||||
!85 U+0085 .notdef
|
||||
!86 U+0086 .notdef
|
||||
!87 U+0087 .notdef
|
||||
!88 U+0088 .notdef
|
||||
!89 U+0089 .notdef
|
||||
!8A U+008A .notdef
|
||||
!8B U+008B .notdef
|
||||
!8C U+008C .notdef
|
||||
!8D U+008D .notdef
|
||||
!8E U+008E .notdef
|
||||
!8F U+008F .notdef
|
||||
!90 U+0090 .notdef
|
||||
!91 U+0091 .notdef
|
||||
!92 U+0092 .notdef
|
||||
!93 U+0093 .notdef
|
||||
!94 U+0094 .notdef
|
||||
!95 U+0095 .notdef
|
||||
!96 U+0096 .notdef
|
||||
!97 U+0097 .notdef
|
||||
!98 U+0098 .notdef
|
||||
!99 U+0099 .notdef
|
||||
!9A U+009A .notdef
|
||||
!9B U+009B .notdef
|
||||
!9C U+009C .notdef
|
||||
!9D U+009D .notdef
|
||||
!9E U+009E .notdef
|
||||
!9F U+009F .notdef
|
||||
!A0 U+00A0 space
|
||||
!A1 U+00A1 exclamdown
|
||||
!A2 U+00A2 cent
|
||||
!A3 U+00A3 sterling
|
||||
!A4 U+00A4 currency
|
||||
!A5 U+00A5 yen
|
||||
!A6 U+00A6 brokenbar
|
||||
!A7 U+00A7 section
|
||||
!A8 U+00A8 dieresis
|
||||
!A9 U+00A9 copyright
|
||||
!AA U+00AA ordfeminine
|
||||
!AB U+00AB guillemotleft
|
||||
!AC U+00AC logicalnot
|
||||
!AD U+00AD hyphen
|
||||
!AE U+00AE registered
|
||||
!AF U+00AF macron
|
||||
!B0 U+00B0 degree
|
||||
!B1 U+00B1 plusminus
|
||||
!B2 U+00B2 twosuperior
|
||||
!B3 U+00B3 threesuperior
|
||||
!B4 U+00B4 acute
|
||||
!B5 U+00B5 mu
|
||||
!B6 U+00B6 paragraph
|
||||
!B7 U+00B7 periodcentered
|
||||
!B8 U+00B8 cedilla
|
||||
!B9 U+00B9 onesuperior
|
||||
!BA U+00BA ordmasculine
|
||||
!BB U+00BB guillemotright
|
||||
!BC U+00BC onequarter
|
||||
!BD U+00BD onehalf
|
||||
!BE U+00BE threequarters
|
||||
!BF U+00BF questiondown
|
||||
!C0 U+00C0 Agrave
|
||||
!C1 U+00C1 Aacute
|
||||
!C2 U+00C2 Acircumflex
|
||||
!C3 U+00C3 Atilde
|
||||
!C4 U+00C4 Adieresis
|
||||
!C5 U+00C5 Aring
|
||||
!C6 U+00C6 AE
|
||||
!C7 U+00C7 Ccedilla
|
||||
!C8 U+00C8 Egrave
|
||||
!C9 U+00C9 Eacute
|
||||
!CA U+00CA Ecircumflex
|
||||
!CB U+00CB Edieresis
|
||||
!CC U+00CC Igrave
|
||||
!CD U+00CD Iacute
|
||||
!CE U+00CE Icircumflex
|
||||
!CF U+00CF Idieresis
|
||||
!D0 U+011E Gbreve
|
||||
!D1 U+00D1 Ntilde
|
||||
!D2 U+00D2 Ograve
|
||||
!D3 U+00D3 Oacute
|
||||
!D4 U+00D4 Ocircumflex
|
||||
!D5 U+00D5 Otilde
|
||||
!D6 U+00D6 Odieresis
|
||||
!D7 U+00D7 multiply
|
||||
!D8 U+00D8 Oslash
|
||||
!D9 U+00D9 Ugrave
|
||||
!DA U+00DA Uacute
|
||||
!DB U+00DB Ucircumflex
|
||||
!DC U+00DC Udieresis
|
||||
!DD U+0130 Idotaccent
|
||||
!DE U+015E Scedilla
|
||||
!DF U+00DF germandbls
|
||||
!E0 U+00E0 agrave
|
||||
!E1 U+00E1 aacute
|
||||
!E2 U+00E2 acircumflex
|
||||
!E3 U+00E3 atilde
|
||||
!E4 U+00E4 adieresis
|
||||
!E5 U+00E5 aring
|
||||
!E6 U+00E6 ae
|
||||
!E7 U+00E7 ccedilla
|
||||
!E8 U+00E8 egrave
|
||||
!E9 U+00E9 eacute
|
||||
!EA U+00EA ecircumflex
|
||||
!EB U+00EB edieresis
|
||||
!EC U+00EC igrave
|
||||
!ED U+00ED iacute
|
||||
!EE U+00EE icircumflex
|
||||
!EF U+00EF idieresis
|
||||
!F0 U+011F gbreve
|
||||
!F1 U+00F1 ntilde
|
||||
!F2 U+00F2 ograve
|
||||
!F3 U+00F3 oacute
|
||||
!F4 U+00F4 ocircumflex
|
||||
!F5 U+00F5 otilde
|
||||
!F6 U+00F6 odieresis
|
||||
!F7 U+00F7 divide
|
||||
!F8 U+00F8 oslash
|
||||
!F9 U+00F9 ugrave
|
||||
!FA U+00FA uacute
|
||||
!FB U+00FB ucircumflex
|
||||
!FC U+00FC udieresis
|
||||
!FD U+0131 dotlessi
|
||||
!FE U+015F scedilla
|
||||
!FF U+00FF ydieresis
|
@ -0,0 +1,256 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+2500 SF100000
|
||||
!81 U+2502 SF110000
|
||||
!82 U+250C SF010000
|
||||
!83 U+2510 SF030000
|
||||
!84 U+2514 SF020000
|
||||
!85 U+2518 SF040000
|
||||
!86 U+251C SF080000
|
||||
!87 U+2524 SF090000
|
||||
!88 U+252C SF060000
|
||||
!89 U+2534 SF070000
|
||||
!8A U+253C SF050000
|
||||
!8B U+2580 upblock
|
||||
!8C U+2584 dnblock
|
||||
!8D U+2588 block
|
||||
!8E U+258C lfblock
|
||||
!8F U+2590 rtblock
|
||||
!90 U+2591 ltshade
|
||||
!91 U+2592 shade
|
||||
!92 U+2593 dkshade
|
||||
!93 U+2320 integraltp
|
||||
!94 U+25A0 filledbox
|
||||
!95 U+2219 periodcentered
|
||||
!96 U+221A radical
|
||||
!97 U+2248 approxequal
|
||||
!98 U+2264 lessequal
|
||||
!99 U+2265 greaterequal
|
||||
!9A U+00A0 space
|
||||
!9B U+2321 integralbt
|
||||
!9C U+00B0 degree
|
||||
!9D U+00B2 twosuperior
|
||||
!9E U+00B7 periodcentered
|
||||
!9F U+00F7 divide
|
||||
!A0 U+2550 SF430000
|
||||
!A1 U+2551 SF240000
|
||||
!A2 U+2552 SF510000
|
||||
!A3 U+0451 afii10071
|
||||
!A4 U+2553 SF520000
|
||||
!A5 U+2554 SF390000
|
||||
!A6 U+2555 SF220000
|
||||
!A7 U+2556 SF210000
|
||||
!A8 U+2557 SF250000
|
||||
!A9 U+2558 SF500000
|
||||
!AA U+2559 SF490000
|
||||
!AB U+255A SF380000
|
||||
!AC U+255B SF280000
|
||||
!AD U+255C SF270000
|
||||
!AE U+255D SF260000
|
||||
!AF U+255E SF360000
|
||||
!B0 U+255F SF370000
|
||||
!B1 U+2560 SF420000
|
||||
!B2 U+2561 SF190000
|
||||
!B3 U+0401 afii10023
|
||||
!B4 U+2562 SF200000
|
||||
!B5 U+2563 SF230000
|
||||
!B6 U+2564 SF470000
|
||||
!B7 U+2565 SF480000
|
||||
!B8 U+2566 SF410000
|
||||
!B9 U+2567 SF450000
|
||||
!BA U+2568 SF460000
|
||||
!BB U+2569 SF400000
|
||||
!BC U+256A SF540000
|
||||
!BD U+256B SF530000
|
||||
!BE U+256C SF440000
|
||||
!BF U+00A9 copyright
|
||||
!C0 U+044E afii10096
|
||||
!C1 U+0430 afii10065
|
||||
!C2 U+0431 afii10066
|
||||
!C3 U+0446 afii10088
|
||||
!C4 U+0434 afii10069
|
||||
!C5 U+0435 afii10070
|
||||
!C6 U+0444 afii10086
|
||||
!C7 U+0433 afii10068
|
||||
!C8 U+0445 afii10087
|
||||
!C9 U+0438 afii10074
|
||||
!CA U+0439 afii10075
|
||||
!CB U+043A afii10076
|
||||
!CC U+043B afii10077
|
||||
!CD U+043C afii10078
|
||||
!CE U+043D afii10079
|
||||
!CF U+043E afii10080
|
||||
!D0 U+043F afii10081
|
||||
!D1 U+044F afii10097
|
||||
!D2 U+0440 afii10082
|
||||
!D3 U+0441 afii10083
|
||||
!D4 U+0442 afii10084
|
||||
!D5 U+0443 afii10085
|
||||
!D6 U+0436 afii10072
|
||||
!D7 U+0432 afii10067
|
||||
!D8 U+044C afii10094
|
||||
!D9 U+044B afii10093
|
||||
!DA U+0437 afii10073
|
||||
!DB U+0448 afii10090
|
||||
!DC U+044D afii10095
|
||||
!DD U+0449 afii10091
|
||||
!DE U+0447 afii10089
|
||||
!DF U+044A afii10092
|
||||
!E0 U+042E afii10048
|
||||
!E1 U+0410 afii10017
|
||||
!E2 U+0411 afii10018
|
||||
!E3 U+0426 afii10040
|
||||
!E4 U+0414 afii10021
|
||||
!E5 U+0415 afii10022
|
||||
!E6 U+0424 afii10038
|
||||
!E7 U+0413 afii10020
|
||||
!E8 U+0425 afii10039
|
||||
!E9 U+0418 afii10026
|
||||
!EA U+0419 afii10027
|
||||
!EB U+041A afii10028
|
||||
!EC U+041B afii10029
|
||||
!ED U+041C afii10030
|
||||
!EE U+041D afii10031
|
||||
!EF U+041E afii10032
|
||||
!F0 U+041F afii10033
|
||||
!F1 U+042F afii10049
|
||||
!F2 U+0420 afii10034
|
||||
!F3 U+0421 afii10035
|
||||
!F4 U+0422 afii10036
|
||||
!F5 U+0423 afii10037
|
||||
!F6 U+0416 afii10024
|
||||
!F7 U+0412 afii10019
|
||||
!F8 U+042C afii10046
|
||||
!F9 U+042B afii10045
|
||||
!FA U+0417 afii10025
|
||||
!FB U+0428 afii10042
|
||||
!FC U+042D afii10047
|
||||
!FD U+0429 afii10043
|
||||
!FE U+0427 afii10041
|
||||
!FF U+042A afii10044
|
@ -0,0 +1,256 @@
|
||||
!00 U+0000 .notdef
|
||||
!01 U+0001 .notdef
|
||||
!02 U+0002 .notdef
|
||||
!03 U+0003 .notdef
|
||||
!04 U+0004 .notdef
|
||||
!05 U+0005 .notdef
|
||||
!06 U+0006 .notdef
|
||||
!07 U+0007 .notdef
|
||||
!08 U+0008 .notdef
|
||||
!09 U+0009 .notdef
|
||||
!0A U+000A .notdef
|
||||
!0B U+000B .notdef
|
||||
!0C U+000C .notdef
|
||||
!0D U+000D .notdef
|
||||
!0E U+000E .notdef
|
||||
!0F U+000F .notdef
|
||||
!10 U+0010 .notdef
|
||||
!11 U+0011 .notdef
|
||||
!12 U+0012 .notdef
|
||||
!13 U+0013 .notdef
|
||||
!14 U+0014 .notdef
|
||||
!15 U+0015 .notdef
|
||||
!16 U+0016 .notdef
|
||||
!17 U+0017 .notdef
|
||||
!18 U+0018 .notdef
|
||||
!19 U+0019 .notdef
|
||||
!1A U+001A .notdef
|
||||
!1B U+001B .notdef
|
||||
!1C U+001C .notdef
|
||||
!1D U+001D .notdef
|
||||
!1E U+001E .notdef
|
||||
!1F U+001F .notdef
|
||||
!20 U+0020 space
|
||||
!21 U+0021 exclam
|
||||
!22 U+0022 quotedbl
|
||||
!23 U+0023 numbersign
|
||||
!24 U+0024 dollar
|
||||
!25 U+0025 percent
|
||||
!26 U+0026 ampersand
|
||||
!27 U+0027 quotesingle
|
||||
!28 U+0028 parenleft
|
||||
!29 U+0029 parenright
|
||||
!2A U+002A asterisk
|
||||
!2B U+002B plus
|
||||
!2C U+002C comma
|
||||
!2D U+002D hyphen
|
||||
!2E U+002E period
|
||||
!2F U+002F slash
|
||||
!30 U+0030 zero
|
||||
!31 U+0031 one
|
||||
!32 U+0032 two
|
||||
!33 U+0033 three
|
||||
!34 U+0034 four
|
||||
!35 U+0035 five
|
||||
!36 U+0036 six
|
||||
!37 U+0037 seven
|
||||
!38 U+0038 eight
|
||||
!39 U+0039 nine
|
||||
!3A U+003A colon
|
||||
!3B U+003B semicolon
|
||||
!3C U+003C less
|
||||
!3D U+003D equal
|
||||
!3E U+003E greater
|
||||
!3F U+003F question
|
||||
!40 U+0040 at
|
||||
!41 U+0041 A
|
||||
!42 U+0042 B
|
||||
!43 U+0043 C
|
||||
!44 U+0044 D
|
||||
!45 U+0045 E
|
||||
!46 U+0046 F
|
||||
!47 U+0047 G
|
||||
!48 U+0048 H
|
||||
!49 U+0049 I
|
||||
!4A U+004A J
|
||||
!4B U+004B K
|
||||
!4C U+004C L
|
||||
!4D U+004D M
|
||||
!4E U+004E N
|
||||
!4F U+004F O
|
||||
!50 U+0050 P
|
||||
!51 U+0051 Q
|
||||
!52 U+0052 R
|
||||
!53 U+0053 S
|
||||
!54 U+0054 T
|
||||
!55 U+0055 U
|
||||
!56 U+0056 V
|
||||
!57 U+0057 W
|
||||
!58 U+0058 X
|
||||
!59 U+0059 Y
|
||||
!5A U+005A Z
|
||||
!5B U+005B bracketleft
|
||||
!5C U+005C backslash
|
||||
!5D U+005D bracketright
|
||||
!5E U+005E asciicircum
|
||||
!5F U+005F underscore
|
||||
!60 U+0060 grave
|
||||
!61 U+0061 a
|
||||
!62 U+0062 b
|
||||
!63 U+0063 c
|
||||
!64 U+0064 d
|
||||
!65 U+0065 e
|
||||
!66 U+0066 f
|
||||
!67 U+0067 g
|
||||
!68 U+0068 h
|
||||
!69 U+0069 i
|
||||
!6A U+006A j
|
||||
!6B U+006B k
|
||||
!6C U+006C l
|
||||
!6D U+006D m
|
||||
!6E U+006E n
|
||||
!6F U+006F o
|
||||
!70 U+0070 p
|
||||
!71 U+0071 q
|
||||
!72 U+0072 r
|
||||
!73 U+0073 s
|
||||
!74 U+0074 t
|
||||
!75 U+0075 u
|
||||
!76 U+0076 v
|
||||
!77 U+0077 w
|
||||
!78 U+0078 x
|
||||
!79 U+0079 y
|
||||
!7A U+007A z
|
||||
!7B U+007B braceleft
|
||||
!7C U+007C bar
|
||||
!7D U+007D braceright
|
||||
!7E U+007E asciitilde
|
||||
!7F U+007F .notdef
|
||||
!80 U+2500 SF100000
|
||||
!81 U+2502 SF110000
|
||||
!82 U+250C SF010000
|
||||
!83 U+2510 SF030000
|
||||
!84 U+2514 SF020000
|
||||
!85 U+2518 SF040000
|
||||
!86 U+251C SF080000
|
||||
!87 U+2524 SF090000
|
||||
!88 U+252C SF060000
|
||||
!89 U+2534 SF070000
|
||||
!8A U+253C SF050000
|
||||
!8B U+2580 upblock
|
||||
!8C U+2584 dnblock
|
||||
!8D U+2588 block
|
||||
!8E U+258C lfblock
|
||||
!8F U+2590 rtblock
|
||||
!90 U+2591 ltshade
|
||||
!91 U+2592 shade
|
||||
!92 U+2593 dkshade
|
||||
!93 U+2320 integraltp
|
||||
!94 U+25A0 filledbox
|
||||
!95 U+2022 bullet
|
||||
!96 U+221A radical
|
||||
!97 U+2248 approxequal
|
||||
!98 U+2264 lessequal
|
||||
!99 U+2265 greaterequal
|
||||
!9A U+00A0 space
|
||||
!9B U+2321 integralbt
|
||||
!9C U+00B0 degree
|
||||
!9D U+00B2 twosuperior
|
||||
!9E U+00B7 periodcentered
|
||||
!9F U+00F7 divide
|
||||
!A0 U+2550 SF430000
|
||||
!A1 U+2551 SF240000
|
||||
!A2 U+2552 SF510000
|
||||
!A3 U+0451 afii10071
|
||||
!A4 U+0454 afii10101
|
||||
!A5 U+2554 SF390000
|
||||
!A6 U+0456 afii10103
|
||||
!A7 U+0457 afii10104
|
||||
!A8 U+2557 SF250000
|
||||
!A9 U+2558 SF500000
|
||||
!AA U+2559 SF490000
|
||||
!AB U+255A SF380000
|
||||
!AC U+255B SF280000
|
||||
!AD U+0491 afii10098
|
||||
!AE U+255D SF260000
|
||||
!AF U+255E SF360000
|
||||
!B0 U+255F SF370000
|
||||
!B1 U+2560 SF420000
|
||||
!B2 U+2561 SF190000
|
||||
!B3 U+0401 afii10023
|
||||
!B4 U+0404 afii10053
|
||||
!B5 U+2563 SF230000
|
||||
!B6 U+0406 afii10055
|
||||
!B7 U+0407 afii10056
|
||||
!B8 U+2566 SF410000
|
||||
!B9 U+2567 SF450000
|
||||
!BA U+2568 SF460000
|
||||
!BB U+2569 SF400000
|
||||
!BC U+256A SF540000
|
||||
!BD U+0490 afii10050
|
||||
!BE U+256C SF440000
|
||||
!BF U+00A9 copyright
|
||||
!C0 U+044E afii10096
|
||||
!C1 U+0430 afii10065
|
||||
!C2 U+0431 afii10066
|
||||
!C3 U+0446 afii10088
|
||||
!C4 U+0434 afii10069
|
||||
!C5 U+0435 afii10070
|
||||
!C6 U+0444 afii10086
|
||||
!C7 U+0433 afii10068
|
||||
!C8 U+0445 afii10087
|
||||
!C9 U+0438 afii10074
|
||||
!CA U+0439 afii10075
|
||||
!CB U+043A afii10076
|
||||
!CC U+043B afii10077
|
||||
!CD U+043C afii10078
|
||||
!CE U+043D afii10079
|
||||
!CF U+043E afii10080
|
||||
!D0 U+043F afii10081
|
||||
!D1 U+044F afii10097
|
||||
!D2 U+0440 afii10082
|
||||
!D3 U+0441 afii10083
|
||||
!D4 U+0442 afii10084
|
||||
!D5 U+0443 afii10085
|
||||
!D6 U+0436 afii10072
|
||||
!D7 U+0432 afii10067
|
||||
!D8 U+044C afii10094
|
||||
!D9 U+044B afii10093
|
||||
!DA U+0437 afii10073
|
||||
!DB U+0448 afii10090
|
||||
!DC U+044D afii10095
|
||||
!DD U+0449 afii10091
|
||||
!DE U+0447 afii10089
|
||||
!DF U+044A afii10092
|
||||
!E0 U+042E afii10048
|
||||
!E1 U+0410 afii10017
|
||||
!E2 U+0411 afii10018
|
||||
!E3 U+0426 afii10040
|
||||
!E4 U+0414 afii10021
|
||||
!E5 U+0415 afii10022
|
||||
!E6 U+0424 afii10038
|
||||
!E7 U+0413 afii10020
|
||||
!E8 U+0425 afii10039
|
||||
!E9 U+0418 afii10026
|
||||
!EA U+0419 afii10027
|
||||
!EB U+041A afii10028
|
||||
!EC U+041B afii10029
|
||||
!ED U+041C afii10030
|
||||
!EE U+041D afii10031
|
||||
!EF U+041E afii10032
|
||||
!F0 U+041F afii10033
|
||||
!F1 U+042F afii10049
|
||||
!F2 U+0420 afii10034
|
||||
!F3 U+0421 afii10035
|
||||
!F4 U+0422 afii10036
|
||||
!F5 U+0423 afii10037
|
||||
!F6 U+0416 afii10024
|
||||
!F7 U+0412 afii10019
|
||||
!F8 U+042C afii10046
|
||||
!F9 U+042B afii10045
|
||||
!FA U+0417 afii10025
|
||||
!FB U+0428 afii10042
|
||||
!FC U+042D afii10047
|
||||
!FD U+0429 afii10043
|
||||
!FE U+0427 afii10041
|
||||
!FF U+042A afii10044
|
@ -0,0 +1,397 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
/*******************************************************************************
|
||||
* Utility to generate font definition files *
|
||||
* *
|
||||
* Version: 1.14 *
|
||||
* Date: 2008-08-03 *
|
||||
* Author: Olivier PLATHEY *
|
||||
*******************************************************************************/
|
||||
|
||||
function ReadMap($enc)
|
||||
{
|
||||
//Read a map file
|
||||
$file = dirname(__FILE__).'/'.strtolower($enc).'.map';
|
||||
$a = file($file);
|
||||
if (empty($a))
|
||||
die('<b>Error:</b> encoding not found: '.$enc);
|
||||
$cc2gn = array();
|
||||
foreach ($a as $l) {
|
||||
if ($l[0] == '!') {
|
||||
$e = preg_split('/[ \\t]+/', rtrim($l));
|
||||
$cc = hexdec(substr($e[0], 1));
|
||||
$gn = $e[2];
|
||||
$cc2gn[ $cc ] = $gn;
|
||||
}
|
||||
}
|
||||
for ($i = 0; $i <= 255; $i++) {
|
||||
if (!isset($cc2gn[ $i ]))
|
||||
$cc2gn[ $i ] = '.notdef';
|
||||
}
|
||||
|
||||
return $cc2gn;
|
||||
}
|
||||
|
||||
function ReadAFM($file, &$map)
|
||||
{
|
||||
//Read a font metric file
|
||||
$a = file($file);
|
||||
if (empty($a))
|
||||
die('File not found');
|
||||
$widths = array();
|
||||
$fm = array();
|
||||
$fix = array(
|
||||
'Edot' => 'Edotaccent', 'edot' => 'edotaccent', 'Idot' => 'Idotaccent', 'Zdot' => 'Zdotaccent', 'zdot' => 'zdotaccent',
|
||||
'Odblacute' => 'Ohungarumlaut', 'odblacute' => 'ohungarumlaut', 'Udblacute' => 'Uhungarumlaut', 'udblacute' => 'uhungarumlaut',
|
||||
'Gcedilla' => 'Gcommaaccent', 'gcedilla' => 'gcommaaccent', 'Kcedilla' => 'Kcommaaccent', 'kcedilla' => 'kcommaaccent',
|
||||
'Lcedilla' => 'Lcommaaccent', 'lcedilla' => 'lcommaaccent', 'Ncedilla' => 'Ncommaaccent', 'ncedilla' => 'ncommaaccent',
|
||||
'Rcedilla' => 'Rcommaaccent', 'rcedilla' => 'rcommaaccent', 'Scedilla' => 'Scommaaccent', 'scedilla' => 'scommaaccent',
|
||||
'Tcedilla' => 'Tcommaaccent', 'tcedilla' => 'tcommaaccent', 'Dslash' => 'Dcroat', 'dslash' => 'dcroat', 'Dmacron' => 'Dcroat', 'dmacron' => 'dcroat',
|
||||
'combininggraveaccent' => 'gravecomb', 'combininghookabove' => 'hookabovecomb', 'combiningtildeaccent' => 'tildecomb',
|
||||
'combiningacuteaccent' => 'acutecomb', 'combiningdotbelow' => 'dotbelowcomb', 'dongsign' => 'dong'
|
||||
);
|
||||
foreach ($a as $l) {
|
||||
$e = explode(' ', rtrim($l));
|
||||
if (count($e) < 2)
|
||||
continue;
|
||||
$code = $e[0];
|
||||
$param = $e[1];
|
||||
if ($code == 'C') {
|
||||
//Character metrics
|
||||
$cc = (int)$e[1];
|
||||
$w = $e[4];
|
||||
$gn = $e[7];
|
||||
if (substr($gn, -4) == '20AC')
|
||||
$gn = 'Euro';
|
||||
if (isset($fix[ $gn ])) {
|
||||
//Fix incorrect glyph name
|
||||
foreach ($map as $c => $n) {
|
||||
if ($n == $fix[ $gn ])
|
||||
$map[ $c ] = $gn;
|
||||
}
|
||||
}
|
||||
if (empty($map)) {
|
||||
//Symbolic font: use built-in encoding
|
||||
$widths[ $cc ] = $w;
|
||||
} else {
|
||||
$widths[ $gn ] = $w;
|
||||
if ($gn == 'X')
|
||||
$fm['CapXHeight'] = $e[13];
|
||||
}
|
||||
if ($gn == '.notdef')
|
||||
$fm['MissingWidth'] = $w;
|
||||
} elseif ($code == 'FontName')
|
||||
$fm['FontName'] = $param;
|
||||
elseif ($code == 'Weight')
|
||||
$fm['Weight'] = $param;
|
||||
elseif ($code == 'ItalicAngle')
|
||||
$fm['ItalicAngle'] = (double)$param;
|
||||
elseif ($code == 'Ascender')
|
||||
$fm['Ascender'] = (int)$param;
|
||||
elseif ($code == 'Descender')
|
||||
$fm['Descender'] = (int)$param;
|
||||
elseif ($code == 'UnderlineThickness')
|
||||
$fm['UnderlineThickness'] = (int)$param;
|
||||
elseif ($code == 'UnderlinePosition')
|
||||
$fm['UnderlinePosition'] = (int)$param;
|
||||
elseif ($code == 'IsFixedPitch')
|
||||
$fm['IsFixedPitch'] = ($param == 'true');
|
||||
elseif ($code == 'FontBBox')
|
||||
$fm['FontBBox'] = array($e[1], $e[2], $e[3], $e[4]);
|
||||
elseif ($code == 'CapHeight')
|
||||
$fm['CapHeight'] = (int)$param;
|
||||
elseif ($code == 'StdVW')
|
||||
$fm['StdVW'] = (int)$param;
|
||||
}
|
||||
if (!isset($fm['FontName']))
|
||||
die('FontName not found');
|
||||
if (!empty($map)) {
|
||||
if (!isset($widths['.notdef']))
|
||||
$widths['.notdef'] = 600;
|
||||
if (!isset($widths['Delta']) && isset($widths['increment']))
|
||||
$widths['Delta'] = $widths['increment'];
|
||||
//Order widths according to map
|
||||
for ($i = 0; $i <= 255; $i++) {
|
||||
if (!isset($widths[ $map[ $i ] ])) {
|
||||
echo '<b>Warning:</b> character '.$map[ $i ].' is missing<br>';
|
||||
$widths[ $i ] = $widths['.notdef'];
|
||||
} else
|
||||
$widths[ $i ] = $widths[ $map[ $i ] ];
|
||||
}
|
||||
}
|
||||
$fm['Widths'] = $widths;
|
||||
|
||||
return $fm;
|
||||
}
|
||||
|
||||
function MakeFontDescriptor($fm, $symbolic)
|
||||
{
|
||||
//Ascent
|
||||
$asc = (isset($fm['Ascender']) ? $fm['Ascender'] : 1000);
|
||||
$fd = "array('Ascent'=>".$asc;
|
||||
//Descent
|
||||
$desc = (isset($fm['Descender']) ? $fm['Descender'] : -200);
|
||||
$fd .= ",'Descent'=>".$desc;
|
||||
//CapHeight
|
||||
if (isset($fm['CapHeight']))
|
||||
$ch = $fm['CapHeight'];
|
||||
elseif (isset($fm['CapXHeight']))
|
||||
$ch = $fm['CapXHeight'];
|
||||
else
|
||||
$ch = $asc;
|
||||
$fd .= ",'CapHeight'=>".$ch;
|
||||
//Flags
|
||||
$flags = 0;
|
||||
if (isset($fm['IsFixedPitch']) && $fm['IsFixedPitch'])
|
||||
$flags += 1 << 0;
|
||||
if ($symbolic)
|
||||
$flags += 1 << 2;
|
||||
if (!$symbolic)
|
||||
$flags += 1 << 5;
|
||||
if (isset($fm['ItalicAngle']) && $fm['ItalicAngle'] != 0)
|
||||
$flags += 1 << 6;
|
||||
$fd .= ",'Flags'=>".$flags;
|
||||
//FontBBox
|
||||
if (isset($fm['FontBBox']))
|
||||
$fbb = $fm['FontBBox'];
|
||||
else
|
||||
$fbb = array(0, $desc - 100, 1000, $asc + 100);
|
||||
$fd .= ",'FontBBox'=>'[".$fbb[0].' '.$fbb[1].' '.$fbb[2].' '.$fbb[3]."]'";
|
||||
//ItalicAngle
|
||||
$ia = (isset($fm['ItalicAngle']) ? $fm['ItalicAngle'] : 0);
|
||||
$fd .= ",'ItalicAngle'=>".$ia;
|
||||
//StemV
|
||||
if (isset($fm['StdVW']))
|
||||
$stemv = $fm['StdVW'];
|
||||
elseif (isset($fm['Weight']) && preg_match('/bold|black/i', $fm['Weight']))
|
||||
$stemv = 120;
|
||||
else
|
||||
$stemv = 70;
|
||||
$fd .= ",'StemV'=>".$stemv;
|
||||
//MissingWidth
|
||||
if (isset($fm['MissingWidth']))
|
||||
$fd .= ",'MissingWidth'=>".$fm['MissingWidth'];
|
||||
$fd .= ')';
|
||||
|
||||
return $fd;
|
||||
}
|
||||
|
||||
function MakeWidthArray($fm)
|
||||
{
|
||||
//Make character width array
|
||||
$s = "array(\n\t";
|
||||
$cw = $fm['Widths'];
|
||||
for ($i = 0; $i <= 255; $i++) {
|
||||
if (chr($i) == "'")
|
||||
$s .= "'\\''";
|
||||
elseif (chr($i) == "\\")
|
||||
$s .= "'\\\\'";
|
||||
elseif ($i >= 32 && $i <= 126)
|
||||
$s .= "'".chr($i)."'";
|
||||
else
|
||||
$s .= "chr($i)";
|
||||
$s .= '=>'.$fm['Widths'][ $i ];
|
||||
if ($i < 255)
|
||||
$s .= ',';
|
||||
if (($i + 1) % 22 == 0)
|
||||
$s .= "\n\t";
|
||||
}
|
||||
$s .= ')';
|
||||
|
||||
return $s;
|
||||
}
|
||||
|
||||
function MakeFontEncoding($map)
|
||||
{
|
||||
//Build differences from reference encoding
|
||||
$ref = ReadMap('cp1252');
|
||||
$s = '';
|
||||
$last = 0;
|
||||
for ($i = 32; $i <= 255; $i++) {
|
||||
if ($map[ $i ] != $ref[ $i ]) {
|
||||
if ($i != $last + 1)
|
||||
$s .= $i.' ';
|
||||
$last = $i;
|
||||
$s .= '/'.$map[ $i ].' ';
|
||||
}
|
||||
}
|
||||
|
||||
return rtrim($s);
|
||||
}
|
||||
|
||||
function SaveToFile($file, $s, $mode)
|
||||
{
|
||||
$f = fopen($file, 'w'.$mode);
|
||||
if (!$f)
|
||||
die('Can\'t write to file '.$file);
|
||||
fwrite($f, $s, strlen($s));
|
||||
fclose($f);
|
||||
}
|
||||
|
||||
function ReadShort($f)
|
||||
{
|
||||
$a = unpack('n1n', fread($f, 2));
|
||||
|
||||
return $a['n'];
|
||||
}
|
||||
|
||||
function ReadLong($f)
|
||||
{
|
||||
$a = unpack('N1N', fread($f, 4));
|
||||
|
||||
return $a['N'];
|
||||
}
|
||||
|
||||
function CheckTTF($file)
|
||||
{
|
||||
//Check if font license allows embedding
|
||||
$f = fopen($file, 'rb');
|
||||
if (!$f)
|
||||
die('<b>Error:</b> Can\'t open '.$file);
|
||||
//Extract number of tables
|
||||
fseek($f, 4, SEEK_CUR);
|
||||
$nb = ReadShort($f);
|
||||
fseek($f, 6, SEEK_CUR);
|
||||
//Seek OS/2 table
|
||||
$found = false;
|
||||
for ($i = 0; $i < $nb; $i++) {
|
||||
if (fread($f, 4) == 'OS/2') {
|
||||
$found = true;
|
||||
break;
|
||||
}
|
||||
fseek($f, 12, SEEK_CUR);
|
||||
}
|
||||
if (!$found) {
|
||||
fclose($f);
|
||||
|
||||
return;
|
||||
}
|
||||
fseek($f, 4, SEEK_CUR);
|
||||
$offset = ReadLong($f);
|
||||
fseek($f, $offset, SEEK_SET);
|
||||
//Extract fsType flags
|
||||
fseek($f, 8, SEEK_CUR);
|
||||
$fsType = ReadShort($f);
|
||||
$rl = ($fsType & 0x02) != 0;
|
||||
$pp = ($fsType & 0x04) != 0;
|
||||
$e = ($fsType & 0x08) != 0;
|
||||
fclose($f);
|
||||
if ($rl && !$pp && !$e)
|
||||
echo '<b>Warning:</b> font license does not allow embedding';
|
||||
}
|
||||
|
||||
/*******************************************************************************
|
||||
* fontfile: path to TTF file (or empty string if not to be embedded) *
|
||||
* afmfile: path to AFM file *
|
||||
* enc: font encoding (or empty string for symbolic fonts) *
|
||||
* patch: optional patch for encoding *
|
||||
* type: font type if fontfile is empty *
|
||||
*******************************************************************************/
|
||||
function MakeFont($fontfile, $afmfile, $enc = 'cp1252', $patch = array(), $type = 'TrueType')
|
||||
{
|
||||
//Generate a font definition file
|
||||
ini_set('auto_detect_line_endings', '1');
|
||||
if ($enc) {
|
||||
$map = ReadMap($enc);
|
||||
foreach ($patch as $cc => $gn)
|
||||
$map[ $cc ] = $gn;
|
||||
} else
|
||||
$map = array();
|
||||
if (!file_exists($afmfile))
|
||||
die('<b>Error:</b> AFM file not found: '.$afmfile);
|
||||
$fm = ReadAFM($afmfile, $map);
|
||||
if ($enc)
|
||||
$diff = MakeFontEncoding($map);
|
||||
else
|
||||
$diff = '';
|
||||
$fd = MakeFontDescriptor($fm, empty($map));
|
||||
//Find font type
|
||||
if ($fontfile) {
|
||||
$ext = strtolower(substr($fontfile, -3));
|
||||
if ($ext == 'ttf')
|
||||
$type = 'TrueType';
|
||||
elseif ($ext == 'pfb')
|
||||
$type = 'Type1';
|
||||
else
|
||||
die('<b>Error:</b> unrecognized font file extension: '.$ext);
|
||||
} else {
|
||||
if ($type != 'TrueType' && $type != 'Type1')
|
||||
die('<b>Error:</b> incorrect font type: '.$type);
|
||||
}
|
||||
//Start generation
|
||||
$s = '<?php'."\n";
|
||||
$s .= '$type=\''.$type."';\n";
|
||||
$s .= '$name=\''.$fm['FontName']."';\n";
|
||||
$s .= '$desc='.$fd.";\n";
|
||||
if (!isset($fm['UnderlinePosition']))
|
||||
$fm['UnderlinePosition'] = -100;
|
||||
if (!isset($fm['UnderlineThickness']))
|
||||
$fm['UnderlineThickness'] = 50;
|
||||
$s .= '$up='.$fm['UnderlinePosition'].";\n";
|
||||
$s .= '$ut='.$fm['UnderlineThickness'].";\n";
|
||||
$w = MakeWidthArray($fm);
|
||||
$s .= '$cw='.$w.";\n";
|
||||
$s .= '$enc=\''.$enc."';\n";
|
||||
$s .= '$diff=\''.$diff."';\n";
|
||||
$basename = substr(basename($afmfile), 0, -4);
|
||||
if ($fontfile) {
|
||||
//Embedded font
|
||||
if (!file_exists($fontfile))
|
||||
die('<b>Error:</b> font file not found: '.$fontfile);
|
||||
if ($type == 'TrueType')
|
||||
CheckTTF($fontfile);
|
||||
$f = fopen($fontfile, 'rb');
|
||||
if (!$f)
|
||||
die('<b>Error:</b> Can\'t open '.$fontfile);
|
||||
$file = fread($f, filesize($fontfile));
|
||||
fclose($f);
|
||||
if ($type == 'Type1') {
|
||||
//Find first two sections and discard third one
|
||||
$header = (ord($file[0]) == 128);
|
||||
if ($header) {
|
||||
//Strip first binary header
|
||||
$file = substr($file, 6);
|
||||
}
|
||||
$pos = strpos($file, 'eexec');
|
||||
if (!$pos)
|
||||
die('<b>Error:</b> font file does not seem to be valid Type1');
|
||||
$size1 = $pos + 6;
|
||||
if ($header && ord($file[ $size1 ]) == 128) {
|
||||
//Strip second binary header
|
||||
$file = substr($file, 0, $size1).substr($file, $size1 + 6);
|
||||
}
|
||||
$pos = strpos($file, '00000000');
|
||||
if (!$pos)
|
||||
die('<b>Error:</b> font file does not seem to be valid Type1');
|
||||
$size2 = $pos - $size1;
|
||||
$file = substr($file, 0, $size1 + $size2);
|
||||
}
|
||||
if (function_exists('gzcompress')) {
|
||||
$cmp = $basename.'.z';
|
||||
SaveToFile($cmp, gzcompress($file), 'b');
|
||||
$s .= '$file=\''.$cmp."';\n";
|
||||
echo 'Font file compressed ('.$cmp.')<br>';
|
||||
} else {
|
||||
$s .= '$file=\''.basename($fontfile)."';\n";
|
||||
echo '<b>Notice:</b> font file could not be compressed (zlib extension not available)<br>';
|
||||
}
|
||||
if ($type == 'Type1') {
|
||||
$s .= '$size1='.$size1.";\n";
|
||||
$s .= '$size2='.$size2.";\n";
|
||||
} else
|
||||
$s .= '$originalsize='.filesize($fontfile).";\n";
|
||||
} else {
|
||||
//Not embedded font
|
||||
$s .= '$file='."'';\n";
|
||||
}
|
||||
$s .= "?>\n";
|
||||
SaveToFile($basename.'.php', $s, 't');
|
||||
echo 'Font definition file generated ('.$basename.'.php'.')<br>';
|
||||
}
|
23
www/modules/tntofficiel/libraries/pdf/fpdf/font/symbol.php
Normal file
23
www/modules/tntofficiel/libraries/pdf/fpdf/font/symbol.php
Normal file
@ -0,0 +1,23 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
$tntofficiel_fpdf_charwidths['symbol']=array(
|
||||
chr(0)=>250,chr(1)=>250,chr(2)=>250,chr(3)=>250,chr(4)=>250,chr(5)=>250,chr(6)=>250,chr(7)=>250,chr(8)=>250,chr(9)=>250,chr(10)=>250,chr(11)=>250,chr(12)=>250,chr(13)=>250,chr(14)=>250,chr(15)=>250,chr(16)=>250,chr(17)=>250,chr(18)=>250,chr(19)=>250,chr(20)=>250,chr(21)=>250,
|
||||
chr(22)=>250,chr(23)=>250,chr(24)=>250,chr(25)=>250,chr(26)=>250,chr(27)=>250,chr(28)=>250,chr(29)=>250,chr(30)=>250,chr(31)=>250,' '=>250,'!'=>333,'"'=>713,'#'=>500,'$'=>549,'%'=>833,'&'=>778,'\''=>439,'('=>333,')'=>333,'*'=>500,'+'=>549,
|
||||
','=>250,'-'=>549,'.'=>250,'/'=>278,'0'=>500,'1'=>500,'2'=>500,'3'=>500,'4'=>500,'5'=>500,'6'=>500,'7'=>500,'8'=>500,'9'=>500,':'=>278,';'=>278,'<'=>549,'='=>549,'>'=>549,'?'=>444,'@'=>549,'A'=>722,
|
||||
'B'=>667,'C'=>722,'D'=>612,'E'=>611,'F'=>763,'G'=>603,'H'=>722,'I'=>333,'J'=>631,'K'=>722,'L'=>686,'M'=>889,'N'=>722,'O'=>722,'P'=>768,'Q'=>741,'R'=>556,'S'=>592,'T'=>611,'U'=>690,'V'=>439,'W'=>768,
|
||||
'X'=>645,'Y'=>795,'Z'=>611,'['=>333,'\\'=>863,']'=>333,'^'=>658,'_'=>500,'`'=>500,'a'=>631,'b'=>549,'c'=>549,'d'=>494,'e'=>439,'f'=>521,'g'=>411,'h'=>603,'i'=>329,'j'=>603,'k'=>549,'l'=>549,'m'=>576,
|
||||
'n'=>521,'o'=>549,'p'=>549,'q'=>521,'r'=>549,'s'=>603,'t'=>439,'u'=>576,'v'=>713,'w'=>686,'x'=>493,'y'=>686,'z'=>494,'{'=>480,'|'=>200,'}'=>480,'~'=>549,chr(127)=>0,chr(128)=>0,chr(129)=>0,chr(130)=>0,chr(131)=>0,
|
||||
chr(132)=>0,chr(133)=>0,chr(134)=>0,chr(135)=>0,chr(136)=>0,chr(137)=>0,chr(138)=>0,chr(139)=>0,chr(140)=>0,chr(141)=>0,chr(142)=>0,chr(143)=>0,chr(144)=>0,chr(145)=>0,chr(146)=>0,chr(147)=>0,chr(148)=>0,chr(149)=>0,chr(150)=>0,chr(151)=>0,chr(152)=>0,chr(153)=>0,
|
||||
chr(154)=>0,chr(155)=>0,chr(156)=>0,chr(157)=>0,chr(158)=>0,chr(159)=>0,chr(160)=>750,chr(161)=>620,chr(162)=>247,chr(163)=>549,chr(164)=>167,chr(165)=>713,chr(166)=>500,chr(167)=>753,chr(168)=>753,chr(169)=>753,chr(170)=>753,chr(171)=>1042,chr(172)=>987,chr(173)=>603,chr(174)=>987,chr(175)=>603,
|
||||
chr(176)=>400,chr(177)=>549,chr(178)=>411,chr(179)=>549,chr(180)=>549,chr(181)=>713,chr(182)=>494,chr(183)=>460,chr(184)=>549,chr(185)=>549,chr(186)=>549,chr(187)=>549,chr(188)=>1000,chr(189)=>603,chr(190)=>1000,chr(191)=>658,chr(192)=>823,chr(193)=>686,chr(194)=>795,chr(195)=>987,chr(196)=>768,chr(197)=>768,
|
||||
chr(198)=>823,chr(199)=>768,chr(200)=>768,chr(201)=>713,chr(202)=>713,chr(203)=>713,chr(204)=>713,chr(205)=>713,chr(206)=>713,chr(207)=>713,chr(208)=>768,chr(209)=>713,chr(210)=>790,chr(211)=>790,chr(212)=>890,chr(213)=>823,chr(214)=>549,chr(215)=>250,chr(216)=>713,chr(217)=>603,chr(218)=>603,chr(219)=>1042,
|
||||
chr(220)=>987,chr(221)=>603,chr(222)=>987,chr(223)=>603,chr(224)=>494,chr(225)=>329,chr(226)=>790,chr(227)=>790,chr(228)=>786,chr(229)=>713,chr(230)=>384,chr(231)=>384,chr(232)=>384,chr(233)=>384,chr(234)=>384,chr(235)=>384,chr(236)=>494,chr(237)=>494,chr(238)=>494,chr(239)=>494,chr(240)=>0,chr(241)=>329,
|
||||
chr(242)=>274,chr(243)=>686,chr(244)=>686,chr(245)=>686,chr(246)=>384,chr(247)=>384,chr(248)=>384,chr(249)=>384,chr(250)=>384,chr(251)=>384,chr(252)=>494,chr(253)=>494,chr(254)=>494,chr(255)=>0
|
||||
);
|
23
www/modules/tntofficiel/libraries/pdf/fpdf/font/times.php
Normal file
23
www/modules/tntofficiel/libraries/pdf/fpdf/font/times.php
Normal file
@ -0,0 +1,23 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
$tntofficiel_fpdf_charwidths['times']=array(
|
||||
chr(0)=>250,chr(1)=>250,chr(2)=>250,chr(3)=>250,chr(4)=>250,chr(5)=>250,chr(6)=>250,chr(7)=>250,chr(8)=>250,chr(9)=>250,chr(10)=>250,chr(11)=>250,chr(12)=>250,chr(13)=>250,chr(14)=>250,chr(15)=>250,chr(16)=>250,chr(17)=>250,chr(18)=>250,chr(19)=>250,chr(20)=>250,chr(21)=>250,
|
||||
chr(22)=>250,chr(23)=>250,chr(24)=>250,chr(25)=>250,chr(26)=>250,chr(27)=>250,chr(28)=>250,chr(29)=>250,chr(30)=>250,chr(31)=>250,' '=>250,'!'=>333,'"'=>408,'#'=>500,'$'=>500,'%'=>833,'&'=>778,'\''=>180,'('=>333,')'=>333,'*'=>500,'+'=>564,
|
||||
','=>250,'-'=>333,'.'=>250,'/'=>278,'0'=>500,'1'=>500,'2'=>500,'3'=>500,'4'=>500,'5'=>500,'6'=>500,'7'=>500,'8'=>500,'9'=>500,':'=>278,';'=>278,'<'=>564,'='=>564,'>'=>564,'?'=>444,'@'=>921,'A'=>722,
|
||||
'B'=>667,'C'=>667,'D'=>722,'E'=>611,'F'=>556,'G'=>722,'H'=>722,'I'=>333,'J'=>389,'K'=>722,'L'=>611,'M'=>889,'N'=>722,'O'=>722,'P'=>556,'Q'=>722,'R'=>667,'S'=>556,'T'=>611,'U'=>722,'V'=>722,'W'=>944,
|
||||
'X'=>722,'Y'=>722,'Z'=>611,'['=>333,'\\'=>278,']'=>333,'^'=>469,'_'=>500,'`'=>333,'a'=>444,'b'=>500,'c'=>444,'d'=>500,'e'=>444,'f'=>333,'g'=>500,'h'=>500,'i'=>278,'j'=>278,'k'=>500,'l'=>278,'m'=>778,
|
||||
'n'=>500,'o'=>500,'p'=>500,'q'=>500,'r'=>333,'s'=>389,'t'=>278,'u'=>500,'v'=>500,'w'=>722,'x'=>500,'y'=>500,'z'=>444,'{'=>480,'|'=>200,'}'=>480,'~'=>541,chr(127)=>350,chr(128)=>500,chr(129)=>350,chr(130)=>333,chr(131)=>500,
|
||||
chr(132)=>444,chr(133)=>1000,chr(134)=>500,chr(135)=>500,chr(136)=>333,chr(137)=>1000,chr(138)=>556,chr(139)=>333,chr(140)=>889,chr(141)=>350,chr(142)=>611,chr(143)=>350,chr(144)=>350,chr(145)=>333,chr(146)=>333,chr(147)=>444,chr(148)=>444,chr(149)=>350,chr(150)=>500,chr(151)=>1000,chr(152)=>333,chr(153)=>980,
|
||||
chr(154)=>389,chr(155)=>333,chr(156)=>722,chr(157)=>350,chr(158)=>444,chr(159)=>722,chr(160)=>250,chr(161)=>333,chr(162)=>500,chr(163)=>500,chr(164)=>500,chr(165)=>500,chr(166)=>200,chr(167)=>500,chr(168)=>333,chr(169)=>760,chr(170)=>276,chr(171)=>500,chr(172)=>564,chr(173)=>333,chr(174)=>760,chr(175)=>333,
|
||||
chr(176)=>400,chr(177)=>564,chr(178)=>300,chr(179)=>300,chr(180)=>333,chr(181)=>500,chr(182)=>453,chr(183)=>250,chr(184)=>333,chr(185)=>300,chr(186)=>310,chr(187)=>500,chr(188)=>750,chr(189)=>750,chr(190)=>750,chr(191)=>444,chr(192)=>722,chr(193)=>722,chr(194)=>722,chr(195)=>722,chr(196)=>722,chr(197)=>722,
|
||||
chr(198)=>889,chr(199)=>667,chr(200)=>611,chr(201)=>611,chr(202)=>611,chr(203)=>611,chr(204)=>333,chr(205)=>333,chr(206)=>333,chr(207)=>333,chr(208)=>722,chr(209)=>722,chr(210)=>722,chr(211)=>722,chr(212)=>722,chr(213)=>722,chr(214)=>722,chr(215)=>564,chr(216)=>722,chr(217)=>722,chr(218)=>722,chr(219)=>722,
|
||||
chr(220)=>722,chr(221)=>722,chr(222)=>556,chr(223)=>500,chr(224)=>444,chr(225)=>444,chr(226)=>444,chr(227)=>444,chr(228)=>444,chr(229)=>444,chr(230)=>667,chr(231)=>444,chr(232)=>444,chr(233)=>444,chr(234)=>444,chr(235)=>444,chr(236)=>278,chr(237)=>278,chr(238)=>278,chr(239)=>278,chr(240)=>500,chr(241)=>500,
|
||||
chr(242)=>500,chr(243)=>500,chr(244)=>500,chr(245)=>500,chr(246)=>500,chr(247)=>564,chr(248)=>500,chr(249)=>500,chr(250)=>500,chr(251)=>500,chr(252)=>500,chr(253)=>500,chr(254)=>500,chr(255)=>500
|
||||
);
|
23
www/modules/tntofficiel/libraries/pdf/fpdf/font/timesb.php
Normal file
23
www/modules/tntofficiel/libraries/pdf/fpdf/font/timesb.php
Normal file
@ -0,0 +1,23 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
$tntofficiel_fpdf_charwidths['timesB']=array(
|
||||
chr(0)=>250,chr(1)=>250,chr(2)=>250,chr(3)=>250,chr(4)=>250,chr(5)=>250,chr(6)=>250,chr(7)=>250,chr(8)=>250,chr(9)=>250,chr(10)=>250,chr(11)=>250,chr(12)=>250,chr(13)=>250,chr(14)=>250,chr(15)=>250,chr(16)=>250,chr(17)=>250,chr(18)=>250,chr(19)=>250,chr(20)=>250,chr(21)=>250,
|
||||
chr(22)=>250,chr(23)=>250,chr(24)=>250,chr(25)=>250,chr(26)=>250,chr(27)=>250,chr(28)=>250,chr(29)=>250,chr(30)=>250,chr(31)=>250,' '=>250,'!'=>333,'"'=>555,'#'=>500,'$'=>500,'%'=>1000,'&'=>833,'\''=>278,'('=>333,')'=>333,'*'=>500,'+'=>570,
|
||||
','=>250,'-'=>333,'.'=>250,'/'=>278,'0'=>500,'1'=>500,'2'=>500,'3'=>500,'4'=>500,'5'=>500,'6'=>500,'7'=>500,'8'=>500,'9'=>500,':'=>333,';'=>333,'<'=>570,'='=>570,'>'=>570,'?'=>500,'@'=>930,'A'=>722,
|
||||
'B'=>667,'C'=>722,'D'=>722,'E'=>667,'F'=>611,'G'=>778,'H'=>778,'I'=>389,'J'=>500,'K'=>778,'L'=>667,'M'=>944,'N'=>722,'O'=>778,'P'=>611,'Q'=>778,'R'=>722,'S'=>556,'T'=>667,'U'=>722,'V'=>722,'W'=>1000,
|
||||
'X'=>722,'Y'=>722,'Z'=>667,'['=>333,'\\'=>278,']'=>333,'^'=>581,'_'=>500,'`'=>333,'a'=>500,'b'=>556,'c'=>444,'d'=>556,'e'=>444,'f'=>333,'g'=>500,'h'=>556,'i'=>278,'j'=>333,'k'=>556,'l'=>278,'m'=>833,
|
||||
'n'=>556,'o'=>500,'p'=>556,'q'=>556,'r'=>444,'s'=>389,'t'=>333,'u'=>556,'v'=>500,'w'=>722,'x'=>500,'y'=>500,'z'=>444,'{'=>394,'|'=>220,'}'=>394,'~'=>520,chr(127)=>350,chr(128)=>500,chr(129)=>350,chr(130)=>333,chr(131)=>500,
|
||||
chr(132)=>500,chr(133)=>1000,chr(134)=>500,chr(135)=>500,chr(136)=>333,chr(137)=>1000,chr(138)=>556,chr(139)=>333,chr(140)=>1000,chr(141)=>350,chr(142)=>667,chr(143)=>350,chr(144)=>350,chr(145)=>333,chr(146)=>333,chr(147)=>500,chr(148)=>500,chr(149)=>350,chr(150)=>500,chr(151)=>1000,chr(152)=>333,chr(153)=>1000,
|
||||
chr(154)=>389,chr(155)=>333,chr(156)=>722,chr(157)=>350,chr(158)=>444,chr(159)=>722,chr(160)=>250,chr(161)=>333,chr(162)=>500,chr(163)=>500,chr(164)=>500,chr(165)=>500,chr(166)=>220,chr(167)=>500,chr(168)=>333,chr(169)=>747,chr(170)=>300,chr(171)=>500,chr(172)=>570,chr(173)=>333,chr(174)=>747,chr(175)=>333,
|
||||
chr(176)=>400,chr(177)=>570,chr(178)=>300,chr(179)=>300,chr(180)=>333,chr(181)=>556,chr(182)=>540,chr(183)=>250,chr(184)=>333,chr(185)=>300,chr(186)=>330,chr(187)=>500,chr(188)=>750,chr(189)=>750,chr(190)=>750,chr(191)=>500,chr(192)=>722,chr(193)=>722,chr(194)=>722,chr(195)=>722,chr(196)=>722,chr(197)=>722,
|
||||
chr(198)=>1000,chr(199)=>722,chr(200)=>667,chr(201)=>667,chr(202)=>667,chr(203)=>667,chr(204)=>389,chr(205)=>389,chr(206)=>389,chr(207)=>389,chr(208)=>722,chr(209)=>722,chr(210)=>778,chr(211)=>778,chr(212)=>778,chr(213)=>778,chr(214)=>778,chr(215)=>570,chr(216)=>778,chr(217)=>722,chr(218)=>722,chr(219)=>722,
|
||||
chr(220)=>722,chr(221)=>722,chr(222)=>611,chr(223)=>556,chr(224)=>500,chr(225)=>500,chr(226)=>500,chr(227)=>500,chr(228)=>500,chr(229)=>500,chr(230)=>722,chr(231)=>444,chr(232)=>444,chr(233)=>444,chr(234)=>444,chr(235)=>444,chr(236)=>278,chr(237)=>278,chr(238)=>278,chr(239)=>278,chr(240)=>500,chr(241)=>556,
|
||||
chr(242)=>500,chr(243)=>500,chr(244)=>500,chr(245)=>500,chr(246)=>500,chr(247)=>570,chr(248)=>500,chr(249)=>556,chr(250)=>556,chr(251)=>556,chr(252)=>556,chr(253)=>500,chr(254)=>556,chr(255)=>500
|
||||
);
|
23
www/modules/tntofficiel/libraries/pdf/fpdf/font/timesbi.php
Normal file
23
www/modules/tntofficiel/libraries/pdf/fpdf/font/timesbi.php
Normal file
@ -0,0 +1,23 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
$tntofficiel_fpdf_charwidths['timesBI']=array(
|
||||
chr(0)=>250,chr(1)=>250,chr(2)=>250,chr(3)=>250,chr(4)=>250,chr(5)=>250,chr(6)=>250,chr(7)=>250,chr(8)=>250,chr(9)=>250,chr(10)=>250,chr(11)=>250,chr(12)=>250,chr(13)=>250,chr(14)=>250,chr(15)=>250,chr(16)=>250,chr(17)=>250,chr(18)=>250,chr(19)=>250,chr(20)=>250,chr(21)=>250,
|
||||
chr(22)=>250,chr(23)=>250,chr(24)=>250,chr(25)=>250,chr(26)=>250,chr(27)=>250,chr(28)=>250,chr(29)=>250,chr(30)=>250,chr(31)=>250,' '=>250,'!'=>389,'"'=>555,'#'=>500,'$'=>500,'%'=>833,'&'=>778,'\''=>278,'('=>333,')'=>333,'*'=>500,'+'=>570,
|
||||
','=>250,'-'=>333,'.'=>250,'/'=>278,'0'=>500,'1'=>500,'2'=>500,'3'=>500,'4'=>500,'5'=>500,'6'=>500,'7'=>500,'8'=>500,'9'=>500,':'=>333,';'=>333,'<'=>570,'='=>570,'>'=>570,'?'=>500,'@'=>832,'A'=>667,
|
||||
'B'=>667,'C'=>667,'D'=>722,'E'=>667,'F'=>667,'G'=>722,'H'=>778,'I'=>389,'J'=>500,'K'=>667,'L'=>611,'M'=>889,'N'=>722,'O'=>722,'P'=>611,'Q'=>722,'R'=>667,'S'=>556,'T'=>611,'U'=>722,'V'=>667,'W'=>889,
|
||||
'X'=>667,'Y'=>611,'Z'=>611,'['=>333,'\\'=>278,']'=>333,'^'=>570,'_'=>500,'`'=>333,'a'=>500,'b'=>500,'c'=>444,'d'=>500,'e'=>444,'f'=>333,'g'=>500,'h'=>556,'i'=>278,'j'=>278,'k'=>500,'l'=>278,'m'=>778,
|
||||
'n'=>556,'o'=>500,'p'=>500,'q'=>500,'r'=>389,'s'=>389,'t'=>278,'u'=>556,'v'=>444,'w'=>667,'x'=>500,'y'=>444,'z'=>389,'{'=>348,'|'=>220,'}'=>348,'~'=>570,chr(127)=>350,chr(128)=>500,chr(129)=>350,chr(130)=>333,chr(131)=>500,
|
||||
chr(132)=>500,chr(133)=>1000,chr(134)=>500,chr(135)=>500,chr(136)=>333,chr(137)=>1000,chr(138)=>556,chr(139)=>333,chr(140)=>944,chr(141)=>350,chr(142)=>611,chr(143)=>350,chr(144)=>350,chr(145)=>333,chr(146)=>333,chr(147)=>500,chr(148)=>500,chr(149)=>350,chr(150)=>500,chr(151)=>1000,chr(152)=>333,chr(153)=>1000,
|
||||
chr(154)=>389,chr(155)=>333,chr(156)=>722,chr(157)=>350,chr(158)=>389,chr(159)=>611,chr(160)=>250,chr(161)=>389,chr(162)=>500,chr(163)=>500,chr(164)=>500,chr(165)=>500,chr(166)=>220,chr(167)=>500,chr(168)=>333,chr(169)=>747,chr(170)=>266,chr(171)=>500,chr(172)=>606,chr(173)=>333,chr(174)=>747,chr(175)=>333,
|
||||
chr(176)=>400,chr(177)=>570,chr(178)=>300,chr(179)=>300,chr(180)=>333,chr(181)=>576,chr(182)=>500,chr(183)=>250,chr(184)=>333,chr(185)=>300,chr(186)=>300,chr(187)=>500,chr(188)=>750,chr(189)=>750,chr(190)=>750,chr(191)=>500,chr(192)=>667,chr(193)=>667,chr(194)=>667,chr(195)=>667,chr(196)=>667,chr(197)=>667,
|
||||
chr(198)=>944,chr(199)=>667,chr(200)=>667,chr(201)=>667,chr(202)=>667,chr(203)=>667,chr(204)=>389,chr(205)=>389,chr(206)=>389,chr(207)=>389,chr(208)=>722,chr(209)=>722,chr(210)=>722,chr(211)=>722,chr(212)=>722,chr(213)=>722,chr(214)=>722,chr(215)=>570,chr(216)=>722,chr(217)=>722,chr(218)=>722,chr(219)=>722,
|
||||
chr(220)=>722,chr(221)=>611,chr(222)=>611,chr(223)=>500,chr(224)=>500,chr(225)=>500,chr(226)=>500,chr(227)=>500,chr(228)=>500,chr(229)=>500,chr(230)=>722,chr(231)=>444,chr(232)=>444,chr(233)=>444,chr(234)=>444,chr(235)=>444,chr(236)=>278,chr(237)=>278,chr(238)=>278,chr(239)=>278,chr(240)=>500,chr(241)=>556,
|
||||
chr(242)=>500,chr(243)=>500,chr(244)=>500,chr(245)=>500,chr(246)=>500,chr(247)=>570,chr(248)=>500,chr(249)=>556,chr(250)=>556,chr(251)=>556,chr(252)=>556,chr(253)=>444,chr(254)=>500,chr(255)=>444
|
||||
);
|
23
www/modules/tntofficiel/libraries/pdf/fpdf/font/timesi.php
Normal file
23
www/modules/tntofficiel/libraries/pdf/fpdf/font/timesi.php
Normal file
@ -0,0 +1,23 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
$tntofficiel_fpdf_charwidths['timesI']=array(
|
||||
chr(0)=>250,chr(1)=>250,chr(2)=>250,chr(3)=>250,chr(4)=>250,chr(5)=>250,chr(6)=>250,chr(7)=>250,chr(8)=>250,chr(9)=>250,chr(10)=>250,chr(11)=>250,chr(12)=>250,chr(13)=>250,chr(14)=>250,chr(15)=>250,chr(16)=>250,chr(17)=>250,chr(18)=>250,chr(19)=>250,chr(20)=>250,chr(21)=>250,
|
||||
chr(22)=>250,chr(23)=>250,chr(24)=>250,chr(25)=>250,chr(26)=>250,chr(27)=>250,chr(28)=>250,chr(29)=>250,chr(30)=>250,chr(31)=>250,' '=>250,'!'=>333,'"'=>420,'#'=>500,'$'=>500,'%'=>833,'&'=>778,'\''=>214,'('=>333,')'=>333,'*'=>500,'+'=>675,
|
||||
','=>250,'-'=>333,'.'=>250,'/'=>278,'0'=>500,'1'=>500,'2'=>500,'3'=>500,'4'=>500,'5'=>500,'6'=>500,'7'=>500,'8'=>500,'9'=>500,':'=>333,';'=>333,'<'=>675,'='=>675,'>'=>675,'?'=>500,'@'=>920,'A'=>611,
|
||||
'B'=>611,'C'=>667,'D'=>722,'E'=>611,'F'=>611,'G'=>722,'H'=>722,'I'=>333,'J'=>444,'K'=>667,'L'=>556,'M'=>833,'N'=>667,'O'=>722,'P'=>611,'Q'=>722,'R'=>611,'S'=>500,'T'=>556,'U'=>722,'V'=>611,'W'=>833,
|
||||
'X'=>611,'Y'=>556,'Z'=>556,'['=>389,'\\'=>278,']'=>389,'^'=>422,'_'=>500,'`'=>333,'a'=>500,'b'=>500,'c'=>444,'d'=>500,'e'=>444,'f'=>278,'g'=>500,'h'=>500,'i'=>278,'j'=>278,'k'=>444,'l'=>278,'m'=>722,
|
||||
'n'=>500,'o'=>500,'p'=>500,'q'=>500,'r'=>389,'s'=>389,'t'=>278,'u'=>500,'v'=>444,'w'=>667,'x'=>444,'y'=>444,'z'=>389,'{'=>400,'|'=>275,'}'=>400,'~'=>541,chr(127)=>350,chr(128)=>500,chr(129)=>350,chr(130)=>333,chr(131)=>500,
|
||||
chr(132)=>556,chr(133)=>889,chr(134)=>500,chr(135)=>500,chr(136)=>333,chr(137)=>1000,chr(138)=>500,chr(139)=>333,chr(140)=>944,chr(141)=>350,chr(142)=>556,chr(143)=>350,chr(144)=>350,chr(145)=>333,chr(146)=>333,chr(147)=>556,chr(148)=>556,chr(149)=>350,chr(150)=>500,chr(151)=>889,chr(152)=>333,chr(153)=>980,
|
||||
chr(154)=>389,chr(155)=>333,chr(156)=>667,chr(157)=>350,chr(158)=>389,chr(159)=>556,chr(160)=>250,chr(161)=>389,chr(162)=>500,chr(163)=>500,chr(164)=>500,chr(165)=>500,chr(166)=>275,chr(167)=>500,chr(168)=>333,chr(169)=>760,chr(170)=>276,chr(171)=>500,chr(172)=>675,chr(173)=>333,chr(174)=>760,chr(175)=>333,
|
||||
chr(176)=>400,chr(177)=>675,chr(178)=>300,chr(179)=>300,chr(180)=>333,chr(181)=>500,chr(182)=>523,chr(183)=>250,chr(184)=>333,chr(185)=>300,chr(186)=>310,chr(187)=>500,chr(188)=>750,chr(189)=>750,chr(190)=>750,chr(191)=>500,chr(192)=>611,chr(193)=>611,chr(194)=>611,chr(195)=>611,chr(196)=>611,chr(197)=>611,
|
||||
chr(198)=>889,chr(199)=>667,chr(200)=>611,chr(201)=>611,chr(202)=>611,chr(203)=>611,chr(204)=>333,chr(205)=>333,chr(206)=>333,chr(207)=>333,chr(208)=>722,chr(209)=>667,chr(210)=>722,chr(211)=>722,chr(212)=>722,chr(213)=>722,chr(214)=>722,chr(215)=>675,chr(216)=>722,chr(217)=>722,chr(218)=>722,chr(219)=>722,
|
||||
chr(220)=>722,chr(221)=>556,chr(222)=>611,chr(223)=>500,chr(224)=>500,chr(225)=>500,chr(226)=>500,chr(227)=>500,chr(228)=>500,chr(229)=>500,chr(230)=>667,chr(231)=>444,chr(232)=>444,chr(233)=>444,chr(234)=>444,chr(235)=>444,chr(236)=>278,chr(237)=>278,chr(238)=>278,chr(239)=>278,chr(240)=>500,chr(241)=>500,
|
||||
chr(242)=>500,chr(243)=>500,chr(244)=>500,chr(245)=>500,chr(246)=>500,chr(247)=>675,chr(248)=>500,chr(249)=>500,chr(250)=>500,chr(251)=>500,chr(252)=>500,chr(253)=>444,chr(254)=>500,chr(255)=>444
|
||||
);
|
@ -0,0 +1,23 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
$tntofficiel_fpdf_charwidths['zapfdingbats']=array(
|
||||
chr(0)=>0,chr(1)=>0,chr(2)=>0,chr(3)=>0,chr(4)=>0,chr(5)=>0,chr(6)=>0,chr(7)=>0,chr(8)=>0,chr(9)=>0,chr(10)=>0,chr(11)=>0,chr(12)=>0,chr(13)=>0,chr(14)=>0,chr(15)=>0,chr(16)=>0,chr(17)=>0,chr(18)=>0,chr(19)=>0,chr(20)=>0,chr(21)=>0,
|
||||
chr(22)=>0,chr(23)=>0,chr(24)=>0,chr(25)=>0,chr(26)=>0,chr(27)=>0,chr(28)=>0,chr(29)=>0,chr(30)=>0,chr(31)=>0,' '=>278,'!'=>974,'"'=>961,'#'=>974,'$'=>980,'%'=>719,'&'=>789,'\''=>790,'('=>791,')'=>690,'*'=>960,'+'=>939,
|
||||
','=>549,'-'=>855,'.'=>911,'/'=>933,'0'=>911,'1'=>945,'2'=>974,'3'=>755,'4'=>846,'5'=>762,'6'=>761,'7'=>571,'8'=>677,'9'=>763,':'=>760,';'=>759,'<'=>754,'='=>494,'>'=>552,'?'=>537,'@'=>577,'A'=>692,
|
||||
'B'=>786,'C'=>788,'D'=>788,'E'=>790,'F'=>793,'G'=>794,'H'=>816,'I'=>823,'J'=>789,'K'=>841,'L'=>823,'M'=>833,'N'=>816,'O'=>831,'P'=>923,'Q'=>744,'R'=>723,'S'=>749,'T'=>790,'U'=>792,'V'=>695,'W'=>776,
|
||||
'X'=>768,'Y'=>792,'Z'=>759,'['=>707,'\\'=>708,']'=>682,'^'=>701,'_'=>826,'`'=>815,'a'=>789,'b'=>789,'c'=>707,'d'=>687,'e'=>696,'f'=>689,'g'=>786,'h'=>787,'i'=>713,'j'=>791,'k'=>785,'l'=>791,'m'=>873,
|
||||
'n'=>761,'o'=>762,'p'=>762,'q'=>759,'r'=>759,'s'=>892,'t'=>892,'u'=>788,'v'=>784,'w'=>438,'x'=>138,'y'=>277,'z'=>415,'{'=>392,'|'=>392,'}'=>668,'~'=>668,chr(127)=>0,chr(128)=>390,chr(129)=>390,chr(130)=>317,chr(131)=>317,
|
||||
chr(132)=>276,chr(133)=>276,chr(134)=>509,chr(135)=>509,chr(136)=>410,chr(137)=>410,chr(138)=>234,chr(139)=>234,chr(140)=>334,chr(141)=>334,chr(142)=>0,chr(143)=>0,chr(144)=>0,chr(145)=>0,chr(146)=>0,chr(147)=>0,chr(148)=>0,chr(149)=>0,chr(150)=>0,chr(151)=>0,chr(152)=>0,chr(153)=>0,
|
||||
chr(154)=>0,chr(155)=>0,chr(156)=>0,chr(157)=>0,chr(158)=>0,chr(159)=>0,chr(160)=>0,chr(161)=>732,chr(162)=>544,chr(163)=>544,chr(164)=>910,chr(165)=>667,chr(166)=>760,chr(167)=>760,chr(168)=>776,chr(169)=>595,chr(170)=>694,chr(171)=>626,chr(172)=>788,chr(173)=>788,chr(174)=>788,chr(175)=>788,
|
||||
chr(176)=>788,chr(177)=>788,chr(178)=>788,chr(179)=>788,chr(180)=>788,chr(181)=>788,chr(182)=>788,chr(183)=>788,chr(184)=>788,chr(185)=>788,chr(186)=>788,chr(187)=>788,chr(188)=>788,chr(189)=>788,chr(190)=>788,chr(191)=>788,chr(192)=>788,chr(193)=>788,chr(194)=>788,chr(195)=>788,chr(196)=>788,chr(197)=>788,
|
||||
chr(198)=>788,chr(199)=>788,chr(200)=>788,chr(201)=>788,chr(202)=>788,chr(203)=>788,chr(204)=>788,chr(205)=>788,chr(206)=>788,chr(207)=>788,chr(208)=>788,chr(209)=>788,chr(210)=>788,chr(211)=>788,chr(212)=>894,chr(213)=>838,chr(214)=>1016,chr(215)=>458,chr(216)=>748,chr(217)=>924,chr(218)=>748,chr(219)=>918,
|
||||
chr(220)=>927,chr(221)=>928,chr(222)=>928,chr(223)=>834,chr(224)=>873,chr(225)=>828,chr(226)=>924,chr(227)=>924,chr(228)=>917,chr(229)=>930,chr(230)=>931,chr(231)=>463,chr(232)=>883,chr(233)=>836,chr(234)=>836,chr(235)=>867,chr(236)=>867,chr(237)=>696,chr(238)=>696,chr(239)=>874,chr(240)=>0,chr(241)=>874,
|
||||
chr(242)=>760,chr(243)=>946,chr(244)=>771,chr(245)=>865,chr(246)=>771,chr(247)=>888,chr(248)=>967,chr(249)=>888,chr(250)=>831,chr(251)=>873,chr(252)=>927,chr(253)=>970,chr(254)=>918,chr(255)=>0
|
||||
);
|
21
www/modules/tntofficiel/libraries/pdf/fpdf/fpdf.css
Normal file
21
www/modules/tntofficiel/libraries/pdf/fpdf/fpdf.css
Normal file
@ -0,0 +1,21 @@
|
||||
body {font-family:"Times New Roman",serif}
|
||||
h1 {font:bold 135% Arial,sans-serif; color:#4000A0; margin-bottom:0.9em}
|
||||
h2 {font:bold 95% Arial,sans-serif; color:#900000; margin-top:1.5em; margin-bottom:1em}
|
||||
dl.param dt {text-decoration:underline}
|
||||
dl.param dd {margin-top:1em; margin-bottom:1em}
|
||||
dl.param ul {margin-top:1em; margin-bottom:1em}
|
||||
tt, code, kbd {font-family:"Courier New",Courier,monospace; font-size:82%}
|
||||
div.source {margin-top:1.4em; margin-bottom:1.3em}
|
||||
div.source pre {display:table; border:1px solid #24246A; width:100%; margin:0em; font-family:inherit; font-size:100%}
|
||||
div.source code {display:block; border:1px solid #C5C5EC; background-color:#F0F5FF; padding:6px; color:#000000}
|
||||
div.doc-source {margin-top:1.4em; margin-bottom:1.3em}
|
||||
div.doc-source pre {display:table; width:100%; margin:0em; font-family:inherit; font-size:100%}
|
||||
div.doc-source code {display:block; background-color:#E0E0E0; padding:4px}
|
||||
.kw {color:#000080; font-weight:bold}
|
||||
.str {color:#CC0000}
|
||||
.cmt {color:#008000}
|
||||
p.demo {text-align:center; margin-top:-0.9em}
|
||||
a.demo {text-decoration:none; font-weight:bold; color:#0000CC}
|
||||
a.demo:link {text-decoration:none; font-weight:bold; color:#0000CC}
|
||||
a.demo:hover {text-decoration:none; font-weight:bold; color:#0000FF}
|
||||
a.demo:active {text-decoration:none; font-weight:bold; color:#0000FF}
|
18
www/modules/tntofficiel/libraries/pdf/fpdf/index.php
Normal file
18
www/modules/tntofficiel/libraries/pdf/fpdf/index.php
Normal file
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../');
|
||||
exit;
|
184
www/modules/tntofficiel/libraries/pdf/fpdi/TNTOfficiel_FPDF2.php
Normal file
184
www/modules/tntofficiel/libraries/pdf/fpdi/TNTOfficiel_FPDF2.php
Normal file
@ -0,0 +1,184 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
//
|
||||
// FPDI - Version 1.3.1
|
||||
//
|
||||
// Copyright 2004-2009 Setasign - Jan Slabon
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
|
||||
/**
|
||||
* This class is used as a bridge between TCPDF and FPDI
|
||||
* and will create the possibility to use both FPDF and TCPDF
|
||||
* via one FPDI version.
|
||||
*
|
||||
* We'll simply remap TCPDF to FPDF again.
|
||||
*
|
||||
* It'll be loaded and extended by FPDF_TPL.
|
||||
*/
|
||||
class TNTOfficiel_FPDF2 extends TNTOfficiel_TCPDF {
|
||||
|
||||
public function __get($name) {
|
||||
switch ($name) {
|
||||
case 'PDFVersion':
|
||||
return $this->PDFVersion;
|
||||
case 'k':
|
||||
return $this->k;
|
||||
default:
|
||||
// Error handling
|
||||
$this->Error('Cannot access protected property '.get_class($this).':$'.$name.' / Undefined property: '.get_class($this).'::$'.$name);
|
||||
}
|
||||
}
|
||||
|
||||
public function __set($name, $value)
|
||||
{
|
||||
switch ($name) {
|
||||
case 'PDFVersion':
|
||||
$this->PDFVersion = $value;
|
||||
break;
|
||||
default:
|
||||
// Error handling
|
||||
$this->Error('Cannot access protected property '.get_class($this).':$'.$name.' / Undefined property: '.get_class($this).'::$'.$name);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Encryption of imported data by FPDI
|
||||
*
|
||||
* @param array $value
|
||||
*/
|
||||
public function pdf_write_value(&$value)
|
||||
{
|
||||
switch ($value[0]) {
|
||||
case PDF_TYPE_STRING :
|
||||
if ($this->encrypted) {
|
||||
$value[1] = $this->_unescape($value[1]);
|
||||
$value[1] = $this->_RC4($this->_objectkey($this->_current_obj_id), $value[1]);
|
||||
$value[1] = $this->_escape($value[1]);
|
||||
}
|
||||
break;
|
||||
|
||||
case PDF_TYPE_STREAM :
|
||||
if ($this->encrypted) {
|
||||
$value[2][1] = $this->_RC4($this->_objectkey($this->_current_obj_id), $value[2][1]);
|
||||
}
|
||||
break;
|
||||
|
||||
case PDF_TYPE_HEX :
|
||||
if ($this->encrypted) {
|
||||
$value[1] = $this->hex2str($value[1]);
|
||||
$value[1] = $this->_RC4($this->_objectkey($this->_current_obj_id), $value[1]);
|
||||
|
||||
// remake hexstring of encrypted string
|
||||
$value[1] = $this->str2hex($value[1]);
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Unescapes a PDF string
|
||||
*
|
||||
* @param string $s
|
||||
* @return string
|
||||
*/
|
||||
public function _unescape($s)
|
||||
{
|
||||
$out = '';
|
||||
for ($count = 0, $n = strlen($s); $count < $n; $count++) {
|
||||
if ($s[$count] != '\\' || $count == $n-1) {
|
||||
$out .= $s[$count];
|
||||
} else {
|
||||
switch ($s[++$count]) {
|
||||
case ')':
|
||||
case '(':
|
||||
case '\\':
|
||||
$out .= $s[$count];
|
||||
break;
|
||||
case 'f':
|
||||
$out .= chr(0x0C);
|
||||
break;
|
||||
case 'b':
|
||||
$out .= chr(0x08);
|
||||
break;
|
||||
case 't':
|
||||
$out .= chr(0x09);
|
||||
break;
|
||||
case 'r':
|
||||
$out .= chr(0x0D);
|
||||
break;
|
||||
case 'n':
|
||||
$out .= chr(0x0A);
|
||||
break;
|
||||
case "\r":
|
||||
if ($count != $n-1 && $s[$count+1] == "\n")
|
||||
$count++;
|
||||
break;
|
||||
case "\n":
|
||||
break;
|
||||
default:
|
||||
// Octal-Values
|
||||
if (ord($s[$count]) >= ord('0') &&
|
||||
ord($s[$count]) <= ord('9')) {
|
||||
$oct = ''. $s[$count];
|
||||
|
||||
if (ord($s[$count+1]) >= ord('0') &&
|
||||
ord($s[$count+1]) <= ord('9')) {
|
||||
$oct .= $s[++$count];
|
||||
|
||||
if (ord($s[$count+1]) >= ord('0') &&
|
||||
ord($s[$count+1]) <= ord('9')) {
|
||||
$oct .= $s[++$count];
|
||||
}
|
||||
}
|
||||
|
||||
$out .= chr(octdec($oct));
|
||||
} else {
|
||||
$out .= $s[$count];
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return $out;
|
||||
}
|
||||
|
||||
/**
|
||||
* Hexadecimal to string
|
||||
*
|
||||
* @param string $hex
|
||||
* @return string
|
||||
*/
|
||||
public function hex2str($hex)
|
||||
{
|
||||
return pack('H*', str_replace(array("\r", "\n", ' '), '', $hex));
|
||||
}
|
||||
|
||||
/**
|
||||
* String to hexadecimal
|
||||
*
|
||||
* @param string $str
|
||||
* @return string
|
||||
*/
|
||||
public function str2hex($str)
|
||||
{
|
||||
return current(unpack('H*', $str));
|
||||
}
|
||||
}
|
@ -0,0 +1,431 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
//
|
||||
// FPDF_TPL - Version 1.1.3
|
||||
//
|
||||
// Copyright 2004-2009 Setasign - Jan Slabon
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
|
||||
class TNTOfficiel_FPDF_TPL extends TNTOfficiel_FPDF {
|
||||
/**
|
||||
* Array of Tpl-Data
|
||||
* @var array
|
||||
*/
|
||||
var $tpls = array();
|
||||
|
||||
/**
|
||||
* Current Template-ID
|
||||
* @var int
|
||||
*/
|
||||
var $tpl = 0;
|
||||
|
||||
/**
|
||||
* "In Template"-Flag
|
||||
* @var boolean
|
||||
*/
|
||||
var $_intpl = false;
|
||||
|
||||
/**
|
||||
* Nameprefix of Templates used in Resources-Dictonary
|
||||
* @var string A String defining the Prefix used as Template-Object-Names. Have to beginn with an /
|
||||
*/
|
||||
var $tplprefix = "/TPL";
|
||||
|
||||
/**
|
||||
* Resources used By Templates and Pages
|
||||
* @var array
|
||||
*/
|
||||
var $_res = array();
|
||||
|
||||
/**
|
||||
* Last used Template data
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
var $lastUsedTemplateData = array();
|
||||
|
||||
/**
|
||||
* Start a Template
|
||||
*
|
||||
* This method starts a template. You can give own coordinates to build an own sized
|
||||
* Template. Pay attention, that the margins are adapted to the new templatesize.
|
||||
* If you want to write outside the template, for example to build a clipped Template,
|
||||
* you have to set the Margins and "Cursor"-Position manual after beginTemplate-Call.
|
||||
*
|
||||
* If no parameter is given, the template uses the current page-size.
|
||||
* The Method returns an ID of the current Template. This ID is used later for using this template.
|
||||
* Warning: A created Template is used in PDF at all events. Still if you don't use it after creation!
|
||||
*
|
||||
* @param int $x The x-coordinate given in user-unit
|
||||
* @param int $y The y-coordinate given in user-unit
|
||||
* @param int $w The width given in user-unit
|
||||
* @param int $h The height given in user-unit
|
||||
* @return int The ID of new created Template
|
||||
*/
|
||||
public function beginTemplate($x=null, $y=null, $w=null, $h=null)
|
||||
{
|
||||
if ($this->page <= 0)
|
||||
$this->error("You have to add a page to fpdf first!");
|
||||
|
||||
if ($x == null)
|
||||
$x = 0;
|
||||
if ($y == null)
|
||||
$y = 0;
|
||||
if ($w == null)
|
||||
$w = $this->w;
|
||||
if ($h == null)
|
||||
$h = $this->h;
|
||||
|
||||
// Save settings
|
||||
$this->tpl++;
|
||||
$tpl =& $this->tpls[$this->tpl];
|
||||
$tpl = array(
|
||||
'o_x' => $this->x,
|
||||
'o_y' => $this->y,
|
||||
'o_AutoPageBreak' => $this->AutoPageBreak,
|
||||
'o_bMargin' => $this->bMargin,
|
||||
'o_tMargin' => $this->tMargin,
|
||||
'o_lMargin' => $this->lMargin,
|
||||
'o_rMargin' => $this->rMargin,
|
||||
'o_h' => $this->h,
|
||||
'o_w' => $this->w,
|
||||
'buffer' => '',
|
||||
'x' => $x,
|
||||
'y' => $y,
|
||||
'w' => $w,
|
||||
'h' => $h
|
||||
);
|
||||
|
||||
$this->SetAutoPageBreak(false);
|
||||
|
||||
// Define own high and width to calculate possitions correct
|
||||
$this->h = $h;
|
||||
$this->w = $w;
|
||||
|
||||
$this->_intpl = true;
|
||||
$this->SetXY($x+$this->lMargin, $y+$this->tMargin);
|
||||
$this->SetRightMargin($this->w-$w+$this->rMargin);
|
||||
|
||||
return $this->tpl;
|
||||
}
|
||||
|
||||
/**
|
||||
* End Template
|
||||
*
|
||||
* This method ends a template and reset initiated variables on beginTemplate.
|
||||
*
|
||||
* @return mixed If a template is opened, the ID is returned. If not a false is returned.
|
||||
*/
|
||||
public function endTemplate()
|
||||
{
|
||||
if ($this->_intpl) {
|
||||
$this->_intpl = false;
|
||||
$tpl =& $this->tpls[$this->tpl];
|
||||
$this->SetXY($tpl['o_x'], $tpl['o_y']);
|
||||
$this->tMargin = $tpl['o_tMargin'];
|
||||
$this->lMargin = $tpl['o_lMargin'];
|
||||
$this->rMargin = $tpl['o_rMargin'];
|
||||
$this->h = $tpl['o_h'];
|
||||
$this->w = $tpl['o_w'];
|
||||
$this->SetAutoPageBreak($tpl['o_AutoPageBreak'], $tpl['o_bMargin']);
|
||||
|
||||
return $this->tpl;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Use a Template in current Page or other Template
|
||||
*
|
||||
* You can use a template in a page or in another template.
|
||||
* You can give the used template a new size like you use the Image()-method.
|
||||
* All parameters are optional. The width or height is calculated automaticaly
|
||||
* if one is given. If no parameter is given the origin size as defined in
|
||||
* beginTemplate() is used.
|
||||
* The calculated or used width and height are returned as an array.
|
||||
*
|
||||
* @param int $tplidx A valid template-Id
|
||||
* @param int $_x The x-position
|
||||
* @param int $_y The y-position
|
||||
* @param int $_w The new width of the template
|
||||
* @param int $_h The new height of the template
|
||||
* @retrun array The height and width of the template
|
||||
*/
|
||||
public function useTemplate($tplidx, $_x=null, $_y=null, $_w=0, $_h=0)
|
||||
{
|
||||
if ($this->page <= 0)
|
||||
$this->error("You have to add a page to fpdf first!");
|
||||
|
||||
if (!isset($this->tpls[$tplidx]))
|
||||
$this->error("Template does not exist!");
|
||||
|
||||
if ($this->_intpl) {
|
||||
$this->_res['tpl'][$this->tpl]['tpls'][$tplidx] =& $this->tpls[$tplidx];
|
||||
}
|
||||
|
||||
$tpl =& $this->tpls[$tplidx];
|
||||
$w = $tpl['w'];
|
||||
$h = $tpl['h'];
|
||||
|
||||
if ($_x == null)
|
||||
$_x = 0;
|
||||
if ($_y == null)
|
||||
$_y = 0;
|
||||
|
||||
$_x += $tpl['x'];
|
||||
$_y += $tpl['y'];
|
||||
|
||||
$wh = $this->getTemplateSize($tplidx, $_w, $_h);
|
||||
$_w = $wh['w'];
|
||||
$_h = $wh['h'];
|
||||
|
||||
$tData = array(
|
||||
'x' => $this->x,
|
||||
'y' => $this->y,
|
||||
'w' => $_w,
|
||||
'h' => $_h,
|
||||
'scaleX' => ($_w/$w),
|
||||
'scaleY' => ($_h/$h),
|
||||
'tx' => $_x,
|
||||
'ty' => ($this->h-$_y-$_h),
|
||||
'lty' => ($this->h-$_y-$_h) - ($this->h-$h) * ($_h/$h)
|
||||
);
|
||||
|
||||
$this->_out(sprintf("q %.4F 0 0 %.4F %.4F %.4F cm", $tData['scaleX'], $tData['scaleY'], $tData['tx']*$this->k, $tData['ty']*$this->k)); // Translate
|
||||
$this->_out(sprintf('%s%d Do Q', $this->tplprefix, $tplidx));
|
||||
|
||||
$this->lastUsedTemplateData = $tData;
|
||||
|
||||
return array("w" => $_w, "h" => $_h);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get The calculated Size of a Template
|
||||
*
|
||||
* If one size is given, this method calculates the other one.
|
||||
*
|
||||
* @param int $tplidx A valid template-Id
|
||||
* @param int $_w The width of the template
|
||||
* @param int $_h The height of the template
|
||||
* @return array The height and width of the template
|
||||
*/
|
||||
public function getTemplateSize($tplidx, $_w=0, $_h=0)
|
||||
{
|
||||
if (!$this->tpls[$tplidx])
|
||||
return false;
|
||||
|
||||
$tpl =& $this->tpls[$tplidx];
|
||||
$w = $tpl['w'];
|
||||
$h = $tpl['h'];
|
||||
|
||||
if ($_w == 0 and $_h == 0) {
|
||||
$_w = $w;
|
||||
$_h = $h;
|
||||
}
|
||||
|
||||
if($_w==0)
|
||||
$_w = $_h*$w/$h;
|
||||
if($_h==0)
|
||||
$_h = $_w*$h/$w;
|
||||
|
||||
return array("w" => $_w, "h" => $_h);
|
||||
}
|
||||
|
||||
/**
|
||||
* See FPDF/TCPDF-Documentation ;-)
|
||||
*/
|
||||
public function SetFont($family, $style='', $size=0, $fontfile='')
|
||||
{
|
||||
if (!is_subclass_of($this, 'TNTOfficiel_TCPDF') && func_num_args() > 3) {
|
||||
$this->Error('More than 3 arguments for the SetFont method are only available in TNTOfficiel_TCPDF.');
|
||||
}
|
||||
/**
|
||||
* force the resetting of font changes in a template
|
||||
*/
|
||||
if ($this->_intpl)
|
||||
$this->FontFamily = '';
|
||||
|
||||
parent::SetFont($family, $style, $size, $fontfile);
|
||||
|
||||
$fontkey = $this->FontFamily.$this->FontStyle;
|
||||
|
||||
if ($this->_intpl) {
|
||||
$this->_res['tpl'][$this->tpl]['fonts'][$fontkey] =& $this->fonts[$fontkey];
|
||||
} else {
|
||||
$this->_res['page'][$this->page]['fonts'][$fontkey] =& $this->fonts[$fontkey];
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* See FPDF/TCPDF-Documentation ;-)
|
||||
*/
|
||||
public function Image($file, $x = NULL, $y = NULL, $w=0, $h=0, $type='', $link='', $align='', $resize=false, $dpi=300, $palign='', $ismask=false, $imgmask=false, $border=0)
|
||||
{
|
||||
if (!is_subclass_of($this, 'TNTOfficiel_TCPDF') && func_num_args() > 7) {
|
||||
$this->Error('More than 7 arguments for the Image method are only available in TNTOfficiel_TCPDF.');
|
||||
}
|
||||
|
||||
parent::Image($file, $x, $y, $w, $h, $type, $link, $align, $resize, $dpi, $palign, $ismask, $imgmask, $border);
|
||||
if ($this->_intpl) {
|
||||
$this->_res['tpl'][$this->tpl]['images'][$file] =& $this->images[$file];
|
||||
} else {
|
||||
$this->_res['page'][$this->page]['images'][$file] =& $this->images[$file];
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* See FPDF-Documentation ;-)
|
||||
*
|
||||
* AddPage is not available when you're "in" a template.
|
||||
*/
|
||||
public function AddPage($orientation='', $format='')
|
||||
{
|
||||
if ($this->_intpl)
|
||||
$this->Error('Adding pages in templates isn\'t possible!');
|
||||
parent::AddPage($orientation, $format);
|
||||
}
|
||||
|
||||
/**
|
||||
* Preserve adding Links in Templates ...won't work
|
||||
*/
|
||||
public function Link($x, $y, $w, $h, $link, $spaces=0)
|
||||
{
|
||||
if (!is_subclass_of($this, 'TNTOfficiel_TCPDF') && func_num_args() > 5) {
|
||||
$this->Error('More than 7 arguments for the Image method are only available in TNTOfficiel_TCPDF.');
|
||||
}
|
||||
|
||||
if ($this->_intpl)
|
||||
$this->Error('Using links in templates aren\'t possible!');
|
||||
parent::Link($x, $y, $w, $h, $link, $spaces);
|
||||
}
|
||||
|
||||
public function AddLink()
|
||||
{
|
||||
if ($this->_intpl)
|
||||
$this->Error('Adding links in templates aren\'t possible!');
|
||||
return parent::AddLink();
|
||||
}
|
||||
|
||||
public function SetLink($link, $y=0, $page=-1)
|
||||
{
|
||||
if ($this->_intpl)
|
||||
$this->Error('Setting links in templates aren\'t possible!');
|
||||
parent::SetLink($link, $y, $page);
|
||||
}
|
||||
|
||||
/**
|
||||
* Private Method that writes the form xobjects
|
||||
*/
|
||||
public function _putformxobjects()
|
||||
{
|
||||
$filter=($this->compress) ? '/Filter /FlateDecode ' : '';
|
||||
reset($this->tpls);
|
||||
foreach($this->tpls AS $tplidx => $tpl) {
|
||||
|
||||
$p=($this->compress) ? gzcompress($tpl['buffer']) : $tpl['buffer'];
|
||||
$this->_newobj();
|
||||
$this->tpls[$tplidx]['n'] = $this->n;
|
||||
$this->_out('<<'.$filter.'/Type /XObject');
|
||||
$this->_out('/Subtype /Form');
|
||||
$this->_out('/FormType 1');
|
||||
$this->_out(sprintf('/BBox [%.2F %.2F %.2F %.2F]',
|
||||
// llx
|
||||
$tpl['x'],
|
||||
// lly
|
||||
-$tpl['y'],
|
||||
// urx
|
||||
($tpl['w']+$tpl['x'])*$this->k,
|
||||
// ury
|
||||
($tpl['h']-$tpl['y'])*$this->k
|
||||
));
|
||||
|
||||
if ($tpl['x'] != 0 || $tpl['y'] != 0) {
|
||||
$this->_out(sprintf('/Matrix [1 0 0 1 %.5F %.5F]',
|
||||
-$tpl['x']*$this->k*2, $tpl['y']*$this->k*2
|
||||
));
|
||||
}
|
||||
|
||||
$this->_out('/Resources ');
|
||||
|
||||
$this->_out('<</ProcSet [/PDF /Text /ImageB /ImageC /ImageI]');
|
||||
if (isset($this->_res['tpl'][$tplidx]['fonts']) && count($this->_res['tpl'][$tplidx]['fonts'])) {
|
||||
$this->_out('/Font <<');
|
||||
foreach($this->_res['tpl'][$tplidx]['fonts'] as $font)
|
||||
$this->_out('/F'.$font['i'].' '.$font['n'].' 0 R');
|
||||
$this->_out('>>');
|
||||
}
|
||||
if(isset($this->_res['tpl'][$tplidx]['images']) && count($this->_res['tpl'][$tplidx]['images']) ||
|
||||
isset($this->_res['tpl'][$tplidx]['tpls']) && count($this->_res['tpl'][$tplidx]['tpls']))
|
||||
{
|
||||
$this->_out('/XObject <<');
|
||||
if (isset($this->_res['tpl'][$tplidx]['images']) && count($this->_res['tpl'][$tplidx]['images'])) {
|
||||
foreach($this->_res['tpl'][$tplidx]['images'] as $image)
|
||||
$this->_out('/I'.$image['i'].' '.$image['n'].' 0 R');
|
||||
}
|
||||
if (isset($this->_res['tpl'][$tplidx]['tpls']) && count($this->_res['tpl'][$tplidx]['tpls'])) {
|
||||
foreach($this->_res['tpl'][$tplidx]['tpls'] as $i => $tpl)
|
||||
$this->_out($this->tplprefix.$i.' '.$tpl['n'].' 0 R');
|
||||
}
|
||||
$this->_out('>>');
|
||||
}
|
||||
$this->_out('>>');
|
||||
|
||||
$this->_out('/Length '.strlen($p).' >>');
|
||||
$this->_putstream($p);
|
||||
$this->_out('endobj');
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Overwritten to add _putformxobjects() after _putimages()
|
||||
*
|
||||
*/
|
||||
public function _putimages()
|
||||
{
|
||||
parent::_putimages();
|
||||
$this->_putformxobjects();
|
||||
}
|
||||
|
||||
public function _putxobjectdict()
|
||||
{
|
||||
parent::_putxobjectdict();
|
||||
|
||||
if (count($this->tpls)) {
|
||||
foreach($this->tpls as $tplidx => $tpl) {
|
||||
$this->_out(sprintf('%s%d %d 0 R', $this->tplprefix, $tplidx, $tpl['n']));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Private Method
|
||||
*/
|
||||
public function _out($s)
|
||||
{
|
||||
if ($this->state==2 && $this->_intpl) {
|
||||
$this->tpls[$this->tpl]['buffer'] .= $s."\n";
|
||||
} else {
|
||||
parent::_out($s);
|
||||
}
|
||||
}
|
||||
}
|
522
www/modules/tntofficiel/libraries/pdf/fpdi/TNTOfficiel_FPDI.php
Normal file
522
www/modules/tntofficiel/libraries/pdf/fpdi/TNTOfficiel_FPDI.php
Normal file
@ -0,0 +1,522 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
//
|
||||
// FPDI - Version 1.3.1
|
||||
//
|
||||
// Copyright 2004-2009 Setasign - Jan Slabon
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
|
||||
define('TNTOFFICIEL_FPDI_VERSION','1.3.1');
|
||||
|
||||
// Check for TCPDF and remap TCPDF to FPDF
|
||||
if (class_exists('TNTOfficiel_TCPDF')) {
|
||||
require_once('TNTOfficiel_FPDF2.php');
|
||||
}
|
||||
|
||||
require_once('TNTOfficiel_FPDF_TPL.php');
|
||||
require_once('TNTOfficiel_fpdi_pdf_parser.php');
|
||||
|
||||
|
||||
class TNTOfficiel_FPDI extends TNTOfficiel_FPDF_TPL {
|
||||
/**
|
||||
* Actual filename
|
||||
* @var string
|
||||
*/
|
||||
var $current_filename;
|
||||
|
||||
/**
|
||||
* Parser-Objects
|
||||
* @var array
|
||||
*/
|
||||
var $parsers;
|
||||
|
||||
/**
|
||||
* Current parser
|
||||
* @var object
|
||||
*/
|
||||
var $current_parser;
|
||||
|
||||
/**
|
||||
* object stack
|
||||
* @var array
|
||||
*/
|
||||
var $_obj_stack;
|
||||
|
||||
/**
|
||||
* done object stack
|
||||
* @var array
|
||||
*/
|
||||
var $_don_obj_stack;
|
||||
|
||||
/**
|
||||
* Current Object Id.
|
||||
* @var integer
|
||||
*/
|
||||
var $_current_obj_id;
|
||||
|
||||
/**
|
||||
* The name of the last imported page box
|
||||
* @var string
|
||||
*/
|
||||
var $lastUsedPageBox;
|
||||
|
||||
var $_importedPages = array();
|
||||
|
||||
|
||||
/**
|
||||
* Set a source-file
|
||||
*
|
||||
* @param string $filename a valid filename
|
||||
* @return int number of available pages
|
||||
*/
|
||||
public function setSourceFile($filename)
|
||||
{
|
||||
$this->current_filename = $filename;
|
||||
$fn =& $this->current_filename;
|
||||
|
||||
if (!isset($this->parsers[$fn]))
|
||||
$this->parsers[$fn] = new TNTOfficiel_fpdi_pdf_parser($fn, $this);
|
||||
$this->current_parser = $this->parsers[$fn];
|
||||
|
||||
return $this->parsers[$fn]->getPageCount();
|
||||
}
|
||||
|
||||
/**
|
||||
* Import a page
|
||||
*
|
||||
* @param int $pageno pagenumber
|
||||
* @return int Index of imported page - to use with fpdf_tpl::useTemplate()
|
||||
*/
|
||||
public function importPage($pageno, $boxName='/CropBox')
|
||||
{
|
||||
if ($this->_intpl) {
|
||||
return $this->error('Please import the desired pages before creating a new template.');
|
||||
}
|
||||
|
||||
$fn =& $this->current_filename;
|
||||
|
||||
// check if page already imported
|
||||
$pageKey = $fn.((int)$pageno).$boxName;
|
||||
if (isset($this->_importedPages[$pageKey]))
|
||||
return $this->_importedPages[$pageKey];
|
||||
|
||||
$parser =& $this->parsers[$fn];
|
||||
$parser->setPageno($pageno);
|
||||
|
||||
$this->tpl++;
|
||||
$this->tpls[$this->tpl] = array();
|
||||
$tpl =& $this->tpls[$this->tpl];
|
||||
$tpl['parser'] =& $parser;
|
||||
$tpl['resources'] = $parser->getPageResources();
|
||||
$tpl['buffer'] = $parser->getContent();
|
||||
|
||||
if (!in_array($boxName, $parser->availableBoxes))
|
||||
return $this->Error(sprintf('Unknown box: %s', $boxName));
|
||||
$pageboxes = $parser->getPageBoxes($pageno);
|
||||
|
||||
/**
|
||||
* MediaBox
|
||||
* CropBox: Default -> MediaBox
|
||||
* BleedBox: Default -> CropBox
|
||||
* TrimBox: Default -> CropBox
|
||||
* ArtBox: Default -> CropBox
|
||||
*/
|
||||
if (!isset($pageboxes[$boxName]) && ($boxName == '/BleedBox' || $boxName == '/TrimBox' || $boxName == '/ArtBox'))
|
||||
$boxName = '/CropBox';
|
||||
if (!isset($pageboxes[$boxName]) && $boxName == '/CropBox')
|
||||
$boxName = '/MediaBox';
|
||||
|
||||
if (!isset($pageboxes[$boxName]))
|
||||
return false;
|
||||
$this->lastUsedPageBox = $boxName;
|
||||
|
||||
$box = $pageboxes[$boxName];
|
||||
$tpl['box'] = $box;
|
||||
|
||||
// To build an array that can be used by PDF_TPL::useTemplate()
|
||||
$this->tpls[$this->tpl] = array_merge($this->tpls[$this->tpl],$box);
|
||||
|
||||
// An imported page will start at 0,0 everytime. Translation will be set in _putformxobjects()
|
||||
$tpl['x'] = 0;
|
||||
$tpl['y'] = 0;
|
||||
|
||||
$page =& $parser->pages[$parser->pageno];
|
||||
|
||||
// handle rotated pages
|
||||
$rotation = $parser->getPageRotation($pageno);
|
||||
$tpl['_rotationAngle'] = 0;
|
||||
if (isset($rotation[1]) && ($angle = $rotation[1] % 360) != 0) {
|
||||
$steps = $angle / 90;
|
||||
|
||||
$_w = $tpl['w'];
|
||||
$_h = $tpl['h'];
|
||||
$tpl['w'] = $steps % 2 == 0 ? $_w : $_h;
|
||||
$tpl['h'] = $steps % 2 == 0 ? $_h : $_w;
|
||||
|
||||
$tpl['_rotationAngle'] = $angle*-1;
|
||||
}
|
||||
|
||||
$this->_importedPages[$pageKey] = $this->tpl;
|
||||
|
||||
return $this->tpl;
|
||||
}
|
||||
|
||||
public function getLastUsedPageBox()
|
||||
{
|
||||
return $this->lastUsedPageBox;
|
||||
}
|
||||
|
||||
public function useTemplate($tplidx, $_x=null, $_y=null, $_w=0, $_h=0, $adjustPageSize=false)
|
||||
{
|
||||
if ($adjustPageSize == true && is_null($_x) && is_null($_y)) {
|
||||
$size = $this->getTemplateSize($tplidx, $_w, $_h);
|
||||
$format = array($size['w'], $size['h']);
|
||||
if ($format[0]!=$this->CurPageFormat[0] || $format[1]!=$this->CurPageFormat[1]) {
|
||||
$this->w=$format[0];
|
||||
$this->h=$format[1];
|
||||
$this->wPt=$this->w*$this->k;
|
||||
$this->hPt=$this->h*$this->k;
|
||||
$this->PageBreakTrigger=$this->h-$this->bMargin;
|
||||
$this->CurPageFormat=$format;
|
||||
$this->PageSizes[$this->page]=array($this->wPt, $this->hPt);
|
||||
}
|
||||
}
|
||||
|
||||
$this->_out('q 0 J 1 w 0 j 0 G 0 g'); // reset standard values
|
||||
$s = parent::useTemplate($tplidx, $_x, $_y, $_w, $_h);
|
||||
$this->_out('Q');
|
||||
return $s;
|
||||
}
|
||||
|
||||
/**
|
||||
* Private method, that rebuilds all needed objects of source files
|
||||
*/
|
||||
public function _putimportedobjects()
|
||||
{
|
||||
if (is_array($this->parsers) && count($this->parsers) > 0) {
|
||||
foreach($this->parsers AS $filename => $p) {
|
||||
$this->current_parser =& $this->parsers[$filename];
|
||||
if (isset($this->_obj_stack[$filename]) && is_array($this->_obj_stack[$filename])) {
|
||||
while(($n = key($this->_obj_stack[$filename])) !== null) {
|
||||
$nObj = $this->current_parser->pdf_resolve_object($this->current_parser->c,$this->_obj_stack[$filename][$n][1]);
|
||||
|
||||
$this->_newobj($this->_obj_stack[$filename][$n][0]);
|
||||
|
||||
if ($nObj[0] == PDF_TYPE_STREAM) {
|
||||
$this->pdf_write_value ($nObj);
|
||||
} else {
|
||||
$this->pdf_write_value ($nObj[1]);
|
||||
}
|
||||
|
||||
$this->_out('endobj');
|
||||
$this->_obj_stack[$filename][$n] = null; // free memory
|
||||
unset($this->_obj_stack[$filename][$n]);
|
||||
reset($this->_obj_stack[$filename]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Private Method that writes the form xobjects
|
||||
*/
|
||||
public function _putformxobjects()
|
||||
{
|
||||
$filter=($this->compress) ? '/Filter /FlateDecode ' : '';
|
||||
reset($this->tpls);
|
||||
foreach($this->tpls AS $tplidx => $tpl) {
|
||||
$p=($this->compress) ? gzcompress($tpl['buffer']) : $tpl['buffer'];
|
||||
$this->_newobj();
|
||||
$cN = $this->n; // TCPDF/Protection: rem current "n"
|
||||
|
||||
$this->tpls[$tplidx]['n'] = $this->n;
|
||||
$this->_out('<<'.$filter.'/Type /XObject');
|
||||
$this->_out('/Subtype /Form');
|
||||
$this->_out('/FormType 1');
|
||||
|
||||
$this->_out(sprintf('/BBox [%.2F %.2F %.2F %.2F]',
|
||||
(isset($tpl['box']['llx']) ? $tpl['box']['llx'] : $tpl['x'])*$this->k,
|
||||
(isset($tpl['box']['lly']) ? $tpl['box']['lly'] : -$tpl['y'])*$this->k,
|
||||
(isset($tpl['box']['urx']) ? $tpl['box']['urx'] : $tpl['w'] + $tpl['x'])*$this->k,
|
||||
(isset($tpl['box']['ury']) ? $tpl['box']['ury'] : $tpl['h']-$tpl['y'])*$this->k
|
||||
));
|
||||
|
||||
$c = 1;
|
||||
$s = 0;
|
||||
$tx = 0;
|
||||
$ty = 0;
|
||||
|
||||
if (isset($tpl['box'])) {
|
||||
$tx = -$tpl['box']['llx'];
|
||||
$ty = -$tpl['box']['lly'];
|
||||
|
||||
if ($tpl['_rotationAngle'] <> 0) {
|
||||
$angle = $tpl['_rotationAngle'] * M_PI/180;
|
||||
$c=cos($angle);
|
||||
$s=sin($angle);
|
||||
|
||||
switch($tpl['_rotationAngle']) {
|
||||
case -90:
|
||||
$tx = -$tpl['box']['lly'];
|
||||
$ty = $tpl['box']['urx'];
|
||||
break;
|
||||
case -180:
|
||||
$tx = $tpl['box']['urx'];
|
||||
$ty = $tpl['box']['ury'];
|
||||
break;
|
||||
case -270:
|
||||
$tx = $tpl['box']['ury'];
|
||||
$ty = 0;
|
||||
break;
|
||||
}
|
||||
}
|
||||
} elseif ($tpl['x'] != 0 || $tpl['y'] != 0) {
|
||||
$tx = -$tpl['x']*2;
|
||||
$ty = $tpl['y']*2;
|
||||
}
|
||||
|
||||
$tx *= $this->k;
|
||||
$ty *= $this->k;
|
||||
|
||||
if ($c != 1 || $s != 0 || $tx != 0 || $ty != 0) {
|
||||
$this->_out(sprintf('/Matrix [%.5F %.5F %.5F %.5F %.5F %.5F]',
|
||||
$c, $s, -$s, $c, $tx, $ty
|
||||
));
|
||||
}
|
||||
|
||||
$this->_out('/Resources ');
|
||||
|
||||
if (isset($tpl['resources'])) {
|
||||
$this->current_parser =& $tpl['parser'];
|
||||
$this->pdf_write_value($tpl['resources']); // "n" will be changed
|
||||
} else {
|
||||
$this->_out('<</ProcSet [/PDF /Text /ImageB /ImageC /ImageI]');
|
||||
if (isset($this->_res['tpl'][$tplidx]['fonts']) && count($this->_res['tpl'][$tplidx]['fonts'])) {
|
||||
$this->_out('/Font <<');
|
||||
foreach($this->_res['tpl'][$tplidx]['fonts'] as $font)
|
||||
$this->_out('/F'.$font['i'].' '.$font['n'].' 0 R');
|
||||
$this->_out('>>');
|
||||
}
|
||||
if(isset($this->_res['tpl'][$tplidx]['images']) && count($this->_res['tpl'][$tplidx]['images']) ||
|
||||
isset($this->_res['tpl'][$tplidx]['tpls']) && count($this->_res['tpl'][$tplidx]['tpls']))
|
||||
{
|
||||
$this->_out('/XObject <<');
|
||||
if (isset($this->_res['tpl'][$tplidx]['images']) && count($this->_res['tpl'][$tplidx]['images'])) {
|
||||
foreach($this->_res['tpl'][$tplidx]['images'] as $image)
|
||||
$this->_out('/I'.$image['i'].' '.$image['n'].' 0 R');
|
||||
}
|
||||
if (isset($this->_res['tpl'][$tplidx]['tpls']) && count($this->_res['tpl'][$tplidx]['tpls'])) {
|
||||
foreach($this->_res['tpl'][$tplidx]['tpls'] as $i => $tpl)
|
||||
$this->_out($this->tplprefix.$i.' '.$tpl['n'].' 0 R');
|
||||
}
|
||||
$this->_out('>>');
|
||||
}
|
||||
$this->_out('>>');
|
||||
}
|
||||
|
||||
$nN = $this->n; // TCPDF: rem new "n"
|
||||
$this->n = $cN; // TCPDF: reset to current "n"
|
||||
$this->_out('/Length '.strlen($p).' >>');
|
||||
$this->_putstream($p);
|
||||
$this->_out('endobj');
|
||||
$this->n = $nN; // TCPDF: reset to new "n"
|
||||
}
|
||||
|
||||
$this->_putimportedobjects();
|
||||
}
|
||||
|
||||
/**
|
||||
* Rewritten to handle existing own defined objects
|
||||
*/
|
||||
public function _newobj($obj_id=false,$onlynewobj=false)
|
||||
{
|
||||
if (!$obj_id) {
|
||||
$obj_id = ++$this->n;
|
||||
}
|
||||
|
||||
//Begin a new object
|
||||
if (!$onlynewobj) {
|
||||
$this->offsets[$obj_id] = is_subclass_of($this, 'TNTOfficiel_TCPDF') ? $this->bufferlen : strlen($this->buffer);
|
||||
$this->_out($obj_id.' 0 obj');
|
||||
$this->_current_obj_id = $obj_id; // for later use with encryption
|
||||
}
|
||||
return $obj_id;
|
||||
}
|
||||
|
||||
/**
|
||||
* Writes a value
|
||||
* Needed to rebuild the source document
|
||||
*
|
||||
* @param mixed $value A PDF-Value. Structure of values see cases in this method
|
||||
*/
|
||||
public function pdf_write_value(&$value)
|
||||
{
|
||||
if (is_subclass_of($this, 'TNTOfficiel_TCPDF')) {
|
||||
parent::pdf_write_value($value);
|
||||
}
|
||||
|
||||
switch ($value[0]) {
|
||||
|
||||
case PDF_TYPE_TOKEN :
|
||||
$this->_straightOut($value[1] . ' ');
|
||||
break;
|
||||
case PDF_TYPE_NUMERIC :
|
||||
case PDF_TYPE_REAL :
|
||||
if (is_float($value[1]) && $value[1] != 0) {
|
||||
$this->_straightOut(rtrim(rtrim(sprintf('%F', $value[1]), '0'), '.') .' ');
|
||||
} else {
|
||||
$this->_straightOut($value[1] . ' ');
|
||||
}
|
||||
break;
|
||||
|
||||
case PDF_TYPE_ARRAY :
|
||||
|
||||
// An array. Output the proper
|
||||
// structure and move on.
|
||||
|
||||
$this->_straightOut('[');
|
||||
for ($i = 0; $i < count($value[1]); $i++) {
|
||||
$this->pdf_write_value($value[1][$i]);
|
||||
}
|
||||
|
||||
$this->_out(']');
|
||||
break;
|
||||
|
||||
case PDF_TYPE_DICTIONARY :
|
||||
|
||||
// A dictionary.
|
||||
$this->_straightOut('<<');
|
||||
|
||||
reset ($value[1]);
|
||||
|
||||
while (list($k, $v) = each($value[1])) {
|
||||
$this->_straightOut($k . ' ');
|
||||
$this->pdf_write_value($v);
|
||||
}
|
||||
|
||||
$this->_straightOut('>>');
|
||||
break;
|
||||
|
||||
case PDF_TYPE_OBJREF :
|
||||
|
||||
// An indirect object reference
|
||||
// Fill the object stack if needed
|
||||
$cpfn =& $this->current_parser->filename;
|
||||
|
||||
if (!isset($this->_don_obj_stack[$cpfn][$value[1]])) {
|
||||
$this->_newobj(false,true);
|
||||
$this->_obj_stack[$cpfn][$value[1]] = array($this->n, $value);
|
||||
$this->_don_obj_stack[$cpfn][$value[1]] = array($this->n, $value); // Value is maybee obsolete!!!
|
||||
}
|
||||
$objid = $this->_don_obj_stack[$cpfn][$value[1]][0];
|
||||
|
||||
$this->_out($objid.' 0 R');
|
||||
break;
|
||||
|
||||
case PDF_TYPE_STRING :
|
||||
|
||||
// A string.
|
||||
$this->_straightOut('('.$value[1].')');
|
||||
|
||||
break;
|
||||
|
||||
case PDF_TYPE_STREAM :
|
||||
|
||||
// A stream. First, output the
|
||||
// stream dictionary, then the
|
||||
// stream data itself.
|
||||
$this->pdf_write_value($value[1]);
|
||||
$this->_out('stream');
|
||||
$this->_out($value[2][1]);
|
||||
$this->_out('endstream');
|
||||
break;
|
||||
case PDF_TYPE_HEX :
|
||||
$this->_straightOut('<'.$value[1].'>');
|
||||
break;
|
||||
|
||||
case PDF_TYPE_BOOLEAN :
|
||||
$this->_straightOut($value[1] ? 'true ' : 'false ');
|
||||
break;
|
||||
|
||||
case PDF_TYPE_NULL :
|
||||
// The null object.
|
||||
|
||||
$this->_straightOut('null ');
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Modified so not each call will add a newline to the output.
|
||||
*/
|
||||
public function _straightOut($s)
|
||||
{
|
||||
if (!is_subclass_of($this, 'TNTOfficiel_TCPDF')) {
|
||||
if($this->state==2)
|
||||
$this->pages[$this->page] .= $s;
|
||||
else
|
||||
$this->buffer .= $s;
|
||||
} else {
|
||||
if ($this->state == 2) {
|
||||
if (isset($this->footerlen[$this->page]) AND ($this->footerlen[$this->page] > 0)) {
|
||||
// puts data before page footer
|
||||
$page = substr($this->getPageBuffer($this->page), 0, -$this->footerlen[$this->page]);
|
||||
$footer = substr($this->getPageBuffer($this->page), -$this->footerlen[$this->page]);
|
||||
$this->setPageBuffer($this->page, $page.' '.$s."\n".$footer);
|
||||
} else {
|
||||
$this->setPageBuffer($this->page, $s, true);
|
||||
}
|
||||
} else {
|
||||
$this->setBuffer($s);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* rewritten to close opened parsers
|
||||
*
|
||||
*/
|
||||
public function _enddoc()
|
||||
{
|
||||
parent::_enddoc();
|
||||
$this->_closeParsers();
|
||||
}
|
||||
|
||||
/**
|
||||
* close all files opened by parsers
|
||||
*/
|
||||
public function _closeParsers()
|
||||
{
|
||||
if ($this->state > 2 && count($this->parsers) > 0) {
|
||||
foreach ($this->parsers as $k => $_){
|
||||
$this->parsers[$k]->closeFile();
|
||||
$this->parsers[$k] = null;
|
||||
unset($this->parsers[$k]);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
@ -0,0 +1,408 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
//
|
||||
// FPDI - Version 1.3.1
|
||||
//
|
||||
// Copyright 2004-2009 Setasign - Jan Slabon
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
|
||||
require_once('TNTOfficiel_pdf_parser.php');
|
||||
|
||||
class TNTOfficiel_fpdi_pdf_parser extends TNTOfficiel_pdf_parser {
|
||||
|
||||
/**
|
||||
* Pages
|
||||
* Index beginns at 0
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
var $pages;
|
||||
|
||||
/**
|
||||
* Page count
|
||||
* @var integer
|
||||
*/
|
||||
var $page_count;
|
||||
|
||||
/**
|
||||
* actual page number
|
||||
* @var integer
|
||||
*/
|
||||
var $pageno;
|
||||
|
||||
/**
|
||||
* PDF Version of imported Document
|
||||
* @var string
|
||||
*/
|
||||
var $pdfVersion;
|
||||
|
||||
/**
|
||||
* FPDI Reference
|
||||
* @var object
|
||||
*/
|
||||
var $fpdi;
|
||||
|
||||
/**
|
||||
* Available BoxTypes
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
var $availableBoxes = array('/MediaBox', '/CropBox', '/BleedBox', '/TrimBox', '/ArtBox');
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
*
|
||||
* @param string $filename Source-Filename
|
||||
* @param object $fpdi Object of type fpdi
|
||||
*/
|
||||
public function TNTOfficiel_fpdi_pdf_parser($filename, &$fpdi)
|
||||
{
|
||||
$this->fpdi =& $fpdi;
|
||||
|
||||
parent::TNTOfficiel_pdf_parser($filename);
|
||||
|
||||
// resolve Pages-Dictonary
|
||||
$pages = $this->pdf_resolve_object($this->c, $this->root[1][1]['/Pages']);
|
||||
|
||||
// Read pages
|
||||
$this->read_pages($this->c, $pages, $this->pages);
|
||||
|
||||
// count pages;
|
||||
$this->page_count = count($this->pages);
|
||||
}
|
||||
|
||||
/**
|
||||
* Overwrite parent::error()
|
||||
*
|
||||
* @param string $msg Error-Message
|
||||
*/
|
||||
public function error($msg)
|
||||
{
|
||||
$this->fpdi->error($msg);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get pagecount from sourcefile
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getPageCount()
|
||||
{
|
||||
return $this->page_count;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Set pageno
|
||||
*
|
||||
* @param int $pageno Pagenumber to use
|
||||
*/
|
||||
public function setPageno($pageno)
|
||||
{
|
||||
$pageno = ((int) $pageno) - 1;
|
||||
|
||||
if ($pageno < 0 || $pageno >= $this->getPageCount()) {
|
||||
$this->fpdi->error('Pagenumber is wrong!');
|
||||
}
|
||||
|
||||
$this->pageno = $pageno;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get page-resources from current page
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function getPageResources()
|
||||
{
|
||||
return $this->_getPageResources($this->pages[$this->pageno]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get page-resources from /Page
|
||||
*
|
||||
* @param array $obj Array of pdf-data
|
||||
*/
|
||||
public function _getPageResources ($obj)
|
||||
{ // $obj = /Page
|
||||
$obj = $this->pdf_resolve_object($this->c, $obj);
|
||||
|
||||
// If the current object has a resources
|
||||
// dictionary associated with it, we use
|
||||
// it. Otherwise, we move back to its
|
||||
// parent object.
|
||||
if (isset ($obj[1][1]['/Resources'])) {
|
||||
$res = $this->pdf_resolve_object($this->c, $obj[1][1]['/Resources']);
|
||||
if ($res[0] == PDF_TYPE_OBJECT)
|
||||
return $res[1];
|
||||
return $res;
|
||||
} else {
|
||||
if (!isset ($obj[1][1]['/Parent'])) {
|
||||
return false;
|
||||
} else {
|
||||
$res = $this->_getPageResources($obj[1][1]['/Parent']);
|
||||
if ($res[0] == PDF_TYPE_OBJECT)
|
||||
return $res[1];
|
||||
return $res;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Get content of current page
|
||||
*
|
||||
* If more /Contents is an array, the streams are concated
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getContent()
|
||||
{
|
||||
$buffer = '';
|
||||
|
||||
if (isset($this->pages[$this->pageno][1][1]['/Contents'])) {
|
||||
$contents = $this->_getPageContent($this->pages[$this->pageno][1][1]['/Contents']);
|
||||
foreach($contents AS $tmp_content) {
|
||||
$buffer .= $this->_rebuildContentStream($tmp_content).' ';
|
||||
}
|
||||
}
|
||||
|
||||
return $buffer;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Resolve all content-objects
|
||||
*
|
||||
* @param array $content_ref
|
||||
* @return array
|
||||
*/
|
||||
public function _getPageContent($content_ref)
|
||||
{
|
||||
$contents = array();
|
||||
|
||||
if ($content_ref[0] == PDF_TYPE_OBJREF) {
|
||||
$content = $this->pdf_resolve_object($this->c, $content_ref);
|
||||
if ($content[1][0] == PDF_TYPE_ARRAY) {
|
||||
$contents = $this->_getPageContent($content[1]);
|
||||
} else {
|
||||
$contents[] = $content;
|
||||
}
|
||||
} elseif ($content_ref[0] == PDF_TYPE_ARRAY) {
|
||||
foreach ($content_ref[1] AS $tmp_content_ref) {
|
||||
$contents = array_merge($contents,$this->_getPageContent($tmp_content_ref));
|
||||
}
|
||||
}
|
||||
|
||||
return $contents;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Rebuild content-streams
|
||||
*
|
||||
* @param array $obj
|
||||
* @return string
|
||||
*/
|
||||
public function _rebuildContentStream($obj)
|
||||
{
|
||||
$filters = array();
|
||||
|
||||
if (isset($obj[1][1]['/Filter'])) {
|
||||
$_filter = $obj[1][1]['/Filter'];
|
||||
|
||||
if ($_filter[0] == PDF_TYPE_TOKEN) {
|
||||
$filters[] = $_filter;
|
||||
} elseif ($_filter[0] == PDF_TYPE_ARRAY) {
|
||||
$filters = $_filter[1];
|
||||
}
|
||||
}
|
||||
|
||||
$stream = $obj[2][1];
|
||||
|
||||
foreach ($filters AS $_filter) {
|
||||
switch ($_filter[1]) {
|
||||
case '/FlateDecode':
|
||||
if (function_exists('gzuncompress')) {
|
||||
$stream = (strlen($stream) > 0) ? @gzuncompress($stream) : '';
|
||||
} else {
|
||||
$this->error(sprintf('To handle %s filter, please compile php with zlib support.',$_filter[1]));
|
||||
}
|
||||
if ($stream === false) {
|
||||
$this->error('Error while decompressing stream.');
|
||||
}
|
||||
break;
|
||||
case '/LZWDecode':
|
||||
include_once('filters/TNTOfficiel_FilterLZW_FPDI.php');
|
||||
$decoder = new TNTOfficiel_FilterLZW_FPDI($this->fpdi);
|
||||
$stream = $decoder->decode($stream);
|
||||
break;
|
||||
case '/ASCII85Decode':
|
||||
include_once('filters/TNTOfficiel_FilterASCII85_FPDI.php');
|
||||
$decoder = new TNTOfficiel_FilterASCII85_FPDI($this->fpdi);
|
||||
$stream = $decoder->decode($stream);
|
||||
break;
|
||||
case null:
|
||||
$stream = $stream;
|
||||
break;
|
||||
default:
|
||||
$this->error(sprintf('Unsupported Filter: %s',$_filter[1]));
|
||||
}
|
||||
}
|
||||
|
||||
return $stream;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Get a Box from a page
|
||||
* Arrayformat is same as used by fpdf_tpl
|
||||
*
|
||||
* @param array $page a /Page
|
||||
* @param string $box_index Type of Box @see $availableBoxes
|
||||
* @return array
|
||||
*/
|
||||
public function getPageBox($page, $box_index)
|
||||
{
|
||||
$page = $this->pdf_resolve_object($this->c,$page);
|
||||
$box = null;
|
||||
if (isset($page[1][1][$box_index]))
|
||||
$box =& $page[1][1][$box_index];
|
||||
|
||||
if (!is_null($box) && $box[0] == PDF_TYPE_OBJREF) {
|
||||
$tmp_box = $this->pdf_resolve_object($this->c,$box);
|
||||
$box = $tmp_box[1];
|
||||
}
|
||||
|
||||
if (!is_null($box) && $box[0] == PDF_TYPE_ARRAY) {
|
||||
$b =& $box[1];
|
||||
return array('x' => $b[0][1]/$this->fpdi->k,
|
||||
'y' => $b[1][1]/$this->fpdi->k,
|
||||
'w' => abs($b[0][1]-$b[2][1])/$this->fpdi->k,
|
||||
'h' => abs($b[1][1]-$b[3][1])/$this->fpdi->k,
|
||||
'llx' => min($b[0][1], $b[2][1])/$this->fpdi->k,
|
||||
'lly' => min($b[1][1], $b[3][1])/$this->fpdi->k,
|
||||
'urx' => max($b[0][1], $b[2][1])/$this->fpdi->k,
|
||||
'ury' => max($b[1][1], $b[3][1])/$this->fpdi->k,
|
||||
);
|
||||
} elseif (!isset ($page[1][1]['/Parent'])) {
|
||||
return false;
|
||||
} else {
|
||||
return $this->getPageBox($this->pdf_resolve_object($this->c, $page[1][1]['/Parent']), $box_index);
|
||||
}
|
||||
}
|
||||
|
||||
public function getPageBoxes($pageno)
|
||||
{
|
||||
return $this->_getPageBoxes($this->pages[$pageno-1]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get all Boxes from /Page
|
||||
*
|
||||
* @param array a /Page
|
||||
* @return array
|
||||
*/
|
||||
public function _getPageBoxes($page)
|
||||
{
|
||||
$boxes = array();
|
||||
|
||||
foreach($this->availableBoxes AS $box) {
|
||||
if ($_box = $this->getPageBox($page,$box)) {
|
||||
$boxes[$box] = $_box;
|
||||
}
|
||||
}
|
||||
|
||||
return $boxes;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the page rotation by pageno
|
||||
*
|
||||
* @param integer $pageno
|
||||
* @return array
|
||||
*/
|
||||
public function getPageRotation($pageno)
|
||||
{
|
||||
return $this->_getPageRotation($this->pages[$pageno-1]);
|
||||
}
|
||||
|
||||
public function _getPageRotation ($obj)
|
||||
{ // $obj = /Page
|
||||
$obj = $this->pdf_resolve_object($this->c, $obj);
|
||||
if (isset ($obj[1][1]['/Rotate'])) {
|
||||
$res = $this->pdf_resolve_object($this->c, $obj[1][1]['/Rotate']);
|
||||
if ($res[0] == PDF_TYPE_OBJECT)
|
||||
return $res[1];
|
||||
return $res;
|
||||
} else {
|
||||
if (!isset ($obj[1][1]['/Parent'])) {
|
||||
return false;
|
||||
} else {
|
||||
$res = $this->_getPageRotation($obj[1][1]['/Parent']);
|
||||
if ($res[0] == PDF_TYPE_OBJECT)
|
||||
return $res[1];
|
||||
return $res;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Read all /Page(es)
|
||||
*
|
||||
* @param object TNTOfficiel_pdf_context
|
||||
* @param array /Pages
|
||||
* @param array the result-array
|
||||
*/
|
||||
public function read_pages (&$c, &$pages, &$result)
|
||||
{
|
||||
// Get the kids dictionary
|
||||
$kids = $this->pdf_resolve_object ($c, $pages[1][1]['/Kids']);
|
||||
|
||||
if (!is_array($kids))
|
||||
$this->error('Cannot find /Kids in current /Page-Dictionary');
|
||||
foreach ($kids[1] as $v) {
|
||||
$pg = $this->pdf_resolve_object ($c, $v);
|
||||
if ($pg[1][1]['/Type'][1] === '/Pages') {
|
||||
// If one of the kids is an embedded
|
||||
// /Pages array, resolve it as well.
|
||||
$this->read_pages ($c, $pg, $result);
|
||||
} else {
|
||||
$result[] = $pg;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Get PDF-Version
|
||||
*
|
||||
* And reset the PDF Version used in FPDI if needed
|
||||
*/
|
||||
public function getPDFVersion()
|
||||
{
|
||||
parent::getPDFVersion();
|
||||
$this->fpdi->PDFVersion = max($this->fpdi->PDFVersion, $this->pdfVersion);
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,105 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
//
|
||||
// FPDI - Version 1.3.1
|
||||
//
|
||||
// Copyright 2004-2009 Setasign - Jan Slabon
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
|
||||
class TNTOfficiel_pdf_context {
|
||||
|
||||
/**
|
||||
* Modi
|
||||
*
|
||||
* @var integer 0 = file | 1 = string
|
||||
*/
|
||||
var $_mode = 0;
|
||||
|
||||
var $file;
|
||||
var $buffer;
|
||||
var $offset;
|
||||
var $length;
|
||||
|
||||
var $stack;
|
||||
|
||||
// Constructor
|
||||
|
||||
public function TNTOfficiel_pdf_context(&$f) {
|
||||
$this->file =& $f;
|
||||
if (is_string($this->file))
|
||||
$this->_mode = 1;
|
||||
$this->reset();
|
||||
}
|
||||
|
||||
// Optionally move the file
|
||||
// pointer to a new location
|
||||
// and reset the buffered data
|
||||
|
||||
public function reset($pos = null, $l = 100) {
|
||||
if ($this->_mode == 0) {
|
||||
if (!is_null ($pos)) {
|
||||
fseek ($this->file, $pos);
|
||||
}
|
||||
|
||||
$this->buffer = $l > 0 ? fread($this->file, $l) : '';
|
||||
$this->length = strlen($this->buffer);
|
||||
if ($this->length < $l)
|
||||
$this->increase_length($l - $this->length);
|
||||
} else {
|
||||
$this->buffer = $this->file;
|
||||
$this->length = strlen($this->buffer);
|
||||
}
|
||||
$this->offset = 0;
|
||||
$this->stack = array();
|
||||
}
|
||||
|
||||
// Make sure that there is at least one
|
||||
// character beyond the current offset in
|
||||
// the buffer to prevent the tokenizer
|
||||
// from attempting to access data that does
|
||||
// not exist
|
||||
|
||||
public function ensure_content() {
|
||||
if ($this->offset >= $this->length - 1) {
|
||||
return $this->increase_length();
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
// Forcefully read more data into the buffer
|
||||
|
||||
public function increase_length($l=100) {
|
||||
if ($this->_mode == 0 && feof($this->file)) {
|
||||
return false;
|
||||
} elseif ($this->_mode == 0) {
|
||||
$totalLength = $this->length + $l;
|
||||
do {
|
||||
$this->buffer .= fread($this->file, $totalLength-$this->length);
|
||||
} while ((($this->length = strlen($this->buffer)) != $totalLength) && !feof($this->file));
|
||||
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,725 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
//
|
||||
// FPDI - Version 1.3.1
|
||||
//
|
||||
// Copyright 2004-2009 Setasign - Jan Slabon
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
|
||||
if (!defined('PDF_TYPE_NULL'))
|
||||
define('PDF_TYPE_NULL', 0);
|
||||
if (!defined('PDF_TYPE_NUMERIC'))
|
||||
define('PDF_TYPE_NUMERIC', 1);
|
||||
if (!defined('PDF_TYPE_TOKEN'))
|
||||
define('PDF_TYPE_TOKEN', 2);
|
||||
if (!defined('PDF_TYPE_HEX'))
|
||||
define('PDF_TYPE_HEX', 3);
|
||||
if (!defined('PDF_TYPE_STRING'))
|
||||
define('PDF_TYPE_STRING', 4);
|
||||
if (!defined('PDF_TYPE_DICTIONARY'))
|
||||
define('PDF_TYPE_DICTIONARY', 5);
|
||||
if (!defined('PDF_TYPE_ARRAY'))
|
||||
define('PDF_TYPE_ARRAY', 6);
|
||||
if (!defined('PDF_TYPE_OBJDEC'))
|
||||
define('PDF_TYPE_OBJDEC', 7);
|
||||
if (!defined('PDF_TYPE_OBJREF'))
|
||||
define('PDF_TYPE_OBJREF', 8);
|
||||
if (!defined('PDF_TYPE_OBJECT'))
|
||||
define('PDF_TYPE_OBJECT', 9);
|
||||
if (!defined('PDF_TYPE_STREAM'))
|
||||
define('PDF_TYPE_STREAM', 10);
|
||||
if (!defined('PDF_TYPE_BOOLEAN'))
|
||||
define('PDF_TYPE_BOOLEAN', 11);
|
||||
if (!defined('PDF_TYPE_REAL'))
|
||||
define('PDF_TYPE_REAL', 12);
|
||||
|
||||
require_once('TNTOfficiel_pdf_context.php');
|
||||
|
||||
if (!class_exists('TNTOfficiel_pdf_parser')) {
|
||||
|
||||
class TNTOfficiel_pdf_parser {
|
||||
|
||||
/**
|
||||
* Filename
|
||||
* @var string
|
||||
*/
|
||||
var $filename;
|
||||
|
||||
/**
|
||||
* File resource
|
||||
* @var resource
|
||||
*/
|
||||
var $f;
|
||||
|
||||
/**
|
||||
* PDF Context
|
||||
* @var object TNTOfficiel_pdf_context-Instance
|
||||
*/
|
||||
var $c;
|
||||
|
||||
/**
|
||||
* xref-Data
|
||||
* @var array
|
||||
*/
|
||||
var $xref;
|
||||
|
||||
/**
|
||||
* root-Object
|
||||
* @var array
|
||||
*/
|
||||
var $root;
|
||||
|
||||
/**
|
||||
* PDF version of the loaded document
|
||||
* @var string
|
||||
*/
|
||||
var $pdfVersion;
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
*
|
||||
* @param string $filename Source-Filename
|
||||
*/
|
||||
public function TNTOfficiel_pdf_parser($filename)
|
||||
{
|
||||
$this->filename = $filename;
|
||||
|
||||
$this->f = @fopen($this->filename, 'rb');
|
||||
|
||||
if (!$this->f)
|
||||
$this->error(sprintf('Cannot open %s !', $filename));
|
||||
|
||||
$this->getPDFVersion();
|
||||
|
||||
$this->c = new TNTOfficiel_pdf_context($this->f);
|
||||
|
||||
// Read xref-Data
|
||||
$this->xref = array();
|
||||
$this->pdf_read_xref($this->xref, $this->pdf_find_xref());
|
||||
|
||||
// Check for Encryption
|
||||
$this->getEncryption();
|
||||
|
||||
// Read root
|
||||
$this->pdf_read_root();
|
||||
}
|
||||
|
||||
/**
|
||||
* Close the opened file
|
||||
*/
|
||||
public function closeFile()
|
||||
{
|
||||
if (isset($this->f) && is_resource($this->f)) {
|
||||
fclose($this->f);
|
||||
unset($this->f);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Print Error and die
|
||||
*
|
||||
* @param string $msg Error-Message
|
||||
*/
|
||||
public function error($msg)
|
||||
{
|
||||
die('<b>PDF-Parser Error:</b> '.$msg);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check Trailer for Encryption
|
||||
*/
|
||||
public function getEncryption()
|
||||
{
|
||||
if (isset($this->xref['trailer'][1]['/Encrypt'])) {
|
||||
$this->error('File is encrypted!');
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Find/Return /Root
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function pdf_find_root()
|
||||
{
|
||||
if ($this->xref['trailer'][1]['/Root'][0] != PDF_TYPE_OBJREF) {
|
||||
$this->error('Wrong Type of Root-Element! Must be an indirect reference');
|
||||
}
|
||||
|
||||
return $this->xref['trailer'][1]['/Root'];
|
||||
}
|
||||
|
||||
/**
|
||||
* Read the /Root
|
||||
*/
|
||||
public function pdf_read_root()
|
||||
{
|
||||
// read root
|
||||
$this->root = $this->pdf_resolve_object($this->c, $this->pdf_find_root());
|
||||
}
|
||||
|
||||
/**
|
||||
* Get PDF-Version
|
||||
*
|
||||
* And reset the PDF Version used in FPDI if needed
|
||||
*/
|
||||
public function getPDFVersion()
|
||||
{
|
||||
fseek($this->f, 0);
|
||||
preg_match('/\d\.\d/',fread($this->f,16),$m);
|
||||
if (isset($m[0]))
|
||||
$this->pdfVersion = $m[0];
|
||||
return $this->pdfVersion;
|
||||
}
|
||||
|
||||
/**
|
||||
* Find the xref-Table
|
||||
*/
|
||||
public function pdf_find_xref()
|
||||
{
|
||||
$toRead = 1500;
|
||||
|
||||
$stat = fseek ($this->f, -$toRead, SEEK_END);
|
||||
if ($stat === -1) {
|
||||
fseek ($this->f, 0);
|
||||
}
|
||||
$data = fread($this->f, $toRead);
|
||||
|
||||
$pos = strlen($data) - strpos(strrev($data), strrev('startxref'));
|
||||
$data = substr($data, $pos);
|
||||
|
||||
if (!preg_match('/\s*(\d+).*$/s', $data, $matches)) {
|
||||
$this->error('Unable to find pointer to xref table');
|
||||
}
|
||||
|
||||
return (int) $matches[1];
|
||||
}
|
||||
|
||||
/**
|
||||
* Read xref-table
|
||||
*
|
||||
* @param array $result Array of xref-table
|
||||
* @param integer $offset of xref-table
|
||||
*/
|
||||
public function pdf_read_xref(&$result, $offset)
|
||||
{
|
||||
|
||||
fseek($this->f, $o_pos = $offset-20); // set some bytes backwards to fetch errorious docs
|
||||
|
||||
$data = fread($this->f, 100);
|
||||
|
||||
$xrefPos = strrpos($data, 'xref');
|
||||
|
||||
if ($xrefPos === false) {
|
||||
fseek($this->f, $offset);
|
||||
$c = new TNTOfficiel_pdf_context($this->f);
|
||||
$xrefStreamObjDec = $this->pdf_read_value($c);
|
||||
|
||||
if (is_array($xrefStreamObjDec) && isset($xrefStreamObjDec[0]) && $xrefStreamObjDec[0] == PDF_TYPE_OBJDEC) {
|
||||
$this->error(sprintf('This document (%s) probably uses a compression technique which is not supported by the free parser shipped with FPDI.', $this->filename));
|
||||
} else {
|
||||
$this->error('Unable to find xref table.');
|
||||
}
|
||||
}
|
||||
|
||||
if (!isset($result['xref_location'])) {
|
||||
$result['xref_location'] = $o_pos+$xrefPos;
|
||||
$result['max_object'] = 0;
|
||||
}
|
||||
|
||||
$cylces = -1;
|
||||
$bytesPerCycle = 100;
|
||||
|
||||
fseek($this->f, $o_pos = $o_pos+$xrefPos+4); // set the handle directly after the "xref"-keyword
|
||||
$data = fread($this->f, $bytesPerCycle);
|
||||
|
||||
while (($trailerPos = strpos($data, 'trailer', max($bytesPerCycle*$cylces++, 0))) === false && !feof($this->f)) {
|
||||
$data .= fread($this->f, $bytesPerCycle);
|
||||
}
|
||||
|
||||
if ($trailerPos === false) {
|
||||
$this->error('Trailer keyword not found after xref table');
|
||||
}
|
||||
|
||||
$data = substr($data, 0, $trailerPos);
|
||||
|
||||
// get Line-Ending
|
||||
preg_match_all("/(\r\n|\n|\r)/", substr($data, 0, 100), $m); // check the first 100 bytes for linebreaks
|
||||
|
||||
$differentLineEndings = count(array_unique($m[0]));
|
||||
if ($differentLineEndings > 1) {
|
||||
$lines = preg_split("/(\r\n|\n|\r)/", $data, -1, PREG_SPLIT_NO_EMPTY);
|
||||
} else {
|
||||
$lines = explode($m[0][1], $data);
|
||||
}
|
||||
|
||||
$data = $differentLineEndings = $m = null;
|
||||
unset($data, $differentLineEndings, $m);
|
||||
|
||||
$linesCount = count($lines);
|
||||
|
||||
$start = 1;
|
||||
|
||||
for ($i = 0; $i < $linesCount; $i++) {
|
||||
$line = trim($lines[$i]);
|
||||
if ($line) {
|
||||
$pieces = explode(' ', $line);
|
||||
$c = count($pieces);
|
||||
switch($c) {
|
||||
case 2:
|
||||
$start = (int)$pieces[0];
|
||||
$end = $start+(int)$pieces[1];
|
||||
if ($end > $result['max_object'])
|
||||
$result['max_object'] = $end;
|
||||
break;
|
||||
case 3:
|
||||
if (!isset($result['xref'][$start]))
|
||||
$result['xref'][$start] = array();
|
||||
|
||||
if (!array_key_exists($gen = (int) $pieces[1], $result['xref'][$start])) {
|
||||
$result['xref'][$start][$gen] = $pieces[2] == 'n' ? (int) $pieces[0] : null;
|
||||
}
|
||||
$start++;
|
||||
break;
|
||||
default:
|
||||
$this->error('Unexpected data in xref table');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$lines = $pieces = $line = $start = $end = $gen = null;
|
||||
unset($lines, $pieces, $line, $start, $end, $gen);
|
||||
|
||||
fseek($this->f, $o_pos+$trailerPos+7);
|
||||
|
||||
$c = new TNTOfficiel_pdf_context($this->f);
|
||||
$trailer = $this->pdf_read_value($c);
|
||||
|
||||
$c = null;
|
||||
unset($c);
|
||||
|
||||
if (!isset($result['trailer'])) {
|
||||
$result['trailer'] = $trailer;
|
||||
}
|
||||
|
||||
if (isset($trailer[1]['/Prev'])) {
|
||||
$this->pdf_read_xref($result, $trailer[1]['/Prev'][1]);
|
||||
}
|
||||
|
||||
$trailer = null;
|
||||
unset($trailer);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Reads an Value
|
||||
*
|
||||
* @param object $c TNTOfficiel_pdf_context
|
||||
* @param string $token a Token
|
||||
* @return mixed
|
||||
*/
|
||||
public function pdf_read_value(&$c, $token = null)
|
||||
{
|
||||
if (is_null($token)) {
|
||||
$token = $this->pdf_read_token($c);
|
||||
}
|
||||
|
||||
if ($token === false) {
|
||||
return false;
|
||||
}
|
||||
|
||||
switch ($token) {
|
||||
case '<':
|
||||
// This is a hex string.
|
||||
// Read the value, then the terminator
|
||||
|
||||
$pos = $c->offset;
|
||||
|
||||
while(1) {
|
||||
|
||||
$match = strpos ($c->buffer, '>', $pos);
|
||||
|
||||
// If you can't find it, try
|
||||
// reading more data from the stream
|
||||
|
||||
if ($match === false) {
|
||||
if (!$c->increase_length()) {
|
||||
return false;
|
||||
} else {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
$result = substr ($c->buffer, $c->offset, $match - $c->offset);
|
||||
$c->offset = $match + 1;
|
||||
|
||||
return array (PDF_TYPE_HEX, $result);
|
||||
}
|
||||
|
||||
break;
|
||||
case '<<':
|
||||
// This is a dictionary.
|
||||
|
||||
$result = array();
|
||||
|
||||
// Recurse into this function until we reach
|
||||
// the end of the dictionary.
|
||||
while (($key = $this->pdf_read_token($c)) !== '>>') {
|
||||
if ($key === false) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (($value = $this->pdf_read_value($c)) === false) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Catch missing value
|
||||
if ($value[0] == PDF_TYPE_TOKEN && $value[1] == '>>') {
|
||||
$result[$key] = array(PDF_TYPE_NULL);
|
||||
break;
|
||||
}
|
||||
|
||||
$result[$key] = $value;
|
||||
}
|
||||
|
||||
return array (PDF_TYPE_DICTIONARY, $result);
|
||||
|
||||
case '[':
|
||||
// This is an array.
|
||||
|
||||
$result = array();
|
||||
|
||||
// Recurse into this function until we reach
|
||||
// the end of the array.
|
||||
while (($token = $this->pdf_read_token($c)) !== ']') {
|
||||
if ($token === false) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (($value = $this->pdf_read_value($c, $token)) === false) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$result[] = $value;
|
||||
}
|
||||
|
||||
return array (PDF_TYPE_ARRAY, $result);
|
||||
|
||||
case '(':
|
||||
// This is a string
|
||||
$pos = $c->offset;
|
||||
|
||||
$openBrackets = 1;
|
||||
do {
|
||||
for (; $openBrackets != 0 && $pos < $c->length; $pos++) {
|
||||
switch (ord($c->buffer[$pos])) {
|
||||
case 0x28: // '('
|
||||
$openBrackets++;
|
||||
break;
|
||||
case 0x29: // ')'
|
||||
$openBrackets--;
|
||||
break;
|
||||
case 0x5C: // backslash
|
||||
$pos++;
|
||||
}
|
||||
}
|
||||
} while($openBrackets != 0 && $c->increase_length());
|
||||
|
||||
$result = substr($c->buffer, $c->offset, $pos - $c->offset - 1);
|
||||
$c->offset = $pos;
|
||||
|
||||
return array (PDF_TYPE_STRING, $result);
|
||||
|
||||
case 'stream':
|
||||
$o_pos = ftell($c->file)-strlen($c->buffer);
|
||||
$o_offset = $c->offset;
|
||||
|
||||
$c->reset($startpos = $o_pos + $o_offset);
|
||||
|
||||
$e = 0; // ensure line breaks in front of the stream
|
||||
if ($c->buffer[0] == chr(10) || $c->buffer[0] == chr(13))
|
||||
$e++;
|
||||
if ($c->buffer[1] == chr(10) && $c->buffer[0] != chr(10))
|
||||
$e++;
|
||||
|
||||
if ($this->actual_obj[1][1]['/Length'][0] == PDF_TYPE_OBJREF) {
|
||||
$tmp_c = new TNTOfficiel_pdf_context($this->f);
|
||||
$tmp_length = $this->pdf_resolve_object($tmp_c,$this->actual_obj[1][1]['/Length']);
|
||||
$length = $tmp_length[1][1];
|
||||
} else {
|
||||
$length = $this->actual_obj[1][1]['/Length'][1];
|
||||
}
|
||||
|
||||
if ($length > 0) {
|
||||
$c->reset($startpos+$e,$length);
|
||||
$v = $c->buffer;
|
||||
} else {
|
||||
$v = '';
|
||||
}
|
||||
$c->reset($startpos+$e+$length+9); // 9 = strlen("endstream")
|
||||
|
||||
return array(PDF_TYPE_STREAM, $v);
|
||||
|
||||
default:
|
||||
if (is_numeric ($token)) {
|
||||
// A numeric token. Make sure that
|
||||
// it is not part of something else.
|
||||
if (($tok2 = $this->pdf_read_token ($c)) !== false) {
|
||||
if (is_numeric ($tok2)) {
|
||||
|
||||
// Two numeric tokens in a row.
|
||||
// In this case, we're probably in
|
||||
// front of either an object reference
|
||||
// or an object specification.
|
||||
// Determine the case and return the data
|
||||
if (($tok3 = $this->pdf_read_token ($c)) !== false) {
|
||||
switch ($tok3) {
|
||||
case 'obj':
|
||||
return array (PDF_TYPE_OBJDEC, (int) $token, (int) $tok2);
|
||||
case 'R':
|
||||
return array (PDF_TYPE_OBJREF, (int) $token, (int) $tok2);
|
||||
}
|
||||
// If we get to this point, that numeric value up
|
||||
// there was just a numeric value. Push the extra
|
||||
// tokens back into the stack and return the value.
|
||||
array_push ($c->stack, $tok3);
|
||||
}
|
||||
}
|
||||
|
||||
array_push ($c->stack, $tok2);
|
||||
}
|
||||
|
||||
if ($token === (string)((int)$token))
|
||||
return array (PDF_TYPE_NUMERIC, (int)$token);
|
||||
else
|
||||
return array (PDF_TYPE_REAL, (float)$token);
|
||||
} elseif ($token == 'true' || $token == 'false') {
|
||||
return array (PDF_TYPE_BOOLEAN, $token == 'true');
|
||||
} elseif ($token == 'null') {
|
||||
return array (PDF_TYPE_NULL);
|
||||
} else {
|
||||
// Just a token. Return it.
|
||||
return array (PDF_TYPE_TOKEN, $token);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Resolve an object
|
||||
*
|
||||
* @param object $c TNTOfficiel_pdf_context
|
||||
* @param array $obj_spec The object-data
|
||||
* @param boolean $encapsulate Must set to true, cause the parsing and fpdi use this method only without this para
|
||||
*/
|
||||
public function pdf_resolve_object(&$c, $obj_spec, $encapsulate = true)
|
||||
{
|
||||
// Exit if we get invalid data
|
||||
if (!is_array($obj_spec)) {
|
||||
$ret = false;
|
||||
return $ret;
|
||||
}
|
||||
|
||||
if ($obj_spec[0] == PDF_TYPE_OBJREF) {
|
||||
|
||||
// This is a reference, resolve it
|
||||
if (isset($this->xref['xref'][$obj_spec[1]][$obj_spec[2]])) {
|
||||
|
||||
// Save current file position
|
||||
// This is needed if you want to resolve
|
||||
// references while you're reading another object
|
||||
// (e.g.: if you need to determine the length
|
||||
// of a stream)
|
||||
|
||||
$old_pos = ftell($c->file);
|
||||
|
||||
// Reposition the file pointer and
|
||||
// load the object header.
|
||||
|
||||
$c->reset($this->xref['xref'][$obj_spec[1]][$obj_spec[2]]);
|
||||
|
||||
$header = $this->pdf_read_value($c);
|
||||
|
||||
if ($header[0] != PDF_TYPE_OBJDEC || $header[1] != $obj_spec[1] || $header[2] != $obj_spec[2]) {
|
||||
$this->error("Unable to find object ({$obj_spec[1]}, {$obj_spec[2]}) at expected location");
|
||||
}
|
||||
|
||||
// If we're being asked to store all the information
|
||||
// about the object, we add the object ID and generation
|
||||
// number for later use
|
||||
$result = array();
|
||||
$this->actual_obj =& $result;
|
||||
if ($encapsulate) {
|
||||
$result = array (
|
||||
PDF_TYPE_OBJECT,
|
||||
'obj' => $obj_spec[1],
|
||||
'gen' => $obj_spec[2]
|
||||
);
|
||||
}
|
||||
|
||||
// Now simply read the object data until
|
||||
// we encounter an end-of-object marker
|
||||
while(1) {
|
||||
$value = $this->pdf_read_value($c);
|
||||
if ($value === false || count($result) > 4) {
|
||||
// in this case the parser coudn't find an endobj so we break here
|
||||
break;
|
||||
}
|
||||
|
||||
if ($value[0] == PDF_TYPE_TOKEN && $value[1] === 'endobj') {
|
||||
break;
|
||||
}
|
||||
|
||||
$result[] = $value;
|
||||
}
|
||||
|
||||
$c->reset($old_pos);
|
||||
|
||||
if (isset($result[2][0]) && $result[2][0] == PDF_TYPE_STREAM) {
|
||||
$result[0] = PDF_TYPE_STREAM;
|
||||
}
|
||||
|
||||
return $result;
|
||||
}
|
||||
} else {
|
||||
return $obj_spec;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Reads a token from the file
|
||||
*
|
||||
* @param object $c TNTOfficiel_pdf_context
|
||||
* @return mixed
|
||||
*/
|
||||
public function pdf_read_token(&$c)
|
||||
{
|
||||
// If there is a token available
|
||||
// on the stack, pop it out and
|
||||
// return it.
|
||||
|
||||
if (count($c->stack)) {
|
||||
return array_pop($c->stack);
|
||||
}
|
||||
|
||||
// Strip away any whitespace
|
||||
|
||||
do {
|
||||
if (!$c->ensure_content()) {
|
||||
return false;
|
||||
}
|
||||
$c->offset += strspn($c->buffer, " \n\r\t", $c->offset);
|
||||
} while ($c->offset >= $c->length - 1);
|
||||
|
||||
// Get the first character in the stream
|
||||
|
||||
$char = $c->buffer[$c->offset++];
|
||||
|
||||
switch ($char) {
|
||||
|
||||
case '[':
|
||||
case ']':
|
||||
case '(':
|
||||
case ')':
|
||||
|
||||
// This is either an array or literal string
|
||||
// delimiter, Return it
|
||||
|
||||
return $char;
|
||||
|
||||
case '<':
|
||||
case '>':
|
||||
|
||||
// This could either be a hex string or
|
||||
// dictionary delimiter. Determine the
|
||||
// appropriate case and return the token
|
||||
|
||||
if ($c->buffer[$c->offset] == $char) {
|
||||
if (!$c->ensure_content()) {
|
||||
return false;
|
||||
}
|
||||
$c->offset++;
|
||||
return $char . $char;
|
||||
} else {
|
||||
return $char;
|
||||
}
|
||||
|
||||
case '%':
|
||||
|
||||
// This is a comment - jump over it!
|
||||
|
||||
$pos = $c->offset;
|
||||
while(1) {
|
||||
$match = preg_match("/(\r\n|\r|\n)/", $c->buffer, $m, PREG_OFFSET_CAPTURE, $pos);
|
||||
if ($match === 0) {
|
||||
if (!$c->increase_length()) {
|
||||
return false;
|
||||
} else {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
$c->offset = $m[0][1]+strlen($m[0][0]);
|
||||
|
||||
return $this->pdf_read_token($c);
|
||||
}
|
||||
|
||||
default:
|
||||
|
||||
// This is "another" type of token (probably
|
||||
// a dictionary entry or a numeric value)
|
||||
// Find the end and return it.
|
||||
|
||||
if (!$c->ensure_content()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
while(1) {
|
||||
|
||||
// Determine the length of the token
|
||||
|
||||
$pos = strcspn($c->buffer, " %[]<>()\r\n\t/", $c->offset);
|
||||
|
||||
if ($c->offset + $pos <= $c->length - 1) {
|
||||
break;
|
||||
} else {
|
||||
// If the script reaches this point,
|
||||
// the token may span beyond the end
|
||||
// of the current buffer. Therefore,
|
||||
// we increase the size of the buffer
|
||||
// and try again--just to be safe.
|
||||
|
||||
$c->increase_length();
|
||||
}
|
||||
}
|
||||
|
||||
$result = substr($c->buffer, $c->offset - 1, $pos + 1);
|
||||
|
||||
$c->offset += $pos;
|
||||
return $result;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,110 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
//
|
||||
// FPDI - Version 1.3.1
|
||||
//
|
||||
// Copyright 2004-2009 Setasign - Jan Slabon
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
|
||||
if (!defined('ORD_z')) {
|
||||
define('ORD_z', ord('z'));
|
||||
}
|
||||
if (!defined('ORD_exclmark')) {
|
||||
define('ORD_exclmark', ord('!'));
|
||||
}
|
||||
if (!defined('ORD_u')) {
|
||||
define('ORD_u', ord('u'));
|
||||
}
|
||||
if (!defined('ORD_tilde')) {
|
||||
define('ORD_tilde', ord('~'));
|
||||
}
|
||||
|
||||
class TNTOfficiel_FilterASCII85 {
|
||||
|
||||
public function error($msg) {
|
||||
die($msg);
|
||||
}
|
||||
|
||||
public function decode($in) {
|
||||
$out = '';
|
||||
$state = 0;
|
||||
$chn = null;
|
||||
|
||||
$l = strlen($in);
|
||||
|
||||
for ($k = 0; $k < $l; ++$k) {
|
||||
$ch = ord($in[$k]) & 0xff;
|
||||
|
||||
if ($ch == ORD_tilde) {
|
||||
break;
|
||||
}
|
||||
if (preg_match('/^\s$/',chr($ch))) {
|
||||
continue;
|
||||
}
|
||||
if ($ch == ORD_z && $state == 0) {
|
||||
$out .= chr(0).chr(0).chr(0).chr(0);
|
||||
continue;
|
||||
}
|
||||
if ($ch < ORD_exclmark || $ch > ORD_u) {
|
||||
$this->error('Illegal character in ASCII85Decode.');
|
||||
}
|
||||
|
||||
$chn[$state++] = $ch - ORD_exclmark;
|
||||
|
||||
if ($state == 5) {
|
||||
$state = 0;
|
||||
$r = 0;
|
||||
for ($j = 0; $j < 5; ++$j)
|
||||
$r = $r * 85 + $chn[$j];
|
||||
$out .= chr($r >> 24);
|
||||
$out .= chr($r >> 16);
|
||||
$out .= chr($r >> 8);
|
||||
$out .= chr($r);
|
||||
}
|
||||
}
|
||||
$r = 0;
|
||||
|
||||
if ($state == 1)
|
||||
$this->error('Illegal length in ASCII85Decode.');
|
||||
if ($state == 2) {
|
||||
$r = $chn[0] * 85 * 85 * 85 * 85 + ($chn[1]+1) * 85 * 85 * 85;
|
||||
$out .= chr($r >> 24);
|
||||
}
|
||||
elseif ($state == 3) {
|
||||
$r = $chn[0] * 85 * 85 * 85 * 85 + $chn[1] * 85 * 85 * 85 + ($chn[2]+1) * 85 * 85;
|
||||
$out .= chr($r >> 24);
|
||||
$out .= chr($r >> 16);
|
||||
}
|
||||
elseif ($state == 4) {
|
||||
$r = $chn[0] * 85 * 85 * 85 * 85 + $chn[1] * 85 * 85 * 85 + $chn[2] * 85 * 85 + ($chn[3]+1) * 85 ;
|
||||
$out .= chr($r >> 24);
|
||||
$out .= chr($r >> 16);
|
||||
$out .= chr($r >> 8);
|
||||
}
|
||||
|
||||
return $out;
|
||||
}
|
||||
|
||||
public function encode($in) {
|
||||
$this->error("ASCII85 encoding not implemented.");
|
||||
}
|
||||
}
|
@ -0,0 +1,41 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
//
|
||||
// FPDI - Version 1.3.1
|
||||
//
|
||||
// Copyright 2004-2009 Setasign - Jan Slabon
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
|
||||
require_once('TNTOfficiel_FilterASCII85.php');
|
||||
|
||||
class TNTOfficiel_FilterASCII85_FPDI extends TNTOfficiel_FilterASCII85 {
|
||||
|
||||
var $fpdi;
|
||||
|
||||
public function TNTOfficiel_FilterASCII85_FPDI(&$fpdi) {
|
||||
$this->fpdi =& $fpdi;
|
||||
}
|
||||
|
||||
public function error($msg) {
|
||||
$this->fpdi->error($msg);
|
||||
}
|
||||
}
|
@ -0,0 +1,162 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
//
|
||||
// FPDI - Version 1.3.1
|
||||
//
|
||||
// Copyright 2004-2009 Setasign - Jan Slabon
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
|
||||
class TNTOfficiel_FilterLZW {
|
||||
|
||||
var $sTable = array();
|
||||
var $data = null;
|
||||
var $dataLength = 0;
|
||||
var $tIdx;
|
||||
var $bitsToGet = 9;
|
||||
var $bytePointer;
|
||||
var $bitPointer;
|
||||
var $nextData = 0;
|
||||
var $nextBits = 0;
|
||||
var $andTable = array(511, 1023, 2047, 4095);
|
||||
|
||||
public function error($msg) {
|
||||
die($msg);
|
||||
}
|
||||
|
||||
/**
|
||||
* Method to decode LZW compressed data.
|
||||
*
|
||||
* @param string data The compressed data.
|
||||
*/
|
||||
public function decode($data) {
|
||||
|
||||
if($data[0] == 0x00 && $data[1] == 0x01) {
|
||||
$this->error('LZW flavour not supported.');
|
||||
}
|
||||
|
||||
$this->initsTable();
|
||||
|
||||
$this->data = $data;
|
||||
$this->dataLength = strlen($data);
|
||||
|
||||
// Initialize pointers
|
||||
$this->bytePointer = 0;
|
||||
$this->bitPointer = 0;
|
||||
|
||||
$this->nextData = 0;
|
||||
$this->nextBits = 0;
|
||||
|
||||
$oldCode = 0;
|
||||
|
||||
$string = '';
|
||||
$uncompData = '';
|
||||
|
||||
while (($code = $this->getNextCode()) != 257) {
|
||||
if ($code == 256) {
|
||||
$this->initsTable();
|
||||
$code = $this->getNextCode();
|
||||
|
||||
if ($code == 257) {
|
||||
break;
|
||||
}
|
||||
|
||||
$uncompData .= $this->sTable[$code];
|
||||
$oldCode = $code;
|
||||
|
||||
} else {
|
||||
|
||||
if ($code < $this->tIdx) {
|
||||
$string = $this->sTable[$code];
|
||||
$uncompData .= $string;
|
||||
|
||||
$this->addStringToTable($this->sTable[$oldCode], $string[0]);
|
||||
$oldCode = $code;
|
||||
} else {
|
||||
$string = $this->sTable[$oldCode];
|
||||
$string = $string.$string[0];
|
||||
$uncompData .= $string;
|
||||
|
||||
$this->addStringToTable($string);
|
||||
$oldCode = $code;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return $uncompData;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Initialize the string table.
|
||||
*/
|
||||
public function initsTable() {
|
||||
$this->sTable = array();
|
||||
|
||||
for ($i = 0; $i < 256; $i++)
|
||||
$this->sTable[$i] = chr($i);
|
||||
|
||||
$this->tIdx = 258;
|
||||
$this->bitsToGet = 9;
|
||||
}
|
||||
|
||||
/**
|
||||
* Add a new string to the string table.
|
||||
*/
|
||||
public function addStringToTable ($oldString, $newString='') {
|
||||
$string = $oldString.$newString;
|
||||
|
||||
// Add this new String to the table
|
||||
$this->sTable[$this->tIdx++] = $string;
|
||||
|
||||
if ($this->tIdx == 511) {
|
||||
$this->bitsToGet = 10;
|
||||
} elseif ($this->tIdx == 1023) {
|
||||
$this->bitsToGet = 11;
|
||||
} elseif ($this->tIdx == 2047) {
|
||||
$this->bitsToGet = 12;
|
||||
}
|
||||
}
|
||||
|
||||
// Returns the next 9, 10, 11 or 12 bits
|
||||
public function getNextCode() {
|
||||
if ($this->bytePointer == $this->dataLength) {
|
||||
return 257;
|
||||
}
|
||||
|
||||
$this->nextData = ($this->nextData << 8) | (ord($this->data[$this->bytePointer++]) & 0xff);
|
||||
$this->nextBits += 8;
|
||||
|
||||
if ($this->nextBits < $this->bitsToGet) {
|
||||
$this->nextData = ($this->nextData << 8) | (ord($this->data[$this->bytePointer++]) & 0xff);
|
||||
$this->nextBits += 8;
|
||||
}
|
||||
|
||||
$code = ($this->nextData >> ($this->nextBits - $this->bitsToGet)) & $this->andTable[$this->bitsToGet-9];
|
||||
$this->nextBits -= $this->bitsToGet;
|
||||
|
||||
return $code;
|
||||
}
|
||||
|
||||
public function encode($in) {
|
||||
$this->error("LZW encoding not implemented.");
|
||||
}
|
||||
}
|
@ -0,0 +1,41 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
//
|
||||
// FPDI - Version 1.3.1
|
||||
//
|
||||
// Copyright 2004-2009 Setasign - Jan Slabon
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
|
||||
require_once('TNTOfficiel_FilterLZW.php');
|
||||
|
||||
class TNTOfficiel_FilterLZW_FPDI extends TNTOfficiel_FilterLZW {
|
||||
|
||||
var $fpdi;
|
||||
|
||||
function TNTOfficiel_FilterLZW_FPDI(&$fpdi) {
|
||||
$this->fpdi =& $fpdi;
|
||||
}
|
||||
|
||||
function error($msg) {
|
||||
$this->fpdi->error($msg);
|
||||
}
|
||||
}
|
18
www/modules/tntofficiel/libraries/pdf/fpdi/filters/index.php
Normal file
18
www/modules/tntofficiel/libraries/pdf/fpdi/filters/index.php
Normal file
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../');
|
||||
exit;
|
18
www/modules/tntofficiel/libraries/pdf/fpdi/index.php
Normal file
18
www/modules/tntofficiel/libraries/pdf/fpdi/index.php
Normal file
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../');
|
||||
exit;
|
18
www/modules/tntofficiel/libraries/pdf/index.php
Normal file
18
www/modules/tntofficiel/libraries/pdf/index.php
Normal file
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../');
|
||||
exit;
|
@ -0,0 +1,90 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
|
||||
// HTMLTemplate<NAME>.
|
||||
class HTMLTemplateTNTOfficielManifest extends HTMLTemplate
|
||||
{
|
||||
public $custom_model;
|
||||
|
||||
public function __construct($custom_object, $smarty)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->custom_model = $custom_object;
|
||||
$this->smarty = $smarty;
|
||||
|
||||
// header informations
|
||||
$id_lang = Context::getContext()->language->id;
|
||||
$this->title = HTMLTemplateTNTOfficielManifest::l('Titre Test');
|
||||
// footer informations
|
||||
$this->shop = new Shop(Context::getContext()->shop->id);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the template's HTML content
|
||||
* @return string HTML content
|
||||
*/
|
||||
public function getContent()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->smarty->assign(array(
|
||||
'manifestData' => $this->custom_model,
|
||||
));
|
||||
|
||||
return $this->smarty->fetch(_PS_MODULE_DIR_.'tntofficiel/views/templates/admin/manifest/custom_template_content.tpl');
|
||||
}
|
||||
|
||||
public function getHeader()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->smarty->assign(array(
|
||||
'manifestData' => $this->custom_model,
|
||||
));
|
||||
|
||||
return $this->smarty->fetch(_PS_MODULE_DIR_.'tntofficiel/views/templates/admin/manifest/custom_template_header.tpl');
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the template filename
|
||||
* @return string filename
|
||||
*/
|
||||
public function getFooter()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
return $this->smarty->fetch(_PS_MODULE_DIR_.'tntofficiel/views/templates/admin/manifest/custom_template_footer.tpl');
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the template filename
|
||||
* @return string filename
|
||||
*/
|
||||
public function getFilename()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
return 'Manifeste.pdf';
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the template filename when using bulk rendering
|
||||
* @return string filename
|
||||
*/
|
||||
public function getBulkFilename()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
return 'Manifeste.pdf';
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,34 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
require_once(_PS_MODULE_DIR_.'tntofficiel/libraries/pdf/manifest/TNTOfficiel_ManifestPDFGenerator.php');
|
||||
|
||||
class TNTOfficiel_ManifestPDF extends PDF
|
||||
{
|
||||
/**
|
||||
* Constructor
|
||||
* @param $objects
|
||||
* @param $template
|
||||
* @param $smarty
|
||||
* @param string $orientation
|
||||
*/
|
||||
public function __construct($objects, $template, $smarty, $orientation = 'P')
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->pdf_renderer = new TNTOfficiel_ManifestPDFGenerator((bool)Configuration::get('PS_PDF_USE_CACHE'), $orientation);
|
||||
$this->template = $template;
|
||||
$this->smarty = $smarty;
|
||||
$this->objects = $objects;
|
||||
if (!($objects instanceof Iterator) && !is_array($objects))
|
||||
$this->objects = array($objects);
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,105 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Carrier.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/pdf/manifest/TNTOfficiel_ManifestPDF.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/pdf/manifest/TNTOfficiel_ManifestPDFGenerator.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/pdf/manifest/HTMLTemplateTNTOfficielManifest.php';
|
||||
|
||||
class TNTOfficiel_ManifestPDFCreator
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $orderList array
|
||||
* @throws Exception
|
||||
*/
|
||||
public function createManifest($orderList)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$parcelsData = array();
|
||||
foreach ($orderList as $intOrderID) {
|
||||
$intOrderID = (int)$intOrderID;
|
||||
$objOrder = new Order($intOrderID);
|
||||
if (!TNTOfficiel_Carrier::isTNTOfficielCarrierID($objOrder->id_carrier)) {
|
||||
continue;
|
||||
}
|
||||
$arrTNTOrder = TNTOfficiel_OrderHelper::getInstance()->getOrderData($intOrderID, false);
|
||||
$onjAddress = new Address($objOrder->id_address_delivery);
|
||||
$parcels = TNTOfficiel_ParcelsHelper::getInstance()->getParcels($intOrderID);
|
||||
foreach ($parcels as $p) {
|
||||
$parcel = $p;
|
||||
$parcel['address'] = $onjAddress;
|
||||
$parcel['tntData'] = $arrTNTOrder;
|
||||
$parcelsData[] = $parcel;
|
||||
}
|
||||
}
|
||||
$carrierAccount = Configuration::get('TNT_CARRIER_ACCOUNT');
|
||||
$carrierName = Configuration::get('TNT_CARRIER_USERNAME');
|
||||
|
||||
$pdf = new TNTOfficiel_ManifestPDF(
|
||||
array(
|
||||
'manifestData' => array(
|
||||
'parcelsData' => $parcelsData,
|
||||
'carrierAccount' => $carrierAccount,
|
||||
'carrierName' => $carrierName,
|
||||
'address' => $this->_getMerchantAddress(),
|
||||
'totalWeight' => $this->_getTotalWeight($parcelsData),
|
||||
'parcelsNumber' => count($parcelsData)
|
||||
)
|
||||
),
|
||||
'TNTOfficielManifest',
|
||||
Context::getContext()->smarty
|
||||
);
|
||||
$pdf->render();
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the shop address
|
||||
* @return array
|
||||
*/
|
||||
private function _getMerchantAddress()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$address = array(
|
||||
'name' => Configuration::get('PS_SHOP_NAME'),
|
||||
'address1' => Configuration::get('PS_SHOP_ADDR1'),
|
||||
'address2' => Configuration::get('PS_SHOP_ADDR2'),
|
||||
'postcode' => Configuration::get('PS_SHOP_CODE'),
|
||||
'city' => Configuration::get('PS_SHOP_CITY'),
|
||||
'country' => Configuration::get('PS_SHOP_COUNTRY'),
|
||||
);
|
||||
|
||||
return $address;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the total weight for the given parcels
|
||||
* @param $parcels
|
||||
* @return float
|
||||
*/
|
||||
private function _getTotalWeight($parcels)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$totalWeight = (float)0;
|
||||
foreach ($parcels as $parcel) {
|
||||
$totalWeight += $parcel['weight'];
|
||||
}
|
||||
|
||||
return $totalWeight;
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,23 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
|
||||
class TNTOfficiel_ManifestPDFGenerator extends PDFGenerator
|
||||
{
|
||||
public function Header()
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
$this->writeHTML($this->header);
|
||||
|
||||
$this->writeHTML('<table style="width: 100%;"><tr style="width: 100%;"><td style="width: 33%"></td><td style="width: 33%"></td><td style="width: 33%; text-align: right">Page : '.$this->getAliasNumPage().' de '.$this->getAliasNbPages().'</td></tr></table>');
|
||||
}
|
||||
|
||||
}
|
18
www/modules/tntofficiel/libraries/pdf/manifest/index.php
Normal file
18
www/modules/tntofficiel/libraries/pdf/manifest/index.php
Normal file
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../');
|
||||
exit;
|
@ -0,0 +1,36 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/helper/TNTOfficiel_OrderHelper.php';
|
||||
|
||||
class TNTOfficiel_OrderSmartyFunction
|
||||
{
|
||||
/**
|
||||
* @param $data array
|
||||
* @param $smarty
|
||||
*
|
||||
* @return bool|string
|
||||
*/
|
||||
public function getTntOrder($data, $smarty)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
try {
|
||||
$arrTNTOrder = TNTOfficiel_OrderHelper::getInstance()->getOrderData($data['orderId']);
|
||||
$smarty->assign('tntOrderData', $arrTNTOrder);
|
||||
|
||||
return (is_string($arrTNTOrder)) ? $arrTNTOrder : null;
|
||||
} catch (Exception $objException) {
|
||||
$smarty->assign('tntOrderData', false);
|
||||
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,98 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
require_once _PS_MODULE_DIR_.'tntofficiel/libraries/TNTOfficiel_Debug.php';
|
||||
|
||||
/**
|
||||
* Class TNTOfficiel_ShippingMethodSmartyFunction.
|
||||
*/
|
||||
class TNTOfficiel_ShippingMethodSmartyFunction
|
||||
{
|
||||
/**
|
||||
* @var array
|
||||
*/
|
||||
protected $_days = array(
|
||||
'Monday',
|
||||
'Tuesday',
|
||||
'Wednesday',
|
||||
'Thursday',
|
||||
'Friday',
|
||||
'Saturday',
|
||||
'Sunday',
|
||||
);
|
||||
|
||||
/**
|
||||
* Returns an array with schedules for each days.
|
||||
*
|
||||
* @param array $params Parameters of the function
|
||||
* @param $smarty Smarty engine
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function getSchedules(array $params, $smarty)
|
||||
{
|
||||
TNTOfficiel_Debug::log(array('msg' => '>>', 'file' => __FILE__, 'line' => __LINE__));
|
||||
|
||||
// Deafult value
|
||||
if (is_null($params)) {
|
||||
$params = array();
|
||||
}
|
||||
|
||||
$schedules = array();
|
||||
|
||||
if ($hours = $params['hours']) {
|
||||
$index = 0;
|
||||
// Position corresponds to the number of the day
|
||||
$position = 0;
|
||||
// Current day
|
||||
$day = null;
|
||||
// Part of the day
|
||||
$part = null;
|
||||
|
||||
foreach ($hours as $hour) {
|
||||
$hour = trim($hour);
|
||||
$day = $this->_days[$position];
|
||||
|
||||
if (($index % 2 === 0) && ($index % 4 === 0)) {
|
||||
$part = 'AM';
|
||||
} elseif (($index % 2 === 0) && ($index % 4 === 2)) {
|
||||
$part = 'PM';
|
||||
}
|
||||
|
||||
// Prepare the current Day
|
||||
if (!isset($schedules[$day])) {
|
||||
$schedules[$day] = array();
|
||||
}
|
||||
|
||||
// Prepare the current period of the current dya
|
||||
if (!isset($schedules[$day][$part]) && $hour) {
|
||||
$schedules[$day][$part] = array();
|
||||
}
|
||||
|
||||
// If hours different from 0
|
||||
if ($hour) {
|
||||
// Add hour
|
||||
$schedules[$day][$part][] = $hour;
|
||||
}
|
||||
|
||||
++$index;
|
||||
|
||||
if ($index % 4 == 0) {
|
||||
++$position;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ($assign = $params['assign']) {
|
||||
$smarty->assign(array(
|
||||
$assign => $schedules,
|
||||
));
|
||||
}
|
||||
}
|
||||
}
|
18
www/modules/tntofficiel/libraries/smarty/index.php
Normal file
18
www/modules/tntofficiel/libraries/smarty/index.php
Normal file
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
/**
|
||||
* TNT OFFICIAL MODULE FOR PRESTASHOP.
|
||||
*
|
||||
* @author GFI Informatique <www.gfi.fr>
|
||||
* @copyright 2016-2017 GFI Informatique, 2016-2017 TNT
|
||||
* @license https://opensource.org/licenses/MIT MIT License
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../');
|
||||
exit;
|
706
www/modules/tntofficiel/log/TNT-request-20170911.log
Normal file
706
www/modules/tntofficiel/log/TNT-request-20170911.log
Normal file
@ -0,0 +1,706 @@
|
||||
20170911 15:01:44 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:02:12 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:02:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:05:07 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:05:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:05:39 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:08:38 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:08:59 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:09:04 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:09:40 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:10:07 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:10:22 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:11:21 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:13:51 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:13:53 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:14:02 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:14:11 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:14:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:14:30 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:14:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:15:30 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:15:34 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:17:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:17:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:17:22 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:17:32 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:19:15 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:19:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:19:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:19:44 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:19:47 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:21:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:21:57 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:22:02 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:22:07 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:22:25 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:22:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:23:09 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:23:15 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:25:22 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:25:31 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:26:53 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:27:33 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:28:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:28:37 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:28:41 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:28:42 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:28:43 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:28:51 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:29:44 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:29:44 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:29:46 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:32:43 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:32:58 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:33:16 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:33:17 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:33:18 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:35:25 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:35:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:35:43 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:35:44 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:35:51 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:35:52 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:35:53 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:36:03 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:36:03 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:36:05 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:36:31 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:36:46 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:37:14 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:37:14 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:37:15 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:37:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:37:23 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:38:58 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:38:58 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:39:00 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:39:12 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:39:12 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:39:13 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:39:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:39:42 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:39:43 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:40:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:40:42 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:40:44 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:40:53 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:40:53 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:40:55 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:41:45 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:41:45 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:41:47 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:41:54 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:41:55 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:41:57 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:42:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:42:25 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:42:27 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:42:50 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:42:50 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:42:52 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:43:05 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:43:22 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:43:23 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:43:23 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:43:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:43:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:43:27 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:43:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:43:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:44:25 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:44:25 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:44:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:44:31 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:44:32 - 08949425 SUCCESS JSON:getRelayPoints
|
||||
20170911 15:44:32 - 08949425 SUCCESS JSON:getCities
|
||||
20170911 15:44:41 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:45:00 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:45:00 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:45:02 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:46:51 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:46:51 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:46:52 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:49:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:49:26 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:49:27 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:49:33 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:49:33 - 08949425 SUCCESS JSON:getRelayPoints
|
||||
20170911 15:49:34 - 08949425 SUCCESS JSON:getCities
|
||||
20170911 15:49:38 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:49:38 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:49:40 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:49:44 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:50:14 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:50:16 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:50:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:50:19 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:50:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:50:49 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:51:57 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:52:04 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:52:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:52:17 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:52:18 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:52:25 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:52:25 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:52:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:52:37 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:52:37 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:52:39 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:53:47 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:53:47 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:53:49 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:54:18 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:54:18 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:54:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:54:43 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:54:46 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:56:23 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:56:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:56:30 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:56:56 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:56:56 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:56:57 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:57:46 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:57:46 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:57:47 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:58:41 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:58:41 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:58:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:59:21 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 15:59:21 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 15:59:22 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:00:25 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:00:26 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 16:00:27 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:00:31 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:00:31 - 08949425 SUCCESS JSON:getRelayPoints
|
||||
20170911 16:00:31 - 08949425 SUCCESS JSON:getCities
|
||||
20170911 16:01:04 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:01:10 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:01:18 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:01:18 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 16:01:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:02:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:02:25 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:02:54 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:03:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:05:43 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:06:50 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:07:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:07:53 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:08:00 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:08:10 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:08:11 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:08:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:08:32 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:08:56 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:09:10 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:09:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:09:38 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:09:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:11:04 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:11:15 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:11:39 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:11:49 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:12:32 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:12:39 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:12:48 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:13:14 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:13:34 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:13:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:14:27 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:14:37 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:14:52 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:14:53 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:15:14 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:15:15 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:15:16 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:15:23 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:15:50 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:16:13 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:17:18 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:17:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:17:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:17:46 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:17:54 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:18:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:18:23 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:18:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:18:46 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:19:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:19:44 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:19:51 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:20:37 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:21:55 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:21:57 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:22:21 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:22:45 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:23:08 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:23:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:23:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:23:48 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:24:05 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:24:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:24:37 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:25:11 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:25:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:25:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:25:37 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:25:41 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:25:45 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:26:05 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:26:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:26:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:27:45 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:28:06 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:28:16 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:28:39 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:28:41 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:29:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:29:49 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:32:45 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:33:59 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:35:39 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:37:31 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:37:31 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 16:37:32 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:37:38 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:37:38 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 16:37:40 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:37:59 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:37:59 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 16:38:00 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:38:13 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:38:13 - 08949425 SUCCESS JSON:getRelayPoints
|
||||
20170911 16:38:13 - 08949425 SUCCESS JSON:getCities
|
||||
20170911 16:38:14 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:38:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:38:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:39:29 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:39:50 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:44:02 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:44:06 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:44:49 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:44:52 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:45:16 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:45:21 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:45:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:46:13 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:46:40 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:47:23 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:47:48 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:48:09 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:48:11 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:48:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:50:14 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:50:30 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:50:31 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:50:41 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:50:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:50:59 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:52:03 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:52:16 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:55:44 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:55:57 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:56:10 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:57:33 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:58:34 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:59:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:59:29 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:59:40 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 16:59:52 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:00:00 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:00:05 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:00:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:00:48 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:01:21 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:01:43 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:02:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:04:09 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:04:49 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:05:13 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:05:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:05:46 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:06:29 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:06:34 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:07:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:07:32 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:07:34 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:08:10 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:08:21 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:11:08 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:12:01 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:13:45 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:14:11 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:14:47 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:15:06 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:16:41 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:20:16 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:21:03 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:21:08 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:21:12 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:22:25 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:22:32 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:22:32 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 17:22:33 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:24:21 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:24:33 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:24:41 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:25:30 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:25:33 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:27:14 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:28:30 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:28:41 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:28:45 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:28:59 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:29:03 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:30:08 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:30:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:30:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:30:43 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:30:55 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:30:56 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:31:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:32:01 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:32:06 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:33:12 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:33:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:33:50 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:33:51 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:34:40 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:34:45 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:36:09 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:36:58 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:36:59 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:37:09 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:37:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:37:37 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:38:01 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:38:03 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:38:14 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:39:11 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:39:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:41:22 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:41:25 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:41:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:41:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:41:44 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:41:46 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:41:47 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:41:54 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:41:54 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:42:18 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:43:09 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:43:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:44:12 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:44:39 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:44:44 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:44:53 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:45:00 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:46:15 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:46:21 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:46:49 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:47:14 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:47:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:47:38 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:48:30 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:48:31 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:51:15 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:51:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:51:40 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:52:46 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:54:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:55:13 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:55:21 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:55:29 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:55:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:56:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:57:08 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:57:56 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:58:40 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 17:59:13 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:00:41 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:00:47 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:00:48 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:00:52 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:01:02 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:01:38 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:01:43 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:01:53 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:02:29 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:02:50 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:03:09 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:03:16 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:03:37 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:03:47 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:03:50 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:03:52 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:05:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:05:48 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:05:53 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:05:59 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:05:59 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 18:06:00 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:06:11 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:06:33 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:07:21 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:08:11 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:08:55 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:09:22 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:09:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:09:40 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:09:48 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:16:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:16:21 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:16:23 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:16:48 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:21:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:21:21 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:27:07 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:32:25 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:32:31 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:32:39 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:33:03 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:42:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:42:38 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:44:01 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:44:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:44:22 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:48:07 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:48:12 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:48:12 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 18:48:13 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:48:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:48:19 - 08949425 SUCCESS JSON:getRelayPoints
|
||||
20170911 18:48:20 - 08949425 SUCCESS JSON:getCities
|
||||
20170911 18:49:30 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:49:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:49:40 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:49:41 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 18:49:41 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:49:49 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:50:59 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:50:59 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 18:51:00 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:51:04 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:51:05 - 08949425 SUCCESS JSON:getRelayPoints
|
||||
20170911 18:51:05 - 08949425 SUCCESS JSON:getCities
|
||||
20170911 18:51:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:54:33 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:54:33 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 18:54:34 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:54:50 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:55:13 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 18:55:13 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 18:55:14 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 20:46:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 20:46:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 20:46:32 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 20:46:41 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 20:48:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 20:48:56 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 20:49:32 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 20:51:06 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:10:49 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:11:03 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:11:08 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:11:23 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:14:50 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:14:52 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:14:58 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:16:56 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:17:01 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:17:14 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:19:10 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:19:12 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:20:12 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:21:43 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:21:51 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:23:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:25:52 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:29:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:33:13 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:34:31 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:43:27 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:43:32 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:43:56 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:44:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:44:31 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:44:34 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:45:11 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:47:06 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:47:10 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:47:46 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:54:32 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:54:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:55:40 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:55:45 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:56:04 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:56:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:56:30 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:56:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:56:45 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:56:52 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:56:56 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:57:09 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:57:12 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:57:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:57:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:57:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:57:39 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:57:44 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:58:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:58:27 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:58:37 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:58:39 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:58:47 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:58:50 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:58:58 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:58:59 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:59:08 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:59:10 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:59:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:59:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:59:27 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 21:59:29 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:01:52 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:01:54 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:01:58 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:05:18 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:05:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:07:40 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:08:01 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:08:22 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:08:23 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:08:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:09:11 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:09:11 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:09:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:09:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:10:49 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:10:55 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:11:41 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:12:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:13:34 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:17:49 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:28:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:29:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:29:46 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:30:07 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:30:10 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:30:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:30:21 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:30:32 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:30:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:32:34 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:45:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:50:34 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:50:38 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:56:15 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:56:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:56:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:56:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:56:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 22:56:43 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:03:48 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:03:53 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:04:02 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:04:23 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:04:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:04:31 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:04:40 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:13:27 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:14:01 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:14:03 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:14:15 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:14:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:14:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:14:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:18:09 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:18:14 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:18:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:22:01 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:24:14 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:24:22 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:24:30 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:24:57 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:29:08 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:29:09 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 23:29:09 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:29:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:29:56 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:29:56 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 23:29:57 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:30:12 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:30:13 - 08949425 SUCCESS JSON:getRelayPoints
|
||||
20170911 23:30:13 - 08949425 SUCCESS JSON:getCities
|
||||
20170911 23:31:11 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:31:11 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 23:31:12 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:31:16 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:33:39 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:33:39 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 23:33:39 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:33:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:33:43 - 08949425 SUCCESS JSON:getRelayPoints
|
||||
20170911 23:33:43 - 08949425 SUCCESS JSON:getCities
|
||||
20170911 23:33:47 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:33:48 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:35:12 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:35:12 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 23:35:13 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:35:18 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:35:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:35:29 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:35:30 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:35:50 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:35:55 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:36:03 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:36:10 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:36:13 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:36:22 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:38:46 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:39:00 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:39:01 - 08949425 SUCCESS JSON:testCity
|
||||
20170911 23:39:01 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:39:34 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:40:12 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:40:16 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:40:54 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:41:01 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:45:15 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:45:18 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:45:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:46:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:46:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:47:16 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:47:22 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:47:39 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:48:46 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:48:47 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:48:47 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:49:14 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:49:21 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:49:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:52:21 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:53:56 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:54:05 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:54:57 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:55:04 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:55:53 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:56:09 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:56:43 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:56:59 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:58:08 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:58:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:59:13 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:59:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:59:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:59:29 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:59:30 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:59:31 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:59:32 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:59:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170911 23:59:56 - 08949425 SUCCESS JSON:getCarrierQuote
|
214
www/modules/tntofficiel/log/TNT-request-20170912.log
Normal file
214
www/modules/tntofficiel/log/TNT-request-20170912.log
Normal file
@ -0,0 +1,214 @@
|
||||
20170912 00:04:08 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:04:08 - 08949425 SUCCESS JSON:testCity
|
||||
20170912 00:04:09 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:04:14 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:04:34 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:04:34 - 08949425 SUCCESS JSON:testCity
|
||||
20170912 00:04:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:04:40 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:04:41 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:05:51 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:05:55 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:07:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:10:07 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:12:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:12:38 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:14:50 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:14:59 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:15:05 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:15:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:15:29 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:15:34 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:15:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:15:52 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:15:55 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:16:12 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:16:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:16:29 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:16:50 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:16:51 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:16:55 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:17:00 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:17:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:17:38 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:17:40 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:17:44 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:17:51 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:17:54 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:17:59 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:18:11 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:18:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:18:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:19:18 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:19:23 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:19:43 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:19:50 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:19:55 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:20:02 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:20:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:20:45 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:20:47 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:21:01 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:21:10 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:21:23 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:21:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:21:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:21:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:21:33 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:21:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:21:43 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:21:44 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:21:51 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:21:51 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:21:55 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:22:02 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:22:02 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:22:04 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:22:11 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:22:15 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:22:18 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:23:05 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:23:07 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:23:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:23:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:23:22 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:23:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:23:34 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:23:39 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:23:40 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:23:48 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:23:50 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:24:01 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:24:58 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:25:04 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:25:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:26:00 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:26:03 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:26:08 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:26:13 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:26:27 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:26:58 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:27:02 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:27:04 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:27:08 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:27:38 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:27:45 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:27:59 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:28:02 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:28:16 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:28:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:31:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:31:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:32:02 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:32:03 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:33:11 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:33:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:33:29 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:33:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:34:17 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:34:18 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:34:19 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:34:22 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:34:23 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:34:29 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:34:51 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:35:07 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:35:11 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:35:38 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:35:39 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:36:00 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:36:05 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:36:05 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:36:22 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:36:27 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:36:27 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:39:49 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:42:07 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:42:37 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 00:42:49 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:29:41 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:30:47 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:30:51 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:31:02 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:31:08 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:31:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:31:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:32:48 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:33:39 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:33:58 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:34:49 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:35:03 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:40:48 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:41:18 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:41:32 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:44:31 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:46:22 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:47:16 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:53:05 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:55:04 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:58:58 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 09:59:51 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:00:10 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:00:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:00:43 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:01:33 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:01:59 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:02:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:07:12 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:07:25 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:07:26 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:07:34 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:07:47 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:07:55 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:07:55 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:08:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:08:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:09:52 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:10:40 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:11:56 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:16:49 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:20:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:23:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:23:37 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:24:02 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:25:05 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:25:10 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:25:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:27:07 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:30:58 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:31:30 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:31:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:31:35 - 08949425 SUCCESS JSON:testCity
|
||||
20170912 10:31:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:33:54 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:33:55 - 08949425 SUCCESS JSON:testCity
|
||||
20170912 10:33:56 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:34:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:34:29 - 08949425 SUCCESS JSON:testCity
|
||||
20170912 10:34:29 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:34:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:34:37 - 08949425 SUCCESS JSON:getRelayPoints
|
||||
20170912 10:34:37 - 08949425 SUCCESS JSON:getCities
|
||||
20170912 10:34:41 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:34:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:35:23 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:35:28 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:35:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:39:36 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:39:42 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:39:44 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:43:21 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:43:23 - 08949425 SUCCESS JSON:testCity
|
||||
20170912 10:43:24 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:43:35 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:44:46 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:44:55 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:44:55 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:45:22 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:45:45 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:45:50 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:45:54 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:46:15 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:46:20 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:47:05 - 08949425 SUCCESS JSON:getCarrierQuote
|
||||
20170912 10:47:09 - 08949425 SUCCESS JSON:getCarrierQuote
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user