public BookCourtModel(ICourtBookingManager courtBookingManager, UserManager <TennisBookingsUser> userManager, IOptions <BookingConfiguration> bookingConfig, IBookingService bookingService)
 {
     _courtBookingManager  = courtBookingManager;
     _userManager          = userManager;
     _bookingService       = bookingService;
     _bookingConfiguration = bookingConfig.Value;
 }
 protected override void OnModelCreating(ModelBuilder modelBuilder)
 {
     modelBuilder.HasDefaultSchema("efcore");
     MemberConfiguration.Configure(modelBuilder.Entity <Member>());
     FacilityConfiguration.Configure(modelBuilder.Entity <Facility>());
     BookingConfiguration.Configure(modelBuilder.Entity <Booking>());
     base.OnModelCreating(modelBuilder);
 }
Exemple #3
0
 public void Setup()
 {
     config = new BookingConfiguration {
         TimeBlockLength = TimeSpan.FromMinutes(30)
     };
     repo = new FakeBookingsRepo();
     mgr  = new BookingsManager <Appointment, AppointmentType, AvailabilityItem>(repo, config);
 }
 public MaxPeakTimeBookingLengthRule(IClubConfiguration clubConfiguration, IOptions <BookingConfiguration> options)
 {
     _clubConfiguration    = clubConfiguration;
     _bookingConfiguration = options.Value;
 }
Exemple #5
0
 public MaxBookingLengthRule(IOptions <BookingConfiguration> bookingConfiguration)
 {
     _bookingConfiguration = bookingConfiguration.Value;
 }
Exemple #6
0
 public MaxBookingLengthRule(IOptions <BookingConfiguration> options)
 {
     _bookingConfiguration = options.Value;
 }