public BaseApiController(IUserService userService, IRoleService roleService) { UserService = userService; RoleService = roleService; }
public HomeController(IEmployeeService empserv, IRoleService roleserv) { employeeService = empserv; roleService = roleserv; }
/// <summary> /// Constructor /// </summary> /// <param name="context"></param> /// <param name="roleService"> </param> /// <param name="categoryNotificationService"> </param> /// <param name="categoryPermissionForRoleService"></param> public CategoryService(IMVCForumContext context, IRoleService roleService, ICategoryNotificationService categoryNotificationService, ICategoryPermissionForRoleService categoryPermissionForRoleService) { _roleService = roleService; _categoryNotificationService = categoryNotificationService; _categoryPermissionForRoleService = categoryPermissionForRoleService; _context = context as MVCForumContext; }
public AccountController(IClientService clientService, IRoleService roleService, IUtilisateurService<Client> utilisateurService, IImageService imageService) { ClientService = clientService; RoleService = roleService; UtilisateurService = utilisateurService; ImageService = imageService; }
public PostService(ISettingsService settingsService, IRoleService roleService, IPostRepository postRepository, ITopicRepository topicRepository) { this._postRepository = postRepository; this._topicRepository = topicRepository; this._roleService = roleService; this._settingsService = settingsService; }
public RolesBasedAuthorizationService(IRoleService roleService, IAuthorizationServiceEventHandler authorizationServiceEventHandler) { _roleService = roleService; _authorizationServiceEventHandler = authorizationServiceEventHandler; Logger = NullLogger.Instance; }
public UserTaskForms( IShapeFactory shapeFactory, IRoleService roleService) { _roleService = roleService; Shape = shapeFactory; T = NullLocalizer.Instance; }
public TagController(ILoggingService loggingService, IUnitOfWorkManager unitOfWorkManager, IMembershipService membershipService, ILocalizationService localizationService, IRoleService roleService, ISettingsService settingsService, ITopicTagService topicTagService, ICategoryService categoryService, ICacheService cacheService) : base(loggingService, unitOfWorkManager, membershipService, localizationService, roleService, settingsService) { _topicTagService = topicTagService; _categoryService = categoryService; _cacheService = cacheService; }
public StatsController(ILoggingService loggingService, IUnitOfWorkManager unitOfWorkManager, IMembershipService membershipService, ILocalizationService localizationService, IRoleService roleService, ISettingsService settingsService, ITopicService topicService, IPostService postService) : base(loggingService, unitOfWorkManager, membershipService, localizationService, roleService, settingsService) { _topicService = topicService; _postService = postService; }
public GuestRoleProvider(IRoleService roleService, IUnitOfWorkFactory unitOfWorkFactory) { using (var uow = unitOfWorkFactory.CreateSystem()) { var role = roleService.GetAll(uow).FirstOrDefault(x => x.SystemRole == SystemRole.Base); if (role != null) { List<Role> roles = role.Roles.SelectRecursive(x => x.Roles).Select(x => x.Item).Distinct().ToList(); roles.Add(role); _roles = new List<Role> { new Role { ChildRoles = new List<ChildRole>(), Name = "GustRole", SystemRole = SystemRole.Base, Permissions = roles .SelectMany(m => m.Permissions) .OrderBy(m => m.FullName) .Select(x => new Permission(){ FullName = x.FullName, AllowRead = x.AllowRead, AllowWrite = x.AllowWrite, AllowCreate = x.AllowCreate, AllowDelete = x.AllowDelete, AllowNavigate = x.AllowNavigate, }).ToList() } }; } } }
public RoleController(IRoleService roleService, IEnumerable<IPermissionProvider> permissionProviders, IRepository<RolePermission> rpRepository) { _roleService = roleService; _permissionProviders = permissionProviders; _rpRepository = rpRepository; }
public MemberController(IMemberService memberService, IUserService userService, IRoleService roleService, ILevelService levelService) { _memberService = memberService; _userService = userService; _roleService = roleService; _levelService = levelService; }
public EmployeController(IEmployeService employeService, IRoleService roleService, IUtilisateurService<Employe> utilisateurService, IImageService imageService) { EmployeService = employeService; RoleService = roleService; UtilisateurService = utilisateurService; ImageService = imageService; }
public void AddUsersToRoles() { var users = Builder<User>.CreateListOfSize(2). TheFirst(1).With(x => x.Login = "******"). TheLast(1).With(x => x.Login = "******").Build(); var roles = Builder<Role>.CreateListOfSize(2). TheFirst(1).With(x => x.RoleName = "User"). TheLast(1).With( x => x.RoleName = "Admin").Build(); _userRepository = Mockery.Stub<IUserRepository>(); _roleRepository = Mockery.Stub<IRoleRepository>(); using (Mockery.Record()) { Expect.Call(_userRepository.GetUserByLogin("A")).Return(users[0]); Expect.Call(_userRepository.GetUserByLogin("B")).Return(users[1]); Expect.Call(_roleRepository.GetRoleByRoleName("User")).Return(roles[0]); Expect.Call(_roleRepository.GetRoleByRoleName("Admin")).Return(roles[1]); } using (Mockery.Playback()) { _roleService = new RoleService(_roleRepository, _userRepository); _roleService.AddUsersToRoles(new[] {"A", "B"}, new[] {"User", "Admin"}); } Assert.AreEqual(users[0].Roles.Count, 2); Assert.AreEqual(users[1].Roles.Count, 2); }
public UserService(IUserRepository userRepository, ISessionManager sesstionService, IRoleService roleService, ISettingService settingService, ISessionManager sessionManager) { _userRepository = userRepository; _roleService = roleService; _sessionManager = sessionManager; _settingService = settingService; }
public WebCoreSecurityServiceBinder(IUserService userService, IRoleService roleService, IUserRolesService userRolesService, IRolePageRestrictionService rolePageRestrictionService) { this.userService = userService; this.roleService = roleService; this.userRolesService = userRolesService; this.rolePageRestrictionService = rolePageRestrictionService; }
public LeadController( ILeadService LeadService, IContactService contactService, IMembershipService membershipService, IRoleService roleService, INoteService noteService, IActivityService activityService, ISaleService saleService, ITaskService taskService, ViewDataHelper viewdataHelper, ICampaignService campaignService, ITagService tagService) { _leadService = LeadService; _contactService = contactService; _membershipService = membershipService; _roleService = roleService; _noteService = noteService; _activityService = activityService; _saleService = saleService; _taskService = taskService; _viewdataHelper = viewdataHelper; _campaignService = campaignService; _tagService = tagService; }
public SnippetsController(ILoggingService loggingService, IUnitOfWorkManager unitOfWorkManager, IMembershipService membershipService, ILocalizationService localizationService, IRoleService roleService, ISettingsService settingsService, IMembershipUserPointsService membershipUserPointsService, ICacheService cacheService) : base(loggingService, unitOfWorkManager, membershipService, localizationService, roleService, settingsService, cacheService) { _membershipUserPointsService = membershipUserPointsService; }
public UsersService( IContentManager contentManager, IOrchardServices orchardServices, IRoleService roleService, IMessageManager messageManager, IScheduledTaskManager taskManager, IRepository<EmailPartRecord> emailRepository, ShellSettings shellSettings, IRepository<UserRolesPartRecord> userRolesRepository, ICacheManager cache, IClock clock, ISignals signals) { _signals = signals; _clock = clock; _cache = cache; _emailRepository = emailRepository; _orchardServices = orchardServices; _contentManager = contentManager; _roleService = roleService; _messageManager = messageManager; _taskManager = taskManager; _shellSettings = shellSettings; _userRolesRepository = userRolesRepository; T = NullLocalizer.Instance; Logger = NullLogger.Instance; }
public SelectRolesForms( IShapeFactory shapeFactory, IRoleService roleService) { _roleService = roleService; Shape = shapeFactory; T = NullLocalizer.Instance; }
public Service(IProcessService processService, ISubProcessService subProcessService, IClassificationService classificationService, IRoleService roleService) { this.subProcessService = subProcessService; this.processService = processService; this.classificationService = classificationService; this.roleService = roleService; }
public CmsPluginServiceBinder(IUserService userService, IRoleService roleService, IUserRolesService userRolesService, IEnquiryService enquiryService) { this.userService = userService; this.roleService = roleService; this.userRolesService = userRolesService; this.enquiryService = enquiryService; }
public DefaultUsersApiOperations(IUsersService users, IUserService user, IRolesService roles, IRoleService role) { Users = users; User = user; Roles = roles; Role = role; }
public UserController(IUnitOfWork uow, IUserService userService, IRoleService roleService, IFormsAuthenticationService formsAuthenticationService) { _uow = uow; _userService = userService; _roleService = roleService; _formsAuthenticationService = formsAuthenticationService; }
public MembersController( IMembershipService membershipService, IRoleService roleService) { _membershipService = membershipService; _roleService = roleService; }
public ToolsController(ILoggingService loggingService, IUnitOfWorkManager unitOfWorkManager, IUserService userService, ISettingsService settingsService, ILocalizationService localizationService, IRoleService roleService) : base(loggingService, unitOfWorkManager, userService, settingsService, localizationService) { }
public AssociateController( IMembershipService membershipService, IMembershipService associateMembershipService, IAssociateService associateService, IDocumentService documentService, IReferenceService referenceService, IEmployeeService employeeService, IProspectService prospectService, IPrincipal user, IClientProjectSharedService clientProjectSharedService, IIndividualService individualService, IRoleService roleService, Admin.Services.IEmailService emailService) : base(membershipService, associateService, user) { this.associateService = associateService; this.documentService = documentService; this.referenceService = referenceService; this.employeeService = employeeService; this.prospectService = prospectService; this.associateMembershipService = associateMembershipService; this.clientProjectSharedService = clientProjectSharedService; this.individualService = individualService; this.roleService = roleService; this.emailService = emailService; }
public GroupController(IRoleService _roleService , IGroupService _groupService ) { roleService = _roleService; groupService = _groupService; }
//public UserController(IUserService userService) //{ // _userService = userService; //} public UserController(IUserService userService, ApplicationSignInManager signInManager, IRoleService roleService, IAuthenticationManager authenticationManager) { _userService = userService; _signInManager = signInManager; _roleService = roleService; _authManager = authenticationManager; }
public FileController(ILoggingService loggingService, IUnitOfWorkManager unitOfWorkManager, IMembershipService membershipService, ILocalizationService localizationService, IRoleService roleService, ISettingsService settingsService, IUploadedFileService uploadedFileService, ICategoryService categoryService, ICacheService cacheService) : base(loggingService, unitOfWorkManager, membershipService, localizationService, roleService, settingsService, cacheService) { _uploadedFileService = uploadedFileService; _categoryService = categoryService; }
public HomeController(IArtistService artistService, ISongService songService, IUserService userService, IRoleService roleService) { this._userService = userService; this._artistService = artistService; this._songService = songService; this._roleService = roleService; }
/// <summary> /// 经纪人管理初始化 /// </summary> /// <param name="clientInfoService">clientInfoService</param> /// <param name="workContext">workContext</param> /// <param name="brokerService">brokerService</param> /// <param name="partnerlistService">partnerlistService</param> /// <param name="recommendagentService">recommendagentService</param> /// <param name="roleService">roleService</param> /// <param name="MessageService">MessageService</param> /// <param name="userService">userService</param> public BrokerInfoController(IClientInfoService clientInfoService, IWorkContext workContext, IBrokerService brokerService, IPartnerListService partnerlistService, IRecommendAgentService recommendagentService, IRoleService roleService, IMessageDetailService MessageService, IUserService userService, IBrokeAccountService brokerAccountService, IEventOrderService eventOrderService, IInviteCodeService inviteCodeService, ILevelService levelService, IAgentBillService agentBillService, IEventService eventService ) { _clientInfoService = clientInfoService; _workContext = workContext; _brokerService = brokerService; _partnerlistService = partnerlistService; _recommendagentService = recommendagentService; _roleService = roleService; _MessageService = MessageService; _userService = userService; _brokerAccountService = brokerAccountService; _eventOrderService = eventOrderService; _inviteCodeService = inviteCodeService; _levelService = levelService; _agentBillService = agentBillService; _eventService = eventService; }
public UserController(IUserService userSvc, IRoleService roleSvc, ITeamService teamSvc) { _userSvc = userSvc; _roleSvc = roleSvc; _teamSvc = teamSvc; }
public AccountController(IUserService service, IRoleService roleService, IActivityService activityService) { this.service = service; this.roleService = roleService; this.activityService = activityService; }
public static Dictionary <Category, PermissionSet> GetPermissionsForTopics(IEnumerable <Topic> topics, IRoleService roleService, MembershipRole usersRole) { // Get all the categories for this topic collection var categories = topics.Select(x => x.Category).Distinct(); // Permissions // loop through the categories and get the permissions var permissions = new Dictionary <Category, PermissionSet>(); foreach (var category in categories) { var permissionSet = roleService.GetPermissions(category, usersRole); permissions.Add(category, permissionSet); } return(permissions); }
public LoginController(ILoginService loginService, IUserService userService, IRoleService roleService) { _loginService = loginService; _userService = userService; _roleService = roleService; }
public UserController(IUserService _UserService, IMenuFunctionService _MenuFunctionService, IUserRoleService _UserRoleService, IRoleService _RoleService, IUserConfigService _UserConfigService) { this._UserService = _UserService; this._MenuFunctionService = _MenuFunctionService; this._UserRoleService = _UserRoleService; this._RoleService = _RoleService; this._UserConfigService = _UserConfigService; }
public SubscriptionTask(IPlanService planService, IUniquePageService uniquepageService, IPageMessageSvc pageMessageSvc, IHelperService helperService, IServicesService serviceSvc, IProviderService Providersvc, ILogAdminService logger, ICompanyService companyService, UserService userService, IRoleService roleService, IEmailSender emailSender, MailSettings mailSettings, IEnrolleeService enrolleeService) { _planService = planService; _uniquePageService = uniquepageService; _pageMessageSvc = pageMessageSvc; _helperSvc = helperService; _serviceSvc = serviceSvc; _providerSvc = Providersvc; _logger = logger; _companySvc = companyService; _userservice = userService; _rolesvc = roleService; _emailSender = emailSender; _mailSettings = mailSettings; _enrolleeService = enrolleeService; }
public UserService(IUserRepository userRepository, IRoleService roleService) { _userRepository = userRepository; _roleService = roleService; }
public CompanyController(ICustomerService CustomerService, IUserService UserService, IRoleService RoleService, IUserRoleService UserRoleService, IFormService FormService, IRoleDetailService RoleDetailService, ICompanyService CompanyService, ICityService CityService, ICountryService CountryService, IStateService StateService) : base(CustomerService, UserService, RoleService, FormService, RoleDetailService, UserRoleService) { this._CompanyService = CompanyService; this._CityService = CityService; this._CountryService = CountryService; this._StateService = StateService; }
public RoleController(IRoleService roleService) { this.roleService = roleService; }
public RoleController(IRoleService roleServices) { _roleServices = roleServices; }
/// <summary> /// Initializes a new instance of the <see cref="RoleController" /> class /// </summary> /// <param name="roleService">The role service which is used to communicate with the logic layer.</param> /// <param name="userService">The user service which is used to communicate with the logic layer.</param> /// <param name="mapper">The mapper which is used to convert the resources to the model to the resource result.</param> public RoleController(IRoleService roleService, IUserService userService, IMapper mapper) { this.roleService = roleService; this.userService = userService; this.mapper = mapper; }
public RoleApiService(IRoleService roleService) { _roleService = roleService; }
public RoleController(IRoleService service) { _service = service; }
public EditModel(IUserService service, IRoleService svcRole) { _service = service; _svcRole = svcRole; }
public AdminController(IUserService userService, IRoleService roleService) { _userService = userService; _roleService = roleService; }
public EffectiveRolesConnectorDriver(INotifier notifier, IRoleService roleService) { _notifier = notifier; _roleService = roleService; T = NullLocalizer.Instance; }
public BaseResourceAuthorizationHandler(IRoleService roleService) { _roleService = roleService; }
public BlogManagerController(IPostService postService, IPostImageService postImageService, IImageService imageService, IPostCategoryService postCategoryService, IUserService userService, IRoleService roleService) { _postService = postService; _postImageService = postImageService; _imageService = imageService; _postCategoryService = postCategoryService; _userService = userService; _roleService = roleService; }
/// <summary> /// 初始化一个<see cref="RoleController"/>类型的实例 /// </summary> /// <param name="service">角色服务</param> /// <param name="queryService">角色查询服务</param> public RoleController(IRoleService service, IQueryRoleService queryService) : base(service) { RoleService = service; QueryRoleService = queryService; }
public PageController(IPageService pageService, IPageSectionService sectionService, IAnalyticsService analyticService, IUserService userService, ILoginService loginService, IRoleService roleService) { _pageService = pageService; _sectionService = sectionService; _analyticService = analyticService; _userService = userService; _loginService = loginService; _roleService = roleService; }
public RolesController(IRoleService roleSvc) { _roleSvc = roleSvc; }
public HomeController(ILoggingService loggingService, IUnitOfWorkManager unitOfWorkManager, IActivityService activityService, IMembershipService membershipService, ITopicService topicService, ILocalizationService localizationService, IRoleService roleService, ISettingsService settingsService, ICategoryService categoryService) : base(loggingService, unitOfWorkManager, membershipService, localizationService, roleService, settingsService) { _topicService = topicService; _categoryService = categoryService; _activityService = activityService; LoggedOnUser = UserIsAuthenticated ? MembershipService.GetUser(Username) : null; UsersRole = LoggedOnUser == null?RoleService.GetRole(AppConstants.GuestRoleName) : LoggedOnUser.Roles.FirstOrDefault(); }
public PermissionController(IRoleService roleService, IPermissionService permissionService) { _roleService = roleService; _permissionService = permissionService; }
public RoleController(IEnumerable <IPermissionProvider> permissionProviders, IRoleService roleService) { _permissionProviders = permissionProviders.OrderBy(p => p.Position); _roleService = roleService; }
public RoleController(IRoleService roleService) { _roleService = roleService; }
public RoleController(IRoleDataService roleDataService, IRoleService roleService) { _roleDataService = roleDataService; _roleService = roleService; }
/// <summary> /// Constructor /// </summary> /// <param name="roleService"></param> /// <param name="membershipService"></param> public RolesController(IRoleService roleService, IMembershipService membershipService) { this.roleService = roleService; this.membershipService = membershipService; }