Example #1
0
 public function updateField($id, $field, $value)
 {
     $row = $this->model->whereId($id)->first();
     $row->{$field} = $value;
     return $row->save();
 }
Example #2
0
 public function find($id)
 {
     return $this->model->whereId($id)->first();
 }