@php $text = '-'; $form = $entry->{$column['from']}; $to = $entry->{$column['to']}; if(isset($column['unit'])){ $form .= $column['unit']; $to .= $column['unit']; } if($entry->{$column['from']} && $entry->{$column['to']}){ $text = $form . '至' . $to; }elseif($entry->{$column['from']} && !($entry->{$column['to']})){ $text = $form . '以上'; }elseif(!($entry->{$column['from']}) && $entry->{$column['to']}){ $text = $to . '以下'; } @endphp
{{$text}}