What are the Slack Archives?
Itβs a history of our time together in the Slack Community! Thereβs a ton of knowledge in here, so feel free to search through the archives for a possible answer to your question.
Because this space is not active, you wonβt be able to create a new post or comment here. If you have a question or want to start a discussion about something, head over to our categories and pick one to post in! You can always refer back to a post from Slack Archives if needed; just copy the link to use it as a reference..
Hi guys π i was wondering, what is supposed to happen if some CheckoutPreConditionPlugin create
Hi guys π i was wondering, what is supposed to happen if some CheckoutPreConditionPlugin created an Error without an ErrorCode? E.g. https://github.com/spryker/gift-card/blob/94c737ef332b228613346dc1deaff36f54ab5d7b[β¦]/Spryker/Zed/GiftCard/Business/Payment/SalesOrderPreChecker.php adds an Error without an ErrorCode to the CheckoutResponse if the GiftCard is already used. So the PlaceOrderStep will not have a postConditionErrorRoute and the StepCollections Error Route checkout-error
will be used. But because of the PlaceOrderSteps PostCondition $quoteTransfer->getOrderReference() !== null
the ErrorSteps PostCondition $quoteTransfer->getOrderReference() === null
can never be triggered. The Result is an infinite redirect from place-order-step to error-step and so on. Am i missing something here?
Comments
-
fsmeier Senior Software Engineer & Developer Enablement Advocate Sprykee Posts: 1,071 βοΈ - Guardians (admin)
Yes, this is sadly a bug π If you have access through a partner or customer portal you can report it to get better attention
0 -
All right i'll report it then, thank you very much π
0 -
fsmeier Senior Software Engineer & Developer Enablement Advocate Sprykee Posts: 1,071 βοΈ - Guardians (admin)
Workaround which worked for me to not have the loop:
<?php namespace Pyz\Yves\CheckoutPage\Process; use Spryker\Yves\StepEngine\Process\StepCollection; use SprykerShop\Yves\CheckoutPage\Plugin\Router\CheckoutPageRouteProviderPlugin; use SprykerShop\Yves\CheckoutPage\Process\StepFactory as SprykerStepFactory; class StepFactory extends SprykerStepFactory { /** * @return \Spryker\Yves\StepEngine\Process\StepCollectionInterface */ public function createStepCollection() { return new StepCollection( $this->getRouter(), CheckoutPageRouteProviderPlugin::ROUTE_NAME_CHECKOUT_SUMMARY ); } }
0 -
fsmeier Senior Software Engineer & Developer Enablement Advocate Sprykee Posts: 1,071 βοΈ - Guardians (admin)
Routing not to error-route but using the summary as default error-route
0 -
@U01F7P3D9NH Seems like a solution for the same issue we have as well, what do you think?
0
Categories
- All Categories
- 42 Getting Started & Guidelines
- 7 Getting Started in the Community
- 8 Additional Resources
- 7 Community Ideas and Feedback
- 73 Spryker News
- 911 Developer Corner
- 771 Spryker Development
- 87 Spryker Dev Environment
- 361 Spryker Releases
- 3 Oryx frontend framework
- 34 Propel ORM
- 68 Community Projects
- 3 Community Ideation Board
- 30 Hackathon
- 3 PHP Bridge
- 6 Gacela Project
- 25 Job Opportunities
- 3.2K π Slack Archives
- 116 Academy
- 5 Business Users
- 370 Docker
- 551 Slack General
- 2K Help
- 75 Knowledge Sharing
- 6 Random Stuff
- 4 Code Testing
- 32 Product & Business Questions
- 69 Spryker Safari Questions
- 50 Random