new widget structure

This commit is contained in:
denisdulici
2019-12-31 02:20:10 +03:00
parent 8c6ca5e5fb
commit 71c5caf264
44 changed files with 333 additions and 502 deletions

View File

@@ -30,15 +30,19 @@ class TotalIncome extends Widget
}
$totals = [
'current' => $current,
'open' => money($open, setting('default.currency'), true),
'overdue' => money($overdue, setting('default.currency'), true),
'progress' => $progress,
'current' => $current,
'open' => money($open, setting('default.currency'), true),
'overdue' => money($overdue, setting('default.currency'), true),
'progress' => $progress,
];
return view('widgets.total_income', [
'config' => (object) $this->config,
return $this->view('widgets.total_income', [
'totals' => $totals,
]);
}
public function getDefaultName()
{
return trans('widgets.total_income');
}
}