Skip to content

"Exclude child attributes" doesn't show all attributes #79

@DuckThom

Description

@DuckThom

Issue Brief

The list of attributes shown in the backend config "Exclude child attributes" does not show all the available product attributes.
This is the default config for this setting:

<exclude_child_attributes>url_key,small_image,small_image_label,thumbnail_label,status,tax_class_id,type_id,required_options,visibility</exclude_child_attributes>

However, when a custom config is set, overriding the default line above, visibility (among others) is then duplicated for Bundle and Configurable products.
The "Exclude child attributes" should prevent this, but as visibility is not one of the options in the list, it's not possible to add it back.
This results in certain Bundle/Configurable products being searchable, even when their visibility is set to "Catalog" as one or more child items has "Catalog, Search".

Environment

  • PHP Version: 8.1.29
  • Magento Version: 2.4.6-p8
  • Magento Enterprise: no
  • Tweakwise Export Version: v7.1.0
  • Magento Deploy Mode: production
  • Third party modules: n.a.

Steps to reproduce

  1. Install Magento with the export module
  2. Check the "Exclude child attributes" setting to see there's no visibility option
  3. Select 1 or more attributes in "Exclude child attributes"
  4. Export a configurable and/or bundle product with visibility "Catalog" that has 1 or more children with visibility "Catalog, Search" or "Search"
  5. Validate the output xml and see multiple visibility options for the confgurable and/or bundle product

Actual result

All visibility options are exported on bundle/configurable products after customizing the "Exclude child attributes" config

        <attribute datatype="numeric">
          <name><![CDATA[visibility]]></name>
          <value>2</value>
        </attribute>
        <attribute datatype="numeric">
          <name><![CDATA[visibility]]></name>
          <value>4</value>
        </attribute>

Expected result

  • [] Having the ability to select all (or at least the same as the default config) product attributes in the exclude child attributes config
  • [] Visibility is only exported once when custom "Exclude child attributes" is present

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions