示例#1
0
 public AuthController(IAuthRepository repo, IGymRepository repoGym, IConfiguration config, IOptions <AppSettings> appSettings)
 {
     this._repo        = repo;
     this._repoGym     = repoGym;
     this._config      = config;
     this._appSettings = appSettings;
 }
示例#2
0
        public GymAttendanceControllerTests() : base()
        {
            gymRepository           = new GymRepository(DbContext);
            gymAttendenceRepository = new GymAttendenceRepository(DbContext);

            attendanceController = new GymAttendanceController(gymRepository, gymAttendenceRepository);
        }
示例#3
0
 public CapacityController(IGymRepository repo, IConfiguration config, IMapper mapper, IOptions <AppSettings> appSettings)
 {
     this._repo        = repo;
     this._config      = config;
     this._mapper      = mapper;
     this._appSettings = appSettings;
 }
 public GymService(IGymRepository gymRepository, ILocalizationService localizationService, IConfigurationService configurationService)
 {
     GymRepository        = gymRepository;
     LocalizationService  = localizationService;
     ConfigurationService = configurationService;
     GymsByFences         = new LazyConcurrentDictionary <FenceConfiguration, int[]>();
 }
示例#5
0
 public GymController(IGymRepository gr, IGymMemberRepository gm, IUserRepository user, INotificationSettingsRepository n)
 {
     gymRepository                 = gr;
     gymMemberRepository           = gm;
     userGymMovesRepository        = user;
     notificationSettingRepository = n;
 }
示例#6
0
 public GymPageController(UserManager <ApplicationUser> userManager, IGymRepository gymRepo, ICommentRepository comRepo, IUserGymsRepository userRepo)
 {
     _gymRepo     = gymRepo;
     _comRepo     = comRepo;
     _userRepo    = userRepo;
     _userManager = userManager;
 }
示例#7
0
        public void Setup()
        {
            _rndGyms = Generate.FakeGyms();
            _gymRepo = SetupGymRepo();

            _unitOfWork = new Mock <IUnitOfWork>().Object;
        }
示例#8
0
 public GymApplicationController(IGymApplicationRepository gar, IGymRepository gr, ISupportStaffRepository ssr, IApplicationCodeRepository acr, IMailer mail)
 {
     applicationRepository = gar;
     gymRepository         = gr;
     staffRepository       = ssr;
     codeRepository        = acr;
     mailer = mail;
 }
示例#9
0
 public NotificationsController(INotificationSettingsRepository notificationSettingsRep, INotificationsRepository notificationsRep,
                                IGymRepository gymRepo, IMailer mail)
 {
     notificationSettingsRepository = notificationSettingsRep;
     notificationsRepository        = notificationsRep;
     gymRepository = gymRepo;
     mailer        = mail;
 }
示例#10
0
 public AdminController(SignInManager <AdminUser> signInManager, UserManager <AdminUser> userManager,
                        IGymRepository gymRepository, IGymLocationService gymLocationService)
 {
     _signInManager      = signInManager;
     _userManager        = userManager;
     _gymRepository      = gymRepository;
     _gymLocationService = gymLocationService;
 }
示例#11
0
 public RatingsController(IClassRepository cr, IUserRepository ur, IClassRatingRepository crr, IInstructorRatingRepository irr, IGymRepository gr)
 {
     classRepository            = cr;
     userRepository             = ur;
     classRatingRepository      = crr;
     instructorRatingRepository = irr;
     gymRepository = gr;
 }
示例#12
0
 public DbInitializer(ApplicationDbContext context, UserManager <ApplicationUser> userManager,
                      RoleManager <IdentityRole> roleManager, IAppPermissionsLookup permissions, IGymRepository gymsRepo)
 {
     this._context     = context;
     this._userManager = userManager;
     this._roleManager = roleManager;
     this._permissions = permissions;
     this._gymsRepo    = gymsRepo;
 }
示例#13
0
 public ClassesController(IUserRepository uR, IClassRepository cR, IClassRegisterRepository cRR,
                          IGymRepository gR, IMailer mail)
 {
     userRepository     = uR;
     classRepository    = cR;
     registerRepository = cRR;
     gymRepository      = gR;
     mailer             = mail;
 }
示例#14
0
 public AdminController(IGymRepository repo, IConfiguration config, IMapper mapper, IOptions <AppSettings> appSettings, IOptions <PaymentSettings> paymentSettings, IHttpClientHelper httpClientHelper)
 {
     this._repo             = repo;
     this._config           = config;
     this._mapper           = mapper;
     this._appSettings      = appSettings;
     this._httpClientHelper = httpClientHelper;
     this._paymentSettings  = paymentSettings;
 }
示例#15
0
 /*
  * Method Name:
  *  UserController
  * Purpose:
  *  This method instantiates the repositories that will be used.
  */
 public UserController(IUserRepository repoOne, IGymMemberRepository repoTwo, IGymRepository repoThree,
                       INotificationSettingsRepository repoFour, IPasswordResetRepository repoFive, IMailer repoSix)
 {
     userGymMovesRepository        = repoOne;
     gymMembersRepository          = repoTwo;
     gymRepository                 = repoThree;
     notificationSettingRepository = repoFour;
     resetPasswordRepository       = repoFive;
     mailer = repoSix;
 }
示例#16
0
 public AdminController(IGymRepository gymRepository, IOpenHoursRepository openHoursRepository, IVacancyRepository vacancyRepository,
                        UserManager <ApplicationUser> userManager, SignInManager <ApplicationUser> signInManager, IMembershipDealRepository dealRepository,
                        IAttendanceRepository attendanceRepository)
 {
     this.gymRepository        = gymRepository;
     this.openHoursRepository  = openHoursRepository;
     this.vacancyRepository    = vacancyRepository;
     this.userManager          = userManager;
     this.signInManager        = signInManager;
     this.dealRepository       = dealRepository;
     this.attendanceRepository = attendanceRepository;
 }
示例#17
0
 public HomeController(IGymRepository gymRepository, IOpenHoursRepository openHoursRepository,
                       IVacancyRepository vacancyRepository, IFreePassRepository freePassRepository, IWebHostEnvironment env,
                       IMembershipDealRepository dealRepository)
 {
     this.gymRepository       = gymRepository;
     this.openHoursRepository = openHoursRepository;
     this.vacancyRepository   = vacancyRepository;
     this.freePassRepository  = freePassRepository;
     this.env            = env;
     this.dealRepository = dealRepository;
     this.gymRepository  = gymRepository;
 }
示例#18
0
 /*
  * Method Name:
  *  UserController
  * Purpose:
  *  This method instantiates the repositories that will be used.
  */
 public UserController(IUserRepository repoOne, IGymMemberRepository repoTwo, IGymRepository repoThree,
                       INotificationSettingsRepository repoFour, IPasswordResetRepository repoFive, IMailer repoSix,
                       IGymApplicationRepository repoSeven, IApplicationCodeRepository repoEight)
 {
     userGymMovesRepository        = repoOne;
     gymMembersRepository          = repoTwo;
     gymRepository                 = repoThree;
     notificationSettingRepository = repoFour;
     resetPasswordRepository       = repoFive;
     mailer = repoSix;
     applicationRepository = repoSeven;
     codeRepository        = repoEight;
 }
示例#19
0
        private bool disposedValue = false; // To detect redundant calls

        protected virtual void Dispose(bool disposing)
        {
            if (!disposedValue)
            {
                if (disposing)
                {
                    // TODO: dispose managed state (managed objects).
                    gymRepository = null;
                }

                // TODO: free unmanaged resources (unmanaged objects) and override a finalizer below.
                // TODO: set large fields to null.

                disposedValue = true;
            }
        }
