public async Task <IActionResult> PutLocation(int id, Location location) { if (id != location.Gcode) { return(BadRequest()); } _context.Entry(location).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!LocationExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <ActionResult <Pocan2> > PostPocan2(Pocan2 pocan2) { _context.Pocan2s.Add(pocan2); await _context.SaveChangesAsync(); return(CreatedAtAction("GetPocan2s", new { id = pocan2.Id }, pocan2)); }
public async Task <IActionResult> PutProduct(string id, Product product) { if (id != product.Pcode) { return(BadRequest()); } _context.Entry(product).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!ProductExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <ActionResult <Pret2> > PostPret2(Pret2 pret2) { _context.Pret2s.Add(pret2); await _context.SaveChangesAsync(); return(CreatedAtAction("GetPret2s", new { id = pret2.Id }, pret2)); }
public async Task <ActionResult <Sorder2> > PostSorder2(Sorder2 sorder2) { _context.Sorder2s.Add(sorder2); await _context.SaveChangesAsync(); return(CreatedAtAction("GetSorder2", new { id = sorder2.Id }, sorder2)); }
public async Task <ActionResult <Credit> > PostCredit(Credit credit) { _context.Credits.Add(credit); await _context.SaveChangesAsync(); return(CreatedAtAction("GetCredits", new { id = credit.Id }, credit)); }
public async Task <ActionResult <Stockpo> > PostStockpo(Stockpo stockpo) { _context.Stockpos.Add(stockpo); await _context.SaveChangesAsync(); return(CreatedAtAction("GetStockpos", new { id = stockpo.Id }, stockpo)); }
public async Task <ActionResult <Salecash2> > PostSalecash2(Salecash2 salecash2) { _context.Salecash2s.Add(salecash2); await _context.SaveChangesAsync(); return(CreatedAtAction("GetSalecash2s", new { id = salecash2.Id }, salecash2)); }
public async Task <IActionResult> PutColor(int id, Color color) { if (id != color.Grp) { return(BadRequest()); } _context.Entry(color).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!ColorExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <ActionResult <LesslistNew> > PostLesslistNew(LesslistNew lesslistNew) { _context.LesslistNews.Add(lesslistNew); await _context.SaveChangesAsync(); return(CreatedAtAction("GetLesslistNew", new { id = lesslistNew.Id }, lesslistNew)); }
public async Task <ActionResult <Cashrcp> > PostCashrcp(Cashrcp cashrcp) { _context.Cashrcps.Add(cashrcp); await _context.SaveChangesAsync(); return(CreatedAtAction("GetCashrcps", new { id = cashrcp.Id }, cashrcp)); }
public async Task <IActionResult> PutGprice(int id, Gprice gprice) { if (id != gprice.Id) { return(BadRequest()); } _context.Entry(gprice).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!GpriceExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <ActionResult <Purch2> > PostPurch2(Purch2 purch2) { _context.Purch2s.Add(purch2); await _context.SaveChangesAsync(); return(CreatedAtAction("GetPurch2s", new { id = purch2.Id }, purch2)); }
public async Task <ActionResult <Journal> > PostJournal(Journal journal) { _context.Journals.Add(journal); await _context.SaveChangesAsync(); return(CreatedAtAction("GetJournals", new { id = journal.Id }, journal)); }
public async Task <IActionResult> PutSale1(int id, Sale1 sale1) { if (id != sale1.No) { return(BadRequest()); } _context.Entry(sale1).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!Sale1Exists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <ActionResult <Prdinfo> > PostPrdinfo(Prdinfo prdinfo) { _context.Prdinfos.Add(prdinfo); await _context.SaveChangesAsync(); return(CreatedAtAction("GetPrdinfos", new { id = prdinfo.Id }, prdinfo)); }
public async Task <ActionResult <Bankjv> > PostBankjv(Bankjv bankjv) { _context.Bankjvs.Add(bankjv); await _context.SaveChangesAsync(); return(CreatedAtAction("GetBankjvs", new { id = bankjv.Id }, bankjv)); }
public async Task <ActionResult <Claim2> > PostClaim2(Claim2 claim2) { _context.Claim2s.Add(claim2); await _context.SaveChangesAsync(); return(CreatedAtAction("GetClaim2s", new { id = claim2.Id }, claim2)); }
public async Task <ActionResult <Pujournal> > PostPujournal(Pujournal pujournal) { _context.Pujournals.Add(pujournal); await _context.SaveChangesAsync(); return(CreatedAtAction("GetPujournals", new { id = pujournal.Id }, pujournal)); }
public async Task <ActionResult <Sljournal> > PostSljournal(Sljournal sljournal) { _context.Sljournals.Add(sljournal); await _context.SaveChangesAsync(); return(CreatedAtAction("GetSljournals", new { id = sljournal.Id }, sljournal)); }
public async Task <ActionResult <Sret2> > PostSret2(Sret2 sret2) { _context.Sret2s.Add(sret2); await _context.SaveChangesAsync(); return(CreatedAtAction("GetSret2s", new { id = sret2.Id }, sret2)); }
public async Task <IActionResult> PutTransport(short id, Transport transport) { if (id != transport.Tcode) { return(BadRequest()); } _context.Entry(transport).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!TransportExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <ActionResult <Opjournal> > PostOpjournal(Opjournal opjournal) { _context.Opjournals.Add(opjournal); await _context.SaveChangesAsync(); return(CreatedAtAction("GetOpjournals", new { id = opjournal.Id }, opjournal)); }
public async Task <ActionResult <Mprodtn2> > PostMprodtn2(Mprodtn2 mprodtn2) { _context.Mprodtn2s.Add(mprodtn2); await _context.SaveChangesAsync(); return(CreatedAtAction("GetMprodtn2s", new { id = mprodtn2.Id }, mprodtn2)); }
public async Task <ActionResult <StockColor> > PostStockColor(StockColor stockColor) { _context.StockColors.Add(stockColor); await _context.SaveChangesAsync(); return(CreatedAtAction("GetStockColors", new { id = stockColor.Id }, stockColor)); }
public async Task <ActionResult <Cashpym> > PostCashpym(Cashpym cashpym) { _context.Cashpyms.Add(cashpym); await _context.SaveChangesAsync(); return(CreatedAtAction("GetCashpyms", new { id = cashpym.Id }, cashpym)); }
public async Task <ActionResult <Gin2> > PostGin2(Gin2 gin2) { _context.Gin2s.Add(gin2); await _context.SaveChangesAsync(); return(CreatedAtAction("GetGin2s", new { id = gin2.Id }, gin2)); }
public async Task <ActionResult <Debit> > PostDebit(Debit debit) { _context.Debits.Add(debit); await _context.SaveChangesAsync(); return(CreatedAtAction("GetDebits", new { id = debit.Id }, debit)); }
public async Task <IActionResult> PutPgroup(int id, Pgroup pgroup) { if (id != pgroup.Pgrp) { return(BadRequest()); } _context.Entry(pgroup).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!PgroupExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <ActionResult <Gnrllgr> > PostGnrllgr(Gnrllgr gnrllgr) { _context.Gnrllgrs.Add(gnrllgr); await _context.SaveChangesAsync(); return(CreatedAtAction("GetGnrllgrs", new { id = gnrllgr.Id }, gnrllgr)); }