1

Is there any method to change the order increment id while submitting the order? My client wants to change the prefix of order_id if the order is paid through a particular payment gateway.

Please let me know. Thanks!

0

You can try this http://www.warpconduit.net/2012/04/18/how-to-change-the-order-increment-id-and-prefix-in-magento/

Thecoderin,it too complex process to change order_id on basic of payment is done/not. Because of you

1.`want to prefix only case of order paid`, and
2.`Most important is this field is auto increment field.`

As a alternative Solution:

add new field to order table sales_flat_order and sales_flat_order_grid

then using magento event/observer you update field.

Magento event/list https://www.nicksays.co.uk/magento-events-cheat-sheet-1-8/

  • Thanks. Can you let me know why we cannot change the order increment id before submitting the order? Is the order id set before we submit the order? – Anish Karim Mar 17 '15 at 4:25

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.