magento / magento2

Prior to making any Submission(s), you must sign an Adobe Contributor License Agreement, available here at: https://opensource.adobe.com/cla.html. All Submissions you make to Adobe Inc. and its affiliates, assigns and subsidiaries (collectively “Adobe”) are subject to the terms of the Adobe Contributor License Agreement.
http://www.magento.com
Open Software License 3.0
11.46k stars 9.28k forks source link

[Issue] Product layout based on attribute_set #38790

Open m2-assistant[bot] opened 3 months ago

m2-assistant[bot] commented 3 months ago

This issue is automatically created based on existing pull request: magento/magento2#36244: Product layout based on attribute_set


Currently there is only the possibility to adjust the layout by SKU or by types of the product. In most productive cases, however, this is only partly practical. because it then only refers to many articles or one article. With the integration the layout can be used based on the attribute set similar to an article group, which is more needed in most cases. The display of the articles are controlled in the backend by attribute_set, so there should be a way to pass this to the frontend store as well.

https://developer.adobe.com/commerce/frontend-core/guide/layouts/product-layouts/

LAYOUT FILE | DESCRIPTION -- | -- catalog_product_view.xml | Common layout. Affects all product types catalog_product_view_type_bundle.xml | Layout from this file is applied to bundle product only catalog_product_view_type_configurable.xml | Layout from this file is applied to configurable product only catalog_product_view_type_downloadable.xml | Layout from this file is applied to downloadable product only catalog_product_view_type_grouped.xml | Layout from this file is applied to grouped product only catalog_product_view_type_simple.xml | Layout from this file is applied to simple product only catalog_product_view_type_virtual.xml | Layout from this file is applied to virtual product only catalog_product_view_id_{id}.xml | Layout from this file is applied to the specific product by Entity ID value. E.g. catalog_product_view_id_45.xml **catalog_product_view_attribute_set_{id}.xml** | **Layout from this file is applied to the specific product attribute set by Entity ID value. E.g. catalog_product_view_attribute_set_45.xml** catalog_product_view_sku_{sku}.xml | Layout from this file is applied to the specific product by SKU value. E.g. catalog_product_view_sku_24-WG080.xml

Example: catalog_product_view_attribute_set_15.xml Controls the front-end display of all items that are within the Bags group.

m2-assistant[bot] commented 3 months ago

Hi @engcom-November. Thank you for working on this issue. In order to make sure that issue has enough information and ready for development, please read and check the following instruction: :point_down:

engcom-November commented 3 months ago

Hello @in-session,

Thank you for the report and collaboration!

Changing the layout of the products based on attribute set is a good feature to implement. Hence marking this as a feature request.