1
  • I created a Rule on event 'After adding to cart' to action 'Page redirect' to redirect straight to Checkout page (at /checkout) so it skips the Cart page.
  • The cart page by default has the Line Item: Delete button and its title is 'Remove' and it works.
  • I decided I wanted same in the Checkout page and it is easy to add, just edit the view and add the 'Line Item: Delete button'.
  • But it does not work. Also for some reason its title is 'Delete', not 'Remove'.
  • When clicking Delete it refreshes the page giving errors 'There are errors on the page. Please correct them and resubmit the form.' under 'Shopping cart contents' and another error under 'Billing information' which simply says to fill in the form details:
Address field is required.
Postal code field is required.
City field is required.
Full name field is required.

Which makes no sense, I'm just trying to update the cart contents inside the checkout page.

Even better. If I do fill the forms and click to delete the product from cart, it redirects straight to Review page. But I didn't even click the 'Continue to next step' button.

?

  • Have never done something of that sort but what I assume is, once you move ahead with checkout, a order is created with status IN CHECKOUT or something like that. So until a product is there in cart, you can remove that & but once you enter into checkout & order id with other details is created...product can't be removed. I can be wrong & that's why putting this as comment. – RajeevK Aug 2 '15 at 13:10
  • What is actually your question? Note: your question does not even include a "?" mark ... And why is this question tagged with "hooks"? Please EDIT your question to make that clear (to avoid we have to guess what the question actually is). – Pierre.Vriens Aug 2 '15 at 13:29
  • OK, I included the ? for you. Hope you understand now. @RajeevK thanks for explanation, it makes sense now. Too bad until this day there is no normal one-page checkout for Commerce that supports Views. Move your answer to Answer and I will select it. Cheers. – Optimus Prime Aug 2 '15 at 16:44
1

Have never done something of that sort but what I assume is, once you move ahead with checkout, a order is created with status IN CHECKOUT or something like that.

So until a product is there in cart, you can remove that & but once you enter into checkout & order id with other details is created...product can't be removed. Maybe someone from Drupal Commerce maintainer can confirm more on this..

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.