From b94e39b53cdd8bd1fc1f01a53d07ec17a9de2568 Mon Sep 17 00:00:00 2001 From: drkthunder02 Date: Mon, 15 Feb 2021 19:12:02 +0900 Subject: [PATCH] migration --- app/Library/Helpers/FinanceHelper.php | 1 + .../2021_02_14_165934_create_alliance_journal_table.php | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Library/Helpers/FinanceHelper.php b/app/Library/Helpers/FinanceHelper.php index 8a3b68bca..f2eb74b1a 100644 --- a/app/Library/Helpers/FinanceHelper.php +++ b/app/Library/Helpers/FinanceHelper.php @@ -104,6 +104,7 @@ class FinanceHelper { if($found == 0) { $awj = new AllianceWalletJournal; + $awj->id = $entry['id']; $awj->corporation_id = $corpId; $awj->division = $division; if(isset($entry['amount'])) { diff --git a/database/migrations/2021_02_14_165934_create_alliance_journal_table.php b/database/migrations/2021_02_14_165934_create_alliance_journal_table.php index e18b26ff0..8288a142a 100644 --- a/database/migrations/2021_02_14_165934_create_alliance_journal_table.php +++ b/database/migrations/2021_02_14_165934_create_alliance_journal_table.php @@ -15,8 +15,7 @@ class CreateAllianceJournalTable extends Migration { if(!Schema::hasTable('alliance_wallet_journal')) { Schema::create('alliance_wallet_journal', function (Blueprint $table) { - $table->unsignedBigInteger('row')->increments(); - $table->unsignedBigInteger('id')->unique()->default(-1); + $table->unsignedBigInteger('id')->unique(); $table->unsignedBigInteger('corporation_id'); $table->unsignedInteger('division'); $table->decimal('amount', 20, 2)->nullable();