public RangList Create(RangList a) { this.context.RangLists.Add(a); this.context.SaveChanges(); return(a); }
public ActionResult <RangListDetailMore> UpdateRangList(long id, [FromBody] RangList updatedRangList) { var rangList = this.subNineRepository.Update(id, updatedRangList); var rangListResult = this.mapper.Map <RangListDetailMore>(rangList); return(rangListResult); }
public RangList Update(long id, RangList updatedRangList) { updatedRangList.Id = id; this.context.Entry(updatedRangList).State = EntityState.Modified; this.context.SaveChanges(); return(updatedRangList); }