/**
  *
  * @param LeaveParameterObject $leaveAssignmentData
  * @return LeaveRequest 
  */
 protected function generateLeaveRequest(LeaveParameterObject $leaveAssignmentData)
 {
     //        $leavePeriodId = null;
     //
     //        $leavePeriod = $this->getLeavePeriodService()->getLeavePeriod(strtotime($leaveAssignmentData->getFromDate()));
     //        if (!is_null($leavePeriod) && ($leavePeriod instanceof LeavePeriod)) {
     //            $leavePeriodId = $leavePeriod->getLeavePeriodId();
     //        }
     $leaveRequest = new LeaveRequest();
     $leaveRequest->setLeaveTypeId($leaveAssignmentData->getLeaveType());
     $leaveRequest->setDateApplied($leaveAssignmentData->getFromDate());
     //        $leaveRequest->setLeavePeriodId($leavePeriodId);
     $leaveRequest->setEmpNumber($leaveAssignmentData->getEmployeeNumber());
     $leaveRequest->setComments($leaveAssignmentData->getComment());
     return $leaveRequest;
 }
 private function _getLeaveRequestData()
 {
     $leaveRequest = new LeaveRequest();
     $leaveRequest->setLeaveTypeId(1);
     $leaveRequest->setDateApplied('2010-09-01');
     $leaveRequest->setEmpNumber(1);
     $leaveRequest->setComments("Testing comment i add");
     $leave1 = new Leave();
     $leave1->setLengthHours(8);
     $leave1->setLengthDays(1);
     $leave1->setDate('2010-12-01');
     $leave1->setStatus(1);
     $leave2 = new Leave();
     $leave2->setLengthHours(6);
     $leave2->setLengthDays(0.75);
     $leave2->setDate('2010-12-02');
     $leave2->setStatus(1);
     return array($leaveRequest, array($leave1, $leave2));
 }