field = $field; } public function getView(): CRadioButtonList { $view = (new CRadioButtonList($this->field->getName(), $this->field->getValue())) ->setModern() ->setAriaRequired($this->isRequired()); foreach ($this->field->getValues() as $key => $value) { $view ->addValue($value, $key, null, $this->field->getAction()) ->setEnabled(!$this->isDisabled()); } return $view; } }