Exemple #1
0
        public async Task <IActionResult> CancelOrder([FromBody] OrderIdDTO orderIdDTO)
        {
            if (!(User.IsInRole("Admin")))
            {
                return(RedirectToAction("Index", "Home"));
            }
            await orderService.CancelOrder(orderIdDTO.OrderId);

            return(Json(new
            {
                newUrl = "/admin/orders"
            }));
        }
Exemple #2
0
 public Task <bool> EndOrder(OrderIdDTO data)
 {
     throw new NotImplementedException();
 }