Closed Cragstar closed 4 years ago
I see the issue and I'll fix it. Thanks for reporting!
Fixed now in v11.2.0
With a subscription item this only changes the quantity to the value passed in the increment and not by the number that is passed. $user->subscription('default')->incrementQuantity(5, 'chat-plan'); Will change the quantity to 5 and not from say 2 -> 7 which an increment of 5 would do?
You're right and good that you spotted this. I'll tackle this today 👍
Description:
When using the following method to update the quantities on a specific plan on a subscription $user->subscription('default')->incrementQuantity(5, 'chat-plan'); I receive the following error
"This method requires a plan argument since the subscription has multiple plans."
Steps To Reproduce:
Create a function server side to increase the quantities of the plan (i.e additional users above the base number that comes with the main subscription) Condensed version of the code
$type = Subscription::where('business_id', $userID)->firstOrFail();
$subscribe = $user->subscription($type->name)->incrementQuantity(1, 'plan_NUMBERISHERE');
Call this function via the web interface
Laravel return the error stated above
You can see I am supplying a plan number to the method.