private void _vista_VistaCargandosePorPrimeraVez(object sender, EventArgs e)
        {
            try
            {
                _vista.CentrosDeDistribucion = ConfiguracionServicio.ObtenerCentrosDeDistribucionPorLogin(new Entidades.Configuracion
                {
                    LOGIN = InteraccionConUsuarioServicio.ObtenerUsuario()
                });

                _vista.ListaDeSeguridad =
                    SeguridadServicio.ObtenerPermisosDeSeguridad(new SeguridadArgumento
                {
                    Seguridad =
                        new Seguridad
                    {
                        PARENT   = Enums.GetStringValue(Tipos.PadreDePrivilegio.SolicitudDeTraslado),
                        CATEGORY = Enums.GetStringValue(Tipos.CategorigaDePrivilegio.Seguridad),
                        LOGIN    = InteraccionConUsuarioServicio.ObtenerUsuario()
                    }
                });
            }
            catch (Exception ex)
            {
                InteraccionConUsuarioServicio.Mensaje(ex.Message);
            }
        }
Beispiel #2
0
        private void btnIngresar_Click(object sender, EventArgs e)
        {
            if (string.IsNullOrEmpty(txtUsuario.Text))
            {
                MessageBox.Show("Por favor ingrese un Usuario");
                return;
            }

            if (string.IsNullOrEmpty(txtPassword.Text))
            {
                MessageBox.Show("Por favor ingrese una Contraseña");
                return;
            }

            if (SeguridadServicio.VerificarSiExiste(txtUsuario.Text, txtPassword.Text))
            {
                clienteLogin           = ClienteServicio.ObtenerPorDni(txtUsuario.Text);
                ejecutoElBotonIngresar = true;
                puedeIngresarSistema   = true;
                Close();
            }
            else
            {
                MessageBox.Show("El usuario o la contraseña son incorrectos");
                txtPassword.Clear();
                txtPassword.Focus();
            }
        }
Beispiel #3
0
        private void _vista_VistaCargandosePorPrimeraVez(object sender, EventArgs e)
        {
            try
            {
                _vista.Clientes = ClienteServicio.ObtenerClientes();
                _vista.Permisos =
                    SeguridadServicio.ObtenerPermisosDeSeguridad(new SeguridadArgumento
                {
                    Seguridad = new Seguridad {
                        PARENT = "POLIZAS_EXPIRADAS", CATEGORY = "SCREEN_SECURITY", LOGIN = InteraccionConUsuarioServicio.ObtenerUsuario()
                    }
                });

                foreach (var cliente in _vista.Clientes)
                {
                    cliente.IS_SELECTED = true;
                }
            }
            catch (Exception ex)
            {
                InteraccionConUsuarioServicio.MensajeErrorDialogo(ex.Message);
            }
        }