public function saveComment($comments, $date, $invoiceid, $commentmode = NULL)
 {
     $comment = new comments();
     $comment->text = ucfirst(strtolower($comments));
     $comment->date = $date;
     $comment->invoice_id = $invoiceid;
     $comment->commentmode = $commentmode;
     $comment->save();
 }
 public function saveComment($comments, $date, $invoiceid)
 {
     $comment = new comments();
     // $result = paymentrecieved::create($data);
     $comment->text = ucfirst(strtolower($comments));
     $comment->date = $date;
     $comment->invoice_id = $invoiceid;
     $comment->save();
 }
Esempio n. 3
0
 public function newComment()
 {
     $data = json_decode(urldecode(base64_decode(Input::get('data'))));
     $content = $data->content;
     $poster = $data->poster;
     $linkId = $data->linkId;
     $comment = new comments();
     $comment->content = $content;
     $comment->poster = $poster;
     $comment->linkId = $linkId;
     $comment->save();
     //increment error
     return linkpreview::findOrFail($comment->linkId);
 }
Esempio n. 4
0
 public function upload_comment($id, Request $request)
 {
     $comment = $request->get('comment');
     $user = $request->get('user');
     $date = date('y-m-d');
     comments::add_comment($id, $comment, $date, $user);
     return redirect()->action('maincontroller@movie_details', $id);
 }
 /**
  * Display a listing of the resource.
  *
  * @return \Illuminate\Http\Response
  */
 public function index()
 {
     //
     return comments::all();
 }