mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-08 05:34:30 -04:00
Bug fixes
This commit is contained in:
parent
9135177c1f
commit
c7a92e4862
@ -103,6 +103,17 @@ class ReportController extends BaseController
|
|||||||
if ($enableChart) {
|
if ($enableChart) {
|
||||||
$params = array_merge($params, self::generateChart($groupBy, $startDate, $endDate));
|
$params = array_merge($params, self::generateChart($groupBy, $startDate, $endDate));
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
$params['columns'] = [];
|
||||||
|
$params['displayData'] = [];
|
||||||
|
$params['reportTotals'] = [
|
||||||
|
'amount' => [],
|
||||||
|
'balance' => [],
|
||||||
|
'paid' => [],
|
||||||
|
];
|
||||||
|
$params['labels'] = [];
|
||||||
|
$params['datasets'] = [];
|
||||||
|
$params['scaleStepWidth'] = 100;
|
||||||
}
|
}
|
||||||
|
|
||||||
return View::make('reports.chart_builder', $params);
|
return View::make('reports.chart_builder', $params);
|
||||||
|
@ -847,7 +847,7 @@ class Utils
|
|||||||
|
|
||||||
$today = new DateTime('now');
|
$today = new DateTime('now');
|
||||||
$datePaid = DateTime::createFromFormat('Y-m-d', $date);
|
$datePaid = DateTime::createFromFormat('Y-m-d', $date);
|
||||||
$interval = $today->diff($date);
|
$interval = $today->diff($datePaid);
|
||||||
|
|
||||||
return $interval->y == 0;
|
return $interval->y == 0;
|
||||||
}
|
}
|
||||||
|
@ -70,6 +70,7 @@ class ActivityRepository
|
|||||||
->leftJoin('invoices', 'invoices.id', '=', 'activities.invoice_id')
|
->leftJoin('invoices', 'invoices.id', '=', 'activities.invoice_id')
|
||||||
->leftJoin('payments', 'payments.id', '=', 'activities.payment_id')
|
->leftJoin('payments', 'payments.id', '=', 'activities.payment_id')
|
||||||
->leftJoin('credits', 'credits.id', '=', 'activities.credit_id')
|
->leftJoin('credits', 'credits.id', '=', 'activities.credit_id')
|
||||||
|
->where('clients.account_id', '=', Auth::user()->account_id)
|
||||||
->where('clients.public_id', '=', $clientPublicId)
|
->where('clients.public_id', '=', $clientPublicId)
|
||||||
->where('contacts.is_primary', '=', 1)
|
->where('contacts.is_primary', '=', 1)
|
||||||
->whereNull('contacts.deleted_at')
|
->whereNull('contacts.deleted_at')
|
||||||
|
Loading…
x
Reference in New Issue
Block a user