'boolean', 'show_subtitle' => 'boolean', 'show_button' => 'boolean', 'sort_order' => 'integer', 'is_active' => 'boolean', ]; } public function scopeActive($query) { return $query->where('is_active', true); } public function scopeForZone($query, string $zone) { return $query->where('zone', $zone); } public function scopeOrdered($query) { return $query->orderBy('sort_order')->orderBy('id'); } public function getImageUrlAttribute(): ?string { if (!$this->image_path) { return null; } if (Str::startsWith($this->image_path, ['http://', 'https://', '/'])) { return $this->image_path; } if (Str::startsWith($this->image_path, 'uploads/')) { return asset($this->image_path); } return '/storage/' . ltrim($this->image_path, '/'); } }