public function compileInitWidget(Twig_Compiler $compiler) { if ($this->isInline()) { parent::compileInitWidget($compiler); } else { $compiler->write(sprintf('echo %s->input(', $this->getVarName())); $this->compileWidgetId($compiler); $compiler->raw(','); } }
public function compileInitWidget(Twig_Compiler $compiler) { if (!$this->getNode('values')->hasNode('region')) { parent::compileInitWidget($compiler); } else { $compiler->write(sprintf('echo %s->initLayout(', $this->getVarName())); $compiler->subcompile($this->getNode('values')->getNode('region')); $compiler->raw(','); $this->compileWidgetId($compiler); $compiler->raw(','); } }