Example #1
0
        public UnitOfWork(DbCoreDataContext context)
        {
            _context = context;

            DictionaryRepository  = new DictionaryRepository(_context);
            UserRepository        = new UserRepository(_context);
            RoleRepository        = new RoleRepository(_context);
            PermissionRepository  = new PermissionRepository(_context);
            OrderRepository       = new OrderRepository(_context);
            OrderDetailRepository = new OrderDetailRepository(_context);
            ClientRepository      = new ClientRepository(_context);
        }
        private void Dispose(bool disposing)
        {
            if (!disposing)
            {
                return;
            }

            if (_dbCoreDataContext == null)
            {
                return;
            }

            _dbCoreDataContext.Dispose();
            _dbCoreDataContext = null;
        }
Example #3
0
 public ExpenseRepository(DbCoreDataContext serkoCoreDataContext)
 => _serkoCoreDataContext = serkoCoreDataContext;
 public UnitOfWork(DbCoreDataContext skynetCoreDataContext)
 {
     _dbCoreDataContext = skynetCoreDataContext;
 }
Example #5
0
 public EmployeeRepository(DbCoreDataContext skynetCoreDataContext)
     => _skynetCoreDataContext = skynetCoreDataContext;