public async Task <ProductResponse> HandleAsncy(int id) { var item = await repository.GetByIdAsync <Product>(id); return(ProductResponse.FromProduct(item)); }
public async Task <ActionResult <ProductResponse> > HandleAsncy(ProductRequest request) { var product = await useCase.Handle(request.ToProduct()); return(ProductResponse.FromProduct(product)); }
public async Task <ActionResult <ProductResponse> > HandleAsncy(int id, ProductRequest request) { var response = await this.useCase.Handle(request.ToProduct(id)); return(ProductResponse.FromProduct(response)); }