mirror of
https://github.com/coollabsio/coolify.git
synced 2026-11-06 13:10:37 -04:00
feat(cleanup): purge stale unsubscribed teams (#11668)
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
|
||||
namespace Database\Factories;
|
||||
|
||||
use App\Models\Subscription;
|
||||
use App\Models\Team;
|
||||
use Illuminate\Database\Eloquent\Factories\Factory;
|
||||
|
||||
/**
|
||||
* @extends Factory<Subscription>
|
||||
*/
|
||||
class SubscriptionFactory extends Factory
|
||||
{
|
||||
protected $model = Subscription::class;
|
||||
|
||||
public function definition(): array
|
||||
{
|
||||
return [
|
||||
'team_id' => Team::factory(),
|
||||
'stripe_customer_id' => 'cus_'.$this->faker->bothify('??????????'),
|
||||
'stripe_subscription_id' => null,
|
||||
'stripe_invoice_paid' => false,
|
||||
'stripe_cancel_at_period_end' => false,
|
||||
'stripe_plan_id' => null,
|
||||
'stripe_past_due' => false,
|
||||
'stripe_trial_already_ended' => false,
|
||||
];
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user