Пример #1
0
        public void CreateLeave(LeaveInputModel input)
        {
            var leaveType = this.leaveTypeFactory.Make(input.LeaveType);
            var employee  = this.repository.FindEmployeeById(input.EmployeeId);
            var leave     = new LeaveEntry(employee, input.StartDate, input.EndDate, leaveType);

            this.repository.InsertLeave(leave);
        }
 public void CreateLeave(LeaveInputModel input)
 {
     var leaveType = this.leaveTypeFactory.Make(input.LeaveType);
     var employee = this.repository.FindEmployeeById(input.EmployeeId);
     var leave = new LeaveEntry(employee, input.StartDate, input.EndDate, leaveType);
     this.repository.InsertLeave(leave);
 }