Skip to content
This repository has been archived by the owner on Jul 10, 2020. It is now read-only.

Commit

Permalink
Merge pull request #197 from rarog/master
Browse files Browse the repository at this point in the history
A button group should be rendered exactly 1 time and not n-1 times fo…
  • Loading branch information
neilime committed Apr 14, 2017
2 parents 8799d13 + 798e9d0 commit a39af80
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/TwbBundle/Form/View/Helper/TwbBundleForm.php
Expand Up @@ -117,9 +117,9 @@ protected function renderElements(FormInterface $oForm, $sFormLayout = self::LAY
$sButtonGroupKey = $aOptions['button-group'];
if (isset($aButtonGroups[$sButtonGroupKey])) {
$aButtonGroups[$sButtonGroupKey][] = $oElement;
$aElementsRendering[$iKey] = $sButtonGroupKey;
} else {
$aButtonGroups[$sButtonGroupKey] = array($oElement);
$aElementsRendering[$iKey] = $sButtonGroupKey;
}
if (!empty($aOptions['column-size']) && !isset($aButtonGroupsColumnSize[$sButtonGroupKey])) {
// Only the first occured column-size will be set, other are ignored.
Expand Down

0 comments on commit a39af80

Please sign in to comment.