/// <summary>
 ///
 /// </summary>
 /// <param name="userApp"></param>
 /// <param name="urlHelperFactory"></param>
 /// <param name="context"></param>
 public UsersController(
     IUserApp userApp,
     IUrlHelperFactory urlHelperFactory)
 {
     this.urlHelperFactory = urlHelperFactory;
     this.userApp          = userApp;
 }
Exemple #2
0
 public CorrectExamApp(IExamRecordApp recordApp, IQuestionApp questionApp, IExamPaperApp examPaperApp, IUserApp userApp)
 {
     _recordApp    = recordApp;
     _questionApp  = questionApp;
     _examPaperApp = examPaperApp;
     _userApp      = userApp;
 }
 public HomeController(IExamPaperApp examPaperApp, ICorrectExamApp correctApp, IExamRecordApp recordApp, IUserApp userApp, ILogger <HomeController> logger)
 {
     _examPaperApp = examPaperApp;
     _recordApp    = recordApp;
     _correctApp   = correctApp;
     _userApp      = userApp;
     _log          = logger;
     _users        = _userApp.Query();
 }
Exemple #4
0
 public ExamRecordApp(IExamRecordRepository recordRepository, IExamRecordQuestionRepository questionRecordRepository, IExamRecordSolutionRepository solutionRecordRepository, ISolutionRepository solutionRepository, IQuestionApp questionApp, IExamPaperApp examPaperApp, IUserApp userApp, ILogger <ExamRecordApp> logger)
 {
     _recordRepository         = recordRepository;
     _questionRecordRepository = questionRecordRepository;
     _solutionRecordRepository = solutionRecordRepository;
     _solutionRepository       = solutionRepository;
     _questionApp  = questionApp;
     _examPaperApp = examPaperApp;
     _userApp      = userApp;
     _log          = logger;
 }
Exemple #5
0
 public DocumentXlsxApp(IMapper iMapper,
                        IDocumentXlsxService service,
                        IDocumentXlsxRepository repository,
                        IUserApp userApp,
                        IBus bus)
     : base(iMapper, service)
 {
     _service    = service;
     _repository = repository;
     _userApp    = userApp;
     _bus        = bus;
 }
 public AccountController(
     IUserApp userApp,
     IIdentityServerInteractionService interaction,
     IClientStore clientStore,
     IAuthenticationSchemeProvider schemeProvider,
     IEventService events)
 {
     _userApp        = userApp;
     _interaction    = interaction;
     _clientStore    = clientStore;
     _schemeProvider = schemeProvider;
     _events         = events;
 }
Exemple #7
0
        public static void AccesTokenConfig(IAppBuilder app, IUserApp loginManager, bool createRefreshToken = false)
        {
            /*
             * Permite acesso ao endereço de fornecimento do token de acesso sem precisar de HTTPS (AllowInsecureHttp = tue).
             * Obviamente, num ambiente de produção, o valor deve ser false.
             *
             * Configurar o endereço do fornecimento do token de acesso (TokenEndpointPath).
             * Configurar por quanto tempo um token de acesso será válido (AccessTokenExpireTimeSpan).
             */

            // configurar criação de tokens
            var opcoesConfiguracaoToken = new OAuthAuthorizationServerOptions()
            {
                // AccessTokenFormat = new JwtFormat(jwtOptions.Audience, symmetricKeyIssuerSecurityTokenProvider),
#if DEBUG
                AllowInsecureHttp = true,
#endif
#if !DEBUG
                AllowInsecureHttp = false,
#endif
                TokenEndpointPath = new PathString("/api/token"),

#if DEBUG
                //AccessTokenExpireTimeSpan = TimeSpan.FromHours(4),
                AccessTokenExpireTimeSpan = TimeSpan.FromSeconds(15),
#endif
#if !DEBUG
                AccessTokenExpireTimeSpan = TimeSpan.FromHours(1),
#endif
                // injetar provider com gestor de logins
                Provider = new AccessTokenProvider(loginManager),
            };

            if (createRefreshToken)
            {
                opcoesConfiguracaoToken.RefreshTokenProvider = new RefreshTokenProvider();
            }

            // activar o uso de access tokens
            app.UseOAuthAuthorizationServer(opcoesConfiguracaoToken);
            app.UseOAuthBearerAuthentication(new OAuthBearerAuthenticationOptions());
        }
Exemple #8
0
 public CorpClientService(ICorpClientApp corpClientApp, IUserApp userApp, IEmailManager emailManager)
 {
     this.corpClientApp = corpClientApp;
     this.userApp       = userApp;
     this.emailManager  = emailManager;
 }
 public MvcMenuFilter(IRoleAuthorizeApp roleAuthorizeApp, IConfiguration configuration, IUserApp userApp)
 {
     Configuration     = configuration;
     _roleAuthorizeApp = roleAuthorizeApp;
     _UserApp          = userApp;
 }
Exemple #10
0
 public UserService(IUserApp userApp, ISystemModuleApp systemModuleApp, IEmailManager emailManager)
 {
     this.userApp         = userApp;
     this.systemModuleApp = systemModuleApp;
     this.emailManager    = emailManager;
 }
Exemple #11
0
 // recebe a injecção da class de gestão de acessos
 public AccessTokenProvider(IUserApp UserManager)
 {
     _userManager = UserManager;
 }
Exemple #12
0
 public BestPlanApp(IUserApp userApp, IPlanApp planApp)
 {
     _userApp = userApp;
     _planApp = planApp;
 }
 public UserController(IUserApp userAppService)
 {
     _userAppService = userAppService;
 }
Exemple #14
0
 public AccountController(IUserApp userApp, IRoleApp roleApp)
 {
     _userApp = userApp;
     _roleApp = roleApp;
 }
 public UserController()
 {
     bestPlanApp = ServiceLocator.Current.GetService<IBestPlanApp>();
     userApp = ServiceLocator.Current.GetService<IUserApp>();
 }
 public LoginController(IUserApp IUserApp)
 {
     _userApp = IUserApp;
 }
Exemple #17
0
 public AccountService(IUserApp userApp)
 {
     this.userApp = userApp;
 }
Exemple #18
0
 public UsersController(IUserApp app) : base(app)
 {
 }
Exemple #19
0
 public AccountController(IUserApp user, IHttpContextAccessor accessor)
 {
     _user     = user;
     _accessor = accessor;
 }
 public UserService(IUserApp userApp)
 {
     _userApp = userApp;
 }
Exemple #21
0
 public UserController()
 {
     app = ServiceLocator.Current.GetService<IUserApp>();
 }
Exemple #22
0
        //private readonly IWorkContext _workContext;

        public UserController(IUserApp userApp)
        {
            this._userApp = userApp;
        }
Exemple #23
0
 /// <summary>
 /// Initializes a new instance of the <see cref="TestUserProfileService"/> class.
 /// </summary>
 /// <param name="users">The users.</param>
 /// <param name="logger">The logger.</param>
 public CustomProfileService(ILogger <TestUserProfileService> logger, IUserApp userApp)
 {
     Logger   = logger;
     _userApp = userApp;
 }