Skip to content

Commit

Permalink
fix: route regex lumen
Browse files Browse the repository at this point in the history
  • Loading branch information
tienanhbui committed Nov 6, 2020
1 parent 04d6442 commit 472ef86
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions src/routes.php
Expand Up @@ -35,21 +35,21 @@
Route::get('{entity}', [
'uses' => 'Megaads\Apify\Controllers\APIController@get',
]);
Route::get('{entity}/{id}', [
Route::get('{entity}/{id:[0-9]+}', [
'uses' => 'Megaads\Apify\Controllers\APIController@show',
])->where(['id' => '[0-9]+']);
]);
Route::post('{entity}', [
'uses' => 'Megaads\Apify\Controllers\APIController@store',
]);
Route::put('{entity}/{id}', [
Route::put('{entity}/{id:[0-9]+}', [
'uses' => 'Megaads\Apify\Controllers\APIController@update',
])->where(['id' => '[0-9]+']);
Route::patch('{entity}/{id}', [
]);
Route::patch('{entity}/{id:[0-9]+}', [
'uses' => 'Megaads\Apify\Controllers\APIController@patch',
])->where(['id' => '[0-9]+']);
Route::delete('{entity}/{id}', [
]);
Route::delete('{entity}/{id:[0-9]+}', [
'uses' => 'Megaads\Apify\Controllers\APIController@destroy',
])->where(['id' => '[0-9]+']);
]);
Route::delete('{entity}', [
'uses' => 'Megaads\Apify\Controllers\APIController@destroyBulk',
]);
Expand Down

0 comments on commit 472ef86

Please sign in to comment.