adrema/app/Form/Presenters/GroupPresenter.php

23 lines
327 B
PHP
Raw Normal View History

2024-02-09 23:22:49 +01:00
<?php
namespace App\Form\Presenters;
use App\Group;
use Carbon\Carbon;
class GroupPresenter extends Presenter
{
/**
* @param ?int $value
*/
public function present($value): string
{
if (!$value) {
return '';
}
return Group::find($value)?->display() ?: '';
}
}