View Javadoc

1   /**
2    * Copyright 2004-2013 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.hr.lm.leave.approval.service;
17  
18  import java.math.BigDecimal;
19  import java.util.Date;
20  import java.util.List;
21  import java.util.Map;
22  
23  import org.kuali.hr.lm.leaveblock.LeaveBlock;
24  import org.kuali.hr.lm.workflow.LeaveCalendarDocumentHeader;
25  import org.kuali.hr.time.approval.web.ApprovalLeaveSummaryRow;
26  import org.kuali.hr.time.calendar.CalendarEntries;
27  import org.kuali.rice.kew.api.note.Note;
28  
29  public interface LeaveApprovalService {
30  	public List<ApprovalLeaveSummaryRow> getLeaveApprovalSummaryRows(List<String> principalIds, CalendarEntries payCalendarEntries, List<Date> leaveSummaryDates);
31  	
32  	public Map<Date, Map<String, BigDecimal>> getEarnCodeLeaveHours(List<LeaveBlock> leaveBlocks, List<Date> leaveSummaryDates);
33  	
34  	public List<Map<String, Object>> getLeaveApprovalDetailSections(LeaveCalendarDocumentHeader lcdh);
35  	
36  	public Map<Date, Map<String, BigDecimal>> getAccrualCategoryLeaveHours(List<LeaveBlock> leaveBlocks, List<Date> leaveSummaryDates);
37  
38      /**
39       * Used to determine if there are notes on a document
40       * @param documentNumber
41       * @return list of note objects
42       */
43      public List<Note> getNotesForDocument(String documentNumber);
44  
45      public List<String> getUniqueLeavePayGroupsForPrincipalIds(List<String> principalIds);
46  	
47      /*
48       * returns all calendar entries with LeaveCalendarDocument created and can be approved by given principalId
49       */
50      public List<CalendarEntries> getAllLeavePayCalendarEntriesForApprover(String principalId, Date currentDate);
51  
52      /*
53       * remove the employees with no jobs that are eligible for leave from the given list of principal ids
54       * 
55       * @param principalIds
56       * 
57       */
58     public void removeNonLeaveEmployees(List<String> principalIds);
59  
60     /**
61      * Method to create a map that contains the principal's id and corresponding leave calendar document header.
62      *
63      *@param principalIds
64      * @param payBeginDate
65      * @param payEndDate
66      * @return A PrincipalId to LeaveCalendarDocumentHeader mapping.
67      */
68     public Map<String, LeaveCalendarDocumentHeader> getPrincipalDocumentHeader(List<String> principalIds, Date payBeginDate, Date payEndDate);
69     
70     /**
71      * 
72      * @param principalId
73      * @param flsaStatus
74      * @param chkForLeaveEligible
75      * @return
76      */
77     public boolean isActiveAssignmentFoundOnJobFlsaStatus(String principalId, String flsaStatus, boolean chkForLeaveEligible);
78   
79     /**
80      * Method to get a lit of principal ids based on work area list, calendarGroup and dates
81      * @param workAreaList
82      * @param calendarGroup
83      * @param effdt
84      * @param beginDate
85      * @param endDate
86      * @return
87      */		   
88     public List<String> getLeavePrincipalIdsWithSearchCriteria(
89  			List<String> workAreaList, String calendarGroup, java.sql.Date effdt, java.sql.Date beginDate, java.sql.Date endDate);
90  }