I am working on a C# E-commerce Application.
After I add two products to my shopping cart, I get Multiple Endpoints error when attempting to delete from the cart.
How can I succesfully delete these items? Please view the two images attached below.
you have two endpoit with same httpmethods(delete) and same parameter(onlineshop),you need to be unique route to avoid route conflicts.
[HttpDelete("remove")]
public IActionResult Remove(OnlineShop model)
{
}
[HttpDelete("removeToChart")]
public IActionResult RemoveToChart(OnlineShop model)
{
}
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.