Exemple #1
0
    protected void ButtonRestaurar(object sender, EventArgs e)
    {
        SEGURIDAD.Backup gestorBackup = new SEGURIDAD.Backup();
        string           mensaje      = gestorBackup.Restaurar(Server.MapPath("~/BackupDB//" + FileUpload1.FileName));

        BLL.Bitacora gestorBitacora = new BLL.Bitacora();
        BE.Bitacora  bitacora       = new BE.Bitacora();
        bitacora.Fecha   = DateTime.Now;
        bitacora.Evento  = mensaje;
        bitacora.Usuario = SEGURIDAD.Sesion._Instance.UsuarioEnSesion;
        gestorBitacora.RegistrarBitacora(bitacora);
        Response.Write(@"<script language='javascript'>alert('" + mensaje + "')</script>");
        Response.Redirect("~/Inicio");
    }
Exemple #2
0
        public List <Tarea> listarPorProyecto(Proyecto proyectoSelected)
        {
            List <Tarea> lista = mapper.listarPorProyecto(proyectoSelected);

            BitacoraService.getInstance().crear(
                Bitacora.builder()
                .Criticidad("BAJA")
                .Descripcion("Se listaton las tareas del proyecto")
                .Funcionalidad("TAREAS")
                .Fecha(DateTime.Now)
                .Usuario(Session.getInstance().Usuario)
                .build()
                );
            return(lista);
        }
Exemple #3
0
        public override Idioma leer(long id)
        {
            Idioma list = mapper.leer(id);

            BitacoraService.getInstance().crear(
                Bitacora.builder()
                .Criticidad("ALTA")
                .Descripcion("SE OBTUVO EL IDIOMA")
                .Funcionalidad("IDIOMA")
                .Fecha(DateTime.Now)
                .Usuario(Session.getInstance().Usuario)
                .build()
                );
            return(list);
        }
Exemple #4
0
        public override Tarea leer(long id)
        {
            Tarea lista = mapper.leer(id);

            BitacoraService.getInstance().crear(
                Bitacora.builder()
                .Criticidad("BAJA")
                .Descripcion("Se leyo la tarea")
                .Funcionalidad("TAREAS")
                .Fecha(DateTime.Now)
                .Usuario(Session.getInstance().Usuario)
                .build()
                );
            return(lista);
        }
Exemple #5
0
        public override List <Tarea> listar()
        {
            List <Tarea> lista = mapper.listar();

            BitacoraService.getInstance().crear(
                Bitacora.builder()
                .Criticidad("BAJA")
                .Descripcion("Se listaron las tareas")
                .Funcionalidad("TAREAS")
                .Fecha(DateTime.Now)
                .Usuario(Session.getInstance().Usuario)
                .build()
                );
            return(lista);
        }
        public List <Usuario> obtenerUsuariosDisponibles(Proyecto proyecto)
        {
            List <Usuario> usuarios = usuarioMapper.obtenerUsuariosDisponibles(proyecto);

            BitacoraService.getInstance().crear(
                Bitacora.builder()
                .Criticidad("BAJA")
                .Descripcion("Se obtienen los usuarios disponibles para el proyecto")
                .Funcionalidad("LISTAR_USUARIOS_DISPONIBLES")
                .Fecha(DateTime.Now)
                .Usuario(Session.getInstance().Usuario)
                .build()
                );
            return(usuarios);
        }
