Mejoras en la gestión de excepciones.
This commit is contained in:
@@ -124,14 +124,23 @@ public class ManagedBeanBase {
|
||||
}
|
||||
|
||||
protected void manageException(Exception ex) {
|
||||
String strType = "";
|
||||
// TODO: Registrar en el log las exception
|
||||
String strType = "runtime";
|
||||
|
||||
if (ex.getClass().equals(ViewExpiredException.class)) {
|
||||
// Sessión expirada
|
||||
strType = "expired";
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Su sesión ha caducado", "Su sesión ha caducado, vuelva a logarse en el sistema.");
|
||||
} else {
|
||||
this.addFacesMessageKeep(FacesMessage.SEVERITY_ERROR, "Se ha producido un error inesperado", "Descripción del error: " + ex.getLocalizedMessage());
|
||||
String msg = "";
|
||||
Throwable th = ex.getCause();
|
||||
|
||||
if (th != null)
|
||||
msg = th.getLocalizedMessage();
|
||||
else
|
||||
msg = ex.getLocalizedMessage();
|
||||
|
||||
this.addFacesMessageKeep(FacesMessage.SEVERITY_ERROR, "Se ha producido un error inesperado", "Descripción del error: ".concat(msg));
|
||||
}
|
||||
|
||||
try {
|
||||
|
||||
@@ -50,27 +50,21 @@ public class ChangeFamilyDoctorMBean extends ManagedBeanBase implements Serializ
|
||||
// Recuperamos el usuario logeado actual
|
||||
LoggedUserTO usr = null;
|
||||
this.lastUIQuery = "";
|
||||
try {
|
||||
usr = SessionUtils.getloggedOnUser();
|
||||
usr = SessionUtils.getloggedOnUser();
|
||||
|
||||
if (usr == null)
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Sesión no válida",
|
||||
"Su sesión actual no es válida, por favor cierre su sesión y vuelva a logearse en el sistema.");
|
||||
else {
|
||||
this.id = Integer.valueOf(usr.getId());
|
||||
if (usr == null)
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Sesión no válida", "Su sesión actual no es válida, por favor cierre su sesión y vuelva a logearse en el sistema.");
|
||||
else {
|
||||
this.id = Integer.valueOf(usr.getId());
|
||||
|
||||
if (usr.getUserType() == UserType.PATIENT) {
|
||||
this.familyDoctorList = this.getRemoteManagerCommon().listFamilyDoctorsPaged(0, Constants.MAX_ITEMS_AUTOCOMPLETE_SEARCH);
|
||||
if (usr.getUserType() == UserType.PATIENT) {
|
||||
this.familyDoctorList = this.getRemoteManagerCommon().listFamilyDoctorsPaged(0, Constants.MAX_ITEMS_AUTOCOMPLETE_SEARCH);
|
||||
|
||||
PatientTO pat = this.getRemoteManagerCommon().findPatientById(this.id);
|
||||
this.currentFamilyDoctor = pat.getFamilyDoctor();
|
||||
} else
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Perfil no válido", "Su tipo de usuario no permite que pueda tener acceso a esta página.");
|
||||
}
|
||||
} catch (Exception e) {
|
||||
this.manageException(e);
|
||||
PatientTO pat = this.getRemoteManagerCommon().findPatientById(this.id);
|
||||
this.currentFamilyDoctor = pat.getFamilyDoctor();
|
||||
} else
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Perfil no válido", "Su tipo de usuario no permite que pueda tener acceso a esta página.");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -49,28 +49,22 @@ public class ChangePrimaryHealthCareCenterMBean extends ManagedBeanBase implemen
|
||||
LoggedUserTO usr = null;
|
||||
this.lastUIQuery = "";
|
||||
|
||||
try {
|
||||
usr = SessionUtils.getloggedOnUser();
|
||||
usr = SessionUtils.getloggedOnUser();
|
||||
|
||||
if (usr == null)
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Sesión no válida",
|
||||
"Su sesión actual no es válida, por favor cierre su sesión y vuelva a logearse en el sistema.");
|
||||
else {
|
||||
this.id = Integer.valueOf(usr.getId());
|
||||
if (usr == null)
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Sesión no válida", "Su sesión actual no es válida, por favor cierre su sesión y vuelva a logearse en el sistema.");
|
||||
else {
|
||||
this.id = Integer.valueOf(usr.getId());
|
||||
|
||||
if (usr.getUserType() == UserType.FAMILY_DOCTOR) {
|
||||
// Recupera la lista de CAPs inicial desde el EJB.
|
||||
this.primaryHealthCareCentersList = this.getRemoteManagerCommon().listCAPsPaged(0, Constants.MAX_ITEMS_AUTOCOMPLETE_SEARCH);
|
||||
if (usr.getUserType() == UserType.FAMILY_DOCTOR) {
|
||||
// Recupera la lista de CAPs inicial desde el EJB.
|
||||
this.primaryHealthCareCentersList = this.getRemoteManagerCommon().listCAPsPaged(0, Constants.MAX_ITEMS_AUTOCOMPLETE_SEARCH);
|
||||
|
||||
FamilyDoctorTO fd = this.getRemoteManagerCommon().findFamilyDoctorById(this.id);
|
||||
this.setCurrentCenter(fd.getPrimaryHealthCareCenter());
|
||||
} else
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Perfil no válido", "Su tipo de usuario no permite que pueda tener acceso a esta página.");
|
||||
}
|
||||
} catch (Exception e) {
|
||||
this.manageException(e);
|
||||
FamilyDoctorTO fd = this.getRemoteManagerCommon().findFamilyDoctorById(this.id);
|
||||
this.setCurrentCenter(fd.getPrimaryHealthCareCenter());
|
||||
} else
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Perfil no válido", "Su tipo de usuario no permite que pueda tener acceso a esta página.");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public List<PrimaryHealthCareCenterTO> getPhcList() {
|
||||
|
||||
@@ -90,22 +90,14 @@ public class RegisterUserMBean extends ManagedBeanBase implements Serializable {
|
||||
public void onUserTypeChange() {
|
||||
switch (this.userType) {
|
||||
case SPECIALIST_DOCTOR:
|
||||
try {
|
||||
// El usuario queire registrarse como médico especialista, lanzamos un evento AJAX de cliente para que la interfaz refleje el cambio en el tipo de usuario
|
||||
// seleccionado: Se muestra la lista de especialidades médicas para obligar a seleccionar una.
|
||||
PrimeFaces.current().ajax().addCallbackParam("specs", true);
|
||||
} catch (Exception e) {
|
||||
this.manageException(e);
|
||||
}
|
||||
// El usuario queire registrarse como médico especialista, lanzamos un evento AJAX de cliente para que la interfaz refleje el cambio en el tipo de usuario
|
||||
// seleccionado: Se muestra la lista de especialidades médicas para obligar a seleccionar una.
|
||||
PrimeFaces.current().ajax().addCallbackParam("specs", true);
|
||||
break;
|
||||
case FAMILY_DOCTOR:
|
||||
try {
|
||||
// El usuario queire registrarse como médico especialista, lanzamos un evento AJAX de cliente para que la interfaz refleje el cambio en el tipo de usuario
|
||||
// seleccionado: Se muestra la lista de CAPs para obligar a seleccionar uno.
|
||||
PrimeFaces.current().ajax().addCallbackParam("caps", true);
|
||||
} catch (Exception e) {
|
||||
this.manageException(e);
|
||||
}
|
||||
// El usuario queire registrarse como médico especialista, lanzamos un evento AJAX de cliente para que la interfaz refleje el cambio en el tipo de usuario
|
||||
// seleccionado: Se muestra la lista de CAPs para obligar a seleccionar uno.
|
||||
PrimeFaces.current().ajax().addCallbackParam("caps", true);
|
||||
break;
|
||||
case ADMINISTRATOR:
|
||||
case PATIENT:
|
||||
@@ -234,7 +226,7 @@ public class RegisterUserMBean extends ManagedBeanBase implements Serializable {
|
||||
* No se permite el registro de administradores a través de la página de registro pública.
|
||||
*
|
||||
*/
|
||||
public void addNewUser() {
|
||||
public void addNewUser() throws Exception {
|
||||
int error = 0;
|
||||
|
||||
this.nif = ValidationUtils.normalizeNIF(this.nif);
|
||||
@@ -252,39 +244,34 @@ public class RegisterUserMBean extends ManagedBeanBase implements Serializable {
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_WARN, "El NIF indicado no es válido", "Por favor, especifique un NIF válido.");
|
||||
error++;
|
||||
}
|
||||
if (this.checkNIFDuplicated(this.nif, this.userType) == true) {
|
||||
if (this.checkNIFDuplicated(this.nif, this.userType) == true) {
|
||||
this.addFacesMessage("frmRegisterUser:nif", FacesMessage.SEVERITY_WARN, "NIF duplicado", "El nif indicado pertenece a otro usuario previamente registrado");
|
||||
error++;
|
||||
}
|
||||
|
||||
if (error == 0) {
|
||||
try {
|
||||
switch (this.userType) {
|
||||
case PATIENT:
|
||||
PatientTO pat = this.getRemoteManagerProfile().registerPatient(nif, name, surname, password, email);
|
||||
this.cipCode = pat.getPersonalIdentificationCode();
|
||||
switch (this.userType) {
|
||||
case PATIENT:
|
||||
PatientTO pat = this.getRemoteManagerProfile().registerPatient(nif, name, surname, password, email);
|
||||
this.cipCode = pat.getPersonalIdentificationCode();
|
||||
|
||||
break;
|
||||
case FAMILY_DOCTOR:
|
||||
FamilyDoctorTO fd = this.getRemoteManagerProfile().registerFamilyDoctor(nif, name, surname, password, email, this.primaryHealthCareCenter);
|
||||
this.cipCode = fd.getProfessionalNumber();
|
||||
break;
|
||||
case FAMILY_DOCTOR:
|
||||
FamilyDoctorTO fd = this.getRemoteManagerProfile().registerFamilyDoctor(nif, name, surname, password, email, this.primaryHealthCareCenter);
|
||||
this.cipCode = fd.getProfessionalNumber();
|
||||
|
||||
break;
|
||||
case SPECIALIST_DOCTOR:
|
||||
SpecialistDoctorTO sd = this.getRemoteManagerProfile().registerSpecialistDoctor(nif, name, surname, password, email, this.medicalSpecialty);
|
||||
this.cipCode = sd.getProfessionalNumber();
|
||||
break;
|
||||
case SPECIALIST_DOCTOR:
|
||||
SpecialistDoctorTO sd = this.getRemoteManagerProfile().registerSpecialistDoctor(nif, name, surname, password, email, this.medicalSpecialty);
|
||||
this.cipCode = sd.getProfessionalNumber();
|
||||
|
||||
break;
|
||||
case ADMINISTRATOR:
|
||||
throw new NotSupportedException("No se soporta el registro directo de administradores.");
|
||||
}
|
||||
|
||||
this.registered = true;
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_INFO, "Registro realizado", "El usuario " + name + " " + surname + " se ha registrado correctamente.");
|
||||
|
||||
} catch (Exception e) {
|
||||
this.manageException(e);
|
||||
break;
|
||||
case ADMINISTRATOR:
|
||||
throw new NotSupportedException("No se soporta el registro directo de administradores.");
|
||||
}
|
||||
|
||||
this.registered = true;
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_INFO, "Registro realizado", "El usuario " + name + " " + surname + " se ha registrado correctamente.");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -78,38 +78,31 @@ public class UpdateProfileMBean extends ManagedBeanBase implements Serializable
|
||||
|
||||
// Recuperamos el usuario logeado actual
|
||||
LoggedUserTO usr = null;
|
||||
try {
|
||||
usr = SessionUtils.getloggedOnUser();
|
||||
usr = SessionUtils.getloggedOnUser();
|
||||
|
||||
if (usr == null)
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Sesión no válida",
|
||||
"Su sesión actual no es válida, por favor cierre su sesión y vuelva a logearse en el sistema.");
|
||||
else {
|
||||
this.userType = usr.getUserType();
|
||||
this.id = Integer.valueOf(usr.getId());
|
||||
if (usr == null)
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Sesión no válida", "Su sesión actual no es válida, por favor cierre su sesión y vuelva a logearse en el sistema.");
|
||||
else {
|
||||
this.userType = usr.getUserType();
|
||||
this.id = Integer.valueOf(usr.getId());
|
||||
|
||||
switch (usr.getUserType()) {
|
||||
case PATIENT:
|
||||
this.familyDoctorList = this.getRemoteManagerCommon().listFamilyDoctorsPaged(0, Constants.MAX_ITEMS_AUTOCOMPLETE_SEARCH);
|
||||
this.setPatientData(this.getRemoteManagerCommon().findPatientById(this.id));
|
||||
break;
|
||||
case SPECIALIST_DOCTOR:
|
||||
this.medicalSpecialitiesList = this.getRemoteManagerCommon().listMedicalSpecialitiesPaged(0, Constants.MAX_ITEMS_AUTOCOMPLETE_SEARCH);
|
||||
this.setSpecialistDoctorData(this.getRemoteManagerCommon().findSpecialistDoctorById(this.id));
|
||||
break;
|
||||
case FAMILY_DOCTOR:
|
||||
this.primaryHealthCareCentersList = this.getRemoteManagerCommon().listCAPsPaged(0, Constants.MAX_ITEMS_AUTOCOMPLETE_SEARCH);
|
||||
this.setFamilyDoctorData(this.getRemoteManagerCommon().findFamilyDoctorById(this.id));
|
||||
break;
|
||||
case ADMINISTRATOR:
|
||||
// TODO: Recuperar usuario administrador para editar su perfil ¿?
|
||||
// this.getRemoteManagerProfile().retrievePatient(usr.getId());
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Usuario sin perfil", "Usted es un usuario de tipo administrador y no puede editar su perfil de usuario.");
|
||||
break;
|
||||
}
|
||||
switch (usr.getUserType()) {
|
||||
case PATIENT:
|
||||
this.familyDoctorList = this.getRemoteManagerCommon().listFamilyDoctorsPaged(0, Constants.MAX_ITEMS_AUTOCOMPLETE_SEARCH);
|
||||
this.setPatientData(this.getRemoteManagerCommon().findPatientById(this.id));
|
||||
break;
|
||||
case SPECIALIST_DOCTOR:
|
||||
this.medicalSpecialitiesList = this.getRemoteManagerCommon().listMedicalSpecialitiesPaged(0, Constants.MAX_ITEMS_AUTOCOMPLETE_SEARCH);
|
||||
this.setSpecialistDoctorData(this.getRemoteManagerCommon().findSpecialistDoctorById(this.id));
|
||||
break;
|
||||
case FAMILY_DOCTOR:
|
||||
this.primaryHealthCareCentersList = this.getRemoteManagerCommon().listCAPsPaged(0, Constants.MAX_ITEMS_AUTOCOMPLETE_SEARCH);
|
||||
this.setFamilyDoctorData(this.getRemoteManagerCommon().findFamilyDoctorById(this.id));
|
||||
break;
|
||||
case ADMINISTRATOR:
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Usuario sin perfil", "Usted es un usuario de tipo administrador y no puede editar su perfil de usuario.");
|
||||
break;
|
||||
}
|
||||
} catch (Exception e) {
|
||||
this.manageException(e);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -309,43 +302,47 @@ public class UpdateProfileMBean extends ManagedBeanBase implements Serializable
|
||||
if (this.userType == null)
|
||||
return;
|
||||
|
||||
this.nif = ValidationUtils.normalizeNIF(this.nif);
|
||||
try {
|
||||
this.nif = ValidationUtils.normalizeNIF(this.nif);
|
||||
|
||||
boolean changePassword = (this.oldPassword != null && this.oldPassword.equals("") == false) || (this.password != null && this.password.equals("") == false);
|
||||
boolean changePassword = (this.oldPassword != null && this.oldPassword.equals("") == false) || (this.password != null && this.password.equals("") == false);
|
||||
|
||||
if (this.isUserTypeFamilyDoctor() && this.primaryHealthCareCenter == null) {
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_WARN, "Centro de atención primaria no seleccionado", "Por favor, especifique un centro de atención primaria.");
|
||||
error++;
|
||||
}
|
||||
if (this.isUserTypeSpecialistDoctor() && this.medicalSpecialty == null) {
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_WARN, "Especialidad médica no seleccionada", "Por favor, especifique una especialidad médica.");
|
||||
error++;
|
||||
}
|
||||
if (ValidationUtils.isValid(nif) == false) {
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_WARN, "El NIF indicado no es válido", "Por favor, especifique un NIF válido.");
|
||||
error++;
|
||||
}
|
||||
if (ValidationUtils.checkIfNifAlreadyRegistered(this.getRemoteManagerCommon(), this.userType, this.nif, this.id) == true) {
|
||||
this.addFacesMessage("frmUpdateProfile:nif", FacesMessage.SEVERITY_WARN, "NIF duplicado", "El nif indicado pertenece a otro usuario previamente registrado");
|
||||
error++;
|
||||
}
|
||||
if (changePassword == true) {
|
||||
// el usuario queire cambiar el password Comprobamos que el password
|
||||
// especificado coincide con el guardado
|
||||
if (this.password == null || this.password.length() < 4) {
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Nueva contraseña incorrectra", "Su nueva contraseña debe tener al menos 4 caracteres.");
|
||||
error++;
|
||||
} else if (HashUtils.hashMD5(this.oldPassword).equals(this.currentPassword) == false) {
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Contraseña actual incorrecta",
|
||||
"Su actual contraseña es incorrecta. Por favor, especifique su contraseña actual.");
|
||||
if (this.userType == UserType.ADMINISTRATOR) {
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Perfil de usuario incorrecto", "Su perfil es de un usuario de tipo administrador y no puede editar su perfil.");
|
||||
error++;
|
||||
}
|
||||
}
|
||||
|
||||
if (error == 0) {
|
||||
try {
|
||||
if (this.isUserTypeFamilyDoctor() && this.primaryHealthCareCenter == null) {
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_WARN, "Centro de atención primaria no seleccionado", "Por favor, especifique un centro de atención primaria.");
|
||||
error++;
|
||||
}
|
||||
if (this.isUserTypeSpecialistDoctor() && this.medicalSpecialty == null) {
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_WARN, "Especialidad médica no seleccionada", "Por favor, especifique una especialidad médica.");
|
||||
error++;
|
||||
}
|
||||
if (ValidationUtils.isValid(nif) == false) {
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_WARN, "El NIF indicado no es válido", "Por favor, especifique un NIF válido.");
|
||||
error++;
|
||||
}
|
||||
if (ValidationUtils.checkIfNifAlreadyRegistered(this.getRemoteManagerCommon(), this.userType, this.nif, this.id) == true) {
|
||||
this.addFacesMessage("frmUpdateProfile:nif", FacesMessage.SEVERITY_WARN, "NIF duplicado", "El nif indicado pertenece a otro usuario previamente registrado");
|
||||
error++;
|
||||
}
|
||||
if (changePassword == true) {
|
||||
// el usuario queire cambiar el password Comprobamos que el password
|
||||
// especificado coincide con el guardado
|
||||
if (this.password == null || this.password.length() < 4) {
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Nueva contraseña incorrectra", "Su nueva contraseña debe tener al menos 4 caracteres.");
|
||||
error++;
|
||||
} else if (HashUtils.hashMD5(this.oldPassword).equals(this.currentPassword) == false) {
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_ERROR, "Contraseña actual incorrecta",
|
||||
"Su actual contraseña es incorrecta. Por favor, especifique su contraseña actual.");
|
||||
error++;
|
||||
}
|
||||
}
|
||||
|
||||
if (error == 0) {
|
||||
LoggedUserTO usr = null;
|
||||
|
||||
switch (this.userType) {
|
||||
case PATIENT:
|
||||
PatientTO pat = this.getRemoteManagerProfile().updatePatientData(id, nif, name, surname, password, email);
|
||||
@@ -366,7 +363,7 @@ public class UpdateProfileMBean extends ManagedBeanBase implements Serializable
|
||||
|
||||
break;
|
||||
case ADMINISTRATOR:
|
||||
throw new NotSupportedException("No se soporta la edición de perfiles de tipo administrador.");
|
||||
break;
|
||||
}
|
||||
|
||||
if (changePassword == true) {
|
||||
@@ -379,9 +376,9 @@ public class UpdateProfileMBean extends ManagedBeanBase implements Serializable
|
||||
SessionUtils.createOrUpdateSession(usr);
|
||||
|
||||
this.addFacesMessage(FacesMessage.SEVERITY_INFO, "Los datos se han guardado", "Los datos de su perfil se han guardado correctamente.");
|
||||
} catch (Exception e) {
|
||||
this.manageException(e);
|
||||
}
|
||||
} catch (Exception ex) {
|
||||
this.manageException(ex);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -35,21 +35,16 @@ public class AddVisitMBean extends ManagedBeanBase implements Serializable {
|
||||
@PostConstruct
|
||||
public void init() {
|
||||
// El usuario actual es un medico de familia, recuperamos su Id de la sessión actual
|
||||
try {
|
||||
Integer patientId = Integer.valueOf(SessionUtils.getUserId());
|
||||
Integer patientId = Integer.valueOf(SessionUtils.getUserId());
|
||||
|
||||
this.patient = this.getRemoteManagerCommon().findPatientById(patientId);
|
||||
|
||||
if (this.patient.getFamilyDoctor() != null)
|
||||
this.familyDoctorDisplayName = this.patient.getFamilyDoctor().getDisplayName();
|
||||
else
|
||||
this.familyDoctorDisplayName = null;
|
||||
this.patient = this.getRemoteManagerCommon().findPatientById(patientId);
|
||||
|
||||
this.date = LocalDate.now();
|
||||
} catch (Exception e) {
|
||||
this.manageException(e);
|
||||
}
|
||||
if (this.patient.getFamilyDoctor() != null)
|
||||
this.familyDoctorDisplayName = this.patient.getFamilyDoctor().getDisplayName();
|
||||
else
|
||||
this.familyDoctorDisplayName = null;
|
||||
|
||||
this.date = LocalDate.now();
|
||||
}
|
||||
|
||||
public void saveData() {
|
||||
@@ -58,7 +53,8 @@ public class AddVisitMBean extends ManagedBeanBase implements Serializable {
|
||||
LocalDate today = LocalDate.now();
|
||||
|
||||
if (this.patient.getFamilyDoctor() == null) {
|
||||
this.addFacesMessage("visitForm:medico", FacesMessage.SEVERITY_ERROR, "Médico de familia no asignado", "Es necesario que tenga un médico de familia asignado, por favor, cambie el médico de familia que tiene asignado");
|
||||
this.addFacesMessage("visitForm:medico", FacesMessage.SEVERITY_ERROR, "Médico de familia no asignado",
|
||||
"Es necesario que tenga un médico de familia asignado, por favor, cambie el médico de familia que tiene asignado");
|
||||
error++;
|
||||
}
|
||||
if (this.date.isBefore(today)) {
|
||||
@@ -119,7 +115,7 @@ public class AddVisitMBean extends ManagedBeanBase implements Serializable {
|
||||
public String getFamilyDoctorDisplayName() {
|
||||
return familyDoctorDisplayName;
|
||||
}
|
||||
|
||||
|
||||
public void setFamilyDoctorDisplayName(String value) {
|
||||
this.familyDoctorDisplayName = value;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user