Exemplo n.º 1
0
 private function _add_movie()
 {
     $movie = Request::input('movie');
     $note = Request::input('note');
     $uid = Tools::getUserIDByEmail(Auth::user()->email);
     $wl = new WishList();
     $wl->movie = $movie;
     $wl->note = $note;
     $wl->user_id = $uid;
     $result = $wl->save();
     echo json_encode(array("status" => $result, "movie" => $movie, "note" => $note, "name" => Auth::user()->name, 'created_at' => date('Y-m-d H:i:s')));
 }