Skip to content

[5.x]: Disabled variant makes it impossible to change sorting of variants #4270

@white-lukas

Description

@white-lukas

What happened?

Description

When you have a disabled variant, the sort order of variants is not saved for all variants that are under this variant.

Take a product with 3 variants:

  • variant 1 -> disabled
  • variant 2 -> enabled
  • variant 3 -> enabled

When changing the order of variant 2 and 3 this is not saved.
But when first moving variant 1 as the latest variant and saving the product
so you have

  • variant 2 -> enabled
  • variant 3 -> enabled
  • variant 1 -> disabled

After this it is possible to change the sorting of variant 2 and 3.

So it seems that the sorting under a disabled variant isn't getting applied.
When having more variants, everything works above the disabled variant, everything after isn't getting applied.

Craft CMS version

5.9.17

Craft Commerce version

5.6.1

PHP version

8.3

Operating system and version

No response

Database type and version

mysql 8.0

Image driver and version

No response

Installed plugins and versions

No response

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions