[Home] [Help]
PACKAGE BODY: APPS.HR_CAGR_CONCURRENT_PROCESS
Source
1 package body hr_cagr_concurrent_process as
2 /* $Header: pecgrcon.pkb 115.7 2002/12/04 10:53:44 pkakar noship $ */
3
4 procedure cagr_concurrent (errbuf out nocopy varchar2
5 ,retcode out nocopy number
6 ,p_effective_date in varchar2
7 ,p_business_group_id in number
8 ,p_apply_results in varchar2
9 ,p_operation_mode in varchar2
10 ,p_validate in varchar2
11 ,p_assignment_id in number
12 ,p_collective_agreement_id in number
13 ,p_entitlement_item_id in number) is
14
15 l_cagr_request_id number := null;
16 l_apply_results varchar2(10);
17 l_effective_date date := fnd_date.canonical_to_date(p_effective_date);
18
19 BEGIN
20
21 errbuf := null;
22 retcode := 0;
23
24 if p_apply_results IN ('Y','B') then
25 -- from cagr_process_mode lookup:
26 -- 'B' is eval + apply (both)
27 -- 'N' is apply only
28 -- 'Y' is eval only
29
30 if p_apply_results = 'B' then
31 -- eval + apply (beneficial result)
32 l_apply_results := 'Y';
33 else
34 -- eval only (do not apply).
35 l_apply_results := 'N';
36 end if;
37
38 per_cagr_evaluation_pkg.initialise
39 (p_process_date => l_effective_date
40 ,p_operation_mode => p_operation_mode
41 ,p_business_group_id => p_business_group_id
42 ,p_assignment_id => p_assignment_id
43 ,p_collective_agreement_id => p_collective_agreement_id
44 ,p_entitlement_item_id => p_entitlement_item_id
45 ,p_commit_flag => p_validate
46 ,p_apply_results_flag => l_apply_results
47 ,p_cagr_request_id => l_cagr_request_id);
48
49 elsif p_apply_results = 'N' then
50
51 per_cagr_apply_results_pkg.initialise
52 (p_process_date => l_effective_date
53 ,p_operation_mode => p_operation_mode
54 ,p_business_group_id => p_business_group_id
55 ,p_assignment_id => p_assignment_id
56 ,p_collective_agreement_id => p_collective_agreement_id
57 ,p_select_flag => 'B' -- Apply beneficial value, not chosen value
58 ,p_commit_flag => p_validate
59 ,p_cagr_request_id => l_cagr_request_id);
60
61 end if;
62
63
64 end cagr_concurrent;
65
66 end hr_cagr_concurrent_process;