VirtueMart Forum

VirtueMart 2 + 3 + 4 => Plugins: Payment, Shipment and others => Topic started by: MrMazze on September 30, 2014, 16:54:00 PM

Title: Process order After Payment Response
Post by: MrMazze on September 30, 2014, 16:54:00 PM
Hello Forum,

i need a plugin, which is able to process the order AFTER the payment has been successfully finished independent of the payment method. For Payment-Plugins, there is a trigger like "plgVmOnPaymentResponseReceived", but i don't need a payment plugin. My plugin should work with any payment option.

As far as i can see there is a trigger "plgVmConfirmedOrder", but it is called before the payment is done.

Is there another trigger?
Title: Re: Process order After Payment Response
Post by: GJC Web Design on October 01, 2014, 00:34:40 AM
function plgVmOnUpdateOrderPayment ($data,$old_order_status) {

if($data->order_status=='C'){

blah blah

}
}
Title: Re: Process order After Payment Response
Post by: MrMazze on October 01, 2014, 12:49:17 PM
It works! Thank you!
Title: Re: Process order After Payment Response
Post by: MrMazze on October 01, 2014, 14:28:32 PM
No, wait: When i use PayPal in sandbox-mode and abort the payment process the event is fired. When i finish the payment, the event is not fired.