From my research, this error is related to a routing error. As this error is thrown regardless of the code I utilize in my update function, that makes sense.
However I believe all my routes/forms are proper:
web.php
Route::get('orders/edit/{order}', 'OrderController@edit')->name('orders.edit');
Route::patch('orders/update', 'OrderController@update')->name('orders.update');
OrderController.php
public function update(Request $request,Order $order)
{
//doesnt seem to matter what is in here but this is my return
return redirect()->route('orders.checkout', $order->id);
}
edit.blade.php
{!! Form::model(['route' => 'orders.update', 'method' => 'patch']) !!}
// sample of an input I am using
{!! Form::close() !!}
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire