示例#1
0
        public bool InicioHopper()
        {
            Globals.log.Debug("Inicio de Hopper");
            List <string> data = new List <string>();

            data.Add("");
            PipeClient2 ServInicioHopper = new PipeClient2();

            ServInicioHopper.Message = Globals.servicio.BuildMessage(ServicioPago.Comandos.InicioHopper, data);
            var respuesta = ServInicioHopper.SendMessage(ServicioPago.Comandos.InicioHopper);

            if (respuesta)
            {
                if (ServInicioHopper.Resultado.Data[0] == "True")
                {
                    return(true);
                }
                else
                {
                    return(false);
                }
            }
            else
            {
                Globals.log.Error("Error al activar la hopper Transaccion: " + Globals.IDTransaccion + " Error:" + ServInicioHopper.Resultado.CodigoError + " Respuesta completa " + ServInicioHopper._Resp);
                return(false);
            }
        }
示例#2
0
        public bool DarVuelto(float vuelto)
        {
            Globals.log.Debug("Dar Vuelto");
            List <string> data = new List <string>();

            data.Add(vuelto.ToString());
            PipeClient2 ServDarVuelto = new PipeClient2();

            ServDarVuelto.Message = Globals.servicio.BuildMessage(ServicioPago.Comandos.DarVuelto, data);
            var respuesta = ServDarVuelto.SendMessage(ServicioPago.Comandos.DarVuelto);

            if (respuesta)
            {
                if (ServDarVuelto.Resultado.Data[0] == "True")
                {
                    return(true);
                }
                else
                {
                    return(false);
                }
            }
            else
            {
                Globals.log.Error("Error al Dar Vuelto Transaccion: " + Globals.IDTransaccion + " Error:" + ServDarVuelto.Resultado.CodigoError + " Respuesta completa " + ServDarVuelto._Resp);
                return(false);
            }
        }
示例#3
0
        public bool FinalizarPago()
        {
            Globals.log.Debug("Finalizar de Pago");
            List <string> data = new List <string>();

            data.Add("");
            PipeClient2 ServFiPago = new PipeClient2();

            ServFiPago.Message = Globals.servicio.BuildMessage(ServicioPago.Comandos.Fin_agregar_dinero, data);
            var respuesta = ServFiPago.SendMessage(ServicioPago.Comandos.Fin_agregar_dinero);

            if (respuesta)
            {
                if (ServFiPago.Resultado.Data[0].Contains("OK"))
                {
                    return(true);
                }
                else
                {
                    return(false);
                }
            }
            else
            {
                Globals.log.Error("Error al Empezaar el pago Transaccion: " + Globals.IDTransaccion + " Error:" + ServFiPago.Resultado.CodigoError + " Respuesta completa " + ServFiPago._Resp);
                return(false);
            }
        }
示例#4
0
        public bool FinPayout()
        {
            Globals.log.Debug("deshabilitar de payout");
            List <string> data = new List <string>();

            data.Add("");
            PipeClient2 ServFinPayout = new PipeClient2();

            ServFinPayout.Message = Globals.servicio.BuildMessage(ServicioPago.Comandos.FinPayout, data);
            var respuesta = ServFinPayout.SendMessage(ServicioPago.Comandos.FinPayout);

            if (respuesta)
            {
                if (ServFinPayout.Resultado.Data[0] == "True")
                {
                    return(true);
                }
                else
                {
                    return(false);
                }
            }
            else
            {
                Globals.log.Error("Error al deshabilitar  payout Transaccion: " + Globals.IDTransaccion + " Error:" + ServFinPayout.Resultado.CodigoError + " Respuesta completa " + ServFinPayout._Resp);
                return(false);
            }
        }
示例#5
0
        public string VueltoRegresado()
        {
            Globals.log.Debug("vuelto regresado");
            List <string> data = new List <string>();

            data.Add("");
            PipeClient2 ServVueltoRegresado = new PipeClient2();

            ServVueltoRegresado.Message = Globals.servicio.BuildMessage(ServicioPago.Comandos.EstadoVuelto, data);
            var respuesta = ServVueltoRegresado.SendMessage(ServicioPago.Comandos.EstadoVuelto);

            if (respuesta)
            {
                Globals.log.Debug("vuelto regresado " + ServVueltoRegresado.Resultado.Data[0]);
                if (ServVueltoRegresado.Resultado.Data[1] == "OK")
                {
                    return(ServVueltoRegresado.Resultado.Data[0] + "OK");
                }
                else
                {
                    return(ServVueltoRegresado.Resultado.Data[0]);
                }
            }
            else
            {
                Globals.log.Error("Error al obtener nivel  hopper Transaccion: /* + Globals.IDTransaccion + */ Error:" + ServVueltoRegresado.Resultado.CodigoError + " Respuesta completa " + ServVueltoRegresado._Resp);
                return("false");
            }
        }
示例#6
0
        public void VersionServicioPago2()
        {
            PipeClient2   pipeClient2 = new PipeClient2();
            ServicioPago  servicio    = new ServicioPago();
            List <string> data        = new List <string>();

            data.Add("");
            var resultado = false;

            pipeClient2.Message = servicio.BuildMessage(ServicioPago.Comandos.APP_FRTINI, data);
            resultado           = pipeClient2.SendMessage(ServicioPago.Comandos.APP_FRTINI);
            if (resultado == true)
            {
                EnviarInicioVersion(pipeClient2.Resultado.Data[0], "SRVLOC2");
            }
        }
示例#7
0
        public string GetAllLevelsCoin()
        {
            Globals.log.Debug("nivel de hopper");
            List <string> data = new List <string>();

            data.Add("");
            PipeClient2 ServNivelMoneda = new PipeClient2();

            ServNivelMoneda.Message = Globals.servicio.BuildMessage(ServicioPago.Comandos.GetAllLevelsCoin, data);
            var respuesta = ServNivelMoneda.SendMessage(ServicioPago.Comandos.GetAllLevelsCoin);

            if (respuesta)
            {
                return(ServNivelMoneda.Resultado.Data[0]);
            }
            else
            {
                Globals.log.Error("Error al obtener nivel  hopper Transaccion: /* + Globals.IDTransaccion + */ Error:" + ServNivelMoneda.Resultado.CodigoError + " Respuesta completa " + ServNivelMoneda._Resp);
                return("false");
            }
        }
示例#8
0
        public bool DetenerVuelto()
        {
            Globals.log.Debug("Inicio de Estado de Salud");
            List <string> data = new List <string>();

            data.Add("");
            PipeClient2 detenerVuelto = new PipeClient2();

            detenerVuelto.Message = Globals.servicio.BuildMessage(ServicioPago.Comandos.DetenerVuelto, data);
            var respuesta = detenerVuelto.SendMessage(ServicioPago.Comandos.DetenerVuelto);

            if (respuesta)
            {
                return(respuesta);
            }
            else
            {
                Globals.log.Error("Error al obtener nivel  hopper Transaccion: /* + Globals.IDTransaccion + */ Error:" + detenerVuelto.Resultado.CodigoError + " Respuesta completa " + detenerVuelto._Resp);
                return(false);
            }
        }
示例#9
0
        public bool FloatByDenominationMoneda()
        {
            Globals.log.Debug("Inicio del float moneda");
            List <string> data = new List <string>();

            data.Add("");
            PipeClient2 FloatMoneda = new PipeClient2();

            FloatMoneda.Message = Globals.servicio.BuildMessage(ServicioPago.Comandos.FloatMoneda, data);
            var respuesta = FloatMoneda.SendMessage(ServicioPago.Comandos.FloatMoneda);

            if (respuesta)
            {
                return(true);
            }
            else
            {
                Globals.log.Error("Error al obtener nivel  hopper Transaccion:  + Globals.IDTransaccion +  Error:" + FloatMoneda.Resultado.CodigoError + " Respuesta completa " + FloatMoneda._Resp);
                return(false);
            }
        }
示例#10
0
        public string DinerIngresado()
        {
            Globals.log.Debug("Dinero Ingreado");
            List <string> data = new List <string>();

            data.Add("");
            PipeClient2 ServDinerIngresado = new PipeClient2();

            ServDinerIngresado.Message = Globals.servicio.BuildMessage(ServicioPago.Comandos.Cons_dinero_ingre, data);
            var respuesta = ServDinerIngresado.SendMessage(ServicioPago.Comandos.Cons_dinero_ingre);

            if (respuesta)
            {
                Globals.log.Debug("Dinero Ingresado " + ServDinerIngresado.Resultado.Data[0]);
                return(ServDinerIngresado.Resultado.Data[0]);
            }
            else
            {
                Globals.log.Error("Error al obtener nivel  hopper Transaccion: /* + Globals.IDTransaccion + */ Error:" + ServDinerIngresado.Resultado.CodigoError + " Respuesta completa " + ServDinerIngresado._Resp);
                return("false");
            }
        }