mirror of
https://github.com/prurigro/hypothetical.git
synced 2024-11-12 12:06:38 -05:00
Fix dropdown selects that aren't boolean, and only convert the select value to 1/0 if it's also boolean
This commit is contained in:
parent
0e7f8ce4f4
commit
5319d7328b
1 changed files with 7 additions and 2 deletions
|
@ -72,10 +72,15 @@
|
|||
@endphp
|
||||
@endif
|
||||
|
||||
@if(gettype($select_title))
|
||||
@if(gettype($select_title) == 'boolean')
|
||||
@php
|
||||
$select_title = $select_title ? 'true' : 'false';
|
||||
@endphp
|
||||
@endif
|
||||
|
||||
@if(gettype($select_value) == 'boolean')
|
||||
@php
|
||||
$select_value = $select_value ? 1 : 0;
|
||||
$select_title = $select_title ? 'true' : 'false';
|
||||
@endphp
|
||||
@endif
|
||||
|
||||
|
|
Loading…
Reference in a new issue