org.kuali.hr.time.timesheet.service
Class TimesheetServiceImpl

java.lang.Object
  extended by org.kuali.hr.time.timesheet.service.TimesheetServiceImpl
All Implemented Interfaces:
TimesheetService

public class TimesheetServiceImpl
extends Object
implements TimesheetService


Constructor Summary
TimesheetServiceImpl()
           
 
Method Summary
 void approveTimesheet(String principalId, TimesheetDocument timesheetDocument)
           
 void approveTimesheet(String principalId, TimesheetDocument timesheetDocument, String action)
           
 void deleteTimesheet(String documentId)
          Delete a timesheet(used for testing only)
 void disapproveTimesheet(String principalId, TimesheetDocument timesheetDocument)
           
 List<TimeBlock> getPrevDocumentTimeBlocks(String principalId, Date payBeginDate)
          Fetch TimeBlocks for previous pay periods
 TimesheetDocument getTimesheetDocument(String documentId)
          For a given document ID, return a fully populated time sheet document.
protected  TimesheetDocument initiateWorkflowDocument(String principalId, Date payBeginDate, Date payEndDate, String documentType, String title)
           
 boolean isSynchronousUser()
          Is user a Clock in/out person or do they manually enter TimeBlocks
 void loadHolidaysOnTimesheet(TimesheetDocument timesheetDocument, String principalId, Date beginDate, Date endDate)
          Load holidays on given timesheet
protected  void loadTimesheetDocumentData(TimesheetDocument tdoc, String principalId, CalendarEntries payCalEntry)
           
 TimesheetDocument openTimesheetDocument(String principalId, CalendarEntries calendarDates)
          Opens the timesheet document for the user at the given payEndDate provided.
 void resetTimeBlock(List<TimeBlock> timeBlocks)
           
 TimeBlock resetWorkedHours(TimeBlock timeBlock)
           
 void routeTimesheet(String action, String principalId, TimesheetDocument timesheetDocument)
           
 void routeTimesheet(String principalId, TimesheetDocument timesheetDocument)
          Route the given timesheet
protected  void timesheetAction(String action, String principalId, TimesheetDocument timesheetDocument)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TimesheetServiceImpl

public TimesheetServiceImpl()
Method Detail

routeTimesheet

public void routeTimesheet(String principalId,
                           TimesheetDocument timesheetDocument)
Description copied from interface: TimesheetService
Route the given timesheet

Specified by:
routeTimesheet in interface TimesheetService

routeTimesheet

public void routeTimesheet(String action,
                           String principalId,
                           TimesheetDocument timesheetDocument)
Specified by:
routeTimesheet in interface TimesheetService

approveTimesheet

public void approveTimesheet(String principalId,
                             TimesheetDocument timesheetDocument)
Specified by:
approveTimesheet in interface TimesheetService

approveTimesheet

public void approveTimesheet(String principalId,
                             TimesheetDocument timesheetDocument,
                             String action)
Specified by:
approveTimesheet in interface TimesheetService

disapproveTimesheet

public void disapproveTimesheet(String principalId,
                                TimesheetDocument timesheetDocument)
Specified by:
disapproveTimesheet in interface TimesheetService

timesheetAction

protected void timesheetAction(String action,
                               String principalId,
                               TimesheetDocument timesheetDocument)

openTimesheetDocument

public TimesheetDocument openTimesheetDocument(String principalId,
                                               CalendarEntries calendarDates)
                                        throws org.kuali.rice.kew.api.exception.WorkflowException
Description copied from interface: TimesheetService
Opens the timesheet document for the user at the given payEndDate provided. If the timesheet does not exist, it is created.

Specified by:
openTimesheetDocument in interface TimesheetService
Returns:
Throws:
org.kuali.rice.kew.api.exception.WorkflowException

loadHolidaysOnTimesheet

public void loadHolidaysOnTimesheet(TimesheetDocument timesheetDocument,
                                    String principalId,
                                    Date beginDate,
                                    Date endDate)
Description copied from interface: TimesheetService
Load holidays on given timesheet

Specified by:
loadHolidaysOnTimesheet in interface TimesheetService

initiateWorkflowDocument

protected TimesheetDocument initiateWorkflowDocument(String principalId,
                                                     Date payBeginDate,
                                                     Date payEndDate,
                                                     String documentType,
                                                     String title)
                                              throws org.kuali.rice.kew.api.exception.WorkflowException
Throws:
org.kuali.rice.kew.api.exception.WorkflowException

getPrevDocumentTimeBlocks

public List<TimeBlock> getPrevDocumentTimeBlocks(String principalId,
                                                 Date payBeginDate)
Description copied from interface: TimesheetService
Fetch TimeBlocks for previous pay periods

Specified by:
getPrevDocumentTimeBlocks in interface TimesheetService
Returns:

getTimesheetDocument

public TimesheetDocument getTimesheetDocument(String documentId)
Description copied from interface: TimesheetService
For a given document ID, return a fully populated time sheet document. Fully populated means: TimeBlocks, Jobs, Assignments

Specified by:
getTimesheetDocument in interface TimesheetService
Returns:

loadTimesheetDocumentData

protected void loadTimesheetDocumentData(TimesheetDocument tdoc,
                                         String principalId,
                                         CalendarEntries payCalEntry)

isSynchronousUser

public boolean isSynchronousUser()
Description copied from interface: TimesheetService
Is user a Clock in/out person or do they manually enter TimeBlocks

Specified by:
isSynchronousUser in interface TimesheetService
Returns:

deleteTimesheet

public void deleteTimesheet(String documentId)
Description copied from interface: TimesheetService
Delete a timesheet(used for testing only)

Specified by:
deleteTimesheet in interface TimesheetService

resetWorkedHours

public TimeBlock resetWorkedHours(TimeBlock timeBlock)

resetTimeBlock

public void resetTimeBlock(List<TimeBlock> timeBlocks)
Specified by:
resetTimeBlock in interface TimesheetService


Copyright © 2004-2012 The Kuali Foundation. All Rights Reserved.