Ejemplo n.º 1
0
 public function index()
 {
     $announcements = Property::latest()->paginate(5);
     $announcements->setPath('announcement');
     $amount = Property::amount();
     return view('main', compact('announcements', 'amount'));
 }
Ejemplo n.º 2
0
 public function home()
 {
     $properties = \App\Property::latest()->take(10)->get();
     return view('pages.home', compact('properties'));
 }