/** * @param $idProject * @return int */ public function getNotes($idProject) { try { $data = ['project_id' => $idProject]; return $this->repository->skipPresenter()->findWhere($data); } catch (ModelNotFoundException $e) { return ['error' => true, 'message' => $e->getMessage()]; } }
public function getFileName($id_file) { $file = $this->repository->skipPresenter()->find($id_file); return $file->getFileName(); }