feat: add middleware for cookie encryption, CSRF verification, string trimming, and maintenance request prevention; implement Designer resource management with CRUD pages and permissions

This commit is contained in:
pacnpal
2025-02-26 21:28:02 -05:00
parent 0e61f7d694
commit 2436e8cec6
46 changed files with 4623 additions and 2391 deletions

View File

@@ -2,26 +2,27 @@
namespace App\Models;
use App\Traits\HasSlugHistory;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\HasMany;
use Illuminate\Support\Str;
class Designer extends Model
{
/**
* The attributes that are mass assignable.
*
* @var array<string>
*/
use HasSlugHistory;
protected $fillable = [
'name',
'slug',
'bio',
'description',
'website',
'founded_date',
'headquarters',
];
protected $casts = [
'founded_date' => 'date',
];
/**
* Boot the model.
*/
protected static function boot()
{
parent::boot();
@@ -32,11 +33,8 @@ class Designer extends Model
}
});
}
/**
* Get the rides designed by this designer.
*/
public function rides(): HasMany
public function rides()
{
return $this->hasMany(Ride::class);
}