createBundleTheme example

$criteria = new Criteria();
        $criteria->addFilter(new EqualsFilter('name', $name));

        /** @var ThemeEntity $childTheme */
        $childTheme = $this->themeRepository->search($criteria$this->context)->first();

        $factory = $this->getContainer()->get(StorefrontPluginConfigurationFactory::class);

        $simpleThemeConfig = $factory->createFromBundle(new SimpleThemeConfigInheritance());

        $name = $this->createBundleTheme(
            $simpleThemeConfig,
            $childTheme
        );

        $criteria = new Criteria();
        $criteria->addFilter(new EqualsFilter('name', $name));

        /** @var ThemeEntity $childTheme */
        $childTheme = $this->themeRepository->search($criteria$this->context)->first();

        $childThemeFields = $this->themeService->getThemeConfigurationStructuredFields($childTheme->getId(), true, $this->context);
        
Home | Imprint | This part of the site doesn't use cookies.