Update edit.blade.php
This commit is contained in:
parent
833e04b557
commit
0597831dc1
|
|
@ -3,12 +3,15 @@
|
|||
<x-card.card class="mx-auto max-w-2xl">
|
||||
<x-card.heading>
|
||||
Edit Entry #{{ $entry->id }}
|
||||
|
||||
<x-slot:right_side>
|
||||
<x-delete-resource-modal action="{{route('admin.entries.destroy',$entry->id)}}" title="Delete entry #{{ $entry->id }}">
|
||||
Confirm you would like to delete entry #{{$entry->id}} by {{$entry->student->full_name()}} on {{$entry->audition->name}}.
|
||||
</x-delete-resource-modal>
|
||||
</x-slot:right_side>
|
||||
@if($entry->scoreSheets()->count() === 0)
|
||||
<x-slot:right_side>
|
||||
<x-delete-resource-modal action="{{route('admin.entries.destroy',$entry->id)}}"
|
||||
title="Delete entry #{{ $entry->id }}">
|
||||
Confirm you would like to delete entry #{{$entry->id}} by {{$entry->student->full_name()}}
|
||||
on {{$entry->audition->name}}.
|
||||
</x-delete-resource-modal>
|
||||
</x-slot:right_side>
|
||||
@endif
|
||||
|
||||
</x-card.heading>
|
||||
<x-form.form id='entryEditForm' method="PATCH" action="/admin/entries/{{ $entry->id }}">
|
||||
|
|
@ -18,12 +21,13 @@
|
|||
<x-slot:label>Student</x-slot:label>
|
||||
@php($student = $students->find($entry->student_id))
|
||||
|
||||
<option value="{{ $student->id }}" {{ ($student->id == $entry->student_id ? 'selected':'') }}>
|
||||
{{ $student->full_name(true) }} - {{ $student->school->name }} (Grade {{ $student->grade }})
|
||||
</option>
|
||||
<option value="{{ $student->id }}" {{ ($student->id == $entry->student_id ? 'selected':'') }}>
|
||||
{{ $student->full_name(true) }} - {{ $student->school->name }} (Grade {{ $student->grade }})
|
||||
</option>
|
||||
</x-form.select>
|
||||
@else
|
||||
<p class="col-span-3 mt-4 ">{{ $entry->student->full_name() }} - {{ $entry->student->school->name }}</p>
|
||||
<p class="col-span-3 mt-4 ">{{ $entry->student->full_name() }}
|
||||
- {{ $entry->student->school->name }}</p>
|
||||
@endif
|
||||
|
||||
@if(! Seat::where('entry_id', $entry->id)->exists())
|
||||
|
|
@ -35,7 +39,7 @@
|
|||
{{ $audition->name }}
|
||||
</option>
|
||||
@endforeach
|
||||
</x-form.select>
|
||||
</x-form.select>
|
||||
@else
|
||||
<p class="col-span-3 mt-4 ">{{ $entry->audition->name }}</p>
|
||||
@endif
|
||||
|
|
@ -44,12 +48,12 @@
|
|||
<div class="col-span-6 align-top">
|
||||
<x-form.checkbox name="for_seating"
|
||||
label="Enter for {{ auditionSetting('auditionAbbreviation') }}"
|
||||
:checked="$entry->for_seating" />
|
||||
:checked="$entry->for_seating"/>
|
||||
</div>
|
||||
<div class="col-span-6 align-top">
|
||||
<x-form.checkbox name="for_advancement"
|
||||
label="Enter for {{ auditionSetting('advanceTo') }}"
|
||||
:checked="$entry->for_advancement" />
|
||||
:checked="$entry->for_advancement"/>
|
||||
</div>
|
||||
@else
|
||||
<input type="hidden" name="for_seating" value="on">
|
||||
|
|
@ -80,7 +84,8 @@
|
|||
<form method="POST" action="{{ route('scores.destroy',['score'=>$score->id]) }}">
|
||||
@csrf
|
||||
@method('DELETE')
|
||||
<button type="submit" class="text-red-500 font-semibold pt-5">Invalid Score - Delete</button>
|
||||
<button type="submit" class="text-red-500 font-semibold pt-5">Invalid Score - Delete
|
||||
</button>
|
||||
@endif
|
||||
</div>
|
||||
@endforeach
|
||||
|
|
|
|||
Loading…
Reference in New Issue