public int Insert(KolabCore.Defect entity)
 {
     context.Defects.Add(entity);
     update();
     return entity.Id;
 }
 public int Update(KolabCore.Defect entity)
 {
     throw new NotImplementedException();
 }
 public void Delete(KolabCore.Defect entity)
 {
     context.Entry(entity).State = EntityState.Deleted;
     update();
 }