Commit e5e0f310 authored by Carsten  Rose's avatar Carsten Rose
Browse files

radio: new class 'qfq-disabled' if readonly is set.

parent f591c7f5
Pipeline #2790 failed with stages
in 1 minute and 56 seconds
......@@ -2076,7 +2076,13 @@ abstract class AbstractBuildForm {
}
$labelAttribute = Support::doAttribute('title', $formElement[FE_TOOLTIP]);
$html = Support::wrapTag("<label class='checkbox' $labelAttribute>", $html, true);
$class = 'checkbox';
if ($formElement[FE_MODE] == FE_MODE_READONLY) {
$class .= ' qfq-disabled'; // necessary for own style checkboxes to display them 'disabled'
}
$html = Support::wrapTag("<label class='$class' $labelAttribute>", $html, true);
// $html = Support::wrapTag("<div class='checkbox'>", $html, true);
$json = $this->getFormElementForJson($htmlFormElementName, $valueJson, $formElement);
......@@ -2247,6 +2253,10 @@ abstract class AbstractBuildForm {
$orientation = ($formElement[FE_MAX_LENGTH] > 1) ? ALIGN_HORIZONTAL : ALIGN_VERTICAL;
$checkboxClass = ($orientation === ALIGN_HORIZONTAL) ? 'checkbox-inline' : 'checkbox';
if ($formElement[FE_MODE] == FE_MODE_READONLY) {
$checkboxClass .= ' qfq-disabled'; // necessary for own style checkboxes to display them 'disabled'
}
$br = '';
$flagFirst = true;
......@@ -2502,6 +2512,9 @@ abstract class AbstractBuildForm {
$orientation = ($formElement[FE_MAX_LENGTH] > 1) ? ALIGN_HORIZONTAL : ALIGN_VERTICAL;
$radioClass = ($orientation === ALIGN_HORIZONTAL) ? 'radio-inline' : 'radio';
if ($formElement[FE_MODE] == FE_MODE_READONLY) {
$radioClass .= ' qfq-disabled';
}
$radioOuterTag = ($orientation === ALIGN_HORIZONTAL) ? 'label' : 'div';
$br = '';
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment