News:

Support the VirtueMart project and become a member

Main Menu

Payson payment plugin not setting order status correct

Started by t68, December 30, 2014, 15:55:43 PM

Previous topic - Next topic

t68

Hi!
I use Paypal and Payson payment plugins in our VM. Paypal works fine but Payson fails to set order status correct. Whatever happens after being redirected to he payson gateway upon confirming order in VM, the order status is set to "confirmed". In the Payson module settings in VM there are two order status options. One is for successful transaction which I have set to "confirmed". The other is for Failed transactions which I have set to "cancelled".

If I cancel an order in the Payson gateway it sends me back to the VM-page with  this url:
http://nnnnnnnnn.se/index.php?option=com_virtuemart&view=pluginresponse&task=pluginUserPaymentCancel&on=xxx&TOKEN=long_string_here_from_payson
(I've replaced w some text where nnnnnnn=url and xxx=payson order no)
I dont know is there is a problem here or if there is some api communication in the background that is problematic.

If I cancel a Paypal order the same way it returns a slightly different url:
http://nnnnnnnnn.se/index.php?option=com_virtuemart&view=pluginresponse&task=pluginUserPaymentCancel&on=yyyyyyyy&pm=1&Itemid=257&lang=
Here yyyyy is the VM order number.

The plugin is said to be working up to VM2.6.8 but our VM is on 2.6.12.2 and J2.528. Can this be the issue?
Thanks for any help solving this.







GJC Web Design

To me it hard to see how the cancel at least can work

the pm= is the payment method id - even if it gets back to the payson payment method  plgVmOnUserPaymentCancel() function how would it know that it is the intended payment method as the pm isn't passed?

Unless it is encrypted in the TOKEN etc

but without the plugin to look at very difficult to advise - but it seems differently coded in this respect from the normal way the payment plugins are...
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

t68

Thanks for your response GJC!
I've asked Payson support to look into this too of course.
But if you want to check the plugin out its here:
https://www.payson.se/integration/moduler/virtuemart

Skickat från min HTC One via Tapatalk


GJC Web Design

had a quick look .. the function for cancel does nothing afaiks

function plgVmOnUserPaymentCancel() {
        if (!class_exists('VirtueMartModelOrders')) {
            require(JPATH_VM_ADMINISTRATOR . DS . 'models' . DS . 'orders.php');
        }
    }

that's it - compare for example to the Paypal function plgVmOnUserPaymentCancel()
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

t68

Thank´s for finding this out! In which file should I look for and try to fix this (or at least point the Payson guys in that direction)?

GJC Web Design

GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation