<?php

namespace App\Http\Controllers\Web;

use App\Http\Controllers\Controller;
use App\Service;
use Illuminate\Http\Request;

class ServiceController extends Controller
{
    public function index(Service $service)
    {
        $ourService = $service->descriptions()->where('language_id', currentLanguage()->id)->first();
        $title = $ourService ? $ourService->title : null;
        $photos = $service->photos;
        return view('web.services.index', compact('ourService', 'photos', 'title'));
    }
}
