DBA Data[Home] [Help]

APPS.SSP_PAD_PKG dependencies on HR_UTILITY

Line 151: hr_utility.trace (l_proc||' p_effective_date = '

147: --
148: procedure check_parameters is
149: begin
150: --
151: hr_utility.trace (l_proc||' p_effective_date = '
152: ||to_char (p_effective_date));
153: --
154: hr_api.mandatory_arg_error (
155: p_api_name => l_proc,

Line 162: hr_utility.set_location (l_proc,1);

158: end check_parameters;
159: --
160: begin
161: --
162: hr_utility.set_location (l_proc,1);
163: --
164: check_parameters;
165: --
166: open csr_PAD_element_details (p_effective_date,c_PAD_Corr_element_name);

Line 170: hr_utility.set_location (l_proc,100);

166: open csr_PAD_element_details (p_effective_date,c_PAD_Corr_element_name);
167: fetch csr_PAD_element_details into g_PAD_Correction_element;
168: close csr_PAD_element_details;
169: --
170: hr_utility.set_location (l_proc,100);
171: --
172: end get_PAD_correction_element;
173: --------------------------------------------------------------------------------
174: procedure get_PAD_element (p_effective_date in date) is

Line 181: hr_utility.trace (l_proc||' p_effective_date = '

177: --
178: procedure check_parameters is
179: begin
180: --
181: hr_utility.trace (l_proc||' p_effective_date = '
182: ||to_char (p_effective_date));
183: --
184: hr_api.mandatory_arg_error (
185: p_api_name => l_proc,

Line 193: hr_utility.set_location (l_proc,1);

189: end check_parameters;
190: --
191: begin
192: --
193: hr_utility.set_location (l_proc,1);
194: --
195: check_parameters;
196: --
197: open csr_PAD_element_details (p_effective_date,c_PAD_element_name);

Line 201: hr_utility.set_location (l_proc,100);

197: open csr_PAD_element_details (p_effective_date,c_PAD_element_name);
198: fetch csr_PAD_element_details into g_PAD_element;
199: close csr_PAD_element_details;
200: --
201: hr_utility.set_location (l_proc,100);
202: --
203: end get_PAD_element;
204: --------------------------------------------------------------------------------
205: function EARLIEST_PPP_START_DATE (p_due_date in date) return date is

Line 279: hr_utility.set_location ('Entering '||l_proc,1);

275: and effective_date = l_effective_date;
276: --
277: begin
278: --
279: hr_utility.set_location ('Entering '||l_proc,1);
280: --
281: l_effective_date := greatest(person.MW, person.date_start);
282: --
283: open csr_average_earnings;

Line 300: hr_utility.set_location ('Leaving '||l_proc,10);

296: end if;
297: --
298: close csr_average_earnings;
299: --
300: hr_utility.set_location ('Leaving '||l_proc,10);
301: --
302: return l_average_earnings;
303: --
304: end average_earnings;

Line 384: hr_utility.trace (l_proc||' p_reason = '||p_reason);

380: procedure check_parameters is
381: --
382: begin
383: --
384: hr_utility.trace (l_proc||' p_reason = '||p_reason);
385: hr_utility.trace (l_proc||' withhold from '||to_char (p_withhold_from));
386: hr_utility.trace (l_proc||' withhold to '||to_char (p_withhold_to));
387: --
388: hr_api.mandatory_arg_error (

Line 385: hr_utility.trace (l_proc||' withhold from '||to_char (p_withhold_from));

381: --
382: begin
383: --
384: hr_utility.trace (l_proc||' p_reason = '||p_reason);
385: hr_utility.trace (l_proc||' withhold from '||to_char (p_withhold_from));
386: hr_utility.trace (l_proc||' withhold to '||to_char (p_withhold_to));
387: --
388: hr_api.mandatory_arg_error (
389: p_api_name => l_proc,

Line 386: hr_utility.trace (l_proc||' withhold to '||to_char (p_withhold_to));

382: begin
383: --
384: hr_utility.trace (l_proc||' p_reason = '||p_reason);
385: hr_utility.trace (l_proc||' withhold from '||to_char (p_withhold_from));
386: hr_utility.trace (l_proc||' withhold to '||to_char (p_withhold_to));
387: --
388: hr_api.mandatory_arg_error (
389: p_api_name => l_proc,
390: p_argument => 'reason',

Line 402: hr_utility.set_location (l_proc,1);

398: end check_parameters;
399: --
400: begin
401: --
402: hr_utility.set_location (l_proc,1);
403: --
404: check_parameters;
405: --
406: l_reason_id := ssp_smp_support_pkg.withholding_reason_id (

Line 427: hr_utility.trace (l_proc||' Stoppage is overridden');

423: p_maternity_id => p_maternity_id,
424: p_user_entered => 'N',
425: p_reason_id => l_reason_id);
426: else
427: hr_utility.trace (l_proc||' Stoppage is overridden');
428: end if;
429: --
430: hr_utility.set_location (l_proc,100);
431: --

Line 430: hr_utility.set_location (l_proc,100);

426: else
427: hr_utility.trace (l_proc||' Stoppage is overridden');
428: end if;
429: --
430: hr_utility.set_location (l_proc,100);
431: --
432: end create_stoppage;
433: --
434: procedure remove_stoppages is

Line 450: hr_utility.set_location (l_proc,1);

446: l_proc varchar2 (72) := g_package||'remove_stoppages';
447: --
448: begin
449: --
450: hr_utility.set_location (l_proc,1);
451: --
452: for each_stoppage in csr_stoppages LOOP
453: ssp_stp_del.del (p_stoppage_id => each_stoppage.stoppage_id,
454: p_object_version_number => l_dummy);

Line 457: hr_utility.set_location (l_proc,100);

453: ssp_stp_del.del (p_stoppage_id => each_stoppage.stoppage_id,
454: p_object_version_number => l_dummy);
455: end loop;
456: --
457: hr_utility.set_location (l_proc,100);
458: --
459: end remove_stoppages;
460: --
461: procedure check_employment_end is

Line 477: hr_utility.set_location (l_proc,1);

473: l_proc varchar2 (72) := g_package||'check_employment_end';
474: --
475: begin
476: --
477: hr_utility.set_location (l_proc,1);
478: --
479: open csr_termination_date;
480: fetch csr_termination_date into l_termination_date;
481: close csr_termination_date;

Line 492: hr_utility.set_location (l_proc,100);

488: create_stoppage (p_withhold_from => person.placement_date,
489: p_reason => 'Not employed on Placement Date');
490: end if;
491: --
492: hr_utility.set_location (l_proc,100);
493: --
494: end check_employment_end;
495: --
496: procedure check_continuity_rule is

Line 518: hr_utility.set_location (l_proc,1);

514: l_proc varchar2 (72) := g_package||'check_continuity_rule';
515: --
516: begin
517: --
518: hr_utility.set_location (l_proc,1);
519: --
520: open period_of_service;
521: fetch period_of_service into l_dummy;
522: --

Line 534: hr_utility.set_location (l_proc,100);

530: end if;
531: --
532: close period_of_service;
533: --
534: hr_utility.set_location (l_proc,100);
535: --
536: end check_continuity_rule;
537: --
538: procedure check_start_date is

Line 547: hr_utility.set_location (l_proc,1);

543: l_PAD_element csr_PAD_element_details%rowtype;
544: --
545: begin
546: --
547: hr_utility.set_location (l_proc,1);
548: --
549: open csr_PAD_element_details (person.placement_date,c_PAD_element_name);
550: fetch csr_PAD_element_details into l_PAD_element;
551: close csr_PAD_element_details;

Line 562: hr_utility.set_location (l_proc,100);

558: p_reason => 'Max PPP Period Exceeded');
559: --
560: end if;
561: --
562: hr_utility.set_location (l_proc,100);
563: --
564: end check_start_date;
565: --
566: procedure check_new_employer is

Line 575: hr_utility.set_location (l_proc,1);

571: l_proc varchar2 (72) := g_package||'check_new_employer';
572: --
573: begin
574: --
575: hr_utility.set_location (l_proc,1);
576: --
577: --
578: -- Stop PAD payment from the start of the week in which the person
579: -- started work for a new employer after the placement of her child.

Line 587: hr_utility.set_location (l_proc,100);

583: (person.start_date_with_new_employer),
584: p_reason => 'Worked for another employer');
585: end if;
586: --
587: hr_utility.set_location (l_proc,100);
588: --
589: end check_new_employer;
590: --
591: procedure check_maternity_allowance is

Line 599: hr_utility.set_location (l_proc,1);

595: l_proc varchar2 (72) := g_package||'check_maternity_allowance';
596: --
597: begin
598: --
599: hr_utility.set_location (l_proc,1);
600: --
601: -- Stop PAD payment from the start of the week in which SMA was first
602: -- paid.
603: --

Line 610: hr_utility.set_location (l_proc,100);

606: (person.start_date_maternity_allowance),
607: p_reason => 'Employee is receiving SMA');
608: end if;
609: --
610: hr_utility.set_location (l_proc,100);
611: --
612: end check_maternity_allowance;
613: --
614: procedure check_death is

Line 630: hr_utility.set_location (l_proc,1);

626: l_death_date date;
627:
628: begin
629: --
630: hr_utility.set_location (l_proc,1);
631: --
632: -- PAD ceases on the Saturday following death
633: --
634: l_death_date := null;

Line 646: hr_utility.set_location (l_proc,100);

642: l_sunday),
643: p_reason => 'Employee died');
644: end if;
645: --
646: hr_utility.set_location (l_proc,100);
647: --
648: end check_death;
649: --
650: procedure check_average_earnings is

Line 661: hr_utility.set_location (l_proc,1);

657: earnings_not_derived exception;
658: --
659: begin
660: --
661: hr_utility.set_location (l_proc,1);
662: --
663: -- If the average earnings figure returned is zero then check that
664: -- no error message was set. Error messages will be set for system-
665: -- generated average earnings when the earnings could not be derived

Line 690: hr_utility.set_location (l_proc,100);

686: create_stoppage (p_withhold_from => person.APP_start_date,
687: p_reason => 'Earnings too low');
688: end if;
689: --
690: hr_utility.set_location (l_proc,100);
691: --
692: exception
693: --
694: when earnings_not_derived then

Line 698: hr_utility.trace (l_proc||' Earnings not derived');

694: when earnings_not_derived then
695: --
696: -- Exit silently from this procedure
697: --
698: hr_utility.trace (l_proc||' Earnings not derived');
699: null;
700: --
701: end check_average_earnings;
702: --

Line 707: hr_utility.trace (l_proc||' p_maternity_id = '

703: procedure check_parameters is
704: --
705: begin
706: --
707: hr_utility.trace (l_proc||' p_maternity_id = '
708: ||to_char (p_maternity_id));
709: --
710: hr_api.mandatory_arg_error (
711: p_api_name => l_proc,

Line 720: hr_utility.set_location (l_proc,1);

716: --
717: begin
718: --
719:
720: hr_utility.set_location (l_proc,1);
721: --
722: check_parameters;
723: --
724: -- Get the details of the woman and her maternity.

Line 735: hr_utility.trace (l_proc||' Person has no maternity record - exiting');

731: if csr_personal_details%notfound
732: then
733: close csr_personal_details;
734: --
735: hr_utility.trace (l_proc||' Person has no maternity record - exiting');
736: --
737: raise no_prima_facia_entitlement;
738: end if;
739: --

Line 745: hr_utility.trace (l_proc||' Person has no APP start date - exiting');

741: --
742: -- If the APP has not started then there is no entitlement to PAD.
743: --
744: if person.APP_start_date is null then
745: hr_utility.trace (l_proc||' Person has no APP start date - exiting');
746: --
747: raise no_prima_facia_entitlement;
748: end if;
749: --

Line 765: hr_utility.trace (l_proc||' Person has not stopped work - exiting');

761: fetch csr_check_if_existing_entries into l_existing_entries;
762: --
763: if csr_check_if_existing_entries%NOTFOUND
764: then
765: hr_utility.trace (l_proc||' Person has not stopped work - exiting');
766: raise no_prima_facia_entitlement;
767: end if;
768: --
769: -- if entries are found then the absence has been deleted and entries remain

Line 783: hr_utility.set_location ('ssp_smp_pkg.entitled_to_PAD',2);

779: --
780: -- Having established a prima facia entitlement to PAD, perform checks which
781: -- may lead to creation of stoppages for particular periods.
782: --
783: hr_utility.set_location ('ssp_smp_pkg.entitled_to_PAD',2);
784: --
785: -- Get the PAD legislative parameters.
786: --
787: get_PAD_element (person.due_date);

Line 824: hr_utility.set_location ('ssp_pad_pkg.entitled_to_PAD',3);

820: p_reason => 'Late absence notification');
821: */
822: end if;
823: --
824: hr_utility.set_location ('ssp_pad_pkg.entitled_to_PAD',3);
825: --
826: -- Check for any work done during the APP.
827: --
828: -- if this is the first absence period in the APP

Line 902: hr_utility.trace (l_proc||' ERROR: Invalid null absence end date');

898: else
899: --
900: -- This is not the last absence in the maternity but it has no end date.
901: --
902: hr_utility.trace (l_proc||' ERROR: Invalid null absence end date');
903: --
904:
905: raise invalid_absence_date;
906: end if;

Line 1085: hr_utility.set_location (l_proc,1);

1081: l_proc varchar2 (72) := g_package||'.remove_stoppages';
1082: --
1083: begin
1084: --
1085: hr_utility.set_location (l_proc,1);
1086: --
1087: for each_stoppage in csr_stoppages LOOP
1088: ssp_stp_del.del (p_stoppage_id => each_stoppage.stoppage_id,
1089: p_object_version_number => l_dummy);

Line 1092: hr_utility.set_location (l_proc,100);

1088: ssp_stp_del.del (p_stoppage_id => each_stoppage.stoppage_id,
1089: p_object_version_number => l_dummy);
1090: end loop;
1091: --
1092: hr_utility.set_location (l_proc,100);
1093: --
1094: end remove_stoppages;
1095: --
1096: begin

Line 1098: hr_utility.set_location('Entering: '||l_proc,10);

1094: end remove_stoppages;
1095: --
1096: begin
1097: --
1098: hr_utility.set_location('Entering: '||l_proc,10);
1099: --
1100: get_PAD_correction_element (person.due_date);
1101: --
1102: -- Check each existing SaP entry in turn against all the potential new ones.

Line 1137: hr_utility.trace (l_proc||' Old entry / Hypo entry time Match with values:');

1133: = hypothetical_entry.week_commencing (entry_number)
1134: and not hypothetical_entry.stopped (entry_number) = 'TRUE'
1135: and ssp_smp_pkg.g_smp_update = 'Y'));
1136: end loop;
1137: hr_utility.trace (l_proc||' Old entry / Hypo entry time Match with values:');
1138: hr_utility.trace (l_proc||' Rate: ' ||old_entry.rate||' / '
1139: ||hypothetical_entry.rate (Entry_number));
1140: hr_utility.trace (l_proc||' Amount: '
1141: ||old_entry.amount||' / '

Line 1138: hr_utility.trace (l_proc||' Rate: ' ||old_entry.rate||' / '

1134: and not hypothetical_entry.stopped (entry_number) = 'TRUE'
1135: and ssp_smp_pkg.g_smp_update = 'Y'));
1136: end loop;
1137: hr_utility.trace (l_proc||' Old entry / Hypo entry time Match with values:');
1138: hr_utility.trace (l_proc||' Rate: ' ||old_entry.rate||' / '
1139: ||hypothetical_entry.rate (Entry_number));
1140: hr_utility.trace (l_proc||' Amount: '
1141: ||old_entry.amount||' / '
1142: ||hypothetical_entry.amount (entry_number));

Line 1140: hr_utility.trace (l_proc||' Amount: '

1136: end loop;
1137: hr_utility.trace (l_proc||' Old entry / Hypo entry time Match with values:');
1138: hr_utility.trace (l_proc||' Rate: ' ||old_entry.rate||' / '
1139: ||hypothetical_entry.rate (Entry_number));
1140: hr_utility.trace (l_proc||' Amount: '
1141: ||old_entry.amount||' / '
1142: ||hypothetical_entry.amount (entry_number));
1143: hr_utility.trace (l_proc||' Recoverable: '
1144: ||old_entry.recoverable_amount||' / '

Line 1143: hr_utility.trace (l_proc||' Recoverable: '

1139: ||hypothetical_entry.rate (Entry_number));
1140: hr_utility.trace (l_proc||' Amount: '
1141: ||old_entry.amount||' / '
1142: ||hypothetical_entry.amount (entry_number));
1143: hr_utility.trace (l_proc||' Recoverable: '
1144: ||old_entry.recoverable_amount||' / '
1145: ||hypothetical_entry.recoverable_amount (entry_number));
1146: hr_utility.trace (l_proc||' Week Comm: '
1147: ||hypothetical_entry.week_commencing (entry_number) );

Line 1146: hr_utility.trace (l_proc||' Week Comm: '

1142: ||hypothetical_entry.amount (entry_number));
1143: hr_utility.trace (l_proc||' Recoverable: '
1144: ||old_entry.recoverable_amount||' / '
1145: ||hypothetical_entry.recoverable_amount (entry_number));
1146: hr_utility.trace (l_proc||' Week Comm: '
1147: ||hypothetical_entry.week_commencing (entry_number) );
1148: --A hypo entry covers the same week as the old one
1149: if old_entry.rate = hypothetical_entry.rate (entry_number)
1150: and old_entry.amount = hypothetical_entry.amount(entry_number)

Line 1158: hr_utility.trace (l_proc||' leave unchanged');

1154: -- the hypo entry has the same values as the old one
1155: -- don't create a correction element.
1156: -- don't create a new entry
1157: hypothetical_entry.dealt_with (entry_number) := 'TRUE';
1158: hr_utility.trace (l_proc||' leave unchanged');
1159: else
1160: if ssp_smp_support_pkg.entry_already_processed
1161: (old_entry.element_entry_id)
1162: then l_ins_corr_ele := TRUE;

Line 1163: hr_utility.trace (l_proc||' processed - correct it');

1159: else
1160: if ssp_smp_support_pkg.entry_already_processed
1161: (old_entry.element_entry_id)
1162: then l_ins_corr_ele := TRUE;
1163: hr_utility.trace (l_proc||' processed - correct it');
1164: else
1165: -- update old entry
1166: hr_utility.trace (l_proc||' unprocessed - update it');
1167: hr_entry_api.update_element_entry (

Line 1166: hr_utility.trace (l_proc||' unprocessed - update it');

1162: then l_ins_corr_ele := TRUE;
1163: hr_utility.trace (l_proc||' processed - correct it');
1164: else
1165: -- update old entry
1166: hr_utility.trace (l_proc||' unprocessed - update it');
1167: hr_entry_api.update_element_entry (
1168: p_dt_update_mode => 'CORRECTION',
1169: p_session_date => old_entry.effective_start_date,
1170: p_element_entry_id => old_entry.element_entry_id,

Line 1189: hr_utility.trace (l_proc||' No Old entry - Hypo entry time Match');

1185: when no_data_found then
1186: -- There was no new entry which exactly matched the old entry.
1187: -- or we are deleting.
1188: entry_number := null;
1189: hr_utility.trace (l_proc||' No Old entry - Hypo entry time Match');
1190: hr_utility.trace (l_proc||' or p_deleting is true');
1191: hr_utility.trace (l_proc||' Old entry values:');
1192: hr_utility.trace (l_proc||' Rate: '||old_entry.rate);
1193: hr_utility.trace (l_proc||' Amount: '||old_entry.amount);

Line 1190: hr_utility.trace (l_proc||' or p_deleting is true');

1186: -- There was no new entry which exactly matched the old entry.
1187: -- or we are deleting.
1188: entry_number := null;
1189: hr_utility.trace (l_proc||' No Old entry - Hypo entry time Match');
1190: hr_utility.trace (l_proc||' or p_deleting is true');
1191: hr_utility.trace (l_proc||' Old entry values:');
1192: hr_utility.trace (l_proc||' Rate: '||old_entry.rate);
1193: hr_utility.trace (l_proc||' Amount: '||old_entry.amount);
1194: hr_utility.trace (l_proc||' Recoverable: '

Line 1191: hr_utility.trace (l_proc||' Old entry values:');

1187: -- or we are deleting.
1188: entry_number := null;
1189: hr_utility.trace (l_proc||' No Old entry - Hypo entry time Match');
1190: hr_utility.trace (l_proc||' or p_deleting is true');
1191: hr_utility.trace (l_proc||' Old entry values:');
1192: hr_utility.trace (l_proc||' Rate: '||old_entry.rate);
1193: hr_utility.trace (l_proc||' Amount: '||old_entry.amount);
1194: hr_utility.trace (l_proc||' Recoverable: '
1195: ||old_entry.recoverable_amount);

Line 1192: hr_utility.trace (l_proc||' Rate: '||old_entry.rate);

1188: entry_number := null;
1189: hr_utility.trace (l_proc||' No Old entry - Hypo entry time Match');
1190: hr_utility.trace (l_proc||' or p_deleting is true');
1191: hr_utility.trace (l_proc||' Old entry values:');
1192: hr_utility.trace (l_proc||' Rate: '||old_entry.rate);
1193: hr_utility.trace (l_proc||' Amount: '||old_entry.amount);
1194: hr_utility.trace (l_proc||' Recoverable: '
1195: ||old_entry.recoverable_amount);
1196: if ssp_smp_support_pkg.entry_already_processed

Line 1193: hr_utility.trace (l_proc||' Amount: '||old_entry.amount);

1189: hr_utility.trace (l_proc||' No Old entry - Hypo entry time Match');
1190: hr_utility.trace (l_proc||' or p_deleting is true');
1191: hr_utility.trace (l_proc||' Old entry values:');
1192: hr_utility.trace (l_proc||' Rate: '||old_entry.rate);
1193: hr_utility.trace (l_proc||' Amount: '||old_entry.amount);
1194: hr_utility.trace (l_proc||' Recoverable: '
1195: ||old_entry.recoverable_amount);
1196: if ssp_smp_support_pkg.entry_already_processed
1197: (old_entry.element_entry_id)

Line 1194: hr_utility.trace (l_proc||' Recoverable: '

1190: hr_utility.trace (l_proc||' or p_deleting is true');
1191: hr_utility.trace (l_proc||' Old entry values:');
1192: hr_utility.trace (l_proc||' Rate: '||old_entry.rate);
1193: hr_utility.trace (l_proc||' Amount: '||old_entry.amount);
1194: hr_utility.trace (l_proc||' Recoverable: '
1195: ||old_entry.recoverable_amount);
1196: if ssp_smp_support_pkg.entry_already_processed
1197: (old_entry.element_entry_id)
1198: then l_ins_corr_ele := TRUE;

Line 1199: hr_utility.trace (l_proc||' Old entry already processed');

1195: ||old_entry.recoverable_amount);
1196: if ssp_smp_support_pkg.entry_already_processed
1197: (old_entry.element_entry_id)
1198: then l_ins_corr_ele := TRUE;
1199: hr_utility.trace (l_proc||' Old entry already processed');
1200: else
1201: hr_utility.trace (l_proc||' Old entry NOT already processed');
1202: --Old entry not already processed so delete it
1203: hr_entry_api.delete_element_entry (

Line 1201: hr_utility.trace (l_proc||' Old entry NOT already processed');

1197: (old_entry.element_entry_id)
1198: then l_ins_corr_ele := TRUE;
1199: hr_utility.trace (l_proc||' Old entry already processed');
1200: else
1201: hr_utility.trace (l_proc||' Old entry NOT already processed');
1202: --Old entry not already processed so delete it
1203: hr_entry_api.delete_element_entry (
1204: p_dt_delete_mode => 'ZAP',
1205: p_session_date => old_entry.effective_start_date,

Line 1214: hr_utility.trace (l_proc ||

1210: then
1211: -- Create a correction element to reverse the old entry. Then create a
1212: -- brand new entry with the correct values.
1213: --
1214: hr_utility.trace (l_proc ||
1215: ' Inserting CORRECTION entry for week commencing ' ||
1216: to_char (old_entry.week_commencing));
1217: hr_utility.trace (l_proc||' Old value / New value:');
1218: if entry_number is null then

Line 1217: hr_utility.trace (l_proc||' Old value / New value:');

1213: --
1214: hr_utility.trace (l_proc ||
1215: ' Inserting CORRECTION entry for week commencing ' ||
1216: to_char (old_entry.week_commencing));
1217: hr_utility.trace (l_proc||' Old value / New value:');
1218: if entry_number is null then
1219: hr_utility.trace (l_proc||' Rate: '
1220: ||old_entry.rate||' / NA');
1221: hr_utility.trace (l_proc||' Amount: '

Line 1219: hr_utility.trace (l_proc||' Rate: '

1215: ' Inserting CORRECTION entry for week commencing ' ||
1216: to_char (old_entry.week_commencing));
1217: hr_utility.trace (l_proc||' Old value / New value:');
1218: if entry_number is null then
1219: hr_utility.trace (l_proc||' Rate: '
1220: ||old_entry.rate||' / NA');
1221: hr_utility.trace (l_proc||' Amount: '
1222: ||old_entry.amount||' / NA');
1223: hr_utility.trace (l_proc||' Recoverable: '

Line 1221: hr_utility.trace (l_proc||' Amount: '

1217: hr_utility.trace (l_proc||' Old value / New value:');
1218: if entry_number is null then
1219: hr_utility.trace (l_proc||' Rate: '
1220: ||old_entry.rate||' / NA');
1221: hr_utility.trace (l_proc||' Amount: '
1222: ||old_entry.amount||' / NA');
1223: hr_utility.trace (l_proc||' Recoverable: '
1224: ||old_entry.recoverable_amount||' / NA');
1225: else

Line 1223: hr_utility.trace (l_proc||' Recoverable: '

1219: hr_utility.trace (l_proc||' Rate: '
1220: ||old_entry.rate||' / NA');
1221: hr_utility.trace (l_proc||' Amount: '
1222: ||old_entry.amount||' / NA');
1223: hr_utility.trace (l_proc||' Recoverable: '
1224: ||old_entry.recoverable_amount||' / NA');
1225: else
1226: hr_utility.trace (l_proc||' Rate: '
1227: ||old_entry.rate||' / '

Line 1226: hr_utility.trace (l_proc||' Rate: '

1222: ||old_entry.amount||' / NA');
1223: hr_utility.trace (l_proc||' Recoverable: '
1224: ||old_entry.recoverable_amount||' / NA');
1225: else
1226: hr_utility.trace (l_proc||' Rate: '
1227: ||old_entry.rate||' / '
1228: ||hypothetical_entry.rate (Entry_number));
1229: hr_utility.trace (l_proc||' Amount: '
1230: ||old_entry.amount||' / '

Line 1229: hr_utility.trace (l_proc||' Amount: '

1225: else
1226: hr_utility.trace (l_proc||' Rate: '
1227: ||old_entry.rate||' / '
1228: ||hypothetical_entry.rate (Entry_number));
1229: hr_utility.trace (l_proc||' Amount: '
1230: ||old_entry.amount||' / '
1231: ||hypothetical_entry.amount (entry_number));
1232: hr_utility.trace (l_proc||' Recoverable: '
1233: ||old_entry.recoverable_amount||' /'

Line 1232: hr_utility.trace (l_proc||' Recoverable: '

1228: ||hypothetical_entry.rate (Entry_number));
1229: hr_utility.trace (l_proc||' Amount: '
1230: ||old_entry.amount||' / '
1231: ||hypothetical_entry.amount (entry_number));
1232: hr_utility.trace (l_proc||' Recoverable: '
1233: ||old_entry.recoverable_amount||' /'
1234: ||hypothetical_entry.recoverable_amount (entry_number));
1235: end if;
1236: --

Line 1286: hr_utility.set_location (l_proc,20);

1282: -- Having been through all the existing entries, we now check that we
1283: -- have dealt with all the newly derived entries by inserting any which
1284: -- were not flagged as dealt with during the above actions.
1285: --
1286: hr_utility.set_location (l_proc,20);
1287: --
1288: <>
1289: begin
1290: if p_deleting then

Line 1291: hr_utility.trace('Deleting an absence so don''t insert entries');

1287: --
1288: <>
1289: begin
1290: if p_deleting then
1291: hr_utility.trace('Deleting an absence so don''t insert entries');
1292: else
1293: for new_entry in 1..g_PAD_element.maximum_PPP LOOP
1294: if (not hypothetical_entry.dealt_with (new_entry) = 'TRUE')
1295: and (not hypothetical_entry.stopped (new_entry) = 'TRUE')

Line 1341: hr_utility.set_location(' Leaving: '||l_proc,100);

1337: if l_no_of_absence_periods = 0 then
1338: remove_stoppages;
1339: end if;
1340: --
1341: hr_utility.set_location(' Leaving: '||l_proc,100);
1342: --
1343: end save_hypothetical_entries;
1344: --
1345: procedure derive_PAD_week (p_week_number in integer) is

Line 1353: hr_utility.set_location ('Entering: ssp_pad_pkg.derive_PAD_week',1);

1349: -- we are and finding the offset from the start date.
1350: --
1351: begin
1352: --
1353: hr_utility.set_location ('Entering: ssp_pad_pkg.derive_PAD_week',1);
1354: hr_utility.trace ('Entry number = '||to_char (p_week_number));
1355: --
1356: hypothetical_entry.week_commencing (p_week_number)
1357: := (person.APP_start_date + ((p_week_number -1) * 7));

Line 1354: hr_utility.trace ('Entry number = '||to_char (p_week_number));

1350: --
1351: begin
1352: --
1353: hr_utility.set_location ('Entering: ssp_pad_pkg.derive_PAD_week',1);
1354: hr_utility.trace ('Entry number = '||to_char (p_week_number));
1355: --
1356: hypothetical_entry.week_commencing (p_week_number)
1357: := (person.APP_start_date + ((p_week_number -1) * 7));
1358: --

Line 1364: hr_utility.trace ('week_commencing = '

1360: hypothetical_entry.stopped (p_week_number) := 'FALSE';
1361: hypothetical_entry.element_link_id (p_week_number) := null;
1362: hypothetical_entry.assignment_id (p_week_number) := null;
1363: --
1364: hr_utility.trace ('week_commencing = '
1365: ||to_char (hypothetical_entry.week_commencing (p_week_number)));
1366: --
1367: hr_utility.set_location ('Leaving : ssp_pad_pkg.derive_PAD_week',100);
1368: --

Line 1367: hr_utility.set_location ('Leaving : ssp_pad_pkg.derive_PAD_week',100);

1363: --
1364: hr_utility.trace ('week_commencing = '
1365: ||to_char (hypothetical_entry.week_commencing (p_week_number)));
1366: --
1367: hr_utility.set_location ('Leaving : ssp_pad_pkg.derive_PAD_week',100);
1368: --
1369: end derive_PAD_week;
1370: --
1371: procedure Check_PAD_stoppages (p_week_number in integer) is

Line 1404: hr_utility.set_location ('ssp_pad_pkg.Check_PAD_stoppages',1);

1400: l_dummy integer (1);
1401: --
1402: begin
1403: --
1404: hr_utility.set_location ('ssp_pad_pkg.Check_PAD_stoppages',1);
1405: --
1406: hypothetical_entry.stopped (p_week_number) := 'FALSE';
1407: --
1408: open csr_stoppages (

Line 1423: hr_utility.trace ('Entry is STOPPED');

1419: -- is payable.
1420: --
1421: hypothetical_entry.stopped (p_week_number) := 'TRUE';
1422: --
1423: hr_utility.trace ('Entry is STOPPED');
1424: --
1425: -- Keep a tally of the number of stopped weeks
1426: --
1427: l_stopped_weeks := l_stopped_weeks +1;

Line 1432: hr_utility.set_location ('ssp_pad_pkg.Check_PAD_stoppages',10);

1428: end if;
1429: --
1430: close csr_stoppages;
1431: --
1432: hr_utility.set_location ('ssp_pad_pkg.Check_PAD_stoppages',10);
1433: --
1434: end Check_PAD_stoppages;
1435: --
1436: procedure Calculate_correct_PAD_rate (p_week_number in number) is

Line 1450: hr_utility.set_location ('ssp_pad_pkg.Calculate_correct_PAD_rate',1);

1446: and lookup_code = p_rate_band;
1447: --
1448: begin
1449: --
1450: hr_utility.set_location ('ssp_pad_pkg.Calculate_correct_PAD_rate',1);
1451: --
1452: if l_high_rate is null then
1453: --
1454: -- Get the meanings for the rate bands

Line 1468: hr_utility.set_location ('ssp_smp_pkg.Calculate_correct_SMP_rate',1);

1464: /*
1465: if (p_week_number - l_stopped_weeks)
1466: <= g_SMP_element.period_at_higher_rate
1467: then
1468: hr_utility.set_location ('ssp_smp_pkg.Calculate_correct_SMP_rate',1);
1469: --
1470: -- We have not yet given the employee all their higher rate weeks
1471: --
1472: */

Line 1480: hr_utility.trace ('PAD Rate = '

1476: hypothetical_entry.rate (p_week_number) := l_low_rate;
1477: end if;
1478: */
1479: --
1480: hr_utility.trace ('PAD Rate = '
1481: ||hypothetical_entry.rate (p_week_number));
1482: --
1483: hr_utility.set_location ('ssp_pad_pkg.Calculate_correct_PAD_rate',10);
1484: --

Line 1483: hr_utility.set_location ('ssp_pad_pkg.Calculate_correct_PAD_rate',10);

1479: --
1480: hr_utility.trace ('PAD Rate = '
1481: ||hypothetical_entry.rate (p_week_number));
1482: --
1483: hr_utility.set_location ('ssp_pad_pkg.Calculate_correct_PAD_rate',10);
1484: --
1485: end Calculate_correct_PAD_rate;
1486: --
1487: procedure Calculate_PAD_amounts (p_week_number in integer, p_APP_start_date in date) is

Line 1491: hr_utility.set_location('Entering: ssp_sAp_pkg.Calculate_SaP_amounts',1);

1487: procedure Calculate_PAD_amounts (p_week_number in integer, p_APP_start_date in date) is
1488: --
1489: begin
1490: --
1491: hr_utility.set_location('Entering: ssp_sAp_pkg.Calculate_SaP_amounts',1);
1492: --
1493: -- Get the PAD element for each week in case the PAD rate has changed
1494: --
1495: get_PAD_element (hypothetical_entry.week_commencing (p_week_number));

Line 1507: hr_utility.trace ('PAD amount = '

1503: hypothetical_entry.recoverable_amount (p_week_number)
1504: := round (hypothetical_entry.amount (p_week_number)
1505: * g_PAD_element.recovery_rate,2);
1506: --
1507: hr_utility.trace ('PAD amount = '
1508: ||to_char (hypothetical_entry.amount (p_week_number)));
1509: hr_utility.trace ('Recoverable amount = '
1510: ||to_char (hypothetical_entry.recoverable_amount (p_week_number)));
1511: --

Line 1509: hr_utility.trace ('Recoverable amount = '

1505: * g_PAD_element.recovery_rate,2);
1506: --
1507: hr_utility.trace ('PAD amount = '
1508: ||to_char (hypothetical_entry.amount (p_week_number)));
1509: hr_utility.trace ('Recoverable amount = '
1510: ||to_char (hypothetical_entry.recoverable_amount (p_week_number)));
1511: --
1512: hr_utility.set_location('Leaving : ssp_pad_pkg.Calculate_PAD_amounts',100);
1513: --

Line 1512: hr_utility.set_location('Leaving : ssp_pad_pkg.Calculate_PAD_amounts',100);

1508: ||to_char (hypothetical_entry.amount (p_week_number)));
1509: hr_utility.trace ('Recoverable amount = '
1510: ||to_char (hypothetical_entry.recoverable_amount (p_week_number)));
1511: --
1512: hr_utility.set_location('Leaving : ssp_pad_pkg.Calculate_PAD_amounts',100);
1513: --
1514: end calculate_PAD_amounts;
1515: --
1516: procedure check_parameters is

Line 1527: hr_utility.set_location ('ssp_pad_pkg.generate_payments',1);

1523: end check_parameters;
1524: --
1525: begin
1526: --
1527: hr_utility.set_location ('ssp_pad_pkg.generate_payments',1);
1528: --
1529: check_parameters;
1530: --
1531: <>

Line 1620: hr_utility.set_location (l_proc,1);

1616: l_proc varchar2 (72) := g_package||'PAD_control';
1617: --
1618: begin
1619: --
1620: hr_utility.set_location (l_proc,1);
1621: --
1622: open csr_maternity;
1623: fetch csr_maternity into l_dummy;
1624:

Line 1648: hr_utility.trace (l_proc||' Deleting element entry_id '||

1644: -- The maternity may have been deleted. Remove any element entries associated
1645: -- with it (the absences, stoppages and medicals are handled by constraints).
1646: --
1647: for obsolete in csr_entries LOOP
1648: hr_utility.trace (l_proc||' Deleting element entry_id '||
1649: to_char (obsolete.element_entry_id));
1650: hr_utility.trace (l_proc||'-------------------------------------------');
1651: --
1652: hr_entry_api.delete_element_entry (

Line 1650: hr_utility.trace (l_proc||'-------------------------------------------');

1646: --
1647: for obsolete in csr_entries LOOP
1648: hr_utility.trace (l_proc||' Deleting element entry_id '||
1649: to_char (obsolete.element_entry_id));
1650: hr_utility.trace (l_proc||'-------------------------------------------');
1651: --
1652: hr_entry_api.delete_element_entry (
1653: p_dt_delete_mode => 'ZAP',
1654: p_session_date => obsolete.effective_start_date,

Line 1659: hr_utility.set_location (l_proc,100);

1655: p_element_entry_id => obsolete.element_entry_id);
1656: end loop;
1657: end if;
1658: --
1659: hr_utility.set_location (l_proc,100);
1660: --
1661: end PAD_control;
1662: --------------------------------------------------------------------------------
1663: end ssp_PAD_pkg;