setArrayStore example

if ($snippet = $snippets->get($key . 'helpText')) {
                $column->setHelpText($snippet);
            }

            $arrayStore = json_decode($column->getArrayStore(), true);
            if (!empty($arrayStore)) {
                foreach ($arrayStore as &$option) {
                    $optionKey = sprintf('%soptions_store_%s', $keystrtolower($option['key']));
                    $option['value'] = $snippets->get($optionKey$option['value']);
                }
                unset($option);
                $column->setArrayStore(json_encode($arrayStore));
            }
        }
    }
}
$item->setHelpText($config['helpText']);
                $item->setDisplayInBackend((bool) $config['displayInBackend']);
                $item->setReadonly((bool) $config['readonly']);
                $item->setLabel($config['label']);
                $item->setPosition((int) $config['position']);
                $item->setCustom((bool) $config['custom']);
                $item->setTranslatable((bool) $config['translatable']);
                $item->setConfigured(true);
                $item->setDbalType($column->getType()->getName());
                $item->setSqlType($this->typeMapping->unifiedToSQL($item->getColumnType()));
                $item->setEntity($config['entity']);
                $item->setArrayStore($config['arrayStore']);
                $item->setElasticSearchType($this->typeMapping->unifiedToElasticSearch($config['columnType']));
                $item->setDefaultValue($config['defaultValue'] === 'NULL' ? null : $config['defaultValue']);
            }
            $items[] = $item;
        }

        usort($itemsfunction DConfigurationStruct $a, ConfigurationStruct $b) {
            if ($a->getPosition() === null && $b->getPosition() !== null) {
                return 1;
            }
            if ($b->getPosition() === null && $a->getPosition() !== null) {
                
Home | Imprint | This part of the site doesn't use cookies.