Jump to content

[SOLVED]Two currencies - different account number for each


Recommended Posts

Hi there,

I'm going to have two currencies - USD and EURO. Is there any way to define different bank account numbers for each of them? So when the user switches to USD, he gets USD account number in the bank wire details summary, and if he switches to EURO, he gets a different, EURO account number?

thanks in advance
m.

Link to comment
Share on other sites

You'll need to modify modules/bankwire/validation.php and change the following lines:

$mailVars = array(
   '{bankwire_owner}' => Configuration::get('BANK_WIRE_OWNER'),
   '{bankwire_details}' => nl2br(Configuration::get('BANK_WIRE_DETAILS')),
   '{bankwire_address}' => nl2br(Configuration::get('BANK_WIRE_ADDRESS'))
);



to:

if ($currency->id == 1)
{
   $mailVars = array(
       '{bankwire_owner}' => 'Enter bank wire owner for first currency here',
       '{bankwire_details}' => 'Enter bank wire details for first currency here',
       '{bankwire_address}' => 'Enter bank wire address for first currency here'
   );
}
elseif ($currency->id == 2)
{
   $mailVars = array(
       '{bankwire_owner}' => 'Enter bank wire owner for second currency here',
       '{bankwire_details}' => 'Enter bank wire details for second currency here',
       '{bankwire_address}' => 'Enter bank wire address for second currency here'
   );
}



Change 1 and 2 to the IDs of USD and EURO. Add more if blocks if you have more currencies.

Link to comment
Share on other sites

  • 8 months later...

Hi, thanks for the tip, but it doesnt seem to be working for Prestashop vershion 1.3.1.1 and higher. I'm quite sure I entered the details correctly, Ive tested with simple change

$mailVars = array(
   '{bankwire_owner}' => 'bla bla',
   '{bankwire_details}' => '123456',
   '{bankwire_address}' => 'address 123'
);



but I still get the account details from back office.

EDIT: Im testing on localhost so Im not checking the result in emails but on Order confirmation page, where its incorrect.... I guess this change is working only for mails?

Link to comment
Share on other sites

  • 13 years later...
On 2/16/2011 at 11:39 AM, webplus said:

I found the best solution to clone the bankwire module to another one and setup module restriction per currency in Payment tab. This way you can still use the administration and translations.

Man - what a great idea - I will check if it works like this.👍

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...