Я пытаюсь обновить свои данные в БД, но я все время получаю сообщение об ошибке.Laravel Call to undefined method
Вызов неопределенной метод Осветите \ Database \ Query \ Builder :: сохранить()
Вот мой код:
public function postTodo(Request $request){
if ($request->input('action') == 'set_as_done'){
$thing = DB::Table('todo')->where('id', $request->input('id'));
if ($thing){
$thing->done = $request->input('set_as_done');
$thing->save();
}
return redirect(route('admin.todo'));
}
}