Page 1 of 1

Payment Method not showing on Order Confirmation

Posted: Fri Nov 12, 2010 12:56 pm
by mfreeze
I noticed this in 7.0.5 but checked other releases and it is happening there also. On the order confirmation email there is a entry for Payment Method but it always seems to be blank. The code in the default template is

Code: Select all

<td class="Email" width="50%">
<strong>Payment Method:</strong>
<div style="padding-left:30px;">
#foreach($payment in $payments)
$payment.PaymentMethodName<br />
$payment.ReferenceNumber<br />
#end
</div>
</td>
The Payment method shows in the admin under payments and on vieworder.aspx. Why would it not be showing in the email?

Re: Payment Method not showing on Order Confirmation

Posted: Tue Dec 07, 2010 1:10 am
by tester
Any comments?

Re: Payment Method not showing on Order Confirmation

Posted: Wed Dec 08, 2010 5:53 am
by s_ismail
Which payment gateway you are using?

Re: Payment Method not showing on Order Confirmation

Posted: Wed Dec 08, 2010 6:37 am
by mazhar
Most probably in this case order is placed via Google Checkout. Seems like our order notification Email gets triggered before we this name information is initialized causing this issue. There doesn't seems to be any simple workaround for this. The only thing that I could think is to don't include payment method name information when its null or empty. For example by doing something like

Code: Select all

#if($payments.Count > 0)

<strong>Payment Method:</strong>
<div style="padding-left:30px;">
#foreach($payment in $payments)
$payment.PaymentMethodName<br />
$payment.ReferenceNumber<br />
#end
</div>

#end