public HandoverDocument Update(HandoverDocument documentChanges) { var document = context.HandoverDocuments.Attach(documentChanges); document.State = Microsoft.EntityFrameworkCore.EntityState.Modified; context.SaveChanges(); return(documentChanges); }
public HandoverDocument Create(HandoverDocument document) { context.HandoverDocuments.Add(document); context.SaveChanges(); return(document); }