Fixed: Tax label is displayed in the front even if the 'Display tax label' is disabled

This commit is contained in:
vishalsingh.qlo325
2025-06-06 17:07:18 +05:30
parent 0540eadbeb
commit 7600a87b21
2 changed files with 83 additions and 138 deletions

View File

@@ -414,46 +414,32 @@
<table class="table table-sm table-responsive table-summary">
<tbody>
{if isset($cart_htl_data)}
{if $priceDisplay && $use_tax}
<tr class="item">
<td>
<strong>{l s='Total Rooms Cost (tax excl.)'}</strong>
</td>
<td class="text-right">
<tr class="item">
<td>
<strong>{l s='Total Rooms Cost'} {if $use_taxes && $display_tax_label == 1}{if $priceDisplay == 1}{l s='(tax excl.)'}{elseif $priceDisplay == 0}{l s='(tax incl.)'}{/if} {/if}</strong>
</td>
<td class="text-right">
{if $priceDisplay && $use_tax}
<span>{displayWtPriceWithCurrency price=($orderTotalInfo['total_rooms_te'] + $orderTotalInfo['total_services_te'] + $orderTotalInfo['total_auto_add_services_te'] + $orderTotalInfo['total_demands_price_te']) currency=$objOrderCurrency}</span>
</td>
</tr>
{else}
<tr class="item">
<td>
<strong>{l s='Total Rooms Cost'} {if $use_tax}{l s='(tax incl.)'}{/if} </strong>
</td>
<td class="text-right">
{else}
<span>{displayWtPriceWithCurrency price=($orderTotalInfo['total_rooms_ti'] + $orderTotalInfo['total_services_ti'] + $orderTotalInfo['total_auto_add_services_ti'] + $orderTotalInfo['total_demands_price_ti']) currency=$objOrderCurrency}</span>
</td>
</tr>
{/if}
{/if}
</td>
</tr>
{/if}
{if (isset($cart_standalone_service_products) && $cart_standalone_service_products) || (isset($cart_hotel_service_products) && $cart_hotel_service_products)}
{if $priceDisplay && $use_tax}
<tr class="item">
<td>
<strong>{l s='Total products cost (tax excl.)'}</strong>
</td>
<td class="text-right">
<tr class="item">
<td>
<strong>{l s='Total products cost'} {if $use_taxes && $display_tax_label == 1}{if $priceDisplay == 1}{l s='(tax excl.)'}{elseif $priceDisplay == 0}{l s='(tax incl.)'}{/if} {/if}</strong>
</td>
<td class="text-right">
{if $priceDisplay && $use_tax}
<span>{displayWtPriceWithCurrency price=$orderTotalInfo['total_standalone_products_te'] currency=$objOrderCurrency}</span>
</td>
</tr>
{else}
<tr class="item">
<td>
<strong>{l s='Total products cost'} {if $use_tax}{l s='(tax incl.)'}{/if} </strong>
</td>
<td class="text-right">
{else}
<span>{displayWtPriceWithCurrency price=$orderTotalInfo['total_standalone_products_ti'] currency=$objOrderCurrency}</span>
</td>
</tr>
{/if}
{/if}
</td>
</tr>
{/if}
{if $order->total_wrapping > 0}
<tr class="item">
@@ -465,22 +451,17 @@
</td>
</tr>
{/if}
{if $priceDisplay && $use_tax && $orderTotalInfo['total_convenience_fee_te']}
{if $orderTotalInfo['total_convenience_fee_te'] || $orderTotalInfo['total_convenience_fee_ti']}
<tr class="item">
<td>
<strong>{l s='Total Convenience Fees (tax excl.)'}</strong>
<strong>{l s='Total Convenience Fees'} {if $use_taxes && $display_tax_label == 1}{if $priceDisplay == 1}{l s='(tax excl.)'}{elseif $priceDisplay == 0}{l s='(tax incl.)'}{/if} {/if}</strong>
</td>
<td class="text-right">
<span>{displayWtPriceWithCurrency price=($orderTotalInfo['total_convenience_fee_te']) currency=$objOrderCurrency}</span>
</td>
</tr>
{else if $orderTotalInfo['total_convenience_fee_ti']}
<tr class="item">
<td>
<strong>{l s='Total Convenience Fees'} {if $use_tax}{l s='(tax incl.)'}{/if} </strong>
</td>
<td class="text-right">
<span>{displayWtPriceWithCurrency price=($orderTotalInfo['total_convenience_fee_ti']) currency=$objOrderCurrency}</span>
{if $priceDisplay && $use_tax}
<span>{displayWtPriceWithCurrency price=($orderTotalInfo['total_convenience_fee_te']) currency=$objOrderCurrency}</span>
{else}
<span>{displayWtPriceWithCurrency price=($orderTotalInfo['total_convenience_fee_ti']) currency=$objOrderCurrency}</span>
{/if}
</td>
</tr>
{/if}

