示例#1
0
        public ActionResult GetAllLots()
        {
            dynamic lots = 0;

            try
            {
                if (ModelState.IsValid)
                {
                    SaleServiceClient saleServiceClient = new SaleServiceClient();
                    lots = saleServiceClient.GetAllLots();
                }
            }
            catch (Exception e)
            {
                ModelState.AddModelError("error", "Something Wrong");
                lots = null;
                throw e;
            }
            return(Json(lots, JsonRequestBehavior.AllowGet));
        }