Пример #1
0
        public double CalculoTaxa(Transacao _transacao)
        {
            MDR Mdr = _mdrRepositorio.GetMDR().FirstOrDefault(mdr => mdr.Adquirente == _transacao.Adquirente.ToLower());

            Taxa taxa = Mdr.Taxas.FirstOrDefault(_taxa => _taxa.Bandeira == _transacao.Bandeira.ToLower());

            if (_transacao.Tipo.ToLower() == "credito")
            {
                return(CalculoTaxacredito(_transacao, taxa));
            }

            if (_transacao.Tipo.ToLower() == "debito")
            {
                return(CalculoTaxadebito(_transacao, taxa));
            }

            return(0);
        }
Пример #2
0
 public IActionResult Get()
 {
     return(Ok(_mdrRepositorio.GetMDR()));
 }