Offline payment of Child plan - 1st Subscription

12 years 10 months ago - 12 years 10 months ago #167346 by nicophp
Have 2 plans:

free plan
paid plan (child of the free plan = Silver Plan)

Steps to duplicate the issue

User have already subscribed the free plan
User login and suscribe the paid plan, by offline payment, up to printing the payment slip

Next, in subscription module, he has: "Silver Plan Subscription: unpaid. Pay Now"
  • He click on "Pay now" and system opens the Plans Tab
  • He Confirms "Pay now"

>>> error message when presenting the invoice and invoicing address <<<
Warning: createSubscriptionsAndPayment::no existing subscription for parent plan id 1 of plan 2 in new subscription ! in C:\xampp\htdocs\ayudapenitenciaria.com\components\com_comprofiler\plugin\user\plug_cbpaidsubscriptions\cbpaidsubscriptions.php on line 2079
A payment basket is pending in progress for payment for this. Are you sure that you didn't already pay for this ?. Here you can pay again:

And he follows to pay again (offline)
This generates new Payment Slip
Now Backend has 2 payments pending

subscription module still have: "Silver Plan Subscription: unpaid. Pay Now"
  • user click on "Pay now" - it opens the Plans Tab
  • user Confirms to "Pay now"

>>> error message when presenting the invoice and invoicing address <<<
Warning: createSubscriptionsAndPayment::no existing subscription for parent plan id 1 of plan 2 in new subscription ! in C:\xampp\htdocs\ayudapenitenciaria.com\components\com_comprofiler\plugin\user\plug_cbpaidsubscriptions\cbpaidsubscriptions.php on line 2079
A payment basket is pending in progress for payment for this. Are you sure that you didn't already pay for this ?. Here you can pay again:

And he follows to pay again (offline)
this generates a new Payment Slip
Now Backend has 3 payments pending

Etc, etc, etc multiplicating all

In the meantime:
  • the user has x Pending Invoices
  • the backend basket has x pending payments

Now the user is back again to "Pay Now" and, this time the user click on cancel "Payment and Subscription"

He receive the confirmation:
  • on screen, "Payment cancelled. Your request to cancel the subscription and invoice has been processed successfully".
  • and the cancellation confirmation email

But it don't change anything: the system still displays "Pay now" + the invoices for the user, The basket is also still full of the pending payments (that can still be payed !!).
  • Why should he "Pay Now" something cancelled?
  • Why is the payment basket not empty?
  • Why does the user still have x invoices pending for the same cancelled subscription?

More problems with all that multiplicated invoices are also for the accounting
  • Paying one of these basket payment leaves all other baskets open for payment and, by consequence, the user has invoices as pending, except for the paid basket.
  • 'Total payment amount pending' not corresponding to the real situation
  • If admin pay more than one of that duplicated baskets, false account balance in 'Total payment amount received'

Suggestion for Offline payments:
When user uses the offline process and click to try to pay again (eg. from 'Pay now' in the module):
  • If he choose once again to pay offline, the system should warn him about a pending payment slip and, instead of creating a new one, the system shows the original pending slip (in case of a user having lost it)
  • If he choose an other way to pay, eg. Credit card, the system, on completing the CC payment, should delete the offline pending payment invoices/basket/slip.
  • If he choose to CANCEL "Payment and Subscription", the system should delete the offline pending of payment invoices/basket/slip and reset the module.

Please Log in to join the conversation.

12 years 9 months ago - 12 years 9 months ago #169278 by krileon

Warning: createSubscriptionsAndPayment::no existing subscription for parent plan id 1 of plan 2 in new subscription ! in C<span>:</span><span>\</span>xampp\htdocs\ayudapenitenciaria.com\components\com_comprofiler\plugin\user\plug_cbpaidsubscriptions\cbpaidsubscriptions.php on line 2079

This means your plan used to be a child plan. The user subscribed. You then changed it from a child plan. This logs to database their subscription has a parent plan, which it no longer does and results in error. Please navigate to your database and fix their database row. Please understand it is ill-advised to alert plans drastically once there are active subscriptions. If using test subscriptions it's best to delete them when done so the record is removed and you can re-test cleanly.

If he choose to CANCEL "Payment and Subscription", the system should delete the offline pending of payment invoices/basket/slip and reset the module.

If you cancel payment it'll delete the basket. It's possible the errors you're experiencing are preventing the workflows from working properly.


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.399 seconds

Facebook Twitter LinkedIn