Partner Producthchange WIP 2024-07-23
This commit is contained in:
@@ -346,6 +346,8 @@ class BillingController extends mfBaseController {
|
||||
$total_days = $last_of_period->diff($first_of_period)->format("%a") + 1;
|
||||
$period_days = ($end_date->diff($start_date)->format("%a")) + 1;
|
||||
|
||||
if($period_days < 0) continue; // don't bill for negative time range
|
||||
|
||||
$pc = $period_days / $total_days * 100;
|
||||
$price = round($contract->price / 100 * $pc, 4);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user