added the possibility to easily customize the template of just one widget of a form (PHP edition)

This commit is contained in:
Fabien Potencier 2011-04-29 07:33:55 +02:00
parent a204aec08b
commit 3a36c08d8e

View File

@ -101,7 +101,9 @@ class FormHelper extends Helper
{
$template = null;
$blocks = $view->get('types');
if ('widget' === $section || 'row' === $section) {
array_unshift($blocks, '_'.$view->get('id'));
}
foreach ($blocks as &$block) {
$block = $block.'_'.$section;
$template = $this->lookupTemplate($block);