private void OnComandaECFPagamentoCallback(string IndiceECF, double Valor, ref int RetornoECF) { if (onComandaECFPagamento.IsAssigned) { var e = new ComandaECFPagamentoEventArgs(IndiceECF, Convert.ToDecimal(Valor)); onComandaECFPagamento.Raise(e); RetornoECF = e.RetornoECF ? 1 : 0; } }
private void acBrTEFD_OnComandaECFPagamento(object sender, ACBrFramework.TEFD.ComandaECFPagamentoEventArgs e) { try { DataModule.ACBrECF.EfetuaPagamento(e.IndiceECF, e.Valor); e.RetornoECF = true; } catch (Exception eError) { Log.write(eError.ToString()); e.RetornoECF = false; } }
private void tef_OnComandaECFPagamento(object sender, ComandaECFPagamentoEventArgs e) { try { WriteResp(string.Format("ECF - Pagamento, IndiceECF: {0} Valor: {1}", e.IndiceECF, e.Valor)); if(acBrECF1.Estado == EstadoECF.NaoFiscal) acBrECF1.EfetuaPagamentoNaoFiscal(e.IndiceECF, e.Valor); else acBrECF1.EfetuaPagamento(e.IndiceECF, e.Valor); e.RetornoECF = true; } catch (Exception) { e.RetornoECF = false; } }