44: p_pre_payroll_action_id and p_pre_effective_date changed).
45: 03-Nov-2002 Ragovind 115.9 2689226 Added NOCOPY for function get_legislative_parameters.
46: 04-Nov-2003 Puchil 115.10 3228928 Added a new cursor csr_element_num_val to sum all the element values for
47: numeric values and archive individual values for other types of input.
48: >Changed hr_utility.trace to execute conditionally.
49: 19-Apr-2004 bramajey 115.5 3578040 Renamed procedure range_code to
50: archive_payroll_level_data
51: 04-May-2004 bramajey 115.6 3604206 Added code to convert numeric data to
52: canonical using fnd_number.number_to_canonical while archiving.
56: 02-Jul-2004 punmehta 115.9 3731940 Modified for GSCC warnings
57: 12-Dec-2006 aaagarwa 115.10 5048802 Added deinitialization_code
58: 05-Oct-2007 jalin 115.11 6471802 Reset l_element_archived to N in the loop in archive_user_elements procedure
59: 11-Oct-2007 jalin 115.12 6486660 Added NOT null check for l_sum_value in archive_user_elements
60: 15-Oct-2007 jalin 115.13 6486660 Changed calling function pay_in_utils to hr_utility
61:
62: *******************************************************************/
63:
64: /*Global variable to enable trace conditionally*/
162: l_input_value_name pay_input_values_f.name%TYPE;
163:
164:
165: BEGIN
166: g_debug := hr_utility.debug_enabled;
167: IF g_debug THEN
168: hr_utility.trace('Entering procedure get_eit_definitions');
169: END IF;
170:
164:
165: BEGIN
166: g_debug := hr_utility.debug_enabled;
167: IF g_debug THEN
168: hr_utility.trace('Entering procedure get_eit_definitions');
169: END IF;
170:
171: FOR csr_eit_rec IN csr_eit_values(p_business_group_id)
172:
174:
175: l_context := csr_eit_rec.org_information1;
176:
177: IF g_debug THEN
178: hr_utility.trace(' For context : l_context ........:'||l_context);
179: END IF;
180:
181: IF (l_context = pay_apac_payslip_archive.g_balance_context) THEN
182:
204: g_user_balance_table(l_balance_index).balance_narrative:= g_user_balance_table(l_balance_index).balance_name ||' '|| g_user_balance_table(l_balance_index).database_item_suffix;
205: END IF;
206:
207: IF g_debug THEN
208: hr_utility.trace('Archiving the user configured balances.......');
209: END IF;
210:
211: IF p_archive = 'Y' THEN
212:
244:
245: l_element_index := l_element_index + 1;
246:
247: IF g_debug THEN
248: hr_utility.trace(' ......ELEMENT :'||l_element_index);
249: END IF;
250: g_element_table(l_element_index).element_type_id := l_element_type_id;
251: g_element_table(l_element_index).input_value_id := l_input_value_id;
252: g_element_table(l_element_index).element_narrative := l_element_narrative;
285: g_max_user_balance_index := l_balance_index;
286: g_max_user_element_index := l_element_index;
287:
288: IF g_debug THEN
289: hr_utility.trace('Leaving procedure get_eit_definition ');
290: END IF;
291:
292: EXCEPTION
293: WHEN OTHERS THEN
291:
292: EXCEPTION
293: WHEN OTHERS THEN
294: IF g_debug THEN
295: hr_utility.trace('Error occured in get_eit_definitions');
296: END IF;
297: RAISE;
298:
299: END get_eit_definitions;
346: and PACT.effective_date between PIVF.effective_start_date and PIVF.effective_end_date;
347:
348:
349: BEGIN
350: g_debug := hr_utility.debug_enabled;
351: IF g_debug THEN
352: hr_utility.trace('Start of archive user balances');
353: END IF;
354:
348:
349: BEGIN
350: g_debug := hr_utility.debug_enabled;
351: IF g_debug THEN
352: hr_utility.trace('Start of archive user balances');
353: END IF;
354:
355: FOR l_index IN 1 .. pay_apac_payslip_archive.g_max_user_balance_index LOOP
356:
400: END IF;
401:
402: END LOOP;
403: IF g_debug THEN
404: hr_utility.trace(' End of archive user balances');
405: END IF;
406:
407: EXCEPTION
408: WHEN OTHERS THEN
406:
407: EXCEPTION
408: WHEN OTHERS THEN
409: IF g_debug THEN
410: hr_utility.trace('Error occured in archive user balances');
411: END IF;
412: RAISE;
413: END archive_user_balances;
414:
528: l_input_name pay_input_values_f.name%TYPE;
529: l_element_archived VARCHAR2(1);
530:
531: BEGIN
532: g_debug := hr_utility.debug_enabled;
533: l_element_archived := 'N';
534: IF g_debug THEN
535: hr_utility.trace(' Start of archive user elements');
536: END IF;
531: BEGIN
532: g_debug := hr_utility.debug_enabled;
533: l_element_archived := 'N';
534: IF g_debug THEN
535: hr_utility.trace(' Start of archive user elements');
536: END IF;
537:
538: FOR l_index IN 1 .. g_max_user_element_index LOOP
539:
564:
565: IF l_element_archived = 'N' THEN
566:
567: IF g_debug THEN
568: hr_utility.trace(' ...Unit Of Measure is ...:'||l_uom);
569: END IF;
570:
571: IF (l_uom ='M' OR l_uom='H' OR l_uom='I') THEN
572:
643:
644: END LOOP; -- End of 1.. max_user_elements Loop
645:
646: IF g_debug THEN
647: hr_utility.trace(' End of archive user elements');
648: END IF;
649:
650: EXCEPTION
651: WHEN OTHERS THEN
649:
650: EXCEPTION
651: WHEN OTHERS THEN
652: IF g_debug THEN
653: hr_utility.trace('Error occured in archive user elements');
654: END IF;
655: RAISE;
656:
657: END archive_user_elements;
687:
688: BEGIN
689:
690: IF g_debug THEN
691: hr_utility.trace('Start of process_eit');
692: END IF;
693:
694: -- Get the legislative parameters of the archive request.
695:
715: , p_archive => p_archive
716: );
717:
718: IF g_debug THEN
719: hr_utility.trace('End of process_eit');
720: END IF;
721:
722: EXCEPTION
723: WHEN OTHERS THEN
721:
722: EXCEPTION
723: WHEN OTHERS THEN
724: IF g_debug THEN
725: hr_utility.trace('Error occured in process_eit');
726: END IF;
727: RAISE;
728: END process_eit;
729:
778: l_archive VARCHAR2(1) ;
779:
780:
781: BEGIN
782: g_debug := hr_utility.debug_enabled;
783: l_archive := 'Y';
784: IF g_debug THEN
785: hr_utility.trace(' Start of APAC archive Range Code');
786: END IF;
781: BEGIN
782: g_debug := hr_utility.debug_enabled;
783: l_archive := 'Y';
784: IF g_debug THEN
785: hr_utility.trace(' Start of APAC archive Range Code');
786: END IF;
787:
788: -----------------------------------------------------------------------+
789: -- Call to process_eit with p_archive parameter as 'Y' as this will
818: l_payroll_id,
819: l_canonical_end_date);
820:
821: IF g_debug THEN
822: hr_utility.trace('Archiving the Payroll Messages.');
823: END IF;
824:
825: FOR csr_msg_rec IN csr_payroll_msg(l_payroll_id
826: ,l_canonical_start_date
846: END LOOP;
847:
848:
849: IF g_debug THEN
850: hr_utility.trace('End of APAC archive Range Code');
851: END IF;
852:
853: EXCEPTION
854: WHEN OTHERS THEN
852:
853: EXCEPTION
854: WHEN OTHERS THEN
855: IF g_debug THEN
856: hr_utility.trace('Error occured in APAC archive Range Code');
857: END IF;
858: RAISE;
859:
860: END range_code;
874:
875: l_archive VARCHAR2(1);
876:
877: BEGIN
878: g_debug := hr_utility.debug_enabled;
879: l_archive := 'N';
880: IF g_debug THEN
881: hr_utility.trace(' Start of APAC archive Initialization Code');
882: END IF;
877: BEGIN
878: g_debug := hr_utility.debug_enabled;
879: l_archive := 'N';
880: IF g_debug THEN
881: hr_utility.trace(' Start of APAC archive Initialization Code');
882: END IF;
883:
884: -----------------------------------------------------------------------+
885: -- Call to process_eit with p_archive parameter as 'N' as this will
889:
890: process_eit(p_payroll_action_id,l_archive);
891:
892: IF g_debug THEN
893: hr_utility.trace('End of APAC Initliazation Code');
894: END IF;
895:
896: EXCEPTION
897: WHEN OTHERS THEN
895:
896: EXCEPTION
897: WHEN OTHERS THEN
898: IF g_debug THEN
899: hr_utility.trace('Error occured in APAC archive Initialization Code');
900: END IF;
901: RAISE;
902:
903: END initialization_code;
939: FROM pay_payroll_actions ppa
940: WHERE ppa.payroll_action_id = p_payroll_action_id;
941:
942: BEGIN
943: g_debug := hr_utility.debug_enabled;
944: IF g_debug THEN
945: hr_utility.trace('Start of get_legislative_parameters Procedure');
946: END IF;
947:
941:
942: BEGIN
943: g_debug := hr_utility.debug_enabled;
944: IF g_debug THEN
945: hr_utility.trace('Start of get_legislative_parameters Procedure');
946: END IF;
947:
948: OPEN csr_params(p_payroll_action_id);
949: FETCH csr_params INTO p_payroll_id
953: ,p_end_date;
954: CLOSE csr_params;
955:
956: IF g_debug THEN
957: hr_utility.trace('End of get_legislative_parameters Procedure');
958: END IF;
959:
960: EXCEPTION
961: WHEN OTHERS THEN
959:
960: EXCEPTION
961: WHEN OTHERS THEN
962: IF g_debug THEN
963: hr_utility.trace('Error occured in get_legislative_parameters');
964: END IF;
965: RAISE;
966:
967: END get_legislative_parameters; /* End of get_legislative_parameters */
1003: BEGIN
1004: l_procedure := 'pay_apac_payslip_archive.deinitialization_code';
1005:
1006: IF g_debug THEN
1007: hr_utility.set_location(l_procedure, 10);
1008: END IF;
1009: l_count := -1;
1010:
1011: OPEN check_pa_data_existence;
1013: CLOSE check_pa_data_existence;
1014:
1015: IF (g_debug)
1016: THEN
1017: hr_utility.trace('p_payroll_action_id:'||p_payroll_action_id);
1018: hr_utility.trace('l_count:'||l_count);
1019: END IF;
1020:
1021: IF (l_count = -1)
1014:
1015: IF (g_debug)
1016: THEN
1017: hr_utility.trace('p_payroll_action_id:'||p_payroll_action_id);
1018: hr_utility.trace('l_count:'||l_count);
1019: END IF;
1020:
1021: IF (l_count = -1)
1022: THEN
1021: IF (l_count = -1)
1022: THEN
1023: pay_apac_payslip_archive.range_code(p_payroll_action_id => p_payroll_action_id);
1024: IF g_debug THEN
1025: hr_utility.set_location(l_procedure, 20);
1026: END IF;
1027: END IF;
1028:
1029: IF g_debug THEN
1026: END IF;
1027: END IF;
1028:
1029: IF g_debug THEN
1030: hr_utility.set_location(l_procedure, 30);
1031: END IF;
1032:
1033: END deinitialization_code;
1034: