Child flight calculate
git-svn-id: http://78.47.251.156/svn/dev/sterntours-3@3449 f459cee4-fb09-11de-96c3-f9c5f16c3c76
This commit is contained in:
parent
82650454d2
commit
5d9820f677
2 changed files with 5 additions and 5 deletions
|
|
@ -463,7 +463,7 @@ class BookingController extends Controller
|
||||||
//DISCOUNT
|
//DISCOUNT
|
||||||
if ($singleDiscountPrice !== null)
|
if ($singleDiscountPrice !== null)
|
||||||
{
|
{
|
||||||
$key = ($singleFullPrice - $singleDiscountPrice);
|
$key = intval(($singleFullPrice - $singleDiscountPrice)*100);
|
||||||
if(!empty($tempDiscountHTML[$key])) {
|
if(!empty($tempDiscountHTML[$key])) {
|
||||||
$tempDiscountHTML[$key]['count'] = $tempDiscountHTML[$key]['count'] + $adultCount;
|
$tempDiscountHTML[$key]['count'] = $tempDiscountHTML[$key]['count'] + $adultCount;
|
||||||
$tempDiscountHTML[$key]['value'] = $tempDiscountHTML[$key]['value'] + $discount;
|
$tempDiscountHTML[$key]['value'] = $tempDiscountHTML[$key]['value'] + $discount;
|
||||||
|
|
@ -476,7 +476,7 @@ class BookingController extends Controller
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
if($childDiscount > 0){
|
if($childDiscount > 0){
|
||||||
$key = ($childPrice - $singleChildDiscountPrice);
|
$key = intval(($childPrice - $singleChildDiscountPrice)*100);
|
||||||
if(!empty($tempDiscountHTML[$key])) {
|
if(!empty($tempDiscountHTML[$key])) {
|
||||||
$tempDiscountHTML[$key]['count'] = $tempDiscountHTML[$key]['count'] + $childrenCount;
|
$tempDiscountHTML[$key]['count'] = $tempDiscountHTML[$key]['count'] + $childrenCount;
|
||||||
$tempDiscountHTML[$key]['value'] = $tempDiscountHTML[$key]['value'] + $childDiscount;
|
$tempDiscountHTML[$key]['value'] = $tempDiscountHTML[$key]['value'] + $childDiscount;
|
||||||
|
|
@ -491,7 +491,7 @@ class BookingController extends Controller
|
||||||
}
|
}
|
||||||
if (isset($outPriceInfo))
|
if (isset($outPriceInfo))
|
||||||
{
|
{
|
||||||
$key = ($singleFullPrice - $singleDiscountPrice);
|
$key = intval(($singleFullPrice - $singleDiscountPrice)*100);
|
||||||
if(!empty($outPriceInfo['discount'][$key])) {
|
if(!empty($outPriceInfo['discount'][$key])) {
|
||||||
$outPriceInfo['discount'][$key]['count'] = $outPriceInfo['discount'][$key]['count'] + $adultCount;
|
$outPriceInfo['discount'][$key]['count'] = $outPriceInfo['discount'][$key]['count'] + $adultCount;
|
||||||
$outPriceInfo['discount'][$key]['value'] = $outPriceInfo['discount'][$key]['value'] + $discount;
|
$outPriceInfo['discount'][$key]['value'] = $outPriceInfo['discount'][$key]['value'] + $discount;
|
||||||
|
|
@ -504,7 +504,7 @@ class BookingController extends Controller
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
if($childDiscount > 0){
|
if($childDiscount > 0){
|
||||||
$key = ($childPrice - $singleChildDiscountPrice);
|
$key = intval(($childPrice - $singleChildDiscountPrice)*100);
|
||||||
if(!empty($outPriceInfo['discount'][$key])) {
|
if(!empty($outPriceInfo['discount'][$key])) {
|
||||||
$outPriceInfo['discount'][$key]['count'] = $outPriceInfo['discount'][$key]['count'] + $childrenCount;
|
$outPriceInfo['discount'][$key]['count'] = $outPriceInfo['discount'][$key]['count'] + $childrenCount;
|
||||||
$outPriceInfo['discount'][$key]['value'] = $outPriceInfo['discount'][$key]['value'] + $childDiscount;
|
$outPriceInfo['discount'][$key]['value'] = $outPriceInfo['discount'][$key]['value'] + $childDiscount;
|
||||||
|
|
|
||||||
|
|
@ -287,7 +287,7 @@ final class TravelDate
|
||||||
{
|
{
|
||||||
$price->setEffectivePrice(round(($flightPrice + $price->getPrice() * $currencyFactor) * $profitMargin));
|
$price->setEffectivePrice(round(($flightPrice + $price->getPrice() * $currencyFactor) * $profitMargin));
|
||||||
$price->setEffectiveComfortPrice(round($price->getPriceComfort() * $currencyFactor * $profitMargin));
|
$price->setEffectiveComfortPrice(round($price->getPriceComfort() * $currencyFactor * $profitMargin));
|
||||||
$price->setEffectiveChildPrice(round($price->getPriceChildren() * $currencyFactor * $profitMargin));
|
$price->setEffectiveChildPrice(round(($flightPrice + $price->getPriceChildren() * $currencyFactor) * $profitMargin));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return $this->prices;
|
return $this->prices;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue