public async Task <IActionResult> Edit(int id, [Bind("ArvindPaymentId,Arvind,OnDate,InvoiceNo,Amount,BankDetails,Remarks")] ArvindPayment arvindPayment) { if (id != arvindPayment.ArvindPaymentId) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(arvindPayment); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!ArvindPaymentExists(arvindPayment.ArvindPaymentId)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(PartialView(arvindPayment)); }
public async Task <IActionResult> Create([Bind("ArvindPaymentId,Arvind,OnDate,InvoiceNo,Amount,BankDetails,Remarks")] ArvindPayment arvindPayment) { if (ModelState.IsValid) { _context.Add(arvindPayment); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } return(PartialView(arvindPayment)); }