forked from pal/prestashop
-
Notifications
You must be signed in to change notification settings - Fork 0
/
history.php
30 lines (23 loc) · 837 Bytes
/
history.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
<?php
/* SSL Management */
$useSSL = true;
include(dirname(__FILE__).'/config/config.inc.php');
include(dirname(__FILE__).'/init.php');
if (!$cookie->isLogged())
Tools::redirect('authentication.php?back=history.php');
/* JS files call */
$js_files = array(__PS_BASE_URI__.'js/jquery/jquery.scrollto.js', _THEME_JS_DIR_.'history.js');
if ($orders = Order::getCustomerOrders(intval($cookie->id_customer)))
foreach ($orders AS &$order)
{
$myOrder = new Order(intval($order['id_order']));
if (Validate::isLoadedObject($myOrder))
$order['virtual'] = $myOrder->isVirtual(false);
}
include(dirname(__FILE__).'/header.php');
$smarty->assign(array(
'orders' => $orders,
'invoiceAllowed' => intval(Configuration::get('PS_INVOICE'))));
$smarty->display(_PS_THEME_DIR_.'history.tpl');
include(dirname(__FILE__).'/footer.php');
?>