File tree Expand file tree Collapse file tree 2 files changed +27
-14
lines changed
resources/views/livewire/media Expand file tree Collapse file tree 2 files changed +27
-14
lines changed Original file line number Diff line number Diff line change @@ -41,6 +41,11 @@ private function getType(): ?MediaTypeName
41
41
return $ this ->type ? MediaTypeName::from ($ this ->type ) : null ;
42
42
}
43
43
44
+ public function disableFilters ()
45
+ {
46
+ return $ this ->list === 'in-progress ' ;
47
+ }
48
+
44
49
private function query (): Collection
45
50
{
46
51
return match ($ this ->list ) {
Original file line number Diff line number Diff line change @@ -12,21 +12,29 @@ class="select select-sm select-ghost"
12
12
<option value =" backlog" >Backlog</option >
13
13
</select >
14
14
15
- <select wire:model.live =" year" class =" select select-sm select-ghost" >
16
- <option value =" " >All Years</option >
17
- @foreach ($years as $year )
18
- <option value =" {{ $year } }" >{{ $year } } </option >
19
- @endforeach
20
- </select >
15
+ <select
16
+ wire:model.live =" year"
17
+ class =" select select-sm select-ghost"
18
+ @if ($this -> disableFilters () ) disabled @endif
19
+ >
20
+ <option value =" " >All Years</option >
21
+ @foreach ($years as $year )
22
+ <option value =" {{ $year } }" >{{ $year } } </option >
23
+ @endforeach
24
+ </select >
21
25
22
- <select wire:model.live =" type" class =" select select-sm select-ghost" >
23
- <option value =" " >All Types</option >
24
- @foreach ($mediaTypes as $type )
25
- <option value =" {{ $type -> value } }" >
26
- {{ $type -> displayName () } }
27
- </option >
28
- @endforeach
29
- </select >
26
+ <select
27
+ wire:model.live =" type"
28
+ class =" select select-sm select-ghost"
29
+ @if ($this -> disableFilters () ) disabled @endif
30
+ >
31
+ <option value =" " >All Types</option >
32
+ @foreach ($mediaTypes as $type )
33
+ <option value =" {{ $type -> value } }" >
34
+ {{ $type -> displayName () } }
35
+ </option >
36
+ @endforeach
37
+ </select >
30
38
</form >
31
39
32
40
<div class =" my-6" >
You can’t perform that action at this time.
0 commit comments