public ActionResult Create(CashDrawer item) { if (!ModelState.IsValid) return PartialView ("_Create", item); item.Store = Store.Find (item.StoreId); using (var scope = new TransactionScope ()) { item.CreateAndFlush (); } return PartialView ("_CreateSuccesful", item); }
public ActionResult Create(CashDrawer item) { if (!ModelState.IsValid) { return(PartialView("_Create", item)); } item.Store = Store.Find(item.StoreId); using (var scope = new TransactionScope()) { item.CreateAndFlush(); } return(PartialView("_CreateSuccesful", item)); }