public async Task <IActionResult> PutBlackList(int id, BlackList blackList) { if (id != blackList.Id) { return(BadRequest()); } _context.Entry(blackList).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!BlackListExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <IActionResult> PutPricing(int id, Pricing pricing) { if (id != pricing.Id) { return(BadRequest()); } _context.Entry(pricing).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!PricingExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <IActionResult> PutCarCopy(int id, CarCopy carCopy) { if (id != carCopy.Id) { return(BadRequest()); } _context.Entry(carCopy).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!CarCopyExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }