Initialer Laravel Commit für BetiX
Some checks failed
linter / quality (push) Has been cancelled
tests / ci (8.4) (push) Has been cancelled
tests / ci (8.5) (push) Has been cancelled

This commit is contained in:
2026-04-04 18:01:50 +02:00
commit 0280278978
374 changed files with 65210 additions and 0 deletions

48
app/Models/Promo.php Normal file
View File

@@ -0,0 +1,48 @@
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\HasMany;
class Promo extends Model
{
use HasFactory;
protected $fillable = [
'code',
'description',
'bonus_amount',
'wager_multiplier',
'per_user_limit',
'global_limit',
'starts_at',
'ends_at',
'min_deposit',
'bonus_expires_days',
'is_active',
];
protected $casts = [
'bonus_amount' => 'decimal:4',
'min_deposit' => 'decimal:4',
'starts_at' => 'datetime',
'ends_at' => 'datetime',
'is_active' => 'boolean',
'bonus_expires_days' => 'integer',
'wager_multiplier' => 'integer',
'per_user_limit' => 'integer',
'global_limit' => 'integer',
];
public function usages(): HasMany
{
return $this->hasMany(PromoUsage::class);
}
public function userBonuses(): HasMany
{
return $this->hasMany(UserBonus::class);
}
}