lots of progress
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class Subscription extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
protected $fillable = [
|
||||
'name',
|
||||
'description',
|
||||
'price',
|
||||
'duration_days',
|
||||
'features',
|
||||
'min_score',
|
||||
'verification_interval_minutes',
|
||||
'is_active'
|
||||
];
|
||||
|
||||
protected $casts = [
|
||||
'features' => 'array',
|
||||
'is_active' => 'boolean',
|
||||
'price' => 'decimal:2',
|
||||
'duration_days' => 'integer',
|
||||
'min_score' => 'integer',
|
||||
'verification_interval_minutes' => 'integer'
|
||||
];
|
||||
|
||||
public function users()
|
||||
{
|
||||
return $this->hasMany(UserSubscription::class);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user