Skip to content

Instantly share code, notes, and snippets.

@vanWittlaer
Created February 23, 2021 16:05
Show Gist options
  • Save vanWittlaer/c315b1c606897a78fbcb9c974148541b to your computer and use it in GitHub Desktop.
Save vanWittlaer/c315b1c606897a78fbcb9c974148541b to your computer and use it in GitHub Desktop.
Shopware 6 config multi-select
Define in config.xml:
<component name="sw-entity-multi-id-select">
<name>b2bCustomerGroupIds</name>
<entity>customer_group</entity>
<label>Choose multiple customer groups as B2B groups</label>
<label lang="de-DE">Wählen Sie die für B2B vorgesehenen Kundengruppen.</label>
</component>
Use in twig:
{% if not page.group.id in shopware.config.MyPlugin.config.b2bCustomerGroupIds %}{% endif %}
@schiefertom
Copy link

Exactly what I was looking for right now, thx Benny!

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