Example #1
0
        public async Task <TaxEntryDto> InsertTaxEntryAsync(string municipalityName, TaxEntryCreateDto taxEntry)
        {
            var municipality = _taxRepository.GetMunicipalityAsync(municipalityName);

            if (municipality == null)
            {
                //Todo handle
            }

            var entity = _mapper.Map <TaxEntry>(taxEntry);

            return(_mapper.Map <TaxEntryDto>(await _taxRepository.InsertTaxEntryAsync(entity)));
        }