Possible solution:
In order to create a 'pending' invoice, the payment method you use for the order must allow you to.
For that you need to add in the payment method's model this member:
protected $_canCapture = true;You can add it right under
protected $_code = 'PAYMENT CODE HERE';For example if you want to do this for Check/money order you need to add the line above in app/code/core/Mage/Payment/Model/Method/Checkmo.php
After this when you create an invoice you will have an option near the save button to set the invoice status. (see picture attached). To create a pending invoice select 'Not capture'.
If you want to mark it later as paid edit the invoice and between the buttons on to one called 'Capture' (see picture). Well you get the idea....
Thank you so much for sharing this info. It was a real lifesaver.
ReplyDeleteHey. Great info. But can this be done without changing core stuff (so that you can still update)? Like overriding the model in /app/code/local?
ReplyDeleteHello Dakira. Yes you can. You can override the payment method model just like any other model (or block or helper) and add the line I suggested in your class.
ReplyDeleteCan i also use it in magento 1.5?
ReplyDeleteYes. Try it.
ReplyDeleteYou saved my day ;)
ReplyDeleteShould this also work for pre-existing invoices, or only invoices created as 'pending' after applying this override?
ReplyDeleteHello.
DeleteIt works only for invoices created after applying the update.
Marius.
You know, if real accountants had been consulted on purchase order processing by the geeks who wrote this sorry stuff, it would not be necessary to tweak it like this. Obviously, the programmers who wrote this do not have to deal with invoicing. Since when is an invoice 'paid' just because it was printed or emailed?? How is a store owner expected to know what is due if all invoices are marked 'paid'?? Another downside to Magento....
ReplyDelete