Begin setup on audition etude grid
This commit is contained in:
parent
fe0c7ce517
commit
115868bd8a
|
|
@ -0,0 +1,17 @@
|
|||
<?php
|
||||
|
||||
namespace App\Http\Controllers\Admin;
|
||||
|
||||
use App\Http\Controllers\Controller;
|
||||
use App\Models\AuditionedEnsemble;
|
||||
use App\Models\Instrument;
|
||||
|
||||
class AuditionEtudeGridController extends Controller
|
||||
{
|
||||
public function index()
|
||||
{
|
||||
$ensembles = AuditionedEnsemble::all();
|
||||
$instruments = Instrument::orderBy('score_order')->get();
|
||||
return view('admin.audition_etude.grid', compact('ensembles', 'instruments'));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,24 @@
|
|||
<x-layout.admin>
|
||||
@foreach($ensembles as $ensemble)
|
||||
<x-card class="mb-5">
|
||||
<x-slot:header class="bg-brand-600!">{{ $ensemble->name }}</x-slot:header>
|
||||
<x-slot:body class="bg-white border border-brand-600">
|
||||
<x-table>
|
||||
<x-slot:header>
|
||||
<x-table.th></x-table.th>
|
||||
@for($n=1; $n<= $ensemble->set_count; $n++)
|
||||
<x-table.th>Set {{$n}}</x-table.th>
|
||||
@endfor
|
||||
</x-slot:header>
|
||||
<tbody>
|
||||
@foreach($instruments as $instrument)
|
||||
<tr class="outline-1 outline-black/5 dark:outline-white/1">
|
||||
<x-table.td>{{ $instrument->instrument }}</x-table.td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
</x-table>
|
||||
</x-slot:body>
|
||||
</x-card>
|
||||
@endforeach
|
||||
</x-layout.admin>
|
||||
|
|
@ -1,6 +1,7 @@
|
|||
<?php
|
||||
|
||||
use App\Http\Controllers\Admin\AuditionEtudeController;
|
||||
use App\Http\Controllers\Admin\AuditionEtudeGridController;
|
||||
use App\Http\Controllers\Admin\DashboardController;
|
||||
use App\Http\Controllers\Admin\NewsStoryController;
|
||||
use App\Http\Controllers\Admin\SiteDataController;
|
||||
|
|
@ -27,4 +28,5 @@ Route::middleware(['auth'])->prefix('admin')->name('admin.')->group(function ()
|
|||
});
|
||||
Route::resource('/etudes', AuditionEtudeController::class)->names('etudes');
|
||||
Route::resource('/news', NewsStoryController::class)->except(['show'])->names('news');
|
||||
Route::get('/etude-grid', [AuditionEtudeGridController::class, 'index'])->name('etude-grid');
|
||||
});
|
||||
|
|
|
|||
Loading…
Reference in New Issue