Skip to content

Custom Price of 0 gets reset to original price on reorder. #36970

@Hexmage

Description

Preconditions and environment

  • Any, apparently been a bug since 2.0

Steps to reproduce

Create an order in admin panel.
Set custom price to 0 for one product.
Place the order.
Reorder the same order.

Expected result

Expect the changed product to have a custom price of 0.

Actual result

The changed product has its original price.

Additional information

if (!empty($customPrice) && !$candidate->getParentProductId()) {

When custom price is 0 the empty() validates as true. While it should validate as false, because 0 is a valid price.

Release note

No response

Triage and priority

  • Severity: S0 - Affects critical data or functionality and leaves users without workaround.
  • Severity: S1 - Affects critical data or functionality and forces users to employ a workaround.
  • Severity: S2 - Affects non-critical data or functionality and forces users to employ a workaround.
  • Severity: S3 - Affects non-critical data or functionality and does not force users to employ a workaround.
  • Severity: S4 - Affects aesthetics, professional look and feel, “quality” or “usability”.

Metadata

Assignees

Labels

Area: OrderComponent: PricingIssue: ConfirmedGate 3 Passed. Manual verification of the issue completed. Issue is confirmedPriority: P2A defect with this priority could have functionality issues which are not to expectations.Progress: PR in progressReported on 2.4.xIndicates original Magento version for the Issue report.Reproduced on 2.4.xThe issue has been reproduced on latest 2.4-develop branch

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions