Skip to content

Commit

Permalink
Merge pull request rrze-mmz#65 from rrze-mmz/61-missing-updated-dark-…
Browse files Browse the repository at this point in the history
…mode-layout-for-classes-on-re-order-clips-page

Fix reorder error layout by adding the column
  • Loading branch information
stefanosgeo authored Feb 28, 2024
2 parents d56ab4c + 8a77150 commit 56ccade
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
2 changes: 1 addition & 1 deletion app/Http/Controllers/Backend/SeriesClipsController.php
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ public function remove(Clip $clip): RedirectResponse

public function listClips(Series $series): Factory|View|Application
{
$clips = Clip::select('id', 'title', 'slug', 'episode')
$clips = Clip::select('id', 'title', 'slug', 'episode', 'is_public')
->where('series_id', $series->id)
->addSelect(
[
Expand Down
12 changes: 9 additions & 3 deletions resources/views/components/list-clips.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -222,8 +222,14 @@ class="focus:outline-none text-white text-sm py-1.5 px-5 rounded-md bg-blue-700
<div class="w-1/12">
@if ($reorder)
<label>
<input class="w-1/2" type="number" name="episodes[{{$clip->id}}]"
value="{{$clip->episode}}">
<input class="w-1/2 dark:text-black" type="number"
name="episodes[{{$clip->id}}]"
value="{{$loop->index + 1}}"
>
<div class="col-start-2 col-end-6">
<p class="mt-2 w-full text-sm text-green-500 dark:text-green-200">
Actual episode: {{ $clip->episode }}</p>
</div>
</label>
@error('episodes')
<p class="mt-2 w-full text-xs text-red-500">{{ $message }}</p>
Expand Down Expand Up @@ -308,7 +314,7 @@ class="mb-4 w-full rounded bg-gray-200 dark:bg-slate-800 p-5 text-center text-2x
</div>
@endforelse
@if($reorder)
<div class="pt-10">
<div class="pt-10 space-x-4">
<x-button class="bg-blue-600 hover:bg-blue-700">
Reorder Series clips
</x-button>
Expand Down

0 comments on commit 56ccade

Please sign in to comment.