Das System ist seit 20.07.2026 live; die dev-Doku spiegelt jetzt den Betriebszustand statt der Release-Vorbereitung: - dev/betrieb/: Deploy-Runbook (neu: §10 Betrieb nach Go-Live mit SFTP-Deploy-Checkliste inkl. queue:restart-Pflicht und den Betriebs-Erkenntnissen der Go-Live-Woche), Legacy-API-Parität, Umami. - dev/roadmap.md: offene Nachlauf-Punkte (Go-Live-Mails, Merge nach main, Stripe-Test-Artefakte, Key-Rotation, Alt-System-Abschaltung) und Ideen-Backlog. - dev/archive/: abgeschlossene Phasen — Migration-2026-Planung, Cutover-Runbook (mit Erledigt-Vermerk), Release-Plan/QA-Checkliste, Optimierungsphasen, Frontend-Konzepte + Responsive-Audits vom 16.07., Altsystem-Reste. - dev/README.md als Wegweiser; gitignore-Pfad der SQL-Dumps mitgezogen (dev/archive/migration-2026/sql/ bleibt untracked, ebenso dev/migration/ und dev/api/). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
72 lines
2.1 KiB
PHP
72 lines
2.1 KiB
PHP
<?php
|
|
|
|
/**
|
|
* Created by Reliese Model.
|
|
*/
|
|
|
|
namespace App\Models;
|
|
|
|
use Carbon\Carbon;
|
|
use Illuminate\Database\Eloquent\Collection;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
/**
|
|
* Class Coupon
|
|
*
|
|
* @property int $id
|
|
* @property int $payment_option_id
|
|
* @property string $code
|
|
* @property float $value
|
|
* @property int|null $on_redeem_expire
|
|
* @property int|null $is_expired
|
|
* @property Carbon|null $valid_until_date
|
|
* @property PaymentOption $payment_option
|
|
* @property Collection|UserPaymentOption[] $user_payment_options
|
|
* @property-read int|null $user_payment_options_count
|
|
*
|
|
* @method static \Illuminate\Database\Eloquent\Builder|Coupon newModelQuery()
|
|
* @method static \Illuminate\Database\Eloquent\Builder|Coupon newQuery()
|
|
* @method static \Illuminate\Database\Eloquent\Builder|Coupon query()
|
|
* @method static \Illuminate\Database\Eloquent\Builder|Coupon whereCode($value)
|
|
* @method static \Illuminate\Database\Eloquent\Builder|Coupon whereId($value)
|
|
* @method static \Illuminate\Database\Eloquent\Builder|Coupon whereIsExpired($value)
|
|
* @method static \Illuminate\Database\Eloquent\Builder|Coupon whereOnRedeemExpire($value)
|
|
* @method static \Illuminate\Database\Eloquent\Builder|Coupon wherePaymentOptionId($value)
|
|
* @method static \Illuminate\Database\Eloquent\Builder|Coupon whereValidUntilDate($value)
|
|
* @method static \Illuminate\Database\Eloquent\Builder|Coupon whereValue($value)
|
|
*
|
|
* @mixin \Eloquent
|
|
*/
|
|
class Coupon extends Model
|
|
{
|
|
protected $table = 'coupon';
|
|
|
|
public $timestamps = false;
|
|
|
|
protected $casts = [
|
|
'payment_option_id' => 'int',
|
|
'value' => 'float',
|
|
'on_redeem_expire' => 'int',
|
|
'is_expired' => 'int',
|
|
'valid_until_date' => 'datetime',
|
|
];
|
|
|
|
protected $fillable = [
|
|
'payment_option_id',
|
|
'code',
|
|
'value',
|
|
'on_redeem_expire',
|
|
'is_expired',
|
|
'valid_until_date',
|
|
];
|
|
|
|
public function payment_option()
|
|
{
|
|
return $this->belongsTo(PaymentOption::class);
|
|
}
|
|
|
|
public function user_payment_options()
|
|
{
|
|
return $this->hasMany(UserPaymentOption::class);
|
|
}
|
|
}
|