Fix incorrect percentage calculation
This commit is contained in:
1 parent
4e55d6f5f9
commit
40f6fc9976
1 file changed
+1
-1
@@ -127,7 +127,7 @@ class AjaxContingentController extends ActionController
|
|||||||
$paxAvaiable = $event->getAvailable();
|
$paxAvaiable = $event->getAvailable();
|
||||||
|
|
||||||
if ($paxTotal > 0) {
|
if ($paxTotal > 0) {
|
||||||
$percentageBooked = round($paxAvaiable / $paxTotal * 100);
|
$percentageBooked = 100 - round($paxAvaiable / $paxTotal * 100);
|
||||||
} else {
|
} else {
|
||||||
$percentageBooked = 100;
|
$percentageBooked = 100;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user