public async Task <IActionResult> Edit(int id, [Bind("IndiID,IndicatorName,GPEOrginalTarget,GPERevisedTarget,GPERevisedAchieved,GPEUnMetTarget,EUTarget,EUAchieved,CumulativeTarget")] CumulativeRF cumulativeRF) { if (id != cumulativeRF.IndiID) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(cumulativeRF); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!CumulativeRFExists(cumulativeRF.IndiID)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(cumulativeRF)); }
public async Task <IActionResult> Create([Bind("IndiID,IndicatorName,GPEOrginalTarget,GPERevisedTarget,GPERevisedAchieved,GPEUnMetTarget,EUTarget,EUAchieved,CumulativeTarget")] CumulativeRF cumulativeRF) { if (ModelState.IsValid) { _context.Add(cumulativeRF); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } return(View(cumulativeRF)); }