mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-18 10:16:49 +00:00
Will now look for new field "transaction_type_type"
This commit is contained in:
@@ -165,55 +165,51 @@ class TransactionJournal extends Model
|
||||
}
|
||||
|
||||
/**
|
||||
* TODO zo even aanpassen naar nieuwe veldnaam.
|
||||
* @return bool
|
||||
*/
|
||||
public function isDeposit()
|
||||
{
|
||||
if (!is_null($this->type)) {
|
||||
return $this->type == TransactionType::DEPOSIT;
|
||||
if (!is_null($this->transaction_type_type)) {
|
||||
return $this->transaction_type_type == TransactionType::DEPOSIT;
|
||||
}
|
||||
|
||||
return $this->transactionType->isDeposit();
|
||||
}
|
||||
|
||||
/**
|
||||
* TODO zo even aanpassen naar nieuwe veldnaam.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function isOpeningBalance()
|
||||
{
|
||||
if (!is_null($this->type)) {
|
||||
return $this->type == TransactionType::OPENING_BALANCE;
|
||||
if (!is_null($this->transaction_type_type)) {
|
||||
return $this->transaction_type_type == TransactionType::OPENING_BALANCE;
|
||||
}
|
||||
|
||||
return $this->transactionType->isOpeningBalance();
|
||||
}
|
||||
|
||||
/**
|
||||
* TODO zo even aanpassen naar nieuwe veldnaam.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function isTransfer()
|
||||
{
|
||||
if (!is_null($this->type)) {
|
||||
return $this->type == TransactionType::TRANSFER;
|
||||
if (!is_null($this->transaction_type_type)) {
|
||||
return $this->transaction_type_type == TransactionType::TRANSFER;
|
||||
}
|
||||
|
||||
return $this->transactionType->isTransfer();
|
||||
}
|
||||
|
||||
/**
|
||||
* TODO zo even aanpassen naar nieuwe veldnaam.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function isWithdrawal()
|
||||
{
|
||||
if (!is_null($this->type)) {
|
||||
return $this->type == TransactionType::WITHDRAWAL;
|
||||
if (!is_null($this->transaction_type_type)) {
|
||||
return $this->transaction_type_type == TransactionType::WITHDRAWAL;
|
||||
}
|
||||
|
||||
return $this->transactionType->isWithdrawal();
|
||||
|
Reference in New Issue
Block a user