24: l_proc varchar2(72) := g_package||'set_security_group_id';
25: --
26: begin
27: --
28: hr_utility.set_location('Entering:'|| l_proc, 10);
29: --
30: -- No business group context. Security group is not applicable.
31: --
32: null;
30: -- No business group context. Security group is not applicable.
31: --
32: null;
33: --
34: hr_utility.set_location(' Leaving:'|| l_proc, 20);
35: --
36: end set_security_group_id;
37: --
38: -- ---------------------------------------------------------------------------
59: l_proc varchar2(72) := g_package||'return_legislation_code';
60: --
61: Begin
62: --
63: hr_utility.set_location('Entering:'|| l_proc, 10);
64: --
65: -- Ensure that all the mandatory parameter are not null
66: --
67: hr_api.mandatory_arg_error
77: -- call to this function. Just return the value in the global
78: -- variable.
79: --
80: l_legislation_code := hr_tdg_bus.g_legislation_code;
81: hr_utility.set_location(l_proc, 20);
82: else
83: --
84: -- The ID is different to the last call to this function
85: -- or this is the first call to this function.
94: close csr_leg_code;
95: fnd_message.set_name('PAY','HR_7220_INVALID_PRIMARY_KEY');
96: fnd_message.raise_error;
97: end if;
98: hr_utility.set_location(l_proc,30);
99: --
100: -- Set the global variables so the values are
101: -- available for the next call to this function.
102: --
103: close csr_leg_code;
104: hr_tdg_bus.g_template_data_group_id := p_template_data_group_id;
105: hr_tdg_bus.g_legislation_code := l_legislation_code;
106: end if;
107: hr_utility.set_location(' Leaving:'|| l_proc, 40);
108: return l_legislation_code;
109: end return_legislation_code;
110: --
111: -- ----------------------------------------------------------------------------
193: l_proc varchar2(72) := g_package || 'chk_form_data_group_id';
194: l_api_updating boolean;
195: --
196: Begin
197: hr_utility.set_location('Entering:'||l_proc, 10);
198: --
199: -- Check value has been passed
200: --
201: hr_api.mandatory_arg_error
203: ,p_argument => 'form_data_group_id'
204: ,p_argument_value => p_form_data_group_id
205: );
206: --
207: hr_utility.set_location('Leaving:'||l_proc, 100);
208: End chk_form_data_group_id;
209: --
210: -- ----------------------------------------------------------------------------
211: -- |-------------------------< chk_form_template_id >-------------------------|
219: l_proc varchar2(72) := g_package || 'chk_form_template_id';
220: l_api_updating boolean;
221: --
222: Begin
223: hr_utility.set_location('Entering:'||l_proc, 10);
224: --
225: -- Check value has been passed
226: --
227: hr_api.mandatory_arg_error
229: ,p_argument => 'form_template_id'
230: ,p_argument_value => p_form_template_id
231: );
232: --
233: hr_utility.set_location('Leaving:'||l_proc, 100);
234: End chk_form_template_id;
235: --
236: -- ----------------------------------------------------------------------------
237: -- |---------------------< chk_data_group_and_template >----------------------|
262: l_template_application_id number;
263: l_template_form_id number;
264: --
265: Begin
266: hr_utility.set_location('Entering:'||l_proc, 10);
267: --
268: l_api_updating := hr_tdg_shd.api_updating
269: (p_template_data_group_id => p_template_data_group_id
270: ,p_object_version_number => p_object_version_number
268: l_api_updating := hr_tdg_shd.api_updating
269: (p_template_data_group_id => p_template_data_group_id
270: ,p_object_version_number => p_object_version_number
271: );
272: hr_utility.set_location(l_proc,20);
273: --
274: -- Only proceed with SQL validation if absolutely necessary
275: --
276: if ( ( l_api_updating
279: or nvl(hr_tdg_shd.g_old_rec.form_template_id,hr_api.g_number) <>
280: nvl(p_form_template_id,hr_api.g_number)))
281: or (NOT l_api_updating)) then
282: --
283: hr_utility.set_location(l_proc,30);
284: --
285: -- Check data group and template reference the same form
286: --
287: open csr_form_data_group;
305: fnd_message.raise_error;
306: end if;
307: close csr_form_template;
308: --
309: hr_utility.set_location(l_proc,40);
310: --
311: if nvl(l_data_group_application_id,hr_api.g_number) <>
312: nvl(l_template_application_id,hr_api.g_number)
313: or nvl(l_data_group_form_id,hr_api.g_number) <>
319: end if;
320: --
321: end if;
322: --
323: hr_utility.set_location('Leaving:'||l_proc, 100);
324: End chk_data_group_and_template;
325: --
326: -- ----------------------------------------------------------------------------
327: -- |------------------------------< chk_delete >------------------------------|
332: --
333: l_proc varchar2(72) := g_package||'chk_delete';
334: --
335: Begin
336: hr_utility.set_location('Entering:'||l_proc, 5);
337: --
338: -- No additional validation required
339: --
340: null;
338: -- No additional validation required
339: --
340: null;
341: --
342: hr_utility.set_location(' Leaving:'||l_proc, 10);
343: End chk_delete;
344: --
345: -- ----------------------------------------------------------------------------
346: -- |---------------------------< insert_validate >----------------------------|
351: --
352: l_proc varchar2(72) := g_package||'insert_validate';
353: --
354: Begin
355: hr_utility.set_location('Entering:'||l_proc, 5);
356: --
357: -- Call all supporting business operations
358: -- No business group context. HR_STANDARD_LOOKUPS used for validation.
359: --
375: ,p_form_data_group_id => p_rec.form_data_group_id
376: ,p_form_template_id => p_rec.form_template_id
377: );
378: --
379: hr_utility.set_location(' Leaving:'||l_proc, 10);
380: End insert_validate;
381: --
382: -- ----------------------------------------------------------------------------
383: -- |---------------------------< update_validate >----------------------------|
388: --
389: l_proc varchar2(72) := g_package||'update_validate';
390: --
391: Begin
392: hr_utility.set_location('Entering:'||l_proc, 5);
393: --
394: -- Call all supporting business operations
395: -- No business group context. HR_STANDARD_LOOKUPS used for validation.
396: --
416: ,p_form_data_group_id => p_rec.form_data_group_id
417: ,p_form_template_id => p_rec.form_template_id
418: );
419: --
420: hr_utility.set_location(' Leaving:'||l_proc, 10);
421: End update_validate;
422: --
423: -- ----------------------------------------------------------------------------
424: -- |---------------------------< delete_validate >----------------------------|
429: --
430: l_proc varchar2(72) := g_package||'delete_validate';
431: --
432: Begin
433: hr_utility.set_location('Entering:'||l_proc, 5);
434: --
435: -- Call all supporting business operations
436: --
437: chk_delete
437: chk_delete
438: (p_rec => p_rec
439: );
440: --
441: hr_utility.set_location(' Leaving:'||l_proc, 10);
442: End delete_validate;
443: --
444: end hr_tdg_bus;