Created
April 26, 2016 23:27
-
-
Save ChadTaljaardt/982cf9c2f93559e3c27706af774925e6 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Http\ViewComposers; | |
use Illuminate\View\View; | |
use App\Models\Store\Cart as Cart; | |
use Auth; | |
use App\Categories as Categories; | |
use App\Models\Store\Products as Products; | |
class ProductsComposer | |
{ | |
public function __construct() | |
{ | |
} | |
public function compose(View $view) | |
{ | |
$categories = Categories::where('enabled', '1')->get(); | |
$view->with(['categories' => $categories]); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment