public IActionResult Meals(MealsViewModel model) { IRequestCookieCollection objCookies = HttpContext.Request.Cookies; var sessionData = string.IsNullOrEmpty(HttpContext.Request.Cookies["VoyagerUser_Id"]) ? HttpContext.Session.GetComplexData <List <ProductAttributeDetails> >(SessionName) : null; PositionSetRes objPositionSetRes = positionMapping.SetAllMealDetails(_configuration, token, model, objCookies, sessionData); //if (objPositionSetRes != null && objPositionSetRes.ResponseStatus.Status.ToLower() == "success") //{ // TempData["success"] = objPositionSetRes.ResponseStatus.ErrorMessage; //} //else //{ // TempData["error"] = objPositionSetRes.ResponseStatus.ErrorMessage; //} //return RedirectToAction("Meals", new { model.MenuViewModel.QRFID }); objPositionSetRes.ResponseStatus.ErrorMessage = "Meal " + objPositionSetRes.ResponseStatus.ErrorMessage; return(Json(new { objPositionSetRes.ResponseStatus })); }