<?php

namespace App\Http\Controllers\Web;

use App\About;
use App\Http\Controllers\Controller;
use App\Page;
use App\Photo;
use App\PhotoCategory;
use App\Product;
use App\Project;
use App\Room;
use App\Staff;
use Illuminate\Http\Request;

use App\User;
use Notification;
use App\Notifications\ArticlesNotification;
use App\WebsitePhoto;
use Config;
use Illuminate\View\View;

class AboutUsController extends Controller
{
    private $view = 'web.about_us.';

    /**
     * Show the application dashboard.
     * @return View
     */
    public function index(): View
    {
        $aboutPage = Page::details(2);
        $about = About::getAbout();
        $staffs = Staff::withDescription();
        $title = $aboutPage->title ?? $about->title ?? __('abouts.head');
        $keywords= $about->keywords ?? $aboutPage->keywords ??__('abouts.head');
        $meta_description = $about->meta_description ?? $aboutPage->meta_description ??__('abouts.head');

        return view($this->view.'index', compact('about', 'staffs', 'aboutPage', 'title', 'keywords', 'meta_description'));
    }
}
