Closed vyrral closed 3 years ago
I noticed there is no promote student option after cloning project
when I try working on it I get error:
Symfony\Component\HttpKernel\Exception\MethodNotAllowedHttpException The GET method is not supported for this route. Supported methods: POST.
on URL : http://localhost:8000/school/promote-students
here is the api.php file
// Route::group(['middleware' => 'auth:api'], function(){ // Route::post('schools/{code}', 'SchoolController@index'); // Route::post('school', 'SchoolController@store'); // Route::match(['get','post'], 'school/{id}', 'SchoolController@show'); // Route::post('school/{id}', 'SchoolController@update'); // //Route::delete('school/{id}', 'SchoolController@destroy') // });
and
web.php file /route
Route::middleware(['auth', 'admin'])->group(function () { Route::prefix('school')->name('school.')->group(function () { Route::post('add-class', 'MyclassController@store'); Route::post('add-section', 'SectionController@store'); Route::post('add-department', 'SchoolController@addDepartment'); Route::get('promote-students/{section_id}', 'UserController@promoteSectionStudents'); Route::post('promote-students', 'UserController@promoteSectionStudentsPost'); Route::post('theme', 'SchoolController@changeTheme'); Route::post('set-ignore-sessions', 'SchoolController@setIgnoreSessions'); });
});
Promote students is part of Academic Settings.
thanks, found it.
good job!!
I noticed there is no promote student option after cloning project
when I try working on it I get error:
Symfony\Component\HttpKernel\Exception\MethodNotAllowedHttpException The GET method is not supported for this route. Supported methods: POST.
on URL : http://localhost:8000/school/promote-students![unifff](https://user-images.githubusercontent.com/76436041/124397777-d13fde00-dd09-11eb-9754-4c23cc9cbd0c.png)
here is the api.php file
// Route::group(['middleware' => 'auth:api'], function(){ // Route::post('schools/{code}', 'SchoolController@index'); // Route::post('school', 'SchoolController@store'); // Route::match(['get','post'], 'school/{id}', 'SchoolController@show'); // Route::post('school/{id}', 'SchoolController@update'); // //Route::delete('school/{id}', 'SchoolController@destroy') // });
and
web.php file /route
Route::middleware(['auth', 'admin'])->group(function () { Route::prefix('school')->name('school.')->group(function () { Route::post('add-class', 'MyclassController@store'); Route::post('add-section', 'SectionController@store'); Route::post('add-department', 'SchoolController@addDepartment'); Route::get('promote-students/{section_id}', 'UserController@promoteSectionStudents'); Route::post('promote-students', 'UserController@promoteSectionStudentsPost'); Route::post('theme', 'SchoolController@changeTheme'); Route::post('set-ignore-sessions', 'SchoolController@setIgnoreSessions'); });
});