Beispiel #1
0
 public UnitOfWork(ApplicationDbContext context)
 {
     _context        = context;
     Polls           = new PollRepository(_context);
     Answers         = new AnswerRepository(_context);
     Users           = new UserRepository(_context);
     DailyStatistics = new DailyStatisticsRepository(_context);
     UniqueVisitors  = new UniqueVisitorsRepository(_context);
 }
Beispiel #2
0
 public StatisticsService()
 {
     smoONEContext                   = new SmoONEDbContext();
     _unitOfWork                     = new UnitOfWork(smoONEContext);
     _AT_CustomDateRepository        = new AT_CustomDateRepository(smoONEContext);
     _AttendanceLogRepository        = new AttendanceLogRepository(smoONEContext);
     _AttendanceTemplateRepository   = new AttendanceTemplateRepository(smoONEContext);
     _attendanceSchedulingRepository = new AttendanceSchedulingRepository(smoONEContext);
     _monthlyStatisticsRepository    = new MonthlyStatisticsRepository(smoONEContext);
     _dailyStatisticsRepository      = new DailyStatisticsRepository(smoONEContext);
     _AT_UserLogRepository           = new AT_UserLogRepository(smoONEContext);
     _monthlyResultRepository        = new MonthlyResultRepository(smoONEContext);
     InitializeComponent();
 }