i want to create a method using dictionary .so that i can map one id with other id in same table and it should be one to many relationship . so that on click i can update all level id in one shot .
public bool UpdateVisioData(VisioShapeDataDALDTO visioObjToUpdate)
{
bool isUpdate = false;
if (visioObjToUpdate.ModifiedDate == DateTime.MinValue)
visioObjToUpdate.ModifiedDate = DateTime.Now;
VisioShapeData entity = DBContext.VisioShapeDatas.Where(a => a.ID == visioObjToUpdate.ID).FirstOrDefault();
entity.Level4Id = visioObjToUpdate.Level4Id;
if (DBContext.SaveChanges() > 0)
{
isUpdate = true;
}
return isUpdate;
}