示例#1
0
        public ActionResult DeleteAuction(DateTime AucDate)
        {
            bool status = false;

            try
            {
                if (ModelState.IsValid)
                {
                    AuctionServiceClient auctionServiceClient = new AuctionServiceClient();

                    status = auctionServiceClient.Delete(AucDate);
                    return(RedirectToAction("Index"));
                }
            }
            catch (Exception e)
            {
                ModelState.AddModelError("error", "Something Went Wrong!");
                status = false;
                throw e;
            }
            return(View());
            //return new JsonResult { Data = new { status = status } };
        }