moduleDataSetup = $moduleDataSetup; $this->metadataPool = $metadataPool; $this->aggregatedFieldDataConverter = $aggregatedFieldDataConverter; } /** * {@inheritdoc} */ public function apply() { $metadata = $this->metadataPool->getMetadata(RuleInterface::class); $this->aggregatedFieldDataConverter->convert( [ new FieldToConvert( SerializedToJson::class, $this->moduleDataSetup->getTable('catalogrule'), $metadata->getLinkField(), 'conditions_serialized' ), new FieldToConvert( SerializedToJson::class, $this->moduleDataSetup->getTable('catalogrule'), $metadata->getLinkField(), 'actions_serialized' ), ], $this->moduleDataSetup->getConnection() ); } /** * {@inheritdoc} */ public static function getDependencies() { return [ UpdateClassAliasesForCatalogRules::class, ]; } /** * {@inheritdoc} */ public static function getVersion() { return '2.0.3'; } /** * {@inheritdoc} */ public function getAliases() { return []; } }