Exemple #7
0
 public override void crear(Hora entity)
 {
     entity.Dvh = verificadorService.generarDVH(new string[] { entity.Proyecto.Id.ToString(), entity.Tarea.Id.ToString(), entity.Usuario.Username, entity.Cantidad.ToString() });
     mapper.crear(entity);
     verificadorService.actualizarDVV("HORA");
     BitacoraService.getInstance().crear(
         Bitacora.builder()
         .Criticidad("ALTA")
         .Descripcion("SE CREO LA HORA")
         .Funcionalidad("HORA")
         .Fecha(DateTime.Now)
         .Usuario(Session.getInstance().Usuario)
         .build()
         );
 }
        public List <Usuario> obtenerUsuariosAsignados(Proyecto proyecto)
        {
            List <Usuario> usuarios = usuarioMapper.obtenerUsuariosAsignados(proyecto);

            BitacoraService.getInstance().crear(
                Bitacora.builder()
                .Criticidad("BAJA")
                .Descripcion("Se obtienen los usuarios asociados al proyecto")
                .Funcionalidad("LISTAR_USUARIOS_ASIGNADOS")
                .Fecha(DateTime.Now)
                .Usuario(Session.getInstance().Usuario)
                .build()
                );
            return(usuarios);
        }
 public void crearUser(ref string mensaje_error, ref int numero_error, int Cod_User, string Username, string Password, string Rol, string Email, string Question, string Answer, string UsernameC)
 {
     connection = cls_DAL.trae_conexion("ServiciosWeb", ref mensaje_error, ref numero_error);
     sql        = "exec register_user @Cod_user = '******', @Username = '******', @Pass = '******', @Rol = '" + Rol + "', @Email = '" + Email + "', @Question = '" + Question + "', @Answer = '" + Answer + "'";
     ds         = cls_DAL.ejecuta_dataset(connection, sql, false, ref mensaje_error, ref numero_error);
     if (numero_error != 0)
     {
         Errors e = new Errors();
         e.crearErrorInterno(ref mensaje_error, ref numero_error, Errors.GlobalValue = Errors.GlobalValue + 1, e.encrypt(mensaje_error), e.encrypt(time), e.encrypt(date), e.encrypt(numero_error.ToString()));
     }
     else
     {
         Bitacora bitacora = new Bitacora();
         bitacora.CreateBitacora(ref mensaje_error, ref numero_error, (Bitacora.GlobalValue = Bitacora.GlobalValue + 1).ToString(), bitacora.encrypt(UsernameC), bitacora.encrypt(date), bitacora.encrypt("Create"), bitacora.encrypt(time), Cod_User.ToString(), bitacora.encrypt("Creacion de nuevo usuario"), bitacora.encrypt("Codigo: " + Cod_User + " | Nombre: " + bitacora.decrypt(Username) + " | Email: " + bitacora.decrypt(Email)));
     }
 }
        public override Familia leer(long id)
        {
            Familia familia = familiaMapper.leer(id);

            familia.Nombre = desencriptarAES(familia.Nombre);
            BitacoraService.getInstance().crear(
                Bitacora.builder()
                .Criticidad("ALTA")
                .Descripcion("SE OBTUVO EL DETALLE DE UNA FAMILIA")
                .Funcionalidad("FAMILIA")
                .Fecha(DateTime.Now)
                .Usuario(Session.getInstance().Usuario)
                .build()
                );
            return(familia);
        }
 public void updateUserPassword(ref string mensaje_error, ref int numero_error, string Username, string Password, string UsernameC, string Cod_User)
 {
     connection = cls_DAL.trae_conexion("ServiciosWeb", ref mensaje_error, ref numero_error);
     sql        = "user_password_update @Username = '******', @Password = '******'";
     ds         = cls_DAL.ejecuta_dataset(connection, sql, false, ref mensaje_error, ref numero_error);
     if (numero_error != 0)
     {
         Errors e = new Errors();
         e.crearErrorInterno(ref mensaje_error, ref numero_error, Errors.GlobalValue = Errors.GlobalValue + 1, e.encrypt(mensaje_error), e.encrypt(time), e.encrypt(date), e.encrypt(numero_error.ToString()));
     }
     else
     {
         Bitacora bitacora = new Bitacora();
         bitacora.CreateBitacora(ref mensaje_error, ref numero_error, (Bitacora.GlobalValue = Bitacora.GlobalValue + 1).ToString(), bitacora.encrypt(UsernameC), bitacora.encrypt(date), bitacora.encrypt("Update"), bitacora.encrypt(time), Cod_User, bitacora.encrypt("Cambio de contraseña"), bitacora.encrypt("Nombre de usuario:" + bitacora.decrypt(Username) + " | PasswordChange****"));
     }
 }
Exemple #12
0
        public override Patente leer(long id)
        {
            Patente patente = patenteMapper.leer(id);

            patente.Nombre = desencriptarAES(patente.Nombre);
            BitacoraService.getInstance().crear(
                Bitacora.builder()
                .Criticidad("ALTA")
                .Descripcion("SE OBTUVO LA PATENTE")
                .Funcionalidad("PATENTE")
                .Fecha(DateTime.Now)
                .Usuario(Session.getInstance().Usuario)
                .build()
                );
            return(patente);
        }
Exemple #13
0
 public void delete_country(ref string mensaje_error, ref int numero_error, string Cod_Pais, string UsernameC, string CodCountry)
 {
     connection = cls_DAL.trae_conexion("ServiciosWeb", ref mensaje_error, ref numero_error);
     sql        = "exec delete_conutry @Cod_Pais = '" + Cod_Pais + "'";
     ds         = cls_DAL.ejecuta_dataset(connection, sql, false, ref mensaje_error, ref numero_error);
     if (numero_error != 0)
     {
         Errors e = new Errors();
         e.crearErrorInterno(ref mensaje_error, ref numero_error, Errors.GlobalValue = Errors.GlobalValue + 1, e.encrypt(mensaje_error), e.encrypt(time), e.encrypt(date), e.encrypt(numero_error.ToString()));
     }
     else
     {
         Bitacora bitacora = new Bitacora();
         bitacora.CreateBitacora(ref mensaje_error, ref numero_error, (Bitacora.GlobalValue = Bitacora.GlobalValue + 1).ToString(), bitacora.encrypt(UsernameC), bitacora.encrypt(date), bitacora.encrypt("Delete"), bitacora.encrypt(time), CodCountry, bitacora.encrypt("Delete de una pais"), bitacora.encrypt("-"));
     }
 }
Exemple #14
0
 public void update_country(ref string mensaje_error, ref int numero_error, string Cod_Pais1, string Cod_Pais2, string Nombre_Pais, string Imagen, string UsernameC, string CodCountry)
 {
     connection = cls_DAL.trae_conexion("ServiciosWeb", ref mensaje_error, ref numero_error);
     sql        = "exec update_country @Cod_Pais = '" + Cod_Pais1 + "', @Cod_Pais2 = '" + Cod_Pais2 + "',  @Nombre_Pais = '" + Nombre_Pais + "', @Imagen = '" + Imagen + "'";
     ds         = cls_DAL.ejecuta_dataset(connection, sql, false, ref mensaje_error, ref numero_error);
     if (numero_error != 0)
     {
         Errors e = new Errors();
         e.crearErrorInterno(ref mensaje_error, ref numero_error, Errors.GlobalValue = Errors.GlobalValue + 1, e.encrypt(mensaje_error), e.encrypt(time), e.encrypt(date), e.encrypt(numero_error.ToString()));
     }
     else
     {
         Bitacora bitacora = new Bitacora();
         bitacora.CreateBitacora(ref mensaje_error, ref numero_error, (Bitacora.GlobalValue = Bitacora.GlobalValue + 1).ToString(), bitacora.encrypt(UsernameC), bitacora.encrypt(date), bitacora.encrypt("Update"), bitacora.encrypt(time), CodCountry, bitacora.encrypt("Update de Pais"), bitacora.encrypt("Pais viejo: " + Cod_Pais1 + " | Pais nuevo: " + Cod_Pais2 + " | Nombre de pais: " + bitacora.decrypt(Nombre_Pais) + " | Imagen: " + bitacora.decrypt(Imagen)));
     }
 }
