1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.kuali.hr.time.timecollection.rule.service;
17
18 import org.apache.commons.lang.StringUtils;
19 import org.kuali.hr.time.collection.rule.TimeCollectionRule;
20 import org.kuali.hr.time.timecollection.rule.dao.TimeCollectionRuleDaoService;
21
22 import java.sql.Date;
23 import java.util.List;
24
25 public class TimeCollectionRuleServiceImpl implements TimeCollectionRuleService{
26 private TimeCollectionRuleDaoService timeCollectRuleDao;
27
28 @Override
29 public TimeCollectionRule getTimeCollectionRule(String dept, Long workArea, String payType, Date asOfDate){
30 return timeCollectRuleDao.getTimeCollectionRule(dept, workArea, payType, asOfDate);
31 }
32
33 @Override
34 public TimeCollectionRule getTimeCollectionRule(String dept, Long workArea,Date asOfDate){
35 return timeCollectRuleDao.getTimeCollectionRule(dept, workArea, asOfDate);
36 }
37
38 public TimeCollectionRuleDaoService getTimeCollectRuleDao() {
39 return timeCollectRuleDao;
40 }
41
42 public void setTimeCollectRuleDao(
43 TimeCollectionRuleDaoService timeCollectRuleDao) {
44 this.timeCollectRuleDao = timeCollectRuleDao;
45 }
46
47 @Override
48 public TimeCollectionRule getTimeCollectionRule(String tkTimeCollectionRuleId) {
49 return timeCollectRuleDao.getTimeCollectionRule(tkTimeCollectionRuleId);
50 }
51
52 @Override
53 public List<TimeCollectionRule> getTimeCollectionRules(String dept, String workArea, String payType, String active, String showHistory) {
54 Long workAreaToSearch = StringUtils.isEmpty(workArea) ? null : Long.parseLong(workArea);
55 return timeCollectRuleDao.getTimeCollectionRules(dept, workAreaToSearch , payType, active, showHistory);
56 }
57 }