trying to add sorting to extraction stuff

This commit is contained in:
2021-03-08 22:25:42 +09:00
parent 94a30377f5
commit cc5bcbb97d

View File

@@ -9,6 +9,9 @@ use Log;
use Carbon\Carbon;
use Khill\Lavacharts\Lavacharts;
use Auth;
//Collection Stuff
use Illuminate\Support\Collection;
use Illuminate\Support\Str;
//Library Helpers
use App\Library\Helpers\LookupHelper;
@@ -128,6 +131,12 @@ class MiningTaxesController extends Controller
]);
}
//Sort extractions by arrival time
$structuresCollection = collect($structures);
$sorted = $structuresCollection->sortBy('arrival_time');
$structures = $sorted->all()->values();
dd($structures);
/**
* Create a 3 month calendar for the past, current, and future extractions
*/