Exemple #15
0
 public void createAirline(ref string mensaje_error, ref int numero_error, int Cod_Agencia, string Nombre_Agencia, string Imagen, string Cod_Pais_FK, string Cod_Aerolinea, string UsernameC)
 {
     connection = cls_DAL.trae_conexion("ServiciosWeb", ref mensaje_error, ref numero_error);
     sql        = "exec create_new_airline @Cod_Agencia= '" + Cod_Agencia + "', @Nombre_Agencia = '" + Nombre_Agencia + "', @Imagen = '" + Imagen + "', @Cod_Pais_FK = '" + Cod_Pais_FK + "', @Cod_Aerolinea = '" + Cod_Aerolinea + "'";
     ds         = cls_DAL.ejecuta_dataset(connection, sql, false, ref mensaje_error, ref numero_error);
     if (numero_error != 0)
     {
         Errors e = new Errors();
         e.crearErrorInterno(ref mensaje_error, ref numero_error, Errors.GlobalValue = Errors.GlobalValue + 1, e.encrypt(mensaje_error), e.encrypt(time), e.encrypt(date), e.encrypt(numero_error.ToString()));
     }
     else
     {
         Bitacora bitacora = new Bitacora();
         bitacora.CreateBitacora(ref mensaje_error, ref numero_error, (Bitacora.GlobalValue = Bitacora.GlobalValue + 1).ToString(), bitacora.encrypt(UsernameC.ToString()), bitacora.encrypt(date), bitacora.encrypt("Create"), bitacora.encrypt(time), Cod_Agencia.ToString(), bitacora.encrypt("Creacion de una aerolinea"), bitacora.encrypt("Codigo: " + Cod_Agencia + " | Nombre: " + bitacora.decrypt(Nombre_Agencia) + " | Imagen: " + bitacora.decrypt(Imagen)));
     }
 }
 public void updateUser(ref string mensaje_error, ref int numero_error, string Username, string Rol, string UsernameC)
 {
     connection = cls_DAL.trae_conexion("ServiciosWeb", ref mensaje_error, ref numero_error);
     sql        = "exec update_user_rol @Username = '******', @Rol = '" + Rol + "'";
     ds         = cls_DAL.ejecuta_dataset(connection, sql, false, ref mensaje_error, ref numero_error);
     if (numero_error != 0)
     {
         Errors e = new Errors();
         e.crearErrorInterno(ref mensaje_error, ref numero_error, Errors.GlobalValue = Errors.GlobalValue + 1, e.encrypt(mensaje_error), e.encrypt(time), e.encrypt(date), e.encrypt(numero_error.ToString()));
     }
     else
     {
         Bitacora bitacora = new Bitacora();
         bitacora.CreateBitacora(ref mensaje_error, ref numero_error, (Bitacora.GlobalValue = Bitacora.GlobalValue + 1).ToString(), bitacora.encrypt(UsernameC), bitacora.encrypt(date), bitacora.encrypt("Update"), bitacora.encrypt(time), Username, bitacora.encrypt("Update de rol"), bitacora.encrypt("Codigo de usuario: " + Username + " | Rol: " + bitacora.decrypt(Rol)));
     }
 }
