|
@@ 240-246 (lines=7) @@
|
| 237 |
|
|
| 238 |
|
'actionAddForIBlock' => 'addForIBlock', |
| 239 |
|
]; |
| 240 |
|
foreach ($simpleDirectives as $directive => $action) { |
| 241 |
|
$compiler->directive($directive, function ($expression) use ($action) { |
| 242 |
|
$expression = rtrim($expression, ')'); |
| 243 |
|
$expression = ltrim($expression, '('); |
| 244 |
|
return '<?php \Arrilot\BitrixHermitage\Action::' . $action . '($template, ' . $expression . '); ?>'; |
| 245 |
|
}); |
| 246 |
|
} |
| 247 |
|
|
| 248 |
|
$echoDirectives = [ |
| 249 |
|
'actionAreaForIBlockElement' => 'areaForIBlockElement', |
|
@@ 253-259 (lines=7) @@
|
| 250 |
|
'actionAreaForIBlockSection' => 'areaForIBlockSection', |
| 251 |
|
'actionAreaForHLBlockElement' => 'areaForHLBlockElement', |
| 252 |
|
]; |
| 253 |
|
foreach ($echoDirectives as $directive => $action) { |
| 254 |
|
$compiler->directive($directive, function ($expression) use ($action) { |
| 255 |
|
$expression = rtrim($expression, ')'); |
| 256 |
|
$expression = ltrim($expression, '('); |
| 257 |
|
return '<?= \Arrilot\BitrixHermitage\Action::' . $action . '($template, ' . $expression . '); ?>'; |
| 258 |
|
}); |
| 259 |
|
} |
| 260 |
|
} |
| 261 |
|
} |
| 262 |
|
|