deleteById() public method

Delete an instance by it's ID.
public deleteById ( integer $model_id ) : boolean
$model_id integer
return boolean
Ejemplo n.º 1
0
 /**
  * Remove the specified model from storage.
  *
  * @param int $model_id
  *
  * @return array
  */
 public function destroy($model_id)
 {
     $this->repository->deleteById($model_id);
     return ['success' => true];
 }