TDoG-Skin/app/Services/Facades/Option.php
2024-08-17 19:13:54 +08:00

24 lines
435 B
PHP
Executable File

<?php
namespace App\Services\Facades;
use App\Services\OptionForm;
use Illuminate\Support\Facades\Facade;
class Option extends Facade
{
protected static function getFacadeAccessor()
{
return 'options';
}
public static function form(string $id, string $title, $callback): OptionForm
{
$form = new OptionForm($id, $title);
call_user_func($callback, $form);
return $form;
}
}