public function correctSpecialAnswer($id, $correct) { $answer = Specialanswer::find($id); $answer->correct = $correct; $answer->corrected = 1; $answer->save(); return back(); }
public function saveDraftSpecialAnswer() { $user_id = Auth::user()->id; Specialanswer::create(['question_id' => $_GET['question'], 'user_id' => $user_id, 'answer' => $_GET['answer'], 'banker' => $_GET['banker']]); }