public async Task <ActionResult <PmIssues> > PostPmIssues(PmIssues pmIssues) { _context.PmIssues.Add(pmIssues); await _context.SaveChangesAsync(); return(CreatedAtAction("GetPmIssues", new { id = pmIssues.PmIssueId }, pmIssues)); }
public async Task <IActionResult> PutPmIssues(int id, PmIssues pmIssues) { if (id != pmIssues.PmIssueId) { return(BadRequest()); } _context.Entry(pmIssues).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!PmIssuesExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }