@if($filter['type'] === 'list')
@php
$selectedValues = is_array($filter['value']) ? $filter['value'] : [$filter['value']];
$options = json_decode($filter['options'], true);
$selectedLabels = collect($options)
->whereIn('refid', $selectedValues)
->pluck('value')
->toArray();
@endphp
{{ implode(', ', $selectedLabels) }}
@elseif($filter['type'] === 'free_form_text')
{{ $filter['value'] }}
@elseif($filter['type'] === 'date')
{{ \Carbon\Carbon::parse($filter['value'])->format('n/j/Y') }}
@elseif($filter['type'] === 'record')
@if($filter['value'] === 'empty')
Empty
@else
@endif
@endif