List Orders of a Restaurant
Learn about one more exciting feature of Laravel: Query Scopes.
New URLs
We should let the user fetch the list of open orders and the list of completed orders of a restaurant.
<?php
// ...
Route::prefix('orders')->group(function () {
Route::get('/list-open', [OrderController::class, 'listOpen']);
Route::get('/list-completed', [OrderController::class, 'listCompleted']);
// ...
});
// ...
...Get hands-on with 1400+ tech skills courses.