Merge pull request #1989 from Azhar-Webkul/gli-3325
Fixed: Order flow,dashboard,Tax and Price issues.
This commit is contained in:
@@ -147,7 +147,7 @@
|
||||
{if ($can_edit)}
|
||||
<td class="product_action center">
|
||||
<div class="btn-group pull-right">
|
||||
{if isset($refundReqBookings) && $refundReqBookings && $data.id|in_array:$refundReqBookings && ($data.id_status == $ROOM_STATUS_CANCELLED || $data.id_status == $ROOM_STATUS_NO_SHOW)}
|
||||
{if $data.id_status == $ROOM_STATUS_CANCELLED || $data.id_status == $ROOM_STATUS_NO_SHOW}
|
||||
<button href="#" class="btn btn-default delete_room_line">
|
||||
<i class="icon-trash"></i>
|
||||
{l s='Delete'}
|
||||
|
||||
@@ -64,7 +64,7 @@
|
||||
</div>
|
||||
</div>
|
||||
{else}
|
||||
<p>
|
||||
<p class="form-control-static">
|
||||
{l s='No group created'}
|
||||
</p>
|
||||
{/if}
|
||||
@@ -503,7 +503,7 @@ class OrderDetailCore extends ObjectModel
|
||||
$this->product_price_calculation_method,
|
||||
$cartServiceItem['date_from'],
|
||||
$cartServiceItem['date_to']
|
||||
);
|
||||
);
|
||||
$itemQuantity = (isset($cartServiceItem['quantity']) ? $cartServiceItem['quantity'] : 0) * $itemNumDays;
|
||||
$quantity += $itemQuantity;
|
||||
$totalPriceTaxExcl += $itemQuantity * (isset($cartServiceItem['unit_price_tax_excl']) ? $cartServiceItem['unit_price_tax_excl'] : 0);
|
||||
@@ -527,7 +527,7 @@ class OrderDetailCore extends ObjectModel
|
||||
if (isset($quantity) && isset($unit_price_tax_excl)) {
|
||||
foreach ($this->tax_calculator->getTaxesAmount($unit_price_tax_excl) as $id_tax => $amount) {
|
||||
|
||||
$total_amount = Tools::processPriceRounding($amount, $quantity, $order->round_type, $order->round_mode);
|
||||
$total_amount = $amount * $quantity;
|
||||
|
||||
$values .= '('.(int)$order->id.','.(int)$this->id.',0,0,'.(int)$id_tax.','.(float)$amount.','.(float)$total_amount.',NOW()),';
|
||||
}
|
||||
@@ -561,7 +561,7 @@ class OrderDetailCore extends ObjectModel
|
||||
|
||||
foreach ($this->tax_calculator->getTaxesAmount($this->unit_price_tax_excl) as $id_tax => $amount) {
|
||||
|
||||
$total_amount = Tools::processPriceRounding($amount, $this->product_quantity, $order->round_type, $order->round_mode);
|
||||
$total_amount = $amount * $this->product_quantity;
|
||||
|
||||
$values .= '('.(int)$order->id.','.(int)$this->id.',0,0,'.(int)$id_tax.','.(float)$amount.','.(float)$total_amount.',NOW()),';
|
||||
}
|
||||
|
||||
@@ -255,7 +255,6 @@ class DashProducts extends Module
|
||||
hbd.`id_product`,
|
||||
hbd.`room_type_name` AS `product_name`,
|
||||
COUNT(hbd.`id_room`) AS `total`,
|
||||
hbd.`total_price_tax_excl` AS `price`,
|
||||
SUM(hbd.`total_price_tax_excl`) AS `sales`
|
||||
FROM `'._DB_PREFIX_.'htl_booking_detail` hbd
|
||||
LEFT JOIN `'._DB_PREFIX_.'orders` o ON (o.`id_order` = hbd.`id_order`)
|
||||
@@ -285,8 +284,6 @@ class DashProducts extends Module
|
||||
$img = ImageManager::thumbnail($path_to_image, 'product_mini_'.$product_obj->id.'.'.$this->context->controller->imageType, 45, $this->context->controller->imageType);
|
||||
}
|
||||
|
||||
$productPrice = $product['price'];
|
||||
|
||||
$body[] = array(
|
||||
array(
|
||||
'id' => 'product',
|
||||
@@ -297,8 +294,7 @@ class DashProducts extends Module
|
||||
'id' => 'product',
|
||||
'value' => '<a href="'.$this->context->link->getAdminLink('AdminProducts', true).
|
||||
'&id_product='.$product_obj->id.'&updateproduct" target="_blank">'.
|
||||
Tools::htmlentitiesUTF8($product['product_name']).'</a>'.
|
||||
'<br/>'.Tools::displayPrice($productPrice),
|
||||
Tools::htmlentitiesUTF8($product['product_name']).'</a>',
|
||||
'class' => 'text-center'
|
||||
),
|
||||
array(
|
||||
|
||||
Reference in New Issue
Block a user