/** * Find a model by their id. * * @param $id * @return mixed */ public function findById($id) { return Note::findOrFail($id); }
/** * Run the database seeds. * * @return void */ public function run() { \Model\Note\Note::truncate(); // factory(\Model\Note\Note::class, rand(10,20))->create(); }
public function destroy(Note\Note $note) { $note->delete(); return response()->json($note); }