/**
  * Display a listing of the resource.
  *
  * @return Response
  */
 public function index()
 {
     $purposeAppointmentList = PurposeAppointment::where("name", "LIKE", "%" . htmlentities(Input::get('filter')) . "%")->orderBy(Config::get('constants.PURPOSE_APPOINTMENT.ATTRS.NAME'))->get();
     if (!$purposeAppointmentList->count()) {
         return $this->notDataFound();
     }
     return $this->respondWithCollection($purposeAppointmentList, new PurposeAppointmentTransformer());
 }
 /**
  *	Función responsable de retornar el listado de proposito de la conslta
  *	para una historia clínica.
  */
 public function getPurposeAppoinmentList()
 {
     $purposeAppointmentList = PurposeAppointment::where("name", "LIKE", "%" . htmlentities(Input::get('filter')) . "%")->orderBy(Config::get('constants.PURPOSE_APPOINTMENT.ATTRS.NAME'))->get();
     if (!$purposeAppointmentList->count()) {
         return $this->notDataFound();
     }
     return $purposeAppointmentList;
 }