public ParameterServiceTests()
            {
                var conn = new SqlServerConnection(SiteConfiguration.ConnectionString);

                categoryRepo = new CategoryRepository(conn);
                degreeRepo = new DegreeRepository(conn);
                countryRepo = new CountryRepository(conn);
                roleRepo = new RoleRepository(conn);
                service = new ParameterService(categoryRepo, degreeRepo, countryRepo, roleRepo);
            }
Exemplo n.º 2
0
 public AuthorController(
     ApplicationUserManager userManager,
     ApplicationSignInManager signInManager,
     IArticleService articleService,
     ParameterService paramService)
 {
     this.userManager = userManager;
     this.signInManager = signInManager;
     this.articleService = articleService;
     this.paramService = paramService;
 }
Exemplo n.º 3
0
        public AccountController(
            ApplicationUserManager userManager, 
            ApplicationSignInManager signInManager,
            IAccountService accountService,
            ParameterService paramService) 
        {
            this.accountService = accountService;
            this.userManager = userManager;
            this.signInManager = signInManager;
            this.paramService = paramService;

           // var provider = new DpapiDataProtectionProvider("SciReview");
            var provider = new MachineKeyProtectionProvider();
            userManager.UserTokenProvider = new DataProtectorTokenProvider<AppMember, int>(provider.Create("ASP.NET Identity"))
            as IUserTokenProvider<AppMember, int>;
        }
Exemplo n.º 4
0
 public AdminController(
     ApplicationRoleManager roleManager, 
     ApplicationUserManager userManager,
     AdministrationService adminService,
     IArticleService articleService,
     IContactService contactService,
     IPageService pageService,
     ParameterService paramService)
 {
     this.roleManager = roleManager;
     this.userManager = userManager;
     this.adminService = adminService;
     this.articleService = articleService;
     this.contactService = contactService;
     this.pageService = pageService;
     this.paramService = paramService;
 }