/// <inheritdoc /> /// <summary> /// Creates the client. /// </summary> /// <param name="client">The client.</param> /// <returns><c>true</c> if XXXX, <c>false</c> otherwise.</returns> public bool CreateClient(Client client) { try { _clientWrite = new WriteClientRepository(_context); _clientWrite.Create(client); _context.SaveChanges(); return(true); } catch (Exception e) { var message = DbEntityCustomException.BuildMessageExceptions(e); throw new DbEntityCustomException(message); } }
/// <inheritdoc /> /// <summary> /// Saves the changes. /// </summary> public void SaveChanges() { _context.SaveChanges(); }