public async Task <ActionResult> Put(int id, [FromBody] ClaimCreationDTO claimCreation) { var claim = mapper.Map <CustClaim>(claimCreation); claim.Id = id; context.Entry(claim).State = EntityState.Modified; await context.SaveChangesAsync(); return(NoContent()); }
public async Task <ActionResult> Put(int id, [FromBody] PaymentCreationDTO paymentCreation) { var payment = mapper.Map <Payment>(paymentCreation); payment.Id = id; context.Entry(payment).State = EntityState.Modified; await context.SaveChangesAsync(); return(NoContent()); }
public async Task <ActionResult> Put(int id, [FromBody] PolicyCreationDTO policyCreation) { var policy = mapper.Map <Policy>(policyCreation); policy.Id = id; context.Entry(policy).State = EntityState.Modified; await context.SaveChangesAsync(); return(NoContent()); }
public async Task <ActionResult> Put(int id, [FromBody] CoverageCreationDTO coverageCreation) { var coverage = mapper.Map <Coverage>(coverageCreation); coverage.Id = id; context.Entry(coverage).State = EntityState.Modified; await context.SaveChangesAsync(); return(NoContent()); }
public async Task <ActionResult> Put(int id, [FromBody] VehicleCreationDTO vehicleCreation) { var vehicle = mapper.Map <Vehicle>(vehicleCreation); vehicle.Id = id; context.Entry(vehicle ).State = EntityState.Modified; await context.SaveChangesAsync(); return(NoContent()); }