<%@ page import="com.tarisan.control.*" %> <%@ page import="com.tarisan.data.*" %> <%@ page import="com.tarisan.excepcion.*" %> <%@ page import="com.tarisan.log.*" %> <%@ page import="com.tarisan.util.Utilidades" %> <%@ page import="com.tarisan.persistencia.PersistenciaParametros" %> <%@ page import="java.sql.*" %> <%@ page import="java.util.Vector" %> <% //LogTarisan.logger.log(NivelLog.INFO, "Inicio página de peticiones capturadas (med/peticiones_capturadas.jsp)"); response.setHeader("Expires", "0"); response.setHeader("Pragma", "no-cache"); response.setHeader("Cache-Control", "no-cache"); HttpSession sesion = request.getSession(true); if(sesion.isNew() || (sesion.getAttribute("USUARIO") == null)) { LogTarisan.logger.log(NivelLog.INFO, "Sesión invalidada"); response.sendRedirect("../../html/login.html"); } else { LogTarisan.logger.log(NivelLog.INFO, ((Usuario)sesion.getAttribute("USUARIO")).getMedico() + " - Inicio página de introducir paciente (med/introducir_paciente.jsp)"); try { // Definicion de variables String strParametroMenu=""; String strCampoFecha=""; StringBuffer strSql = new StringBuffer(); int intPagina=0; int intBuscarPaciente=0; String troquelado = ""; String mensajeNoEncontrado = ""; Object aCondiciones[]=null; int intTarifa = ((Usuario)sesion.getAttribute("USUARIO")).getTarifa(); int intEspecialidad = ((Usuario)sesion.getAttribute("USUARIO")).getEspecialidad(); //Obtención del perfil del usuario conectado StringBuffer perfil = new StringBuffer(); perfil.append("|"); perfil.append(sesion.getAttribute("PERFIL")); perfil.append("|"); //Obtenemos los valores de los parametros que se pasan a la pagina //En caso de que no se le pasen parametros, quedaram inicializados //a sus valores por defecto //parametro x para marcar la opcion del menu en la que se encuentra el usuario if (request.getParameter("x")!=null) strParametroMenu=(String)request.getParameter("x"); //parametro descripcion para las busquedas if (request.getParameter("fecha")!=null) strCampoFecha = (String)request.getParameter("fecha"); //parametro pagina para realizar la paginacion if (request.getParameter("pagina")!=null) intPagina=Integer.parseInt(request.getParameter("pagina")); //parametro pagina para realizar la paginacion if (request.getParameter("buscarPaciente")!=null) intBuscarPaciente=Integer.parseInt(request.getParameter("buscarPaciente")); Tamensaje tamensaje = new Tamensaje(); PersistenciaTamensaje pertamensaje = new PersistenciaTamensaje(); int medico = ((Usuario)sesion.getAttribute("USUARIO")).getMedico(); String ape = ""; String nom = ""; String dir = ""; String fec = ""; String tel = ""; String nif = ""; String ent = ""; String tar = ""; boolean mostrarNoticia = true; PersistenciaTanoticias perTaNo = new PersistenciaTanoticias(); Vector vSeleccionNot = perTaNo.obtener_noticias_cabecera(); Vector vNoticias = new Vector(); String strNoticia = ""; String noticias =""; String separador = " ---//--- "; if(vSeleccionNot.size()==0){ mostrarNoticia = false; }else{ mostrarNoticia = true; Tanoticias tanoticia = null; for(int i = 0; i < vSeleccionNot.size(); i++) { tanoticia = (Tanoticias)vSeleccionNot.elementAt(i); if (i!=0){ strNoticia = strNoticia + separador + tanoticia.getNoticia(); }else{ strNoticia = tanoticia.getNoticia(); } strNoticia = strNoticia.replaceAll("
", " "); } } %> Introducir Paciente
<%= sesion.getAttribute("USUARIO") %>

<%=strNoticia %>



<% //Se ha pulsado en Buscar Paciente /*if (intBuscarPaciente==1){ troquelado = (String)request.getParameter("troque"); PersistenciaTapecap per = new PersistenciaTapecap(); Tapecap tapecap = null; Vector vSeleccion = per.buscarPaciente(troquelado, intPagina); if (vSeleccion.size()==0) //No se han encontrado datos { mensajeNoEncontrado = "No se ha encontrado el paciente"; } else { tapecap = (Tapecap)vSeleccion.firstElement(); if (tapecap.getApellidos()!=null){ ape = tapecap.getApellidos(); } if (tapecap.getNombre()!=null){ nom = tapecap.getNombre().trim(); } if (tapecap.getDireccion()!=null){ dir = tapecap.getDireccion(); } if (tapecap.getFecha_nac()!=null){ fec = tapecap.getFecha_nac().toString(); String[] arrFecha = fec.split("-"); fec = arrFecha[2] + "-" + arrFecha[1] + "-" + arrFecha[0]; } if (tapecap.getTelefono()!=null){ tel = tapecap.getTelefono().trim(); } if (tapecap.getNif()!=null){ nif = tapecap.getNif().trim(); } if (tapecap.getCompañia()!=null){ ent = tapecap.getCompañia(); } } }*/ if (intBuscarPaciente==1){ if (request.getParameter("nom")!=null) nom=(String)request.getParameter("nom"); if (request.getParameter("ape")!=null) ape=(String)request.getParameter("ape"); if (request.getParameter("dir")!=null) dir=(String)request.getParameter("dir"); if (request.getParameter("fec")!=null) fec=(String)request.getParameter("fec"); if (request.getParameter("tel")!=null) tel=(String)request.getParameter("tel"); if (request.getParameter("nif")!=null) nif=(String)request.getParameter("nif"); if (request.getParameter("ent")!=null) ent=(String)request.getParameter("ent"); if (request.getParameter("tar")!=null) tar=(String)request.getParameter("tar"); } %>

DATOS BÁSICOS DE LA ANALÍTICA

<%=mensajeNoEncontrado %>
 
Apellidos:
Nombre:
Telefono:
DNI:
Buscar Paciente
Peticionario:
Especialidad:
Autorizacion:
 
Introducir Paciente
 
<% } catch(Exception ex) { LogTarisan.logger.log(NivelLog.ERROR, ((Usuario)sesion.getAttribute("USUARIO")).getMedico() + " - Exception: " + ex); sesion.setAttribute("ERROR", "Error en la presentación de la página al usuario."); response.sendRedirect("../error.jsp"); } LogTarisan.logger.log(NivelLog.INFO, ((Usuario)sesion.getAttribute("USUARIO")).getMedico() + " - Final página de peticiones capturadas (med/peticiones_capturadas.jsp)"); } %>