<?php

namespace App\Http\Controllers\Views;

use App\Http\Controllers\Controller;
use Illuminate\Http\Request;
use App\Novedad;
use App\Proveedor;

class HomeController extends Controller
{
    public function index()
    {
        $novedades = Novedad::orderBy('updated_at', 'DESC')->get()->take(5);

        $proveedores = Proveedor::orderBy('id', 'ASC')->get();

        return view('web.index', compact('novedades', 'proveedores'));
    }
}