/**
  * Show the form for editing the specified resource.
  *
  * @param  int  $id
  * @return \Illuminate\Http\Response
  */
 public function edit($id)
 {
     $r = ProjectBug::find($id)->update(['is_finish' => 1]);
     return response()->json($r);
 }
Ejemplo n.º 2
0
 protected function getBug($id)
 {
     $data['bugs'] = ProjectBug::pro($id)->where('is_finish', '0')->get();
     $data['bugsfinish'] = ProjectBug::pro($id)->where('is_finish', '1')->get();
     return $data;
 }