Hoschis Vollpfosten First Commit
This commit is contained in:
parent
b52a6fade5
commit
0736ecf29f
112 changed files with 9777 additions and 0 deletions
28
pfosten/app/Http/Controllers/RoundsController.php
Normal file
28
pfosten/app/Http/Controllers/RoundsController.php
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
<?php
|
||||
|
||||
namespace App\Http\Controllers;
|
||||
|
||||
use Illuminate\Http\Request;
|
||||
use App\Season;
|
||||
use App\Round;
|
||||
use DB;
|
||||
|
||||
class RoundsController extends Controller
|
||||
{
|
||||
public function index() {
|
||||
$activeSeason=Season::getCurrent();
|
||||
$rounds =null;
|
||||
|
||||
|
||||
//$rounds=Round::all();
|
||||
|
||||
if ($activeSeason) {
|
||||
$activeSeasonId = Season::getCurrent()->id;
|
||||
$rounds = Round::all()->where('season_id', '=', $activeSeasonId);
|
||||
}
|
||||
|
||||
return view('rounds.index', compact('rounds','activeSeason'));
|
||||
//return view('rounds.index');
|
||||
//return view ('welcome');
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue