A read-only weekly (or other period) view of a worker's logged hours, built by TimesheetManager. Combines the worker's timesheet entries for the period with their assigned tasks and leads, any free text labels used in the preceding two weeks, and any caller-supplied standard items, so the grid shows every relevant work item even for days with no hours logged. Rows are the work items and columns are the days in the period; use getHours to read the hours logged for a given day and item.


Properties

PropertyReturnsDescription
daysList<Date>The days covered by this timesheet, sorted in ascending order, including days with no hours logged.
entriesList<TimesheetEntry>The raw timesheet entries this view was built from.
finishDateDateThe latest day covered by this timesheet.
startDateDateThe earliest day covered by this timesheet.
workItemsList<Object>The work items shown as rows in this timesheet: a mix of Task, Lead and free text label entries, sorted with tasks first, then leads, then labels.

Methods

getDays()

Returns: List<Date>

The days covered by this timesheet, sorted in ascending order, including days with no hours logged.

getWorkItems()

Returns: List<Object>

The work items shown as rows in this timesheet: a mix of Task, Lead and free text label entries, sorted with tasks first, then leads, then labels.

getEntries()

Returns: List<TimesheetEntry>

The raw timesheet entries this view was built from.

getHours(Date day, Object item)

Returns: Double

The hours logged for the given day against the given work item.

ParameterDescription
daythe day to look up, matched against the start of that day
itemthe work item to look up, as returned by getWorkItems

addItems(Iterable<String> items)

Returns: void

Adds free text labels as extra work item rows, skipping any label already present.

ParameterDescription
itemsthe labels to add as work items

getStartDate()

Returns: Date

The earliest day covered by this timesheet.

getFinishDate()

Returns: Date

The latest day covered by this timesheet.

To get full access to the Kademi Hub existing customers can login here, or new customers can register here.