Skip to content
This repository was archived by the owner on Sep 22, 2024. It is now read-only.

Commit b20cc6f

Browse files
committed
Update readme
1 parent 7ac6c37 commit b20cc6f

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,14 @@ class ProductController extends Controller
2424
return $this->respond($paginator);
2525
}
2626

27+
public function store(Request $request)
28+
{
29+
$product = Product::create($request->all());
30+
31+
return $this->respond($product->fresh())
32+
->setStatusCode(201);
33+
}
34+
2735
public function show(Product $product)
2836
{
2937
return $this->respond($product);

0 commit comments

Comments
 (0)