Skip to content

Commit

Permalink
Render menu item options in accordion groups
Browse files Browse the repository at this point in the history
  • Loading branch information
mbabker committed Aug 4, 2012
1 parent 5ffb780 commit e1e1a3d
Showing 1 changed file with 11 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,13 @@
defined('_JEXEC') or die;
?>
<?php

echo JHtml::_('bootstrap.startAccordion', 'menuOptions', array('active' => 'collapse0'));
$fieldSets = $this->form->getFieldsets('params');
$i = 0;

foreach ($fieldSets as $name => $fieldSet) :
$label = !empty($fieldSet->label) ? $fieldSet->label : 'COM_MENUS_'.$name.'_FIELDSET_LABEL';
echo JHtml::_('bootstrap.addSlide', 'menuOptions', JText::_($label), 'collapse' . $i++);
if (isset($fieldSet->description) && trim($fieldSet->description)) :
echo '<p class="tip">'.$this->escape(JText::_($fieldSet->description)).'</p>';
endif;
Expand All @@ -28,14 +30,16 @@
<?php echo $field->input; ?>
</div>
</div>
<?php endforeach; ?>
<?php endforeach;?>
<?php endforeach;
echo JHtml::_('bootstrap.endSlide');
endforeach;?>
<?php

$fieldSets = $this->form->getFieldsets('associations');

foreach ($fieldSets as $name => $fieldSet) :
$label = !empty($fieldSet->label) ? $fieldSet->label : 'COM_MENUS_'.$name.'_FIELDSET_LABEL';
echo JHtml::_('bootstrap.addSlide', 'menuOptions', JText::_($label), 'collapse' . $i++);
if (isset($fieldSet->description) && trim($fieldSet->description)) :
echo '<p class="tip">'.$this->escape(JText::_($fieldSet->description)).'</p>';
endif;
Expand All @@ -49,5 +53,7 @@
<?php echo $field->input; ?>
</div>
</div>
<?php endforeach; ?>
<?php endforeach;?>
<?php endforeach;
echo JHtml::_('bootstrap.endSlide');
endforeach;
echo JHtml::_('bootstrap.endAccordion');

0 comments on commit e1e1a3d

Please sign in to comment.