diff --git a/admin/themes/default/img/icon-info.svg b/admin/themes/default/img/icon-info.svg new file mode 100644 index 000000000..5d4d44d02 --- /dev/null +++ b/admin/themes/default/img/icon-info.svg @@ -0,0 +1,4 @@ + + + + diff --git a/admin/themes/default/js/admin-theme.js b/admin/themes/default/js/admin-theme.js index 1aa61350d..04acc90b5 100644 --- a/admin/themes/default/js/admin-theme.js +++ b/admin/themes/default/js/admin-theme.js @@ -478,4 +478,42 @@ $(document).ready(function() { $('.no-htl-access-option').on('click', function() { $(this).prop('selected', false); }); + initTooltip(); }); //end dom ready + +function initTooltip($target, contentFn, items) { + var $elements = $target || $('.tooltip-trigger'); + if (!$elements.length) { + return; + } + $elements.each(function () { + var $this = $(this); + if (!contentFn && $this.data('ui-tooltip')) { + return; + } + $this.tooltip({ + content: contentFn || $this.next('.tooltip-content').html(), + items: items || 'span', + trigger: 'hover', + tooltipClass: 'tooltip-popup', + open: function (event, ui) { + if (event.buttons == 1 || event.buttons == 3) { + ui.tooltip.remove(); + } + if (typeof event.originalEvent === 'undefined') { + return false; + } + var $id = $(ui.tooltip).attr('id'); + if ($('div.ui-tooltip').not('#' + $id).length) { + return false; + } + }, + close: function (event, ui) { + ui.tooltip.hover( + function () { $(this).stop(true).fadeTo(300, 1); }, + function () { $(this).fadeOut(300, function () { $(this).remove(); }); } + ); + } + }); + }); +} \ No newline at end of file diff --git a/admin/themes/default/js/modernizr-loads.js b/admin/themes/default/js/modernizr-loads.js index aa738e542..f4142963e 100644 --- a/admin/themes/default/js/modernizr-loads.js +++ b/admin/themes/default/js/modernizr-loads.js @@ -3,6 +3,10 @@ Modernizr.load([ test: window.matchMedia, nope: ["themes/default/js/vendor/matchMedia.js", "themes/default/js/vendor/matchMedia.addListener.js"] }, - "themes/default/js/vendor/enquire.min.js", - "themes/default/js/admin-theme.js", + { + load: ["themes/default/js/vendor/enquire.min.js", "themes/default/js/admin-theme.js"], + complete: function() { + $(document).trigger('admin-theme.js.ready'); + } + } ]); \ No newline at end of file diff --git a/admin/themes/default/sass/partials/_tooltip.sass b/admin/themes/default/sass/partials/_tooltip.sass index 986d49667..d1f445386 100644 --- a/admin/themes/default/sass/partials/_tooltip.sass +++ b/admin/themes/default/sass/partials/_tooltip.sass @@ -1,5 +1,4 @@ .tooltip_cont - min-width: 280px width: 100% font-size: 14px font-weight: 600 @@ -7,6 +6,7 @@ margin-bottom: 10px .tip-body > div margin-bottom: 6px + margin-right: 10px .tip_element_head font-size: 12px @@ -28,3 +28,30 @@ border: none padding: 10px box-shadow: 0px 0px 15px 0px rgba(0, 0, 0, 0.15) + width: auto + +.tooltip-trigger + cursor: pointer + display: inline-block + vertical-align: middle + + + +.ui-tooltip.tooltip-popup + ul + margin: 0 + padding: 0 0 0 16px + list-style: disc + li + padding: 2px 0 + +.tooltip-popup-row + display: flex + justify-content: space-between + align-items: center + gap: 12px + margin: 3px 0 + white-space: nowrap + label + font-weight: 600 + margin: 0 diff --git a/admin/themes/default/template/controllers/guest_registration/helpers/view/view.tpl b/admin/themes/default/template/controllers/guest_registration/helpers/view/view.tpl new file mode 100644 index 000000000..91b33e572 --- /dev/null +++ b/admin/themes/default/template/controllers/guest_registration/helpers/view/view.tpl @@ -0,0 +1,68 @@ +{** +* NOTICE OF LICENSE +* +* This source file is subject to the Open Software License version 3.0 +* that is bundled with this package in the file LICENSE.md +* It is also available through the world-wide-web at this URL: +* https://opensource.org/license/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 support@qloapps.com so we can send you a copy immediately. +* +* DISCLAIMER +* +* Do not edit or add to this file if you wish to upgrade this module to a 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 +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 +*} + +
+
+ + {l s='Guest Registration Card Information'} +
+ +
+ + +
+ +
+ {$guest_reg_card_info_tree} +
+ +
+ + +
+
+ + diff --git a/modules/hotelreservationsystem/views/templates/admin/hotel_features/index.php b/admin/themes/default/template/controllers/guest_registration/index.php similarity index 82% rename from modules/hotelreservationsystem/views/templates/admin/hotel_features/index.php rename to admin/themes/default/template/controllers/guest_registration/index.php index 409280877..e7a621e6c 100644 --- a/modules/hotelreservationsystem/views/templates/admin/hotel_features/index.php +++ b/admin/themes/default/template/controllers/guest_registration/index.php @@ -2,10 +2,10 @@ /** * NOTICE OF LICENSE * -* This source file is subject to the Open Software License version 3.0 +* This source file is subject to the Academic Free License (AFL 3.0) * that is bundled with this package in the file LICENSE.md * It is also available through the world-wide-web at this URL: -* https://opensource.org/license/osl-3-0-php +* https://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 support@qloapps.com so we can send you a copy immediately. @@ -18,7 +18,7 @@ * * @author Webkul IN * @copyright Since 2010 Webkul -* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 +* @license https://opensource.org/licenses/afl-3.0.php Academic Free License 3.0 */ header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); @@ -29,4 +29,4 @@ header('Cache-Control: post-check=0, pre-check=0', false); header('Pragma: no-cache'); header('Location: ../../../'); -exit; +exit; \ No newline at end of file diff --git a/admin/themes/default/template/controllers/orders/_current_cart_details_data.tpl b/admin/themes/default/template/controllers/orders/_current_cart_details_data.tpl index a8a692a98..0e6573e8f 100644 --- a/admin/themes/default/template/controllers/orders/_current_cart_details_data.tpl +++ b/admin/themes/default/template/controllers/orders/_current_cart_details_data.tpl @@ -124,8 +124,15 @@ {/if} {assign var=shown_room_type_price value=$data.feature_price_tax_excl} + {if isset($can_edit_booking_carts)} + {assign var=can_edit_booking_cart_price value=$can_edit_booking_carts} + {elseif isset($can_edit)} + {assign var=can_edit_booking_cart_price value=$can_edit} + {else} + {assign var=can_edit_booking_cart_price value=0} + {/if}
- + {$currency->prefix}{$currency->suffix}
diff --git a/admin/themes/default/template/controllers/orders/_product_line.tpl b/admin/themes/default/template/controllers/orders/_product_line.tpl index b8b4a0168..9044b1774 100644 --- a/admin/themes/default/template/controllers/orders/_product_line.tpl +++ b/admin/themes/default/template/controllers/orders/_product_line.tpl @@ -164,6 +164,11 @@ {if $data.num_checkin_documents > 0}{$data.num_checkin_documents}{else}0{/if} +
  • + + {l s='GRC'} + +
  • diff --git a/admin/themes/default/template/controllers/orders/_stay_periods_tooltip.tpl b/admin/themes/default/template/controllers/orders/_stay_periods_tooltip.tpl new file mode 100644 index 000000000..eb98c6735 --- /dev/null +++ b/admin/themes/default/template/controllers/orders/_stay_periods_tooltip.tpl @@ -0,0 +1,47 @@ +{** +* NOTICE OF LICENSE +* +* This source file is subject to the Open Software License version 3.0 +* that is bundled with this package in the file LICENSE.md +* It is also available through the world-wide-web at this URL: +* https://opensource.org/license/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 support@qloapps.com so we can send you a copy immediately. +* +* DISCLAIMER +* +* Do not edit or add to this file if you wish to upgrade this module to a 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 +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 +*} + +{capture name='stay_periods_tooltip'} +
    +
    +
    {l s='Stay Periods'}
    +
    + + + + + + + + + {foreach from=$stay_periods item=stay_period} + + + + + {/foreach} + +
    {l s='Duration'}{l s='Rooms'}
    {$stay_period.from} – {$stay_period.to}{$stay_period.count}
    +
    +{/capture} +{capture name='stay_periods_tooltip_title'}+{$extra_stay_periods_count}{/capture} +{include file='helpers/tooltip.tpl' tooltip_content=$smarty.capture.stay_periods_tooltip tooltip_title=$smarty.capture.stay_periods_tooltip_title} diff --git a/admin/themes/default/template/controllers/orders/form.tpl b/admin/themes/default/template/controllers/orders/form.tpl index 73b4660f2..80baa51a2 100644 --- a/admin/themes/default/template/controllers/orders/form.tpl +++ b/admin/themes/default/template/controllers/orders/form.tpl @@ -27,6 +27,8 @@ var id_cart = {$cart->id|intval}; {/if} var id_customer = 0; + var can_edit_booking_carts = {if isset($can_edit_booking_carts) && $can_edit_booking_carts}true{else}false{/if}; + var can_add_addresses = {if isset($can_add_addresses) && $can_add_addresses}true{else}false{/if}; var admin_order_tab_link = "{$link->getAdminLink('AdminOrders')|addslashes}"; var changed_shipping_price = false; var shipping_price_selected_carrier = ''; @@ -620,6 +622,10 @@ $(booking_occupancy_wrapper).siblings('.booking_guest_occupancy').find('span').text(guestButtonVal); } {/literal} + + if (!can_edit_booking_carts || !can_add_addresses) { + $('#address_part').hide(); + } }); function resetBind() @@ -953,7 +959,9 @@ {if isset($cart->id) && $cart->id} id_cart = "{$cart->id}"; {/if} - $('#new_address').attr('href', address_link.replace(/id_customer=[0-9]+/, 'id_customer='+id_customer)); + if (address_link) { + $('#new_address').attr('href', address_link.replace(/id_customer=[0-9]+/, 'id_customer='+id_customer)); + } $.ajax({ type:"POST", url : "{$link->getAdminLink('AdminCarts')|addslashes}", @@ -1396,6 +1404,7 @@ { $("#customer_cart_details").empty(); $("#customer_cart_details").append(res.cart_detail_html); + initTooltip(); displaySummary(res); } @@ -1505,13 +1514,20 @@ if (addresses.length == 0) { $('#address_delivery, #address_invoice').hide(); - $("#new_address").show(); + if (can_edit_booking_carts && can_add_addresses) { + $('#address_part').show(); + $("#new_address").show(); + } else { + $('#address_part').hide(); + } } else { $('#addresses_err').hide(); $("#new_address").hide(); $('#address_delivery, #address_invoice').show(); + $('#address_part').show(); + $('#address_part .panel-heading').show(); } $('#id_address_delivery').html(addresses_delivery_options).hide(); @@ -1894,13 +1910,15 @@ -
    - {l s='Or'}  - - - {l s='Add new customer'} - -
    + {if isset($can_edit_booking_carts) && $can_edit_booking_carts && isset($can_add_customers) && $can_add_customers} +
    + {l s='Or'}  + + + {l s='Add new customer'} + +
    + {/if} @@ -1918,7 +1936,7 @@ Details @@ -2127,13 +2145,15 @@ -
    - {l s='Or'}  - - - {l s='Add new voucher'} - -
    + {if isset($can_edit_booking_carts) && $can_edit_booking_carts && isset($can_add_vouchers) && $can_add_vouchers} +
    + {l s='Or'}  + + + {l s='Add new voucher'} + +
    + {/if} @@ -2155,7 +2175,7 @@
    -
    +
    {l s='Addresses'}
    @@ -2189,6 +2209,7 @@
    + {if isset($can_edit_booking_carts) && $can_edit_booking_carts && isset($can_add_addresses) && $can_add_addresses}
    + {/if}