diff --git a/app/Library/FinanceHelper.php b/app/Library/FinanceHelper.php index 70720a4e0..9d3b6c3e3 100644 --- a/app/Library/FinanceHelper.php +++ b/app/Library/FinanceHelper.php @@ -140,7 +140,7 @@ class FinanceHelper { if($journal['ref_type'] == 'player_donation') { //if we don't find the journal entry, add the journal entry to the database - if(!PlayerDonationJournal::where('id', $journal['id'])->exists()) { + if(!PlayerDonationJournal::where(['id' => $journal['id']])->exists()) { $entry = new CorpJournal; $entry->id = $journal['id']; $entry->corporation_id = $corpId; @@ -179,7 +179,7 @@ class FinanceHelper { } } else { //if we don't find the journal entry, add the journal entry to the database - if(!CorpJournal::where('id', $journal['id'])->exists()) { + if(!CorpJournal::where(['id' => $journal['id']])->exists()) { $entry = new CorpJournal; $entry->id = $journal['id']; $entry->corporation_id = $corpId; diff --git a/app/Models/Corporation/CorpJournal.php b/app/Models/Corporation/CorpJournal.php index d3dd88423..3c8f3a788 100644 --- a/app/Models/Corporation/CorpJournal.php +++ b/app/Models/Corporation/CorpJournal.php @@ -22,6 +22,7 @@ class CorpJournal extends Model * @var array */ protected $fillable = [ + 'id', 'corporation_id', 'division', 'amount', diff --git a/app/Models/Finances/PlayerDonationJournal.php b/app/Models/Finances/PlayerDonationJournal.php index d22aa660f..3260868d1 100644 --- a/app/Models/Finances/PlayerDonationJournal.php +++ b/app/Models/Finances/PlayerDonationJournal.php @@ -22,6 +22,7 @@ class PlayerDonationJournal extends Model * @var array */ protected $fillable = [ + 'id', 'corporation_id', 'division', 'amount',