Exemplo n.º 1
0
 public boolean getPatientMedicalTestComponents(PatientDTO dto) throws Exception {
   List<PatientMedicalTestComponent> patientMedicalTestComponents =
       appDAO.findPatientMedicalTestComponentByTestId(dto.getPatientMedicalTestId());
   dto.setPatientMedicalTestComponents(patientMedicalTestComponents);
   activityLogService.logViewPatient(
       dto.getId(), null, dto.getId(), "GetPatientMedicalTestComponents");
   return true;
 }
Exemplo n.º 2
0
 public void createPassword(PatientDTO dto) throws Exception {
   Patient patient = appDAO.findPatientById(dto.getId());
   String newSalt = UUID.randomUUID().toString();
   String encodedPassword = OneWayPasswordEncoder.getInstance().encode(dto.getPassword(), newSalt);
   patient.getCred().setPassword(encodedPassword);
   appDAO.update(patient.getCred());
 }
Exemplo n.º 3
0
 public List<PatientLetter> getPatientLetters(PatientDTO dto) throws Exception {
   Patient patient = appDAO.findPatientById(dto.getId());
   activityLogService.logViewPatient(patient.getId(), null, patient.getId(), "GetPatientLetters");
   List<PatientLetter> letters = appDAO.getPatientLetters(patient);
   for (PatientLetter pl : letters) {
     decrypt(pl.getPatient());
   }
   return letters;
 }
Exemplo n.º 4
0
 public List<Appointment> getAppointments(PatientDTO dto, boolean isPast) throws Exception {
   Patient patient = appDAO.findPatientById(dto.getId());
   activityLogService.logViewPatient(patient.getId(), null, patient.getId(), "GetAppointments");
   List<Appointment> appointments = appDAO.getAppointments(patient, isPast);
   for (Appointment a : appointments) {
     decrypt(a.getPatient());
   }
   return appointments;
 }
Exemplo n.º 5
0
 public List<PatientClinician> getPatientClinicians(PatientDTO dto) throws Exception {
   Patient patient = appDAO.findPatientById(dto.getId());
   activityLogService.logViewPatient(
       patient.getId(), null, patient.getId(), "GetPatientClinicians");
   List<PatientClinician> patientClinicians = appDAO.getPatientClinicians(patient);
   for (PatientClinician patientClinician : patientClinicians) {
     ExcludedObjects.excludeObjects(patientClinician.getPatient());
   }
   return patientClinicians;
 }
Exemplo n.º 6
0
 public List<PatientMessage> getPatientMessages(PatientDTO dto, Boolean fromClinician)
     throws Exception {
   Patient patient = appDAO.findPatientById(dto.getId());
   activityLogService.logViewPatient(patient.getId(), null, patient.getId(), "GetPatientMessages");
   List<PatientMessage> messages = appDAO.getPatientMessages(patient, fromClinician);
   for (PatientMessage pm : messages) {
     decrypt(pm.getPatient());
   }
   return messages;
 }
Exemplo n.º 7
0
 public List<PatientHealthTrendReport> getPatientHealthTrendReports(PatientDTO dto)
     throws Exception {
   Integer patientId = dto.getId();
   activityLogService.logViewPatient(patientId, null, patientId, "GetPatientHealthTrendReports");
   return appDAO.getPatientHealthTrendReports(patientId);
 }
Exemplo n.º 8
0
 public List<PatientMedicalProcedure> getPatientMedicalProcedures(PatientDTO dto)
     throws Exception {
   Integer patientId = dto.getId();
   activityLogService.logViewPatient(patientId, null, patientId, "GetPatientMedicalProcedures");
   return appDAO.getPatientMedicalProcedures(patientId);
 }
Exemplo n.º 9
0
 public List<PatientImmunization> getPatientImmunizations(PatientDTO dto) throws Exception {
   Integer patientId = dto.getId();
   activityLogService.logViewPatient(patientId, null, patientId, "GetPatientImmunizations");
   return appDAO.getPatientImmunizations(patientId);
 }
Exemplo n.º 10
0
 public List<PatientAllergen> getPatientAllergens(PatientDTO dto) throws Exception {
   Patient patient = appDAO.findPatientById(dto.getId());
   activityLogService.logViewPatient(
       patient.getId(), null, patient.getId(), "GetPatientAllergens");
   return appDAO.getPatientAllergens(patient);
 }