using DrinkRateAPI.ApiModels.ProductTable; using DrinkRateAPI.Services; using Microsoft.AspNetCore.Mvc; namespace DrinkRateAPI.Controllers; [ApiController] [Route("productTables")] public class ProductTableController : ControllerBase { private ProductTableService _productTableService; public ProductTableController(ProductTableService productTableService) { _productTableService = productTableService; } [HttpGet("{productTableName}")] [Produces("application/json")] public async Task GetProductTable([FromRoute] string productTableName) { return await _productTableService.GetProductTable(productTableName); } }