Is it possible to switch configuration scope/store when executing a module? #1778
Unanswered
f1-outsourcing
asked this question in
Questions & Answers
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I have created a module that does a remote api request, and configured this module under website_a
Now I create an order in admin, I choose a website_a view, select the product.
When I click submit order, the module api request fails with an authentication error, because it is not configured in the configuration scope 'Default Config'
How should I change my observer.php so it gets the website_a from the order, sets this as a default 'environment' and then executes api requests?
Is it even possible to change the 'environment' from a configuration scope 'Default Config' to a configuration scope 'website_a'?
Beta Was this translation helpful? Give feedback.
All reactions