[Home] [Help]
PACKAGE BODY: APPS.PAY_KR_YEA_DON_EFILE_PKG
Source
1 package body pay_kr_yea_don_efile_pkg as
2 /* $Header: pykrydef.pkb 120.1.12010000.1 2008/07/27 23:05:48 appldev ship $ */
3 --
4 -- Constants
5 --
6 c_package constant varchar2(31) := ' pay_kr_yea_don_efile_pkg.';
7 --
8
9 ------------------------------------------------------------------------
10 -- Package initialization section
11 ------------------------------------------------------------------------
12 begin
13 declare
14 l_report_type varchar2(3);
15 --------------------------------------------------------
16 function user_entity_id(p_user_entity_name in varchar2) return number
17 --------------------------------------------------------
18 is
19 l_user_entity_id number;
20 begin
21 select user_entity_id
22 into l_user_entity_id
23 from ff_user_entities
24 where user_entity_name = p_user_entity_name
25 and legislation_code = 'KR'
26 and creator_type = 'X';
27 --
28 return l_user_entity_id;
29 end user_entity_id;
30 begin
31 --
32 g_payroll_action_id := to_number(pay_magtape_generic.get_parameter_value('PAYROLL_ACTION_ID') );
33 g_target_year := to_number(pay_magtape_generic.get_parameter_value('TARGET_YEAR'));
34 g_assignment_set_id := to_number(pay_magtape_generic.get_parameter_value('ASSIGNMENT_SET_ID'));
35 --
36 g_donation_exem_archive := user_entity_id('X_YEA_DONATION_TAX_EXEM');
37 --
38 if g_payroll_action_id is null then
39
40 l_report_type := pay_magtape_generic.get_parameter_value('REPORT_TYPE');
41
42 if l_report_type is null then
43 g_normal_yea := 'N';
44 g_interim_yea := 'I';
45
46 elsif l_report_type = 'N' then
47 g_normal_yea := 'N';
48
49 elsif l_report_type = 'I' then
50 g_interim_yea := 'I';
51
52 elsif l_report_type = 'R' then
53 g_re_yea := 'R';
54
55 elsif l_report_type = 'NI' then
56 g_normal_yea := 'N';
57 g_interim_yea := 'I';
58
59 elsif l_report_type = 'NR' then
60 g_normal_yea := 'N';
61 g_re_yea := 'R';
62
63 end if;
64 end if;
65 --
66 end;
67 end pay_kr_yea_don_efile_pkg;