public Repository(CapstoneDBContext context) { _dbSet = context.Set <T>(); ScopedOnWriteEventAsync += context.VoidEventSaveChangesAsync; ScopedOnWriteManyEventAsync += context.VoidEventSaveChangesAsync; ScopedOnUpdateEvent += context.VoidEventSaveChanges; ScopedOnDeleteEventAsync += context.VoidEventSaveChangesAsync; ScopedOnDeleteManyEventAsync += context.VoidEventSaveChangesAsync; ScopedOnWriteEvent += context.VoidEventSaveChanges; ScopedOnWriteManyEvent += context.VoidEventSaveChanges; ScopedOnUpdateEvent += context.VoidEventSaveChanges; ScopedOnDeleteEvent += context.VoidEventSaveChanges; ScopedOnDeleteManyEvent += context.VoidEventSaveChanges; }
public async Task <IEnumerable <Student> > GetAllAsync() { return(await _context.Set <Student>().ToListAsync()); }
public async Task <IEnumerable <Group> > GetAllAsync() { return(await _context.Set <Group>().ToListAsync()); }
public async Task <IEnumerable <Notification> > GetAllAsync() { return(await _context.Set <Notification>().ToListAsync()); }