public function destroy($id)
 {
     try {
         $this->repository->delete($id);
         return ['success' => true, 'message' => 'Tarefa deletada com sucesso!'];
     } catch (ModelNotFoundException $e) {
         return ['error' => true, 'message' => $e->getMessage()];
     } catch (QueryException $e) {
         return ['error' => true, 'message' => $e->getMessage()];
     }
 }
 /**
  * Display a listing of the resource.
  *
  * @return \Illuminate\Http\Response
  */
 public function index($id)
 {
     //
     return $this->repository->findWhere(['project_id' => $id]);
 }