예제 #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="UsersController"/> class.
 /// </summary>
 /// <param name="context">The context<see cref="PigeonContext"/>.</param>
 /// <param name="mapper">The mapper<see cref="IMapper"/>.</param>
 /// <param name="appsettings">The appsettings<see cref="IOptions{AppSettings}"/>.</param>
 public UsersController(IWebHostEnvironment environment, IConfiguration configuration, PigeonContext context, IMapper mapper, IOptions <AppSettings> appsettings)
 {
     _environment    = environment;
     _configuration  = configuration;
     _context        = context;
     _mapper         = mapper;
     _appSettings    = appsettings.Value;
     _userRepository = new UserRepository(_context);
     _cityRepository = new CityRepository(_context);
 }
예제 #2
0
        public void TestCleanup()
        {
            if (this.httpTestServer != null)
            {
                this.httpTestServer.Dispose();
            }

            var context = new PigeonContext();
            context.Users.Delete();
            context.UserSessions.Delete();
        }
예제 #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ReportController"/> class.
 /// </summary>
 /// <param name="context">The context<see cref="PigeonContext"/>.</param>
 /// <param name="mapper">The mapper<see cref="IMapper"/>.</param>
 public MessageController(PigeonContext context, IMapper mapper)
 {
     _context = context;
     _mapper  = mapper;
 }
예제 #4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="UsersController"/> class.
 /// </summary>
 /// <param name="context">The context<see cref="PigeonContext"/>.</param>
 /// <param name="mapper">The mapper<see cref="IMapper"/>.</param>
 public GroupController(PigeonContext context, IMapper mapper)
 {
     _context = context;
     _mapper = mapper;
 }
예제 #5
0
 /// <summary>
 /// Initializes a new instance of the <see cref="FriendsController"/> class.
 /// </summary>
 /// <param name="context">The context<see cref="PigeonContext"/>.</param>
 /// <param name="mapper">The mapper<see cref="IMapper"/>.</param>
 public FriendsController(PigeonContext context, IMapper mapper)
 {
     _context = context;
     _mapper  = mapper;
 }
예제 #6
0
 public CityRepository(PigeonContext context)
 {
     _context = context;
 }
예제 #7
0
 public CitiesController(PigeonContext context)
 {
     _context = context;
 }
예제 #8
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ReportController"/> class.
 /// </summary>
 /// <param name="context">The context<see cref="PigeonContext"/>.</param>
 /// <param name="mapper">The mapper<see cref="IMapper"/>.</param>
 public ReportController(PigeonContext context, IMapper mapper)
 {
     _context = context;
     _mapper  = mapper;
 }
예제 #9
0
 public UserRepository(PigeonContext context)
 {
     _context = context;
 }