Merge branch 'develop' into gli-1798

This commit is contained in:
Shreesh Arora
2024-07-02 16:55:28 +05:30
130 changed files with 9762 additions and 8840 deletions

View File

@@ -46,7 +46,6 @@
<span class="input-group-addon">%</span>
<input type="text" id="reduction_percent" class="input-mini" name="reduction_percent" value="{$currentTab->getFieldValue($currentObject, 'reduction_percent')|floatval}" />
</div>
<span class="help-block"><i class="icon-warning-sign"></i> {l s='Does not apply to the shipping costs'}</span>
</div>
</div>

View File

@@ -47,7 +47,7 @@
<div class="form-group">
<label class="control-label col-lg-3">
<span class="label-tooltip" data-toggle="tooltip"
title="{l s='You can choose a minimum amount for the cart either with or without the taxes and shipping.'}">
title="{l s='You can choose a minimum amount for the cart either with or without the taxes.'}">
{l s='Minimum amount'}
</span>
</label>
@@ -125,7 +125,6 @@
{l s='Country selection'}
</label>
</p>
<span class="help-block">{l s='This restriction applies to the country of delivery.'}</span>
<div id="country_restriction_div">
<br />
<table class="table">

View File

@@ -35,15 +35,9 @@
<h3><i class="icon-user"></i> {l s='Customer information'}</h3>
{if $customer->id}
<a class="btn btn-default pull-right" href="mailto:{$customer->email}"><i class="icon-envelope"></i> {$customer->email}</a>
<h2>
{if $customer->id_gender == 1}
<i class="icon-male"></i>
{elseif $customer->id_gender == 2}
<i class="icon-female"></i>
{else}
<i class="icon-question"></i>
{/if}
<a href="{$link->getAdminLink('AdminCustomers')|escape:'html':'UTF-8'}&amp;id_customer={$customer->id|intval}&amp;viewcustomer">{$customer->firstname} {$customer->lastname}</a></h2>
<h4 style="padding-top:10px">
{l s='Customer Name'}:
<a href="{$link->getAdminLink('AdminCustomers')|escape:'html':'UTF-8'}&amp;id_customer={$customer->id|intval}&amp;viewcustomer">{$customer->firstname} {$customer->lastname}</a></h4>
<div class="form-horizontal">
<div class="form-group">
<label class="col-lg-3 control-label">{l s='Account registration date:'}</label>

View File

@@ -152,7 +152,7 @@
{l s='All'} <span class="badge pull-right">{$nb_modules}</span>
</a>
{foreach from=$list_modules_categories item=module_category key=module_category_key}
<a class="categoryModuleFilterLink list-group-item {if isset($categoryFiltered[$module_category_key])}active{/if}" href="{$currentIndex|escape:'html':'UTF-8'}&amp;token={$token|escape:'html':'UTF-8'}&amp;{if isset($categoryFiltered[$module_category_key])}un{/if}filterCategory={$module_category_key}" id="filter_{$module_category_key}">
<a class="categoryModuleFilterLink list-group-item {if isset($categoryFiltered[$module_category_key])}active{/if}" href="{$currentIndex|escape:'html':'UTF-8'}&amp;token={$token|escape:'html':'UTF-8'}&amp;filterCategory={$module_category_key}" id="filter_{$module_category_key}">
{$module_category.name} <span class="badge pull-right">{$module_category.nb}</span>
</a>
{/foreach}

View File

@@ -193,18 +193,22 @@
</div>
{/if}
</td>
{if (isset($refundReqBookings) && $refundReqBookings) || (isset($isCancelledRoom) && $isCancelledRoom)}
{if (isset($refundReqBookings) && $refundReqBookings)}
<td>
{if $data.is_cancelled}
<span class="badge badge-danger">{l s='Cancelled'}</span>
{elseif isset($data.refund_info) && $data.refund_info}
<span class="badge" style="background-color:{$data.refund_info.color|escape:'html':'UTF-8'}">{$data.refund_info.name|escape:'html':'UTF-8'}</span>
{if $data.id|in_array:$refundReqBookings}
{if $data.is_cancelled}
<span class="badge badge-danger">{l s='Cancelled'}</span>
{elseif isset($data.refund_info) && (!$data.refund_info.refunded || $data.refund_info.id_customization)}
<span class="badge" style="background-color:{$data.refund_info.color|escape:'html':'UTF-8'}">{$data.refund_info.name|escape:'html':'UTF-8'}</span>
{else}
<span>--</span>
{/if}
{else}
<span>--</span>
{/if}
<span>--</span>
{/if}
</td>
<td>
{if isset($data.refund_info) && $data.refund_info}
{if $data.is_refunded && isset($data.refund_info) && $data.refund_info}
{convertPriceWithCurrency price=$data.refund_info.refunded_amount currency=$currency->id}
{else}
--
@@ -242,7 +246,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-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}'>
<i class="icon-refresh"></i>
{l s='Reallocate/Swap Room'}
</a>