Exemple #17
0
        public void updateCons(ref string mensaje_error, ref int numero_error, string Descripcion, string Valor, string prefijo, string Rango_ini, string Rango_fin, string UsernameC, string ConsCod)
        {
            connection = cls_DAL.trae_conexion("ServiciosWeb", ref mensaje_error, ref numero_error);
            sql        = "exec consecutive_update_cambios @Descripcion = '" + Descripcion + "', @Valor = '" + Valor + "', @Prefijo = '" + prefijo + "', @Rango_ini = '" + Rango_ini + "', @Rango_fin = '" + Rango_fin + "'";
            ds         = cls_DAL.ejecuta_dataset(connection, sql, false, ref mensaje_error, ref numero_error);

            if (numero_error != 0)
            {
                Errors e = new Errors();
                e.crearErrorInterno(ref mensaje_error, ref numero_error, Errors.GlobalValue = Errors.GlobalValue + 1, e.encrypt(mensaje_error), e.encrypt(time), e.encrypt(date), e.encrypt(numero_error.ToString()));
            }
            else
            {
                Bitacora bitacora = new Bitacora();
                bitacora.CreateBitacora(ref mensaje_error, ref numero_error, (Bitacora.GlobalValue = Bitacora.GlobalValue + 1).ToString(), bitacora.encrypt(UsernameC), bitacora.encrypt(date), bitacora.encrypt("Update"), bitacora.encrypt(time), ConsCod, bitacora.encrypt("Update de un consecutivo"), bitacora.encrypt("Codigo: " + Codigo_Consecutivo.ToString() + " | Descripcion: " + bitacora.decrypt(Descripcion) + " | Valor: " + bitacora.decrypt(Valor) + " | Prefijo: " + bitacora.decrypt(prefijo) + " | RangoINI - RangoFIN: " + bitacora.decrypt(Rango_ini) + "-" + bitacora.decrypt(Rango_fin)));
            }
        }
        public override Proyecto leer(long id)
        {
            Proyecto proyecto = mapper.leer(id);

            proyecto.ValorHora      = desencriptarAES(proyecto.ValorHora);
            proyecto.HorasEstimadas = desencriptarAES(proyecto.HorasEstimadas);
            BitacoraService.getInstance().crear(
                Bitacora.builder()
                .Criticidad("BAJA")
                .Descripcion("Se leyo el proyecto")
                .Funcionalidad("PROYECTO")
                .Fecha(DateTime.Now)
                .Usuario(Session.getInstance().Usuario)
                .build()
                );
            return(proyecto);
        }
Exemple #19
0
        public void updateGate(ref string mensaje_error, ref int numero_error, string Cod_Puerta, string Cod_Puerta2, string Numero_Puerta, string Detalle, string UsernameC, string GateCod)
        {
            connection = cls_DAL.trae_conexion("ServiciosWeb", ref mensaje_error, ref numero_error);
            sql        = "exec update_ecist_gate @Cod_Puerta = '" + Cod_Puerta + "', @Cod_Puerta2 = '" + Cod_Puerta2 + "' , @Numero_Puerta = '" + Numero_Puerta + "', @Detalle = '" + Detalle + "'";
            ds         = cls_DAL.ejecuta_dataset(connection, sql, false, ref mensaje_error, ref numero_error);

            if (numero_error != 0)
            {
                Errors e = new Errors();
                e.crearErrorInterno(ref mensaje_error, ref numero_error, Errors.GlobalValue = Errors.GlobalValue + 1, e.encrypt(mensaje_error), e.encrypt(time), e.encrypt(date), e.encrypt(numero_error.ToString()));
            }
            else
            {
                Bitacora bitacora = new Bitacora();
                bitacora.CreateBitacora(ref mensaje_error, ref numero_error, (Bitacora.GlobalValue = Bitacora.GlobalValue + 1).ToString(), bitacora.encrypt(UsernameC), bitacora.encrypt(date), bitacora.encrypt("Update"), bitacora.encrypt(time), GateCod, bitacora.encrypt("Update de una puerta"), bitacora.encrypt("Codigo: " + Cod_Puerta + " | Numero: " + bitacora.decrypt(Numero_Puerta) + " | Detalle: " + bitacora.decrypt(Detalle)));
            }
        }
