The checkout complete event only fires on checkout.
The workflow placed event would fire on both checkout and admin, making it a better candidate for most listeners (such as the one that sends the confirmation email).

Problem is, state_machine doesn't fire events yet.
Once it does, we remove the checkout complete event.

Comments

bojanz created an issue. See original summary.

steveoliver’s picture

Relating state_machine issue.

bojanz’s picture

The parent issue has landed.

This one will need a change record.

bojanz’s picture

Status: Active » Needs review
StatusFileSize
new2.78 KB

Patch for the code removal.

And here's an unpublished change record: https://www.drupal.org/node/2818373

Sounds like we should rename our workflow group from order to commerce_order, to make the event be "commerce_order.place.pre_transition".

EDIT: Opened #2818423: Prefix workflow groups with 'commerce_', let's do that first.

  • bojanz committed 890d5e2 on 8.x-2.x
    Issue #2788037 by bojanz: Remove the checkout complete event in favor of...
bojanz’s picture

Status: Needs review » Fixed

Done.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

petros’s picture

I am sorry for opening this again but checkout complete event should not have been removed in my opinion. There are some things that need to run after checkout complete (e.g a redirections or something like that). Also from my understanding this is the main purpose of the order workflow to disconnect order from checkout...