예제 #1
0
        public UnitOfWork(AssessoriasConsultoriasDbContext context, IDapperDbConnection dapperDbConnection)
        {
            _context            = context;
            _dapperDbConnection = dapperDbConnection;
            //_dapperDbConnection.OpenConnection();

            Contratos = new ContratoRepository(_context, _dapperDbConnection);
            Parceiros = new ParceiroRepository(_context, _dapperDbConnection);
        }
예제 #2
0
 public AssessoriasConsultoriasIntegrationEventService(
     ILogger <AssessoriasConsultoriasIntegrationEventService> logger,
     IEventBus eventBus,
     AssessoriasConsultoriasDbContext assessoriasConsultoriasDbContext
     /*,Func<DbConnection, IIntegrationEventLogService> integrationEventLogServiceFactory*/)
 {
     _logger = logger ?? throw new ArgumentNullException(nameof(logger));
     _assessoriasConsultoriasDbContext = assessoriasConsultoriasDbContext ?? throw new ArgumentNullException(nameof(assessoriasConsultoriasDbContext));
     //  _integrationEventLogServiceFactory = integrationEventLogServiceFactory ?? throw new ArgumentNullException(nameof(integrationEventLogServiceFactory));
     _eventBus = eventBus ?? throw new ArgumentNullException(nameof(eventBus));
     //_eventLogService = _integrationEventLogServiceFactory(_gestaoNormasDbContext.Database.GetDbConnection());
 }
예제 #3
0
 public ParceiroRepository(AssessoriasConsultoriasDbContext context, IDapperDbConnection dapperDbConnection) : base(dapperDbConnection)
 {
     _context = context;
 }