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