Various code optimalisations.

This commit is contained in:
James Cole
2018-07-08 07:59:58 +02:00
parent 10492e3b2f
commit 2f2f907ffe
59 changed files with 309 additions and 279 deletions

View File

@@ -85,7 +85,6 @@ class TransactionController extends Controller
$types = config('firefly.transactionTypesByWhat.' . $what);
$page = (int)$request->get('page');
$pageSize = (int)Preferences::get('listPageSize', 50)->data;
$path = route('transactions.index', [$what]);
if (null === $start) {
$start = session('start');
$end = session('end');
@@ -183,8 +182,8 @@ class TransactionController extends Controller
$order = 0;
$ids = array_unique($ids);
foreach ($ids as $id) {
$journal = $this->repository->find((int)$id);
if ($journal && $journal->date->isSameDay($date)) {
$journal = $this->repository->findNull((int)$id);
if (null !== $journal && $journal->date->isSameDay($date)) {
$this->repository->setOrder($journal, $order);
++$order;
}