Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Need some help on payment processing


iamcanadian2

Recommended Posts

As of now, PaySystems does not accept any kind of "currency" flag. Basically, you would have to have your PaySystems account in $USD or $CAD and have your shop checkout ONLY in the currency that your PaySystems account is in.

 

Myself, even though I'm in Canada, have my PaySystems account set to $USD, and ONLY have $USD in my shop. Just makes things simpler...(but still a pain)

Link to comment
Share on other sites

This is what I have done/want to do::

 

I have installed Paysystems twice in my store. I named one paysystems & one paystemsusa. I have 2 accounts set up with Paysystems, 1 in Canadian funds, 1 in US funds (two different logins).

 

Right now I can enable both paysystems and paysystemsusa & they go to the correct payment page on the Paysystems website. I can set the zone so that if the customer is in Canada, only the Canadian credit card payment will show up on the payment screen & the same for US, BUT the problem is if they are not browsing in the currency of the country they live in, then the total passed to Paysystems is the correct amount, but not the correct currency (so if they live in the US, but are browsing in CAD currency, they will pay $10 US for something that was $10 CAD).

 

Without selecting any zone, I can also have both options show up on the payment screen and write something like the following "Canadian customers select here for credit card payment" & "US customers select here". They will then directed to the correct Paysystems screen, BUT the same problem exists, if the customer is not browsing in the currency they wish to pay, then they aren't given the correct currency amount.

 

So I want to avoid that by having oscommerce recognize what currency they are currently browsing & then either show the US customer Paysystems or the Canadian Customer Paysystems, NOT both.

 

Basically what "I think" I need to do is to change the following zone code to read the currency value instead of the zone in paysystems.php & paysystemsusa.php??

 

 

CURRENT CODE FOR ZONE:::

 

// class methods
   function update_status() {
     global $order;

     if ( ($this->enabled == true) && ((int)MODULE_PAYMENT_PAYSYSTEMS_ZONE > 0) ) {
       $check_flag = false;
       $check_query = tep_db_query("select zone_id from " . TABLE_ZONES_TO_GEO_ZONES . " where geo_zone_id = '" . MODULE_PAYMENT_PAYSYSTEMS_ZONE . "' and zone_country_id = '" . $order->billing['country']['id'] . "' order by zone_id");
       while ($check = tep_db_fetch_array($check_query)) {
         if ($check['zone_id'] < 1) {
           $check_flag = true;
           break;
         } elseif ($check['zone_id'] == $order->billing['zone_id']) {
           $check_flag = true;
           break;
         }
       }

       if ($check_flag == false) {
         $this->enabled = false;
       }
     }
   }

 

AND

tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added) values ('Payment Zone', 'MODULE_PAYMENT_PAYSYSTEMS_ZONE', '0', 'If a zone is selected, only enable this payment method for that zone.', '6', '2', 'tep_get_zone_class_title', 'tep_cfg_pull_down_zone_classes(', now())");

 

Does anyone know how I can modify the code above to do what I want?

 

Thanks to anyone who can help :)

Link to comment
Share on other sites

Anyone? I'm trying to screen capture exactly what I want to change, but my Prt Scrn button won't work.... :angry:

 

Anyway I hope this makes sense, basically in Paysystems admin I want to change:

 

Payment Zone
If a zone is selected, only enable this payment method for that zone.
--none--
Canada Payment Zone
USA Payment Zone

 

To the following:::

 

Payment Currency
If a currency is selected, only enable this payment method for that currency.
--none--
Canada Payment Zone
USA Payment Zone

 

Of course, not only the wording needs to be changed, but the functionality as well.

Link to comment
Share on other sites

  • 3 months later...
  • 2 months later...

Archived

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

×
×
  • Create New...