using AutoMapper; using Microsoft.AspNetCore.Mvc; using SytelineSaAppEfDataModel.Dtos; using SytelineSaAppEfDataModel.Services; namespace FaKrosnoApi.Controllers; [ApiController] [Route("api/[controller]")] public class VatCodeAssociationController(IVatCodeAssociationService service, IMapper mapper) : Controller { [HttpGet("by-parameters")] public async Task> GetVatCodesAssociation(string customerDoInvoice, string endUserType, string productCode) { var result = await service.GetVatCodesAssociation(customerDoInvoice, endUserType, productCode); if (result == null) { return NotFound(); } return Ok(mapper.Map(result)); } }