ÿØÿà JFIF H H ÿÛ C GIF89;
| System: Linux srv913213 5.15.0-190-generic #200-Ubuntu SMP Fri Aug 7 15:06:04 UTC 2026 x86_64 Current Path : /var/www/yapwebtv.com/app/Http/View/Composers/ |
| Current File : /var/www/yapwebtv.com/app/Http/View/Composers/HeaderWidgetComposer.php |
<?php
namespace App\Http\View\Composers;
use App\Services\HeaderWidgetService;
use Illuminate\Support\Facades\Cache;
use Illuminate\View\View;
class HeaderWidgetComposer
{
protected $widgetService;
public function __construct(HeaderWidgetService $widgetService)
{
$this->widgetService = $widgetService;
}
public function compose(View $view)
{
$widgets = Cache::rememberForever('headerWidgets', function (){
return $this->widgetService->getWidgetDetails();
});
$view->with('widgets', $widgets);
}
}