First off, thank you for addressing one of the most glaring shortcomings of Drupal Commerce.
However, to quote Wikipedia, "A receipt is a written acknowledgment that a specified article or sum of money as an exchange for goods or services. The receipt is evidence of purchase of the property or service obtained in the exchange." (emphasis added) The documents generated by this module are invoices, not receipts, because they provide no indication of whether or not the invoice has already been paid. As a first stab toward making the payment info available in the template, we can add the following lines to _commerce_invoice_receipt_get_invoice_info():
$info['payment_method'] = $order->data['payment_method'];
$info['status'] = $order->status;
$payments = commerce_payment_transaction_load_multiple(NULL, array('order_id' => $order->order_number));
if (is_array($payments)) {
foreach($payments as $payment) {
$info['payments'] .= $payment->message .'<br />';
}
}
Thank you for your consideration.
Closed: outdated
2.0
Code
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.
No activities found.