public async Task <ActionResult <ProductRespone> > UpdateProduct(int id, [FromForm] ProductRequest productReq) { var productRes = await _productRepository.UpdateProduct(id, productReq); return(Ok(productRes)); }
public async Task <ActionResult <ProductRespone> > CreateProduct([FromForm] ProductRequest productReq) { var product = await _productRepository.CreateProduct(productReq); return(Created(Endpoints.Product, product)); }