Exemple #20
0
        public void delete_airline(ref string mensaje_error, ref int numero_error, string Cod_Aerolinea, string UsernameC, string Cod_Agency)
        {
            connection = cls_DAL.trae_conexion("ServiciosWeb", ref mensaje_error, ref numero_error);
            sql        = "exec delete_airline @Cod_Aerolinea = '" + Cod_Aerolinea + "'";
            ds         = cls_DAL.ejecuta_dataset(connection, sql, false, ref mensaje_error, ref numero_error);

            if (numero_error != 0)
            {
                Errors e = new Errors();
                e.crearErrorInterno(ref mensaje_error, ref numero_error, Errors.GlobalValue = Errors.GlobalValue + 1, e.encrypt(mensaje_error), e.encrypt(time), e.encrypt(date), e.encrypt(numero_error.ToString()));
            }
            else
            {
                Bitacora bitacora = new Bitacora();
                bitacora.CreateBitacora(ref mensaje_error, ref numero_error, (Bitacora.GlobalValue = Bitacora.GlobalValue + 1).ToString(), bitacora.encrypt(UsernameC), bitacora.encrypt(date), bitacora.encrypt("Delete"), bitacora.encrypt(time), Cod_Agency, bitacora.encrypt("Eliminacion de Agencia/Aerolinea"), bitacora.encrypt("-"));
            }
        }
Exemple #21
0
 public void quitarPatente(Familia familia, Patente patente)
 {
     if (!patenteMapper.existeOtraAsignacionFamiliaPatente(patente.Id, familia.Id))
     {
         throw new ProEasyException(70, "Patente sin asignacion");
     }
     patenteMapper.quitarPatente(familia, patente);
     verificadorService.actualizarDVV("FAMILIA_PATENTE");
     BitacoraService.getInstance().crear(
         Bitacora.builder()
         .Criticidad("ALTA")
         .Descripcion("SE DESASIGNO LA PATENTE:" + patente.Id + " ASIGNADAS A LA FAMILIA: " + familia.Id)
         .Funcionalidad("PATENTE")
         .Fecha(DateTime.Now)
         .Usuario(Session.getInstance().Usuario)
         .build()
         );
 }
        public override Usuario leer(long id)
        {
            Usuario usuario = this.usuarioMapper.leer(id);

            usuario.Username  = desencriptarAES(usuario.Username);
            usuario.ValorHora = desencriptarAES(usuario.ValorHora);

            BitacoraService.getInstance().crear(
                Bitacora.builder()
                .Criticidad("BAJA")
                .Descripcion("Se consulto un usuario")
                .Funcionalidad("LEER_USUARIO")
                .Fecha(DateTime.Now)
                .Usuario(Session.getInstance().Usuario)
                .build()
                );
            return(usuario);
        }
Exemple #23
0
 public void quitarPatente(Usuario usuario, Patente patente)
 {
     if (!patenteMapper.existeOtraAsignacion(patente.Id, usuario.Id))
     {
         throw new ProEasyException(70, "Patente sin asignacion");
     }
     patenteMapper.quitarPatente(usuario, patente);
     verificadorService.actualizarDVV("USUARIO_PATENTE");
     BitacoraService.getInstance().crear(
         Bitacora.builder()
         .Criticidad("ALTA")
         .Descripcion("SE DESASIGNO LA PATENTE: " + patente.Id + " AL USUARIO: " + usuario.Id)
         .Funcionalidad("PATENTE")
         .Fecha(DateTime.Now)
         .Usuario(Session.getInstance().Usuario)
         .build()
         );
 }
        public void resetPass(Usuario user)
        {
            var newPass = generarContrasenia();

            user.Contrasenia = encriptarMD5(newPass);
            actualizar(user);
            BitacoraService.getInstance().crear(
                Bitacora.builder()
                .Criticidad("MEDIA")
                .Descripcion("Se reseteo la contraseña de un usuario")
                .Funcionalidad("RESET_PASS_USUARIO")
                .Fecha(DateTime.Now)
                .Usuario(Session.getInstance().Usuario)
                .build()
                );
            user.Contrasenia = newPass;
            new EmailService().send(user, true);
        }
 public override void eliminar(Proyecto entity)
 {
     if (new TareaMapper().listarPorProyecto(entity).Count > 0)
     {
         throw new ProEasyException(41, "Proyecto tiene tareas asociadas");
     }
     mapper.eliminar(entity);
     verificadorService.actualizarDVV("PROYECTO");
     BitacoraService.getInstance().crear(
         Bitacora.builder()
         .Criticidad("ALTA")
         .Descripcion("Se elimina un proyecto")
         .Funcionalidad("PROYECTO")
         .Fecha(DateTime.Now)
         .Usuario(Session.getInstance().Usuario)
         .build()
         );
 }
