コード例 #1
0
ファイル: ProductsController.php プロジェクト: saj696/pipe
 /**
  * Show the form for editing the specified resource.
  *
  * @param  int $id
  * @return \Illuminate\Http\Response
  */
 public function edit($id)
 {
     $product = Product::findOrFail($id);
     $product_types = ProductType::lists('title', 'id');
     $color = Material::where('type', 3)->lists('name', 'id');
     return view('products.edit', compact('product', 'product_types', 'color'));
 }