mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-09-29 18:20:01 +00:00
Replace enum
This commit is contained in:
@@ -84,7 +84,7 @@ class BoxController extends Controller
|
||||
/** @var GroupCollectorInterface $collector */
|
||||
$collector = app(GroupCollectorInterface::class);
|
||||
$collector->setRange($start, $end)
|
||||
->setTypes([TransactionType::DEPOSIT])
|
||||
->setTypes([TransactionTypeEnum::DEPOSIT->value])
|
||||
;
|
||||
$set = $collector->getExtractedJournals();
|
||||
|
||||
|
@@ -242,7 +242,7 @@ class ReconcileController extends Controller
|
||||
foreach ($array as $journal) {
|
||||
$inverse = false;
|
||||
|
||||
if (TransactionType::DEPOSIT === $journal['transaction_type_type']) {
|
||||
if (TransactionTypeEnum::DEPOSIT->value === $journal['transaction_type_type']) {
|
||||
$inverse = true;
|
||||
}
|
||||
// transfer to this account? then positive amount:
|
||||
@@ -251,7 +251,7 @@ class ReconcileController extends Controller
|
||||
}
|
||||
|
||||
// opening balance into account? then positive amount:
|
||||
if (TransactionType::OPENING_BALANCE === $journal['transaction_type_type']
|
||||
if (TransactionTypeEnum::OPENING_BALANCE->value === $journal['transaction_type_type']
|
||||
&& $account->id === $journal['destination_account_id']) {
|
||||
$inverse = true;
|
||||
}
|
||||
|
Reference in New Issue
Block a user