App\Services\Html\FormBuilder::checkboxWithLabel PHP Метод

checkboxWithLabel() публичный Метод

public checkboxWithLabel ( $subject, string $fieldName, string $label, array $options = [] ) : string
$fieldName string
$label string
$options array
Результат string
    public function checkboxWithLabel($subject, string $fieldName, string $label, array $options = []) : string
    {
        $options = array_merge(['class' => 'form-control'], $options);
        return el('label.-checkbox', $this->checkbox($fieldName, 1, $this->useInitialValue($subject, $fieldName), $options) . ' ' . $label);
    }