public ActionResult GetData() { using (ShopModel db = new ShopModel()) { List <OrderDetails_Result> orderList = db.OrderDetails().ToList <OrderDetails_Result>(); return(Json(new { data = orderList }, JsonRequestBehavior.AllowGet)); } }