Exemplo n.º 1
0
 public EmployerAccountsCommand(IEmployersCommand employersCommand, IEmployersQuery employersQuery, ILoginCredentialsCommand loginCredentialsCommand, ILoginCredentialsQuery loginCredentialsQuery, IJobPostersCommand jobPostersCommand, ILinkedInCommand linkedInCommand)
 {
     _employersCommand        = employersCommand;
     _employersQuery          = employersQuery;
     _loginCredentialsCommand = loginCredentialsCommand;
     _loginCredentialsQuery   = loginCredentialsQuery;
     _jobPostersCommand       = jobPostersCommand;
     _linkedInCommand         = linkedInCommand;
 }
Exemplo n.º 2
0
 public static Employer CreateTestEmployer(this IEmployersCommand employersCommand, string emailAddress, string firstName, string lastName, IOrganisation organisation)
 {
     return(employersCommand.CreateTestEmployer(
                emailAddress,
                firstName,
                lastName,
                EmployerSubRole.Employer,
                organisation));
 }
Exemplo n.º 3
0
 public static Employer CreateTestRecruiter(this IEmployersCommand employersCommand, IOrganisation organisation)
 {
     return(employersCommand.CreateTestEmployer(
                string.Format(EmailAddressFormat, 0),
                string.Format(FirstNameFormat, 0),
                string.Format(LastNameFormat, 0),
                EmployerSubRole.Recruiter,
                organisation));
 }
Exemplo n.º 4
0
        private static Employer CreateTestEmployer(this IEmployersCommand employersCommand, string emailAddress, string firstName, string lastName, EmployerSubRole subRole, IOrganisation organisation)
        {
            var employer = new Employer
            {
                IsEnabled    = true,
                IsActivated  = true,
                EmailAddress = new EmailAddress {
                    Address = emailAddress, IsVerified = true
                },
                PhoneNumber = new PhoneNumber {
                    Number = DefaultPhoneNumber, Type = PhoneNumberType.Work
                },
                FirstName    = firstName,
                LastName     = lastName,
                Organisation = organisation,
                SubRole      = subRole,
            };

            employersCommand.CreateEmployer(employer);
            return(employer);
        }