public OperationResult AddEmployeeWithProfile(Profile profile) { var attachResult = AttachEmployeerIfNeeded(profile); if (!attachResult.Ok) { return(attachResult); } dbContext.Add(profile); dbContext.SaveChanges(); return(OperationResult.BuildSuccess()); }
public OperationResult Add(T value) {//verification? dbContext.Add(value); dbContext.SaveChanges(); return(OperationResult.BuildSuccess()); }