1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.kuali.hr.time.timeblock.service;
17
18 import org.kuali.hr.time.assignment.Assignment;
19 import org.kuali.hr.time.timeblock.TimeBlock;
20 import org.kuali.hr.time.timeblock.TimeBlockHistory;
21 import org.kuali.hr.time.timesheet.TimesheetDocument;
22
23 import java.math.BigDecimal;
24 import java.sql.Date;
25 import java.sql.Timestamp;
26 import java.util.List;
27
28 public interface TimeBlockService {
29
30
31
32
33
34 public TimeBlock getTimeBlock(String timeBlockId);
35
36
37
38
39
40 public void deleteTimeBlock(TimeBlock timeBlock);
41
42
43
44
45
46
47
48
49
50
51
52
53
54 public List<TimeBlock> buildTimeBlocks(Assignment assignment, String earnCode, TimesheetDocument timesheetDocument,
55 Timestamp beginTimestamp, Timestamp endTimestamp, BigDecimal hours, BigDecimal amount,
56 Boolean isClockLogCreated, Boolean isLunchDeleted);
57
58
59
60
61
62
63 public void saveTimeBlocks(List<TimeBlock> oldTimeBlocks, List<TimeBlock> newTimeBlocks);
64
65
66
67
68
69 public void saveTimeBlocks(List<TimeBlock> tbList);
70
71
72
73
74 public void resetTimeHourDetail(List<TimeBlock> origTimeBlocks);
75
76
77
78
79
80 public List<TimeBlock> getTimeBlocks(String documentId);
81
82
83
84
85
86 public List<TimeBlock> getTimeBlocksForAssignment(Assignment assign);
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101 public List<TimeBlock> buildTimeBlocksSpanDates(Assignment assignment, String earnCode, TimesheetDocument timesheetDocument,
102 Timestamp beginTimestamp, Timestamp endTimestamp, BigDecimal hours, BigDecimal amount,
103 Boolean isClockLogCreated, Boolean isLunchDeleted, String spanningWeeks);
104
105
106
107
108
109
110
111
112
113
114
115
116
117 public TimeBlock createTimeBlock(TimesheetDocument timesheetDocument, Timestamp beginTime, Timestamp endTime,
118 Assignment assignment, String earnCode, BigDecimal hours, BigDecimal amount,
119 Boolean isClockLogCreated, Boolean isLunchDeleted);
120
121 public void deleteTimeBlocksAssociatedWithDocumentId(String documentId);
122
123 public Boolean isTimeBlockEditable(TimeBlock tb);
124
125
126
127
128
129
130 public List<TimeBlock> getTimeBlocksForClockLogEndId(String tkClockLogId);
131
132
133
134
135
136 public List<TimeBlock> getTimeBlocksForClockLogBeginId(String tkClockLogId);
137
138 public List<TimeBlock> getTimeBlocks();
139 public List<TimeBlock> getLatestEndTimestamp();
140
141
142
143
144
145
146 public List<TimeBlock> getOvernightTimeBlocks(String clockLogEndId);
147
148 public void updateTimeBlock(TimeBlock tb);
149
150 public List<TimeBlockHistory> createTimeBlockHistories(TimeBlock tb, String actionHistory);
151
152 void deleteLunchDeduction(String tkTimeHourDetailId);
153
154
155
156
157
158
159 public List<TimeBlock> getTimeBlocksWithEarnCode(String earnCode, Date effDate);
160 }