From ec23dbd4f3feff42e41b3250c2a89ecc95298c5e Mon Sep 17 00:00:00 2001 From: Shreesh Arora Date: Wed, 26 Feb 2025 11:07:31 +0530 Subject: [PATCH] Added feature for adding standard product in cart --- .../normal_products/helpers/form/form.tpl | 5 +- .../normal_products/informations.tpl | 54 +- .../normal_products/quantities.tpl | 301 ++++ .../orders/_current_cart_details_data.tpl | 19 +- .../orders/_hotel_service_products_table.tpl | 153 ++ .../orders/_service_product_line.tpl | 139 -- .../orders/_service_products_table.tpl | 60 - .../_standalone_service_products_table.tpl | 153 ++ .../template/controllers/orders/form.tpl | 42 + .../controllers/orders/helpers/view/view.tpl | 300 ++-- .../orders/modals/_add_product.tpl | 93 ++ .../orders/modals/_add_room_booking.tpl | 4 +- .../orders/modals/_cancel_room_bookings.tpl | 90 +- .../orders/modals/_edit_product.tpl | 78 + classes/Cart.php | 194 ++- classes/PaymentModule.php | 171 ++- classes/Product.php | 85 +- .../CheckoutCustomerDetailsStep.php | 2 +- classes/order/Order.php | 136 +- classes/order/OrderDetail.php | 16 +- classes/order/OrderInvoice.php | 8 +- classes/order/OrderReturn.php | 59 +- classes/order/OrderReturnDetail.php | 6 +- classes/order/OrderSlip.php | 83 +- classes/pdf/HTMLTemplateInvoice.php | 33 +- classes/pdf/HTMLTemplateOrderSlip.php | 17 +- .../WebserviceSpecificManagementBookings.php | 7 +- controllers/admin/AdminCartsController.php | 14 + .../admin/AdminNormalProductsController.php | 229 ++- controllers/admin/AdminOrdersController.php | 895 ++++++++---- .../admin/AdminPPreferencesController.php | 148 +- controllers/front/CartController.php | 150 +- controllers/front/GuestTrackingController.php | 2 +- .../front/OrderConfirmationController.php | 60 +- controllers/front/OrderDetailController.php | 186 ++- controllers/front/OrderOpcController.php | 75 +- controllers/front/OrderReturnController.php | 3 + controllers/front/ParentOrderController.php | 104 +- controllers/front/ProductController.php | 139 +- install/data/db_structure.sql | 5 +- js/admin/normal_products.js | 160 +- js/admin/orders.js | 1292 +++++++++++------ mails/en/hotel-booking-cart-data.tpl | 5 +- mails/en/order_conf.html | 5 + mails/en/order_conf.txt | 2 + mails/en/order_conf_admin.html | 6 + mails/en/order_conf_admin.txt | 2 + ...text.tpl => service-product-data-text.tpl} | 0 ...duct-data.tpl => service-product-data.tpl} | 6 +- modules/blockcart/blockcart.php | 94 +- modules/blockcart/blockcart.tpl | 2 +- .../classes/HotelCartBookingData.php | 6 +- .../classes/HotelReservationSystemDb.php | 27 +- .../classes/HotelServiceProductCartDetail.php | 299 ---- .../RoomTypeServiceProductCartDetail.php | 405 +++++- .../RoomTypeServiceProductOrderDetail.php | 147 +- .../classes/RoomTypeServiceProductPrice.php | 26 + .../classes/ServiceProductOption.php | 91 ++ .../AdminHotelRoomsBookingController.php | 36 +- .../AdminOrderRefundRequestsController.php | 59 +- modules/hotelreservationsystem/define.php | 2 +- .../helpers/view/view.tpl | 69 + modules/qlohotelreview/qlohotelreview.php | 114 +- pdf/invoice.service-product-tab.tpl | 14 +- pdf/invoice.tax-tab.tpl | 2 +- pdf/invoice.total-tab.tpl | 37 +- pdf/invoice.tpl | 4 - pdf/order-slip.product-tab.tpl | 261 ++-- .../_partials/booking-form.tpl | 131 +- .../_partials/cart_booking_demands.tpl | 3 +- .../_partials/order-hotel-service-detail.tpl | 98 ++ .../_partials/order-room-detail.tpl | 4 +- .../order-standalone-service-detail.tpl | 84 ++ .../_partials/service-products-list-row.tpl | 6 +- .../cart-total-block.tpl | 144 ++ themes/hotel-reservation-theme/css/global.css | 35 +- .../css/modules/blockcart/blockcart.css | 11 +- .../css/order-confirmation.css | 47 + .../css/order-detail.css | 38 +- .../hotel-reservation-theme/css/product.css | 20 + themes/hotel-reservation-theme/css/rtl.css | 2 +- .../js/cart-summary.js | 408 ++++-- .../js/modules/blockcart/ajax-cart.js | 638 ++++---- .../js/order-confirmation.js | 2 +- .../js/order-detail.js | 2 +- .../hotel-reservation-theme/js/order-opc.js | 70 +- themes/hotel-reservation-theme/js/product.js | 157 +- .../modules/blockcart/blockcart.tpl | 152 +- .../modules/blockcart/cartrow.tpl | 154 ++ themes/hotel-reservation-theme/my-account.tpl | 2 +- .../order-confirmation.tpl | 804 +++++----- .../hotel-reservation-theme/order-detail.tpl | 475 +++--- .../hotel-reservation-theme/order-follow.tpl | 4 +- themes/hotel-reservation-theme/order-opc.tpl | 108 +- .../hotel-reservation-theme/order-return.tpl | 121 +- themes/hotel-reservation-theme/product.tpl | 8 +- .../shopping-cart-detail.tpl | 418 ++++++ .../hotel-reservation-theme/shopping-cart.tpl | 398 +---- 98 files changed, 8153 insertions(+), 3882 deletions(-) create mode 100644 admin/themes/default/template/controllers/normal_products/quantities.tpl create mode 100644 admin/themes/default/template/controllers/orders/_hotel_service_products_table.tpl delete mode 100644 admin/themes/default/template/controllers/orders/_service_product_line.tpl delete mode 100644 admin/themes/default/template/controllers/orders/_service_products_table.tpl create mode 100644 admin/themes/default/template/controllers/orders/_standalone_service_products_table.tpl create mode 100644 admin/themes/default/template/controllers/orders/modals/_add_product.tpl create mode 100644 admin/themes/default/template/controllers/orders/modals/_edit_product.tpl rename mails/en/{hotel-service-product-data-text.tpl => service-product-data-text.tpl} (100%) rename mails/en/{hotel-service-product-data.tpl => service-product-data.tpl} (96%) delete mode 100644 modules/hotelreservationsystem/classes/HotelServiceProductCartDetail.php create mode 100644 modules/hotelreservationsystem/classes/ServiceProductOption.php create mode 100644 themes/hotel-reservation-theme/_partials/order-hotel-service-detail.tpl create mode 100644 themes/hotel-reservation-theme/_partials/order-standalone-service-detail.tpl create mode 100644 themes/hotel-reservation-theme/cart-total-block.tpl create mode 100644 themes/hotel-reservation-theme/modules/blockcart/cartrow.tpl create mode 100644 themes/hotel-reservation-theme/shopping-cart-detail.tpl diff --git a/admin/themes/default/template/controllers/normal_products/helpers/form/form.tpl b/admin/themes/default/template/controllers/normal_products/helpers/form/form.tpl index 3fe9645bf..86a30fe2f 100644 --- a/admin/themes/default/template/controllers/normal_products/helpers/form/form.tpl +++ b/admin/themes/default/template/controllers/normal_products/helpers/form/form.tpl @@ -79,8 +79,9 @@ var product_type_virtual = {Product::PTYPE_VIRTUAL|intval}; var product_type_simple = {Product::PTYPE_SIMPLE|intval}; - var with_room_type = {Product::SERVICE_PRODUCT_WITH_ROOMTYPE|intval}; - var without_room_type = {Product::SERVICE_PRODUCT_WITHOUT_ROOMTYPE|intval}; + var SERVICE_PRODUCT_WITH_ROOMTYPE = {Product::SERVICE_PRODUCT_WITH_ROOMTYPE|intval}; + var SERVICE_PRODUCT_STANDALONE = {Product::SERVICE_PRODUCT_STANDALONE|intval}; + var SERVICE_PRODUCT_lINKED_WITH_HOTEL = {Product::SERVICE_PRODUCT_lINKED_WITH_HOTEL|intval}; var price_addition_type_with_room = {Product::PRICE_ADDITION_TYPE_WITH_ROOM|intval}; var price_addition_type_independent = {Product::PRICE_ADDITION_TYPE_INDEPENDENT|intval}; diff --git a/admin/themes/default/template/controllers/normal_products/informations.tpl b/admin/themes/default/template/controllers/normal_products/informations.tpl index a9ad62206..3ebfe90d7 100644 --- a/admin/themes/default/template/controllers/normal_products/informations.tpl +++ b/admin/themes/default/template/controllers/normal_products/informations.tpl @@ -232,20 +232,47 @@ var product_name_redirected = '{$product_name_redirected|escape:'html':'UTF-8'}'; -
service_product_type == Product::SERVICE_PRODUCT_WITHOUT_ROOMTYPE}style="display:none;"{/if}> +
+ +
+ +
+
+
service_product_type != Product::SERVICE_PRODUCT_WITH_ROOMTYPE && $product->service_product_type != 0}style="display:none;"{/if}>
{include file="controllers/products/multishop/checkbox.tpl" field="category_box" type="category_box"}
-
+
service_product_type != Product::SERVICE_PRODUCT_lINKED_WITH_HOTEL}style="display:none;"{/if}> +
{include file="controllers/products/multishop/checkbox.tpl" field="category_box" type="category_box"}
+
{$hotel_tree}
-
+
service_product_type != Product::SERVICE_PRODUCT_WITH_ROOMTYPE && $product->service_product_type != 0}style="display:none;"{/if}>
- - {*
- -
- -
-
*} - {*
service_product_type != Product::SERVICE_PRODUCT_WITHOUT_ROOMTYPE}style="display:none"{/if}> -
-
- {l s='Independent products can only be bought from backoffice.'} -
-
-
*}
auto_add_to_cart}style="display:none;"{/if}>
+
+ {l s='Hotel Name' mod='blockcart'}  -  + +
+
+ {l s='Unit Price' mod='blockcart'}  -  + +
{if isset($occupancy_required_for_booking) && $occupancy_required_for_booking}{l s='Room occupancy' mod='blockcart'}{else}{l s='Rooms quantity added' mod='blockcart'}{/if}  -  {l s='Quantity' mod='blockcart'}  -  @@ -345,7 +250,7 @@ {/block} - {block name='blockcart_layer_cart_total_price'} + {block name='blockcart_layer_cart_room_total_price'}
{l s='Total Rooms Cost in cart' mod='blockcart'} @@ -364,6 +269,25 @@
{/block} + {block name='blockcart_layer_cart_product_total_price'} +
+ + {l s='Total Product Cost in cart' mod='blockcart'} + {if $display_tax_label} + {if $priceDisplay == 1} + {l s='(tax excl.)' mod='blockcart'} + {else} + {l s='(tax incl.)' mod='blockcart'} + {/if} + {/if} + + + {if $cart_qties > 0} + {convertPrice price=$cart->getOrderTotal(false, Cart::ONLY_PRODUCTS)} + {/if} + +
+ {/block} + *} + {$product.name|truncate:30:'...':true|escape:'html':'UTF-8'} +
+ {/block} + {block name='blockcart_shopping_cart_hotel_name'} + {if $product.service_product_type == Product::SERVICE_PRODUCT_lINKED_WITH_HOTEL} +
+ {$hotel_wise_data.hotel_name|escape:'html':'UTF-8'} +
+ {/if} + {/block} + {if isset($product.attributes_small)} + + {/if} + {block name='blockcart_shopping_cart_product_total_price'} +
+ {l s='Price' mod='blockcart'}: + + {if !isset($product.is_gift) || !$product.is_gift} + {if $product.booking_product} + {displayWtPrice p="`$product.bookingData.total_room_type_amount`"} + {else if $product.service_product_type == Product::SERVICE_PRODUCT_lINKED_WITH_HOTEL} + {if $priceDisplay == $smarty.const.PS_TAX_EXC}{displayWtPrice p="`$hotel_wise_data.total_price_tax_excl`"}{else}{displayWtPrice p="`$hotel_wise_data.total_price_tax_incl`"}{/if} + {else} + {if $priceDisplay == $smarty.const.PS_TAX_EXC}{displayWtPrice p="`$product.total_price_tax_excl`"}{else}{displayWtPrice p="`$product.total_price_tax_incl`"}{/if} + {/if} +
+ {block name='displayProductPriceBlock'} + {hook h="displayProductPriceBlock" product=$product type="price" from="blockcart"} + {/block} +
+ {else} + {l s='Free!' mod='blockcart'} + {/if} +
+
+ {/block} + + {block name='blockcart_shopping_cart_product_quantity'} +
+ {l s='Total Qty.' mod='blockcart'}: + + {if $product.booking_product} + {$product.bookingData['total_num_rooms']} + {else} + {if $product.service_product_type == Product::SERVICE_PRODUCT_lINKED_WITH_HOTEL} + {$hotel_wise_data.total_qty} + {elseif $product.service_product_type == Product::SERVICE_PRODUCT_STANDALONE} + {$product.cart_quantity} + {/if} + {/if} + +
+ {/block} + + + {if !isset($customizedDatas.$productId.$productAttributeId) && (!isset($product.is_gift) || !$product.is_gift)} +   + {/if} + +
+ {if $product.booking_product} + {block name='blockcart_shopping_cart_dates'} +
+
+ + + + + + + + + {foreach from=$product.bookingData['date_diff'] key=data_k1 item=data_v} + + {assign var="is_full_date" value=($show_full_date && ($data_v['data_form']|date_format:'%D' == $data_v['data_to']|date_format:'%D'))} + + + + + + {/foreach} + +
{l s='Duration' mod='blockcart'}{l s='Qty.' mod='blockcart'}{l s='Price' mod='blockcart'} 
+ {dateFormat date=$data_v['data_form'] full=$is_full_date} - {dateFormat date=$data_v['data_to'] full=$is_full_date} + {$data_v['num_rm']}{convertPrice price=($data_v['amount'] + $data_v['demand_price'])}
+
+
+ {/block} + {else if $product.hasOptions} + {block name='blockcart_shopping_cart_options'} + {if $product.service_product_type == Product::SERVICE_PRODUCT_lINKED_WITH_HOTEL} + {assign var='options' value=$hotel_wise_data.options} + {else if $product.service_product_type == Product::SERVICE_PRODUCT_STANDALONE} + {assign var='options' value=$product.options} + {/if} +
+ + + + + + + + + {foreach from=$options item=data_v} + + + + + + + {/foreach} + +
{l s='Variant' mod='blockcart'}{l s='Qty.' mod='blockcart'}{l s='Price' mod='blockcart'} 
{$data_v.option_name}{$data_v['quantity']}{convertPrice price=($data_v['total_price_tax_excl'])} 
+
+ {/block} + {/if} + +{if isset($product.attributes_small)} +
+{/if} + +{if isset($customizedDatas.$productId.$productAttributeId[$product.id_address_delivery])} + {if !isset($product.attributes_small)} +
+ {/if} +
    + {foreach from=$customizedDatas.$productId.$productAttributeId[$product.id_address_delivery] key='id_customization' item='customization' name='customizations'} +
  • +
    +   +
    + {if isset($customization.datas.$CUSTOMIZE_TEXTFIELD.0)} + {$customization.datas.$CUSTOMIZE_TEXTFIELD.0.value|replace:"
    ":" "|truncate:28:'...'|escape:'html':'UTF-8'} + {else} + {l s='Customization #%d:' sprintf=$id_customization|intval mod='blockcart'} + {/if} +
  • + {/foreach} +
+ {if !isset($product.attributes_small)}
{/if} +{/if} +{if isset($product.attributes_small)}{/if} \ No newline at end of file diff --git a/themes/hotel-reservation-theme/my-account.tpl b/themes/hotel-reservation-theme/my-account.tpl index e3c8a3b01..d74c358b0 100644 --- a/themes/hotel-reservation-theme/my-account.tpl +++ b/themes/hotel-reservation-theme/my-account.tpl @@ -42,7 +42,7 @@
  • {l s='Address'}
  • {l s='Bookings'}
  • {if $refundAllowed} -
  • {l s='Booking refund requests'}
  • +
  • {l s='Refund requests'}
  • {/if}
  • {l s='Credit slips'}
  • {l s='Personal information'}
  • diff --git a/themes/hotel-reservation-theme/order-confirmation.tpl b/themes/hotel-reservation-theme/order-confirmation.tpl index f1c9c9e9c..a5501acb5 100644 --- a/themes/hotel-reservation-theme/order-confirmation.tpl +++ b/themes/hotel-reservation-theme/order-confirmation.tpl @@ -26,7 +26,7 @@ {block name='order_confirmation'} {capture name=path}{l s='Order confirmation'}{/capture} {block name='order_confirmation_heading'} -

    {l s='Order confirmation'}

    +

    {l s='Booking confirmation'} : {$order->reference}

    {/block} {assign var='current_step' value='payment'} @@ -41,13 +41,17 @@ {block name='displayOrderConfirmation'} {$HOOK_ORDER_CONFIRMATION} {/block} -
    - {block name='displayPaymentReturn'} - {$HOOK_PAYMENT_RETURN} - {/block} + +
    +
    +
    + {block name='displayPaymentReturn'} + {$HOOK_PAYMENT_RETURN} + {/block} +
    +
    {if isset($order->id) && $order->id} {if $is_guest} -

    {l s='Your Order Reference is:'} {$order->reference}

    {l s='Follow my order'}

    @@ -55,8 +59,6 @@ {if isset($is_free_order) && $is_free_order}

    {l s='Your'} {if $total_rooms_booked > 1}{l s='bookings have'}{else}{l s='booking has'}{/if} {l s='been created successfully!'}


    {/if} -

    {l s='Order Status :'} {l s='Confirmed'}

    -

    {l s='Order Reference :'} {$order->reference}

    {if $any_back_order} {if $shw_bo_msg}
    @@ -66,357 +68,465 @@

    {/if} {/if} -
    - {block name='order_detail_heading'} -

    {l s='Order Details -'}

    - {/block} {block name='order_details'}
    - - {if isset($cart_htl_data)} - - - - - - - - - - - - - - {foreach from=$cart_htl_data key=data_k item=data_v} - {foreach from=$data_v['date_diff'] key=rm_k item=rm_v} - - {block name='order_detail_room_type_image'} - - {/block} - {block name='order_detail_room_type_name'} - - {/block} - {block name='order_detail_room_type_hotel_name'} - - {/block} - {block name='order_detail_room_type_guest'} - - {/block} - {assign var="is_full_date" value=($show_full_date && ($rm_v['data_form']|date_format:'%D' == $rm_v['data_to']|date_format:'%D'))} - {block name='order_detail_room_type_check_in'} - - {/block} - {block name='order_detail_room_type_check_out'} - - {/block} - {block name='order_detail_room_type_extra_demands'} - - {/block} - {block name='order_confirmation_cart_total'} - - {/block} - {if isset($orders_has_invoice) && $orders_has_invoice && $order->payment != 'Free order'} - {/if} - {* *} - - {/foreach} - {/foreach} - - {/if} - {if isset($cart_service_products)} - - - - - - - - - - - {foreach from=$cart_service_products key=data_k item=data_v} - - - - - - - - {/foreach} - - {/if} - - {block name='order_detail_total_information'} - {if isset($cart_htl_data)} - {if $priceDisplay && $use_tax} - - - - - - {else} - - - - - - {/if} - {/if} - {* {if isset($cart_service_products) && $cart_service_products} - {if $priceDisplay && $use_tax} - - - - - - {/if} - - - - - - {/if} *} - {* {if $orderTotalInfo['total_services_te'] > 0} - {if $priceDisplay && $use_tax} - - - - - - {/if} - - - - - - {/if} *} - {if $order->total_wrapping > 0} - - - - - - {/if} - {if $priceDisplay && $use_tax && $orderTotalInfo['total_convenience_fee_te']} - - - - - - {else if $orderTotalInfo['total_convenience_fee_ti']} - - - - - - {/if} - - - - - - {if $order->total_discounts > 0} - - - - - - {/if} - - - - - - {if $orderTotalInfo['total_paid'] > $orderTotalInfo['total_paid_real']} - - - - - - {/if} + + + + {block name='displayOrderDetailPaymentDetailsRow'} + {hook h='displayOrderDetailPaymentDetailsRow' id_order=$order->id} + {/block} + + {/block} - -
    {l s='Room Image'}{l s='Room Description'}{l s='Hotel Name'}{l s='Rooms'}{l s='Check-in Date'}{l s='Check-out Date'}{l s='Extra Services'}{l s='Total'}
    - - - - -

    - - {$data_v['name']} - -

    -
    - {$data_v['hotel_name']} - {block name='displayOrderConfirmationHotelNameAfter'} - {hook h="displayOrderConfirmationHotelNameAfter" id_product=$data_v['id_product']} - {/block} - -

    - {if $rm_v['adults'] <= 9}0{$rm_v['adults']}{else}{$rm_v['adults']}{/if} {if $rm_v['adults'] > 1}{l s='Adults'}{else}{l s='Adult'}{/if}{if $rm_v['children']}, {if $rm_v['children'] <= 9}0{$rm_v['children']}{else} {$rm_v['children']}{/if} {if $rm_v['children'] > 1}{l s='Children'}{else}{l s='Child'}{/if}{/if}
    {if $rm_v['num_rm'] <= 9}0{/if}{$rm_v['num_rm']} {if $rm_v['num_rm'] > 1}{l s='Rooms'}{else}{l s='Room'}{/if} -

    -
    -

    - {dateFormat date=$rm_v['data_form'] full=$is_full_date} -

    -
    -

    - {dateFormat date=$rm_v['data_to'] full=$is_full_date} -

    -
    -

    - {if (isset($rm_v['extra_demands']) && $rm_v['extra_demands']) || isset($rm_v['additional_services']) && $rm_v['additional_services']} - - {/if} - {if $group_use_tax} - {displayWtPriceWithCurrency price=($rm_v['extra_demands_price_ti'] + $rm_v['additional_services_price_ti']) currency=$objOrderCurrency} - {else} - {displayWtPriceWithCurrency price=($rm_v['extra_demands_price_te'] + $rm_v['additional_services_price_te']) currency=$objOrderCurrency} - {/if} - {if (isset($rm_v['extra_demands']) && $rm_v['extra_demands']) || isset($rm_v['additional_services']) && $rm_v['additional_services']} +

    -

    - {if $group_use_tax} - {displayWtPriceWithCurrency price=($rm_v['amount_tax_incl'] + $rm_v['extra_demands_price_ti'] + $rm_v['additional_services_price_ti'] + $rm_v['additional_services_price_auto_add_ti']) currency=$objOrderCurrency} - {else} - {displayWtPriceWithCurrency price=($rm_v['amount_tax_excl'] + $rm_v['extra_demands_price_te'] + $rm_v['additional_services_price_te'] + $rm_v['additional_services_price_auto_add_te']) currency=$objOrderCurrency} - {/if} - {if (isset($rm_v['extra_demands']) && $rm_v['extra_demands']) || isset($rm_v['additional_services']) && $rm_v['additional_services']} - - - -

    + {/if} + {if isset($cart_standalone_service_products) || isset($cart_hotel_service_products)} +
    +
    {l s='Product Details'}
    +
    + {if isset($cart_hotel_service_products)} + {foreach from=$cart_hotel_service_products key=data_k item=product} +
    +
    + {block name='order_hotel_product_image'} +
    + + + +
    + {/block} + {block name='order_hotel_product_detail'} +
    +
    + +
    +
    +
    +
    +
    +
    +
    {l s='Quantity'}
    +
    {$product.product_quantity}
    +
    +
    +
    +
    +
    {l s='Unit Price'}
    +
    + {if $group_use_tax} + {displayWtPriceWithCurrency price=$product.unit_price_tax_incl currency=$currency} + {else} + {displayWtPriceWithCurrency price=$product.unit_price_tax_excl currency=$currency} + {/if} +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    {l s='Total Pricing'}
    +
    + {if $group_use_tax} + {displayWtPriceWithCurrency price=$product.total_price_tax_incl currency=$currency} + {else} + {displayWtPriceWithCurrency price=$product.total_price_tax_excl currency=$currency} + {/if} +
    +
    +
    +
    +
    + {/block} +
    +
    + {/foreach} + {/if} + {if isset($cart_standalone_service_products)} + {foreach from=$cart_standalone_service_products key=data_k item=product} +
    +
    + {block name='order_hotel_product_image'} +
    + + + +
    + {/block} + {block name='order_hotel_product_detail'} +
    +
    + +
    +
    +
    +
    +
    +
    +
    {l s='Quantity'}
    +
    {$product.product_quantity}
    +
    +
    +
    +
    +
    {l s='Unit Price'}
    +
    + {if $group_use_tax} + {displayWtPriceWithCurrency price=$product.unit_price_tax_incl currency=$currency} + {else} + {displayWtPriceWithCurrency price=$product.unit_price_tax_excl currency=$currency} + {/if} +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    {l s='Total Pricing'}
    +
    + {if $group_use_tax} + {displayWtPriceWithCurrency price=$product.total_price_tax_incl currency=$currency} + {else} + {displayWtPriceWithCurrency price=$product.total_price_tax_excl currency=$currency} + {/if} +
    +
    +
    +
    +
    +
    +
    +
    +
    + {/block} +
    +
    + {/foreach} + {/if} +
    +
    + {/if} + +
    + {block name='order_detail_payment_details'} +
    +
    + {l s='Payment Details'} +
    +
    +
    + +
    + {* {if $invoice && $invoiceAllowed} + + + {$order->payment|escape:'html':'UTF-8'} + + {else} *} + {$order->payment|escape:'html':'UTF-8'} + {* {/if} *} +
    +
    +
    +
    + +
    + {if isset($order_history[0]) && $order_history[0]} + + {if $order_history[0].id_order_state|in_array:$overbooking_order_states} + {l s='Order Not Confirmed'} + {else} + {$order_history[0].ostate_name|escape:'html':'UTF-8'} {/if} -

    -
    - {if isset($rm_v['is_backorder']) && $rm_v['is_backorder']} - {l s='On Backorder'} + {else} - -- + {l s='Processing'} {/if} -
    {l s='Image'}{l s='Name'}{l s='Unit Price'}{l s='Quantity'}{l s='Total'}
    - - - - -

    - - {$data_v['product_name']} - -

    -
    -

    - {if $group_use_tax} - {displayWtPriceWithCurrency price=$data_v['unit_price_tax_incl'] currency=$objOrderCurrency} - {* {displayPrice price=$data_v['unit_price_tax_incl']|floatval|round:2} *} - {else} - {* {displayPrice price=$data_v['unit_price_tax_excl']|floatval|round:2} *} - {displayWtPriceWithCurrency price=$data_v['unit_price_tax_excl'] currency=$objOrderCurrency} - {/if} -

    -
    -

    - {$data_v['product_quantity']} -

    -
    -

    - {if $group_use_tax} - {displayWtPriceWithCurrency price=$data_v['total_price_tax_incl'] currency=$objOrderCurrency} - {else} - {displayWtPriceWithCurrency price=$data_v['total_price_tax_excl'] currency=$objOrderCurrency} - {/if} -

    -
    - {l s='Total Rooms Cost (tax excl.)'} - - {displayWtPriceWithCurrency price=($orderTotalInfo['total_rooms_te'] + $orderTotalInfo['total_services_te'] + $orderTotalInfo['total_auto_add_services_te'] + $orderTotalInfo['total_demands_price_te']) currency=$objOrderCurrency} -
    - {l s='Total Rooms Cost'} {if $use_tax}{l s='(tax incl.)'}{/if} - - {displayWtPriceWithCurrency price=($orderTotalInfo['total_rooms_ti'] + $orderTotalInfo['total_services_ti'] + $orderTotalInfo['total_auto_add_services_ti'] + $orderTotalInfo['total_demands_price_ti']) currency=$objOrderCurrency} -
    - {l s='Total service products cost (tax excl.)'} - - {displayWtPriceWithCurrency price=$orderTotalInfo['total_service_products_te'] currency=$objOrderCurrency} -
    - {l s='Total service products cost'} {if $use_tax}{l s='(tax incl.)'}{/if} - - {displayWtPriceWithCurrency price=$orderTotalInfo['total_service_products_ti'] currency=$objOrderCurrency} -
    - {l s='Total extra services cost (tax excl.)'} - - {displayWtPriceWithCurrency price=$orderTotalInfo['total_services_te'] currency=$objOrderCurrency} -
    - {l s='Total extra services cost'} {if $use_tax}{l s='(tax incl.)'}{/if} - - {displayWtPriceWithCurrency price=$orderTotalInfo['total_services_ti'] currency=$objOrderCurrency convert=1} -
    - {l s='Total gift wrapping cost'} - - {displayWtPriceWithCurrency price=($orderTotalInfo['total_wrapping'] * -1) currency=$objOrderCurrency} -
    - {l s='Total Convenience Fees (tax excl.)'} - - {displayWtPriceWithCurrency price=($orderTotalInfo['total_convenience_fee_te']) currency=$objOrderCurrency} -
    - {l s='Total Convenience Fees'} {if $use_tax}{l s='(tax incl.)'}{/if} - - {displayWtPriceWithCurrency price=($orderTotalInfo['total_convenience_fee_ti']) currency=$objOrderCurrency} -
    - {l s='Total Tax'} - - {displayWtPriceWithCurrency price=$orderTotalInfo['total_tax_without_discount'] currency=$objOrderCurrency convert=1} -
    - {l s='Total Vouchers'} - - {if $priceDisplay && $use_tax} - {displayWtPriceWithCurrency price=($orderTotalInfo['total_discounts_te'] * -1) currency=$objOrderCurrency convert=1} - {else} - {displayWtPriceWithCurrency price=($orderTotalInfo['total_discounts'] * -1) currency=$objOrderCurrency convert=1} - {/if} -
    - {l s='Final Booking Total'} - - {displayWtPriceWithCurrency price=$orderTotalInfo['total_paid'] currency=$objOrderCurrency} -
    - {l s='Due Amount'} - - {displayWtPriceWithCurrency price=($orderTotalInfo['total_paid'] - $orderTotalInfo['total_paid_real']) currency=$objOrderCurrency} -
    + {block name='order_detail_payment_summary'} +
    +
    + {l s='Payment Summary'} +
    +
    +
    + + + {if isset($cart_htl_data)} + {if $priceDisplay && $use_tax} + + + + + {else} + + + + + {/if} + {/if} + {if isset($cart_standalone_service_products) || isset($cart_hotel_service_products)} + {if $priceDisplay && $use_tax} + + + + + {else} + + + + + {/if} + {/if} + {if $order->total_wrapping > 0} + + + + + {/if} + {if $priceDisplay && $use_tax && $orderTotalInfo['total_convenience_fee_te']} + + + + + {else if $orderTotalInfo['total_convenience_fee_ti']} + + + + + {/if} + + + + + {if $order->total_discounts > 0} + + + + + {/if} + + + + + {if $orderTotalInfo['total_paid'] > $orderTotalInfo['total_paid_real']} + + + + + {/if} + + + +
    + {l s='Total Rooms Cost (tax excl.)'} + + {displayWtPriceWithCurrency price=($orderTotalInfo['total_rooms_te'] + $orderTotalInfo['total_services_te'] + $orderTotalInfo['total_auto_add_services_te'] + $orderTotalInfo['total_demands_price_te']) currency=$objOrderCurrency} +
    + {l s='Total Rooms Cost'} {if $use_tax}{l s='(tax incl.)'}{/if} + + {displayWtPriceWithCurrency price=($orderTotalInfo['total_rooms_ti'] + $orderTotalInfo['total_services_ti'] + $orderTotalInfo['total_auto_add_services_ti'] + $orderTotalInfo['total_demands_price_ti']) currency=$objOrderCurrency} +
    + {l s='Total products cost (tax excl.)'} + + {displayWtPriceWithCurrency price=$orderTotalInfo['total_service_products_te'] currency=$objOrderCurrency} +
    + {l s='Total products cost'} {if $use_tax}{l s='(tax incl.)'}{/if} + + {displayWtPriceWithCurrency price=$orderTotalInfo['total_service_products_ti'] currency=$objOrderCurrency} +
    + {l s='Total gift wrapping cost'} + + {displayWtPriceWithCurrency price=($orderTotalInfo['total_wrapping'] * -1) currency=$objOrderCurrency} +
    + {l s='Total Convenience Fees (tax excl.)'} + + {displayWtPriceWithCurrency price=($orderTotalInfo['total_convenience_fee_te']) currency=$objOrderCurrency} +
    + {l s='Total Convenience Fees'} {if $use_tax}{l s='(tax incl.)'}{/if} + + {displayWtPriceWithCurrency price=($orderTotalInfo['total_convenience_fee_ti']) currency=$objOrderCurrency} +
    + {l s='Total Tax'} + + {displayWtPriceWithCurrency price=$orderTotalInfo['total_tax_without_discount'] currency=$objOrderCurrency convert=1} +
    + {l s='Total Vouchers'} + + {if $priceDisplay && $use_tax} + {displayWtPriceWithCurrency price=($orderTotalInfo['total_discounts_te'] * -1) currency=$objOrderCurrency convert=1} + {else} + {displayWtPriceWithCurrency price=($orderTotalInfo['total_discounts'] * -1) currency=$objOrderCurrency convert=1} + {/if} +
    + {l s='Final Booking Total'} + + {displayWtPriceWithCurrency price=$orderTotalInfo['total_paid'] currency=$objOrderCurrency} +
    + {l s='Due Amount'} + + {displayWtPriceWithCurrency price=($orderTotalInfo['total_paid'] - $orderTotalInfo['total_paid_real']) currency=$objOrderCurrency} +
    +
    +
    +
    + {/block} +
    +
    {/block}

    {l s='An email has been sent with this information.'} diff --git a/themes/hotel-reservation-theme/order-detail.tpl b/themes/hotel-reservation-theme/order-detail.tpl index b2f89be2e..632e262cb 100644 --- a/themes/hotel-reservation-theme/order-detail.tpl +++ b/themes/hotel-reservation-theme/order-detail.tpl @@ -75,38 +75,40 @@ {/block} {block name='order_detail_hotel_details'} -

    -
    - {l s='Hotel Details'} + {if isset($obj_hotel_branch_information)} +
    +
    + {l s='Hotel Details'} +
    +
    + {if Validate::isLoadedObject($obj_hotel_branch_information)} +
    +
    +
    +
    {l s='Hotel Name'}
    +
    {$obj_hotel_branch_information->hotel_name}
    +
    {l s='Phone Number'}
    +
    + + {if $hotel_address_info.phone_mobile}{$hotel_address_info.phone_mobile}{else}{$hotel_address_info.phone}{/if} + +
    +
    {l s='Email'}
    +
    + +
    + {block name='displayOrderDetailHotelDetailsAfter'} + {hook h='displayOrderDetailHotelDetailsAfter' id_order=$order->id} + {/block} +
    +
    +
    + {else} +
    {l s='Hotel details not available.'}
    + {/if} +
    -
    - {if Validate::isLoadedObject($obj_hotel_branch_information)} -
    -
    -
    -
    {l s='Hotel Name'}
    -
    {$obj_hotel_branch_information->hotel_name}
    -
    {l s='Phone Number'}
    -
    - - {if $hotel_address_info.phone_mobile}{$hotel_address_info.phone_mobile}{else}{$hotel_address_info.phone}{/if} - -
    -
    {l s='Email'}
    -
    - -
    - {block name='displayOrderDetailHotelDetailsAfter'} - {hook h='displayOrderDetailHotelDetailsAfter' id_order=$order->id} - {/block} -
    -
    -
    - {else} -
    {l s='Hotel details not available.'}
    - {/if} -
    -
    + {/if} {/block} {block name='order_details_payment_details_mobile'} @@ -154,42 +156,44 @@ {/block} {block name='order_detail_hotel_location_mobile'} -