-
Notifications
You must be signed in to change notification settings - Fork 9.3k
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
sales.xsd #953
Comments
Item name is an identifier attribute, so you should be able to modify both instance type and sort order. |
Doesn't seem to work for me. If I use
I get
which is the expected outcome. However if I use if with the existing subtotal
I would expect to see the same error message but it processes the cart normally. It would also be great to have this consistent with the renderer (ie choose 1 approach) |
This can happen because original config overrides your because your module is loaded later. |
Indeed when I move it to the end of the module declaration in I did have
so it appears that the xml file loader for |
Sales.xml reader uses standard configuration reader so it should be sorted in the same way as other files do. app/etc/config.php is created by install script taking into account module dependencies so the list is sorted in specific way. And editing it manually to turn off/on modules might lead to problems that you encountered. |
@antonkril the following statement is probably more correct: only the loading of My expectation would have been that the sequence defined in
Manually editing config.php is currently the only way to extend Magento so as long as there is no alternative for it it will be used. |
Sorting happens only once for module.xml, and sort order is then used for all configuration files. So sales.xml is loaded/merged in same order. See https://github.com/magento/magento2/blob/develop/lib/internal/Magento/Framework/Module/Dir/Reader.php#L78 You can use |
@antonkril that's great to hear that this command is now available. Hopefully this gets a bit more exposure in the docs so that everyone knows how to use this going forward. |
- Merge Pull Request magento/graphql-ce#953 from pmclain/graphql-ce:issue/881 - Merged commits: 1. 17ea087
The new format for the sales.xml files moves both the instance and the sort order into the item node. Previously in Mage1 it was possible to change both the instance / sort order via an xml directive that got merged, for example:
The equivalent would not work in Magento2. Not sure if this currently an intended outcome to disallow this or an unintended consequence.
Subnodes are allowed in Mage2 to supply a different renderer like the Tax module currently does.
The text was updated successfully, but these errors were encountered: