コード例 #1
0
        public ActionResult GetOrderDetail(string OrderId)
        {
            AjaxResult result = new AjaxResult();

            try
            {
                var list = OrderDetailLogic.GetList().Where(t => t.c_order_id == OrderId).ToList();
                foreach (var item in list)
                {
                    item.Pro = ProductLogic.GetEnityById(item.c_product_id);
                }
                result.data    = list;
                result.state   = ResultType.success.ToString();
                result.message = "成功";
                return(Content(result.ToJson()));
            }
            catch (Exception ex)
            {
                result.state   = ResultType.error.ToString();
                result.message = string.Format("({0})", ex.Message);
                return(Content(result.ToJson()));

                throw;
            }
        }