mirror of
https://github.com/Combodo/iTop.git
synced 2026-05-01 06:28:46 +02:00
N°2737 - RenderBlockTemplate enhancement, uilinkswidget UIBlock refactor
This commit is contained in:
@@ -169,7 +169,8 @@ class Extension
|
||||
// Usage in twig: {{ render_block(oBlock) }}
|
||||
/** @since 3.0.0 */
|
||||
$oTwigEnv->addFunction(new Twig_SimpleFunction('render_block', function(iUIBlock $oBlock, $aContextParams = []){
|
||||
return BlockRenderer::RenderBlockTemplates($oBlock, $aContextParams);
|
||||
$oRenderer = new BlockRenderer($oBlock, $aContextParams);
|
||||
return $oRenderer->RenderHtml();
|
||||
}, ['is_safe' => ['html']]));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user