Skip to content

Error at reorder for order with no longer existing customer group id. #29059

Closed
@victortodoran

Description

@victortodoran

Preconditions (*)

  1. Magento 2.4

Steps to reproduce (*)

  1. Fresh install
  2. Create customer (via Admin Panel)
  3. Create customer group
  4. Associate customer (step 2) with recently created customer group (step3)
  5. Place order for customer (step 2) (via Admin Panel)
  6. Delete customer group (step 3)
  7. Reorder order (step 5) (via Admin Panel)

Expected result (*)

  1. After deleting customer group (step 6) customer (step 2) is assigned to default customer group
  2. At reorder current customer group is used

Actual result (*)

  1. After deleting customer group (step 6) customer (step 2) is assigned to default customer group
  2. At reorder customer group from previous order (which no longer exists) is used
  3. Error when quote is saved
    Screenshot_16

Additional information(*)

Issue is from

\Magento\Sales\Model\AdminOrder\Create::initFromOrder

More specifically this line here

$this->getQuote()->setCustomerGroupId($order->getCustomerGroupId());


Please provide Severity assessment for the Issue as Reporter. This information will help during Confirmation and Issue triage processes.

  • 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

Metadata

Assignees

No one assigned

    Labels

    Component: CustomerIssue: Clear DescriptionGate 2 Passed. Manual verification of the issue description passedIssue: ConfirmedGate 3 Passed. Manual verification of the issue completed. Issue is confirmedIssue: Format is validGate 1 Passed. Automatic verification of issue format passedIssue: Ready for WorkGate 4. Acknowledged. Issue is added to backlog and ready for developmentPriority: P3May be fixed according to the position in the backlog.Progress: doneReported on 2.4.0Indicates original Magento version for the Issue report.Reproduced on 2.4.xThe issue has been reproduced on latest 2.4-develop branchSeverity: S2Major restrictions or short-term circumventions are required until a fix is available.Triage: DoneHas been reviewed and prioritized during Triage with Product Managers

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions