public function up($modus) { $sql = <<<SQL
INSERT IGNORE INTO `s_search_custom_facet` (`id`, `unique_key`, `active`, `display_in_categories`, `position`, `name`, `facet`, `deletable`) VALUES
(NULL, 'VariantFacet', 0, 1, 11, 'Varianten', '{"Shopware\\\\\\\Bundle\\\\\\\SearchBundle\\\\\\\Facet\\\\\\\VariantFacet":{"groupIds":"", "expandGroupIds":""}}', 0)
;
SQL;
$this->
addSql($sql);
$id =
(int) $this->connection->
query('SELECT id FROM `s_search_custom_facet` WHERE `unique_key` = "VariantFacet"'
)->
fetchColumn(0
);
$this->
importFacetTranslations($id);
} /**
* @param int $facetId
*/
private function importFacetTranslations($facetId) { $shops =
$this->connection->
query('SELECT shops.id, shops.main_id, shops.locale_id, locales.locale FROM s_core_shops shops INNER JOIN s_core_locales locales ON locales.id=shops.locale_id'
) ->
fetchAll(PDO::FETCH_ASSOC
);
foreach ($shops as $shop) {