Created
June 10, 2015 12:32
-
-
Save just-tom/479c3f8578738fcb6ae1 to your computer and use it in GitHub Desktop.
Add custom attributes to collections with XML
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** Add custom attribute to category collection on frontend */ | |
<frontend> | |
<category> | |
<collection> | |
<attributes> | |
<some_category_attribute/> | |
</attributes> | |
</collection> | |
</category> | |
</frontend> | |
/** Add custom attribute to product collection on frontend */ | |
<frontend> | |
<product> | |
<collection> | |
<attributes> | |
<some_product_attribute/> | |
</attributes> | |
</collection> | |
</product> | |
</frontend> | |
/** Add attributes to any config node that permits it e.g sales_quote_item */ | |
<global> | |
<sales> | |
<quote> | |
<item> | |
<product_attributes> | |
<some_product_attribute /> | |
</product_attributes> | |
</item> | |
</quote> | |
</sales> | |
</global> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment