View Javadoc
1   /**
2    * Copyright 2004-2014 The Kuali Foundation
3    *
4    * Licensed under the Educational Community License, Version 2.0 (the "License");
5    * you may not use this file except in compliance with the License.
6    * You may obtain a copy of the License at
7    *
8    * http://www.opensource.org/licenses/ecl2.php
9    *
10   * Unless required by applicable law or agreed to in writing, software
11   * distributed under the License is distributed on an "AS IS" BASIS,
12   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13   * See the License for the specific language governing permissions and
14   * limitations under the License.
15   */
16  package org.kuali.kpme.tklm.time.timeblock;
17  
18  import java.util.Date;
19  
20  import org.kuali.kpme.tklm.api.time.timeblock.TimeBlockHistoryDetailContract;
21  import org.kuali.kpme.tklm.time.timehourdetail.TimeHourDetail;
22  import org.kuali.rice.kim.api.identity.Person;
23  
24  public class TimeBlockHistoryDetail extends TimeHourDetail implements TimeBlockHistoryDetailContract {
25  
26  	private static final long serialVersionUID = 1L;
27  	private String tkTimeBlockHistoryDetailId;
28  	private String tkTimeBlockHistoryId;
29  	
30  	private TimeBlockHistory timeBlockHistory;
31  	
32  	private transient Person principal;
33  	private transient Person userPrincipal;
34  
35  	public String getTkTimeBlockHistoryDetailId() {
36  		return tkTimeBlockHistoryDetailId;
37  	}
38  
39  	public void setTkTimeBlockHistoryDetailId(String tkTimeBlockHistoryDetailId) {
40  		this.tkTimeBlockHistoryDetailId = tkTimeBlockHistoryDetailId;
41  	}
42  
43  	public String getTkTimeBlockHistoryId() {
44  		return tkTimeBlockHistoryId;
45  	}
46  
47  	public void setTkTimeBlockHistoryId(String tkTimeBlockHistoryId) {
48  		this.tkTimeBlockHistoryId = tkTimeBlockHistoryId;
49  	}
50  
51  		
52  	public TimeBlockHistoryDetail(TimeHourDetail thd) {
53  		this.setEarnCode(thd.getEarnCode());
54  		this.setAmount(thd.getAmount());
55  		this.setHours(thd.getHours());
56  	}
57  	
58      protected TimeBlockHistoryDetail(TimeBlockHistoryDetail t) {
59          this.tkTimeBlockHistoryDetailId = t.tkTimeBlockHistoryDetailId;
60          this.tkTimeBlockHistoryId = t.tkTimeBlockHistoryId;
61          this.setEarnCode(t.getEarnCode());
62          this.setHours(t.getHours());
63          this.setAmount(t.getAmount());
64      }
65  
66      public TimeBlockHistoryDetail copy() {
67          return new TimeBlockHistoryDetail(this);
68      }
69      public TimeBlockHistoryDetail() {
70      }
71  
72  	public TimeBlockHistory getTimeBlockHistory() {
73  		return timeBlockHistory;
74  	}
75  
76  	public void setTimeBlockHistory(TimeBlockHistory timeBlockHistory) {
77  		this.timeBlockHistory = timeBlockHistory;
78  	}
79  
80  	public Person getPrincipal() {
81  		return principal;
82  	}
83  
84  	public void setPrincipal(Person principal) {
85  		this.principal = principal;
86  	}
87  
88  	public Person getUserPrincipal() {
89  		return userPrincipal;
90  	}
91  
92  	public void setUserPrincipal(Person userPrincipal) {
93  		this.userPrincipal = userPrincipal;
94  	}
95  
96  	public Date getBeginDate() {
97  		return timeBlockHistory.getBeginDate();
98  	}
99  
100 
101 
102 }