Jump to content

Interac gateway after upgrade to 6.4.2


windsurfer

Recommended Posts

In the file /modules/gateway/ e_Payments_Interac/gateway.class.php:

Find near line 173:

		if (!empty($item['product_options'])) $product['product_options'] = implode(' ',unserialize($item['product_options']));

Change to:

		$list = array();
		if (!empty($item['product_options'])) {
			if (($list = unserialize($item['product_options'])) !== false) {
			} else {
				if(method_exists($order,'unSerializeOptions')) {
					$list = $order->unSerializeOptions($item['product_options']);
				} else {
					if(($list = cc_unserialize($item['product_options'])) !== false) {
					} else if (($list = cc_unserialize(base64_decode($item['product_options']))) !== false) {
					} else { $list = explode("\n", $item['product_options']);
					}
				}
			}
		}
		$product['product_options'] = implode(' ', $list);




Find near line 69:

		$options = explode("\n", $item['product_options']);

Change to:

		if(method_exists($order,'unSerializeOptions')) {
			$options = $order->unSerializeOptions($item['product_options']);
		} else {
			if(empty($item['product_options'])) {
				$options = array();
			} else if(($options = cc_unserialize($item['product_options'])) !== false) {
			} else if (($options = cc_unserialize(base64_decode($item['product_options']))) !== false) {
			} else {
				$options = explode("\n", $item['product_options']);
			}
		}

 

Link to comment
Share on other sites

Another issue

Before the upgrade i pasted code in the email template to show the interac information in the customer email for their reference. And it did show that information in the customer email but now after the upgrade it doesn't.

<p>{if $BANK}</p>

<div class="payment_method"><strong>Pay by e-Payment Bank Transfer - Interac</strong><br />
&nbsp;
<div><strong>{$LANG.gateway.bank_name}:</strong> {$MODULE.bankName}</div>

<div><strong>{$LANG.gateway.bank_account_name}:</strong> {$MODULE.accName}</div>

<div><strong>e-Payment Email Address:</strong> {$MODULE.addressCode}</div>

<div><strong>e-Payment Secret Question ?</strong> {$MODULE.secretCode}</div>

<div><strong>Answer to Secret Question ?</strong> {$MODULE.answerCode}</div>
</div>

<p>{/if}</p>

Link to comment
Share on other sites

The Interac module does send, as a courtesy, the Cart:Order Confirmed email. This action is a setting in the module.

Making BANK info available is also a setting in the module.

So, if the BANK info appears on the printable payment form, then it should appear in the email -- assuming the added code is still part of the email contents.

 

Link to comment
Share on other sites

I don't see a setting in the interac settings to send an email I had to change the setting in the store settings to pending in order for the customer and admin email to be sent, if that setting is Processing the email won't get sent to admin or the customer. I am sure this is a shortcoming in the module and i have had communication with the creator and he doesn't think it is important for anybody to get an email regarding the purchase to which i strongly disagree.

The email template hasn't changed and the BANK info appears on the printable form but not in the email anymore and the added code is still in the email template.

 

image.png.33c0bfe3dfdbcc771b4d48c6f3ec63fe.png

Link to comment
Share on other sites

Yes that is correct but i am not talking about a Bank transfer i am talking about email interac payment which is different. I also did the modification in the file mentioned. My point is that first of all the module doesn't have the means to send an email to admin or the customer unless the status is set to pending and also after the upgrade to 6.4.2 the information i talked about as below doesn't show up in the email anymore.

Link to comment
Share on other sites

You have verified that the following is in the email content template:

<p>{if $BANK}</p>
<div class="payment_method"><strong>Pay by e-Payment Bank Transfer - Interac</strong><br />
  &nbsp;
  <div><strong>{$LANG.gateway.bank_name}:</strong> {$MODULE.bankName}</div>
  <div><strong>{$LANG.gateway.bank_account_name}:</strong> {$MODULE.accName}</div>
  <div><strong>e-Payment Email Address:</strong> {$MODULE.addressCode}</div>
  <div><strong>e-Payment Secret Question ?</strong> {$MODULE.secretCode}</div>
  <div><strong>Answer to Secret Question ?</strong> {$MODULE.answerCode}</div>
</div>
<p>{/if}</p>

Please make this change and test:

From:

<p>{/if}</p>

To:
{else}BANK is empty. 
<p>{/if}</p>

Let us know if you see "BANK is empty" or nothing at all.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...