Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Theme Config of a duplicated theme is not updated #507

Closed
NicoWenig27 opened this issue Feb 5, 2020 · 4 comments
Closed

Theme Config of a duplicated theme is not updated #507

NicoWenig27 opened this issue Feb 5, 2020 · 4 comments
Assignees

Comments

@NicoWenig27
Copy link
Contributor

Description
When I update my theme plugin to a new version where the theme.json has new fields, only the original theme config gets those new fields. Duplicated themes of the original won't get the new fields.

Additional context
Steps to reproduce:

  1. Create a new theme plugin with one custom field in the theme.json
  2. Install and activate plugin
  3. Duplicate the theme
  4. Update the theme.json and add a new field
  5. Compare the theme configs of the original and the duplicated theme
@ssltg
Copy link
Contributor

ssltg commented Feb 20, 2020

Hi @NicoWenig27 ,
your described behaviour works as intended. https://docs.shopware.com/en/shopware-platform-dev-en/internals/plugins/plugin-themes#inheritance-of-theme-config
A Duplicated Theme is actually a copy, not an inheritance when it comes to configuration. If you Update your ThemePlugin you have to create a new Duplication and then assign this to your Saleschannel.
This is done this way to minimize possible Breaks on running Storefronts.
We are aware of the need for a more convient way to make updates on duplications and there is a Ticket in our Issue Tracker vor this Topic: https://issues.shopware.com/issues/NEXT-6402

@NicoWenig27
Copy link
Contributor Author

Hi @ssltg,

thanks for the answer! My problem with this is, that when you have a duplicated theme for a sales channel with its own theme config and update the main theme, you have to duplicate it again and copy all config to the new duplicated theme. So yes, I think there should be a way to update duplicates, without creating a complete new one.

I think the ticket you linked describes another problem. At the moment you cannot inherit the views of another theme, when you create a new theme. This is an issue with which we also have problems. Our plan was to create a whitelabel theme and inherit from it to create new themes for every customer. As a workaround we copy the complete whitelabel theme project for every new theme.
But that's not really related to this issue. Just as a hint, that we are having problems with it.

@peterjaap
Copy link
Contributor

peterjaap commented Aug 11, 2020

@NicoWenig27 AFAIK, view inheritance now does work, except the config settings don't (as you mentioned here as well). I've opened another issue about it here; #1227

@shyim
Copy link
Member

shyim commented Oct 14, 2021

They are merged in the newest version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants