Cleanup and fixes

This commit is contained in:
2013-01-12 14:58:33 -05:00
parent bc019923d2
commit e50052d41e
27 changed files with 240 additions and 156 deletions
+4 -8
View File
@@ -22,17 +22,13 @@ namespace MileageTraker.Web.Controllers
[HttpPost]
public ActionResult Index(CreateLogViewModel model)
{
if (!ModelState.IsValid)
if (ModelState.IsValid)
{
ViewBag.updateError = "Create Failure";
if (model.LogType == null) // WTF why doesn't the model binder get this
model.LogType = new MileageLogTypeWrapper();
return View(model);
var confirmCreateLogViewModel = new ConfirmCreateLogViewModel(model);
return View("Confirm", confirmCreateLogViewModel);
}
var confirmCreateLogViewModel = new ConfirmCreateLogViewModel(model);
return View("Confirm", confirmCreateLogViewModel);
return View(model);
}
[HttpParamAction]