public function indexAll() { logger()->info("Indexing all products"); $products = Product::all(); logger()->debug(sprintf("Found %d products.", count($products))); foreach ($products as $product) { $this->indexProduct($product->id); } }
/** * List all of the products. * * @return mixed */ public function lists() { return View::make('product.list')->withProducts(Product::all()); }
public function all() { return Product::all(); }
public function allProductsApi() { $productList = Product::all(); $categories = ProductSubCategory::all(); foreach ($categories as $category) { } return response()->json(['response_message' => 'success', 'response_rows' => sizeof($productList), 'response_data' => $productList]); }
public function index() { $products = Product::all(); return view('product.index', ['products' => $products]); }