public ActionResult Create(CollectionTmp collectionTmp) { var response = MovementsHelper.NewCollection(User.Identity.Name); var responseUpdate = MovementsHelper.UpdateInventories(User.Identity.Name); // var errors = ModelState.Where(x => x.Value.Errors.Count > 0) //.Select(x => new { x.Key, x.Value.Errors }) //.ToArray(); if (ModelState.IsValid) { //db.CollectionTmps.Add(collectionTmp); //await db.SaveChangesAsync(); return(RedirectToAction("Index")); } return(RedirectToAction("Index")); }