first commit

This commit is contained in:
2025-01-06 20:47:25 +01:00
commit 3bdbd78c2f
25591 changed files with 3586440 additions and 0 deletions

View File

@@ -0,0 +1,40 @@
<?php
/**
* NOTICE OF LICENSE
*
* This source file is subject to a trade license awarded by
* Garamo Online L.T.D.
*
* Any use, reproduction, modification or distribution
* of this source file without the written consent of
* Garamo Online L.T.D It Is prohibited.
*
* @author ReactionCode <info@reactioncode.com>
* @copyright 2015-2020 Garamo Online L.T.D
* @license Commercial license
*/
class Rc_PgAnalyticsClientId extends ObjectModel
{
public $id_customer;
public $id_shop;
public $client_id;
public static $definition = array(
'table' => 'rc_pganalytics_client_id',
'primary' => 'id_customer',
'fields' => array(
'id_customer' => array('type' => self::TYPE_INT, 'validate' => 'isUnsignedId', 'required' => true),
'id_shop' => array('type' => self::TYPE_INT, 'validate' => 'isUnsignedId', 'required' => true),
'client_id' => array('type' => self::TYPE_STRING, 'validate' => 'isGenericName', 'required' => true),
)
);
public static function getClientIdByCustomerId($id_customer)
{
$query = 'SELECT client_id FROM `'._DB_PREFIX_.'rc_pganalytics_client_id`
WHERE id_customer = '.(int)$id_customer
;
return Db::getInstance()->getValue($query);
}
}

View File

@@ -0,0 +1,50 @@
<?php
/**
* NOTICE OF LICENSE
*
* This source file is subject to a trade license awarded by
* Garamo Online L.T.D.
*
* Any use, reproduction, modification or distribution
* of this source file without the written consent of
* Garamo Online L.T.D It Is prohibited.
*
* @author ReactionCode <info@reactioncode.com>
* @copyright 2015-2020 Garamo Online L.T.D
* @license Commercial license
*/
class Rc_PgAnalyticsOrderSent extends ObjectModel
{
public $id_order;
public $id_shop;
public $sent_from;
public $sent_at;
public static $definition = array(
'table' => 'rc_pganalytics_orders_sent',
'primary' => 'id_order',
'fields' => array(
'id_order' => array('type' => self::TYPE_INT, 'validate' => 'isUnsignedId', 'required' => true),
'id_shop' => array('type' => self::TYPE_INT, 'validate' => 'isUnsignedId', 'required' => true),
'sent_from' => array('type' => self::TYPE_STRING, 'validate' => 'isGenericName', 'required' => true),
'sent_at' => array('type' => self::TYPE_DATE, 'validate' => 'isDate', 'required' => true),
)
);
public static function getOrderReport($id_order, $id_shop)
{
$query = 'SELECT * FROM `'._DB_PREFIX_.'rc_pganalytics_orders_sent`
WHERE id_order = '.(int)$id_order.' AND id_shop = '.(int)$id_shop
;
return Db::getInstance()->getRow($query);
}
public static function removeOrder($id_order, $id_shop)
{
$query = 'DELETE FROM `'._DB_PREFIX_.'rc_pganalytics_orders_sent`
WHERE id_order = '.(int)$id_order.' AND id_shop = '.(int)$id_shop
;
return Db::getInstance()->execute($query);
}
}

View File

@@ -0,0 +1,35 @@
<?php
/*
* 2007-2011 PrestaShop
*
* NOTICE OF LICENSE
*
* This source file is subject to the Open Software License (OSL 3.0)
* that is bundled with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://opensource.org/licenses/osl-3.0.php
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@prestashop.com so we can send you a copy immediately.
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
* versions in the future. If you wish to customize PrestaShop for your
* needs please refer to http://www.prestashop.com for more information.
*
* @author PrestaShop SA <contact@prestashop.com>
* @copyright 2007-2011 PrestaShop SA
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
* International Registered Trademark & Property of PrestaShop SA
*/
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;