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

Commit a39af80

Browse files
authored
Merge pull request #197 from rarog/master
A button group should be rendered exactly 1 time and not n-1 times fo…
2 parents 8799d13 + 798e9d0 commit a39af80

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/TwbBundle/Form/View/Helper/TwbBundleForm.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -117,9 +117,9 @@ protected function renderElements(FormInterface $oForm, $sFormLayout = self::LAY
117117
$sButtonGroupKey = $aOptions['button-group'];
118118
if (isset($aButtonGroups[$sButtonGroupKey])) {
119119
$aButtonGroups[$sButtonGroupKey][] = $oElement;
120-
$aElementsRendering[$iKey] = $sButtonGroupKey;
121120
} else {
122121
$aButtonGroups[$sButtonGroupKey] = array($oElement);
122+
$aElementsRendering[$iKey] = $sButtonGroupKey;
123123
}
124124
if (!empty($aOptions['column-size']) && !isset($aButtonGroupsColumnSize[$sButtonGroupKey])) {
125125
// Only the first occured column-size will be set, other are ignored.

0 commit comments

Comments
 (0)