23-01-2026

This commit is contained in:
Kevin Adametz 2026-01-23 17:33:10 +01:00
parent 07959c0ba2
commit 854ce02bf6
166 changed files with 32909 additions and 1262 deletions

View file

@ -0,0 +1,38 @@
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
class DisplayVideo extends Model
{
protected $fillable = [
'filename',
'title',
'position',
'sort_order',
'is_active',
];
protected $casts = [
'is_active' => 'boolean',
'position' => 'integer',
'sort_order' => 'integer',
];
/**
* Scope für aktive Videos in sortierter Reihenfolge
*/
public function scopeActive($query)
{
return $query->where('is_active', true)->orderBy('sort_order');
}
/**
* Gibt den vollständigen Pfad zum Video zurück
*/
public function getFullPathAttribute(): string
{
return "assets/{$this->filename}";
}
}