My problem is, that I wan’t to use scope switcher that is, for example, in product editor in the toolbar:
It has a really nice ability to quickly switch between store views and usage default values for inputs inside product edit form.
I want to use it in my custom module, for my custom entity that I’ve created. I know how to add the block itself:
<referenceContainer name="page.main.actions"> <block class="Magento\Backend\Block\Store\Switcher" name="store_switcher"> <action method="setUseConfirm"> <argument name="params" xsi:type="string">1</argument> </action> </block> </referenceContainer>
But I had no luck finding how the mechanism itself works. Can someone explain it to me how it works and how can i use it in my module?