public TaxTypeModel GetById(int id)
        {
            var tax = taxRepository.GetById(id);

            Mapper.Initialize(cfg => { cfg.CreateMap <TaxType, TaxTypeModel>(); });

            var taxModel = Mapper.Map <TaxTypeModel>(tax);


            return(taxModel);
        }
Ejemplo n.º 2
0
        public void DeleteTax(int id)
        {
            var tax = _taxRepository.GetById(id);

            _taxRepository.Delete(tax);
        }
Ejemplo n.º 3
0
 public Task <TaxReadModel> GetById(Guid taxId, CancellationToken cancellationToken) =>
 _taxRepository.GetById(taxId, cancellationToken);