public UserController(UserSettings userSettings,
                       IAuthenticationService authenticationService,
                       IUserModelFactory userModelFactory,
                       IUserRegistrationService userRegistrationService,
                       IUserService userService,
                       IEventPublisher eventPublisher,
                       IWebHelper webHelper,
                       IWorkContext workContext,
                       IWorkflowMessageService workflowMessageService,
                       IGenericAttributeService genericAttributeService,
                       IResearcherService researcherService,
                       IAuthenticationService cookieAuthenticationService,
                       IPermissionService permissionService,
                       IScheduleTaskService scheduleTaskService)
 {
     this._userSettings            = userSettings;
     this._authenticationService   = authenticationService;
     this._userModelFactory        = userModelFactory;
     this._userRegistrationService = userRegistrationService;
     this._userService             = userService;
     this._eventPublisher          = eventPublisher;
     this._webHelper                   = webHelper;
     this._workContext                 = workContext;
     this._workflowMessageService      = workflowMessageService;
     this._genericAttributeService     = genericAttributeService;
     this._researcherService           = researcherService;
     this._cookieAuthenticationService = cookieAuthenticationService;
     this._permissionService           = permissionService;
     this._scheduleTaskService         = scheduleTaskService;
 }
Exemple #2
0
 public WebWorkContext(IAuthenticationService authenticationService,
                       IUserService userService,
                       IHttpContextAccessor httpContextAccessor,
                       IUserAgentHelper userAgentHelper,
                       IResearcherService researcherService)
 {
     this._authenticationService = authenticationService;
     this._userService           = userService;
     this._httpContextAccessor   = httpContextAccessor;
     this._userAgentHelper       = userAgentHelper;
     this._researcherService     = researcherService;
 }
Exemple #3
0
 public ResearcherModelFactory(IActionContextAccessor actionContextAccessor,
                               IBaseAdminModelFactory baseAdminModelFactory,
                               IResearcherService researcherService,
                               IUrlHelperFactory urlHelperFactory,
                               IWebHelper webHelper,
                               IUserService userService)
 {
     this._actionContextAccessor = actionContextAccessor;
     this._baseAdminModelFactory = baseAdminModelFactory;
     this._researcherService     = researcherService;
     this._urlHelperFactory      = urlHelperFactory;
     this._webHelper             = webHelper;
     this._userService           = userService;
 }
 public UserRegistrationService(UserSettings userSettings,
                                IUserService userService,
                                IEncryptionService encryptionService,
                                IEventPublisher eventPublisher,
                                IWorkContext workContext,
                                IWorkflowMessageService workflowMessageService,
                                IResearcherService researcherService)
 {
     this._userSettings           = userSettings;
     this._userService            = userService;
     this._encryptionService      = encryptionService;
     this._eventPublisher         = eventPublisher;
     this._workContext            = workContext;
     this._workflowMessageService = workflowMessageService;
     this._researcherService      = researcherService;
 }
 public ResearcherController(IUserActivityService userActivityService,
                             IUserService userService,
                             IPermissionService permissionService,
                             IResearcherModelFactory researcherModelFactory,
                             IResearcherService researcherService,
                             IPictureService pictureService,
                             IAddressService addressService,
                             IAcademicRankService academicRankService,
                             IWorkContext workContext)
 {
     this._userActivityService    = userActivityService;
     this._userService            = userService;
     this._permissionService      = permissionService;
     this._researcherModelFactory = researcherModelFactory;
     this._researcherService      = researcherService;
     this._pictureService         = pictureService;
     this._addressService         = addressService;
     this._academicRankService    = academicRankService;
     this._workContext            = workContext;
 }
Exemple #6
0
 public BaseAdminModelFactory(IFacultyService facultyService,
                              ICountryService countryService,
                              IUserActivityService userActivityService,
                              IUserService userService,
                              IDateTimeHelper dateTimeHelper,
                              IEmailAccountService emailAccountService,
                              IProfessorService professorService,
                              IProvinceService provinceService,
                              IStaticCacheManager cacheManager,
                              IAcademicRankService academicRankService,
                              IResearchIssueService researchIssueService,
                              IAgencyService agencyService,
                              IResearcherService researcherService,
                              IEducationLevelService educationLevelService,
                              IStrategyGroupService strategyGroupService,
                              IFiscalScheduleService fiscalScheduleService,
                              ITitleService titleService,
                              IInstituteService instituteService)
 {
     this._facultyService        = facultyService;
     this._countryService        = countryService;
     this._userActivityService   = userActivityService;
     this._userService           = userService;
     this._dateTimeHelper        = dateTimeHelper;
     this._emailAccountService   = emailAccountService;
     this._professorService      = professorService;
     this._provinceService       = provinceService;
     this._cacheManager          = cacheManager;
     this._academicRankService   = academicRankService;
     this._researchIssueService  = researchIssueService;
     this._agencyService         = agencyService;
     this._researcherService     = researcherService;
     this._educationLevelService = educationLevelService;
     this._strategyGroupService  = strategyGroupService;
     this._fiscalScheduleService = fiscalScheduleService;
     this._titleService          = titleService;
     this._instituteService      = instituteService;
 }
        public ResearcherValidator(IResearcherService researcherService,
                                   IDbContext dbContext)
        {
            //ensure that valid email address is entered if Registered role is checked to avoid registered users with empty email address
            RuleFor(x => x.TitleId)
            .NotEqual(0)
            .WithMessage("ระบุรหัสคำนำชื่อ!");

            RuleFor(x => x.PersonalTypeId)
            .NotEqual(0)
            .WithMessage("ระบุรหัสประเภทบุคลากร!");

            RuleFor(x => x.AgencyId)
            .NotEqual(0)
            .WithMessage("ระบุหน่วยงาน!");

            RuleFor(x => x.AcademicRankId)
            .NotEqual(0)
            .WithMessage("ระบุตำแหน่งทางวิชาการ!");


            RuleFor(x => x.DateOfBirthDay)
            .NotEqual(0)
            .WithMessage("ระบุวันเกิด!");

            RuleFor(x => x.DateOfBirthMonth)
            .NotEqual(0)
            .WithMessage("ระบุเดือนเกิด!");

            RuleFor(x => x.DateOfBirthYear)
            .NotEqual(0)
            .WithMessage("ระบุปีเกิด!");


            SetDatabaseValidationRules <Researcher>(dbContext);
        }
 public ResearchesController(IResearcherService researcherService)
 {
     _researcherService = researcherService;
 }