import sys, os from utilidades.ficheros.ProcesadorPDF import ProcesadorPDF from sqlalchemy.ext.declarative import declarative_base from sqlalchemy import create_engine, text, and_ from sqlalchemy.orm import sessionmaker from sqlalchemy import Column, Integer, String from utilidades.modelos.Modelos import * from utilidades.fechas.GestorFechas import GestorFechas from utilidades.ficheros.GestorFicheros import GestorFicheros gestor_fechas=GestorFechas() gestor_ficheros=GestorFicheros() fecha_hoy=gestor_fechas.get_hoy_iso() NUMEROS_DNI_A_OCULTAR=0 DIRECTORIO_PLANTILLAS="." + os.sep + "plantillas" DIRECTORIO_RESULTADOS="." + os.sep + "resultados" PLANTILLA_INFORME = DIRECTORIO_PLANTILLAS + os.sep + "plantilla_informe.html" CAD_CONEXION=sys.argv[1] CODIGO_ESPECIALIDAD=sys.argv[2] PLANTILLA_SQL=""" select especialidad, fecha_inicio, fecha_fin from nombramientos where nif='{0}' order by fecha_procedimiento desc """