File tree Expand file tree Collapse file tree
view/adminhtml/templates/form/field_type Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -17,15 +17,10 @@ use Loki\Components\Util\Block\TemplateRenderer;
1717/** @var Escaper $escaper */
1818
1919$ field = $ block ->getField ();
20- $ options = $ field ->getOptions ();
2120$ emptyOption = $ field ->getEmptyOption ();
2221$ fieldType = $ field ->getFieldType ();
22+ $ options = $ fieldType ->getOptions ();
2323$ fieldAttributes = $ field ->getFieldAttributes ();
24-
25- if (false === $ options instanceof OptionSourceInterface) {
26- echo '$options is not a proper instance: ' .gettype ($ options );
27- return ;
28- }
2924?>
3025<select
3126 aria-label="<?= $ escaper ->escapeHtml ($ field ->getLabel ()) ?> "
@@ -54,7 +49,7 @@ if (false === $options instanceof OptionSourceInterface) {
5449 ) ?>
5550 <?php endif ; ?>
5651
57- <?php foreach ($ options-> toOptionArray () as $ option ) : ?>
52+ <?php foreach ($ options as $ option ) : ?>
5853 <?php $ option ['level ' ] = 0 ; ?>
5954 <?= /* @noEscape */ $ templateRenderer ->html (
6055 $ block ,
You can’t perform that action at this time.
0 commit comments