CBsubs trigger order

5 years 7 months ago #307168 by activha
Replied by activha on topic CBsubs trigger order
We are sending the basket data to an external script to have a pdf invoice when the basket is completed for Stripe gateway and when the basket is pending for offline gateway.

For Stripe and automatic gateways, we use onCPayAfterPaymentStatusUpdateEvent
[var2_payment_status] REGEX /Completed|Processed/
[var2_gateway_account] REGEX /1|2|5|12/

Action PHP
Output Silent

And we send
$payment_basket = array (
'date' => $variables->date,
'user_id' => $variables->user_id,
'txn_type' => $variables->txn_type,
'txn_id' => $variables->txn_id,
'payment_type' => $variables->payment_type,
'address_street' => $variables->address_street,
'address_city' => $variables->address_city,
'address_state' => $variables->address_state,
'address_zip' => $variables->address_zip,
'address_country' => $variables->address_country,
'payer_business_name' => $variables->payer_business_name,
'first_name' => $variables->first_name,
'last_name' => $variables->last_name,
'payer_email' => $variables->payer_email,
'contact_phone' => $variables->contact_phone,
'vat_number' => $variables->vat_number,
'item_name' => $variables->item_name,
'item_number' => $variables->item_number,
'quantity' => $variables->quantity,
'custom' => $variables->custom,
'invoice' => $variables->invoice,
'tax' => $variables->tax,
'payment_date' => $variables->payment_date,
'shipping' => $variables->shipping,
'mc_currency' => $variables->mc_currency,
'mc_fee' => $variables->mc_fee,
'mc_gross' => $variables->mc_gross,
'mc_handling' => $variables->mc_handling,
'mc_shipping' => $variables->mc_shipping,
'payment_fee' => $variables->payment_fee,
'payment_gross' => $variables->payment_gross,
'basket_items' => $variables->loadPaymentItems()
);

Please Log in to join the conversation.

5 years 7 months ago #307174 by krileon
Replied by krileon on topic CBsubs trigger order
Try using onCPayAfterPaymentBasketUpdated.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.
The following user(s) said Thank You: activha

Please Log in to join the conversation.

5 years 7 months ago - 5 years 7 months ago #307352 by activha
Replied by activha on topic CBsubs trigger order
onCPayAfterPaymentBasketUpdated does not fire the auto action and nothing has been sent since the 4 of september then.

I guess we have to revert to onCPayAfterPaymentStatusUpdateEvent :-(

Is there a solution to resend all baskets data since the 4th of september to our invoice gateway ?

We have a lot of invoices and would need a solution

Please Log in to join the conversation.

5 years 7 months ago #307356 by krileon
Replied by krileon on topic CBsubs trigger order

Is there a solution to resend all baskets data since the 4th of september to our invoice gateway ?

If you can do it via database then you could just use the _cbsubs_payment_baskets table in your query. Aside from that no.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

5 years 7 months ago #307358 by activha
Replied by activha on topic CBsubs trigger order
Could I copy the auto action then remove the triggers and add date conditions between 4 of september and now ? and then trigger it manually with the auto action link ?

If yes how can I write the date conditions with CB ?

Please Log in to join the conversation.

5 years 7 months ago #307359 by krileon
Replied by krileon on topic CBsubs trigger order

Could I copy the auto action then remove the triggers and add date conditions between 4 of september and now ? and then trigger it manually with the auto action link ?

No, that's not how CB Auto Actions works. It acts on a trigger at the time of the trigger being fired. Running in manually won't do anything as it has none of the variables that would be sent by the trigger.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.224 seconds

Facebook Twitter LinkedIn