54: o_formula_id := l_rec.formula_id;
55: o_effective_start_date := l_rec.effective_start_date;
56: EXCEPTION
57: WHEN formula_missing THEN
58: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
59: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.FORMULA_DETAILS');
60: hr_utility.set_message_token('STEP', '10');
61: hr_utility.raise_error;
62: END formula_details;
55: o_effective_start_date := l_rec.effective_start_date;
56: EXCEPTION
57: WHEN formula_missing THEN
58: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
59: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.FORMULA_DETAILS');
60: hr_utility.set_message_token('STEP', '10');
61: hr_utility.raise_error;
62: END formula_details;
63: --
56: EXCEPTION
57: WHEN formula_missing THEN
58: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
59: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.FORMULA_DETAILS');
60: hr_utility.set_message_token('STEP', '10');
61: hr_utility.raise_error;
62: END formula_details;
63: --
64: --
57: WHEN formula_missing THEN
58: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
59: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.FORMULA_DETAILS');
60: hr_utility.set_message_token('STEP', '10');
61: hr_utility.raise_error;
62: END formula_details;
63: --
64: --
65: -- Service routine to return information on the business group
100: --
101: o_currency_code := l_rec.currency_code;
102: EXCEPTION
103: WHEN bg_missing THEN
104: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
105: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.BUSINESS_GROUP_DETAILS');
106: hr_utility.set_message_token('STEP', '10');
107: hr_utility.raise_error;
108: END business_group_details;
101: o_currency_code := l_rec.currency_code;
102: EXCEPTION
103: WHEN bg_missing THEN
104: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
105: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.BUSINESS_GROUP_DETAILS');
106: hr_utility.set_message_token('STEP', '10');
107: hr_utility.raise_error;
108: END business_group_details;
109: --
102: EXCEPTION
103: WHEN bg_missing THEN
104: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
105: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.BUSINESS_GROUP_DETAILS');
106: hr_utility.set_message_token('STEP', '10');
107: hr_utility.raise_error;
108: END business_group_details;
109: --
110: --
103: WHEN bg_missing THEN
104: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
105: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.BUSINESS_GROUP_DETAILS');
106: hr_utility.set_message_token('STEP', '10');
107: hr_utility.raise_error;
108: END business_group_details;
109: --
110: --
111: -- Computes the employee's notice period
145: --
146: --
147: -- Get the details for the formula.
148: --
149: hr_utility.set_location(c_proc_name, 10);
150: formula_details
151: (p_session_date => p_session_date
152: ,p_formula_name => 'BE_DERIVE_NOTICE_PERIOD'
153: ,o_formula_id => l_formula_id
155: --
156: --
157: -- Get the details for the business group.
158: --
159: hr_utility.set_location(c_proc_name, 15);
160: business_group_details
161: (p_business_group_id => p_business_group_id
162: ,o_currency_code => l_bg_currency_code);
163: --
163: --
164: --
165: -- Prepare to run the formula.
166: --
167: hr_utility.set_location(c_proc_name, 20);
168: ff_exec.init_formula
169: (l_formula_id
170: ,l_effective_start_date
171: ,l_inputs
173: --
174: --
175: -- Setup the inputs to the formula.
176: --
177: hr_utility.set_location(c_proc_name, 30);
178: FOR l_in_cnt IN l_inputs.first..l_inputs.last LOOP
179: IF l_inputs(l_in_cnt).name = 'BE_EMP_SERV_YEARS' THEN
180: l_inputs(l_in_cnt).value := fnd_number.number_to_canonical(p_service_years);
181: ELSIF l_inputs(l_in_cnt).name = 'BE_EMP_SERV_MONTHS' THEN
205: --
206: --
207: -- Run the formula.
208: --
209: hr_utility.set_location(c_proc_name, 40);
210: ff_exec.run_formula
211: (l_inputs
212: ,l_outputs);
213: --
213: --
214: --
215: -- Extract all the outputs.
216: --
217: hr_utility.set_location(c_proc_name, 50);
218: FOR l_out_cnt IN l_outputs.first..l_outputs.last LOOP
219: IF l_outputs(l_out_cnt).name = 'BE_NOTICE_PERIOD' THEN
220: p_notice_period := fnd_number.canonical_to_number(l_outputs(l_out_cnt).value);
221: ELSIF l_outputs(l_out_cnt).name = 'BE_COUNTER_NOTICE' THEN
227: END IF;
228: END LOOP;
229: EXCEPTION
230: WHEN wrong_input_params THEN
231: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
232: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CALCULATE_NOTICE_PERIOD');
233: hr_utility.set_message_token('STEP', '10');
234: hr_utility.raise_error;
235: WHEN wrong_output_params THEN
228: END LOOP;
229: EXCEPTION
230: WHEN wrong_input_params THEN
231: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
232: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CALCULATE_NOTICE_PERIOD');
233: hr_utility.set_message_token('STEP', '10');
234: hr_utility.raise_error;
235: WHEN wrong_output_params THEN
236: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
229: EXCEPTION
230: WHEN wrong_input_params THEN
231: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
232: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CALCULATE_NOTICE_PERIOD');
233: hr_utility.set_message_token('STEP', '10');
234: hr_utility.raise_error;
235: WHEN wrong_output_params THEN
236: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
237: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CALCULATE_NOTICE_PERIOD');
230: WHEN wrong_input_params THEN
231: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
232: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CALCULATE_NOTICE_PERIOD');
233: hr_utility.set_message_token('STEP', '10');
234: hr_utility.raise_error;
235: WHEN wrong_output_params THEN
236: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
237: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CALCULATE_NOTICE_PERIOD');
238: hr_utility.set_message_token('STEP', '20');
232: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CALCULATE_NOTICE_PERIOD');
233: hr_utility.set_message_token('STEP', '10');
234: hr_utility.raise_error;
235: WHEN wrong_output_params THEN
236: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
237: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CALCULATE_NOTICE_PERIOD');
238: hr_utility.set_message_token('STEP', '20');
239: hr_utility.raise_error;
240: END calculate_notice_period;
233: hr_utility.set_message_token('STEP', '10');
234: hr_utility.raise_error;
235: WHEN wrong_output_params THEN
236: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
237: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CALCULATE_NOTICE_PERIOD');
238: hr_utility.set_message_token('STEP', '20');
239: hr_utility.raise_error;
240: END calculate_notice_period;
241: --
234: hr_utility.raise_error;
235: WHEN wrong_output_params THEN
236: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
237: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CALCULATE_NOTICE_PERIOD');
238: hr_utility.set_message_token('STEP', '20');
239: hr_utility.raise_error;
240: END calculate_notice_period;
241: --
242: --
235: WHEN wrong_output_params THEN
236: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
237: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CALCULATE_NOTICE_PERIOD');
238: hr_utility.set_message_token('STEP', '20');
239: hr_utility.raise_error;
240: END calculate_notice_period;
241: --
242: --
243: -- Validates the NI Number.
328: --
329: -- If the format was not correct then raise an error.
330: --
331: IF l_return_value = 'INVALID_ID' THEN
332: hr_utility.set_message(801, l_invalid_mesg);
333: hr_utility.raise_error;
334: END IF;
335: --
336: --
329: -- If the format was not correct then raise an error.
330: --
331: IF l_return_value = 'INVALID_ID' THEN
332: hr_utility.set_message(801, l_invalid_mesg);
333: hr_utility.raise_error;
334: END IF;
335: --
336: --
337: -- Pass back the result.
338: --
339: RETURN l_return_value;
340: EXCEPTION
341: WHEN wrong_input_params THEN
342: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
343: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CHECK_NI');
344: hr_utility.set_message_token('STEP', '10');
345: hr_utility.raise_error;
346: WHEN wrong_output_params THEN
339: RETURN l_return_value;
340: EXCEPTION
341: WHEN wrong_input_params THEN
342: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
343: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CHECK_NI');
344: hr_utility.set_message_token('STEP', '10');
345: hr_utility.raise_error;
346: WHEN wrong_output_params THEN
347: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
340: EXCEPTION
341: WHEN wrong_input_params THEN
342: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
343: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CHECK_NI');
344: hr_utility.set_message_token('STEP', '10');
345: hr_utility.raise_error;
346: WHEN wrong_output_params THEN
347: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
348: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CHECK_NI');
341: WHEN wrong_input_params THEN
342: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
343: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CHECK_NI');
344: hr_utility.set_message_token('STEP', '10');
345: hr_utility.raise_error;
346: WHEN wrong_output_params THEN
347: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
348: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CHECK_NI');
349: hr_utility.set_message_token('STEP', '20');
343: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CHECK_NI');
344: hr_utility.set_message_token('STEP', '10');
345: hr_utility.raise_error;
346: WHEN wrong_output_params THEN
347: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
348: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CHECK_NI');
349: hr_utility.set_message_token('STEP', '20');
350: hr_utility.raise_error;
351: END check_ni;
344: hr_utility.set_message_token('STEP', '10');
345: hr_utility.raise_error;
346: WHEN wrong_output_params THEN
347: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
348: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CHECK_NI');
349: hr_utility.set_message_token('STEP', '20');
350: hr_utility.raise_error;
351: END check_ni;
352: --
345: hr_utility.raise_error;
346: WHEN wrong_output_params THEN
347: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
348: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CHECK_NI');
349: hr_utility.set_message_token('STEP', '20');
350: hr_utility.raise_error;
351: END check_ni;
352: --
353: end be_call_ff_pkg;
346: WHEN wrong_output_params THEN
347: hr_utility.set_message(800,'HR_6153_ALL_PROCEDURE_FAIL');
348: hr_utility.set_message_token('PROCEDURE', 'BE_CALL_FF_PKG.CHECK_NI');
349: hr_utility.set_message_token('STEP', '20');
350: hr_utility.raise_error;
351: END check_ni;
352: --
353: end be_call_ff_pkg;