Exemple #26
0
 public override void eliminar(Tarea entity)
 {
     if (new HoraMapper().listarPorTarea(entity).Count > 0)
     {
         throw new ProEasyException(21, "La tarea tiene horas cargadas");
     }
     mapper.eliminar(entity);
     verificadorService.actualizarDVV("TAREA");
     BitacoraService.getInstance().crear(
         Bitacora.builder()
         .Criticidad("MEDIA")
         .Descripcion("Se elimino una tarea")
         .Funcionalidad("TAREAS")
         .Fecha(DateTime.Now)
         .Usuario(Session.getInstance().Usuario)
         .build()
         );
 }
        public List <Familia> obtenerFamiliasDisponibles(Usuario user)
        {
            List <Familia> list = familiaMapper.obtenerFamiliasDisponibles(user);

            foreach (Familia familia in list)
            {
                familia.Nombre = desencriptarAES(familia.Nombre);
            }
            BitacoraService.getInstance().crear(
                Bitacora.builder()
                .Criticidad("ALTA")
                .Descripcion("SE OBTUVIERON LAS FAMILIAS DISPONIBLES DEL USUARIO: " + user.Username)
                .Funcionalidad("FAMILIA")
                .Fecha(DateTime.Now)
                .Usuario(Session.getInstance().Usuario)
                .build()
                );
            return(list);
        }
Exemple #28
0
        public override List <Patente> listar()
        {
            List <Patente> patentes = patenteMapper.listar();

            foreach (Patente patente in patentes)
            {
                patente.Nombre = desencriptarAES(patente.Nombre);
            }
            BitacoraService.getInstance().crear(
                Bitacora.builder()
                .Criticidad("ALTA")
                .Descripcion("SE LISTARON LAS PATENTES")
                .Funcionalidad("PATENTE")
                .Fecha(DateTime.Now)
                .Usuario(Session.getInstance().Usuario)
                .build()
                );
            return(patentes);
        }
        public override List <Familia> listar()
        {
            List <Familia> familias = familiaMapper.listar();

            foreach (Familia familia in familias)
            {
                familia.Nombre = desencriptarAES(familia.Nombre);
            }
            BitacoraService.getInstance().crear(
                Bitacora.builder()
                .Criticidad("ALTA")
                .Descripcion("SE OBTUVO EL LISTADO DE FAMILIAS")
                .Funcionalidad("FAMILIA")
                .Fecha(DateTime.Now)
                .Usuario(Session.getInstance().Usuario)
                .build()
                );
            return(familias);
        }
Exemple #30
0
        public List <Patente> obtenerPatentesAsignadas(Familia familia)
        {
            List <Patente> list = patenteMapper.obtenerPatentesAsignadas(familia);

            foreach (Patente patente in list)
            {
                patente.Nombre = desencriptarAES(patente.Nombre);
            }
            BitacoraService.getInstance().crear(
                Bitacora.builder()
                .Criticidad("ALTA")
                .Descripcion("SE OBTUVIERON LAS PANTENTES ASIGNADAS A LA FAMILIA " + familia.Id)
                .Funcionalidad("PATENTE")
                .Fecha(DateTime.Now)
                .Usuario(Session.getInstance().Usuario)
                .build()
                );
            return(list);
        }