public async Task <IActionResult> PutTms_OnboardingDeposits(int id, Tms_OnboardingDeposits tms_OnboardingDeposits) { if (id != tms_OnboardingDeposits.DepositId) { return(BadRequest()); } _context.Entry(tms_OnboardingDeposits).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!Tms_OnboardingDepositsExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <ActionResult <Tms_OnboardingDeposits> > PostTms_OnboardingDeposits(Tms_OnboardingDeposits tms_OnboardingDeposits) { _context.OnboardingDeposits.Add(tms_OnboardingDeposits); await _context.SaveChangesAsync(); return(CreatedAtAction("GetTms_OnboardingDeposits", new { id = tms_OnboardingDeposits.DepositId }, tms_OnboardingDeposits)); }
public async Task <ActionResult <Tms_OnboardingDeposits> > PostTms_OnboardingDeposits(Tms_OnboardingDeposits tms_OnboardingDeposits) { _context.OnboardingDeposits.Add(tms_OnboardingDeposits); try { await _context.SaveChangesAsync(); } catch { if (Tms_OnboardingDepositsExists(tms_OnboardingDeposits.DepositId)) { return(Conflict()); } else { throw; } } return(CreatedAtAction("GetTms_OnboardingDeposits", new { id = tms_OnboardingDeposits.DepositId }, tms_OnboardingDeposits)); }