コード例 #1
0
 public EmployeeService()
 {
     _repository        = ServiceLocator.Resolve <IEmployeeRepository>();
     _validator         = ServiceLocator.Resolve <IEmployeeValidator>();
     _unitOfWork        = ServiceLocator.Resolve <IUnitOfWork>();
     _mailMessageSender = ServiceLocator.Resolve <IMailMessageSender>();
 }
コード例 #2
0
ファイル: frmMain.cs プロジェクト: ppcinj/KanekiBlyat
 public frmMain(IEmployeeFacade employeeFacade, IEmployeeValidator employeeValidator)
 {
     _employeeFacade    = employeeFacade;
     _employeeValidator = employeeValidator;
     InitializeComponent();
     RebuildList();
 }
コード例 #3
0
        public EmployeeService(IEmployeeRepository employeeRepository,
                               IEmployeeValidator employeeValidator,
                               IMapper mapper)
        {
            _employeeRepository = employeeRepository;
            _employeeValidator  = employeeValidator;
            _mapper             = mapper;

            Errors = new List <string>();
        }
コード例 #4
0
        public frmEdit(IEmployeeValidator employeeValidator, Employee employee)
        {
            _employeeValidator = employeeValidator;
            MyEmployee         = employee;
            Action             = EditCloseAction.Discard;

            InitializeComponent();
            tbName.Text     = MyEmployee.Name;
            tbSurname.Text  = MyEmployee.Surname;
            tbWorkdays.Text = MyEmployee.Workdays.ToString();
            tbSalary.Text   = MyEmployee.Salary.ToString(CultureInfo.InvariantCulture);
        }
コード例 #5
0
 public TimeTrackerService(ITimeTrackerSession timeTrackerSession, 
     ITimesheetToViewModelMapper timesheetMapper, 
     IProjectToViewModelMapper projectMapper,
     IViewModelToTimesheetMapper viewModelMapper,
     ITimesheetValidator timesheetValidator,
     IEmployeeValidator employeeValidator)
 {
     _timeTrackerSession = timeTrackerSession;
     _timesheetMapper = timesheetMapper;
     _projectMapper = projectMapper;
     _viewModelMapper = viewModelMapper;
     _timesheetValidator = timesheetValidator;
     _employeeValidator = employeeValidator;
 }
コード例 #6
0
ファイル: EmployeeService.cs プロジェクト: usruk/AttPayroll
 public EmployeeService(IEmployeeRepository _employeeRepository, IEmployeeValidator _employeeValidator)
 {
     _repository = _employeeRepository;
     _validator  = _employeeValidator;
 }
コード例 #7
0
        public WorkSiteValidatorRenewal(IAddressValidatorNoCounty addressValidatorNoCounty, IEmployeeValidator employeeValidator)
            : base(addressValidatorNoCounty)
        {
            RuleFor(w => w.NumEmployees).NotNull();
            RuleFor(w => w.Employees).NotNull().SetCollectionValidator(employeeValidator);

            RuleFor(w => w.Employees.Count).Equal(w => w.NumEmployees.GetValueOrDefault()).When(w => w.Employees != null);
        }
コード例 #8
0
 public PaycheckHandler(IPaycheckService paycheckService, IEmployeeContext employeeContext, IEmployeeValidator employeeValidator)
 {
     _paycheckService   = paycheckService;
     _employeeContext   = employeeContext;
     _employeeValidator = employeeValidator;
 }