Merge branch 'develop' into gli-926

This commit is contained in:
vishalsingh.qlo325
2024-08-13 10:07:29 +05:30
320 changed files with 9951 additions and 9891 deletions

1
.gitignore vendored
View File

@@ -53,6 +53,7 @@ composer.lock
img/**
!/img/404.gif
!/img/.htaccess
!/img/admin/
!/img/admin/*.gif
!/img/admin/*.png

View File

@@ -1,2 +1,10 @@
Order deny,allow
Deny from all
# Apache 2.2
<IfModule !mod_authz_core.c>
Order deny,allow
Deny from all
</IfModule>
# Apache 2.4
<IfModule mod_authz_core.c>
Require all denied
</IfModule>

View File

@@ -1,2 +1,10 @@
Order deny,allow
Deny from all
# Apache 2.2
<IfModule !mod_authz_core.c>
Order deny,allow
Deny from all
</IfModule>
# Apache 2.4
<IfModule mod_authz_core.c>
Require all denied
</IfModule>

View File

@@ -1,2 +1,10 @@
Order deny,allow
Deny from all
# Apache 2.2
<IfModule !mod_authz_core.c>
Order deny,allow
Deny from all
</IfModule>
# Apache 2.4
<IfModule mod_authz_core.c>
Require all denied
</IfModule>

View File

@@ -1,2 +1,10 @@
Order deny,allow
Deny from all
# Apache 2.2
<IfModule !mod_authz_core.c>
Order deny,allow
Deny from all
</IfModule>
# Apache 2.4
<IfModule mod_authz_core.c>
Require all denied
</IfModule>

View File

@@ -77,3 +77,22 @@
.room_status_info_form
.room_status
white-space: normal
#noteContent
max-height: 200px
.panel-refund-request .refunded_amount
margin-top: 2px
.panel-guest_address
.panel-heading
align-items: center
display: flex
gap: 10px
justify-content: space-between
.panel-title
width: 100%
.dropdown-menu
right: 0
left: unset
font-size: 14px

View File

@@ -9,7 +9,7 @@
// Kill the scroll on the body
.modal-open {
overflow-x: hidden;
overflow: hidden;
}
// Container that the modal scrolls within

View File

@@ -29,31 +29,29 @@
{if $input.name == 'vat_number'}
<div id="vat_area" style="display: visible">
{/if}
{if $input.type == 'text_customer' && !isset($customer)}
<label class="control-label col-lg-3 required" for="email">{l s='Customer email'}</label>
{else}
{$smarty.block.parent}
{/if}
{$smarty.block.parent}
{/block}
{block name="field"}
{block name="input"}
{if $input.type == 'text_customer'}
{if isset($customer)}
<div class="col-lg-9">
<a class="btn btn-default" href="?tab=AdminCustomers&amp;id_customer={$customer->id|intval}&amp;viewcustomer&amp;token={$tokenCustomer}">
<i class="icon-eye-open"></i> {$customer->lastname} {$customer->firstname} ({$customer->email})
</a>
</div>
<a class="btn btn-default" href="?tab=AdminCustomers&amp;id_customer={$customer->id|intval}&amp;viewcustomer&amp;token={$tokenCustomer}">
<i class="icon-eye-open"></i> {$customer->lastname} {$customer->firstname} ({$customer->email})
</a>
<input type="hidden" name="id_customer" value="{$customer->id}" />
<input type="hidden" name="email" value="{$customer->email}" />
{else}
<script type="text/javascript">
$('input[name=email]').live('blur', function(e)
{/if}
{else if $input.type == 'select' && $input.name == 'id_customer'}
{$smarty.block.parent}
<input type="hidden" name="email" id="email" value="">
<script type="text/javascript">
$('#id_customer').on('change', function(e)
{
var email = $(this).val();
if (email.length > 5)
{
var id_customer = parseInt($(this).val());
$('#email').val('');
if (!isNaN(id_customer)) {
var email = $(this).find('[value="'+id_customer+'"]').text();
$('#email').val(email);
var data = {};
data.email = email;
data.token = "{$token|escape:'html':'UTF-8'}";
@@ -66,31 +64,29 @@
data: data,
dataType: 'json',
async : true,
success: function(msg)
{
if (msg)
{
success: function(msg) {
if (msg) {
var infos = msg.infos.replace("\\'", "'").split('_');
$('input[name=firstname]').val(infos[0]);
$('input[name=lastname]').val(infos[1]);
$('input[name=company]').val(infos[2]);
$('input[name=id_customer]').val(infos[3]);
} else {
resetCustomerRelatedAddressFields();
}
},
error: function(msg)
{
}
});
} else {
resetCustomerRelatedAddressFields();
}
});
</script>
<div class="col-lg-4">
<input type="hidden" name="id_customer" value="{$fields_value[$input.name]}" />
<input type="email" id="email" name="email" value="{$fields_value[$input.name]|escape:'html':'UTF-8'}"/>
</div>
{/if}
function resetCustomerRelatedAddressFields() {
$('input[name=firstname]').val('');
$('input[name=lastname]').val('');
$('input[name=company]').val('');
$('input[name=id_customer]').val('');
}
</script>
{else}
{$smarty.block.parent}
{/if}

View File

@@ -33,7 +33,7 @@
{if isset($next_thread) && $next_thread}
<a class="btn btn-default pull-right" href="{$next_thread.href|escape:'html':'UTF-8'}">
{$next_thread.name} <i class="icon-forward"></i>
</a>
</a>
{/if}
</div>
<div class="well">
@@ -71,7 +71,7 @@
<div class="col-sm-6">
<p>
{if $count_ok}
{l s='[1]%1$d[/1] order(s) validated for a total amount of [2]%2$s[/2]' sprintf=[$count_ok, $total_ok] tags=['<span class="badge">', '<span class="badge badge-success">']}
{l s='[1]%1$d[/1] order(s) validated, total amount paid [2]%2$s[/2]' sprintf=[$count_ok, $total_ok] tags=['<span class="badge">', '<span class="badge badge-success">']}
{else}
{l s="No orders validated for the moment"}
{/if}
@@ -115,7 +115,7 @@
<i class="icon-magic icon-2x"></i><br>
{l s="Choose a template"}
</button>
-->
-->
<button class="btn btn-default pull-right" name="submitReply"><i class="process-icon-mail-reply"></i> {l s="Send"}</button>
<input type="hidden" name="id_customer_thread" value="{$thread->id|intval}" />
<input type="hidden" name="msg_email" value="{$thread->email}" />
@@ -159,7 +159,7 @@
});
timer = setInterval("markAsRead()", 3000);
});
function markAsRead()
{
$.ajax({

View File

@@ -146,15 +146,27 @@
<label class="control-label col-lg-3">{l s='Status'}</label>
<div class="col-lg-9">
<p class="form-control-static">
{if $customer->active}
<span class="label label-success">
<i class="icon-check"></i>
{l s='Active'}
{if !$customer->deleted}
{if $customer->active}
<span class="label label-success">
<i class="icon-check"></i>
{l s='Active'}
</span>
{else}
<span class="label label-danger">
<i class="icon-remove"></i>
{l s='Inactive'}
</span>
{/if}
{elseif $customer->deleted == Customer::STATUS_BANNED}
<span class="label label-warning">
<i class="icon-remove"></i>
{l s='Banned'}
</span>
{else}
{elseif $customer->deleted == Customer::STATUS_DELETED}
<span class="label label-danger">
<i class="icon-remove"></i>
{l s='Inactive'}
{l s='Deleted'}
</span>
{/if}
</p>
@@ -185,85 +197,122 @@
{if $orders AND count($orders)}
{assign var=count_ok value=count($orders_ok)}
{assign var=count_ko value=count($orders_ko)}
<div class="panel">
<div class="row">
<div class="col-lg-6">
<i class="icon-ok-circle icon-big"></i>
{l s='Valid orders:'}
<span class="label label-success">{$count_ok}</span>
{l s='for a total amount of %s' sprintf=$total_ok}
</div>
<div class="col-lg-6">
<i class="icon-exclamation-sign icon-big"></i>
{l s='Invalid orders:'}
<span class="label label-danger">{$count_ko}</span>
{if $count_ok || $count_ko}
<div class="nav nav-tabs">
<ul class="nav nav-tabs">
<li {if $count_ok}class="active"{/if}>
<a data-toggle="tab" href="#valid_orders">
<i class="icon-ok-circle icon-big"></i>
{l s='Valid orders:'}
<span class="label label-success">{$count_ok}</span>
</a>
</li>
<li {if !$count_ok && $count_ko}class="active"{/if}>
<a data-toggle="tab" href="#invalid_orders">
<i class="icon-exclamation-sign icon-big"></i>
{l s='Invalid orders:'}
<span class="label label-danger">{$count_ko}</span>
</a>
</li>
</ul>
<div class="tab-content panel">
<div class="tab-pane {if $count_ok}active{/if}" id="valid_orders">
<div class="row">
<div class="col-lg-5">
{l s='Total amount received: %s' sprintf=$total_ok}
</div>
</div>
<hr>
{if $count_ok}
<table class="table">
<thead>
<tr>
<th class="center"><span class="title_box ">{l s='ID'}</span></th>
<th><span class="title_box">{l s='Date'}</span></th>
<th><span class="title_box">{l s='Payment'}</span></th>
<th><span class="title_box">{l s='Status'}</span></th>
<th><span class="title_box">{l s='Products'}</span></th>
<th><span class="title_box ">{l s='Total spent'}</span></th>
<th></th>
</tr>
</thead>
<tbody>
{foreach $orders_ok AS $key => $order}
<tr onclick="document.location = '?tab=AdminOrders&amp;id_order={$order['id_order']|intval}&amp;vieworder&amp;token={getAdminToken tab='AdminOrders'}'">
<td>{$order['id_order']}</td>
<td>{dateFormat date=$order['date_add'] full=0}</td>
<td>{$order['payment']}</td>
<td>{$order['order_state']}</td>
<td>{$order['nb_products']}</td>
<td>{$order['total_paid_real']}</td>
<td>
<a class="btn btn-default" href="?tab=AdminOrders&amp;id_order={$order['id_order']|intval}&amp;vieworder&amp;token={getAdminToken tab='AdminOrders'}">
<i class='icon-search'></i> {l s='View'}
</a>
</td>
</tr>
{/foreach}
</tbody>
</table>
{else}
<p class="text-muted text-center">
{l s='No valid order found!!'}
</p>
{/if}
</div>
<div class="tab-pane {if !$count_ok && $count_ko}active{/if}" id="invalid_orders">
<div class="row">
<div class="col-lg-5">
{l s='Order total: %s' sprintf=$total_ko}
</div>
</div>
<hr>
{if $count_ko}
<table class="table">
<thead>
<tr>
<th><span class="title_box ">{l s='ID'}</span></th>
<th><span class="title_box ">{l s='Date'}</span></th>
<th><span class="title_box ">{l s='Payment'}</span></th>
<th><span class="title_box ">{l s='Status'}</span></th>
<th><span class="title_box ">{l s='Products'}</span></th>
<th><span class="title_box ">{l s='Total spent'}</span></th>
<th></th>
</tr>
</thead>
<tbody>
{foreach $orders_ko AS $key => $order}
<tr onclick="document.location = '?tab=AdminOrders&amp;id_order={$order['id_order']|intval}&amp;vieworder&amp;token={getAdminToken tab='AdminOrders'}'">
<td>{$order['id_order']}</td>
<td>{dateFormat date=$order['date_add'] full=0}</a></td>
<td>{$order['payment']}</td>
<td>{$order['order_state']}</td>
<td>{$order['nb_products']}</td>
<td>{$order['total_paid_real']}</td>
<td>
<a class="btn btn-default" href="?tab=AdminOrders&amp;id_order={$order['id_order']|intval}&amp;vieworder&amp;token={getAdminToken tab='AdminOrders'}">
<i class='icon-search'></i> {l s='View'}
</a>
</td>
</tr>
{/foreach}
</tbody>
</table>
{else}
<p class="text-muted text-center">
{l s='No invalid order found!!'}
</p>
{/if}
</div>
</div>
</div>
</div>
{if $count_ok}
<table class="table">
<thead>
<tr>
<th class="center"><span class="title_box ">{l s='ID'}</span></th>
<th><span class="title_box">{l s='Date'}</span></th>
<th><span class="title_box">{l s='Payment'}</span></th>
<th><span class="title_box">{l s='Status'}</span></th>
<th><span class="title_box">{l s='Products'}</span></th>
<th><span class="title_box ">{l s='Total spent'}</span></th>
<th></th>
</tr>
</thead>
<tbody>
{foreach $orders_ok AS $key => $order}
<tr onclick="document.location = '?tab=AdminOrders&amp;id_order={$order['id_order']|intval}&amp;vieworder&amp;token={getAdminToken tab='AdminOrders'}'">
<td>{$order['id_order']}</td>
<td>{dateFormat date=$order['date_add'] full=0}</td>
<td>{$order['payment']}</td>
<td>{$order['order_state']}</td>
<td>{$order['nb_products']}</td>
<td>{$order['total_paid_real']}</td>
<td>
<a class="btn btn-default" href="?tab=AdminOrders&amp;id_order={$order['id_order']|intval}&amp;vieworder&amp;token={getAdminToken tab='AdminOrders'}">
<i class='icon-search'></i> {l s='View'}
</a>
</td>
</tr>
{/foreach}
</tbody>
</table>
{/if}
{if $count_ko}
<table class="table">
<thead>
<tr>
<th><span class="title_box ">{l s='ID'}</span></th>
<th><span class="title_box ">{l s='Date'}</span></th>
<th><span class="title_box ">{l s='Payment'}</span></th>
<th><span class="title_box ">{l s='Status'}</span></th>
<th><span class="title_box ">{l s='Products'}</span></th>
<th><span class="title_box ">{l s='Total spent'}</span></th>
</tr>
</thead>
<tbody>
{foreach $orders_ko AS $key => $order}
<tr onclick="document.location = '?tab=AdminOrders&amp;id_order={$order['id_order']|intval}&amp;vieworder&amp;token={getAdminToken tab='AdminOrders'}'">
<td>{$order['id_order']}</td>
<td><a href="?tab=AdminOrders&amp;id_order={$order['id_order']}&amp;vieworder&amp;token={getAdminToken tab='AdminOrders'}">{dateFormat date=$order['date_add'] full=0}</a></td>
<td>{$order['payment']}</td>
<td>{$order['order_state']}</td>
<td>{$order['nb_products']}</td>
<td>{$order['total_paid_real']}</td>
</tr>
{/foreach}
</tbody>
</table>
{/if}
{else}
<p class="text-muted text-center">
{l s='%1$s %2$s has not placed any orders yet' sprintf=[$customer->firstname, $customer->lastname]}
</p>
<p class="text-muted text-center">
{l s='%1$s %2$s has not placed any orders yet' sprintf=[$customer->firstname, $customer->lastname]}
</p>
{/if}
</div>
@@ -277,7 +326,6 @@
<tr>
<th><span class="title_box ">{l s='ID'}</span></th>
<th><span class="title_box ">{l s='Date'}</span></th>
<th><span class="title_box ">{l s='Carrier'}</span></th>
<th><span class="title_box ">{l s='Total'}</span></th>
</tr>
</thead>
@@ -290,7 +338,6 @@
{dateFormat date=$cart['date_upd'] full=0}
</a>
</td>
<td>{$cart['name']}</td>
<td>{$cart['total_price']}</td>
</tr>
{/foreach}
@@ -303,33 +350,95 @@
{/if}
</div>
{if $products AND count($products)}
<div class="panel">
<div class="panel-heading">
<i class="icon-archive"></i> {l s='Purchased products'} <span class="badge">{count($products)}</span>
<div class="panel">
<div class="panel-heading">
<i class="icon-archive"></i> {l s='Room types and services'} <span class="badge">{count($products)}</span>
</div>
<div class="nav nav-tabs">
<ul class="nav nav-tabs">
{assign var=count_room_types value=count($purchasedRoomTypes)}
{assign var=count_services value=count($purchasedServices)}
{if $count_room_types}
<li class="active">
<a data-toggle="tab" href="#purchased_room_types">
{l s='Room Types'}
<span class="label label-success">{$count_room_types}</span>
</a>
</li>
{/if}
{if $count_services}
<li {if !$count_room_types} class="active" {/if}>
<a data-toggle="tab" href="#purchased_services">
{l s='Services:'}
<span class="label label-success">{$count_services}</span>
</a>
</li>
{/if}
</ul>
<div class="tab-content panel">
{if $count_room_types}
<div class="tab-pane active" id="purchased_room_types">
<table class="table">
<thead>
<tr>
<th><span class="title_box">{l s='ID Order'}</span></th>
<th><span class="title_box">{l s='Name'}</span></th>
<th><span class="title_box">{l s='Nights booked'}</span></th>
<th><span class="title_box">{l s='Booking Date'}</span></th>
</tr>
</thead>
<tbody>
{foreach $purchasedRoomTypes AS $key => $product}
<tr onclick="document.location = '?tab=AdminOrders&amp;id_order={$product['id_order']|intval}&amp;vieworder&amp;token={getAdminToken tab='AdminOrders'}'">
<td>
<a href="?tab=AdminOrders&amp;id_order={$product['id_order']}&amp;vieworder&amp;token={getAdminToken tab='AdminOrders'}">
#{$product['id_order']}
</a>
</td>
<td>
{$product['product_name']}
</td>
<td>{$product['product_quantity']}</td>
<td>{dateFormat date=$product['date_add'] full=0}</td>
</tr>
{/foreach}
</tbody>
</table>
</div>
{/if}
{if $count_services}
<div class="tab-pane {if !$count_room_types}active{/if}" id="purchased_services">
<table class="table">
<thead>
<tr>
<th><span class="title_box">{l s='ID Order'}</span></th>
<th><span class="title_box">{l s='Name'}</span></th>
<th><span class="title_box">{l s='Quantity'}</span></th>
<th><span class="title_box">{l s='Booking Date'}</span></th>
</tr>
</thead>
<tbody>
{foreach $purchasedServices AS $key => $product}
<tr onclick="document.location = '?tab=AdminOrders&amp;id_order={$product['id_order']|intval}&amp;vieworder&amp;token={getAdminToken tab='AdminOrders'}'">
<td>
<a href="?tab=AdminOrders&amp;id_order={$product['id_order']}&amp;vieworder&amp;token={getAdminToken tab='AdminOrders'}">
#{$product['id_order']}
</a>
</td>
<td>
{$product['product_name']}
</td>
<td>{$product['product_quantity']}</td>
<td>{dateFormat date=$product['date_add'] full=0}</td>
</tr>
{/foreach}
</tbody>
</table>
</div>
{/if}
</div>
</div>
</div>
<table class="table">
<thead>
<tr>
<th><span class="title_box">{l s='Date'}</span></th>
<th><span class="title_box">{l s='Name'}</span></th>
<th><span class="title_box">{l s='Quantity'}</span></th>
</tr>
</thead>
<tbody>
{foreach $products AS $key => $product}
<tr onclick="document.location = '?tab=AdminOrders&amp;id_order={$product['id_order']|intval}&amp;vieworder&amp;token={getAdminToken tab='AdminOrders'}'">
<td>{dateFormat date=$product['date_add'] full=0}</td>
<td>
<a href="?tab=AdminOrders&amp;id_order={$product['id_order']}&amp;vieworder&amp;token={getAdminToken tab='AdminOrders'}">
{$product['product_name']}
</a>
</td>
<td>{$product['product_quantity']}</td>
</tr>
{/foreach}
</tbody>
</table>
</div>
{/if}
{if count($interested)}
<div class="panel">
@@ -442,7 +551,7 @@
<a href="?tab=AdminCartRules&amp;id_cart_rule={$discount['id_cart_rule']|intval}&amp;addcart_rule&amp;token={getAdminToken tab='AdminCartRules'}&amp;back={$smarty.server.REQUEST_URI|urlencode}">
<i class="icon-pencil"></i>
</a>
<a href="?tab=AdminCartRules&amp;id_cart_rule={$discount['id_cart_rule']|intval}&amp;deletecart_rule&amp;token={getAdminToken tab='AdminCartRules'}&amp;back={$smarty.server.REQUEST_URI|urlencode}">
<a onclick="return confirm('{l s='Are you sure?'}')" href="?tab=AdminCartRules&amp;id_cart_rule={$discount['id_cart_rule']|intval}&amp;deletecart_rule&amp;token={getAdminToken tab='AdminCartRules'}&amp;back={$smarty.server.REQUEST_URI|urlencode}">
<i class="icon-remove"></i>
</a>
</td>

View File

@@ -67,6 +67,7 @@
</label>
<input name="passwd" type="password" id="passwd" class="form-control" value="{if isset($password)}{$password|escape:'html':'UTF-8'}{/if}" tabindex="2" placeholder="&#xf084 {l s='Password'}" />
</div>
{hook h="displayAdminLoginFormFieldsAfter"}
<div class="form-group row-padding-top">
<button name="submitLogin" type="submit" tabindex="4" class="btn btn-primary btn-lg btn-block ladda-button" data-style="slide-up" data-spinner-color="white" >
<span class="ladda-label">

View File

@@ -39,7 +39,7 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="robots" content="NOFOLLOW, NOINDEX">
<title>
{$shop_name} {if $meta_title != ''}{if isset($navigationPipe)}{$navigationPipe|escape:'html':'UTF-8'}{else}&gt;{/if} {$meta_title}{/if} (PrestaShop&trade;)
{$shop_name} {if $meta_title != ''}{if isset($navigationPipe)}{$navigationPipe|escape:'html':'UTF-8'}{else}&gt;{/if} {$meta_title}{/if} (QloApps&trade;)
</title>
{if isset($css_files)}
{foreach from=$css_files key=css_uri item=media}

View File

@@ -92,7 +92,7 @@
{foreach $data['child_ages'] as $childAge}
<p class="col-xs-12 col-sm-12 col-md-6 col-lg-6">
<select class="guest_child_age room_occupancies" name="occupancy[0][child_ages][]">
<option value="-1" {if $childAge == -1}selected{/if}>{l s='Select 1'}</option>
<option value="-1" {if $childAge == -1}selected{/if}>{l s='Select age'}</option>
<option value="0" {if $childAge == 0}selected{/if}>{l s='Under 1'}</option>
{for $age=1 to ($max_child_age-1)}
<option value="{$age|escape:'htmlall':'UTF-8'}" {if $childAge == $age}selected{/if}>{$age|escape:'htmlall':'UTF-8'}</option>

View File

@@ -1,196 +0,0 @@
{*
* 2007-2017 PrestaShop
*
* NOTICE OF LICENSE
*
* This source file is subject to the Academic Free License (AFL 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/afl-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-2017 PrestaShop SA
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
* International Registered Trademark & Property of PrestaShop SA
*}
<tr id="new_product" style="display:none">
<td style="display:none;" colspan="3" class="text-center">
<input type="hidden" id="add_product_product_id" name="add_product[product_id]" value="0" />
<div class="form-group">
<label>{l s='Room Type:'}</label>
<div class="input-group">
<input type="text" id="add_product_product_name" value=""/>
<div class="input-group-addon">
<i class="icon-search"></i>
</div>
</div>
</div>
<!-- <div id="add_product_product_attribute_area" class="form-group" style="display: none;">
<label>{l s='Combinations'}</label>
<select name="add_product[product_attribute_id]" id="add_product_product_attribute_id"></select>
</div>
<div id="add_product_product_warehouse_area" class="form-group" style="display: none;">
<label>{l s='Warehouse'}</label>
<select id="add_product_warehouse" name="add_product_warehouse"></select>
</div> -->
</td>
<td style="display:none;" class="bookingDuration text-center" colspan="2">
<center>
<div class="room_check_in_div">
<div class="input-group fixed-width-xl">
<div class="input-group-addon">{l s='Check In'}</div>
<input type="text" class="form-control add_room_date_from" name="add_product[date_from]" readonly />
<div class="input-group-addon"><i class="icon-calendar"></i></div>
</div>
</div>
<br/>
<div class="room_check_out_div">
<div class="input-group fixed-width-xl">
<div class="input-group-addon">{l s='Check Out'}</div>
<input type="text" class="form-control add_room_date_to" name="add_product[date_to]" readonly/>
<div class="input-group-addon"><i class="icon-calendar"></i></div>
</div>
</div>
</center>
</td>
<td style="display:none;" class="productQuantity text-center" colspan="1">
{if $order->with_occupancy}
<div class="booking_occupancy">
<div class="dropdown">
<button class="booking_guest_occupancy form-control btn btn-default btn-left btn-block input-occupancy disabled" type="button">
<span>{l s='Select occupancy'}</span>
</button>
<input type="hidden" class="max_avail_type_qty" value="">
<div class="dropdown-menu booking_occupancy_wrapper fixed-width-xxl well well-sm">
<div class="booking_occupancy_inner">
<div class="occupancy_info_block col-sm-12" occ_block_index="0">
<div class="occupancy_info_head col-sm-12"><label class="room_num_wrapper">{l s='Room - 1'}</label></div>
<div class="col-sm-12">
<div class="row">
<div class="form-group col-xs-6 occupancy_count_block">
<label>{l s='Adults'}</label>
<input type="number" class="form-control num_occupancy num_adults" name="occupancy[0][adults]" value="1" min="1">
</div>
<div class="form-group col-xs-6 occupancy_count_block">
<label>{l s='Child'} <span class="label-desc-txt"></span></label>
<input type="number" class="form-control num_occupancy num_children" name="occupancy[0][children]" value="0" min="0">
({l s='Below'} {$max_child_age|escape:'htmlall':'UTF-8'} {l s='years'})
</div>
</div>
<p style="display:none;"><span class="text-danger occupancy-input-errors"></span></p>
<div class="row children_age_info_block" style="display:none">
<div class="form-group col-sm-12">
<label class="">{l s='All Children'}</label>
<div class="">
<div class="row children_ages">
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<hr class="occupancy-info-separator col-sm-12">
<div class="add_occupancy_block col-sm-12">
<a class="add_new_occupancy_btn" href="#"><i class="icon-plus"></i> <span>{l s='Add Room'}</span></a>
<a class="pull-right close_occupancy_link" href="#">{l s='close'} <i class="icon-remove"></i></a>
</div>
</div>
</div>
</div>
{else}
<center>
<input type="number" class="form-control fixed-width-sm" name="add_product[product_quantity]" id="add_product_product_quantity" value="1" disabled="disabled" min="1"/>
</center>
{/if}
</td>
<td style="display:none;" class="text-center" colspan="2">
<center>
<div class="row">
<div class="input-group fixed-width-xl">
{if $currency->format % 2}<div class="input-group-addon">{$currency->sign} {l s='tax excl.'}</div>{/if}
<input type="text" name="add_product[product_price_tax_excl]" id="add_product_product_price_tax_excl" value="" />
{if !($currency->format % 2)}<div class="input-group-addon">{$currency->sign} {l s='tax excl.'}</div>{/if}
</div>
</div>
<br/>
<div class="row">
<div class="input-group fixed-width-xl">
{if $currency->format % 2}<div class="input-group-addon">{$currency->sign} {l s='tax incl.'}</div>{/if}
<input type="text" name="add_product[product_price_tax_incl]" id="add_product_product_price_tax_incl" value="" />
{if !($currency->format % 2)}<div class="input-group-addon">{$currency->sign} {l s='tax incl.'}</div>{/if}
</div>
</div>
</center>
</td>
{*{if ($order->hasBeenPaid())}<td style="display:none;" class="productQuantity"></td>{/if}
{if $display_warehouse}<td></td>{/if}
{if ($order->hasBeenDelivered())}<td style="display:none;" class="productQuantity"></td>{/if}
<td style="display:none;" class="productQuantity" id="add_product_product_stock">0</td>*}
<td style="display:none;" id="add_product_product_total" class="text-center">{displayPrice price=0 currency=$currency->id}</td>
<td style="display:none;" class="text-center">
{if sizeof($invoices_collection)}
<select class="form-control" name="add_product[invoice]" id="add_product_product_invoice" disabled="disabled">
<optgroup class="existing" label="{l s='Existing'}">
{foreach from=$invoices_collection item=invoice}
<option value="{$invoice->id}">{$invoice->getInvoiceNumberFormatted($current_id_lang)}</option>
{/foreach}
</optgroup>
<optgroup label="{l s='New'}">
<option value="0">{l s='Create a new invoice'}</option>
</optgroup>
</select>
{/if}
</td>
<td style="display:none;" class="text-center">
<button type="button" class="btn btn-default" id="cancelAddProduct">
<i class="icon-remove text-danger"></i>
{l s='Cancel'}
</button>
<button type="button" class="btn btn-default" id="submitAddProduct" disabled="disabled">
<i class="icon-ok text-success"></i>
{l s='Add'}
</button>
</td>
</tr>
<!-- <tr id="new_invoice" style="display:none">
<td colspan="10">
<h4>{l s='New invoice information'}</h4>
<div class="form-horizontal">
<div class="form-group">
<label class="control-label col-lg-3">{l s='Carrier'}</label>
<div class="col-lg-9">
<p class="form-control-static"><strong>{$carrier->name}</strong></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-lg-3">{l s='Shipping Cost'}</label>
<div class="col-lg-9">
<div class="checkbox">
<label>
<input type="checkbox" name="add_invoice[free_shipping]" value="1" />
{l s='Free shipping'}
</label>
<p class="help-block">{l s='If you don\'t select "Free shipping," the normal shipping cost will be applied.'}</p>
</div>
</div>
</div>
</div>
</td>
</tr>
-->

View File

@@ -43,15 +43,19 @@
<td>
{if $order->with_occupancy && $data['children']}
<div class="dropdown booking_occupancy_show">
<button class="btn btn-default btn-left btn-block" data-toggle="dropdown" type="button">
<a data-toggle="dropdown">
<span>{if $data['adults']}{$data['adults']}{/if} {if $data['adults'] > 1}{l s='Adults'}{else}{l s='Adult'}{/if}{if {$data['children']}}, {$data['children']} {if $data['children'] > 1}{l s='Children'}{else}{l s='Child'}{/if}{/if}</span>
</button>
</a>
<div class="dropdown-menu well well-sm">
<label>{l s='Children Ages'}</label>
{if isset($data['child_ages']) && $data['child_ages']}
{foreach $data['child_ages'] as $childAge}
<p class="">
{l s='Child %s : %s years' sprintf=[$childAge@iteration, $childAge]}
{if $childAge == 0}
{l s='Child %s : Under 1' sprintf=[$childAge@iteration]}
{else}
{l s='Child %s : %s' sprintf=[$childAge@iteration, $childAge]} {if $childAge > 1}{l s='years'}{else}{l s='year'}{/if}
{/if}
</p>
{/foreach}
{/if}

View File

@@ -70,7 +70,11 @@
{if isset($data['child_ages']) && $data['child_ages']}
{foreach $data['child_ages'] as $childAge}
<p class="">
{l s='Child %s : %s years' sprintf=[$childAge@iteration, $childAge]}
{if $childAge == 0}
{l s='Child %s : Under 1' sprintf=[$childAge@iteration]}
{else}
{l s='Child %s : %s' sprintf=[$childAge@iteration, $childAge]} {if $childAge > 1}{l s='years'}{else}{l s='year'}{/if}
{/if}
</p>
{/foreach}
{/if}
@@ -246,7 +250,7 @@
</button>
<ul class="dropdown-menu" role="menu">
<li>
<a href="#" class="room_reallocate_swap" id="reallocate_room_{$data['id']}" data-room_type_name="{$data['room_type_name']}" data-toggle="modal" data-target="#mySwappigModal" data-id_htl_booking="{$data['id']}" data-id_order="{$data['id_order']}" data-room_num='{$data.room_num}' data-id_room_type='{$data.id_product}' data-cust_name='{$data.alloted_cust_name}' data-cust_email='{$data.alloted_cust_email}' data-avail_rm_swap='{$data.avail_rooms_to_swap|@json_encode}' data-avail_realloc_room_types='{$data.avail_room_types_to_realloc|@json_encode}'>
<a href="#" class="room_reallocate_swap" id="reallocate_room_{$data['id']}" data-room_type_name="{$data['room_type_name']}" data-toggle="modal" data-target="#mySwappigModal" data-id_htl_booking="{$data['id']}" data-id_order="{$data['id_order']}" data-room_num='{$data.room_num}' data-id_room_type='{$data.id_product}' data-cust_name='{$data.alloted_cust_name}' data-cust_email='{$data.alloted_cust_email}' data-avail_rm_swap='{$data.avail_rooms_to_swap|@json_encode}' data-avail_realloc_room_types='{$data.avail_room_types_to_realloc|@json_encode}' data-allotment_type='{$data['booking_type']}' data-allotment_type_label='{if $data['booking_type'] == $ALLOTMENT_MANUAL}{l s='Manual'}{else}{l s='Auto'}{/if}' data-comment='{$data.comment}'>
<i class="icon-refresh"></i>
{l s='Reallocate/Swap Room'}
</a>

View File

@@ -28,9 +28,9 @@
{block name=pageTitle}
<h2 class="order_page_title page-title">
{if is_array($title)}{$title|end|strip_tags}{else}{$title|strip_tags}{/if}
{if $currentState == Configuration::get('PS_OS_REFUND')}
{if $currentState->id == Configuration::get('PS_OS_REFUND')}
<span class="toolbar_order_status_badge badge badge-danger">{l s='Refunded'}</span>
{elseif $currentState == Configuration::get('PS_OS_CANCELED')}
{elseif $currentState->id == Configuration::get('PS_OS_CANCELED')}
<span class="toolbar_order_status_badge badge badge-danger">{l s='Cancelled'}</span>
{else}
<span class="toolbar_order_status_badge badge badge-success">{l s='Booked'}</span>
@@ -98,12 +98,12 @@
<table class="table">
<thead>
<tr>
<th>{l s='Room No.'}</th>
<th>{l s='Room Type'}</th>
<th>{l s='Room'}</th>
<th>{l s='Duration'}</th>
<th>{l s='Documents'}</th>
<th>{l s='Room Status'}</th>
<th class="text-center">{l s='Action'}</th>
<th>{l s='Check-In'}</th>
<th>{l s='Check-Out'}</th>
<th>{l s='Allotment'}</th>
<th>{l s='Action'}</th>
</tr>
</thead>
<tbody>
@@ -111,34 +111,43 @@
{foreach from=$htl_booking_order_data item=data}
<tr>
<td>
{$data['room_num']}
</td>
<td>
{$data['room_num']}<br>
<a href="{$link->getAdminLink('AdminProducts')|escape:'html':'UTF-8'}&amp;id_product={$data['id_product']}&amp;updateproduct" target="_blank">{$data['room_type_name']|escape:'html':'UTF-8'}</a>
</td>
<td>
{dateFormat date=$data['date_from']} - {dateFormat date=$data['date_to']}
</td>
<td>
<a href="#" onclick="BookingDocumentsModal.init({$data.id|intval}, this); return false;">
{if $data.num_checkin_documents > 0}{$data.num_checkin_documents}{else}{l s='Upload'}{/if} {l s='Documents'}
</a>
</td>
<td>
{if $data['id_status'] == $hotel_order_status['STATUS_ALLOTED']['id_status']}
{l s='Alloted'}
{elseif $data['id_status'] == $hotel_order_status['STATUS_CHECKED_IN']['id_status']}
<span class="text-danger room_status">{l s='Checked in on'} {dateFormat date=$data['check_in']}</span>
{elseif $data['id_status'] == $hotel_order_status['STATUS_CHECKED_OUT']['id_status']}
<span class="text-success room_status">{l s='Checked out on'} {dateFormat date=$data['check_out']}</span>
{if ($data['id_status'] == $hotel_order_status['STATUS_CHECKED_IN']['id_status']) || ($data['id_status'] == $hotel_order_status['STATUS_CHECKED_OUT']['id_status'])}
<span class="text-danger room_status">{l s='Checked in on'}<br>{dateFormat date=$data['check_in'] full=1}</span>
{else}
--
{/if}
</td>
<td class="text-center">
<td>
{if $data['id_status'] == $hotel_order_status['STATUS_CHECKED_OUT']['id_status']}
<span class="text-success room_status">{l s='Checked out on'}<br>{dateFormat date=$data['check_out'] full=1}</span>
{else}
--
{/if}
</td>
<td>
{if $data['booking_type'] == $ALLOTMENT_MANUAL}
{l s='Manual'} &nbsp;{if $data['comment'] != ''}<a class="manual_allotment_comment" href="#" data-id_hotel_booking_detail="{$data['id']}"><i class="icon-info-circle"></i></a>{/if}
{else}
{l s='Auto'}
{/if}
</td>
<td>
<a title="{l s='Upload/Check guest documents'}" class="btn btn-default" href="#" onclick="BookingDocumentsModal.init({$data.id|intval}, this); return false;">
<span class="badge badge-info">{if $data.num_checkin_documents > 0}{$data.num_checkin_documents}{else}0{/if}</span> <i class="icon-file-text"></i>
</a>
{if isset($refundReqBookings) && $refundReqBookings && $data.id|in_array:$refundReqBookings && $data.is_refunded}
<span class="badge badge-danger">{if $data.is_cancelled}{l s='Cancelled'}{else}{l s='Refunded'}{/if}</span>
{else}
<a class="open_room_status_form btn btn-default" href="#" data-id_hotel_booking_detail="{$data['id']}" data-id_order="{$data['id_order']}" data-id_status="{$data['id_status']}" data-id_room="{$data['id_room']}" data-date_from="{$data['date_from']|date_format:"%Y-%m-%d"}" data-date_to="{$data['date_to']|date_format:"%Y-%m-%d"}" data-check_in_time="{$data['check_in_time']}" data-check_out_time="{$data['check_out_time']}">
<i class="icon-pencil"></i>
<i class="icon-pencil"></i> {l s='Edit'}
</a>
{/if}
</td>
@@ -575,7 +584,7 @@
<dd><b><i class="icon-calendar"></i> &nbsp; {$customer->date_add|date_format:"%d %b, %Y"}</b> ({l s='Member since'})</dd>
<dd><b><i class="icon-list"></i> &nbsp; {$customerStats['nb_orders']|intval}</b> ({l s='Total valid order placed'})</dd>
<dd><b><i class="icon-credit-card"></i> &nbsp; {displayPrice price=Tools::ps_round(Tools::convertPrice($customerStats['total_orders'], $currency), 2) currency=$currency->id}</b> ({l s='Total spent since registration'})</dd>
<dd><b><i class="icon-credit-card"></i> &nbsp; {displayPrice price=Tools::ps_round(Tools::convertPrice($customerStats['total_spent'], $currency), 2) currency=$currency->id}</b> ({l s='Total spent since registration'})</dd>
{if Configuration::get('PS_B2B_ENABLE')}
<dd><b>{$customer->siret}</b> ({l s='Siret'})</dd>
<dd><b>{$customer->ape|date_format:"%d %b, %Y"}</b> ({l s='APE'})</dd>
@@ -625,128 +634,60 @@
</div>
{/if}
<!-- Tab nav -->
<div class="row" style="display:none">
<ul class="nav nav-tabs" id="tabAddresses">
<li class="active">
<a href="#addressShipping">
<i class="icon-truck"></i>
{l s='Shipping address'}
</a>
</li>
<li>
<a href="#addressInvoice">
<i class="icon-file-text"></i>
{l s='Invoice address'}
</a>
</li>
</ul>
<!-- Tab content -->
<div class="tab-content panel">
<!-- Tab status -->
<div class="tab-pane in active" id="addressShipping">
<!-- Addresses -->
<h4 class="visible-print">{l s='Shipping address'}</h4>
{if !$order->isVirtual()}
<!-- Shipping address -->
{if $can_edit}
<form class="form-horizontal hidden-print" method="post" action="{$link->getAdminLink('AdminOrders')|escape:'html':'UTF-8'}&amp;vieworder&amp;id_order={$order->id|intval}">
<div class="form-group">
<div class="col-lg-9">
<select name="id_address">
{foreach from=$customer_addresses item=address}
<option value="{$address['id_address']}"
{if $address['id_address'] == $order->id_address_delivery}
selected="selected"
{/if}>
{$address['alias']} -
{$address['address1']}
{$address['postcode']}
{$address['city']}
{if !empty($address['state'])}
{$address['state']}
{/if},
{$address['country']}
</option>
{/foreach}
</select>
</div>
<div class="col-lg-3">
<button class="btn btn-default" type="submit" name="submitAddressShipping"><i class="icon-refresh"></i> {l s='Change'}</button>
</div>
</div>
</form>
{/if}
<div class="well">
<div class="row">
<div class="col-sm-6">
<a class="btn btn-default pull-right" href="?tab=AdminAddresses&amp;id_address={$addresses.delivery->id}&amp;addaddress&amp;realedit=1&amp;id_order={$order->id}&amp;address_type=1&amp;token={getAdminToken tab='AdminAddresses'}&amp;back={$smarty.server.REQUEST_URI|urlencode}">
<i class="icon-pencil"></i>
{l s='Edit'}
</a>
{displayAddressDetail address=$addresses.delivery newLine='<br />'}
{if $addresses.delivery->other}
<hr />{$addresses.delivery->other}<br />
{/if}
</div>
</div>
</div>
{/if}
</div>
<div class="tab-pane " id="addressInvoice">
<!-- Invoice address -->
<h4 class="visible-print">{l s='Invoice address'}</h4>
{if $can_edit}
<form class="form-horizontal hidden-print" method="post" action="{$link->getAdminLink('AdminOrders')|escape:'html':'UTF-8'}&amp;vieworder&amp;id_order={$order->id|intval}">
<div class="form-group">
<div class="col-lg-9">
<select name="id_address">
{foreach from=$customer_addresses item=address}
<option value="{$address['id_address']}"
{if $address['id_address'] == $order->id_address_invoice}
selected="selected"
{/if}>
{$address['alias']} -
{$address['address1']}
{$address['postcode']}
{$address['city']}
{if !empty($address['state'])}
{$address['state']}
{/if},
{$address['country']}
</option>
{/foreach}
</select>
</div>
<div class="col-lg-3">
<button class="btn btn-default" type="submit" name="submitAddressInvoice"><i class="icon-refresh"></i> {l s='Change'}</button>
</div>
</div>
</form>
{/if}
<div class="well">
<div class="row">
<div class="col-sm-6">
<a class="btn btn-default pull-right" href="?tab=AdminAddresses&amp;id_address={$addresses.invoice->id}&amp;addaddress&amp;realedit=1&amp;id_order={$order->id}&amp;address_type=2&amp;back={$smarty.server.REQUEST_URI|urlencode}&amp;token={getAdminToken tab='AdminAddresses'}">
<i class="icon-pencil"></i>
{l s='Edit'}
</a>
{displayAddressDetail address=$addresses.invoice newLine='<br />'}
{if $addresses.invoice->other}
<hr />{$addresses.invoice->other}<br />
</div>
<div class="panel panel-guest_address">
<div class="panel-heading">
<span class="panel-title"><i class="icon icon-envelope"></i> &nbsp;{l s='Customer Address'}</span>
{if $can_edit}
{if $idOrderAddressInvoice}
<button id="edit_guest_address" class="btn btn-primary pull-right fancybox" href="{$link->getAdminLink('AdminAddresses')}&amp;id_address={$idOrderAddressInvoice}&amp;updateaddress&amp;id_order={$order->id|intval}&amp;address_type=2&amp;realedit=1&amp;liteDisplaying=1&amp;submitFormAjax=1#">
<i class="icon-pencil"></i> {l s='Edit'}
</button>
{if (!$idCurrentAddress || ($idCurrentAddress != $idOrderAddressInvoice)) || $ordersWithDiffInvAddr}
<div class="guest_address_actions dropdown">
<a class="dropdown-toggle" data-toggle="dropdown" href="#">
<i class="icon-ellipsis-vertical"></i>
</a>
<ul class="dropdown-menu">
{if $ordersWithDiffInvAddr}
<li><a href="{$current_index}&amp;vieworder&amp;token={$smarty.get.token|escape:'html':'UTF-8'}&amp;id_order={$order->id|intval}&amp;action=set_old_orders_address">{l s='Set for all orders'}</a></li>
{/if}
</div>
{if !$idCurrentAddress || ($idCurrentAddress != $idOrderAddressInvoice)}
<li><a href="{$current_index}&amp;vieworder&amp;token={$smarty.get.token|escape:'html':'UTF-8'}&amp;id_order={$order->id|intval}&amp;action=set_address_current_address">{l s='Set as current address'}</a></li>
{/if}
</ul>
</div>
{/if}
{else}
<button id="add_guest_address" class="btn btn-primary pull-right fancybox" href="{$link->getAdminLink('AdminAddresses')}&amp;addaddress&amp;id_order={$order->id|intval}&amp;address_type=2&amp;id_customer={$order->id_customer}&amp;liteDisplaying=1&amp;submitFormAjax=1#">
<i class="icon-plus-circle"></i> {l s='Add Address'}
</button>
{if $idCurrentAddress}
<div class="guest_address_actions dropdown">
<a class="dropdown-toggle" data-toggle="dropdown" href="#">
<i class="icon-ellipsis-vertical"></i>
</a>
<ul class="dropdown-menu">
<li><a href="{$current_index}&amp;vieworder&amp;token={$smarty.get.token|escape:'html':'UTF-8'}&amp;id_order={$order->id|intval}&amp;action=set_order_active_address">{l s='Set current address for this order'}</a></li>
</ul>
</div>
{/if}
{/if}
{/if}
</div>
<div class="row">
{if $guestFormattedAddress}
{$guestFormattedAddress}
{else}
<div class="list-empty">
<div class="list-empty-msg">
<i class="icon-warning-sign list-empty-icon"></i>
{l s='Guest address not found.'}
</div>
</div>
</div>
{/if}
</div>
<script>
$('#tabAddresses a').click(function (e) {
e.preventDefault()
$(this).tab('show')
})
</script>
</div>
{* Order Internal notes *}
@@ -783,7 +724,7 @@
</div>
{/if}
<div class="panel">
<div class="panel panel-refund-request">
<div class="panel-heading">
<i class="icon-undo"></i> &nbsp;{l s='Refund Requests'}
</div>
@@ -814,7 +755,7 @@
<td>
<span class="badge" style="background-color:{$return_info.state_color}">{$return_info.state_name}</span>
{if $return_info.refunded_amount > 0}
&nbsp;<span class="badge badge-success">{displayPrice price=$return_info.refunded_amount currency=$currency->id}</span>
&nbsp;<span class="badge badge-success refunded_amount">{displayPrice price=$return_info.refunded_amount currency=$currency->id}</span>
{/if}
</td>
</tr>
@@ -918,7 +859,7 @@
{assign var=additional_service_price_tax_incl value=($order->getTotalProductsWithTaxes(false, false, Product::SERVICE_PRODUCT_WITH_ROOMTYPE) + $totalDemandsPriceTI)}
{if $room_price_tax_excl}
<tr id="total_products">
<td class="text-right">{l s='Total Rooms Cost (tax excl.)'}</td>
<td class="text-right">{l s='Total Rooms Cost (Tax excl.)'}</td>
<td class="amount text-right nowrap">
{displayPrice price=$room_price_tax_excl currency=$currency->id}
</td>
@@ -927,34 +868,16 @@
{/if}
{if isset($additional_service_price_tax_excl) && $additional_service_price_tax_excl > 0}
<tr id="total_products">
<td class="text-right">{l s='Total Extra services (tax excl.)'}</td>
<td class="text-right">{l s='Total Extra services (Tax excl.)'}</td>
<td class="amount text-right nowrap">
{displayPrice price=($additional_service_price_tax_excl - $totalConvenienceFeeTE) currency=$currency->id}
</td>
<td class="partial_refund_fields current-edit" style="display:none;"></td>
</tr>
{/if}
{* {if $room_price_tax_excl}
<tr id="total_tax_order">
<td class="text-right"><strong>{l s='Total Rooms Tax'}</strong></td>
<td class="text-right nowrap">
<strong>{displayPrice price=($room_price_tax_incl - $room_price_tax_excl) currency=$currency->id}</strong>
</td>
<td class="partial_refund_fields current-edit" style="display:none;"></td>
</tr>
{/if}
{if isset($additional_service_price_tax_excl) && $additional_service_price_tax_excl > 0}
<tr id="total_tax_order">
<td class="text-right"><strong>{l s='Extra services Tax'}</strong></td>
<td class="text-right nowrap">
<strong>{displayPrice price=($additional_service_price_tax_incl - $additional_service_price_tax_excl) currency=$currency->id}</strong>
</td>
<td class="partial_refund_fields current-edit" style="display:none;"></td>
</tr>
{/if} *}
{if $service_products_price_tax_excl}
<tr id="total_products">
<td class="text-right">{l s='Total service products cost (tax excl.)'}</td>
<td class="text-right">{l s='Total service products cost (Tax excl.)'}</td>
<td class="amount text-right nowrap">
{displayPrice price=$service_products_price_tax_excl currency=$currency->id}
</td>
@@ -962,10 +885,64 @@
</tr>
{/if}
{if isset($totalConvenienceFeeTE) && $totalConvenienceFeeTE > 0}
<tr id="total_products">
<td class="text-right">{l s='Convenience Fee (Tax excl.)'}</td>
<td class="amount text-right nowrap">
{displayPrice price=$totalConvenienceFeeTE currency=$currency->id}
</td>
<td class="partial_refund_fields current-edit" style="display:none;"></td>
</tr>
{/if}
{if $room_price_tax_excl}
<tr id="total_tax_order">
<td class="text-right">{l s='Total Rooms Tax'}</td>
<td class="text-right nowrap">
{displayPrice price=($room_price_tax_incl - $room_price_tax_excl) currency=$currency->id}
</td>
<td class="partial_refund_fields current-edit" style="display:none;"></td>
</tr>
{/if}
{if isset($additional_service_price_tax_excl) && $additional_service_price_tax_excl > 0}
<tr id="total_tax_order">
<td class="text-right">{l s='Extra services Tax'}</td>
<td class="text-right nowrap">
{displayPrice price=(($additional_service_price_tax_incl - $additional_service_price_tax_excl) - ($totalConvenienceFeeTI - $totalConvenienceFeeTE)) currency=$currency->id}
</td>
<td class="partial_refund_fields current-edit" style="display:none;"></td>
</tr>
{/if}
{if isset($totalConvenienceFeeTE) && $totalConvenienceFeeTE > 0}
<tr id="total_products">
<td class="text-right">{l s='Convenience Fee Tax'}</td>
<td class="amount text-right nowrap">
{displayPrice price=($totalConvenienceFeeTI - $totalConvenienceFeeTE) currency=$currency->id}
</td>
<td class="partial_refund_fields current-edit" style="display:none;"></td>
</tr>
{/if}
{* {if ($order->getTaxCalculationMethod() == $smarty.const.PS_TAX_EXC)} *}
<tr id="total_taxes">
<td class="text-right"><strong>{l s='Total Taxes'}</strong>
</td>
<td class="amount text-right nowrap" ><strong>{displayPrice price=(($order->total_paid_tax_incl + $order->total_discounts_tax_incl) - ($order->total_paid_tax_excl + $order->total_discounts_tax_excl)) currency=$currency->id}</strong>
</td>
<td class="partial_refund_fields current-edit" style="display:none;"></td>
</tr>
{* {/if} *}
<tr id="total_discounts" {if $order->total_discounts_tax_incl == 0}style="display: none;"{/if}>
<td class="text-right">{l s='Discounts'}</td>
<td class="text-right"><strong>{l s='Total Booking Amount'}</strong></td>
<td class="amount text-right nowrap">
-{displayPrice price=$order_discount_price currency=$currency->id}
<strong>{displayPrice price=($order->total_paid_tax_incl + $order->total_discounts_tax_incl) currency=$currency->id}</strong>
</td>
<td class="partial_refund_fields current-edit" style="display:none;"></td>
</tr>
<tr id="total_discounts" {if $order->total_discounts_tax_incl == 0}style="display: none;"{/if}>
<td class="text-right"><strong>{l s='Discounts'}</strong></td>
<td class="amount text-right nowrap">
<strong>-{displayPrice price=$order->total_discounts_tax_incl currency=$currency->id}</strong>
</td>
<td class="partial_refund_fields current-edit" style="display:none;"></td>
</tr>
@@ -976,24 +953,6 @@
</td>
<td class="partial_refund_fields current-edit" style="display:none;"></td>
</tr>
{if isset($totalConvenienceFeeTI) && $totalConvenienceFeeTI > 0}
<tr id="total_products">
<td class="text-right">{l s='Convenience Fee'}</td>
<td class="amount text-right nowrap">
{displayPrice price=$totalConvenienceFeeTE currency=$currency->id}
</td>
<td class="partial_refund_fields current-edit" style="display:none;"></td>
</tr>
{/if}
{* {if ($order->getTaxCalculationMethod() == $smarty.const.PS_TAX_EXC)} *}
<tr id="total_taxes">
<td class="text-right">{l s='Total Taxes'}
</td>
<td class="amount text-right nowrap" >{displayPrice price=($order->total_paid_tax_incl - $order->total_paid_tax_excl) currency=$currency->id}
</td>
<td class="partial_refund_fields current-edit" style="display:none;"></td>
</tr>
{* {/if} *}
<tr id="total_order">
<td class="text-right"><strong>{l s='Final Booking Total'}</strong></td>
<td class="amount text-right nowrap">
@@ -1067,7 +1026,7 @@
</td>
{if $can_edit}
<td class="text-center">
<a class="btn btn-default" href="{$current_index}&amp;submitDeleteVoucher&amp;id_order_cart_rule={$discount['id_order_cart_rule']}&amp;id_order={$order->id}&amp;token={$smarty.get.token|escape:'html':'UTF-8'}"><i class="icon-trash"></i></a>
<a class="btn btn-default delete-voucher" href="{$current_index}&amp;submitDeleteVoucher&amp;id_order_cart_rule={$discount['id_order_cart_rule']}&amp;id_order={$order->id}&amp;token={$smarty.get.token|escape:'html':'UTF-8'}"><i class="icon-trash"></i></a>
</td>
{/if}
</tr>
@@ -1248,14 +1207,13 @@
{addJsDefL name='select_room_txt'}{l s='Select room' js=1}{/addJsDefL}
{addJsDef max_child_age=$max_child_age|escape:'quotes':'UTF-8'}
{addJsDef max_child_in_room=$max_child_in_room|escape:'quotes':'UTF-8'}
{addJsDef ROOM_STATUS_ALLOTED=$ROOM_STATUS_ALLOTED|escape:'quotes':'UTF-8'}
{addJsDef ROOM_STATUS_CHECKED_IN=$ROOM_STATUS_CHECKED_IN|escape:'quotes':'UTF-8'}
{addJsDef ROOM_STATUS_CHECKED_OUT=$ROOM_STATUS_CHECKED_OUT|escape:'quotes':'UTF-8'}
{addJsDef ALLOTMENT_MANUAL=$ALLOTMENT_MANUAL|escape:'quotes':'UTF-8'}
{addJsDef PS_OS_CANCELED=Configuration::get('PS_OS_CANCELED')|escape:'quotes':'UTF-8'}
{addJsDef PS_OS_REFUND=Configuration::get('PS_OS_REFUND')|escape:'quotes':'UTF-8'}
{addJsDefL name=txt_booking_document_upload_success}{l s='Document uploaded successfully.' js=1}{/addJsDefL}
{addJsDefL name=txt_booking_document_delete_confirm}{l s='Are you sure?' js=1}{/addJsDefL}
{addJsDefL name=txt_booking_document_delete_success}{l s='Document deleted successfully.' js=1}{/addJsDefL}
{/strip}
{/block}
{/block}

View File

@@ -49,7 +49,7 @@
<div class="row form-group">
<div class="col-sm-6">
<label class="control-label">{l s='Price (Tax excl.)'}</label>
<label class="control-label">{l s='Price (tax excl.)'}</label>
<div class="input-group">
{if $currency->format % 2}<div class="input-group-addon">{$currency->sign}</div>{/if}
<input class="form-control" type="text" name="add_product[product_price_tax_excl]" id="add_product_product_price_tax_excl" value="" disabled="disabled"/>
@@ -57,7 +57,7 @@
</div>
</div>
<div class="col-sm-6">
<label class="control-label">{l s='Price (Tax incl.)'}</label>
<label class="control-label">{l s='Price (tax incl.)'}</label>
<div class="input-group">
{if $currency->format % 2}<div class="input-group-addon">{$currency->sign}</div>{/if}
<input class="form-control" type="text" name="add_product[product_price_tax_incl]" id="add_product_product_price_tax_incl" value="" disabled="disabled"/>

View File

@@ -58,7 +58,7 @@
<div class="row form-group">
<div class="col-sm-6">
<label class="control-label">{l s='Price (Tax excl.)'}</label>
<label class="control-label">{l s='Price (tax excl.)'}</label>
<div class="input-group">
{if $currency->format % 2}<div class="input-group-addon">{$currency->sign}</div>{/if}
<input class="form-control room_unit_price" type="text" name="room_unit_price" value=""/>
@@ -67,55 +67,55 @@
</div>
<div class="col-sm-6">
<label class="control-label">{l s='Occupancy'}</label>
{if $order->with_occupancy}
<div class="booking_occupancy_edit">
<div class="dropdown">
<button class="form-control booking_guest_occupancy btn btn-default btn-left btn-block input-occupancy" type="button">
<span>
{if $data['adults']}{$data['adults']}{/if} {if $data['adults'] > 1}{l s='Adults'}{else}{l s='Adult'}{/if}{if {$data['children']}}, {$data['children']} {if $data['children'] > 1}{l s='Children'}{else}{l s='Child'}{/if}{/if}
</span>
</button>
<div class="dropdown-menu booking_occupancy_wrapper fixed-width-xxl well well-sm">
<div class="booking_occupancy_inner">
<input type="hidden" class="max_adults" value="{if isset($data['room_type_info'])}{$data['room_type_info']['max_adults']|escape:'html':'UTF-8'}{/if}">
<input type="hidden" class="max_children" value="{if isset($data['room_type_info'])}{$data['room_type_info']['max_children']|escape:'html':'UTF-8'}{/if}">
<input type="hidden" class="max_guests" value="{if isset($data['room_type_info'])}{$data['room_type_info']['max_guests']|escape:'html':'UTF-8'}{/if}">
<div class="occupancy_info_block" occ_block_index="0">
<div class="occupancy_info_head col-sm-12"><span class="room_num_wrapper">{l s='Room - 1'}</span></div>
<div class="row">
<div class="col-xs-6 occupancy_count_block">
<div class="col-sm-12">
<label>{l s='Adults'}</label>
<input type="number" class="form-control num_occupancy num_adults" name="occupancy[0][adults]" value="{$data['adults']}" min="1" max="{$data['room_type_info']['max_adults']|escape:'html':'UTF-8'}">
</div>
</div>
<div class="col-xs-6 occupancy_count_block">
<div class="col-sm-12">
<label>{l s='Child'} <span class="label-desc-txt"></span></label>
<input type="number" class="form-control num_occupancy num_children" name="occupancy[0][children]" value="{$data['children']}" min="0" max="{$data['room_type_info']['max_children']|escape:'html':'UTF-8'}">
({l s='Below'} {$max_child_age|escape:'htmlall':'UTF-8'} {l s='years'})
</div>
<div class="booking_occupancy_edit">
<div class="dropdown">
<button class="form-control booking_guest_occupancy btn btn-default btn-left btn-block input-occupancy" type="button">
<span>
{if $data['adults']}{$data['adults']}{/if} {if $data['adults'] > 1}{l s='Adults'}{else}{l s='Adult'}{/if}{if {$data['children']}}, {$data['children']} {if $data['children'] > 1}{l s='Children'}{else}{l s='Child'}{/if}{/if}
</span>
</button>
<div class="dropdown-menu booking_occupancy_wrapper fixed-width-xxl well well-sm">
<div class="booking_occupancy_inner">
<input type="hidden" class="max_adults" value="{if isset($data['room_type_info'])}{$data['room_type_info']['max_adults']|escape:'html':'UTF-8'}{/if}">
<input type="hidden" class="max_children" value="{if isset($data['room_type_info'])}{$data['room_type_info']['max_children']|escape:'html':'UTF-8'}{/if}">
<input type="hidden" class="max_guests" value="{if isset($data['room_type_info'])}{$data['room_type_info']['max_guests']|escape:'html':'UTF-8'}{/if}">
<div class="occupancy_info_block" occ_block_index="0">
<div class="occupancy_info_head col-sm-12"><span class="room_num_wrapper">{l s='Room - 1'}</span></div>
<div class="row">
<div class="col-xs-6 occupancy_count_block">
<div class="col-sm-12">
<label>{l s='Adults'}</label>
<input type="number" class="form-control num_occupancy num_adults" name="occupancy[0][adults]" value="{$data['adults']}" min="1" max="{$data['room_type_info']['max_adults']|escape:'html':'UTF-8'}">
</div>
</div>
<div class="row children_age_info_block" {if !isset($data['child_ages']) || !$data['child_ages']}style="display:none"{/if}>
<div class="col-xs-6 occupancy_count_block">
<div class="col-sm-12">
<label class="col-sm-12">{l s='All Children'}</label>
<div class="col-sm-12">
<div class="row children_ages">
{if isset($data['child_ages']) && $data['child_ages']}
{foreach $data['child_ages'] as $childAge}
<p class="col-xs-12 col-sm-12 col-md-6 col-lg-6">
<select class="guest_child_age room_occupancies" name="occupancy[0][child_ages][]">
<option value="-1" {if $childAge == -1}selected{/if}>{l s='Select 1'}</option>
<option value="0" {if $childAge == 0}selected{/if}>{l s='Under 1'}</option>
{for $age=1 to ($max_child_age-1)}
<option value="{$age|escape:'htmlall':'UTF-8'}" {if $childAge == $age}selected{/if}>{$age|escape:'htmlall':'UTF-8'}</option>
{/for}
</select>
</p>
{/foreach}
{/if}
</div>
<label>{l s='Child'} <span class="label-desc-txt"></span></label>
<input type="number" class="form-control num_occupancy num_children" name="occupancy[0][children]" value="{$data['children']}" min="0" max="{$data['room_type_info']['max_children']|escape:'html':'UTF-8'}">
({l s='Below'} {$max_child_age|escape:'htmlall':'UTF-8'} {l s='years'})
</div>
</div>
</div>
<p style="display:none;"><span class="text-danger occupancy-input-errors"></span></p>
<div class="row children_age_info_block" {if !isset($data['child_ages']) || !$data['child_ages']}style="display:none"{/if}>
<div class="col-sm-12">
<label class="col-sm-12">{l s='All Children'}</label>
<div class="col-sm-12">
<div class="row children_ages">
{if isset($data['child_ages']) && $data['child_ages']}
{foreach $data['child_ages'] as $childAge}
<p class="col-xs-12 col-sm-12 col-md-6 col-lg-6">
<select class="guest_child_age room_occupancies" name="occupancy[0][child_ages][]">
<option value="-1" {if $childAge == -1}selected{/if}>{l s='Select age'}</option>
<option value="0" {if $childAge == 0}selected{/if}>{l s='Under 1'}</option>
{for $age=1 to ($max_child_age-1)}
<option value="{$age|escape:'htmlall':'UTF-8'}" {if $childAge == $age}selected{/if}>{$age|escape:'htmlall':'UTF-8'}</option>
{/for}
</select>
</p>
{/foreach}
{/if}
</div>
</div>
</div>
@@ -124,9 +124,7 @@
</div>
</div>
</div>
{else}
<span class="booking_occupancy_edit" style="display:none;">{if $data['adults']}{$data['adults']}{/if} {if $data['adults'] > 1}{l s='Adults'}{else}{l s='Adult'}{/if}{if {$data['children']}}, {$data['children']} {if $data['children'] > 1}{l s='Children'}{else}{l s='Child'}{/if}{/if}</span>
{/if}
</div>
</div>
</div>
</div>

View File

@@ -31,8 +31,8 @@
<thead>
<tr>
<th>{l s='Name'}</th>
<th>{l s='Unit Price'}</th>
<th>{l s='Total Price'}</th>
<th>{l s='Unit Price (tax excl.)'}</th>
<th>{l s='Total Price (tax excl.)'}</th>
<th class="text-right">{l s='Action'}</th>
</tr>
</thead>
@@ -77,7 +77,7 @@
<th></th>
<th>{l s='Name'}</th>
<th>{l s='Option'}</th>
<th>{l s='Unit Price'}</th>
<th>{l s='Unit Price (tax excl.)'}</th>
</tr>
</thead>
<tbody>

View File

@@ -33,8 +33,8 @@
<th>{l s='Name'}</th>
<th class="fixed-width-sm"></th>
<th class="fixed-width-sm text-center">{l s='Quantity'}</th>
<th>{l s='Unit Price'}</th>
<th>{l s='Total Price'}</th>
<th>{l s='Unit Price (tax excl.)'}</th>
<th>{l s='Total Price (tax excl.)'}</th>
<th class="text-right">{l s='Action'}</th>
</tr>
</thead>
@@ -101,7 +101,7 @@
<th>{l s='Name'}</th>
<th class="fixed-width-sm"> </th>
<th class="fixed-width-sm text-center">{l s='Quantity'}</th>
<th>{l s='Unit Price'}</th>
<th>{l s='Unit Price (tax excl.)'}</th>
</tr>
</thead>
<tbody>

View File

@@ -0,0 +1,28 @@
{*
* Since 2010 Webkul.
*
* NOTICE OF LICENSE
*
* All right is reserved,
* Please go through this link for complete license : https://store.webkul.com/license.html
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade this module to newer
* versions in the future. If you wish to customize this module for your
* needs please refer to https://store.webkul.com/customisation-guidelines/ for more information.
*
* @author Webkul IN <support@webkul.com>
* @copyright Since 2010 Webkul IN
* @license https://store.webkul.com/license.html
*}
<div class="modal-body">
<div><b>{l s='Allotment remark'}</b>: {$comment}</div>
{if isset($loaderImg) && $loaderImg}
<div class="loading_overlay">
<img src='{$loaderImg}' class="loading-img"/>
</div>
{/if}
</div>

View File

@@ -28,15 +28,25 @@
</ul>
<div class="tab-content active">
<div role="tabpanel" class="tab-pane active" id="reallocate_room_tab">
<div class="row">
<dl class="list-detail col-sm-6">
<label class="label-title">{l s='Current Room Number'}</label>
<dd><i class="icon-bed"></i> &nbsp;<span class="modal_curr_room_num"></span></dd>
</dl>
<dl class="list-detail col-sm-6">
<label class="label-title">{l s='Allotment type'}</label>
<dd><span class="modal_curr_allotent_type"></span></dd>
</dl>
</div>
<div class="row">
<dl class="list-detail col-sm-6">
<label class="label-title">{l s='Currently Alloted Customer'}</label>
<dd><i class="icon-user"></i> &nbsp;<span class="cust_name"></span></dd>
<dd><i class="icon-envelope"></i> &nbsp;<span class="cust_email"></span></dd>
</dl>
<dl class="list-detail col-sm-6">
<label class="label-title">{l s='Current Room Number'}</label>
<dd><i class="icon-bed"></i> &nbsp;<span class="modal_curr_room_num"></span></dd>
<dl class="list-detail col-sm-6 allotment_comment_block">
<label class="label-title">{l s='Allotment Comment'}</label>
<dd><span class="modal_curr_allotment_comment"></span></dd>
</dl>
</div>
@@ -90,15 +100,25 @@
</form>
</div>
<div role="tabpanel" class="tab-pane" id="swap_room_tab">
<div class="row">
<dl class="list-detail col-sm-6">
<label class="label-title">{l s='Current Room Number'}</label>
<dd><i class="icon-bed"></i> &nbsp;<span class="modal_curr_room_num"></span></dd>
</dl>
<dl class="list-detail col-sm-6">
<label class="label-title">{l s='Allotment type'}</label>
<dd><span class="modal_curr_allotent_type"></span></dd>
</dl>
</div>
<div class="row">
<dl class="list-detail col-sm-6">
<label class="label-title">{l s='Currently Alloted Customer'}</label>
<dd><i class="icon-user"></i> &nbsp;<span class="cust_name"></span></dd>
<dd><i class="icon-envelope"></i> &nbsp;<span class="cust_email"></span></dd>
</dl>
<dl class="list-detail col-sm-6">
<label class="label-title">{l s='Current Room Number'}</label>
<dd><i class="icon-bed"></i> &nbsp;<span class="modal_curr_room_num"></span></dd>
<dl class="list-detail col-sm-6 allotment_comment_block">
<label class="label-title">{l s='Allotment Comment'}</label>
<dd><span class="modal_curr_allotment_comment"></span></dd>
</dl>
</div>
<hr>

View File

@@ -43,7 +43,7 @@
{l s='Price'}
</th>
<th>
{l s='Tax rate'}
{l s='Tax rule'}
</th>
<th class="fixed-width-lg text-center">
{l s='Per day price calculation'}

View File

@@ -27,7 +27,7 @@
<span>{l s='Price'}</span>
</th>
<th>
<span>{l s='Tax'}</span>
<span>{l s='Tax rule'}</span>
</th>
</tr>
</thead>

View File

@@ -210,6 +210,7 @@
</div>
</li>
{/if}
{hook h='displayBackOfficeTopNotificaiton'}
</ul>
{if count($quick_access) >= 0}
<ul id="header_quick">

View File

@@ -138,6 +138,9 @@
</select>
{elseif isset($input.empty_message)}
{$input.empty_message}
{else}
<select class="form-control fixed-width-xxl {if isset($field['class'])}{$field['class']}{/if}" name="{$key}"{if isset($field['js'])} onchange="{$field['js']}"{/if} id="{$key}" {if isset($field['size'])} size="{$field['size']}"{/if}>
</select>
{/if}
</div>
{elseif $field['type'] == 'bool'}

View File

@@ -1,2 +1,10 @@
Order deny,allow
Deny from all
# Apache 2.2
<IfModule !mod_authz_core.c>
Order deny,allow
Deny from all
</IfModule>
# Apache 2.4
<IfModule mod_authz_core.c>
Require all denied
</IfModule>

View File

@@ -180,7 +180,7 @@ class AddressCore extends ObjectModel
{
// for customer address we need to check of customer address already exists.
if ($this->id_customer) {
if ($id_address = Customer::getCustomerIdAddress($this->id_customer, false)) {
if ($this->deleted == 0 && $id_address = Customer::getCustomerIdAddress($this->id_customer, false)) {
return false;
}
}
@@ -196,6 +196,8 @@ class AddressCore extends ObjectModel
public function update($null_values = false)
{
$context = Context::getContext();
// Empty related caches
if (isset(self::$_idCountries[$this->id])) {
unset(self::$_idCountries[$this->id]);
@@ -208,9 +210,42 @@ class AddressCore extends ObjectModel
Customer::resetAddressCache($this->id_customer, $this->id);
}
// If address is already used in any order, it will not be edited directly, set address to "deleted" and create a new address
if ($this->isUsed() && $this->deleted == 0) {
return $this->updateUsedAddress($this);
}
return parent::update($null_values);
}
/**
* If address is already used in any order
* set address to "deleted" and create a new address
* @param Address $address
* @return bool
*/
public function updateUsedAddress(Address $address)
{
$objOldAddress = new Address($address->id);
$address->id = $address->id_address = null;
if ($objOldAddress->delete() && $address->save()) {
// we need to change the address id in the current cart as the deleted ID can assigned in context->cart.
if ($customerCarts = Cart::getCustomerCarts($objOldAddress->id_customer, false)) {
foreach ($customerCarts as $cart) {
$objCart = new Cart($cart['id_cart']);
if ($cart['id_address_invoice'] == $objOldAddress->id) {
$objCart->updateAddressId($objOldAddress->id, $address->id);
}
}
}
return true;
}
return false;
}
/**
* @see ObjectModel::delete()
*/
@@ -222,12 +257,12 @@ class AddressCore extends ObjectModel
// reset checkout process if addresses deletes
CheckoutProcess::refreshCheckoutProcess();
if (!$this->isUsed()) {
return parent::delete();
} else {
if ($this->isUsed()) {
$this->deleted = true;
return $this->update();
}
return parent::delete();
}
/**
@@ -252,10 +287,9 @@ class AddressCore extends ObjectModel
// for customer address we need to check of customer address already exists.
// if we are editing an address we do not need to validate already created address.
if (!Validate::isLoadedObject($this)) {
if (!Validate::isLoadedObject($this) && $this->deleted != 0) {
if ($idCustomer = Tools::getValue('id_customer')) {
if ($id_address = Customer::getCustomerIdAddress($idCustomer)) {
$errors[] = sprintf(Tools::displayError('Customer address already exists. Id address: #%d'), $id_address);
}
}
@@ -517,5 +551,4 @@ class AddressCore extends ObjectModel
)
');
}
}

31
classes/BoOrder.php Normal file
View File

@@ -0,0 +1,31 @@
<?php
/**
* 2010-2022 Webkul.
*
* NOTICE OF LICENSE
*
* All right is reserved,
* Please go through this link for complete license : https://store.webkul.com/license.html
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade this module to newer
* versions in the future. If you wish to customize this module for your
* needs please refer to https://store.webkul.com/customisation-guidelines/ for more information.
*
* @author Webkul IN <support@webkul.com>
* @copyright 2010-2022 Webkul IN
* @license https://store.webkul.com/license.html
*/
class BoOrder extends PaymentModule
{
public $active = 1;
public $name = 'bo_order';
public function __construct()
{
$this->displayName = $this->l('Back office order');
$this->validateOrderAmount = false;
}
}

View File

@@ -135,6 +135,9 @@ class CustomerCore extends ObjectModel
public $groupBox;
const STATUS_BANNED = 1;
const STATUS_DELETED = 2;
protected $webserviceParameters = array(
'fields' => array(
'id_default_group' => array('xlink_resource' => 'groups'),
@@ -179,7 +182,7 @@ class CustomerCore extends ObjectModel
'id_risk' => array('type' => self::TYPE_INT, 'validate' => 'isUnsignedInt', 'copy_post' => false),
'max_payment_days' => array('type' => self::TYPE_INT, 'validate' => 'isUnsignedInt', 'copy_post' => false),
'active' => array('type' => self::TYPE_BOOL, 'validate' => 'isBool', 'copy_post' => false),
'deleted' => array('type' => self::TYPE_BOOL, 'validate' => 'isBool', 'copy_post' => false),
'deleted' => array('type' => self::TYPE_INT, 'validate' => 'isUnsignedInt', 'copy_post' => false),
'note' => array('type' => self::TYPE_HTML, 'validate' => 'isCleanHtml', 'size' => 65000, 'copy_post' => false),
'is_guest' => array('type' => self::TYPE_BOOL, 'validate' => 'isBool', 'copy_post' => false),
'id_shop' => array('type' => self::TYPE_INT, 'validate' => 'isUnsignedId', 'copy_post' => false),
@@ -294,21 +297,37 @@ class CustomerCore extends ObjectModel
}
/**
* Return customers list
* Returns a list of customers.
*
* @param null|bool $only_active Returns only active customers when true
* @return array Customers
* @param null|bool $active Optional. Filter customers by their active status. If null, no filter is applied.
* @param null|bool $deleted Optional. Filter customers by their deleted status. If null, no filter is applied.
* @param null|bool $havingAddress Optional. Filter customers having|not having address. If true, only customers having an address are returned.
* If false, only customers without an address are returned. If null, no filter is applied.
* @return array List of customers matching the specified criteria.
*/
public static function getCustomers($only_active = null)
public static function getCustomers($active = null, $deleted = null, $havingAddress = null)
{
$sql = 'SELECT `id_customer`, `email`, `firstname`, `lastname`
FROM `'._DB_PREFIX_.'customer`
WHERE 1 '.Shop::addSqlRestriction(Shop::SHARE_CUSTOMER).
($only_active ? ' AND `active` = 1' : '').'
ORDER BY `id_customer` ASC';
$sqlSelect = 'SELECT c.`id_customer`, c.`email`, c.`firstname`, c.`lastname`';
$sqlFrom = 'FROM `'._DB_PREFIX_.'customer` c';
$sqlJoin = '';
$sqlWhere = 'WHERE 1 '.Shop::addSqlRestriction(Shop::SHARE_CUSTOMER).
(!is_null($active) ? ' AND c.`active` = '.(int) $active: ' ' ).
(!is_null($deleted) ? ' AND c.`deleted` = '.(int) $deleted : ' ');
$sqlOrderBy = 'ORDER BY c.`id_customer` ASC';
$sqlGroupBy = 'GROUP BY c.`id_customer`';
if (!is_null($havingAddress)) {
$sqlJoin .= ' LEFT JOIN `'._DB_PREFIX_.'address` a
ON a.`id_customer` = c.`id_customer` AND a.`deleted`=0';
$sqlWhere .= (($havingAddress) ? ' AND a.`id_address` IS NOT NULL': ' AND a.`id_address` IS NULL');
}
$sql = $sqlSelect .' '. $sqlFrom.' '.$sqlJoin.' '.$sqlWhere.' '.$sqlGroupBy.' '.$sqlOrderBy;
return Db::getInstance(_PS_USE_SQL_SLAVE_)->executeS($sql);
}
/**
* Return customer instance from its e-mail (optionnaly check password)
*
@@ -570,7 +589,8 @@ class CustomerCore extends ObjectModel
public function getStats()
{
$result = Db::getInstance()->getRow('
SELECT COUNT(`id_order`) AS nb_orders, SUM(`total_paid` / o.`conversion_rate`) AS total_orders
SELECT COUNT(`id_order`) AS nb_orders, SUM(`total_paid` / o.`conversion_rate`) AS total_orders,
SUM(o.`total_paid_real` / o.`conversion_rate`) AS total_spent
FROM `'._DB_PREFIX_.'orders` o
WHERE o.`id_customer` = '.(int)$this->id.'
AND o.valid = 1');
@@ -717,7 +737,7 @@ class CustomerCore extends ObjectModel
return Db::getInstance(_PS_USE_SQL_SLAVE_)->executeS('
SELECT * FROM `'._DB_PREFIX_.'orders` o
LEFT JOIN `'._DB_PREFIX_.'order_detail` od ON o.id_order = od.id_order
WHERE o.valid = 1 AND o.`id_customer` = '.(int)$this->id);
WHERE od.`product_auto_add`= 0 AND o.valid = 1 AND o.`id_customer` = '.(int)$this->id);
}
public static function getDefaultGroupId($id_customer)
@@ -951,4 +971,5 @@ class CustomerCore extends ObjectModel
$sql_filter .= Shop::addSqlRestriction(Shop::SHARE_CUSTOMER, 'main');
return parent::getWebserviceObjectList($sql_join, $sql_filter, $sql_sort, $sql_limit);
}
}

View File

@@ -33,6 +33,7 @@ abstract class PaymentModuleCore extends Module
public $currencies = true;
public $currencies_mode = 'checkbox';
public $payment_type = OrderPayment::PAYMENT_TYPE_REMOTE_PAYMENT;
public $validateOrderAmount = true;
public function install()
{
@@ -162,7 +163,7 @@ abstract class PaymentModuleCore extends Module
*/
public function validateOrder($id_cart, $id_order_state, $amount_paid, $payment_method = 'Unknown',
$message = null, $extra_vars = array(), $currency_special = null, $dont_touch_amount = false,
$secure_key = false, Shop $shop = null)
$secure_key = false, Shop $shop = null, $send_mails = true)
{
if (self::DEBUG_MODE) {
PrestaShopLogger::addLog('PaymentModule::validateOrder - Function called', 1, null, 'Cart', (int)$id_cart, true);
@@ -418,8 +419,7 @@ abstract class PaymentModuleCore extends Module
// If webservice order request then no need to impose equal amounts(total cart and sent amount) condition
if ($order_status->logable
&& number_format($cart_total_paid, _PS_PRICE_COMPUTE_PRECISION_) != number_format($amount_paid, _PS_PRICE_COMPUTE_PRECISION_)
&& $this->name != 'wsorder'
&& $this->name != 'bo_order'
&& ($this->validateOrderAmount)
) {
// if customer is paying full payment amount
$id_order_state = Configuration::get('PS_OS_ERROR');
@@ -684,24 +684,25 @@ abstract class PaymentModuleCore extends Module
if ($voucher->add()) {
// If the voucher has conditions, they are now copied to the new voucher
CartRule::copyConditions($cart_rule['obj']->id, $voucher->id);
$params = array(
'{voucher_amount}' => Tools::displayPrice($voucher->reduction_amount, $this->context->currency, false),
'{voucher_num}' => $voucher->code,
'{firstname}' => $this->context->customer->firstname,
'{lastname}' => $this->context->customer->lastname,
'{id_order}' => $order->reference,
'{order_name}' => $order->getUniqReference()
);
Mail::Send(
(int)$order->id_lang,
'voucher',
sprintf(Mail::l('New voucher for your order %s', (int)$order->id_lang), $order->reference),
$params,
$this->context->customer->email,
$this->context->customer->firstname.' '.$this->context->customer->lastname,
null, null, null, null, _PS_MAIL_DIR_, false, (int)$order->id_shop
);
if ($send_mails) {
$params = array(
'{voucher_amount}' => Tools::displayPrice($voucher->reduction_amount, $this->context->currency, false),
'{voucher_num}' => $voucher->code,
'{firstname}' => $this->context->customer->firstname,
'{lastname}' => $this->context->customer->lastname,
'{id_order}' => $order->reference,
'{order_name}' => $order->getUniqReference()
);
Mail::Send(
(int)$order->id_lang,
'voucher',
sprintf(Mail::l('New voucher for your order %s', (int)$order->id_lang), $order->reference),
$params,
$this->context->customer->email,
$this->context->customer->firstname.' '.$this->context->customer->lastname,
null, null, null, null, _PS_MAIL_DIR_, false, (int)$order->id_shop
);
}
}
}
@@ -1050,10 +1051,12 @@ abstract class PaymentModuleCore extends Module
// Set the order status
$new_history = new OrderHistory();
$new_history->id_order = (int)$order->id;
$new_history->changeIdOrderState((int)$id_order_state, $order, true);
$new_history->addWithemail(true, $extra_vars);
if ($send_mails) {
$new_history->addWithemail(true, $extra_vars);
} else {
$new_history->add(true);
}
// Switch to back order if needed
$objHotelBookingDetail = new HotelBookingDetail();
@@ -1089,7 +1092,11 @@ abstract class PaymentModuleCore extends Module
$history = new OrderHistory();
$history->id_order = (int)$order->id;
$history->changeIdOrderState($id_order_state, $order, true);
$history->addWithemail();
if ($send_mails) {
$history->addWithemail();
} else {
$history->add();
}
}
unset($order_detail);
@@ -1098,7 +1105,11 @@ abstract class PaymentModuleCore extends Module
$order = new Order((int)$order->id);
// Send an e-mail to customer (one order = one email)
if ($id_order_state != Configuration::get('PS_OS_ERROR') && $id_order_state != Configuration::get('PS_OS_CANCELED') && $this->context->customer->id) {
if ($id_order_state != Configuration::get('PS_OS_ERROR')
&& $id_order_state != Configuration::get('PS_OS_CANCELED')
&& $this->context->customer->id
&& $send_mails
) {
$invoice = new Address($order->id_address_invoice);
$delivery = new Address($order->id_address_delivery);
$delivery_state = $delivery->id_state ? new State($delivery->id_state) : false;
@@ -1327,9 +1338,7 @@ abstract class PaymentModuleCore extends Module
}
}
}
if ($idHotel
&& Validate::isLoadedObject($objHotel = new HotelBranchInformation($idHotel))
) {
if ($idHotel && Validate::isLoadedObject($objHotel = new HotelBranchInformation($idHotel))) {
if (Configuration::get('PS_ORDER_CONF_MAIL_TO_HOTEL_MANAGER')){
// If order currenct state is overbooking, the send overbooking email or send order confirmation email
if ($isOverBookingStatus) {

View File

@@ -233,7 +233,7 @@ class ValidateCore
*/
public static function isPrice($price)
{
return preg_match('/^[0-9]{1,10}(\.[0-9]{1,9})?$/', $price);
return preg_match('/^[0-9]{1,10}(\.[0-9]{1,})?$/', $price);
}
/**
@@ -244,7 +244,7 @@ class ValidateCore
*/
public static function isNegativePrice($price)
{
return preg_match('/^[-]?[0-9]{1,10}(\.[0-9]{1,9})?$/', $price);
return preg_match('/^[-]?[0-9]{1,10}(\.[0-9]{1,})?$/', $price);
}
/**
@@ -364,7 +364,7 @@ class ValidateCore
*/
public static function isCityName($city)
{
return preg_match(Tools::cleanNonUnicodeSupport('/^[^!<>;?=+@#"°{}_$%]*$/u'), $city);
return preg_match(Tools::cleanNonUnicodeSupport('/^\p{L}+[^!<>;?=+@#"°{}_$%]*$/u'), $city);
}
/**

View File

@@ -502,7 +502,7 @@ abstract class CacheCore
$this->_deleteMulti($invalidKeys);
if ($keyToKeep) {
$this->sql_tables_cached[$table][$keyToKeep] = $toKeep ?? null;
$this->sql_tables_cached[$table][$keyToKeep] = isset($toKeep) ? $toKeep : null;
}
}
$this->adjustTableCacheSize = false;

View File

@@ -602,13 +602,19 @@ class OrderCore extends ObjectModel
$is_booking = null,
$product_service_type = null,
$product_auto_add = null,
$product_price_addition_type = null
$product_price_addition_type = null,
$ids_order_detail = []
) {
$sql = 'SELECT *
FROM `'._DB_PREFIX_.'order_detail` od
LEFT JOIN `'._DB_PREFIX_.'product` p ON (p.id_product = od.product_id)
LEFT JOIN `'._DB_PREFIX_.'product_shop` ps ON (ps.id_product = p.id_product AND ps.id_shop = od.id_shop)
WHERE od.`id_order` = '.(int)$this->id;
if ($ids_order_detail) {
$sql .= ' AND od.`id_order_detail` IN ('.implode(',', $ids_order_detail).')';
}
if ($is_booking !== null) {
$sql .= ' AND od.`is_booking_product` = '. (int)$is_booking;
if (!$is_booking && $product_service_type !== null) {
@@ -954,21 +960,30 @@ class OrderCore extends ObjectModel
*
* @param int $id_customer Customer id
* @param bool $show_hidden_status Display or not hidden order statuses
* @param bool $skip_id_address_invoice Skip orders from this id_address_invoice
* @return array Customer orders
*/
public static function getCustomerOrders($id_customer, $show_hidden_status = false, Context $context = null)
public static function getCustomerOrders($id_customer, $show_hidden_status = false, Context $context = null, $id_address_invoice = null, $skip_address = 0)
{
if (!$context) {
$context = Context::getContext();
}
$res = Db::getInstance(_PS_USE_SQL_SLAVE_)->executeS('
SELECT o.*, (SELECT SUM(od.`product_quantity`) FROM `'._DB_PREFIX_.'order_detail` od WHERE od.`id_order` = o.`id_order`) nb_products
$sql = 'SELECT o.*, (SELECT SUM(od.`product_quantity`) FROM `'._DB_PREFIX_.'order_detail` od WHERE od.`id_order` = o.`id_order`) nb_products
FROM `'._DB_PREFIX_.'orders` o
WHERE o.`id_customer` = '.(int)$id_customer.
Shop::addSqlRestriction(Shop::SHARE_ORDER).'
WHERE o.`id_customer` = '.(int)$id_customer;
// if you want orders from / not from a specific id_address_invoice
if (!is_null($id_address_invoice)) {
$sql .= ' AND o.`id_address_invoice`';
$sql .= ($skip_address ? ' != ' : ' = ').(int)$id_address_invoice;
}
$sql .= Shop::addSqlRestriction(Shop::SHARE_ORDER).'
GROUP BY o.`id_order`
ORDER BY o.`date_add` DESC');
ORDER BY o.`date_add` DESC';
$res = Db::getInstance(_PS_USE_SQL_SLAVE_)->executeS($sql);
if (!$res) {
return array();
}
@@ -1091,11 +1106,12 @@ class OrderCore extends ObjectModel
$bookingProducts = null,
$product_service_type = null,
$product_auto_add = null,
$product_price_addition_type = null
$product_price_addition_type = null,
$ids_order_detail = []
) {
// update
if (!$products) {
$products = $this->getProductsDetail($bookingProducts, $product_service_type, $product_auto_add, $product_price_addition_type);
$products = $this->getProductsDetail($bookingProducts, $product_service_type, $product_auto_add, $product_price_addition_type, $ids_order_detail);
}
$return = 0;
@@ -1116,11 +1132,12 @@ class OrderCore extends ObjectModel
$bookingProducts = null,
$product_service_type = null,
$product_auto_add = null,
$product_price_addition_type = null
$product_price_addition_type = null,
$ids_order_detail = []
) {
/* Retro-compatibility (now set directly on the validateOrder() method) */
if (!$products) {
$products = $this->getProductsDetail($bookingProducts, $product_service_type, $product_auto_add, $product_price_addition_type);
$products = $this->getProductsDetail($bookingProducts, $product_service_type, $product_auto_add, $product_price_addition_type, $ids_order_detail);
}
$return = 0;
@@ -1805,7 +1822,7 @@ class OrderCore extends ObjectModel
SELECT opd.`amount` as `real_paid_amount`, opd.*, op.*
FROM `'._DB_PREFIX_.'order_payment_detail` opd
INNER JOIN `'._DB_PREFIX_.'order_payment` op ON (opd.`id_order_payment` = op.`id_order_payment`)
WHERE `id_order` = '.$this->id
WHERE `id_order` = '.(int) $this->id
);
}

View File

@@ -413,7 +413,7 @@ class OrderInvoiceCore extends ObjectModel
// - 'total_price_tax_excl'
// - 'total_amount'
$breakdown = array();
$order_detail = $order->getOrderDetailList();
$order_detail = $this->getProducts();
$order_detail = array_filter($order_detail, function($v) {
return ($v['is_booking_product']
|| ($v['product_auto_add']
@@ -482,7 +482,7 @@ class OrderInvoiceCore extends ObjectModel
// - 'total_price_tax_excl'
// - 'total_amount'
$breakdown = array();
$order_detail = $order->getOrderDetailList();
$order_detail = $this->getProducts();
$order_detail = array_filter($order_detail, function($v) {
return (!$v['is_booking_product'] && !$v['product_auto_add'] && $v['product_service_type'] == Product::SERVICE_PRODUCT_WITH_ROOMTYPE);
});
@@ -546,7 +546,7 @@ class OrderInvoiceCore extends ObjectModel
// - 'total_price_tax_excl'
// - 'total_amount'
$breakdown = array();
$order_detail = $order->getOrderDetailList();
$order_detail = $this->getProducts();
$order_detail = array_filter($order_detail, function($v) {
return (!$v['is_booking_product']
&& $v['product_auto_add']
@@ -616,7 +616,7 @@ class OrderInvoiceCore extends ObjectModel
// - 'total_price_tax_excl'
// - 'total_amount'
$breakdown = array();
$order_detail = $order->getOrderDetailList();
$order_detail = $this->getProducts();
$order_detail = array_filter($order_detail, function($v) {
return (!$v['is_booking_product'] && $v['product_service_type'] == Product::SERVICE_PRODUCT_WITHOUT_ROOMTYPE);
});
@@ -674,8 +674,10 @@ class OrderInvoiceCore extends ObjectModel
$order = $this->getOrder();
}
$breakdown = array();
$order_details = $this->getProducts();
$objBookingDemand = new HotelBookingDemands();
$details = $objBookingDemand->getExtraDemandsTaxesDetails($order->id);
$order_details = array_column($order_details, 'id_order_detail');
$details = $objBookingDemand->getExtraDemandsTaxesDetails($order->id, $order_details);
if (!$this->useOneAfterAnotherTaxComputationMethod()) {
$grouped_details = array();
foreach ($details as $row) {
@@ -1013,7 +1015,7 @@ class OrderInvoiceCore extends ObjectModel
$payments = OrderPaymentDetail::getByInvoiceId($this->id);
foreach ($payments as $payment) {
/** @var OrderPayment $payment */
$amount += $payment['amount'];
$amount += ($payment['amount'] / $payment['conversion_rate']);
}
Cache::store($cache_id, $amount);
return $amount;

View File

@@ -349,9 +349,9 @@ class HTMLTemplateInvoiceCore extends HTMLTemplate
if ($type_value)
if (isset($customer->id)) {
$cart_obj = new Cart($this->order->id_cart);
$order_bk_data = $obj_htl_bk_dtl->getOnlyOrderBookingData($this->order->id, $cart_obj->id_guest, $type_value['product_id'], $customer->id);
$order_bk_data = $obj_htl_bk_dtl->getOnlyOrderBookingData($this->order->id, $cart_obj->id_guest, $type_value['product_id'], $customer->id, $type_value['id_order_detail']);
} else {
$order_bk_data = $obj_htl_bk_dtl->getOnlyOrderBookingData($this->order->id, $customer->id_guest, $type_value['product_id']);
$order_bk_data = $obj_htl_bk_dtl->getOnlyOrderBookingData($this->order->id, $customer->id_guest, $type_value['product_id'], 0, $type_value['id_order_detail']);
}
$cart_htl_data[$type_key]['id_product'] = $type_value['product_id'];
@@ -387,7 +387,8 @@ class HTMLTemplateInvoiceCore extends HTMLTemplate
$data_v['date_to'],
0,
1,
0
0,
$type_value['id_order_detail']
);
$cart_htl_data[$type_key]['date_diff'][$date_join]['extra_demands_price_ti'] = $objBookingDemand->getRoomTypeBookingExtraDemands(
$order_obj->id,
@@ -397,7 +398,8 @@ class HTMLTemplateInvoiceCore extends HTMLTemplate
$data_v['date_to'],
0,
1,
1
1,
$type_value['id_order_detail']
);
$cart_htl_data[$type_key]['date_diff'][$date_join]['additional_services_price_auto_add_ti'] = $objRoomTypeServiceProductOrderDetail->getroomTypeServiceProducts(
$order_obj->id,
@@ -457,7 +459,8 @@ class HTMLTemplateInvoiceCore extends HTMLTemplate
$data_v['date_to'],
0,
1,
0
0,
$type_value['id_order_detail']
);
$cart_htl_data[$type_key]['date_diff'][$date_join]['extra_demands_price_ti'] = $objBookingDemand->getRoomTypeBookingExtraDemands(
$order_obj->id,
@@ -467,7 +470,8 @@ class HTMLTemplateInvoiceCore extends HTMLTemplate
$data_v['date_to'],
0,
1,
1
1,
$type_value['id_order_detail']
);
$cart_htl_data[$type_key]['date_diff'][$date_join]['additional_services'] = $objRoomTypeServiceProductOrderDetail->getroomTypeServiceProducts(
$order_obj->id,
@@ -610,14 +614,25 @@ class HTMLTemplateInvoiceCore extends HTMLTemplate
$footer['total_extra_demands_te'] = $totalDemandsPriceTE;
}
}
$footer['room_price_tax_excl'] = $this->order->getTotalProductsWithoutTaxes(false, true) + $this->order->getTotalProductsWithoutTaxes(false, false, Product::SERVICE_PRODUCT_WITH_ROOMTYPE, 1, Product::PRICE_ADDITION_TYPE_WITH_ROOM);
$footer['room_price_tax_incl'] = $this->order->getTotalProductsWithTaxes(false, true) + $this->order->getTotalProductsWithoutTaxes(false, false, Product::SERVICE_PRODUCT_WITH_ROOMTYPE, 1, Product::PRICE_ADDITION_TYPE_WITH_ROOM);
// $footer['service_products_price_tax_excl'] = $this->order->getTotalProductsWithoutTaxes(false, false, Product::SERVICE_PRODUCT_WITHOUT_ROOMTYPE);
// $footer['service_products_price_tax_incl'] = $this->order->getTotalProductsWithTaxes(false, false, Product::SERVICE_PRODUCT_WITHOUT_ROOMTYPE);
$footer['additional_service_price_tax_excl'] = $this->order->getTotalProductsWithoutTaxes(false, false, Product::SERVICE_PRODUCT_WITH_ROOMTYPE, 0) + $totalDemandsPriceTE;
$footer['additional_service_price_tax_incl'] = $this->order->getTotalProductsWithTaxes(false, false, Product::SERVICE_PRODUCT_WITH_ROOMTYPE, 0) + $totalDemandsPriceTI;
$footer['total_convenience_fee_te'] = $this->order->getTotalProductsWithoutTaxes(false, false, Product::SERVICE_PRODUCT_WITH_ROOMTYPE, 1, Product::PRICE_ADDITION_TYPE_INDEPENDENT);
$footer['total_convenience_fee_ti'] = $this->order->getTotalProductsWithTaxes(false, false, Product::SERVICE_PRODUCT_WITH_ROOMTYPE, 1, Product::PRICE_ADDITION_TYPE_INDEPENDENT);
$footer['room_price_tax_excl'] = 0;
$footer['room_price_tax_incl'] = 0;
$footer['additional_service_price_tax_excl'] = 0;
$footer['additional_service_price_tax_incl'] =0;
$footer['total_convenience_fee_te'] = 0;
$footer['total_convenience_fee_ti'] = 0;
if ($idsOrderDetail = array_column($order_details, 'id_order_detail')) {
$footer['room_price_tax_excl'] = $this->order->getTotalProductsWithoutTaxes(false, true, null, null, null, $idsOrderDetail) + $this->order->getTotalProductsWithoutTaxes(false, false, Product::SERVICE_PRODUCT_WITH_ROOMTYPE, 1, Product::PRICE_ADDITION_TYPE_WITH_ROOM, $idsOrderDetail);
$footer['room_price_tax_incl'] = $this->order->getTotalProductsWithTaxes(false, true, null, null, null, $idsOrderDetail) + $this->order->getTotalProductsWithoutTaxes(false, false, Product::SERVICE_PRODUCT_WITH_ROOMTYPE, 1, Product::PRICE_ADDITION_TYPE_WITH_ROOM, $idsOrderDetail);
// $footer['service_products_price_tax_excl'] = $this->order->getTotalProductsWithoutTaxes(false, false, Product::SERVICE_PRODUCT_WITHOUT_ROOMTYPE);
// $footer['service_products_price_tax_incl'] = $this->order->getTotalProductsWithTaxes(false, false, Product::SERVICE_PRODUCT_WITHOUT_ROOMTYPE);
$footer['additional_service_price_tax_excl'] = $this->order->getTotalProductsWithoutTaxes(false, false, Product::SERVICE_PRODUCT_WITH_ROOMTYPE, 0, null, $idsOrderDetail) + $totalDemandsPriceTE;
$footer['additional_service_price_tax_incl'] = $this->order->getTotalProductsWithTaxes(false, false, Product::SERVICE_PRODUCT_WITH_ROOMTYPE, 0, null, $idsOrderDetail) + $totalDemandsPriceTI;
$footer['total_convenience_fee_te'] = $this->order->getTotalProductsWithoutTaxes(false, false, Product::SERVICE_PRODUCT_WITH_ROOMTYPE, 1, Product::PRICE_ADDITION_TYPE_INDEPENDENT, $idsOrderDetail);
$footer['total_convenience_fee_ti'] = $this->order->getTotalProductsWithTaxes(false, false, Product::SERVICE_PRODUCT_WITH_ROOMTYPE, 1, Product::PRICE_ADDITION_TYPE_INDEPENDENT, $idsOrderDetail);
}
$footer['total_paid_real'] = $this->order_invoice->getTotalPaid();
$data = array(
'cart_htl_data' => $cart_htl_data,
'service_product_data' => $service_product_data,
@@ -737,6 +752,7 @@ class HTMLTemplateInvoiceCore extends HTMLTemplate
'ecotax_tax' => $this->order_invoice->getEcoTaxTaxesBreakdown(),
'wrapping_tax' => $this->order_invoice->getWrappingTaxesBreakdown(),
);
foreach ($breakdowns as $type => $bd) {
if (empty($bd)) {
unset($breakdowns[$type]);
@@ -822,7 +838,9 @@ class HTMLTemplateInvoiceCore extends HTMLTemplate
*/
protected function getTemplateByCountry($iso_country)
{
$file = Configuration::get('PS_INVOICE_MODEL');
// $file = Configuration::get('PS_INVOICE_MODEL');
// @todo redesign invoice template for b2b, for now we have ony one template design.
$file = 'invoice';
// try to fetch the iso template
$template = $this->getTemplate($file.'.'.$iso_country);

View File

@@ -26,5 +26,6 @@ class WebserviceOrderCore extends PaymentModule
public function __construct()
{
$this->displayName = $this->l('Order from API');
$this->validateOrderAmount = false;
}
}

View File

@@ -1,2 +1,10 @@
Order deny,allow
Deny from all
# Apache 2.2
<IfModule !mod_authz_core.c>
Order deny,allow
Deny from all
</IfModule>
# Apache 2.4
<IfModule mod_authz_core.c>
Require all denied
</IfModule>

View File

@@ -1,2 +1,10 @@
Order deny,allow
Deny from all
# Apache 2.2
<IfModule !mod_authz_core.c>
Order deny,allow
Deny from all
</IfModule>
# Apache 2.4
<IfModule mod_authz_core.c>
Require all denied
</IfModule>

View File

@@ -112,18 +112,43 @@ class AdminAddressesControllerCore extends AdminController
public function renderForm()
{
$customerField =array(
'type' => 'text_customer',
'label' => $this->l('Customer'),
'name' => 'id_customer',
'required' => false,
);
if ($this->loadObject(true)
&& !$this->object->id
&& !Tools::getValue('liteDisplaying')
) {
$customerEmails = array(array(
'email' => $this->l('Select Customer'),
'id_customer' => 0,
'id_address'=> 0
));
$customerEmails = array_merge($customerEmails, Customer::getCustomers(null, 0, 0));
$customerField = array(
'type' => 'select',
'label' => $this->l('Customer'),
'name' => 'id_customer',
'required' => true,
'class' => 'chosen',
'options' => array(
'query' => $customerEmails,
'id' => 'id_customer',
'name' => 'email'
),
);
}
$this->fields_form = array(
'legend' => array(
'title' => $this->l('Addresses'),
'icon' => 'icon-envelope-alt'
),
'input' => array(
array(
'type' => 'text_customer',
'label' => $this->l('Customer'),
'name' => 'id_customer',
'required' => false,
),
$customerField,
array(
'type' => 'text',
'label' => $this->l('Identification Number'),
@@ -191,9 +216,8 @@ class AdminAddressesControllerCore extends AdminController
}
$this->tpl_form_vars = array(
'customer' => isset($customer) ? $customer : null,
'tokenCustomer' => isset($token_customer) ? $token_customer : null,
'back_url' => urldecode(Tools::getValue('back'))
'customer' => (isset($customer) && ($this->object->id || Tools::getValue('liteDisplaying'))) ? $customer : null,
'tokenCustomer' => isset($token_customer) ? $token_customer : null
);
// Order address fields depending on country format
@@ -430,10 +454,8 @@ class AdminAddressesControllerCore extends AdminController
** we delete its id_address to force the creation of a new one */
if ((int)Tools::getValue('id_order')) {
$this->_redirect = false;
if (isset($_POST['address_type'])) {
$_POST['id_address'] = '';
$this->id_object = null;
}
// set deleted=1 as customer can have only one address and this address is for an order only
$_POST['deleted'] = 1;
}
// Check the requires fields which are settings in the BO
@@ -454,10 +476,18 @@ class AdminAddressesControllerCore extends AdminController
if ($this->action == 'save' && ($id_order = (int)Tools::getValue('id_order')) && !count($this->errors) && !empty($address_type)) {
if (!Db::getInstance()->Execute('UPDATE '._DB_PREFIX_.'orders SET `id_address_'.bqSQL($address_type).'` = '.(int)$this->object->id.' WHERE `id_order` = '.(int)$id_order)) {
$this->errors[] = Tools::displayError('An error occurred while linking this address to its order.');
} else {
Tools::redirectAdmin(urldecode(Tools::getValue('back')).'&conf=4');
}
}
// in case of save and stay, redirect after save with current address.
// Because the current address can not be same as the current one(We have to delete it and create a new one in case address is used in orders)
if (empty($this->errors) && Tools::isSubmit('submitAdd'.$this->table.'AndStay')) {
$idCurrentAddress = Customer::getCustomerIdAddress($this->object->id_customer, false);
if ($idCurrentAddress != $this->object->id) {
$this->redirect_after = self::$currentIndex.'&'.$this->identifier.'='.$idCurrentAddress.'&conf=4&update'.$this->table.'&token='.$this->token;
}
}
return $return;
}
@@ -503,7 +533,7 @@ class AdminAddressesControllerCore extends AdminController
return $out;
}
/**
/**
* Method called when an ajax request is made
* @see AdminController::postProcess()
*/

View File

@@ -85,6 +85,7 @@ class AdminCmsContentControllerCore extends AdminController
public function initContent()
{
$this->loadObject(true);
$this->initTabModuleList();
$this->renderPageHeaderToolbar();
@@ -151,8 +152,9 @@ class AdminCmsContentControllerCore extends AdminController
if (Tools::getValue('addcms') !== false) {
$this->toolbar_title[] = $this->l('Add new');
} elseif ($id_cms_page) {
$cms_page = new CMS($id_cms_page);
} elseif ($id_cms_page
&& Validate::isLoadedObject($cms_page = new CMS($id_cms_page))
) {
$this->toolbar_title[] = sprintf($this->l('Edit: %s'), $cms_page->meta_title[$this->context->employee->id_lang]);
}
} else {

View File

@@ -133,7 +133,7 @@ class AdminCustomerPreferencesControllerCore extends AdminController
'PS_KPI_FREQUENT_CUSTOMER_NB_ORDERS' => array(
'title' => $this->l('Number of orders to use to calculate frequent customers'),
'hint' => $this->l('Set the number of orders to use to calculate frequent customers.'),
'validation' => 'isUnsignedInt',
'validation' => 'isInt',
'cast' => 'intval',
'type' => 'text',
'class' => 'fixed-width-xxl',
@@ -173,6 +173,14 @@ class AdminCustomerPreferencesControllerCore extends AdminController
);
}
public function beforeUpdateOptions()
{
$fieldData = $this->fields_options['customer_kpi']['fields']['PS_KPI_FREQUENT_CUSTOMER_NB_ORDERS'];
if (!Tools::getValue('PS_KPI_FREQUENT_CUSTOMER_NB_ORDERS')) {
$this->errors[] = sprintf(Tools::displayError('field %s must be greater than 0.'), $fieldData['title']);;
}
}
/**
* Update PS_B2B_ENABLE and enables / disables the associated tabs
* @param $value integer Value of option

View File

@@ -79,6 +79,9 @@ class AdminCustomersControllerCore extends AdminController
$this->_join = 'LEFT JOIN '._DB_PREFIX_.'gender_lang gl ON (a.id_gender = gl.id_gender AND gl.id_lang = '.(int)$this->context->language->id.')';
$this->_join .= ' LEFT JOIN '._DB_PREFIX_.'group_lang grl ON (a.id_default_group = grl.id_group AND grl.id_lang = '.(int)$this->context->language->id.')';
$this->_join .= ' LEFT JOIN '._DB_PREFIX_.'orders o ON (a.id_customer = o.id_customer)';
$this->_group = 'GROUP BY a.`id_customer`';
$this->_use_found_rows = false;
$this->fields_list = array(
'id_customer' => array(
@@ -123,6 +126,7 @@ class AdminCustomersControllerCore extends AdminController
),
'total_orders' => array(
'title' => $this->l('Number of orders'),
'type' => 'range',
'optional' => true,
'visible_default' => true,
'havingFilter' => true,
@@ -163,6 +167,7 @@ class AdminCustomersControllerCore extends AdminController
'date_add' => array(
'title' => $this->l('Registration'),
'type' => 'date',
'filter_key' => 'a!date_add',
'align' => 'text-right'
),
'connect' => array(
@@ -170,6 +175,17 @@ class AdminCustomersControllerCore extends AdminController
'type' => 'datetime',
'search' => false,
'havingFilter' => true
),
'deleted' => array(
'title' => $this->l('Banned'),
'type' => 'bool',
'displayed' => false,
),
'order_date' => array(
'title' => $this->l('Order date'),
'type' => 'date',
'filter_key' => 'o!date_add',
'displayed' => false
)
));
@@ -178,19 +194,8 @@ class AdminCustomersControllerCore extends AdminController
parent::__construct();
$this->_select = '
a.date_add, gl.name as title, grl.name as default_group_name, (
SELECT SUM(total_paid_real / conversion_rate)
FROM '._DB_PREFIX_.'orders o
WHERE o.id_customer = a.id_customer
'.Shop::addSqlRestriction(Shop::SHARE_ORDER, 'o').'
AND o.valid = 1
) as total_spent, (
SELECT COUNT(o.`id_order`)
FROM '._DB_PREFIX_.'orders o
WHERE o.id_customer = a.id_customer
'.Shop::addSqlRestriction(Shop::SHARE_ORDER, 'o').'
AND o.valid = 1
) as total_orders, (
a.date_add, gl.name as title, grl.name as default_group_name, COUNT(o.`id_order`) as total_orders,
o.`date_add` as order_date, SUM(total_paid_real / conversion_rate) as total_spent, (
SELECT c.date_add FROM '._DB_PREFIX_.'guest g
LEFT JOIN '._DB_PREFIX_.'connections c ON c.id_guest = g.id_guest
WHERE g.id_customer = a.id_customer
@@ -218,6 +223,12 @@ class AdminCustomersControllerCore extends AdminController
}
parent::postProcess();
// Added this to check if the filter for the banned(deleted) is used, since $this->delete = true will not display the deleted customers.
$prefix = $this->getCookieFilterPrefix();
$filters = $this->context->cookie->getFamily($prefix.$this->table.'Filter_');
if (isset($filters[$prefix.$this->table.'Filter_deleted']) && $filters[$prefix.$this->table.'Filter_deleted'] == 1) {
$this->deleted = false;
}
}
public function initContent()
@@ -696,7 +707,8 @@ class AdminCustomersControllerCore extends AdminController
$helper->icon = 'icon-star';
$helper->color = 'color2';
$helper->title = $this->l('Total Frequent Customers', null, null, false);
$helper->subtitle = $this->l('All Time', null, null, false);
$helper->subtitle = $this->l('1 year', null, null, false);
$helper->href = $this->context->link->getAdminLink('AdminCustomers').'&submitFiltercustomer=1&customerFilter_total_orders%5B0%5D='.Configuration::get('PS_KPI_FREQUENT_CUSTOMER_NB_ORDERS').'&customerFilter_o%21date_add%5B0%5D='.date('Y-m-d', strtotime('-365 day')).'&customerFilter_o%21date_add%5B1%5D='.date('Y-m-d');
$helper->source = $this->context->link->getAdminLink('AdminStats').'&ajax=1&action=getKpi&kpi=total_frequent_customers';
$helper->tooltip = $this->l('The total number of frequent customers in given period of time.', null, null, false);
$kpis[] = $helper;
@@ -739,6 +751,9 @@ class AdminCustomersControllerCore extends AdminController
$helper->color = 'color4';
$helper->title = $this->l('New Customers', null, null, false);
$nbDaysNewCustomers = Validate::isUnsignedInt(Configuration::get('PS_KPI_NEW_CUSTOMERS_NB_DAYS')) ? Configuration::get('PS_KPI_NEW_CUSTOMERS_NB_DAYS') : 30;
$date_from = date('Y-m-d', strtotime('-'.$nbDaysNewCustomers.' day'));
$date_to = date('Y-m-d');
$helper->href = $this->context->link->getAdminLink('AdminCustomers').'&customerFilter_date_add[]='.$date_from.'&customerFilter_date_add[]='.$date_to;
$helper->subtitle = sprintf($this->l('%d Days', null, null, false), (int) $nbDaysNewCustomers);
$helper->source = $this->context->link->getAdminLink('AdminStats').'&ajax=1&action=getKpi&kpi=total_new_customers';
$helper->tooltip = $this->l('The total number of new customers who registered in given period of time.', null, null, false);
@@ -750,6 +765,7 @@ class AdminCustomersControllerCore extends AdminController
$helper->color = 'color2';
$helper->title = $this->l('Banned Customers', null, null, false);
$helper->subtitle = $this->l('All Time', null, null, false);
$helper->href = $this->context->link->getAdminLink('AdminCustomers').'&customerFilter_deleted=1';
$helper->source = $this->context->link->getAdminLink('AdminStats').'&ajax=1&action=getKpi&kpi=total_banned_customers';
$helper->tooltip = $this->l('The total number of banned customers.', null, null, false);
$kpis[] = $helper;
@@ -822,6 +838,7 @@ class AdminCustomersControllerCore extends AdminController
}
$total_ok = 0;
$total_ko = 0;
$orders_ok = array();
$orders_ko = array();
foreach ($orders as $order) {
@@ -834,10 +851,21 @@ class AdminCustomersControllerCore extends AdminController
$total_ok += $order['total_paid_real_not_formated']/$order['conversion_rate'];
} else {
$orders_ko[] = $order;
$total_ko += $order['total_paid'] / $order['conversion_rate'];
}
}
$products = $customer->getBoughtProducts();
$purchasedServices = array();
$purchasedRoomTypes = array();
if ($products = $customer->getBoughtProducts()) {
foreach ($products as $product) {
if ($product['is_booking_product']) {
$purchasedRoomTypes[] = $product;
} else {
$purchasedServices[] = $product;
}
}
}
$carts = Cart::getCustomerCarts($customer->id);
$total_carts = count($carts);
@@ -860,6 +888,7 @@ class AdminCustomersControllerCore extends AdminController
FROM '._DB_PREFIX_.'cart_product cp
JOIN '._DB_PREFIX_.'cart c ON (c.id_cart = cp.id_cart)
JOIN '._DB_PREFIX_.'product p ON (cp.id_product = p.id_product)
AND p.booking_product=1
WHERE c.id_customer = '.(int)$customer->id.'
AND NOT EXISTS (
SELECT 1
@@ -932,8 +961,11 @@ class AdminCustomersControllerCore extends AdminController
'orders_ok' => $orders_ok,
'orders_ko' => $orders_ko,
'total_ok' => Tools::displayPrice($total_ok, $this->context->currency->id),
'total_ko' => Tools::displayPrice($total_ko, $this->context->currency->id),
// Products
'products' => $products,
'purchasedRoomTypes' => $purchasedRoomTypes,
'purchasedServices' => $purchasedServices,
// Addresses
'addresses' => $customer->getAddresses($this->default_form_language),
// Discounts
@@ -958,8 +990,8 @@ class AdminCustomersControllerCore extends AdminController
// If customer is going to be deleted permanently then if customer has orders the change this customer as an anonymous customer
if (Validate::isLoadedObject($objCustomer = $this->loadObject())) {
if ($this->delete_mode == 'real' && Order::getCustomerOrders($objCustomer->id, true)) {
$objCustomer->email = 'anonymous'.'-'.$objCustomer->id.'@'.Tools::getShopDomain();
$objCustomer->deleted = 1;
$objCustomer->email = 'anonymous'.'-'.$objCustomer->id.'@'.Tools::link_rewrite(Configuration::get('PS_SHOP_NAME')).'_anonymous.com';
$objCustomer->deleted = Customer::STATUS_DELETED;
if (!$objCustomer->update()) {
$this->errors[] = Tools::displayError('Some error ocurred while deleting the Customer');
return;
@@ -1000,7 +1032,7 @@ class AdminCustomersControllerCore extends AdminController
// check if customer has orders for email change else customer will be deleted
if (Order::getCustomerOrders($objCustomer->id, true)) {
$objCustomer->email = 'anonymous'.'-'.$objCustomer->id.'@'.Tools::getShopDomain();
$objCustomer->deleted = 1;
$objCustomer->deleted = Customer::STATUS_DELETED;
if ($objCustomer->update()) {
// unset the customer which is processed
// not processed customers will be deleted with default process if no errors are there
@@ -1040,7 +1072,7 @@ class AdminCustomersControllerCore extends AdminController
$this->redirect_after = false;
}
// Check that the new email is not already in use
$customer_email = strval(Tools::getValue('email'));
$customer_email = trim(strval(Tools::getValue('email')));
$customer = new Customer();
if (Validate::isEmail($customer_email)) {
$customer->getByEmail($customer_email);
@@ -1048,6 +1080,9 @@ class AdminCustomersControllerCore extends AdminController
$this->errors[] = Tools::displayError('An account already exists for this email address:').' '.$customer_email;
$this->display = 'edit';
return $customer;
} elseif (Customer::customerExists($customer_email, false, true)) {
$this->errors[] = Tools::displayError('The email is already associated with a banned account. Please use a different one.');
$this->display = 'edit';
} elseif (trim(Tools::getValue('passwd')) == '') {
$this->validateRules();
$this->errors[] = Tools::displayError('Password can not be empty.');
@@ -1068,7 +1103,7 @@ class AdminCustomersControllerCore extends AdminController
public function processUpdate()
{
if (Validate::isLoadedObject($this->object)) {
$customer_email = strval(Tools::getValue('email'));
$customer_email = trim(strval(Tools::getValue('email')));
// check if e-mail already used
if ($customer_email != $this->object->email) {
@@ -1297,4 +1332,41 @@ class AdminCustomersControllerCore extends AdminController
die('ok');
}
}
public function ajaxProcessVerifyCustomerEmail()
{
$response = array('status' => true);
$idCustomer = Tools::getValue('id_customer', 0);
if (($email = trim(strval(Tools::getValue('email'))))
&& ($idCustomerByEmail = Customer::customerExists($email, true, false))
&& (Validate::isLoadedObject($objCustomer = new Customer($idCustomerByEmail)))
&& $idCustomerByEmail != $idCustomer // the admin is trying to add/update the account
) {
$response['status'] = false;
if ($objCustomer->deleted) {
$response['msg'] = Tools::displayError('This email is already associated with a banned account. Please use a different one.');
} else {
$response['msg'] = Tools::displayError('An account already exists for this email address.');
}
}
$this->ajaxDie(json_encode($response));
}
public function setMedia()
{
parent::setMedia();
if ($this->loadObject(true)
&& ($this->display == 'edit' || $this->display == 'add')
) {
$idCustomer = $this->object->id ? $this->object->id : 0;
Media::addJSDef(
array(
'customer_controller_url' => self::$currentIndex.'&token='.$this->token,
'id_customer' => $idCustomer
)
);
$this->addJS(_PS_JS_DIR_.'admin/customers.js');
}
}
}

View File

@@ -452,10 +452,9 @@ class AdminFeaturesControllerCore extends AdminController
$this->initToolbar();
$this->initPageHeaderToolbar();
if ($this->display == 'edit' || $this->display == 'add') {
if (!$this->loadObject(true)) {
return;
if ($this->loadObject(true)) {
$this->content .= $this->renderForm();
}
$this->content .= $this->renderForm();
} elseif ($this->display == 'view') {
// Some controllers use the view action without an object
if ($this->className) {

View File

@@ -208,7 +208,6 @@ class AdminNormalProductsControllerCore extends AdminController
// show the list of the product according to the booking or service products
$this->_where .= ' AND a.`booking_product` = 0';
$this->_use_found_rows = false;
$this->_group = 'GROUP BY a.`id_product`';
$this->fields_list = array();
@@ -1393,7 +1392,10 @@ class AdminNormalProductsControllerCore extends AdminController
parent::postProcess();
}
if ($this->display == 'edit' || $this->display == 'add') {
if (in_array($this->display, array('add', 'edit'))
&& $this->tabAccess[$this->display] == '1'
&& $this->loadObject(true)
) {
$this->addJqueryUI(array(
'ui.core',
'ui.widget'
@@ -2815,9 +2817,7 @@ class AdminNormalProductsControllerCore extends AdminController
}
// let's calculate this once for all
if (!Validate::isLoadedObject($this->object) && Tools::getValue('id_product')) {
$this->errors[] = 'Unable to load object';
} else {
if ($this->loadObject(true)) {
$this->_displayDraftWarning($this->object->active);
// if there was an error while saving, we don't want to lose posted data

View File

@@ -82,6 +82,7 @@ class AdminOrderPreferencesControllerCore extends AdminController
)
);
$maxOrderDate = Tools::getValue('MAX_GLOBAL_BOOKING_DATE', Configuration::get('MAX_GLOBAL_BOOKING_DATE'));
$this->fields_options = array(
'order_restrict' => array(
'title' => $this->l('Order Restrict'),
@@ -92,11 +93,13 @@ class AdminOrderPreferencesControllerCore extends AdminController
'hint' => $this->l('Maximum date of check-out for which rooms of your hotels can be booked.'),
'type' => 'text',
'id' => 'max_global_book_date',
'auto_value' => false,
'value' => date('d-m-Y', strtotime($maxOrderDate)),
'class' => 'fixed-width-xxl readonly',
),
'GLOBAL_PREPARATION_TIME' => array(
'title' => $this->l('Preparation time'),
'hint' => $this->l('Number of days required to prepare a room for a guest\'s stay. For example, if you set this value to 3 and someone is booking on 2nd of March he can only book rooms for dates from and after 3 days, i.e, 5th of March.'),
'title' => $this->l('Minimum booking offset'),
'hint' => $this->l('The minimum booking offset is the minimum number of days before the check-in date that a guest must book a room. For example, if you set this value to 3 and someone is booking on 2nd of March he can only book rooms for dates from and after 3 days, i.e, 5th of March.'),
'desc' => $this->l('Set to 0 to disable this feature.'),
'type' => 'text',
'class' => 'fixed-width-xl',
@@ -329,6 +332,7 @@ class AdminOrderPreferencesControllerCore extends AdminController
$this->errors[] = Tools::displayError('Please assign a valid CMS page for Terms and Conditions.');
}
$_POST['MAX_GLOBAL_BOOKING_DATE'] = date('Y-m-d', strtotime(Tools::getValue('MAX_GLOBAL_BOOKING_DATE')));
$maxGlobalBookingDate = Tools::getValue('MAX_GLOBAL_BOOKING_DATE');
$globalPreparationTime = Tools::getValue('GLOBAL_PREPARATION_TIME');
$maxGlobalBookingDateFormatted = date('Y-m-d', strtotime($maxGlobalBookingDate));
@@ -342,9 +346,9 @@ class AdminOrderPreferencesControllerCore extends AdminController
}
if ($globalPreparationTime === '') {
$this->errors[] = Tools::displayError('Field \'Preparation time\' can not be empty.');
$this->errors[] = Tools::displayError('Field \'Minimum booking offset\' can not be empty.');
} elseif ($globalPreparationTime !== '0' && !Validate::isUnsignedInt($globalPreparationTime)) {
$this->errors[] = Tools::displayError('Field \'Preparation time\' is invalid.');
$this->errors[] = Tools::displayError('Field \'Minimum booking offset\' is invalid.');
}
}

View File

@@ -24,17 +24,6 @@
* International Registered Trademark & Property of PrestaShop SA
*/
class BoOrder extends PaymentModule
{
public $active = 1;
public $name = 'bo_order';
public function __construct()
{
$this->displayName = $this->l('Back office order');
}
}
/**
* @property Order $object
*/
@@ -628,11 +617,23 @@ class AdminOrdersControllerCore extends AdminController
$payment_methods[] = $module->displayName;
}
}
// Set the order currency at first element of currencies
if ($currencies = Currency::getCurrenciesByIdShop($objOrder->id_shop)) {
foreach ($currencies as $key => $currency) {
if ($currency['id_currency'] == $objOrder->id_currency) {
unset($currencies[$key]);
array_unshift($currencies, $currency);
break;
}
}
}
$this->context->smarty->assign(
array(
'current_index' => self::$currentIndex,
'order' => $objOrder,
'currencies' => Currency::getCurrenciesByIdShop($objOrder->id_shop),
'currencies' => $currencies,
'payment_methods' => $payment_methods,
'payment_types' => $this->getPaymentsTypes(),
'invoices_collection' => $objOrder->getInvoicesCollection(),
@@ -765,6 +766,33 @@ class AdminOrdersControllerCore extends AdminController
die(Tools::jsonEncode($response));
}
public function ajaxProcessInitRoomAllotmentCommentModal()
{
$response['hasError'] = 1;
if (Validate::isLoadedObject($objBookingDetail = new HotelBookingDetail(Tools::getValue('id_hotel_booking')))) {
if ($objBookingDetail->booking_type == HotelBookingDetail::ALLOTMENT_MANUAL) {
// get booking information by order
$this->context->smarty->assign('comment', $objBookingDetail->comment);
$title = $objBookingDetail->room_num.' - '.$objBookingDetail->room_type_name.' ('.
Tools::displayDate($objBookingDetail->date_from).' - '.Tools::displayDate($objBookingDetail->date_to).')';
$modal = array(
'modal_id' => 'room-allotment-comment-modal',
'modal_class' => 'modal-md order_detail_modal',
'modal_title' => '<i class="icon icon-comment"></i> &nbsp'.$title,
'modal_content' => $this->context->smarty->fetch('controllers/orders/modals/_room_allotment_comment.tpl'),
'modal_actions' => array(),
);
$this->context->smarty->assign($modal);
$response['hasError'] = 0;
$response['modalHtml'] = $this->context->smarty->fetch('modal.tpl');
}
}
die(Tools::jsonEncode($response));
}
public function ajaxProcessInitRoomReallocationModal()
{
// set modal details
@@ -991,7 +1019,9 @@ class AdminOrdersControllerCore extends AdminController
$this->addJS(_PS_JS_DIR_.'vendor/d3.v3.min.js');
if ($this->tabAccess['edit'] == 1 && $this->display == 'view') {
$this->addJS(_PS_JS_DIR_.'admin/orders.js');
if ($this->loadObject()) {
$this->addJS(_PS_JS_DIR_.'admin/orders.js');
}
// add js for reallocation process
$this->addJS(_PS_JS_DIR_.'admin/reallocation.js');
// $this->addJS(_PS_JS_DIR_.'admin/orders-product-event.js');
@@ -2236,6 +2266,88 @@ class AdminOrdersControllerCore extends AdminController
} else {
$this->errors = Tools::displayError('An error occurred while resolving overbooking.');
}
// Set old orders address as current order address
} elseif (Tools::getValue('action') && Tools::getValue('action') == 'set_old_orders_address') {
if ($idOrder = Tools::getValue('id_order')) {
if (Validate::isLoadedObject($objOrder = new Order($idOrder))) {
$idAddressInvoice = $objOrder->id_address_invoice;
if ($idAddressInvoice && Validate::isLoadedObject(new Address($idAddressInvoice))) {
// get all customer orders and set old orders address as current order address
if ($customerOrders = Order::getCustomerOrders($objOrder->id_customer)) {
foreach ($customerOrders as $order) {
$objOrder = new Order($order['id_order']);
$objOrder->id_address_invoice = $idAddressInvoice;
$objOrder->update();
}
}
Tools::redirectAdmin(self::$currentIndex.'&id_order='.$idOrder.'&vieworder&conf=6&token='.$this->token);
} else {
$this->errors = Tools::displayError('Address not found. Please try again.');
}
} else {
$this->errors = Tools::displayError('Order not found. Please try again.');
}
} else {
$this->errors = Tools::displayError('Order not found. Please try again.');
}
// Set customer current active address as current order address
} elseif (Tools::getValue('action') && Tools::getValue('action') == 'set_address_current_address') {
if ($idOrder = Tools::getValue('id_order')) {
if (Validate::isLoadedObject($objOrder = new Order($idOrder))) {
$idAddressInvoice = $objOrder->id_address_invoice;
if ($idAddressInvoice && Validate::isLoadedObject($objOrderAddress = new Address($idAddressInvoice))) {
$updateAddress = 1;
if ($idCustomerAddress = Customer::getCustomerIdAddress($objOrder->id_customer)) {
// only proceed if current active address and current order address are different
if ($idCustomerAddress != $idAddressInvoice) {
if (Validate::isLoadedObject($objActiveAddress = new Address($idCustomerAddress))) {
// set current active address information from order address
$objOrderAddress->id = $objOrderAddress->id_address = $objActiveAddress->id;
$objOrderAddress->deleted = 0;
$objOrderAddress->update();
} else {
$this->errors = Tools::displayError('Customer address not found. Please try again.');
}
}
} else {
// If customer has no active address, create new customer address with the order address
$objOrderAddress->id = $objOrderAddress->id_address = null;
$objOrderAddress->deleted = 0;
$objOrderAddress->add();
}
if (!count($this->errors)) {
Tools::redirectAdmin(self::$currentIndex.'&id_order='.$idOrder.'&vieworder&conf=6&token='.$this->token);
}
} else {
$this->errors = Tools::displayError('Address not found. Please try again.');
}
} else {
$this->errors = Tools::displayError('Order not found. Please try again.');
}
} else {
$this->errors = Tools::displayError('Order not found. Please try again.');
}
} elseif (Tools::getValue('action') && Tools::getValue('action') == 'set_order_active_address') {
if ($idOrder = Tools::getValue('id_order')) {
if (Validate::isLoadedObject($objOrder = new Order($idOrder))) {
// get currenct active address of the customer
if ($idCustomerAddress = Customer::getCustomerIdAddress($objOrder->id_customer)) {
$objOrder->id_address_invoice = $idCustomerAddress;
if ($objOrder->update()) {
Tools::redirectAdmin(self::$currentIndex.'&id_order='.$idOrder.'&vieworder&conf=6&token='.$this->token);
} else {
$this->errors[] = Tools::displayError('Some error occurred while updating address detail. Please try again.');
}
} else {
$this->errors = Tools::displayError('Customer address not found. Please try again.');
}
} else {
$this->errors = Tools::displayError('Order not found. Please try again.');
}
} else {
$this->errors = Tools::displayError('Order not found. Please try again.');
}
}
// Sending loader image for the modals to be used for all the modals ajax processes
@@ -2853,9 +2965,30 @@ class AdminOrdersControllerCore extends AdminController
// Overbookings information of the order
$orderOverBookings = $objHotelBookingDetail->getOverbookedRooms($order->id, 0, '', '', 0, 0, 1);
// Guest address info
$guestFormattedAddress = '';
$idOrderAddressInvoice = 0;
$ordersWithDiffInvAddr = 0;
$idCurrentAddress = Customer::getCustomerIdAddress($order->id_customer);
if ($order->id_address_invoice && Validate::isLoadedObject($objGuestAddress = new Address($order->id_address_invoice))) {
$idOrderAddressInvoice = $order->id_address_invoice;
$guestFormattedAddress = AddressFormat::generateAddress($objGuestAddress, array(), "<br />");
// get customer orders without same id_address_invoice
if ($customerOrders = Order::getCustomerOrders($order->id_customer, false, null, $idOrderAddressInvoice, 1)) {
if ($customerOrders > 1) {
$ordersWithDiffInvAddr = 1;
}
}
}
$this->tpl_view_vars = array(
'guestFormattedAddress' => $guestFormattedAddress,
'idOrderAddressInvoice' => $idOrderAddressInvoice,
'ordersWithDiffInvAddr' => $ordersWithDiffInvAddr,
'idCurrentAddress' => $idCurrentAddress,
'totalRefundedRooms' => $totalRefundedRooms,
'orderOverBookings' => $orderOverBookings,
// refund info
'refund_allowed' => (int) $order->isReturnable(),
'applicable_refund_policies' => $applicableRefundPolicies,
'returns' => OrderReturn::getOrdersReturn($order->id_customer, $order->id),
@@ -2948,9 +3081,9 @@ class AdminOrdersControllerCore extends AdminController
'customer' => $customer)
),
'orderDocuments' => $order->getDocuments(),
'ROOM_STATUS_ALLOTED' => HotelBookingDetail::STATUS_ALLOTED,
'ROOM_STATUS_CHECKED_IN' => HotelBookingDetail::STATUS_CHECKED_IN,
'ROOM_STATUS_CHECKED_OUT' => HotelBookingDetail::STATUS_CHECKED_OUT,
'ALLOTMENT_MANUAL' => HotelBookingDetail::ALLOTMENT_MANUAL,
);
return parent::renderView();
@@ -4820,6 +4953,7 @@ class AdminOrdersControllerCore extends AdminController
'tax_excl' => $totalRoomPriceAfterTE,
'tax_incl' => $totalRoomPriceAfterTI,
);
if ($update_htl_tables = $obj_booking_detail->UpdateHotelCartHotelOrderOnOrderEdit(
$id_order,
$id_room,
@@ -6236,6 +6370,14 @@ class AdminOrdersControllerCore extends AdminController
$res &= $objOrderDetail->update();
}
if ($objOrderDetail->id_order_invoice != 0) {
// values changes as values are calculated
$objOrderInvoice = new OrderInvoice($objOrderDetail->id_order_invoice);
$objOrderInvoice->total_paid_tax_excl -= $priceTaxExcl;
$objOrderInvoice->total_paid_tax_incl -= $priceTaxIncl;
$res &= $objOrderInvoice->update();
}
$order->total_paid_tax_excl -= $priceTaxExcl;
$order->total_paid_tax_incl -= $priceTaxIncl;
$order->total_paid -= $priceTaxIncl;
@@ -6268,6 +6410,9 @@ class AdminOrdersControllerCore extends AdminController
// valiadate services being added
if (Validate::isLoadedObject($objHotelBookingDetail = new HotelBookingDetail($idBookingDetail))) {
$objOrder = new Order($objHotelBookingDetail->id_order);
$objOrderDetail = new OrderDetail($objHotelBookingDetail->id_order_detail);
$objOrderInvoice = new OrderInvoice($objOrderDetail->id_order_invoice);
// set context currency So that we can get prices in the order currency
$this->context->currency = new Currency($objOrder->id_currency);
@@ -6449,7 +6594,7 @@ class AdminOrdersControllerCore extends AdminController
}
$order_detail = new OrderDetail();
$order_detail->createList($order, $cart, $order->getCurrentOrderState(), $productList, (isset($order_invoice) ? $order_invoice->id : 0), true);
$order_detail->createList($order, $cart, $order->getCurrentOrderState(), $productList, (isset($objOrderInvoice) ? $objOrderInvoice->id : 0), true);
$objRoomTypeServiceProductOrderDetail = new RoomTypeServiceProductOrderDetail();
$objRoomTypeServiceProductOrderDetail->id_product = $product['id_product'];
@@ -6473,16 +6618,18 @@ class AdminOrdersControllerCore extends AdminController
$order->total_paid_tax_excl += Tools::ps_round((float)($totalPriceChangeTaxExcl), 2);
$order->total_paid_tax_incl += Tools::ps_round((float)($totalPriceChangeTaxIncl), 2);
if (isset($order_invoice) && Validate::isLoadedObject($order_invoice)) {
$order->total_shipping = $order_invoice->total_shipping_tax_incl;
$order->total_shipping_tax_incl = $order_invoice->total_shipping_tax_incl;
$order->total_shipping_tax_excl = $order_invoice->total_shipping_tax_excl;
// update invoice total
if (isset($objOrderInvoice) && Validate::isLoadedObject($objOrderInvoice)) {
$objOrderInvoice->total_paid_tax_excl += Tools::ps_round((float)($totalPriceChangeTaxExcl), 2);
$objOrderInvoice->total_paid_tax_incl += Tools::ps_round((float)($totalPriceChangeTaxIncl), 2);
$objOrderInvoice->save();
}
// discount
$order->total_discounts += (float)abs($cart->getOrderTotal(true, Cart::ONLY_DISCOUNTS));
$order->total_discounts_tax_excl += (float)abs($cart->getOrderTotal(false, Cart::ONLY_DISCOUNTS));
$order->total_discounts_tax_incl += (float)abs($cart->getOrderTotal(true, Cart::ONLY_DISCOUNTS));
// Save changes of order
$order->update();
if (Validate::isLoadedObject($specific_price)) {
@@ -6681,8 +6828,9 @@ class AdminOrdersControllerCore extends AdminController
$order_invoice = new OrderInvoice($order_detail->id_order_invoice);
$order_invoice->total_paid_tax_excl += $priceDiffTaxExcl;
$order_invoice->total_paid_tax_incl += $priceDiffTaxIncl;
$res &= $order_invoice->update();
$order_invoice->update();
}
$order = new Order($objBookingDetail->id_order);
$order->total_paid_tax_excl += $priceDiffTaxExcl;
$order->total_paid_tax_incl += $priceDiffTaxIncl;
@@ -6923,4 +7071,4 @@ class AdminOrdersControllerCore extends AdminController
$this->ajaxDie(json_encode($result));
}
}
}

View File

@@ -201,13 +201,15 @@ class AdminProductsControllerCore extends AdminController
LEFT JOIN `'._DB_PREFIX_.'address` aa ON (aa.`id_hotel` = hb.`id`)
LEFT JOIN `'._DB_PREFIX_.'feature_product` fp ON (fp.`id_product` = a.`id_product`)
LEFT JOIN `'._DB_PREFIX_.'htl_room_type_demand` hrtd ON (hrtd.`id_product` = a.`id_product`)
LEFT JOIN `'._DB_PREFIX_.'htl_room_type_service_product` hrtsp ON ((hrtsp.`element_type` = '.(int) RoomTypeServiceProduct::WK_ELEMENT_TYPE_HOTEL.' AND hrtsp.`id_element` = hrt.`id_hotel`) OR (hrtsp.`element_type` = '.(int) RoomTypeServiceProduct::WK_ELEMENT_TYPE_ROOM_TYPE.' AND hrtsp.`id_element` = a.`id_product`))';
LEFT JOIN `'._DB_PREFIX_.'htl_room_type_service_product` hrtsp ON ((hrtsp.`element_type` = '.(int) RoomTypeServiceProduct::WK_ELEMENT_TYPE_HOTEL.' AND hrtsp.`id_element` = hrt.`id_hotel`) OR (hrtsp.`element_type` = '.(int) RoomTypeServiceProduct::WK_ELEMENT_TYPE_ROOM_TYPE.' AND hrtsp.`id_element` = a.`id_product`))
LEFT JOIN `'._DB_PREFIX_.'htl_advance_payment` hap ON (hap.`id_product` = a.`id_product`)';
$this->_select .= ' (SELECT COUNT(hri.`id`) FROM `'._DB_PREFIX_.'htl_room_information` hri WHERE hri.`id_product` = a.`id_product`) as num_rooms, ';
$this->_select .= ' a.`show_at_front`, (SELECT COUNT(hri.`id`) FROM `'._DB_PREFIX_.'htl_room_information` hri WHERE hri.`id_product` = a.`id_product`) as num_rooms, ';
$this->_select .= 'hrt.`adults`, hrt.`children`, hrt.`max_guests`, hb.`id` as id_hotel, aa.`city`, hbl.`hotel_name`, ';
$this->_select .= 'shop.`name` AS `shopname`, a.`id_shop_default`, ';
$this->_select .= $alias_image.'.`id_image` AS `id_image`, cl.`name` AS `name_category`, '.$alias.'.`price`, 0 AS `price_final`, a.`is_virtual`, pd.`nb_downloadable`, sav.`quantity` AS `sav_quantity`, '.$alias.'.`active`, IF(sav.`quantity`<=0, 1, 0) AS `badge_danger`';
$this->_select .= ', IFNULL((SELECT hap.`active` FROM `'._DB_PREFIX_.'htl_advance_payment` hap WHERE hap.`id_product` = a.`id_product`), 0) AS advance_payment';
$this->_select .= ', IFNULL(hap.`active`, 0) AS advance_payment';
$this->_select .= ', IF(IFNULL(hap.`active`, 0), 1, 0) badge_success, IF(IFNULL(hap.`active`, 0), 0, 1) badge_danger ';
if ($join_category) {
$this->_join .= ' INNER JOIN `'._DB_PREFIX_.'category_product` cp ON (cp.`id_product` = a.`id_product` AND cp.`id_category` = '.(int)$this->_category->id.') ';
@@ -319,10 +321,23 @@ class AdminProductsControllerCore extends AdminController
'optional' => true,
);
$this->fields_list['show_at_front'] = array(
'title' => $this->l('Show at front'),
'align' => 'text-center',
'type' => 'bool',
'active' => 'show_at_front',
'optional' => true,
'havingFilter' => true,
'visible_default' => true,
'orderby' => false,
);
if (Configuration::get('WK_ALLOW_ADVANCED_PAYMENT')) {
$this->fields_list['advance_payment'] = array(
'title' => $this->l('Advance Payment'),
'active' => 'advance_payment',
'callback' => 'getAdvancePaymentStatus',
'badge_success' => true,
'badge_danger' => true,
'align' => 'text-center',
'type' => 'bool',
'optional' => true,
@@ -431,6 +446,18 @@ class AdminProductsControllerCore extends AdminController
}
}
public function getAdvancePaymentStatus($val, $row)
{
if ($val) {
$str_return = $this->l('Yes');
} else {
$str_return = $this->l('No');
}
return $str_return;
}
private function buildCategoryOptions($category)
{
$space = str_repeat('&nbsp;', 5 * (($category['level_depth'] - $this->objLocationsCategory->level_depth) - 1));
@@ -816,6 +843,13 @@ class AdminProductsControllerCore extends AdminController
if (!$id_hotel_new) {
$id_hotel_new = $room_type_info['id_hotel'];
}
if ($product->hasAttributes()) {
Product::updateDefaultAttribute($product->id);
} else {
Product::duplicateSpecificPrices($id_product_old, $product->id);
}
$id_room_type_new = HotelRoomType::duplicateRoomType(
$id_product_old,
$product->id,
@@ -839,11 +873,6 @@ class AdminProductsControllerCore extends AdminController
} else {
$this->errors[] = Tools::displayError('An error occurred while duplicating room type.');
}
if ($product->hasAttributes()) {
Product::updateDefaultAttribute($product->id);
} else {
Product::duplicateSpecificPrices($id_product_old, $product->id);
}
if (!Tools::getValue('noimage') && !Image::duplicateProductImages($id_product_old, $product->id, $combination_images)) {
$this->errors[] = Tools::displayError('An error occurred while copying images.');
@@ -1336,10 +1365,10 @@ class AdminProductsControllerCore extends AdminController
$this->errors[] = Tools::displayError('You do not have permission to add this.');
}
}
// Toggle Advance Payment
elseif (Tools::getIsset('advance_payment'.$this->table)) {
// Toggle Show at front
elseif (Tools::getIsset('show_at_front'.$this->table)) {
if ($this->tabAccess['edit'] === '1') {
$this->action = 'toggleAdvancePayment';
$this->action = 'toggleShowAtFront';
} else {
$this->errors[] = Tools::displayError('You do not have permission to edit this.');
}
@@ -1457,6 +1486,7 @@ class AdminProductsControllerCore extends AdminController
if (in_array($this->display, array('add', 'edit'))
&& $this->tabAccess[$this->display] == '1'
&& $this->loadObject(true)
) {
$this->addJqueryUI(array(
'ui.core',
@@ -1896,38 +1926,21 @@ class AdminProductsControllerCore extends AdminController
return $res;
}
public function processToggleAdvancePayment()
public function processToggleShowAtFront()
{
if (Configuration::get('WK_ALLOW_ADVANCED_PAYMENT')) {
$this->loadObject(true);
if (!Validate::isLoadedObject($this->object)) {
return false;
}
if (!$this->loadObject()) {
return false;
}
if (!Product::isBookingProduct($this->object->id)) {
return false;
}
if (!Product::isBookingProduct($this->object->id)) {
return false;
}
$objHotelAdvancedPayment = new HotelAdvancedPayment();
$roomTypeAdvancePaymentInfo = $objHotelAdvancedPayment->getIdAdvPaymentByIdProduct($this->object->id);
if ($roomTypeAdvancePaymentInfo) {
$objHotelAdvancedPayment = new HotelAdvancedPayment($roomTypeAdvancePaymentInfo['id']);
$objHotelAdvancedPayment->active = !$objHotelAdvancedPayment->active;
} else {
$objHotelAdvancedPayment->id_product = $this->object->id;
$objHotelAdvancedPayment->payment_type = '';
$objHotelAdvancedPayment->value = '';
$objHotelAdvancedPayment->id_currency = '';
$objHotelAdvancedPayment->tax_include = '';
$objHotelAdvancedPayment->calculate_from = 0;
$objHotelAdvancedPayment->active = 1;
}
if ($objHotelAdvancedPayment->save()) {
Tools::redirectAdmin(self::$currentIndex.'&token='.$this->token.'&conf=4');
} else {
$this->errors[] = $this->l('Something went wrong while updating Advance payment status.');
}
$this->object->show_at_front = !$this->object->show_at_front;
if ($this->object->save()) {
Tools::redirectAdmin(self::$currentIndex.'&token='.$this->token.'&conf=4');
} else {
$this->errors[] = $this->l('An error occurred while updating "show at front".');
}
}
@@ -2463,7 +2476,7 @@ class AdminProductsControllerCore extends AdminController
$helper->title = $this->l('Occupied Rooms', null, null, false);
$helper->subtitle = $this->l('Today', null, null, false);
$helper->source = $this->context->link->getAdminLink('AdminStats').'&ajax=1&action=getKpi&kpi=occupied_rooms';
$helper->tooltip = $this->l('The current count of rooms that are currently occupied by guests.', null, null, false);
$helper->tooltip = $this->l('The count of rooms that are currently occupied by guests.', null, null, false);
$kpis[] = $helper;
$helper = new HelperKpi();
@@ -2473,7 +2486,7 @@ class AdminProductsControllerCore extends AdminController
$helper->title = $this->l('Vacant Rooms', null, null, false);
$helper->subtitle = $this->l('Today', null, null, false);
$helper->source = $this->context->link->getAdminLink('AdminStats').'&ajax=1&action=getKpi&kpi=vacant_rooms';
$helper->tooltip = $this->l('The count of rooms that are currently unoccupied and available for booking.', null, null, false);
$helper->tooltip = $this->l('The count of rooms that are either booked but currently unoccupied or available for booking', null, null, false);
$kpis[] = $helper;
$helper = new HelperKpi();
@@ -2483,7 +2496,7 @@ class AdminProductsControllerCore extends AdminController
$helper->title = $this->l('Booked Rooms', null, null, false);
$helper->subtitle = $this->l('Today', null, null, false);
$helper->source = $this->context->link->getAdminLink('AdminStats').'&ajax=1&action=getKpi&kpi=booked_rooms';
$helper->tooltip = $this->l('The number of rooms that are currently booked but not yet occupied.', null, null, false);
$helper->tooltip = $this->l('The total number of rooms that are currently booked and and awaiting guest check-in', null, null, false);
$kpis[] = $helper;
$helper = new HelperKpi();
@@ -2493,7 +2506,7 @@ class AdminProductsControllerCore extends AdminController
$helper->title = $this->l('Disabled Rooms', null, null, false);
$helper->subtitle = $this->l('Today', null, null, false);
$helper->source = $this->context->link->getAdminLink('AdminStats').'&ajax=1&action=getKpi&kpi=disabled_rooms';
$helper->tooltip = $this->l('The number of rooms that are currently disabled.', null, null, false);
$helper->tooltip = $this->l('The total number of rooms that are currently disabled.', null, null, false);
$kpis[] = $helper;
$helper = new HelperKpi();
@@ -2503,7 +2516,7 @@ class AdminProductsControllerCore extends AdminController
$helper->title = $this->l('Online Bookable Rooms', null, null, false);
$helper->subtitle = $this->l('Today', null, null, false);
$helper->source = $this->context->link->getAdminLink('AdminStats').'&ajax=1&action=getKpi&kpi=online_bookable_rooms';
$helper->tooltip = $this->l('The total number of rooms that can be booked only using website.', null, null, false);
$helper->tooltip = $this->l('The total number of rooms that can be booked directly from the front office.', null, null, false);
$kpis[] = $helper;
$helper = new HelperKpi();
@@ -2513,7 +2526,7 @@ class AdminProductsControllerCore extends AdminController
$helper->title = $this->l('Offline Bookable Rooms', null, null, false);
$helper->subtitle = $this->l('Today', null, null, false);
$helper->source = $this->context->link->getAdminLink('AdminStats').'&ajax=1&action=getKpi&kpi=offline_bookable_rooms';
$helper->tooltip = $this->l('The number of rooms that can be booked either through website or offline channels (e.g., phone or in-person).', null, null, false);
$helper->tooltip = $this->l('The total number of rooms available for booking through the back office.', null, null, false);
$kpis[] = $helper;
$helper = new HelperKpi();
@@ -2850,9 +2863,7 @@ class AdminProductsControllerCore extends AdminController
}
// let's calculate this once for all
if (!Validate::isLoadedObject($this->object) && Tools::getValue('id_product')) {
$this->errors[] = 'Unable to load object';
} else {
if ($this->loadObject(true)) {
$this->_displayDraftWarning($this->object->active);
// if there was an error while saving, we don't want to lose posted data

View File

@@ -283,11 +283,9 @@ class AdminRequestSqlControllerCore extends AdminController
$this->initToolbar();
$this->initPageHeaderToolbar();
if ($this->display == 'edit' || $this->display == 'add') {
if (!$this->loadObject(true)) {
return;
if ($this->loadObject(true)) {
$this->content .= $this->renderForm();
}
$this->content .= $this->renderForm();
} elseif ($this->display == 'view') {
// Some controllers use the view action without an object
if ($this->className) {

View File

@@ -172,6 +172,7 @@ class AdminSpecificPriceRuleControllerCore extends AdminController
'name' => 'name',
'maxlength' => 32,
'required' => true,
'col' => 3,
'hint' => $this->l('Forbidden characters').' <>;=#{}'
),
array(
@@ -222,8 +223,8 @@ class AdminSpecificPriceRuleControllerCore extends AdminController
'name' => 'price',
'disabled' => ($this->object->price == -1 ? 1 : 0),
'maxlength' => 10,
'suffix' => $this->context->currency->getSign('right'),
'suffix' => $this->context->currency->sign,
'col' => 3,
),
array(
'type' => 'checkbox',
@@ -279,6 +280,7 @@ class AdminSpecificPriceRuleControllerCore extends AdminController
'type' => 'text',
'label' => $this->l('Reduction'),
'name' => 'reduction',
'col' => 3,
'required' => true,
),
),
@@ -297,16 +299,12 @@ class AdminSpecificPriceRuleControllerCore extends AdminController
);
$price = $this->getFieldValue($this->object, 'price');
if ($price != -1 && Validate::isPrice($price)) {
$price = number_format($price, 6);
} else {
if ($price == -1 || !Validate::isPrice($price)) {
$price = '';
}
$reduction = $this->getFieldValue($this->object, 'reduction');
if (Validate::isPrice($reduction)) {
$reduction = number_format($reduction, 6);
} else {
if (!Validate::isPrice($reduction)) {
$reduction = 0;
}

View File

@@ -573,20 +573,20 @@ class AdminStatsControllerCore extends AdminStatsTabController
{
$sql = 'SELECT p.`id_product`,
(
SELECT IFNULL(SUM(ROUND((DATEDIFF(LEAST(hbd.`date_to`, "'.pSQL($dateTo).'"), GREATEST(hbd.`date_from`, "'.pSQL($dateFrom).'")) / DATEDIFF(hbd.`date_to`, hbd.`date_from`)) * hbd.`total_price_tax_excl`, 2)), 0)
SELECT count(hbd.`id_product`)
FROM `'._DB_PREFIX_.'htl_booking_detail` hbd
LEFT JOIN `'._DB_PREFIX_.'orders` o
ON (o.`id_order` = hbd.`id_order`)
WHERE hbd.`id_product` = p.`id_product` AND o.`valid` = 1
AND hbd.`date_to` > "'.pSQL($dateFrom).'" AND hbd.`date_from` < "'.pSQL($dateTo).'"
) AS totalRevenue
FROM `'._DB_PREFIX_.'product` p
) as total_booked FROM `'._DB_PREFIX_.'product` p
INNER JOIN `'._DB_PREFIX_.'htl_room_type` hrt
ON (hrt.`id_product` = p.`id_product`)
WHERE p.`active` = 1 AND p.`booking_product` = 1'.
WHERE p.`active` = 1 AND p.`booking_product` = 1 '.
(!is_null($idHotel) ? HotelBranchInformation::addHotelRestriction($idHotel, 'hrt') : '').'
HAVING totalRevenue > 0
ORDER BY totalRevenue DESC';
GROUP By p.`id_product`
HAVING total_booked > 0
ORDER BY total_booked DESC';
return Db::getInstance()->getValue($sql);
}
@@ -856,20 +856,36 @@ class AdminStatsControllerCore extends AdminStatsTabController
break;
case 'occupied_rooms':
$value = AdminStatsController::getOccupiedRooms(0);
$value = AdminStatsController::getDistinctRoomBookingsCount(
date('Y-m-d', strtotime('-1 day')),
date('Y-m-d'),
0,
HotelBookingDetail::STATUS_CHECKED_IN
);
break;
case 'vacant_rooms':
$totalAvailableRooms = AdminStatsController::getAvailableRoomsForDiscreteDates(date('Y-m-d'), null, 0);
$totalAvailableRooms = $totalAvailableRooms[strtotime(date('Y-m-d'))];
$totalOccupiedRooms = AdminStatsController::getOccupiedRooms(0);
$value = $totalAvailableRooms - $totalOccupiedRooms;
$totalUnAvailRooms = AdminStatsController::getDisabledRoomsForDiscreteDates(date('Y-m-d'), null, 0);
$totalUnAvailRooms = $totalUnAvailRooms[strtotime(date('Y-m-d'))];
$totalRooms = AdminStatsController::getTotalRooms(0);
$totalOccupiedRooms = AdminStatsController::getDistinctRoomBookingsCount(
date('Y-m-d', strtotime('-1 day')),
date('Y-m-d'),
0,
HotelBookingDetail::STATUS_CHECKED_IN
);
$value = $totalRooms - ($totalUnAvailRooms + $totalOccupiedRooms);
break;
case 'booked_rooms':
$value = AdminStatsController::getBookedRooms(0);
$value = AdminStatsController::getDistinctRoomBookingsCount(
date('Y-m-d'),
date('Y-m-d', strtotime('+1 day')),
0,
HotelBookingDetail::STATUS_ALLOTED
);
break;
@@ -894,7 +910,12 @@ class AdminStatsControllerCore extends AdminStatsTabController
case 'total_frequent_customers':
$nbOrdersFrequentCustomers = Configuration::get('PS_KPI_FREQUENT_CUSTOMER_NB_ORDERS');
$value = AdminStatsController::getTotalFrequentCustomers($nbOrdersFrequentCustomers, 0);
$value = AdminStatsController::getTotalFrequentCustomers(
date('Y-m-d', strtotime('-365 day')),
date('Y-m-d'),
$nbOrdersFrequentCustomers,
0
);
break;
@@ -965,6 +986,12 @@ class AdminStatsControllerCore extends AdminStatsTabController
case 'average_lead_time':
$dateToday = date('Y-m-d');
$value = Tools::ps_round(AdminStatsController::getAverageLeadTime(), 2);
if ($value && $value <= 1) {
$value .= ' '.$this->l('day');
} else {
$value .= ' '.$this->l('days');
}
break;
case 'average_guest_in_booking':
$dateToday = date('Y-m-d');
@@ -1103,13 +1130,14 @@ class AdminStatsControllerCore extends AdminStatsTabController
);
}
public static function getTotalRooms($idHotel = null)
public static function getTotalRooms($idHotel = null, $active = null)
{
$sql = 'SELECT COUNT(hri.`id`)
FROM `'._DB_PREFIX_.'htl_room_information` hri
INNER JOIN `'._DB_PREFIX_.'product` p
ON (p.`id_product` = hri.`id_product`)
WHERE p.`booking_product` = 1 '.
(!is_null($active) ? ' AND p.`active` ='.(int) $active : ' ').
(!is_null($idHotel) ? HotelBranchInformation::addHotelRestriction($idHotel, 'hri') : '');
return Db::getInstance()->getValue($sql);
@@ -1123,16 +1151,7 @@ class AdminStatsControllerCore extends AdminStatsTabController
$occupancyData = array('count_total' => 0, 'count_occupied' => 0, 'count_available' => 0, 'count_unavailable' => 0);
$countTotal = Db::getInstance()->getValue(
'SELECT COUNT(hri.`id`)
FROM `'._DB_PREFIX_.'htl_room_information` hri
INNER JOIN `'._DB_PREFIX_.'htl_branch_info` hbi
ON (hbi.`id` = hri.`id_hotel`)
LEFT JOIN `'._DB_PREFIX_.'product` p
ON (p.`id_product` = hri.`id_product`)
WHERE p.`active` = 1'.
HotelBranchInformation::addHotelRestriction($idsHotel, 'hri')
);
$countTotal = self::getTotalRooms($idsHotel, true);
$occupancyData['count_total'] = $countTotal;
// Occupied rooms are booked rooms that are not refunded in the date range
@@ -1417,7 +1436,27 @@ class AdminStatsControllerCore extends AdminStatsTabController
return $result;
}
public static function getTotalOccupiedRooms($dateFrom, $dateTo, $idHotel = null)
public static function getDistinctRoomBookingsCount($dateFrom = false, $dateTo = false, $idHotel = null, $roomBookingStatus = null)
{
$sql = 'SELECT COUNT(DISTINCT hbd.`id_room`)
FROM `'._DB_PREFIX_.'htl_booking_detail` hbd
LEFT JOIN `'._DB_PREFIX_.'htl_room_information` hri
ON (hri.`id` = hbd.`id_room`)
LEFT JOIN `'._DB_PREFIX_.'product` p
ON (p.`id_product` = hri.`id_product`)
WHERE p.`active` = 1
AND hbd.`is_refunded` = 0
AND hbd.`is_cancelled` = 0 '.
(($dateFrom && $dateTo) ? ' AND hbd.`date_from` <= "'.pSQL($dateTo).' 00:00:00" AND hbd.`date_to` > "'.pSQL($dateFrom).' 00:00:00" ': ' ').
(!is_null($roomBookingStatus) ? ' AND hbd.`id_status` = '.(int) $roomBookingStatus : ' ').
(!is_null($idHotel) ? HotelBranchInformation::addHotelRestriction($idHotel, 'hbd') : '');
$result = Db::getInstance()->getValue($sql);
return $result ? $result : 0;
}
public static function getTotalBookedRooms($dateFrom, $dateTo, $idHotel = null)
{
$sql = 'SELECT COUNT(hbd.`id_room`)
FROM `'._DB_PREFIX_.'htl_booking_detail` hbd
@@ -1795,47 +1834,7 @@ class AdminStatsControllerCore extends AdminStatsTabController
return $result;
}
/**
* Returns the number of rooms that have been checked-in.
*/
public static function getOccupiedRooms($idHotel = null)
{
$sql = 'SELECT COUNT(DISTINCT hbd.`id_room`)
FROM `'._DB_PREFIX_.'htl_booking_detail` hbd
LEFT JOIN `'._DB_PREFIX_.'htl_room_information` hri
ON (hri.`id` = hbd.`id_room`)
LEFT JOIN `'._DB_PREFIX_.'product` p
ON (p.`id_product` = hri.`id_product`)
WHERE p.`active` = 1
AND hbd.`is_refunded` = 0
AND hbd.`is_cancelled` = 0
AND hbd.`id_status` = '.(int) HotelBookingDetail::STATUS_CHECKED_IN.
(!is_null($idHotel) ? HotelBranchInformation::addHotelRestriction($idHotel, 'hbd') : '');
$result = Db::getInstance()->getValue($sql);
return $result;
}
/**
* Returns the number of rooms that have been booked but not checked-in yet.
*/
public static function getBookedRooms($idHotel = null)
{
$dateToday = date('Y-m-d');
$sql = 'SELECT COUNT(DISTINCT hbd.`id_room`)
FROM `'._DB_PREFIX_.'htl_booking_detail` hbd
WHERE hbd.`is_refunded` = 0
AND hbd.`is_cancelled` = 0
AND hbd.`id_status` = '.(int) HotelBookingDetail::STATUS_ALLOTED.'
AND hbd.`date_from` = "'.pSQL($dateToday).' 00:00:00"'.
(!is_null($idHotel) ? HotelBranchInformation::addHotelRestriction($idHotel, 'hbd') : '');
$result = Db::getInstance()->getValue($sql);
return $result;
}
public static function getTotalFrequentCustomers($nbOrders = 5, $idHotel = null)
public static function getTotalFrequentCustomers($dateFrom, $dateTo, $nbOrders = 5, $idHotel = null)
{
$sql = 'SELECT COUNT(t.`id_customer`)
FROM (
@@ -1846,7 +1845,7 @@ class AdminStatsControllerCore extends AdminStatsTabController
WHERE hbd.`id_order` = o.`id_order` LIMIT 1
) AS id_hotel
FROM `'._DB_PREFIX_.'orders` o
WHERE o.`valid` = 1
WHERE o.`valid` = 1 AND o.`date_add` BETWEEN "'.pSQL($dateFrom).' 00:00:00" AND "'.pSQL($dateTo).' 23:59:59"
GROUP BY o.`id_customer`
HAVING 1 '.(!is_null($idHotel) ? HotelBranchInformation::addHotelRestriction($idHotel) : '').'
) AS t
@@ -1891,7 +1890,7 @@ class AdminStatsControllerCore extends AdminStatsTabController
public static function getTotalNewCustomers($nbDaysNewCustomers)
{
$maxDateAdd = date('Y-m-d H:i:s', strtotime('-'.$nbDaysNewCustomers.' day'));
$maxDateAdd = date('Y-m-d', strtotime('-'.$nbDaysNewCustomers.' day'));
$sql = 'SELECT COUNT(c.`id_customer`)
FROM `'._DB_PREFIX_.'customer` c
WHERE c.`date_add` >= "'.pSQL($maxDateAdd).'" AND c.`deleted` = 0';
@@ -1976,7 +1975,7 @@ class AdminStatsControllerCore extends AdminStatsTabController
$nightsBookedByDate = self::getRoomNightsData($dateFrom, $dateTo, $idHotel);
$totalNightsBooked = array_sum($nightsBookedByDate);
$totalOccupiedRoom = self::getTotalOccupiedRooms($dateFrom, $dateTo, $idHotel);
$totalOccupiedRoom = self::getTotalBookedRooms($dateFrom, $dateTo, $idHotel);
return $totalOccupiedRoom ? ($totalNightsBooked / $totalOccupiedRoom) : 0;
}

View File

@@ -707,6 +707,15 @@ class AdminStatusesControllerCore extends AdminController
$theme = new Theme($this->context->shop->id_theme);
$default_path = '../mails/';
$theme_path = '../themes/'.$theme->directory.'/mails/'; // Mail templates can also be found in the theme folder
$templatesToIgnore = array(
'footer.html',
'header.html',
'shipped.html',
'in_transit.html',
'download_products.html',
'header_order_conf.html',
'test.html'
);
$array = array();
foreach (Language::getLanguages(false) as $language) {
@@ -722,7 +731,9 @@ class AdminStatusesControllerCore extends AdminController
// We merge all available emails in one array
$templates = array_unique(array_merge(scandir(_PS_ADMIN_DIR_.'/'.$default_path.$iso_code), $theme_templates));
foreach ($templates as $key => $template) {
if (!strncmp(strrev($template), 'lmth.', 5)) {
if (!strncmp(strrev($template), 'lmth.', 5)
&& !in_array($template, $templatesToIgnore)
) {
$search_result = array_search($template, $theme_templates);
$array[$iso_code][] = array(
'id' => substr($template, 0, -5),

View File

@@ -186,8 +186,8 @@ class AdminThemesControllerCore extends AdminController
'thumb' => $this->context->link->getMediaLink(_PS_IMG_.Configuration::get('PS_FAVICON').(Tools::getValue('conf') ? sprintf('?%04d', rand(0, 9999)) : ''))
),
'PS_STORES_ICON' => array(
'title' => $this->l('Store icon'),
'hint' => $this->l('Will appear on the store locator (inside Google Maps).').'<br />'.$this->l('Suggested size: 30x30, transparent GIF.'),
'title' => $this->l('Map icon'),
'hint' => $this->l('This icon will be displayed at hotel locations on Google Maps.').'<br />'.$this->l('Suggested size: 30x30, transparent GIF.'),
'type' => 'file',
'name' => 'PS_STORES_ICON',
'tab' => 'icons',

View File

@@ -954,7 +954,7 @@ class AdminTranslationsControllerCore extends AdminController
*
* @throws PrestaShopException
*/
protected function findAndWriteTranslationsIntoFile($file_name, $files, $theme_name, $module_name, $dir = false)
protected function findAndWriteTranslationsIntoFile($file_name, $files, $theme_name, $module_name, $dir = false, $copyExistingTranslations = false)
{
// These static vars allow to use file to write just one time.
static $cache_file = array();
@@ -964,7 +964,12 @@ class AdminTranslationsControllerCore extends AdminController
// Set file_name in static var, this allow to open and wright the file just one time
if (!isset($cache_file[$theme_name.'-'.$file_name])) {
require $file_name;
if (file_exists($file_name)) {
require $file_name;
} else {
$_MODULE = array();
}
$module_existing_translations = $_MODULE;
$str_write = '';
$cache_file[$theme_name.'-'.$file_name] = true;
@@ -1010,25 +1015,26 @@ class AdminTranslationsControllerCore extends AdminController
}
if (array_key_exists($post_key, $_POST) && !in_array($pattern, $array_check_duplicate)) {
$array_check_duplicate[] = $pattern;
if ($_POST[$post_key] == '') {
continue;
}
$array_check_duplicate[] = $pattern;
$str_write .= '$_MODULE['.$pattern.'] = \''.pSQL(str_replace(array("\r\n", "\r", "\n"), ' ', $_POST[$post_key])).'\';'."\n";
$this->total_expression++;
}
}
foreach ($module_existing_translations as $key => $value) {
if (!in_array('\''.$key.'\'', $array_check_duplicate)) {
$str_write .= '$_MODULE[\''.$key.'\'] = \''.pSQL(str_replace(array("\r\n", "\r", "\n"), ' ', $value)).'\';'."\n";
}
}
}
}
if (isset($cache_file[$theme_name.'-'.$file_name]) && $str_write != "<?php\n\nglobal \$_MODULE;\n\$_MODULE = array();\n") {
if ($copyExistingTranslations) {
foreach ($module_existing_translations as $key => $value) {
if (!in_array('\''.$key.'\'', $array_check_duplicate)) {
$str_write .= '$_MODULE[\''.$key.'\'] = \''.pSQL(str_replace(array("\r\n", "\r", "\n"), ' ', $value)).'\';'."\n";
}
}
}
if (isset($cache_file[$theme_name.'-'.$file_name])) {
file_put_contents($file_name, $str_write);
}
}
@@ -1056,6 +1062,8 @@ class AdminTranslationsControllerCore extends AdminController
unset($files[$key]);
} elseif ($type_clear === 'directory' && (!is_dir($path.$file) || in_array($file, $arr_exclude))) {
unset($files[$key]);
} else if ($file == 'index.php') {
unset($files[$key]);
}
}
@@ -1468,8 +1476,15 @@ class AdminTranslationsControllerCore extends AdminController
$arr_files = $this->getAllModuleFiles($modules, null, $this->lang_selected->iso_code, true);
// Find and write all translation modules files
foreach ($arr_files as $value) {
$this->findAndWriteTranslationsIntoFile($value['file_name'], $value['files'], $value['theme'], $value['module'], $value['dir']);
foreach ($arr_files as $key => $value) {
$copyExistingTranslations = false;
if (!isset($arr_files[$key + 1])
|| ($arr_files[$key + 1]['module'] != $value['module'])
) {
$copyExistingTranslations = true;
}
$this->findAndWriteTranslationsIntoFile($value['file_name'], $value['files'], $value['theme'], $value['module'], $value['dir'], $copyExistingTranslations);
}
// Clear modules cache
@@ -2611,12 +2626,14 @@ class AdminTranslationsControllerCore extends AdminController
}
foreach ($dir_to_copy_iso as $dir) {
foreach (scandir($dir) as $file) {
if (!in_array($file, Translate::$ignore_folder)) {
$files_to_copy_iso[] = array(
"from" => $dir.$file,
"to" => str_replace((strpos($dir, _PS_CORE_DIR_) !== false) ? _PS_CORE_DIR_ : _PS_ROOT_DIR_, _PS_ROOT_DIR_.'/themes/'.$current_theme, $dir).$file
);
if (is_dir($dir)) {
foreach (scandir($dir) as $file) {
if (!in_array($file, Translate::$ignore_folder)) {
$files_to_copy_iso[] = array(
"from" => $dir.$file,
"to" => str_replace((strpos($dir, _PS_CORE_DIR_) !== false) ? _PS_CORE_DIR_ : _PS_ROOT_DIR_, _PS_ROOT_DIR_.'/themes/'.$current_theme, $dir).$file
);
}
}
}
}
@@ -2978,7 +2995,7 @@ class AdminTranslationsControllerCore extends AdminController
$tabs_array[$prefix_key][$key]['use_sprintf'] = Translate::checkIfKeyUseSprintf($key);
}
}
} elseif (Tools::file_exists_cache($file_path)) {
} elseif (Tools::file_exists_cache($file_path) && is_file($file_path)) {
$tabs_array = $this->parsePdfClass($file_path, 'php', $GLOBALS[$name_var], $prefix_key, $tabs_array, $missing_translations_pdf);
}
}

View File

@@ -59,7 +59,6 @@ class CategoryControllerCore extends FrontController
$this->addCSS(_THEME_CSS_DIR_.'occupancy.css');
$this->addJS(_THEME_JS_DIR_.'occupancy.js');
$scenes = Scene::getScenes($this->category->id, $this->context->language->id, true, false);
if ($scenes && count($scenes)) {
$this->addJS(_THEME_JS_DIR_.'scenes.js');
@@ -101,16 +100,8 @@ class CategoryControllerCore extends FrontController
// validate dates if available
$dateFrom = Tools::getValue('date_from');
$dateTo = Tools::getValue('date_to');
$currentTimestamp = strtotime(date('Y-m-d'));
$dateFromTimestamp = strtotime($dateFrom);
$dateToTimestamp = strtotime($dateTo);
if ($dateFrom != '' && ($dateFromTimestamp === false || ($dateFromTimestamp < $currentTimestamp))) {
Tools::redirect($this->context->link->getPageLink('pagenotfound'));
}
if ($dateTo != '' && ($dateToTimestamp === false || ($dateToTimestamp < $currentTimestamp))) {
$idHotel = HotelBranchInformation::getHotelIdByIdCategory($id_category);
if (!HotelHelper::validateDateRangeForHotel($dateFrom, $dateTo, $idHotel)) {
Tools::redirect($this->context->link->getPageLink('pagenotfound'));
}
@@ -165,6 +156,16 @@ class CategoryControllerCore extends FrontController
$currency = new Currency($this->context->currency->id);
if ($id_hotel = HotelBranchInformation::getHotelIdByIdCategory($id_category)) {
$preparationTime = (int) HotelOrderRestrictDate::getPreparationTime($id_hotel);
if ($preparationTime
&& strtotime('+ '.$preparationTime.' day') >= strtotime($date_from)
) {
$date_from = date('Y-m-d', strtotime('+ '.$preparationTime.' day'));
if (strtotime($date_from) >= strtotime($date_to)) {
$date_to = date('Y-m-d', strtotime($date_from) + 86400);
}
}
$id_cart = $this->context->cart->id;
$id_guest = $this->context->cookie->id_guest;

View File

@@ -79,8 +79,8 @@ class CmsControllerCore extends FrontController
} elseif (Validate::isLoadedObject($this->cms_category) && $this->cms_category->active && $this->cms_category->isAssociatedToShop()) {
$this->assignCase = 2;
} else {
header('HTTP/1.1 404 Not Found');
header('Status: 404 Not Found');
// incase the cms page in invalid i.e, url is tampered
Tools::redirect($this->context->link->getPageLink('pagenotfound'));
}
}
@@ -134,6 +134,9 @@ class CmsControllerCore extends FrontController
'path' => ($this->cms_category->id !== 1) ? Tools::getPath($this->cms_category->id, $this->cms_category->name, false, 'CMS') : '',
'body_classes' => array($this->php_self.'-'.$this->cms_category->id, $this->php_self.'-'.$this->cms_category->link_rewrite)
));
} else {
// incase the cms page is inactive
Tools::redirect($this->context->link->getPageLink('pagenotfound'));
}
$this->setTemplate(_PS_THEME_DIR_.'cms.tpl');

View File

@@ -235,6 +235,11 @@ class ContactControllerCore extends FrontController
// GOOGLE MAP
if (($PS_API_KEY = Configuration::get('PS_API_KEY')) && Configuration::get('WK_GOOGLE_ACTIVE_MAP')) {
Media::addJsDef(
array(
'PS_STORES_ICON' => $this->context->link->getMediaLink(_PS_IMG_.Configuration::get('PS_STORES_ICON')),
)
);
$this->addJS(
'https://maps.googleapis.com/maps/api/js?key='.$PS_API_KEY.
'&libraries=places&language='.$this->context->language->iso_code.'&region='.$this->context->country->iso_code
@@ -308,6 +313,7 @@ class ContactControllerCore extends FrontController
$this->context->smarty->assign(
array(
'hotelsInfo' => $hotelsInfo,
'viewOnMap' => Configuration::get('WK_GOOGLE_ACTIVE_MAP'),
'gblHtlPhone' => $gblHtlPhone,
'gblHtlEmail' => $gblHtlEmail,
'gblHtlAddress' => $gblHtlAddress,

View File

@@ -250,6 +250,9 @@ class GuestTrackingControllerCore extends FrontController
$total_convenience_fee_te = 0;
$total_convenience_fee_ti = 0;
$objOrderReturn = new OrderReturn();
$refundReqBookings = $objOrderReturn->getOrderRefundRequestedBookings($order->id, 0, 1);
foreach ($orderProducts as $type_key => $type_value) {
if (in_array($type_value['product_id'], $processedProducts)) {
continue;
@@ -307,6 +310,14 @@ class GuestTrackingControllerCore extends FrontController
if ($data_v['is_back_order']) {
$anyBackOrder = 1;
}
if ($refundReqBookings && in_array($data_v['id'], $refundReqBookings) && $data_v['is_refunded']) {
if ($data_v['is_cancelled']) {
$cartHotelData[$type_key]['date_diff'][$date_join]['count_cancelled'] += 1;
} else {
$cartHotelData[$type_key]['date_diff'][$date_join]['count_refunded'] += 1;
}
}
} else {
$num_days = $objBookingDetail->getNumberOfDays($data_v['date_from'], $data_v['date_to']);
$cartHotelData[$type_key]['date_diff'][$date_join]['num_rm'] = 1;
@@ -326,6 +337,16 @@ class GuestTrackingControllerCore extends FrontController
if ($data_v['is_back_order']) {
$anyBackOrder = 1;
}
$cartHotelData[$type_key]['date_diff'][$date_join]['count_cancelled'] = 0;
$cartHotelData[$type_key]['date_diff'][$date_join]['count_refunded'] = 0;
if ($refundReqBookings && in_array($data_v['id'], $refundReqBookings) && $data_v['is_refunded']) {
if ($data_v['is_cancelled']) {
$cartHotelData[$type_key]['date_diff'][$date_join]['count_cancelled'] += 1;
} else {
$cartHotelData[$type_key]['date_diff'][$date_join]['count_refunded'] += 1;
}
}
}
$cartHotelData[$type_key]['date_diff'][$date_join]['is_refunded'] = $data_v['is_refunded'];
@@ -583,6 +604,7 @@ class GuestTrackingControllerCore extends FrontController
'CUSTOMIZE_TEXTFIELD' => Product::CUSTOMIZE_TEXTFIELD,
'use_tax' => Configuration::get('PS_TAX'),
'guestInformations' => (array)$customer,
'view_on_map' => Configuration::get('WK_GOOGLE_ACTIVE_MAP'),
));
}
@@ -614,7 +636,9 @@ class GuestTrackingControllerCore extends FrontController
if ($idHotel = HotelBookingDetail::getIdHotelByIdOrder($objOrder->id)) {
$objHotelBranchInformation = new HotelBranchInformation($idHotel, $this->context->language->id);
if (Validate::isLoadedObject($objHotelBranchInformation)) {
if ($apiKey = Configuration::get('PS_API_KEY')) {
if (($apiKey = Configuration::get('PS_API_KEY'))
&& Configuration::get('WK_GOOGLE_ACTIVE_MAP')
) {
if (floatval($objHotelBranchInformation->latitude) != 0
&& floatval($objHotelBranchInformation->longitude) != 0
) {
@@ -625,6 +649,7 @@ class GuestTrackingControllerCore extends FrontController
'map_input_text' => $objHotelBranchInformation->map_input_text,
),
'hotel_name' => $objHotelBranchInformation->hotel_name,
'PS_STORES_ICON' => $this->context->link->getMediaLink(_PS_IMG_.Configuration::get('PS_STORES_ICON'))
));
$this->addJS(

View File

@@ -423,6 +423,7 @@ class OrderDetailControllerCore extends FrontController
'obj_hotel_branch_information' => $objHotelBranchInformation,
'hotel_address_info' => $hotelAddressInfo,
'hotel_refund_rules' => $hotelRefundRules,
'view_on_map' => Configuration::get('WK_GOOGLE_ACTIVE_MAP'),
)
);
@@ -797,7 +798,9 @@ class OrderDetailControllerCore extends FrontController
if ($idHotel = HotelBookingDetail::getIdHotelByIdOrder(Tools::getValue('id_order'))) {
$objHotelBranchInformation = new HotelBranchInformation($idHotel, $this->context->language->id);
if (Validate::isLoadedObject($objHotelBranchInformation)) {
if ($apiKey = Configuration::get('PS_API_KEY')) {
if (($apiKey = Configuration::get('PS_API_KEY'))
&& Configuration::get('WK_GOOGLE_ACTIVE_MAP')
) {
if (floatval($objHotelBranchInformation->latitude) != 0
&& floatval($objHotelBranchInformation->longitude) != 0
) {
@@ -808,6 +811,7 @@ class OrderDetailControllerCore extends FrontController
'map_input_text' => $objHotelBranchInformation->map_input_text,
),
'hotel_name' => $objHotelBranchInformation->hotel_name,
'PS_STORES_ICON' => $this->context->link->getMediaLink(_PS_IMG_.Configuration::get('PS_STORES_ICON'))
));
$this->addJS(

View File

@@ -426,7 +426,9 @@ class OrderOpcControllerCore extends ParentOrderController
public function initContent()
{
// validate room types before payment by customer
$this->errors = HotelCartBookingData::validateCartBookings();
if ($orderRestrictErr = HotelCartBookingData::validateCartBookings()) {
$this->errors = array_merge($this->errors, $orderRestrictErr);
}
parent::initContent();
@@ -494,7 +496,7 @@ class OrderOpcControllerCore extends ParentOrderController
// $objCurrency = new Currency(Configuration::get('PS_CURRENCY_DEFAULT'));
$this->context->smarty->assign(
array(
'orderRestrictErr' => count($this->errors) ? 1 : 0,
'orderRestrictErr' => count($orderRestrictErr) ? 1 : 0,
// 'allDemands' => $allDemands,
// 'defaultcurrencySign' => $objCurrency->sign,
'THEME_DIR' => _THEME_DIR_,

View File

@@ -78,7 +78,8 @@ class ProductControllerCore extends FrontController
'hotel_location' => array(
'latitude' => $objHotelBranchInformation->latitude,
'longitude' => $objHotelBranchInformation->longitude,
)
),
'PS_STORES_ICON' => $this->context->link->getMediaLink(_PS_IMG_.Configuration::get('PS_STORES_ICON'))
));
$this->addJS(
@@ -109,26 +110,18 @@ class ProductControllerCore extends FrontController
// validate dates if available
$dateFrom = Tools::getValue('date_from');
$dateTo = Tools::getValue('date_to');
$currentTimestamp = strtotime(date('Y-m-d'));
$dateFromTimestamp = strtotime($dateFrom);
$dateToTimestamp = strtotime($dateTo);
if ($dateFrom != '' && ($dateFromTimestamp === false || ($dateFromTimestamp < $currentTimestamp))) {
Tools::redirect($this->context->link->getPageLink('pagenotfound'));
}
if ($dateTo != '' && ($dateToTimestamp === false || ($dateToTimestamp < $currentTimestamp))) {
Tools::redirect($this->context->link->getPageLink('pagenotfound'));
}
parent::init();
if ($id_product = (int) Tools::getValue('id_product')) {
$this->product = new Product($id_product, true, $this->context->language->id, $this->context->shop->id);
}
if (!$this->product->booking_product || ($this->product->booking_product && !$this->product->show_at_front)) {
$objHotelRoomType = new HotelRoomType();
$hotelRoomInfo = $objHotelRoomType->getRoomTypeInfoByIdProduct($this->product->id);
$idHotel = (int) $hotelRoomInfo['id_hotel'];
if (!HotelHelper::validateDateRangeForHotel($dateFrom, $dateTo, $idHotel)) {
Tools::redirect($this->context->link->getPageLink('pagenotfound'));
} else if (!$this->product->booking_product || ($this->product->booking_product && !$this->product->show_at_front)) {
Tools::redirect($this->context->link->getPageLink('pagenotfound'));
}
@@ -341,6 +334,7 @@ class ProductControllerCore extends FrontController
$date_from = Tools::getValue('date_from');
$date_to = Tools::getValue('date_to');
$preparationTime = (int) HotelOrderRestrictDate::getPreparationTime($hotel_id);
if (!($date_from = Tools::getValue('date_from'))) {
$date_from = date('Y-m-d');
// set date to according to los
@@ -355,6 +349,17 @@ class ProductControllerCore extends FrontController
$date_to = date('Y-m-d', strtotime('+'.$los['min_los'].' day', strtotime($date_from)));
}
if ($preparationTime
&& strtotime('+ '.$preparationTime.' day') >= strtotime($date_from)
) {
$date_from = date('Y-m-d', strtotime('+ '.$preparationTime.' day'));
if (strtotime($date_from) >= strtotime($date_to)) {
$objHotelRoomTypeRestrictionDateRange = new HotelRoomTypeRestrictionDateRange();
$los = $objHotelRoomTypeRestrictionDateRange->getRoomTypeLengthOfStay($this->product->id, $date_from);
$date_to = date('Y-m-d', strtotime('+'.$los['min_los'].' day', strtotime($date_from)));
}
}
$hotel_branch_obj = new HotelBranchInformation($hotel_id);
/*Max date of ordering for order restrict*/
$order_date_restrict = false;
@@ -368,9 +373,6 @@ class ProductControllerCore extends FrontController
}
}
/*End*/
// booking preparation time
$preparationTime = (int) HotelOrderRestrictDate::getPreparationTime($hotel_id);
$objHotelImage = new HotelImage();
$hotelImageLink = null;
if ($coverImage = HotelImage::getCover($hotel_id)) {
@@ -413,6 +415,8 @@ class ProductControllerCore extends FrontController
'hotel_address1' => $addressInfo['address1'],
'hotel_phone' => $addressInfo['phone'],
'hotel_name' => $hotel_name,
'hotel_rating' => $hotel_info_by_id['rating'],
'hotel_description' => $hotel_info_by_id['description'],
'hotel_policies' => $hotel_policies,
'hotel_features' => $htl_features,
'hotel_image_link' => $hotelImageLink,

View File

@@ -208,8 +208,12 @@ class StoresControllerCore extends FrontController
*/
protected function assignStores()
{
$this->context->smarty->assign('hasStoreIcon', Tools::file_get_contents($this->context->link->getMediaLink(_PS_IMG_DIR_.Configuration::get('PS_STORES_ICON')))); // by webkul to get media link.
$hasStoreIcon = false;
if (Tools::file_get_contents($this->context->link->getMediaLink(_PS_IMG_.Configuration::get('PS_STORES_ICON')))) { // by webkul to get media link.
$hasStoreIcon = true;
}
$this->context->smarty->assign('hasStoreIcon', $hasStoreIcon);
$distance_unit = Configuration::get('PS_DISTANCE_UNIT');
if (!in_array($distance_unit, array('km', 'mi'))) {
$distance_unit = 'km';

View File

@@ -1 +1,10 @@
Deny from ALL
# Apache 2.2
<IfModule !mod_authz_core.c>
Order deny,allow
Deny from all
</IfModule>
# Apache 2.4
<IfModule mod_authz_core.c>
Require all denied
</IfModule>

View File

@@ -1 +1,10 @@
Allow from ALL
# Apache 2.2
<IfModule !mod_authz_core.c>
Order allow,deny
Allow from ALL
</IfModule>
# Apache 2.4
<IfModule mod_authz_core.c>
Require all granted
</IfModule>

View File

@@ -1,2 +1,10 @@
Order deny,allow
Deny from all
# Apache 2.2
<IfModule !mod_authz_core.c>
Order deny,allow
Deny from all
</IfModule>
# Apache 2.4
<IfModule mod_authz_core.c>
Require all denied
</IfModule>

16
img/.htaccess Normal file
View File

@@ -0,0 +1,16 @@
# Apache 2.2
<IfModule !mod_authz_core.c>
Order deny,allow
Deny from all
<Files ~ "(?i)^.*\.(jpg|jpeg|gif|png|bmp|tiff|svg|pdf|mov|mpeg|mp4|avi|mpg|wma|flv|webm|ico|webp|avif)$">
Allow from all
</Files>
</IfModule>
# Apache 2.4
<IfModule mod_authz_core.c>
Require all denied
<Files ~ "(?i)^.*\.(jpg|jpeg|gif|png|bmp|tiff|svg|pdf|mov|mpeg|mp4|avi|mpg|wma|flv|webm|ico|webp|avif)$">
Require all granted
</Files>
</IfModule>

View File

@@ -1,8 +0,0 @@
<IfModule mod_php5.c>
php_flag engine off
</IfModule>
deny from all
<Files ~ "(?i)^.*\.(jpg|jpeg|gif|png|bmp|tiff|svg|pdf|mov|mpeg|mp4|avi|mpg|wma|flv|webm)$">
order deny,allow
allow from all
</Files>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 123 KiB

After

Width:  |  Height:  |  Size: 175 KiB

View File

@@ -1,102 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<entity_access>
<fields primary="id_profile, id_tab" sql="a.id_profile = 1">
<field name="id_profile" relation="profile"/>
<field name="id_tab" relation="tab"/>
<field name="view"/>
<field name="add"/>
<field name="edit"/>
<field name="delete"/>
</fields>
<entities>
<access id="access_1_0" id_profile="SuperAdmin" id_tab="" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_1" id_profile="SuperAdmin" id_tab="Home" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_2" id_profile="SuperAdmin" id_tab="CMS_pages" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_3" id_profile="SuperAdmin" id_tab="CMS_categories" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_4" id_profile="SuperAdmin" id_tab="Combinations_generator" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_5" id_profile="SuperAdmin" id_tab="Search" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_7" id_profile="SuperAdmin" id_tab="Shops" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_8" id_profile="SuperAdmin" id_tab="Shop_Urls" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_9" id_profile="SuperAdmin" id_tab="Catalog" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_10" id_profile="SuperAdmin" id_tab="Orders" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_11" id_profile="SuperAdmin" id_tab="Customers" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_13" id_profile="SuperAdmin" id_tab="Shipping" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_14" id_profile="SuperAdmin" id_tab="Localization" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_15" id_profile="SuperAdmin" id_tab="Modules" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_16" id_profile="SuperAdmin" id_tab="Preferences" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_19" id_profile="SuperAdmin" id_tab="Stats" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_20" id_profile="SuperAdmin" id_tab="Stock" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_21" id_profile="SuperAdmin" id_tab="Products" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_22" id_profile="SuperAdmin" id_tab="Categories" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_23" id_profile="SuperAdmin" id_tab="Monitoring" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_24" id_profile="SuperAdmin" id_tab="Attributes_and_Values" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_25" id_profile="SuperAdmin" id_tab="Features" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_26" id_profile="SuperAdmin" id_tab="Manufacturers" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_27" id_profile="SuperAdmin" id_tab="Suppliers" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_29" id_profile="SuperAdmin" id_tab="Tags" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_30" id_profile="SuperAdmin" id_tab="Attachments" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_32" id_profile="SuperAdmin" id_tab="Invoices" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_33" id_profile="SuperAdmin" id_tab="Merchandise_Returns" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_34" id_profile="SuperAdmin" id_tab="Delivery_Slips" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_35" id_profile="SuperAdmin" id_tab="Credit_Slips" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_36" id_profile="SuperAdmin" id_tab="Statuses" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_37" id_profile="SuperAdmin" id_tab="Order_Messages" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_39" id_profile="SuperAdmin" id_tab="Addresses" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_40" id_profile="SuperAdmin" id_tab="Groups" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_41" id_profile="SuperAdmin" id_tab="Shopping_Carts" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_42" id_profile="SuperAdmin" id_tab="Customer_Service" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_43" id_profile="SuperAdmin" id_tab="Contacts" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_44" id_profile="SuperAdmin" id_tab="Genders" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_45" id_profile="SuperAdmin" id_tab="Outstanding" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_46" id_profile="SuperAdmin" id_tab="Cart_Rules" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_47" id_profile="SuperAdmin" id_tab="Catalog_price_rules" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_49" id_profile="SuperAdmin" id_tab="CarrierWizard" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_49" id_profile="SuperAdmin" id_tab="Carriers" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_50" id_profile="SuperAdmin" id_tab="Price_Ranges" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_51" id_profile="SuperAdmin" id_tab="Weight_Ranges" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_53" id_profile="SuperAdmin" id_tab="Languages" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_54" id_profile="SuperAdmin" id_tab="Zones" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_55" id_profile="SuperAdmin" id_tab="Countries" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_56" id_profile="SuperAdmin" id_tab="States" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_57" id_profile="SuperAdmin" id_tab="Currencies" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_58" id_profile="SuperAdmin" id_tab="Tax_Rules" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_59" id_profile="SuperAdmin" id_tab="Taxes" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_60" id_profile="SuperAdmin" id_tab="Translations" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_62" id_profile="SuperAdmin" id_tab="Modules_Themes_Catalog" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_63" id_profile="SuperAdmin" id_tab="Positions" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_64" id_profile="SuperAdmin" id_tab="Payment" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_67" id_profile="SuperAdmin" id_tab="Products_1" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_68" id_profile="SuperAdmin" id_tab="Customers_2" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_69" id_profile="SuperAdmin" id_tab="Themes" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_70" id_profile="SuperAdmin" id_tab="SEO_URLs" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_71" id_profile="SuperAdmin" id_tab="CMS" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_72" id_profile="SuperAdmin" id_tab="Images" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_73" id_profile="SuperAdmin" id_tab="Contact_stores" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_74" id_profile="SuperAdmin" id_tab="Search_1" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_75" id_profile="SuperAdmin" id_tab="Maintenance" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_76" id_profile="SuperAdmin" id_tab="Geolocation" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_77" id_profile="SuperAdmin" id_tab="Configuration_Information" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_78" id_profile="SuperAdmin" id_tab="Performance" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_79" id_profile="SuperAdmin" id_tab="E-mail" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_81" id_profile="SuperAdmin" id_tab="CSV_Import" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_82" id_profile="SuperAdmin" id_tab="DB_Backup" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_83" id_profile="SuperAdmin" id_tab="SQL_Manager" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_84" id_profile="SuperAdmin" id_tab="Logs" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_85" id_profile="SuperAdmin" id_tab="Webservice" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_87" id_profile="SuperAdmin" id_tab="Quick_Access" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_88" id_profile="SuperAdmin" id_tab="Employees" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_89" id_profile="SuperAdmin" id_tab="Profiles" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_90" id_profile="SuperAdmin" id_tab="Permissions" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_91" id_profile="SuperAdmin" id_tab="Tabs" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_93" id_profile="SuperAdmin" id_tab="Search_Engines" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_94" id_profile="SuperAdmin" id_tab="Referrers" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_95" id_profile="SuperAdmin" id_tab="Warehouses" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_96" id_profile="SuperAdmin" id_tab="Stock_Management" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_97" id_profile="SuperAdmin" id_tab="Stock_Movement" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_98" id_profile="SuperAdmin" id_tab="Stock_instant_state" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_99" id_profile="SuperAdmin" id_tab="Stock_cover" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_100" id_profile="SuperAdmin" id_tab="Supply_orders" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_101" id_profile="SuperAdmin" id_tab="Configuration" view="1" add="1" edit="1" delete="1"/>
<access id="access_1_102" id_profile="SuperAdmin" id_tab="Dashboard" view="1" add="1" edit="1" delete="1"/>
</entities>
</entity_access>

View File

@@ -1,319 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<entity_access>
<fields primary="id_profile, id_tab" sql="a.id_profile &gt; 1">
<field name="id_profile" relation="profile"/>
<field name="id_tab" relation="tab"/>
<field name="view"/>
<field name="add"/>
<field name="edit"/>
<field name="delete"/>
</fields>
<entities>
<access id="access_3_1" id_profile="Logistician" id_tab="Home" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_2" id_profile="Logistician" id_tab="CMS_pages" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_3" id_profile="Logistician" id_tab="CMS_categories" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_4" id_profile="Logistician" id_tab="Combinations_generator" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_5" id_profile="Logistician" id_tab="Search" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_6" id_profile="Logistician" id_tab="Login" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_7" id_profile="Logistician" id_tab="Shops" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_8" id_profile="Logistician" id_tab="Shop_Urls" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_9" id_profile="Logistician" id_tab="Catalog" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_10" id_profile="Logistician" id_tab="Orders" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_11" id_profile="Logistician" id_tab="Customers" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_12" id_profile="Logistician" id_tab="Price_rules" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_13" id_profile="Logistician" id_tab="Shipping" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_14" id_profile="Logistician" id_tab="Localization" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_15" id_profile="Logistician" id_tab="Modules" view="1" add="0" edit="1" delete="0"/>
<access id="access_3_16" id_profile="Logistician" id_tab="Preferences" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_17" id_profile="Logistician" id_tab="Advanced_parameters" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_18" id_profile="Logistician" id_tab="Administration" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_19" id_profile="Logistician" id_tab="Stats" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_20" id_profile="Logistician" id_tab="Stock" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_21" id_profile="Logistician" id_tab="Products" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_22" id_profile="Logistician" id_tab="Categories" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_23" id_profile="Logistician" id_tab="Monitoring" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_24" id_profile="Logistician" id_tab="Attributes_and_Values" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_25" id_profile="Logistician" id_tab="Features" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_26" id_profile="Logistician" id_tab="Manufacturers" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_27" id_profile="Logistician" id_tab="Suppliers" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_29" id_profile="Logistician" id_tab="Tags" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_30" id_profile="Logistician" id_tab="Attachments" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_31" id_profile="Logistician" id_tab="Orders_1" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_32" id_profile="Logistician" id_tab="Invoices" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_33" id_profile="Logistician" id_tab="Merchandise_Returns" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_34" id_profile="Logistician" id_tab="Delivery_Slips" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_35" id_profile="Logistician" id_tab="Credit_Slips" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_36" id_profile="Logistician" id_tab="Statuses" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_37" id_profile="Logistician" id_tab="Order_Messages" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_38" id_profile="Logistician" id_tab="Customers_1" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_39" id_profile="Logistician" id_tab="Addresses" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_40" id_profile="Logistician" id_tab="Groups" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_41" id_profile="Logistician" id_tab="Shopping_Carts" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_42" id_profile="Logistician" id_tab="Customer_Service" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_43" id_profile="Logistician" id_tab="Contacts" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_44" id_profile="Logistician" id_tab="Genders" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_45" id_profile="Logistician" id_tab="Outstanding" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_46" id_profile="Logistician" id_tab="Cart_Rules" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_47" id_profile="Logistician" id_tab="Catalog_price_rules" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_48" id_profile="Logistician" id_tab="Shipping_1" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_49" id_profile="Logistician" id_tab="Carriers" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_50" id_profile="Logistician" id_tab="Price_Ranges" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_51" id_profile="Logistician" id_tab="Weight_Ranges" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_52" id_profile="Logistician" id_tab="Localization_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_53" id_profile="Logistician" id_tab="Languages" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_54" id_profile="Logistician" id_tab="Zones" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_55" id_profile="Logistician" id_tab="Countries" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_56" id_profile="Logistician" id_tab="States" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_57" id_profile="Logistician" id_tab="Currencies" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_58" id_profile="Logistician" id_tab="Tax_Rules" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_59" id_profile="Logistician" id_tab="Taxes" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_60" id_profile="Logistician" id_tab="Translations" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_61" id_profile="Logistician" id_tab="Modules_1" view="1" add="0" edit="1" delete="0"/>
<access id="access_3_62" id_profile="Logistician" id_tab="Modules_Catalog" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_62" id_profile="Logistician" id_tab="Modules_Themes_Catalog" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_63" id_profile="Logistician" id_tab="Positions" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_64" id_profile="Logistician" id_tab="Payment" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_65" id_profile="Logistician" id_tab="General" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_66" id_profile="Logistician" id_tab="Orders_2" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_67" id_profile="Logistician" id_tab="Products_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_68" id_profile="Logistician" id_tab="Customers_2" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_69" id_profile="Logistician" id_tab="Themes" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_70" id_profile="Logistician" id_tab="SEO_URLs" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_71" id_profile="Logistician" id_tab="CMS" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_72" id_profile="Logistician" id_tab="Images" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_73" id_profile="Logistician" id_tab="Contact_stores" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_74" id_profile="Logistician" id_tab="Search_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_75" id_profile="Logistician" id_tab="Maintenance" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_76" id_profile="Logistician" id_tab="Geolocation" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_77" id_profile="Logistician" id_tab="Configuration_Information" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_78" id_profile="Logistician" id_tab="Performance" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_79" id_profile="Logistician" id_tab="E-mail" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_80" id_profile="Logistician" id_tab="Multi-shop" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_81" id_profile="Logistician" id_tab="CSV_Import" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_82" id_profile="Logistician" id_tab="DB_Backup" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_83" id_profile="Logistician" id_tab="SQL_Manager" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_84" id_profile="Logistician" id_tab="Logs" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_85" id_profile="Logistician" id_tab="Webservice" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_86" id_profile="Logistician" id_tab="Preferences_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_87" id_profile="Logistician" id_tab="Quick_Access" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_88" id_profile="Logistician" id_tab="Employees" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_89" id_profile="Logistician" id_tab="Profiles" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_90" id_profile="Logistician" id_tab="Permissions" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_91" id_profile="Logistician" id_tab="Tabs" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_92" id_profile="Logistician" id_tab="Stats_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_93" id_profile="Logistician" id_tab="Search_Engines" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_94" id_profile="Logistician" id_tab="Referrers" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_95" id_profile="Logistician" id_tab="Warehouses" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_96" id_profile="Logistician" id_tab="Stock_Management" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_97" id_profile="Logistician" id_tab="Stock_Movement" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_98" id_profile="Logistician" id_tab="Stock_instant_state" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_99" id_profile="Logistician" id_tab="Stock_cover" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_100" id_profile="Logistician" id_tab="Supply_orders" view="1" add="1" edit="1" delete="1"/>
<access id="access_3_101" id_profile="Logistician" id_tab="Configuration" view="1" add="1" edit="1" delete="1"/>
<access id="access_4_1" id_profile="Translator" id_tab="Home" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_2" id_profile="Translator" id_tab="CMS_pages" view="1" add="1" edit="1" delete="1"/>
<access id="access_4_3" id_profile="Translator" id_tab="CMS_categories" view="1" add="1" edit="1" delete="1"/>
<access id="access_4_4" id_profile="Translator" id_tab="Combinations_generator" view="1" add="1" edit="1" delete="1"/>
<access id="access_4_5" id_profile="Translator" id_tab="Search" view="1" add="0" edit="0" delete="0"/>
<access id="access_4_6" id_profile="Translator" id_tab="Login" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_7" id_profile="Translator" id_tab="Shops" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_8" id_profile="Translator" id_tab="Shop_Urls" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_9" id_profile="Translator" id_tab="Catalog" view="1" add="1" edit="1" delete="1"/>
<access id="access_4_10" id_profile="Translator" id_tab="Orders" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_11" id_profile="Translator" id_tab="Customers" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_12" id_profile="Translator" id_tab="Price_rules" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_13" id_profile="Translator" id_tab="Shipping" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_14" id_profile="Translator" id_tab="Localization" view="1" add="0" edit="0" delete="0"/>
<access id="access_4_15" id_profile="Translator" id_tab="Modules" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_16" id_profile="Translator" id_tab="Preferences" view="1" add="0" edit="0" delete="0"/>
<access id="access_4_17" id_profile="Translator" id_tab="Advanced_parameters" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_18" id_profile="Translator" id_tab="Administration" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_19" id_profile="Translator" id_tab="Stats" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_20" id_profile="Translator" id_tab="Stock" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_21" id_profile="Translator" id_tab="Products" view="1" add="1" edit="1" delete="1"/>
<access id="access_4_22" id_profile="Translator" id_tab="Categories" view="1" add="1" edit="1" delete="1"/>
<access id="access_4_23" id_profile="Translator" id_tab="Monitoring" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_24" id_profile="Translator" id_tab="Attributes_and_Values" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_25" id_profile="Translator" id_tab="Features" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_26" id_profile="Translator" id_tab="Manufacturers" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_27" id_profile="Translator" id_tab="Suppliers" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_29" id_profile="Translator" id_tab="Tags" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_30" id_profile="Translator" id_tab="Attachments" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_31" id_profile="Translator" id_tab="Orders_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_32" id_profile="Translator" id_tab="Invoices" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_33" id_profile="Translator" id_tab="Merchandise_Returns" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_34" id_profile="Translator" id_tab="Delivery_Slips" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_35" id_profile="Translator" id_tab="Credit_Slips" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_36" id_profile="Translator" id_tab="Statuses" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_37" id_profile="Translator" id_tab="Order_Messages" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_38" id_profile="Translator" id_tab="Customers_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_39" id_profile="Translator" id_tab="Addresses" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_40" id_profile="Translator" id_tab="Groups" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_41" id_profile="Translator" id_tab="Shopping_Carts" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_42" id_profile="Translator" id_tab="Customer_Service" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_43" id_profile="Translator" id_tab="Contacts" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_44" id_profile="Translator" id_tab="Genders" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_45" id_profile="Translator" id_tab="Outstanding" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_46" id_profile="Translator" id_tab="Cart_Rules" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_47" id_profile="Translator" id_tab="Catalog_price_rules" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_48" id_profile="Translator" id_tab="Shipping_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_49" id_profile="Translator" id_tab="Carriers" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_50" id_profile="Translator" id_tab="Price_Ranges" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_51" id_profile="Translator" id_tab="Weight_Ranges" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_52" id_profile="Translator" id_tab="Localization_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_53" id_profile="Translator" id_tab="Languages" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_54" id_profile="Translator" id_tab="Zones" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_55" id_profile="Translator" id_tab="Countries" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_56" id_profile="Translator" id_tab="States" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_57" id_profile="Translator" id_tab="Currencies" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_58" id_profile="Translator" id_tab="Tax_Rules" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_59" id_profile="Translator" id_tab="Taxes" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_60" id_profile="Translator" id_tab="Translations" view="1" add="1" edit="1" delete="1"/>
<access id="access_4_61" id_profile="Translator" id_tab="Modules_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_62" id_profile="Translator" id_tab="Modules_Catalog" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_62" id_profile="Translator" id_tab="Modules_Themes_Catalog" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_63" id_profile="Translator" id_tab="Positions" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_64" id_profile="Translator" id_tab="Payment" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_65" id_profile="Translator" id_tab="General" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_66" id_profile="Translator" id_tab="Orders_2" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_67" id_profile="Translator" id_tab="Products_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_68" id_profile="Translator" id_tab="Customers_2" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_69" id_profile="Translator" id_tab="Themes" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_70" id_profile="Translator" id_tab="SEO_URLs" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_71" id_profile="Translator" id_tab="CMS" view="1" add="1" edit="1" delete="1"/>
<access id="access_4_72" id_profile="Translator" id_tab="Images" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_73" id_profile="Translator" id_tab="Contact_stores" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_74" id_profile="Translator" id_tab="Search_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_75" id_profile="Translator" id_tab="Maintenance" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_76" id_profile="Translator" id_tab="Geolocation" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_77" id_profile="Translator" id_tab="Configuration_Information" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_78" id_profile="Translator" id_tab="Performance" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_79" id_profile="Translator" id_tab="E-mail" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_80" id_profile="Translator" id_tab="Multi-shop" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_81" id_profile="Translator" id_tab="CSV_Import" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_82" id_profile="Translator" id_tab="DB_Backup" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_83" id_profile="Translator" id_tab="SQL_Manager" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_84" id_profile="Translator" id_tab="Logs" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_85" id_profile="Translator" id_tab="Webservice" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_86" id_profile="Translator" id_tab="Preferences_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_87" id_profile="Translator" id_tab="Quick_Access" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_88" id_profile="Translator" id_tab="Employees" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_89" id_profile="Translator" id_tab="Profiles" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_90" id_profile="Translator" id_tab="Permissions" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_91" id_profile="Translator" id_tab="Tabs" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_92" id_profile="Translator" id_tab="Stats_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_93" id_profile="Translator" id_tab="Search_Engines" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_94" id_profile="Translator" id_tab="Referrers" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_95" id_profile="Translator" id_tab="Warehouses" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_96" id_profile="Translator" id_tab="Stock_Management" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_97" id_profile="Translator" id_tab="Stock_Movement" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_98" id_profile="Translator" id_tab="Stock_instant_state" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_99" id_profile="Translator" id_tab="Stock_cover" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_100" id_profile="Translator" id_tab="Supply_orders" view="0" add="0" edit="0" delete="0"/>
<access id="access_4_101" id_profile="Translator" id_tab="Configuration" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_1" id_profile="Salesman" id_tab="Home" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_2" id_profile="Salesman" id_tab="CMS_pages" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_3" id_profile="Salesman" id_tab="CMS_categories" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_4" id_profile="Salesman" id_tab="Combinations_generator" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_5" id_profile="Salesman" id_tab="Search" view="1" add="0" edit="0" delete="0"/>
<access id="access_5_6" id_profile="Salesman" id_tab="Login" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_7" id_profile="Salesman" id_tab="Shops" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_8" id_profile="Salesman" id_tab="Shop_Urls" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_9" id_profile="Salesman" id_tab="Catalog" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_10" id_profile="Salesman" id_tab="Orders" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_11" id_profile="Salesman" id_tab="Customers" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_12" id_profile="Salesman" id_tab="Price_rules" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_13" id_profile="Salesman" id_tab="Shipping" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_14" id_profile="Salesman" id_tab="Localization" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_15" id_profile="Salesman" id_tab="Modules" view="1" add="0" edit="1" delete="0"/>
<access id="access_5_16" id_profile="Salesman" id_tab="Preferences" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_17" id_profile="Salesman" id_tab="Advanced_parameters" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_18" id_profile="Salesman" id_tab="Administration" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_19" id_profile="Salesman" id_tab="Stats" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_20" id_profile="Salesman" id_tab="Stock" view="1" add="0" edit="0" delete="0"/>
<access id="access_5_21" id_profile="Salesman" id_tab="Products" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_22" id_profile="Salesman" id_tab="Categories" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_23" id_profile="Salesman" id_tab="Monitoring" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_24" id_profile="Salesman" id_tab="Attributes_and_Values" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_25" id_profile="Salesman" id_tab="Features" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_26" id_profile="Salesman" id_tab="Manufacturers" view="1" add="0" edit="0" delete="0"/>
<access id="access_5_27" id_profile="Salesman" id_tab="Suppliers" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_29" id_profile="Salesman" id_tab="Tags" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_30" id_profile="Salesman" id_tab="Attachments" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_31" id_profile="Salesman" id_tab="Orders_1" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_32" id_profile="Salesman" id_tab="Invoices" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_33" id_profile="Salesman" id_tab="Merchandise_Returns" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_34" id_profile="Salesman" id_tab="Delivery_Slips" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_35" id_profile="Salesman" id_tab="Credit_Slips" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_36" id_profile="Salesman" id_tab="Statuses" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_37" id_profile="Salesman" id_tab="Order_Messages" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_38" id_profile="Salesman" id_tab="Customers_1" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_39" id_profile="Salesman" id_tab="Addresses" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_40" id_profile="Salesman" id_tab="Groups" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_41" id_profile="Salesman" id_tab="Shopping_Carts" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_42" id_profile="Salesman" id_tab="Customer_Service" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_43" id_profile="Salesman" id_tab="Contacts" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_44" id_profile="Salesman" id_tab="Genders" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_45" id_profile="Salesman" id_tab="Outstanding" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_46" id_profile="Salesman" id_tab="Cart_Rules" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_47" id_profile="Salesman" id_tab="Catalog_price_rules" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_48" id_profile="Salesman" id_tab="Shipping_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_49" id_profile="Salesman" id_tab="Carriers" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_50" id_profile="Salesman" id_tab="Price_Ranges" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_51" id_profile="Salesman" id_tab="Weight_Ranges" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_52" id_profile="Salesman" id_tab="Localization_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_53" id_profile="Salesman" id_tab="Languages" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_54" id_profile="Salesman" id_tab="Zones" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_55" id_profile="Salesman" id_tab="Countries" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_56" id_profile="Salesman" id_tab="States" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_57" id_profile="Salesman" id_tab="Currencies" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_58" id_profile="Salesman" id_tab="Tax_Rules" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_59" id_profile="Salesman" id_tab="Taxes" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_60" id_profile="Salesman" id_tab="Translations" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_61" id_profile="Salesman" id_tab="Modules_1" view="1" add="0" edit="1" delete="0"/>
<access id="access_5_62" id_profile="Salesman" id_tab="Modules_Catalog" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_62" id_profile="Salesman" id_tab="Modules_Themes_Catalog" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_63" id_profile="Salesman" id_tab="Positions" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_64" id_profile="Salesman" id_tab="Payment" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_65" id_profile="Salesman" id_tab="General" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_66" id_profile="Salesman" id_tab="Orders_2" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_67" id_profile="Salesman" id_tab="Products_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_68" id_profile="Salesman" id_tab="Customers_2" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_69" id_profile="Salesman" id_tab="Themes" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_70" id_profile="Salesman" id_tab="SEO_URLs" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_71" id_profile="Salesman" id_tab="CMS" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_72" id_profile="Salesman" id_tab="Images" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_73" id_profile="Salesman" id_tab="Contact_stores" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_74" id_profile="Salesman" id_tab="Search_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_75" id_profile="Salesman" id_tab="Maintenance" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_76" id_profile="Salesman" id_tab="Geolocation" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_77" id_profile="Salesman" id_tab="Configuration_Information" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_78" id_profile="Salesman" id_tab="Performance" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_79" id_profile="Salesman" id_tab="E-mail" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_80" id_profile="Salesman" id_tab="Multi-shop" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_81" id_profile="Salesman" id_tab="CSV_Import" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_82" id_profile="Salesman" id_tab="DB_Backup" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_83" id_profile="Salesman" id_tab="SQL_Manager" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_84" id_profile="Salesman" id_tab="Logs" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_85" id_profile="Salesman" id_tab="Webservice" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_86" id_profile="Salesman" id_tab="Preferences_1" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_87" id_profile="Salesman" id_tab="Quick_Access" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_88" id_profile="Salesman" id_tab="Employees" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_89" id_profile="Salesman" id_tab="Profiles" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_90" id_profile="Salesman" id_tab="Permissions" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_91" id_profile="Salesman" id_tab="Tabs" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_92" id_profile="Salesman" id_tab="Stats_1" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_93" id_profile="Salesman" id_tab="Search_Engines" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_94" id_profile="Salesman" id_tab="Referrers" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_95" id_profile="Salesman" id_tab="Warehouses" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_96" id_profile="Salesman" id_tab="Stock_Management" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_97" id_profile="Salesman" id_tab="Stock_Movement" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_98" id_profile="Salesman" id_tab="Stock_instant_state" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_99" id_profile="Salesman" id_tab="Stock_cover" view="0" add="0" edit="0" delete="0"/>
<access id="access_5_100" id_profile="Salesman" id_tab="Supply_orders" view="1" add="0" edit="0" delete="0"/>
<access id="access_5_101" id_profile="Salesman" id_tab="Configuration" view="0" add="0" edit="0" delete="0"/>
<access id="access_3_0" id_profile="Logistician" id_tab="" view="1" add="1" edit="1" delete="1"/>
<access id="access_4_0" id_profile="Translator" id_tab="" view="1" add="1" edit="1" delete="1"/>
<access id="access_5_0" id_profile="Salesman" id_tab="" view="1" add="1" edit="1" delete="1"/>
</entities>
</entity_access>

View File

@@ -1,9 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<entity_profile>
<fields id="name" class="Profile" sql="a.id_profile &gt; 1"/>
<entities>
<profile id="Logistician"/>
<profile id="Translator"/>
<profile id="Salesman"/>
</entities>
</entity_profile>

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,12 +0,0 @@
<?xml version="1.0"?>
<entity_profile>
<profile id="Logistician">
<name>Logistician</name>
</profile>
<profile id="Translator">
<name>Translator</name>
</profile>
<profile id="Salesman">
<name>Salesman</name>
</profile>
</entity_profile>

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,12 +0,0 @@
<?xml version='1.0'?>
<entity_profile>
<profile id='Logistician'>
<name>Especialista em logística</name>
</profile>
<profile id='Translator'>
<name>Tradutor</name>
</profile>
<profile id='Salesman'>
<name>Vendedor</name>
</profile>
</entity_profile>

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,12 +0,0 @@
<?xml version="1.0"?>
<entity_profile>
<profile id="Logistician">
<name>Logistician</name>
</profile>
<profile id="Translator">
<name>Translator</name>
</profile>
<profile id="Salesman">
<name>Salesman</name>
</profile>
</entity_profile>

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,12 +0,0 @@
<?xml version="1.0"?>
<entity_profile>
<profile id="Logistician">
<name>Logistician</name>
</profile>
<profile id="Translator">
<name>Translator</name>
</profile>
<profile id="Salesman">
<name>Salesman</name>
</profile>
</entity_profile>

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,12 +0,0 @@
<?xml version='1.0'?>
<entity_profile>
<profile id='Logistician'>
<name>Especialista en logística</name>
</profile>
<profile id='Translator'>
<name>Traductor</name>
</profile>
<profile id='Salesman'>
<name>Vendedor</name>
</profile>
</entity_profile>

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,12 +0,0 @@
<?xml version="1.0"?>
<entity_profile>
<profile id="Logistician">
<name>پشتیبان</name>
</profile>
<profile id="Translator">
<name>مترجم</name>
</profile>
<profile id="Salesman">
<name>مسئول فروش</name>
</profile>
</entity_profile>

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,12 +0,0 @@
<?xml version='1.0'?>
<entity_profile>
<profile id='Logistician'>
<name>Logisticien</name>
</profile>
<profile id='Translator'>
<name>Traducteur</name>
</profile>
<profile id='Salesman'>
<name>Commercial</name>
</profile>
</entity_profile>

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,12 +0,0 @@
<?xml version="1.0"?>
<entity_profile>
<profile id="Logistician">
<name>Logistician</name>
</profile>
<profile id="Translator">
<name>Translator</name>
</profile>
<profile id="Salesman">
<name>Salesman</name>
</profile>
</entity_profile>

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,12 +0,0 @@
<?xml version='1.0'?>
<entity_profile>
<profile id='Logistician'>
<name>Responsabile logistica</name>
</profile>
<profile id='Translator'>
<name>Traduttore</name>
</profile>
<profile id='Salesman'>
<name>Commesso</name>
</profile>
</entity_profile>

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

View File

@@ -1,35 +0,0 @@
<?php
/*
* 2007-2015 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-2015 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;

Some files were not shown because too many files have changed in this diff Show More