I'm trying to understand how 'exclusive' plans and 'parent' plans work together.
I create a plan A, and then I create a Plan B which is Plan A's only 'exclusive' (and therefore mandatory) child.
At registration, its only possible to subscribe to Plan A by also subscribing to Plan B at the same time (as is expected)
but it is then possible for the user to unsubscribe from Plan B, leaving them with a subscription to Plan A but with no subscription to Plan B.
Is it possible to ensure that the user cannot be subscribed to a parent plan without being subscribed to one of its exclusive children ?
Here is how to recreate it:
create a 'new user subscription plan' with all the default settings (Plan A)
create a second 'new user subscription plan' (Plan
set the 'parent plan' of 'Plan B' to 'Plan A'
confirm that 'Exclusive Plan' of 'plan B' is set to 'Exclusive'
sign up to Plan B using the 'Url of plan to display only this plan ('-' to display multiple plans)'
once logged in, navigate to /index.php?option=com_comprofiler&view=pluginclass&plugin=cbpaidsubscriptions&do=display_subscriptions
The layout is
Plan A
Active, expiring on 09/05/21
Plan B
Active, expiring on 09/05/21
[renew button]
[unsubscribe button]
[renew button]
[unsubscribe button]
Clicking the first 'unsubscribe button' unsubscribes the user from Plan B (as would be expected because of the indenting of the layout).
The user is now subscribed to Plan A, but not to Plan B.
I thought that since 'Plan B' was the only exclusive plan, it's subscription would be mandatory. ie it wouldn't be possible to be subscribed to plan A without also being subscribed to plan B.
Is there some way to ensure that it's not possible to be subscribed to a parent plan without also being subscribed to one of its exclusive and mandatory children ?
Thanks