示例#20
0
        public GymClassesTests() : base()
        {
            IConfigurationBuilder configurationBuilder = new ConfigurationBuilder();

            configurationBuilder.AddJsonFile("appsettings.json");
            IConfiguration configuration = configurationBuilder.Build();

            userRepository            = new UserRepository(DbContext);
            registerRepository        = new ClassRegisterRepository(DbContext);
            classRepository           = new ClassRepository(DbContext, registerRepository);
            gymRepository             = new GymRepository(DbContext);
            classAttendanceRepository = new ClassAttendanceRepository(DbContext);

            mailer = new Mailer(configuration);

            classesController = new ClassesController(userRepository, classRepository, registerRepository, gymRepository, classAttendanceRepository, mailer);
        }
示例#21
0
        public GymApplicationTests() : base()
        {
            IConfigurationBuilder configurationBuilder = new ConfigurationBuilder();

            configurationBuilder.AddJsonFile("appsettings.json");
            IConfiguration configuration = configurationBuilder.Build();

            /* Setup Repositories */
            applicationRepository = new GymApplicationRepository(DbContext);
            gymRepository         = new GymRepository(DbContext);
            staffRepository       = new SupportStaffRepository(DbContext);
            codeRepository        = new ApplicationCodeRepository(DbContext);
            mailer = new Mailer(configuration);

            /* Setup Controllers */
            gymApplicationController = new GymApplicationController(applicationRepository, gymRepository, staffRepository, codeRepository, mailer);
        }
示例#22
0
 public ManageController(
     UserManager <ApplicationUser> userManager,
     SignInManager <ApplicationUser> signInManager,
     IEmailSender emailSender,
     ILogger <ManageController> logger,
     UrlEncoder urlEncoder,
     IUserProfileRepository userProfileRepository,
     IHostingEnvironment hostingEnvironment,
     IGymRepository gymRepository)
 {
     _userManager           = userManager;
     _signInManager         = signInManager;
     _emailSender           = emailSender;
     _logger                = logger;
     _urlEncoder            = urlEncoder;
     _userProfileRepository = userProfileRepository;
     _hostingEnvironment    = hostingEnvironment;
     _gymRepository         = gymRepository;
 }
示例#23
0
 public GymService(IGymRepository gymRepository, IUnitOfWork unitOfWork)
 {
     this.gymRepository = gymRepository;
     this.unitOfWork    = unitOfWork;
 }
示例#24
0
 /// <summary>
 /// Default constructor
 /// </summary>
 /// <param name="gymRepository"></param>
 /// <param name="mapper"></param>
 public GymApiController(IGymRepository gymRepository, IMapper mapper)
 {
     _mapper        = mapper;
     _gymRepository = gymRepository;
 }
示例#25
0
 public SearchController(IGymRepository repo, UserManager <ApplicationUser> userManager)
 {
     _gymRepo     = repo;
     _userManager = userManager;
 }
示例#26
0
 public CommentController(ICommentRepository comRepo, IGymRepository gymRepo)
 {
     _comRepo = comRepo;
     _gymRepo = gymRepo;
 }
 public GetAllGymsQueryHandler(IGymRepository gymRepository, IMapper mapper)
 {
     this.mapper        = mapper;
     this.gymRepository = gymRepository;
 }
示例#28
0
 /// <summary>
 /// Default constructor
 /// </summary>
 /// <param name="gymRepository"></param>
 public GymController(IGymRepository gymRepository)
 {
     _gymRepository = gymRepository;
 }
示例#29
0
 public GymService(IGymRepository gymRepository, IAddressService addressService)
 {
     _gymRepository  = gymRepository;
     _addressService = addressService;
 }
 public CreateGymCommandHandler(IGymRepository gymRepository, IMapper mapper)
 {
     this.gymRepository = gymRepository;
     this.mapper        = mapper;
 }