Осталось привязать к вируалке

This commit is contained in:
maxnes3 2023-05-02 23:19:34 +04:00
parent 681a92d13f
commit c66fb80196

View File

@ -93,7 +93,7 @@ namespace PersonnelDepartmentDatabaseImplement.Implements
using var context = new PersonnelDepartmentDatabase();
context.Deals.Add(newElement);
context.SaveChanges();
return newElement.GetViewModel;
return GetElement(new DealSearchModel { Id = newElement.Id } );
}
public DealViewModel? Update(DealBindingModel model)
@ -111,7 +111,7 @@ namespace PersonnelDepartmentDatabaseImplement.Implements
}
element.Update(model);
context.SaveChanges();
return element.GetViewModel;
return GetElement(new DealSearchModel { Id = element.Id });
}
}
}