I want to add extra information in a transactional email when the order has a product which is backordered.
I know where and how to edit the email templates following this guide: http://www.flyingtophat.co.uk/blog/2011/08/31/magento-displaying-custom-attributes-in-emails.html
The problem is I don't know how to check if the order has backorder items. I found that the table
sales_flat_order_item has a a field
qty_backordered but it has no value and is
I can get the value of the field with the following code
My question is, why is the value of the field
NULL? How can I make sure the field gets populated with the amount of items which are backordered? Or maybe there is another solution?
The only thing I actually need is to check if a placed order has at least 1 item backordered (so I can display extra backorder information).