Skip to content
This repository has been archived by the owner on May 26, 2023. It is now read-only.

Releases: bpuig/laravel-subby

v3.0.0 - Important notice

25 Apr 11:02
7cbaa73
Compare
Choose a tag to compare

Notice: Since this package is used by me only and maybe 1 or 2 people. I'll allow myself to remove v1 and v2 and launch v3 because previous versions were really messed up. This version is working fine.

Breaking Changes

  • Rename User to Subscriber for a more generic use. Was not thought that a subscriber could be a customer, team, account... etc
  • ofUser() method in PlanSubscription now is ofSubscriber()

Changed method names to avoid confusion with possible scopes.

$user->subscribedTo($planId);
$user->subscription('main')->active();
$user->subscription('main')->canceled();
$user->subscription('main')->ended();
$user->subscription('main')->onTrial();

Now are:

$user->isSubscribedTo($planId);
$user->subscription('main')->isActive();
$user->subscription('main')->isCanceled();
$user->subscription('main')->hasEnded();
$user->subscription('main')->isOnTrial();

Changes

  • Default value in plans table for invoice_period is now 1.
  • Removed softDeletes

v0.4.2

16 Apr 10:24
49326fa
Compare
Choose a tag to compare

Fixes


  • changePlan() in scheduled service trait actually changes plan and then succeeds, not only succeeds.

Other


  • PHP 8 support

0.4.1

26 Jan 19:08
f09e86c
Compare
Choose a tag to compare

Fixes


  • Solved wrong success action on IsScheduleService.

0.4.0

21 Jan 17:01
01b0429
Compare
Choose a tag to compare

New


  • Added uncancel() method to PlanSubscription. This removes all cancel flags.
  • PlanSubscriptionSchedule model scope pending() accepts Carbon date as parameter to show pending until date.
    • SubscriptionScheduleQueuerJob accepts parameter for date limit.

Changes


  • Method renew() no longer checks for ended period, only cancelled.

Other


  • Minor fix with unused parameter.
  • Minor doc changes

0.3.1

17 Jan 15:38
74c6467
Compare
Choose a tag to compare

Fixes


  • Fix 'datetime' cast.
  • In schedule setSchedule() method returns created schedule object.

0.3.0

13 Dec 18:38
1e600c0
Compare
Choose a tag to compare

New


  • Number of schedules per subscription can now be limited via config.
    • Ability to check if subscription limit has been reached using reachedScheduleLimit() on subscription model.
    • Schedules per subscription config can be ignored with ignoreLimit() on subscription scheduling.

Other


  • Moved schedules() relationship from PlanSubscription model to IsScheduled trait. Since it's only available if trait is applied.

0.2.1

13 Dec 15:54
400a668
Compare
Choose a tag to compare
  • Fixed wrong config name that did not allow loading Subscription Schedules relationship.

0.2.0

15 Nov 17:15
70ee40b
Compare
Choose a tag to compare
  • Added scheduling capabilities. In this release you can set a future date for a subscription plan change.

0.1.2

14 Nov 18:55
Compare
Choose a tag to compare
  • Remove docs from README.md

You can check the new documentation at https://bpuig.github.io/laravel-subby/

0.1.1

13 Nov 10:33
508021f
Compare
Choose a tag to compare
  • Add editor and gitignore configs