Skip to main content
Rollback to Revision 1 - Edit approval overridden by post owner or moderator
Source Link
Igor S
  • 923
  • 7
  • 7

There is no necessity to change any PHP code for doing this.

You just need to create {MODULE_NAME}/etc/catalog_attributes.xml with such content:

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Catalog:etc/catalog_attributes.xsd">
    <group name="quote_item">
        <attribute name="sample_attr"/>
    </group>
</config>

After that apply a commands like:

php bin/magento setup:upgrade

after that regenerate your static content by running the following command

php bin/magento setup:static-content:deploy

at last apply permission

chmod -R 777 var pub

There is no necessity to change any PHP code for doing this.

You just need to create {MODULE_NAME}/etc/catalog_attributes.xml with such content:

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Catalog:etc/catalog_attributes.xsd">
    <group name="quote_item">
        <attribute name="sample_attr"/>
    </group>
</config>

After that apply a commands like:

php bin/magento setup:upgrade

after that regenerate your static content by running the following command

php bin/magento setup:static-content:deploy

at last apply permission

chmod -R 777 var pub

There is no necessity to change any PHP code for doing this.

You just need to create {MODULE_NAME}/etc/catalog_attributes.xml with such content:

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Catalog:etc/catalog_attributes.xsd">
    <group name="quote_item">
        <attribute name="sample_attr"/>
    </group>
</config>
magento2 checkout cart page apply necessary commands after create a module.
Source Link

There is no necessity to change any PHP code for doing this.

You just need to create {MODULE_NAME}/etc/catalog_attributes.xml with such content:

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Catalog:etc/catalog_attributes.xsd">
    <group name="quote_item">
        <attribute name="sample_attr"/>
    </group>
</config>

After that apply a commands like:

php bin/magento setup:upgrade

after that regenerate your static content by running the following command

php bin/magento setup:static-content:deploy

at last apply permission

chmod -R 777 var pub

There is no necessity to change any PHP code for doing this.

You just need to create {MODULE_NAME}/etc/catalog_attributes.xml with such content:

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Catalog:etc/catalog_attributes.xsd">
    <group name="quote_item">
        <attribute name="sample_attr"/>
    </group>
</config>

There is no necessity to change any PHP code for doing this.

You just need to create {MODULE_NAME}/etc/catalog_attributes.xml with such content:

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Catalog:etc/catalog_attributes.xsd">
    <group name="quote_item">
        <attribute name="sample_attr"/>
    </group>
</config>

After that apply a commands like:

php bin/magento setup:upgrade

after that regenerate your static content by running the following command

php bin/magento setup:static-content:deploy

at last apply permission

chmod -R 777 var pub
Source Link
Igor S
  • 923
  • 7
  • 7

There is no necessity to change any PHP code for doing this.

You just need to create {MODULE_NAME}/etc/catalog_attributes.xml with such content:

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Catalog:etc/catalog_attributes.xsd">
    <group name="quote_item">
        <attribute name="sample_attr"/>
    </group>
</config>