View File

@@ -33,7 +33,7 @@
<th><span class="title_box">{l s='Extra Services/Fee (Tax excl.)'}</span></th>
<th><span class="title_box">{l s='Total Tax'}</span></th>
<th><span class="title_box">{l s='Total Price (Tax incl.)'}</span></th>
{if (isset($refundReqBookings) && $refundReqBookings) || (isset($isCancelledRoom) && $isCancelledRoom)}
{if (isset($refundReqBookings) && $refundReqBookings)}
<th><span class="title_box">{l s='Refund/Cancel Status'}</span></th>
<th><span class="title_box">{l s='Refunded amount'}</span></th>
{/if}

View File

@@ -41,6 +41,7 @@
{block name="override_tpl"}
<script type="text/javascript">
var admin_order_tab_link = "{$link->getAdminLink('AdminOrders')|addslashes}";
var rooms_reallocation_url = "{$link->getAdminLink('AdminOrders')|addslashes}";
var id_order = {$order->id};
var id_lang = {$current_id_lang};
var id_currency = {$order->id_currency};
@@ -102,7 +103,7 @@
<th>{l s='Duration'}</th>
<th>{l s='Documents'}</th>
<th>{l s='Room Status'}</th>
<th>{l s='Action'}</th>
<th class="text-center">{l s='Action'}</th>
</tr>
</thead>
<tbody>
@@ -133,7 +134,7 @@
{/if}
</td>
<td class="text-center">
{if $data.is_refunded || $data.is_cancelled}
{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']}">
@@ -246,7 +247,7 @@
<div class="col-lg-9">
<select id="id_order_state" class="chosen form-control" name="id_order_state">
{foreach from=$states item=state}
<option value="{$state['id_order_state']|intval}"{if isset($currentState) && $state['id_order_state'] == $currentState->id} selected="selected" disabled="disabled"{elseif ($state['id_order_state'] == Configuration::get('PS_OS_REFUND') && !$allBookingsRefunded)} disabled="disabled"{elseif ($state['id_order_state'] == Configuration::get('PS_OS_CANCELED') && !$allBookingsCancelled)} disabled="disabled"{elseif ($state['id_order_state'] == Configuration::get('PS_OS_OVERBOOKING_PAID') || $state['id_order_state'] == Configuration::get('PS_OS_OVERBOOKING_UNPAID') || $state['id_order_state'] == Configuration::get('PS_OS_OVERBOOKING_PARTIAL_PAID')) && (!isset($orderOverBookings) || !$orderOverBookings)} disabled="disabled"{/if}>{$state['name']|escape}</option>
<option value="{$state['id_order_state']|intval}"{if isset($currentState) && $state['id_order_state'] == $currentState->id} selected="selected" disabled="disabled"{elseif ($state['id_order_state'] == Configuration::get('PS_OS_REFUND') && ($total_paid <= 0 && !$discounts|count))} disabled="disabled"{elseif ($state['id_order_state'] == Configuration::get('PS_OS_CANCELED') && ($totalRefundedRooms || $discounts|count || $total_paid > 0))} disabled="disabled"{elseif ($state['id_order_state'] == Configuration::get('PS_OS_OVERBOOKING_PAID') || $state['id_order_state'] == Configuration::get('PS_OS_OVERBOOKING_UNPAID') || $state['id_order_state'] == Configuration::get('PS_OS_OVERBOOKING_PARTIAL_PAID')) && (!isset($orderOverBookings) || !$orderOverBookings)} disabled="disabled"{/if}>{$state['name']|escape}</option>
{/foreach}
</select>
<input type="hidden" name="id_order" value="{$order->id}" />
@@ -542,6 +543,7 @@
<dl class="list-detail col-sm-12">
<label class="label-title">{l s='Guest info'}</label>
<dd><i class="icon-user"></i> &nbsp;<b><a href="?tab=AdminCustomers&amp;id_customer={$customer->id}&amp;viewcustomer&amp;token={getAdminToken tab='AdminCustomers'}">{$customer->firstname} {$customer->lastname}</a></b></dd>
<dd><i class="icon-envelope"></i> &nbsp;<b><a href="mailto:{$customer->email}">{$customer->email}</a></b></dd>
{if $addresses.invoice->phone_mobile || $addresses.invoice->phone}
<dd><i class="icon-phone"></i> &nbsp;<b><a href="tel:{if $addresses.invoice->phone_mobile}{$addresses.invoice->phone_mobile}{else}{$addresses.invoice->phone}{/if}">{if $addresses.invoice->phone_mobile}{$addresses.invoice->phone_mobile}{else}{$addresses.invoice->phone}{/if}</a></b></dd>
@@ -1249,6 +1251,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 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}

View File

@@ -65,7 +65,7 @@
<div class="list-empty">
<div class="list-empty-msg">
<i class="icon-warning-sign list-empty-icon"></i>
{l s='No room bookings found.'}
{l s='No room bookings found to cancel'}
</div>
</div>
{/if}

View File

@@ -41,7 +41,7 @@
</div>
<hr>
<form class="form-hozizontal" method="post" action="{$current_index}&amp;vieworder&amp;token={$smarty.get.token|escape:'html':'UTF-8'}&amp;id_order={$order->id|intval}">
<form class="form-hozizontal" method="post" action="{$reallocate_form_action}">
<div class="form-group">
<div class="row">
<div class="form-group col-sm-6">
@@ -102,7 +102,7 @@
</dl>
</div>
<hr>
<form method="post" action="{$current_index}&amp;vieworder&amp;token={$smarty.get.token|escape:'html':'UTF-8'}&amp;id_order={$order->id|intval}">
<form method="post" action="{$reallocate_form_action}">
<div class="form-group">
</div>
<div class="form-group">

View File

@@ -18,6 +18,7 @@
*}
<div class="modal-body">
<div class="text-left errors-wrap"></div>
<form id="customer-guest-details-form">
<div class="form-group row">
<div class="col-sm-2">

View File

@@ -446,24 +446,21 @@
{if isset($product->id) && $product->id}
<div class="form-group">
<label class="control-label col-lg-3" id="category_position" for="category_position">
<span class="label-tooltip" data-toggle="tooltip" title="{l s='Set position of the room type when hotel search results are displayed.'}">
<span class="label-tooltip" data-toggle="tooltip" title="{l s='Set display position of room type on the search results page.'}">
{l s='Position'}
</span>
</label>
<div class="col-lg-9">
<input type="text" id="category_position" class="form-control fixed-width-lg" name="category_position" value="{$category_position}" />
<p class="help-block">{l s='Please note that position numbering starts from 0. A position of 0 means room type will be displayed at the topmost.'}</p>
<p class="help-block">{l s='Please note that position numbering starts from 0. A position of 0 means room type will be displayed at the topmost position.'}</p>
<div class="alert alert-info">
{l s='You can manage positions of the room types of this hotel from'}
<a href="{$link->getAdminLink('AdminProducts')}&id_category={$htl_full_info['id_category']}">{l s='here.'}</a>
</div>
</div>
</div>
{/if}
{if isset($product->id) && $product->id}
<div class="alert alert-info">
{l s='You can change positions of room types of this hotel from '}
<a href="{$link->getAdminLink('AdminProducts')}&id_category={$htl_full_info['id_category']}">{l s='here.'}</a>
</div>
{/if}
{* <div class="form-group">
<label class="control-label col-lg-3" for="tags_{$id_lang}">
<span class="label-tooltip" data-toggle="tooltip"

View File

@@ -25,6 +25,7 @@
<div class="alert alert-info">
{l s='Below, enter the base occupancy of this room type.'}
<p><b>{l s='Note'}</b>: {l s='Minimum 1 adult is madatory in the base occupancy of the room type'}</p>
</div>
<div class="form-group">
@@ -35,7 +36,7 @@
</span>
</label>
<div class="col-sm-3">
<input id="base_adults" type="text" name="base_adults" class="form-control" value="{if isset($roomTypeInfo)}{$roomTypeInfo['adults']|escape:'htmlall':'UTF-8'}{else}2{/if}">
<input id="base_adults" type="text" name="base_adults" class="form-control" value="{if isset($smarty.post.base_adults)}{$smarty.post.base_adults|escape:'html':'UTF-8'}{elseif isset($roomTypeInfo['adults'])}{$roomTypeInfo['adults']|escape:'html':'UTF-8'}{else}2{/if}">
</div>
</div>
<div class="form-group">
@@ -46,7 +47,7 @@
</span>
</label>
<div class="col-sm-3">
<input id="base_children" type="text" name="base_children" class="form-control" {if isset($roomTypeInfo)}value="{$roomTypeInfo['children']|escape:'htmlall':'UTF-8'}"{/if}>
<input id="base_children" type="text" name="base_children" class="form-control" value="{if isset($smarty.post.base_children)}{$smarty.post.base_children|escape:'html':'UTF-8'}{elseif isset($roomTypeInfo['children'])}{$roomTypeInfo['children']|escape:'html':'UTF-8'}{else}0{/if}">
</div>
</div>
<input id="is_occupancy_submit" type="hidden" name="is_occupancy_submit" class="form-control" value="0">
@@ -67,7 +68,7 @@
</span>
</label>
<div class="col-sm-3">
<input id="max_adults" type="text" name="max_adults" class="form-control" {if isset($roomTypeInfo)}value="{$roomTypeInfo['max_adults']|escape:'htmlall':'UTF-8'}"{/if}>
<input id="max_adults" type="text" name="max_adults" class="form-control" value="{if isset($smarty.post.max_adults)}{$smarty.post.max_adults|escape:'html':'UTF-8'}{elseif isset($roomTypeInfo['max_adults'])}{$roomTypeInfo['max_adults']|escape:'html':'UTF-8'}{/if}">
</div>
</div>
<div class="form-group">
@@ -78,7 +79,7 @@
</span>
</label>
<div class="col-sm-3">
<input id="max_children" type="text" name="max_children" class="form-control" {if isset($roomTypeInfo)}value="{$roomTypeInfo['max_children']|escape:'htmlall':'UTF-8'}"{/if}>
<input id="max_children" type="text" name="max_children" class="form-control" value="{if isset($smarty.post.max_children)}{$smarty.post.max_children|escape:'html':'UTF-8'}{elseif isset($roomTypeInfo['max_children'])}{$roomTypeInfo['max_children']|escape:'html':'UTF-8'}{/if}">
</div>
</div>
<div class="form-group">
@@ -89,7 +90,7 @@
</span>
</label>
<div class="col-sm-3">
<input id="max_guests" type="text" name="max_guests" class="form-control" {if isset($roomTypeInfo)}value="{$roomTypeInfo['max_guests']|escape:'htmlall':'UTF-8'}"{/if}>
<input id="max_guests" type="text" name="max_guests" class="form-control" value="{if isset($smarty.post.max_guests)}{$smarty.post.max_guests|escape:'html':'UTF-8'}{elseif isset($roomTypeInfo['max_guests'])}{$roomTypeInfo['max_guests']|escape:'html':'UTF-8'}{/if}">
</div>
</div>

View File

@@ -147,47 +147,51 @@
form.submit();
});
{if $fields_optional|count}
toggleVisibleColumns($('#form-{$list_id}'));
{/if}
$('#optional-list-toggle').on('click', function(e) {
e.stopPropagation();
})
$('#form-{$list_id} input[name="list_fields_visibility"]').on('change', function(){
toggleVisibleColumns($('#form-{$list_id}'));
})
});
function toggleVisibleColumns(form) {
var list_fields_visibility = [];
$(form).find('input[name="list_fields_visibility"]:checked').each(function(i, field){
list_fields_visibility.push($(field).val());
});
$(form).find('table.table .field_optional').hide();
$(form).find('table.table .field_optional').each(function(i, val) {
if (list_fields_visibility.includes($(this).data('key'))) {
$(this).css('display', '');
}
});
updateListVisibility(list_fields_visibility)
}
function updateListVisibility(list_fields_visibility) {
$.ajax({
type: 'POST',
headers: { "cache-control": "no-cache" },
url: '{$action}',
data: {
ajax: 1,
action: 'updateListVisivility',
list_fields_visibility: list_fields_visibility
},
cache: false,
dataType: 'json'
});
}
</script>
{/if}
<script>
$(document).ready(function(){
{if $fields_optional|count}
toggleVisibleColumns($('#form-{$list_id}'));
{/if}
$('#optional-list-toggle').on('click', function(e) {
e.stopPropagation();
})
$('#form-{$list_id} input[name="list_fields_visibility"]').on('change', function(){
toggleVisibleColumns($('#form-{$list_id}'));
})
});
function toggleVisibleColumns(form) {
var list_fields_visibility = [];
$(form).find('input[name="list_fields_visibility"]:checked').each(function(i, field){
list_fields_visibility.push($(field).val());
});
$(form).find('table.table .field_optional').hide();
$(form).find('table.table .field_optional').each(function(i, val) {
if (list_fields_visibility.includes($(this).data('key'))) {
$(this).show();
}
});
updateListVisibility(list_fields_visibility)
}
function updateListVisibility(list_fields_visibility) {
$.ajax({
type: 'POST',
headers: { "cache-control": "no-cache" },
url: '{$action}',
data: {
ajax: 1,
action: 'updateListVisivility',
list_fields_visibility: list_fields_visibility
},
cache: false,
dataType: 'json'
});
}
</script>
{block name="updatelist"}
{if $new_list_header_design}
<div class="list_action_wrapper">

View File

@@ -64,7 +64,7 @@
</li>
<li class="search-invoices search-option">
<a href="#" data-value="{$QLO_SEARCH_TYPE_INVOICE}" data-placeholder="{l s='Invoice Number'}" data-icon="icon-book">
<i class="icon-book"></i> {l s='Invoices'}
<i class="icon-file-text"></i> {l s='Invoices'}
</a>
</li>
<li class="search-carts search-option">