public ActionResult QueryForColor(LotMaterialListViewModel model) { string strErrorMessage = string.Empty; MethodReturnResult <DataSet> result = new MethodReturnResult <DataSet>(); try { using (LotQueryServiceClient client = new LotQueryServiceClient()) { //RPTLotMateriallistParameter param = new RPTLotMateriallistParameter(); //param.LotNumber = model.LotNumber; string lot = model.LotNumber; MethodReturnResult <DataSet> ds = client.GetLotColor(lot); ViewBag.HistoryList = ds; } } catch (Exception ex) { result.Code = 1000; result.Message = ex.Message; result.Detail = ex.ToString(); } if (Request.IsAjaxRequest()) { return(PartialView("_ColorListPartial", model)); } else { return(View("IndexColor", model)); } }