View File

@@ -326,57 +326,39 @@
{assign var=total_standard_products_tax_incl value=($order->getTotalProductsWithTaxes(false, false, Product::SELLING_PREFERENCE_STANDALONE) + $order->getTotalProductsWithTaxes(false, false, Product::SELLING_PREFERENCE_HOTEL_STANDALONE))}
{assign var=total_standard_products_tax_excl value=($order->getTotalProductsWithoutTaxes(false, false, Product::SELLING_PREFERENCE_STANDALONE) + $order->getTotalProductsWithoutTaxes(false, false, Product::SELLING_PREFERENCE_HOTEL_STANDALONE))}
{if isset($cart_htl_data) && $cart_htl_data}
{if $priceDisplay && $use_tax && $room_price_tax_excl}
<tr>
<td>{l s='Total rooms cost (tax excl.)'}</td>
<td class="text-right">
<span class="price">{displayWtPriceWithCurrency price=($room_price_tax_excl + $room_services_price_tax_excl - $total_convenience_fee_te) currency=$currency}</span>
</td>
</tr>
{else}
<tr>
<td>{l s='Total Rooms Cost'} {if $use_tax}{l s='(tax incl.)'}{/if} </td>
<td class="text-right">
<span class="price">{displayWtPriceWithCurrency price=($room_price_tax_incl + $room_services_price_tax_incl - $total_convenience_fee_ti) currency=$currency}</span>
</td>
</tr>
{/if}
{/if}
{if (isset($hotel_service_products) && $hotel_service_products) || (isset($standalone_service_products) && $standalone_service_products)}
{if $priceDisplay && $use_tax}
<tr class="item">
<td>
<strong>{l s='Total products cost (tax excl.)'}</strong>
</td>
<td class="text-right">
<span>{displayWtPriceWithCurrency price=$total_standard_products_tax_excl currency=$currency}</span>
</td>
</tr>
{else}
<tr class="item">
<td>
<strong>{l s='Total products cost'} {if $use_tax}{l s='(tax incl.)'}{/if} </strong>
</td>
<td class="text-right">
<span>{displayWtPriceWithCurrency price=$total_standard_products_tax_incl currency=$currency}</span>
</td>
</tr>
{/if}
{/if}
{if $priceDisplay && $use_tax && $total_convenience_fee_te}
<tr>
<td>{l s='Total Convenience Fees (tax excl.)'}</td>
<td>{l s='Total rooms cost'} {if $use_taxes && $display_tax_label == 1}{if $priceDisplay == 1}{l s='(tax excl.)'}{elseif $priceDisplay == 0}{l s='(tax incl.)'}{/if} {/if}</td>
<td class="text-right">
<span class="price">{displayWtPriceWithCurrency price=$total_convenience_fee_te currency=$currency}</span>
{if $priceDisplay && $use_tax}
<span class="price">{displayWtPriceWithCurrency price=($room_price_tax_excl + $room_services_price_tax_excl - $total_convenience_fee_te) currency=$currency}</span>
{else}
<span class="price">{displayWtPriceWithCurrency price=($room_price_tax_incl + $room_services_price_tax_incl - $total_convenience_fee_ti) currency=$currency}</span>
{/if}
</td>
</tr>
{else if $total_convenience_fee_ti}
<tr>
<td>{l s='Total Convenience Fees (tax incl.)'}</td>
{/if}
{if (isset($hotel_service_products) && $hotel_service_products) || (isset($standalone_service_products) && $standalone_service_products)}
<tr class="item">
<td>{l s='Total products cost'} {if $use_taxes && $display_tax_label == 1}{if $priceDisplay == 1}{l s='(tax excl.)'}{elseif $priceDisplay == 0}{l s='(tax incl.)'}{/if}{/if}</td>
<td class="text-right">
<span class="price">{displayWtPriceWithCurrency price=$total_convenience_fee_ti currency=$currency}</span>
{if $priceDisplay && $use_tax}
<span>{displayWtPriceWithCurrency price=$total_standard_products_tax_excl currency=$currency}</span>
{else}
<span>{displayWtPriceWithCurrency price=$total_standard_products_tax_incl currency=$currency}</span>
{/if}
</td>
</tr>
{/if}
{if $total_convenience_fee_te || $total_convenience_fee_te}
<tr class="item">
<td>{l s='Total Convenience Fees'} {if $use_taxes && $display_tax_label == 1}{if $priceDisplay == 1}{l s='(tax excl.)'}{elseif $priceDisplay == 0}{l s='(tax incl.)'}{/if}{/if}</td>
<td class="text-right">
{if $priceDisplay && $use_tax}
<span class="price">{displayWtPriceWithCurrency price=$total_convenience_fee_te currency=$currency}</span>
{else}
<span class="price">{displayWtPriceWithCurrency price=$total_convenience_fee_ti currency=$currency}</span>
{/if}
</td>
</tr>
{/if}
@@ -743,57 +725,39 @@
{assign var=total_tax_without_discount value=(($room_price_tax_incl - $room_price_tax_excl) + ($room_services_price_tax_incl - $room_services_price_tax_excl) + ($total_standard_products_tax_incl - $total_standard_products_tax_excl))}
{if isset($cart_htl_data) && $cart_htl_data}
{if $priceDisplay && $use_tax && $room_price_tax_excl}
<tr>
<td>{l s='Total rooms cost (tax excl.)'}</td>
<td class="text-right">
<span class="price">{displayWtPriceWithCurrency price=($room_price_tax_excl + $room_services_price_tax_excl - $total_convenience_fee_te) currency=$currency}</span>
</td>
</tr>
{else}
<tr>
<td>{l s='Total Rooms Cost'} {if $use_tax}{l s='(tax incl.)'}{/if} </td>
<td class="text-right">
<span class="price">{displayWtPriceWithCurrency price=($room_price_tax_incl + $room_services_price_tax_incl - $total_convenience_fee_ti) currency=$currency}</span>
</td>
</tr>
{/if}
{/if}
{if (isset($hotel_service_products) && $hotel_service_products) || (isset($standalone_service_products) && $standalone_service_products)}
{if $priceDisplay && $use_tax}
<tr class="item">
<td>
<strong>{l s='Total products cost (tax excl.)'}</strong>
</td>
<td class="text-right">
<span>{displayWtPriceWithCurrency price=$total_standard_products_tax_excl currency=$currency}</span>
</td>
</tr>
{else}
<tr class="item">
<td>
<strong>{l s='Total products cost'} {if $use_tax}{l s='(tax incl.)'}{/if} </strong>
</td>
<td class="text-right">
<span>{displayWtPriceWithCurrency price=$total_standard_products_tax_incl currency=$currency}</span>
</td>
</tr>
{/if}
{/if}
{if $priceDisplay && $use_tax && $total_convenience_fee_te}
<tr>
<td>{l s='Total Convenience Fees (tax excl.)'}</td>
<td>{l s='Total rooms cost'} {if $use_taxes && $display_tax_label == 1}{if $priceDisplay == 1}{l s='(tax excl.)'}{elseif $priceDisplay == 0}{l s='(tax incl.)'}{/if} {/if}</td>
<td class="text-right">
<span class="price">{displayWtPriceWithCurrency price=$total_convenience_fee_te currency=$currency}</span>
{if $priceDisplay && $use_tax}
<span class="price">{displayWtPriceWithCurrency price=($room_price_tax_excl + $room_services_price_tax_excl - $total_convenience_fee_te) currency=$currency}</span>
{else}
<span class="price">{displayWtPriceWithCurrency price=($room_price_tax_incl + $room_services_price_tax_incl - $total_convenience_fee_ti) currency=$currency}</span>
{/if}
</td>
</tr>
{else if $total_convenience_fee_ti}
<tr>
<td>{l s='Total Convenience Fees (tax incl.)'}</td>
{/if}
{if (isset($hotel_service_products) && $hotel_service_products) || (isset($standalone_service_products) && $standalone_service_products)}
<tr class="item">
<td>{l s='Total products cost'} {if $use_taxes && $display_tax_label == 1}{if $priceDisplay == 1}{l s='(tax excl.)'}{elseif $priceDisplay == 0}{l s='(tax incl.)'}{/if}{/if}</td>
<td class="text-right">
<span class="price">{displayWtPriceWithCurrency price=$total_convenience_fee_ti currency=$currency}</span>
{if $priceDisplay && $use_tax}
<span>{displayWtPriceWithCurrency price=$total_standard_products_tax_excl currency=$currency}</span>
{else}
<span>{displayWtPriceWithCurrency price=$total_standard_products_tax_incl currency=$currency}</span>
{/if}
</td>
</tr>
{/if}
{if $total_convenience_fee_te || $total_convenience_fee_te}
<tr class="item">
<td>{l s='Total Convenience Fees'} {if $use_taxes && $display_tax_label == 1}{if $priceDisplay == 1}{l s='(tax excl.)'}{elseif $priceDisplay == 0}{l s='(tax incl.)'}{/if}{/if}</td>
<td class="text-right">
{if $priceDisplay && $use_tax}
<span class="price">{displayWtPriceWithCurrency price=$total_convenience_fee_te currency=$currency}</span>
{else}
<span class="price">{displayWtPriceWithCurrency price=$total_convenience_fee_ti currency=$currency}</span>
{/if}
</td>
</tr>
{/if}