Skip to content

Commit

Permalink
Replace subscriptions plan (#136)
Browse files Browse the repository at this point in the history
* ✨ Replace subscriptions package

* ✅ Update tests

* Publish laravel stub

* Fix code styling

* Fix code styling

---------

Co-authored-by: mckenziearts <[email protected]>
  • Loading branch information
mckenziearts and mckenziearts authored Oct 3, 2023
1 parent d401310 commit e870291
Show file tree
Hide file tree
Showing 49 changed files with 1,166 additions and 293 deletions.
2 changes: 1 addition & 1 deletion app/Http/Controllers/HomeController.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

use App\Models\Article;
use App\Models\Discussion;
use App\Models\Premium\Plan;
use App\Models\Plan;
use App\Models\Thread;
use Illuminate\Contracts\View\View;
use Illuminate\Support\Facades\Cache;
Expand Down
9 changes: 3 additions & 6 deletions app/Models/Premium/Plan.php → app/Models/Plan.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,18 @@

declare(strict_types=1);

namespace App\Models\Premium;
namespace App\Models;

use App\Enums\PlanType;
use App\Models\Premium\IdeHelperPlan;
use Illuminate\Database\Eloquent\Builder;
use Illuminate\Database\Eloquent\Factories\HasFactory;
// use Rinvex\Subscriptions\Models\Plan as Model;
use Illuminate\Database\Eloquent\Model;
use Laravelcm\Subscriptions\Models\Plan as Model;

/**
* @mixin IdeHelperPlan
*/
final class Plan extends Model
{
use HasFactory;

public function scopeDeveloper(Builder $query): Builder
{
return $query->where('type', PlanType::DEVELOPER->value);
Expand Down
17 changes: 0 additions & 17 deletions app/Models/Premium/Feature.php

This file was deleted.

17 changes: 0 additions & 17 deletions app/Models/Premium/Subscription.php

This file was deleted.

17 changes: 0 additions & 17 deletions app/Models/Premium/SubscriptionUsage.php

This file was deleted.

1 change: 1 addition & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
"laravel/slack-notification-channel": "^2.5",
"laravel/socialite": "^5.6.3",
"laravel/tinker": "^2.8.1",
"laravelcm/laravel-subscriptions": "^1.0",
"livewire/livewire": "^2.12.3",
"lorisleiva/laravel-actions": "^2.6",
"mckenziearts/blade-untitledui-icons": "^1.2",
Expand Down
Loading

0 comments on commit e870291

Please sign in to comment.