public async Task <IActionResult> Create([Bind("PolicyID,PolicyLocationID,LocationNumber,LocationDescription,LocationAddress,LocationCity,LocationState,LocationZip")] PolicyLocation policyLocation) { if (ModelState.IsValid) { _context.Add(policyLocation); await _context.SaveChangesAsync(); return(RedirectToAction("Index")); } return(View(policyLocation)); }
public async Task <IActionResult> Create([Bind("OutageID,StartDate,EndDate,Application,Description")] Outage outage) { if (ModelState.IsValid) { _context.Add(outage); await _context.SaveChangesAsync(); return(RedirectToAction("Index")); } return(View(outage)); }
public async Task <IActionResult> Create([Bind("PolicyID,PolicyNumber,EffectiveDate,ExpirationDate,PremiumAmount,InsuredName")] Policy policy) { if (ModelState.IsValid) { _context.Add(policy); await _context.SaveChangesAsync(); return(RedirectToAction("Index")); } return(View(policy)); }