From da4457eba6ec8df1dc92afe830dcf15a3fa3b4c7 Mon Sep 17 00:00:00 2001 From: drkthunder02 Date: Tue, 25 May 2021 01:17:17 +0900 Subject: [PATCH] testing new mining tax --- app/Http/Controllers/Test/TestController.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/app/Http/Controllers/Test/TestController.php b/app/Http/Controllers/Test/TestController.php index 8dfb65b29..4d53c9684 100644 --- a/app/Http/Controllers/Test/TestController.php +++ b/app/Http/Controllers/Test/TestController.php @@ -80,6 +80,14 @@ class TestController extends Controller //Get the users from the database $mains = User::all(); + //Pluck all the users from the database of ledgers to determine if they are mains or alts. + $mains = Ledger::where([ + 'character_id' => $main->character_id, + 'invoiced' => 'Yes', + ])->where('last_updated', '>', Carbon::now()->subMonths(3))->pluck('character_id')->get(); + + dd($mains) + /** * For each of the users, let's determine if there are any ledgers, * then determine if there are any alts and ledgers associated with the alts.