[Home] [Help]
PACKAGE BODY: APPS.HR_ITP_BUS
Source
1 Package Body hr_itp_bus as
2 /* $Header: hritprhi.pkb 115.11 2003/12/03 07:01:45 adhunter noship $ */
3 --
4 -- ----------------------------------------------------------------------------
5 -- | Private Global Definitions |
6 -- ----------------------------------------------------------------------------
7 --
8 g_package varchar2(33) := ' hr_itp_bus.'; -- Global package name
9 --
10 -- The following two global variables are only to be used by the
11 -- return_legislation_code function.
12 --
13 g_legislation_code varchar2(150) default null;
14 g_item_property_id number default null;
15 --
16 -- The following three global variables are only to be used by the
17 -- return_item_type function.
18 --
19 g_item_type varchar2(30) default null;
20 g_form_item_id number default null;
21 g_template_item_id number default null;
22 g_template_item_context_id number default null;
23 --
24 -- ---------------------------------------------------------------------------
25 -- |----------------------< set_security_group_id >--------------------------|
26 -- ---------------------------------------------------------------------------
27 --
28 Procedure set_security_group_id
29 (p_item_property_id in number
30 ) is
31 --
32 l_proc varchar2(72) := g_package||'set_security_group_id';
33 --
34 begin
35 --
36 hr_utility.set_location('Entering:'|| l_proc, 10);
37 --
38 -- No business group context. Security group is not applicable.
39 --
40 null;
41 --
42 hr_utility.set_location(' Leaving:'|| l_proc, 20);
43 --
44 end set_security_group_id;
45 --
46 -- ---------------------------------------------------------------------------
47 -- |---------------------< return_legislation_code >-------------------------|
48 -- ---------------------------------------------------------------------------
49 --
50 Function return_legislation_code
51 (p_item_property_id in number
52 )
53 Return Varchar2 Is
54 --
55 -- Declare cursor
56 --
57 cursor csr_leg_code is
58 select tmp.legislation_code
59 from hr_form_templates_b tmp
60 ,hr_template_items_b tim
61 ,hr_item_properties_b itp
62 where tmp.form_template_id = tim.form_template_id
63 and tim.template_item_id = itp.template_item_id
64 and itp.item_property_id = p_item_property_id
65 union
66 select tmp.legislation_code
67 from hr_form_templates_b tmp
68 ,hr_template_items_b tim
69 ,hr_template_item_contexts_b tic
70 ,hr_item_properties_b itp
71 where tmp.form_template_id = tim.form_template_id
72 and tim.template_item_id = tic.template_item_id
73 and tic.template_item_context_id = itp.template_item_context_id
74 and itp.item_property_id = p_item_property_id;
75 --
76 -- Declare local variables
77 --
78 l_legislation_code varchar2(150);
79 l_proc varchar2(72) := g_package||'return_legislation_code';
80 --
81 Begin
82 --
83 hr_utility.set_location('Entering:'|| l_proc, 10);
84 --
85 -- Ensure that all the mandatory parameter are not null
86 --
87 hr_api.mandatory_arg_error
88 (p_api_name => l_proc
89 ,p_argument => 'item_property_id'
90 ,p_argument_value => p_item_property_id
91 );
92 --
93 if ( nvl(hr_itp_bus.g_item_property_id, hr_api.g_number)
94 = p_item_property_id) then
95 --
96 -- The legislation code has already been found with a previous
97 -- call to this function. Just return the value in the global
98 -- variable.
99 --
100 l_legislation_code := hr_itp_bus.g_legislation_code;
101 hr_utility.set_location(l_proc, 20);
102 else
103 --
104 -- The ID is different to the last call to this function
105 -- or this is the first call to this function.
106 --
107 open csr_leg_code;
108 fetch csr_leg_code into l_legislation_code;
109 --
110 if csr_leg_code%notfound then
111 --
112 -- Legislation code not found, which may be correct for certain item
113 -- properties.
114 --
115 l_legislation_code := null;
116 end if;
117 hr_utility.set_location(l_proc,30);
118 --
119 -- Set the global variables so the values are
120 -- available for the next call to this function.
121 --
122 close csr_leg_code;
123 hr_itp_bus.g_item_property_id := p_item_property_id;
124 hr_itp_bus.g_legislation_code := l_legislation_code;
125 end if;
126 hr_utility.set_location(' Leaving:'|| l_proc, 40);
127 return l_legislation_code;
128 end return_legislation_code;
129 --
130 --
131 -- ----------------------------------------------------------------------------
132 -- |--------------------< chk_prev_and_next_nav_item >------------------------|
133 -- ----------------------------------------------------------------------------
134 Procedure chk_prev_and_next_nav_item
135 (p_effective_date in date
136 ,p_item_property_id in number
137 ,p_form_item_id in number
138 ,p_template_item_id in number
139 ,p_template_item_context_id in number
140 ,p_previous_navigation_item_id in number
141 ,p_next_navigation_item_id in number
142 ) is
143 --
144 l_proc varchar2(72) := g_package || 'chk_prev_and_next_nav_item';
145 --
146 CURSOR cur_form
147 IS
148 SELECT form_id
149 FROM hr_form_items_b
150 WHERE form_item_id = p_form_item_id
151 AND p_form_item_id is not null
152 AND p_template_item_id is null
153 AND p_template_item_context_id is null
154 UNION
155 SELECT form_id
156 FROM hr_template_items_b hti
157 , hr_form_items_b hfi
158 WHERE hti.template_item_id = p_template_item_id
159 AND hti.form_item_id = hfi.form_item_id
160 AND p_template_item_id is not null
161 AND p_form_item_id is null
162 AND p_template_item_context_id is null
163 UNION
164 SELECT form_id
165 FROM hr_template_item_contexts_b tic
166 , hr_template_items_b hti
167 , hr_form_items_b hfi
168 WHERE tic.template_item_context_id = p_template_item_context_id
169 AND hti.template_item_id = tic.template_item_id
170 AND hti.form_item_id = hfi.form_item_id
171 AND p_template_item_context_id is not null
172 AND p_template_item_id is null
173 AND p_form_item_id is null;
174
175 CURSOR cur_item(l_item_id number)
176 IS
177 SELECT form_id
178 FROM hr_form_items_b
179 WHERE form_item_id = l_item_id;
180
181 l_form_id number(15);
182 l_prev_form_id number(15);
183 l_next_form_id number(15);
184 Begin
185 hr_utility.set_location('Entering:'||l_proc, 10);
186
187 IF (p_item_property_id is not null
188 and ((p_previous_navigation_item_id is not null and
189 (nvl(hr_itp_shd.g_old_rec.previous_navigation_item_id,hr_api.g_number)
190 <> nvl(p_previous_navigation_item_id,hr_api.g_number)))
191 or (p_next_navigation_item_id is not null and
192 (nvl(hr_itp_shd.g_old_rec.next_navigation_item_id,hr_api.g_number)
193 <> nvl(p_next_navigation_item_id,hr_api.g_number)))))
194 or ( p_item_property_id is null and
195 ( p_previous_navigation_item_id is not null
196 or p_next_navigation_item_id is not null )) THEN
197
198 OPEN cur_form;
199 FETCH cur_form INTO l_form_id;
200 IF cur_form%NOTFOUND THEN
201 CLOSE cur_form;
202 IF p_template_item_id is not null THEN
203 -- error message - invalid template item id
204 fnd_message.set_name('PER', 'HR_6153_ALL_PROCEDURE_FAIL');
205 fnd_message.set_token('PROCEDURE ', l_proc);
206 fnd_message.set_token('STEP ', '10');
207 fnd_message.raise_error;
208 ELSIF p_form_item_id is not null THEN
209 -- error message - invalid form item id
210 fnd_message.set_name('PER', 'HR_6153_ALL_PROCEDURE_FAIL');
211 fnd_message.set_token('PROCEDURE ', l_proc);
212 fnd_message.set_token('STEP ', '20');
213 fnd_message.raise_error;
214 ELSIF p_template_item_context_id is not null THEN
215 -- error message - invalid template item context id
216 fnd_message.set_name('PER', 'HR_6153_ALL_PROCEDURE_FAIL');
217 fnd_message.set_token('PROCEDURE ', l_proc);
218 fnd_message.set_token('STEP ', '30');
219 fnd_message.raise_error;
220 END IF;
221 END IF;
222 CLOSE cur_form;
223 END IF;
224
225 if (p_item_property_id is not null
226 and (p_previous_navigation_item_id is not null and
227 (nvl(hr_itp_shd.g_old_rec.previous_navigation_item_id,hr_api.g_number)
228 <> nvl(p_previous_navigation_item_id,hr_api.g_number))))
229 or (p_item_property_id is null
230 and p_previous_navigation_item_id is not null) then
231
232 OPEN cur_item(p_previous_navigation_item_id);
233 FETCH cur_item into l_prev_form_id;
234 IF cur_item%NOTFOUND THEN
235 CLOSE cur_item;
236 -- error message - invalid previous navigation item id
237 fnd_message.set_name('PER', 'HR_6153_ALL_PROCEDURE_FAIL');
238 fnd_message.set_token('PROCEDURE ', l_proc);
239 fnd_message.set_token('STEP ', '40');
240 fnd_message.raise_error;
241 END IF;
242 CLOSE cur_item;
243
244 IF l_prev_form_id <> l_form_id THEN
245 -- error message - previous navigation item id is not on the same form
246 -- as the item for which the item property is being created/amended
247 fnd_message.set_name('PER', 'HR_6153_ALL_PROCEDURE_FAIL');
248 fnd_message.set_token('PROCEDURE ', l_proc);
249 fnd_message.set_token('STEP ', '50');
250 fnd_message.raise_error;
251 END IF;
252
253 end if;
254
255 hr_utility.set_location('Leaving:'||l_proc, 20);
256
257 if (p_item_property_id is not null and
258 (p_next_navigation_item_id is not null and
259 (nvl(hr_itp_shd.g_old_rec.next_navigation_item_id,hr_api.g_number)
260 <> nvl(p_next_navigation_item_id,hr_api.g_number))))
261 or (p_item_property_id is null and p_next_navigation_item_id is not null)
262 then
263
264 OPEN cur_item(p_next_navigation_item_id);
265 FETCH cur_item into l_next_form_id;
266 IF cur_item%NOTFOUND THEN
267 CLOSE cur_item;
268 -- error message - invalid next navigation item id
269 fnd_message.set_name('PER', 'HR_6153_ALL_PROCEDURE_FAIL');
270 fnd_message.set_token('PROCEDURE ', l_proc);
271 fnd_message.set_token('STEP ', '60');
272 fnd_message.raise_error;
273 END IF;
274 CLOSE cur_item;
275
276 IF l_next_form_id <> l_form_id THEN
277 -- error message - next item id is not on the same form
278 -- as the item for which the item property is being created/amended
279 fnd_message.set_name('PER', 'HR_6153_ALL_PROCEDURE_FAIL');
280 fnd_message.set_token('PROCEDURE ', l_proc);
281 fnd_message.set_token('STEP ', '70');
282 fnd_message.raise_error;
283 END IF;
284
285 end if;
286 --
287 --
288 hr_utility.set_location('Leaving:'||l_proc, 100);
289 End chk_prev_and_next_nav_item;
290 --
291 --
292 -- ---------------------------------------------------------------------------
293 -- |---------------------------< return_item_type >--------------------------|
294 -- ---------------------------------------------------------------------------
295 FUNCTION return_item_type
296 (p_form_item_id in number default hr_api.g_number
297 ,p_template_item_id in number default hr_api.g_number
298 ,p_template_item_context_id in number default hr_api.g_number
299 ) RETURN varchar2 is
300 --
301 -- Declare cursors
302 --
303 cursor csr_form_item is
304 select fim.item_type
305 from hr_form_items_b fim
306 where fim.form_item_id = p_form_item_id;
307 --
308 cursor csr_template_item is
309 select fim.item_type
310 from hr_form_items_b fim
311 ,hr_template_items_b tim
312 where fim.form_item_id = tim.form_item_id
313 and tim.template_item_id = p_template_item_id;
314 --
315 cursor csr_template_item_context is
316 select fim.item_type
317 from hr_form_items_b fim
318 ,hr_template_items_b tim
319 ,hr_template_item_contexts_b tic
320 where fim.form_item_id = tim.form_item_id
321 and tim.template_item_id = tic.template_item_id
322 and tic.template_item_context_id = p_template_item_context_id;
323 --
324 -- Declare local variables
325 --
326 l_item_type varchar2(30);
327 l_proc varchar2(72) := g_package||'return_canvas_type';
328 --
329 Begin
330 --
331 hr_utility.set_location('Entering:'|| l_proc, 10);
332 --
333 if ( nvl(hr_itp_bus.g_form_item_id, hr_api.g_number) = nvl(p_form_item_id, hr_api.g_number)
334 and nvl(hr_itp_bus.g_template_item_id, hr_api.g_number) = nvl(p_template_item_id, hr_api.g_number)
335 and nvl(hr_itp_bus.g_template_item_context_id, hr_api.g_number) = nvl(p_template_item_context_id, hr_api.g_number)
336 ) then
337 --
338 -- The item has already been found with a previous
339 -- call to this function. Just return the value in the global
340 -- variable.
341 --
342 l_item_type := hr_itp_bus.g_item_type;
343 hr_utility.set_location(l_proc, 20);
344 else
345 --
346 -- The IDs are different to the last call to this function
347 -- or this is the first call to this function.
348 --
349 if (nvl(p_form_item_id, hr_api.g_number) <> hr_api.g_number) then
350 --
351 open csr_form_item;
352 fetch csr_form_item into l_item_type;
353 --
354 if csr_form_item%notfound then
355 --
356 -- The form item id is invalid therefore we must error
357 --
358 close csr_form_item;
359 fnd_message.set_name('PER', 'HR_6153_ALL_PROCEDURE_FAIL');
360 fnd_message.set_token('PROCEDURE ', l_proc);
361 fnd_message.set_token('STEP ', '10');
362 fnd_message.raise_error;
363 end if;
364 hr_utility.set_location(l_proc,30);
365 close csr_form_item;
366 --
367 elsif (nvl(p_template_item_id, hr_api.g_number) <> hr_api.g_number) then
368 --
369 open csr_template_item;
370 fetch csr_template_item into l_item_type;
371 --
372 if csr_template_item%notfound then
373 --
374 -- The template item id is invalid therefore we must error
375 --
376 close csr_template_item;
377 fnd_message.set_name('PER', 'HR_6153_ALL_PROCEDURE_FAIL');
378 fnd_message.set_token('PROCEDURE ', l_proc);
379 fnd_message.set_token('STEP ', '20');
380 fnd_message.raise_error;
381 end if;
382 hr_utility.set_location(l_proc,40);
383 close csr_template_item;
384 --
385 elsif (nvl(p_template_item_context_id, hr_api.g_number) <> hr_api.g_number) then
386 --
387 open csr_template_item_context;
388 fetch csr_template_item_context into l_item_type;
389 --
390 if csr_template_item_context%notfound then
391 --
392 -- The template item context id is invalid therefore we must error
393 --
394 close csr_template_item_context;
395 fnd_message.set_name('PER', 'HR_6153_ALL_PROCEDURE_FAIL');
396 fnd_message.set_token('PROCEDURE ', l_proc);
397 fnd_message.set_token('STEP ', '30');
398 fnd_message.raise_error;
399 end if;
400 hr_utility.set_location(l_proc,50);
401 close csr_template_item_context;
402 --
403 end if;
404 --
405 -- Set the global variables so the values are
406 -- available for the next call to this function.
407 --
408 hr_itp_bus.g_form_item_id := p_form_item_id;
409 hr_itp_bus.g_template_item_id := p_template_item_id;
410 hr_itp_bus.g_template_item_context_id := p_template_item_context_id;
411 hr_itp_bus.g_item_type := l_item_type;
412 end if;
413 hr_utility.set_location(' Leaving:'|| l_proc, 50);
414 return l_item_type;
415 End return_item_type;
416 --
417 -- ----------------------------------------------------------------------------
418 -- |-----------------------------< chk_ddf >----------------------------------|
419 -- ----------------------------------------------------------------------------
420 --
421 -- Description:
422 -- Validates all the Developer Descriptive Flexfield values.
423 --
424 -- Prerequisites:
425 -- All other columns have been validated. Must be called as the
426 -- last step from insert_validate and update_validate.
427 --
428 -- In Arguments:
429 -- p_rec
430 --
431 -- Post Success:
432 -- If the Developer Descriptive Flexfield structure column and data values
433 -- are all valid this procedure will end normally and processing will
434 -- continue.
435 --
436 -- Post Failure:
437 -- If the Developer Descriptive Flexfield structure column value or any of
438 -- the data values are invalid then an application error is raised as
439 -- a PL/SQL exception.
440 --
441 -- Access Status:
442 -- Internal Row Handler Use Only.
443 --
444 -- ----------------------------------------------------------------------------
445 procedure chk_ddf
446 (p_rec in hr_itp_shd.g_rec_type
447 ) is
448 --
449 l_proc varchar2(72) := g_package || 'chk_ddf';
450 --
451 begin
452 hr_utility.set_location('Entering:'||l_proc,10);
453 --
454 if ((p_rec.item_property_id is not null) and (
455 nvl(hr_itp_shd.g_old_rec.information_formula_id, hr_api.g_number) <>
456 nvl(p_rec.information_formula_id, hr_api.g_number) or
457 nvl(hr_itp_shd.g_old_rec.information_parameter_item_id1, hr_api.g_number)
458 <>
459 nvl(p_rec.information_parameter_item_id1, hr_api.g_number) or
460 nvl(hr_itp_shd.g_old_rec.information_parameter_item_id2, hr_api.g_number)
461 <>
462 nvl(p_rec.information_parameter_item_id2, hr_api.g_number) or
463 nvl(hr_itp_shd.g_old_rec.information_parameter_item_id3, hr_api.g_number)
464 <>
465 nvl(p_rec.information_parameter_item_id3, hr_api.g_number) or
466 nvl(hr_itp_shd.g_old_rec.information_parameter_item_id4, hr_api.g_number)
467 <>
468 nvl(p_rec.information_parameter_item_id4, hr_api.g_number) or
469 nvl(hr_itp_shd.g_old_rec.information_parameter_item_id5, hr_api.g_number)
470 <>
471 nvl(p_rec.information_parameter_item_id5, hr_api.g_number) or
472 nvl(hr_itp_shd.g_old_rec.information_category, hr_api.g_varchar2) <>
473 nvl(p_rec.information_category, hr_api.g_varchar2) or
474 nvl(hr_itp_shd.g_old_rec.information1, hr_api.g_varchar2) <>
475 nvl(p_rec.information1, hr_api.g_varchar2) or
476 nvl(hr_itp_shd.g_old_rec.information2, hr_api.g_varchar2) <>
477 nvl(p_rec.information2, hr_api.g_varchar2) or
478 nvl(hr_itp_shd.g_old_rec.information3, hr_api.g_varchar2) <>
479 nvl(p_rec.information3, hr_api.g_varchar2) or
480 nvl(hr_itp_shd.g_old_rec.information4, hr_api.g_varchar2) <>
481 nvl(p_rec.information4, hr_api.g_varchar2) or
482 nvl(hr_itp_shd.g_old_rec.information5, hr_api.g_varchar2) <>
483 nvl(p_rec.information5, hr_api.g_varchar2) or
484 nvl(hr_itp_shd.g_old_rec.information6, hr_api.g_varchar2) <>
485 nvl(p_rec.information6, hr_api.g_varchar2) or
486 nvl(hr_itp_shd.g_old_rec.information7, hr_api.g_varchar2) <>
487 nvl(p_rec.information7, hr_api.g_varchar2) or
488 nvl(hr_itp_shd.g_old_rec.information8, hr_api.g_varchar2) <>
489 nvl(p_rec.information8, hr_api.g_varchar2) or
490 nvl(hr_itp_shd.g_old_rec.information9, hr_api.g_varchar2) <>
491 nvl(p_rec.information9, hr_api.g_varchar2) or
492 nvl(hr_itp_shd.g_old_rec.information10, hr_api.g_varchar2) <>
493 nvl(p_rec.information10, hr_api.g_varchar2) or
494 nvl(hr_itp_shd.g_old_rec.information11, hr_api.g_varchar2) <>
495 nvl(p_rec.information11, hr_api.g_varchar2) or
496 nvl(hr_itp_shd.g_old_rec.information12, hr_api.g_varchar2) <>
497 nvl(p_rec.information12, hr_api.g_varchar2) or
498 nvl(hr_itp_shd.g_old_rec.information13, hr_api.g_varchar2) <>
499 nvl(p_rec.information13, hr_api.g_varchar2) or
500 nvl(hr_itp_shd.g_old_rec.information14, hr_api.g_varchar2) <>
501 nvl(p_rec.information14, hr_api.g_varchar2) or
502 nvl(hr_itp_shd.g_old_rec.information15, hr_api.g_varchar2) <>
503 nvl(p_rec.information15, hr_api.g_varchar2) or
504 nvl(hr_itp_shd.g_old_rec.information16, hr_api.g_varchar2) <>
505 nvl(p_rec.information16, hr_api.g_varchar2) or
506 nvl(hr_itp_shd.g_old_rec.information17, hr_api.g_varchar2) <>
507 nvl(p_rec.information17, hr_api.g_varchar2) or
508 nvl(hr_itp_shd.g_old_rec.information18, hr_api.g_varchar2) <>
509 nvl(p_rec.information18, hr_api.g_varchar2) or
510 nvl(hr_itp_shd.g_old_rec.information19, hr_api.g_varchar2) <>
511 nvl(p_rec.information19, hr_api.g_varchar2) or
512 nvl(hr_itp_shd.g_old_rec.information20, hr_api.g_varchar2) <>
513 nvl(p_rec.information20, hr_api.g_varchar2) or
514 nvl(hr_itp_shd.g_old_rec.information21, hr_api.g_varchar2) <>
515 nvl(p_rec.information21, hr_api.g_varchar2) or
516 nvl(hr_itp_shd.g_old_rec.information22, hr_api.g_varchar2) <>
517 nvl(p_rec.information22, hr_api.g_varchar2) or
518 nvl(hr_itp_shd.g_old_rec.information23, hr_api.g_varchar2) <>
519 nvl(p_rec.information23, hr_api.g_varchar2) or
520 nvl(hr_itp_shd.g_old_rec.information24, hr_api.g_varchar2) <>
521 nvl(p_rec.information24, hr_api.g_varchar2) or
522 nvl(hr_itp_shd.g_old_rec.information25, hr_api.g_varchar2) <>
523 nvl(p_rec.information25, hr_api.g_varchar2) or
524 nvl(hr_itp_shd.g_old_rec.information26, hr_api.g_varchar2) <>
525 nvl(p_rec.information26, hr_api.g_varchar2) or
526 nvl(hr_itp_shd.g_old_rec.information27, hr_api.g_varchar2) <>
527 nvl(p_rec.information27, hr_api.g_varchar2) or
528 nvl(hr_itp_shd.g_old_rec.information28, hr_api.g_varchar2) <>
529 nvl(p_rec.information28, hr_api.g_varchar2) or
530 nvl(hr_itp_shd.g_old_rec.information29, hr_api.g_varchar2) <>
531 nvl(p_rec.information29, hr_api.g_varchar2) or
532 nvl(hr_itp_shd.g_old_rec.information30, hr_api.g_varchar2) <>
533 nvl(p_rec.information30, hr_api.g_varchar2) )
534 or (p_rec.item_property_id is null) ) then
535 --
536 -- Only execute the validation if absolutely necessary:
537 -- a) During update, the structure column value or any
538 -- of the attribute values have actually changed.
539 -- b) During insert.
540 --
541 hr_dflex_utility.ins_or_upd_descflex_attribs
542 (p_appl_short_name => 'PER'
543 ,p_descflex_name => 'HR_ITEM_PROPERTIES'
544 ,p_attribute_category => p_rec.information_category
545 ,p_attribute1_name => 'INFORMATION1'
546 ,p_attribute1_value => p_rec.information1
547 ,p_attribute2_name => 'INFORMATION2'
548 ,p_attribute2_value => p_rec.information2
549 ,p_attribute3_name => 'INFORMATION3'
550 ,p_attribute3_value => p_rec.information3
551 ,p_attribute4_name => 'INFORMATION4'
552 ,p_attribute4_value => p_rec.information4
553 ,p_attribute5_name => 'INFORMATION5'
554 ,p_attribute5_value => p_rec.information5
555 ,p_attribute6_name => 'INFORMATION6'
556 ,p_attribute6_value => p_rec.information6
557 ,p_attribute7_name => 'INFORMATION7'
558 ,p_attribute7_value => p_rec.information7
559 ,p_attribute8_name => 'INFORMATION8'
560 ,p_attribute8_value => p_rec.information8
561 ,p_attribute9_name => 'INFORMATION9'
562 ,p_attribute9_value => p_rec.information9
563 ,p_attribute10_name => 'INFORMATION10'
564 ,p_attribute10_value => p_rec.information10
565 ,p_attribute11_name => 'INFORMATION11'
566 ,p_attribute11_value => p_rec.information11
567 ,p_attribute12_name => 'INFORMATION12'
568 ,p_attribute12_value => p_rec.information12
569 ,p_attribute13_name => 'INFORMATION13'
570 ,p_attribute13_value => p_rec.information13
571 ,p_attribute14_name => 'INFORMATION14'
572 ,p_attribute14_value => p_rec.information14
573 ,p_attribute15_name => 'INFORMATION15'
574 ,p_attribute15_value => p_rec.information15
575 ,p_attribute16_name => 'INFORMATION16'
576 ,p_attribute16_value => p_rec.information16
577 ,p_attribute17_name => 'INFORMATION17'
578 ,p_attribute17_value => p_rec.information17
579 ,p_attribute18_name => 'INFORMATION18'
580 ,p_attribute18_value => p_rec.information18
581 ,p_attribute19_name => 'INFORMATION19'
582 ,p_attribute19_value => p_rec.information19
583 ,p_attribute20_name => 'INFORMATION20'
584 ,p_attribute20_value => p_rec.information20
585 ,p_attribute21_name => 'INFORMATION21'
586 ,p_attribute21_value => p_rec.information21
587 ,p_attribute22_name => 'INFORMATION22'
588 ,p_attribute22_value => p_rec.information22
589 ,p_attribute23_name => 'INFORMATION23'
590 ,p_attribute23_value => p_rec.information23
591 ,p_attribute24_name => 'INFORMATION24'
592 ,p_attribute24_value => p_rec.information24
593 ,p_attribute25_name => 'INFORMATION25'
594 ,p_attribute25_value => p_rec.information25
595 ,p_attribute26_name => 'INFORMATION26'
596 ,p_attribute26_value => p_rec.information26
597 ,p_attribute27_name => 'INFORMATION27'
598 ,p_attribute27_value => p_rec.information27
599 ,p_attribute28_name => 'INFORMATION28'
600 ,p_attribute28_value => p_rec.information28
601 ,p_attribute29_name => 'INFORMATION29'
602 ,p_attribute29_value => p_rec.information29
603 ,p_attribute30_name => 'INFORMATION30'
604 ,p_attribute30_value => p_rec.information30
605 );
606 end if;
607 --
608 hr_utility.set_location(' Leaving:'||l_proc,20);
609 end chk_ddf;
610 --
611 -- ----------------------------------------------------------------------------
612 -- |-----------------------< chk_non_updateable_args >------------------------|
613 -- ----------------------------------------------------------------------------
614 -- {Start Of Comments}
615 --
616 -- Description:
617 -- This procedure is used to ensure that non updateable attributes have
618 -- not been updated. If an attribute has been updated an error is generated.
619 --
620 -- Pre Conditions:
621 -- g_old_rec has been populated with details of the values currently in
622 -- the database.
623 --
624 -- In Arguments:
625 -- p_rec has been populated with the updated values the user would like the
626 -- record set to.
627 --
628 -- Post Success:
629 -- Processing continues if all the non updateable attributes have not
630 -- changed.
631 --
632 -- Post Failure:
633 -- An application error is raised if any of the non updatable attributes
634 -- have been altered.
635 --
636 -- {End Of Comments}
637 -- ----------------------------------------------------------------------------
638 Procedure chk_non_updateable_args
639 (p_effective_date in date
640 ,p_rec in hr_itp_shd.g_rec_type
641 ) IS
642 --
643 l_proc varchar2(72) := g_package || 'chk_non_updateable_args';
644 l_error EXCEPTION;
645 l_argument varchar2(30);
646 --
647 Begin
648 --
649 -- Only proceed with the validation if a row exists for the current
650 -- record in the HR Schema.
651 --
652 IF NOT hr_itp_shd.api_updating
653 (p_item_property_id => p_rec.item_property_id
654 ,p_object_version_number => p_rec.object_version_number
655 ) THEN
656 fnd_message.set_name('PER', 'HR_6153_ALL_PROCEDURE_FAIL');
657 fnd_message.set_token('PROCEDURE ', l_proc);
658 fnd_message.set_token('STEP ', '5');
659 fnd_message.raise_error;
660 END IF;
661 --
662 IF (nvl(p_rec.form_item_id,hr_api.g_number) <>
663 nvl(hr_itp_shd.g_old_rec.form_item_id,hr_api.g_number)
664 ) THEN
665 l_argument := 'form_item_id';
666 RAISE l_error;
667 END IF;
668 --
669 IF (nvl(p_rec.template_item_id,hr_api.g_number) <>
670 nvl(hr_itp_shd.g_old_rec.template_item_id,hr_api.g_number)
671 ) THEN
672 l_argument := 'template_item_id';
673 RAISE l_error;
674 END IF;
675 --
676 IF (nvl(p_rec.template_item_context_id,hr_api.g_number) <>
677 nvl(hr_itp_shd.g_old_rec.template_item_context_id,hr_api.g_number)
678 ) THEN
679 l_argument := 'template_item_context_id';
680 RAISE l_error;
681 END IF;
682 --
683 EXCEPTION
684 WHEN l_error THEN
685 hr_api.argument_changed_error
686 (p_api_name => l_proc
687 ,p_argument => l_argument);
688 WHEN OTHERS THEN
689 RAISE;
690 End chk_non_updateable_args;
691 --
692 -- ----------------------------------------------------------------------------
693 -- |--------------------< chk_form_template_and_context >---------------------|
694 -- ----------------------------------------------------------------------------
695 Procedure chk_form_template_and_context
696 (p_effective_date in date
697 ,p_item_property_id in number
698 ,p_form_item_id in number
699 ,p_template_item_id in number
700 ,p_template_item_context_id in number
701 ) is
702 --
703 l_proc varchar2(72) := g_package || 'chk_form_template_and_context';
704 l_api_updating boolean;
705 --
706 Begin
707 hr_utility.set_location('Entering:'||l_proc, 10);
708 --
709 -- One and only one of form_item_id, template_item_id and
710 -- template_item_context_id must be given
711 --
712 if not ( ( p_form_item_id is not null
713 and p_template_item_id is null
714 and p_template_item_context_id is null)
715 or ( p_form_item_id is null
716 and p_template_item_id is not null
717 and p_template_item_context_id is null)
718 or ( p_form_item_id is null
719 and p_template_item_id is null
720 and p_template_item_context_id is not null)) then
721 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
722 fnd_message.set_token('PROCEDURE', l_proc);
723 fnd_message.set_token('STEP','10');
724 fnd_message.raise_error;
725 end if;
726 --
727 hr_utility.set_location('Leaving:'||l_proc, 100);
728 End chk_form_template_and_context;
729 --
730 -- ----------------------------------------------------------------------------
731 -- |---------------------------< chk_form_item_id >---------------------------|
732 -- ----------------------------------------------------------------------------
733 Procedure chk_form_item_id
734 (p_effective_date in date
735 ,p_item_property_id in number
736 ,p_form_item_id in number
737 ) is
738 --
739 l_proc varchar2(72) := g_package || 'chk_form_item_id';
740 l_api_updating boolean;
741 --
742 Begin
743 hr_utility.set_location('Entering:'||l_proc, 10);
744 --
745 -- No additional validation required
746 --
747 null;
748 --
749 hr_utility.set_location('Leaving:'||l_proc, 100);
750 End chk_form_item_id;
751 --
752 -- ----------------------------------------------------------------------------
753 -- |-------------------------< chk_template_item_id >-------------------------|
754 -- ----------------------------------------------------------------------------
755 Procedure chk_template_item_id
756 (p_effective_date in date
757 ,p_item_property_id in number
758 ,p_template_item_id in number
759 ) is
760 --
761 l_proc varchar2(72) := g_package || 'chk_template_item_id';
762 l_api_updating boolean;
763 --
764 Begin
765 hr_utility.set_location('Entering:'||l_proc, 10);
766 --
767 -- No additional validation required
768 --
769 null;
770 --
771 hr_utility.set_location('Leaving:'||l_proc, 100);
772 End chk_template_item_id;
773 --
774 -- ----------------------------------------------------------------------------
775 -- |---------------------< chk_template_item_context_id >---------------------|
776 -- ----------------------------------------------------------------------------
777 Procedure chk_template_item_context_id
778 (p_effective_date in date
779 ,p_item_property_id in number
780 ,p_template_item_context_id in number
781 ) is
782 --
783 l_proc varchar2(72) := g_package || 'chk_template_item_context_id';
784 l_api_updating boolean;
785 --
786 Begin
787 hr_utility.set_location('Entering:'||l_proc, 10);
788 --
789 -- No additional validation required
790 --
791 null;
792 --
793 hr_utility.set_location('Leaving:'||l_proc, 100);
794 End chk_template_item_context_id;
795 --
796 -- ----------------------------------------------------------------------------
797 -- |----------------------------< chk_alignment >-----------------------------|
798 -- ----------------------------------------------------------------------------
799 Procedure chk_alignment
800 (p_effective_date in date
801 ,p_object_version_number in number
802 ,p_item_property_id in number
803 ,p_alignment in number
804 ) is
805 --
806 l_proc varchar2(72) := g_package || 'chk_alignment';
807 l_api_updating boolean;
808 --
809 Begin
810 hr_utility.set_location('Entering:'||l_proc, 10);
811 --
812 -- Check mandatory arguments have been set
813 --
814 hr_api.mandatory_arg_error
815 (p_api_name => l_proc
816 ,p_argument => 'effective_date'
817 ,p_argument_value => p_effective_date
818 );
819 --
820 l_api_updating := hr_itp_shd.api_updating
821 (p_item_property_id => p_item_property_id
822 ,p_object_version_number => p_object_version_number
823 );
824 hr_utility.set_location(l_proc,20);
825 --
826 -- Only proceed with SQL validation if absolutely necessary
827 --
828 if ( ( l_api_updating
829 and nvl(hr_itp_shd.g_old_rec.alignment,hr_api.g_number) <>
830 nvl(p_alignment,hr_api.g_number))
831 or (NOT l_api_updating)) then
832 --
833 hr_utility.set_location(l_proc,30);
834 --
835 if (p_alignment is not null) then
836 --
837 hr_utility.set_location(l_proc,40);
838 --
839 -- Must exist in hr_standard_lookups where lookup_type is
840 -- ALIGNMENTS
841 --
842 if hr_api.not_exists_in_hrstanlookups
843 (p_effective_date => p_effective_date
844 ,p_lookup_type => 'ALIGNMENTS'
845 ,p_lookup_code => p_alignment
846 ) then
847 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
848 fnd_message.set_token('PROCEDURE', l_proc);
849 fnd_message.set_token('STEP','10');
850 fnd_message.raise_error;
851 end if;
852 --
853 end if;
854 --
855 end if;
856 --
857 hr_utility.set_location('Leaving:'||l_proc, 100);
858 End chk_alignment;
859 --
860 -- ----------------------------------------------------------------------------
861 -- |------------------------------< chk_bevel >-------------------------------|
862 -- ----------------------------------------------------------------------------
863 Procedure chk_bevel
864 (p_effective_date in date
865 ,p_object_version_number in number
866 ,p_item_property_id in number
867 ,p_bevel in number
868 ) is
869 --
870 l_proc varchar2(72) := g_package || 'chk_bevel';
871 l_api_updating boolean;
872 --
873 Begin
874 hr_utility.set_location('Entering:'||l_proc, 10);
875 --
876 -- Check mandatory arguments have been set
877 --
878 hr_api.mandatory_arg_error
879 (p_api_name => l_proc
880 ,p_argument => 'effective_date'
881 ,p_argument_value => p_effective_date
882 );
883 --
884 l_api_updating := hr_itp_shd.api_updating
885 (p_item_property_id => p_item_property_id
886 ,p_object_version_number => p_object_version_number
887 );
888 hr_utility.set_location(l_proc,20);
889 --
890 -- Only proceed with SQL validation if absolutely necessary
891 --
892 if ( ( l_api_updating
893 and nvl(hr_itp_shd.g_old_rec.bevel,hr_api.g_number) <>
894 nvl(p_bevel,hr_api.g_number))
895 or (NOT l_api_updating)) then
896 --
897 hr_utility.set_location(l_proc,30);
898 --
899 if (p_bevel is not null) then
900 --
901 hr_utility.set_location(l_proc,40);
902 --
903 -- Must exist in hr_standard_lookups where lookup_type is
904 -- BORDER_BEVELS
905 --
906 if hr_api.not_exists_in_hrstanlookups
907 (p_effective_date => p_effective_date
908 ,p_lookup_type => 'BORDER_BEVELS'
909 ,p_lookup_code => p_bevel
910 ) then
911 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
912 fnd_message.set_token('PROCEDURE', l_proc);
913 fnd_message.set_token('STEP','10');
914 fnd_message.raise_error;
915 end if;
916 --
917 end if;
918 --
919 end if;
920 --
921 hr_utility.set_location('Leaving:'||l_proc, 100);
922 End chk_bevel;
923 --
924 -- ----------------------------------------------------------------------------
925 -- |-------------------------< chk_case_restriction >-------------------------|
926 -- ----------------------------------------------------------------------------
927 Procedure chk_case_restriction
928 (p_effective_date in date
929 ,p_object_version_number in number
930 ,p_item_property_id in number
931 ,p_case_restriction in number
932 ) is
933 --
934 l_proc varchar2(72) := g_package || 'chk_case_restriction';
935 l_api_updating boolean;
936 --
937 Begin
938 hr_utility.set_location('Entering:'||l_proc, 10);
939 --
940 -- Check mandatory arguments have been set
941 --
942 hr_api.mandatory_arg_error
943 (p_api_name => l_proc
944 ,p_argument => 'effective_date'
945 ,p_argument_value => p_effective_date
946 );
947 --
948 l_api_updating := hr_itp_shd.api_updating
949 (p_item_property_id => p_item_property_id
950 ,p_object_version_number => p_object_version_number
951 );
952 hr_utility.set_location(l_proc,20);
953 --
954 -- Only proceed with SQL validation if absolutely necessary
955 --
956 if ( ( l_api_updating
957 and nvl(hr_itp_shd.g_old_rec.case_restriction,hr_api.g_number) <>
958 nvl(p_case_restriction,hr_api.g_number))
959 or (NOT l_api_updating)) then
960 --
961 hr_utility.set_location(l_proc,30);
962 --
963 if (p_case_restriction is not null) then
964 --
965 hr_utility.set_location(l_proc,40);
966 --
967 -- Must exist in hr_standard_lookups where lookup_type is
968 -- CASE_RESTRICTIONS
969 --
970 if hr_api.not_exists_in_hrstanlookups
971 (p_effective_date => p_effective_date
972 ,p_lookup_type => 'CASE_RESTRICTIONS'
973 ,p_lookup_code => p_case_restriction
974 ) then
975 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
976 fnd_message.set_token('PROCEDURE', l_proc);
977 fnd_message.set_token('STEP','10');
978 fnd_message.raise_error;
979 end if;
980 --
981 end if;
982 --
983 end if;
984 --
985 hr_utility.set_location('Leaving:'||l_proc, 100);
986 End chk_case_restriction;
987 --
988 -- ----------------------------------------------------------------------------
989 -- |-----------------------------< chk_enabled >------------------------------|
990 -- ----------------------------------------------------------------------------
991 Procedure chk_enabled
992 (p_effective_date in date
993 ,p_object_version_number in number
994 ,p_item_property_id in number
995 ,p_enabled in number
996 ) is
997 --
998 l_proc varchar2(72) := g_package || 'chk_enabled';
999 l_api_updating boolean;
1000 --
1001 Begin
1002 hr_utility.set_location('Entering:'||l_proc, 10);
1003 --
1004 -- Check mandatory arguments have been set
1005 --
1006 hr_api.mandatory_arg_error
1007 (p_api_name => l_proc
1008 ,p_argument => 'effective_date'
1009 ,p_argument_value => p_effective_date
1010 );
1011 --
1012 l_api_updating := hr_itp_shd.api_updating
1013 (p_item_property_id => p_item_property_id
1014 ,p_object_version_number => p_object_version_number
1015 );
1016 hr_utility.set_location(l_proc,20);
1017 --
1018 -- Only proceed with SQL validation if absolutely necessary
1019 --
1020 if ( ( l_api_updating
1021 and nvl(hr_itp_shd.g_old_rec.enabled,hr_api.g_number) <>
1022 nvl(p_enabled,hr_api.g_number))
1023 or (NOT l_api_updating)) then
1024 --
1025 hr_utility.set_location(l_proc,30);
1026 --
1027 if (p_enabled is not null) then
1028 --
1029 hr_utility.set_location(l_proc,40);
1030 --
1031 -- Must exist in hr_standard_lookups where lookup_type is
1032 -- PROPERTY_TRUE_OR_FALSE
1033 --
1034 if hr_api.not_exists_in_hrstanlookups
1035 (p_effective_date => p_effective_date
1036 ,p_lookup_type => 'PROPERTY_TRUE_OR_FALSE'
1037 ,p_lookup_code => p_enabled
1038 ) then
1039 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1040 fnd_message.set_token('PROCEDURE', l_proc);
1041 fnd_message.set_token('STEP','10');
1042 fnd_message.raise_error;
1043 end if;
1044 --
1045 end if;
1046 --
1047 end if;
1048 --
1049 hr_utility.set_location('Leaving:'||l_proc, 100);
1050 End chk_enabled;
1051 --
1052 -- ----------------------------------------------------------------------------
1053 -- |---------------------------< chk_format_mask >----------------------------|
1054 -- ----------------------------------------------------------------------------
1055 Procedure chk_format_mask
1056 (p_effective_date in date
1057 ,p_item_property_id in number
1058 ,p_format_mask in varchar2
1059 ) is
1060 --
1061 l_proc varchar2(72) := g_package || 'chk_format_mask';
1062 l_api_updating boolean;
1063 --
1064 Begin
1065 hr_utility.set_location('Entering:'||l_proc, 10);
1066 --
1067 -- No additional validation required
1068 --
1069 null;
1070 --
1071 hr_utility.set_location('Leaving:'||l_proc, 100);
1072 End chk_format_mask;
1073 --
1074 -- ----------------------------------------------------------------------------
1075 -- |------------------------------< chk_height >------------------------------|
1076 -- ----------------------------------------------------------------------------
1077 Procedure chk_height
1078 (p_effective_date in date
1079 ,p_item_property_id in number
1080 ,p_height in number
1081 ) is
1082 --
1083 l_proc varchar2(72) := g_package || 'chk_height';
1084 l_api_updating boolean;
1085 --
1086 Begin
1087 hr_utility.set_location('Entering:'||l_proc, 10);
1088 --
1089 -- Height must be greater than or equal to zero, if given
1090 --
1091 if (p_height is not null) then
1092 --
1093 hr_utility.set_location(l_proc,30);
1094 --
1095 if (p_height < 0) then
1096 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1097 fnd_message.set_token('PROCEDURE', l_proc);
1098 fnd_message.set_token('STEP','10');
1099 fnd_message.raise_error;
1100 end if;
1101 --
1102 end if;
1103 --
1104 hr_utility.set_location('Leaving:'||l_proc, 100);
1105 End chk_height;
1106 --
1107 -- ----------------------------------------------------------------------------
1108 -- |----------------------< chk_information_formula_id >----------------------|
1109 -- ----------------------------------------------------------------------------
1110 Procedure chk_information_formula_id
1111 (p_effective_date in date
1112 ,p_object_version_number in number
1113 ,p_item_property_id in number
1114 ,p_information_formula_id in number
1115 ) is
1116 --
1117 cursor csr_formula is
1118 select fft.formula_type_name
1119 from ff_formula_types fft
1120 ,ff_formulas fml
1121 where fft.formula_type_id = fml.formula_type_id
1122 and fml.formula_id = p_information_formula_id;
1123 --
1124 l_proc varchar2(72) := g_package || 'chk_information_formula_id';
1125 l_api_updating boolean;
1126 l_formula_type_name varchar2(80);
1127 --
1128 Begin
1129 hr_utility.set_location('Entering:'||l_proc, 10);
1130 --
1131 l_api_updating := hr_itp_shd.api_updating
1132 (p_item_property_id => p_item_property_id
1133 ,p_object_version_number => p_object_version_number
1134 );
1135 hr_utility.set_location(l_proc,20);
1136 --
1137 -- Only proceed with SQL validation if absolutely necessary
1138 --
1139 if ( ( l_api_updating
1140 and nvl(hr_itp_shd.g_old_rec.information_formula_id,hr_api.g_number) <>
1141 nvl(p_information_formula_id,hr_api.g_number))
1142 or (NOT l_api_updating)) then
1143 --
1144 if p_information_formula_id is not null then
1145 --
1146 -- Check formula exists
1147 --
1148 open csr_formula;
1149 fetch csr_formula into l_formula_type_name;
1150 if csr_formula%notfound then
1151 close csr_formula;
1152 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1153 fnd_message.set_token('PROCEDURE', l_proc);
1154 fnd_message.set_token('STEP','10');
1155 fnd_message.raise_error;
1156 end if;
1157 close csr_formula;
1158 --
1159 -- Check formula is of type 'Template Information' if specified
1160 --
1161 if nvl(l_formula_type_name,hr_api.g_varchar2) <> 'Template Information' then
1162 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1163 fnd_message.set_token('PROCEDURE', l_proc);
1164 fnd_message.set_token('STEP','20');
1165 fnd_message.raise_error;
1166 end if;
1167 --
1168 end if;
1169 --
1170 end if;
1171 --
1172 hr_utility.set_location('Leaving:'||l_proc, 100);
1173 End chk_information_formula_id;
1174 --
1175 -- ----------------------------------------------------------------------------
1176 -- |--------------------< chk_information_param_item_ids >--------------------|
1177 -- ----------------------------------------------------------------------------
1178 Procedure chk_information_param_item_ids
1179 (p_effective_date in date
1180 ,p_item_property_id in number
1181 ,p_information_formula_id in number
1182 ,p_information_param_item_id1 in number
1183 ,p_information_param_item_id2 in number
1184 ,p_information_param_item_id3 in number
1185 ,p_information_param_item_id4 in number
1186 ,p_information_param_item_id5 in number
1187 ) is
1188 --
1189 l_proc varchar2(72) := g_package || 'chk_information_param_item_ids';
1190 l_api_updating boolean;
1191 --
1192 Begin
1193 hr_utility.set_location('Entering:'||l_proc, 10);
1194 --
1195 -- Check item ids have only been specified if the formula has
1196 --
1197 if p_information_formula_id is null then
1198 if ( p_information_param_item_id1 is not null
1199 or p_information_param_item_id2 is not null
1200 or p_information_param_item_id3 is not null
1201 or p_information_param_item_id4 is not null
1202 or p_information_param_item_id5 is not null) then
1203 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1204 fnd_message.set_token('PROCEDURE', l_proc);
1205 fnd_message.set_token('STEP','10');
1206 fnd_message.raise_error;
1207 end if;
1208 end if;
1209 --
1210 hr_utility.set_location('Leaving:'||l_proc, 100);
1211 End chk_information_param_item_ids;
1212 --
1213 -- ----------------------------------------------------------------------------
1214 -- |--------------------------< chk_insert_allowed >--------------------------|
1215 -- ----------------------------------------------------------------------------
1216 Procedure chk_insert_allowed
1217 (p_effective_date in date
1218 ,p_object_version_number in number
1219 ,p_item_property_id in number
1220 ,p_insert_allowed in number
1221 ) is
1222 --
1223 l_proc varchar2(72) := g_package || 'chk_insert_allowed';
1224 l_api_updating boolean;
1225 --
1226 Begin
1227 hr_utility.set_location('Entering:'||l_proc, 10);
1228 --
1229 -- Check mandatory arguments have been set
1230 --
1231 hr_api.mandatory_arg_error
1232 (p_api_name => l_proc
1233 ,p_argument => 'effective_date'
1234 ,p_argument_value => p_effective_date
1235 );
1236 --
1237 l_api_updating := hr_itp_shd.api_updating
1238 (p_item_property_id => p_item_property_id
1239 ,p_object_version_number => p_object_version_number
1240 );
1241 hr_utility.set_location(l_proc,20);
1242 --
1243 -- Only proceed with SQL validation if absolutely necessary
1244 --
1245 if ( ( l_api_updating
1246 and nvl(hr_itp_shd.g_old_rec.insert_allowed,hr_api.g_number) <>
1247 nvl(p_insert_allowed,hr_api.g_number))
1248 or (NOT l_api_updating)) then
1249 --
1250 hr_utility.set_location(l_proc,30);
1251 --
1252 if (p_insert_allowed is not null) then
1253 --
1254 hr_utility.set_location(l_proc,40);
1255 --
1256 -- Must exist in hr_standard_lookups where lookup_type is
1257 -- PROPERTY_TRUE_OR_FALSE
1258 --
1259 if hr_api.not_exists_in_hrstanlookups
1260 (p_effective_date => p_effective_date
1261 ,p_lookup_type => 'PROPERTY_TRUE_OR_FALSE'
1262 ,p_lookup_code => p_insert_allowed
1263 ) then
1264 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1265 fnd_message.set_token('PROCEDURE', l_proc);
1266 fnd_message.set_token('STEP','10');
1267 fnd_message.raise_error;
1268 end if;
1269 --
1270 end if;
1271 --
1272 end if;
1273 --
1274 hr_utility.set_location('Leaving:'||l_proc, 100);
1275 End chk_insert_allowed;
1276 --
1277 -- ----------------------------------------------------------------------------
1278 -- |---------------------< chk_prompt_alignment_offset >----------------------|
1279 -- ----------------------------------------------------------------------------
1280 Procedure chk_prompt_alignment_offset
1281 (p_effective_date in date
1282 ,p_item_property_id in number
1283 ,p_prompt_alignment_offset in number
1284 ) is
1285 --
1286 l_proc varchar2(72) := g_package || 'chk_prompt_alignment_offset';
1287 l_api_updating boolean;
1288 --
1289 Begin
1290 hr_utility.set_location('Entering:'||l_proc, 10);
1291 --
1292 hr_utility.set_location('Leaving:'||l_proc, 100);
1293 End chk_prompt_alignment_offset;
1294 --
1295 -- ----------------------------------------------------------------------------
1296 -- |-----------------------< chk_prompt_display_style >-----------------------|
1297 -- ----------------------------------------------------------------------------
1298 Procedure chk_prompt_display_style
1299 (p_effective_date in date
1300 ,p_object_version_number in number
1301 ,p_item_property_id in number
1302 ,p_prompt_display_style in number
1303 ) is
1304 --
1305 l_proc varchar2(72) := g_package || 'chk_prompt_display_style';
1306 l_api_updating boolean;
1307 --
1308 Begin
1309 hr_utility.set_location('Entering:'||l_proc, 10);
1310 --
1311 -- Check mandatory arguments have been set
1312 --
1313 hr_api.mandatory_arg_error
1314 (p_api_name => l_proc
1315 ,p_argument => 'effective_date'
1316 ,p_argument_value => p_effective_date
1317 );
1318 --
1319 l_api_updating := hr_itp_shd.api_updating
1320 (p_item_property_id => p_item_property_id
1321 ,p_object_version_number => p_object_version_number
1322 );
1323 hr_utility.set_location(l_proc,20);
1324 --
1325 -- Only proceed with SQL validation if absolutely necessary
1326 --
1327 if ( ( l_api_updating
1328 and nvl(hr_itp_shd.g_old_rec.prompt_display_style,hr_api.g_number) <>
1329 nvl(p_prompt_display_style,hr_api.g_number))
1330 or (NOT l_api_updating)) then
1331 --
1332 hr_utility.set_location(l_proc,30);
1333 --
1334 if (p_prompt_display_style is not null) then
1335 --
1336 hr_utility.set_location(l_proc,40);
1337 --
1338 -- Must exist in hr_standard_lookups where lookup_type is
1339 -- PROMTP_DISPLAY_STYLES
1340 --
1341 if hr_api.not_exists_in_hrstanlookups
1342 (p_effective_date => p_effective_date
1343 ,p_lookup_type => 'PROMPT_DISPLAY_STYLES'
1344 ,p_lookup_code => p_prompt_display_style
1345 ) then
1346 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1347 fnd_message.set_token('PROCEDURE', l_proc);
1348 fnd_message.set_token('STEP','10');
1349 fnd_message.raise_error;
1350 end if;
1351 --
1352 end if;
1353 --
1354 end if;
1355 --
1356 hr_utility.set_location('Leaving:'||l_proc, 100);
1357 End chk_prompt_display_style;
1358 --
1359 -- ----------------------------------------------------------------------------
1360 -- |----------------------------< chk_prompt_edge >---------------------------|
1361 -- ----------------------------------------------------------------------------
1362 Procedure chk_prompt_edge
1363 (p_effective_date in date
1364 ,p_object_version_number in number
1365 ,p_item_property_id in number
1366 ,p_prompt_edge in number
1367 ) is
1368 --
1369 l_proc varchar2(72) := g_package || 'chk_prompt_edge';
1370 l_api_updating boolean;
1371 --
1372 Begin
1373 hr_utility.set_location('Entering:'||l_proc, 10);
1374 --
1375 -- Check mandatory arguments have been set
1376 --
1377 hr_api.mandatory_arg_error
1378 (p_api_name => l_proc
1379 ,p_argument => 'effective_date'
1380 ,p_argument_value => p_effective_date
1381 );
1382 --
1383 l_api_updating := hr_itp_shd.api_updating
1384 (p_item_property_id => p_item_property_id
1385 ,p_object_version_number => p_object_version_number
1386 );
1387 hr_utility.set_location(l_proc,20);
1388 --
1389 -- Only proceed with SQL validation if absolutely necessary
1390 --
1391 if ( ( l_api_updating
1392 and nvl(hr_itp_shd.g_old_rec.prompt_edge,hr_api.g_number) <>
1393 nvl(p_prompt_edge,hr_api.g_number))
1394 or (NOT l_api_updating)) then
1395 --
1396 hr_utility.set_location(l_proc,30);
1397 --
1398 if (p_prompt_edge is not null) then
1399 --
1400 hr_utility.set_location(l_proc,40);
1401 --
1402 -- Must exist in hr_standard_lookups where lookup_type is
1403 -- PROMPT_EDGES
1404 --
1405 if hr_api.not_exists_in_hrstanlookups
1406 (p_effective_date => p_effective_date
1407 ,p_lookup_type => 'PROMPT_EDGES'
1408 ,p_lookup_code => p_prompt_edge
1409 ) then
1410 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1411 fnd_message.set_token('PROCEDURE', l_proc);
1412 fnd_message.set_token('STEP','10');
1413 fnd_message.raise_error;
1414 end if;
1415 --
1416 end if;
1417 --
1418 end if;
1419 --
1420 hr_utility.set_location('Leaving:'||l_proc, 100);
1421 End chk_prompt_edge;
1422 --
1423 -- ----------------------------------------------------------------------------
1424 -- |-----------------------< chk_prompt_edge_alignment >----------------------|
1425 -- ----------------------------------------------------------------------------
1426 Procedure chk_prompt_edge_alignment
1427 (p_effective_date in date
1428 ,p_object_version_number in number
1429 ,p_item_property_id in number
1430 ,p_prompt_edge_alignment in number
1431 ) is
1432 --
1433 l_proc varchar2(72) := g_package || 'chk_prompt_edge_alignment';
1434 l_api_updating boolean;
1435 --
1436 Begin
1437 hr_utility.set_location('Entering:'||l_proc, 10);
1438 --
1439 -- Check mandatory arguments have been set
1440 --
1441 hr_api.mandatory_arg_error
1442 (p_api_name => l_proc
1443 ,p_argument => 'effective_date'
1444 ,p_argument_value => p_effective_date
1445 );
1446 --
1447 l_api_updating := hr_itp_shd.api_updating
1448 (p_item_property_id => p_item_property_id
1449 ,p_object_version_number => p_object_version_number
1450 );
1451 hr_utility.set_location(l_proc,20);
1452 --
1453 -- Only proceed with SQL validation if absolutely necessary
1454 --
1455 if ( ( l_api_updating
1456 and nvl(hr_itp_shd.g_old_rec.prompt_edge_alignment,hr_api.g_number) <>
1457 nvl(p_prompt_edge_alignment,hr_api.g_number))
1458 or (NOT l_api_updating)) then
1459 --
1460 hr_utility.set_location(l_proc,30);
1461 --
1462 if (p_prompt_edge_alignment is not null) then
1463 --
1464 hr_utility.set_location(l_proc,40);
1465 --
1466 -- Must exist in hr_standard_lookups where lookup_type is
1467 -- PROMPT_EDGE_ALIGNMENTS
1468 --
1469 if hr_api.not_exists_in_hrstanlookups
1470 (p_effective_date => p_effective_date
1471 ,p_lookup_type => 'PROMPT_EDGE_ALIGNMENTS'
1472 ,p_lookup_code => p_prompt_edge_alignment
1473 ) then
1474 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1475 fnd_message.set_token('PROCEDURE', l_proc);
1476 fnd_message.set_token('STEP','10');
1477 fnd_message.raise_error;
1478 end if;
1479 --
1480 end if;
1481 --
1482 end if;
1483 --
1484 hr_utility.set_location('Leaving:'||l_proc, 100);
1485 End chk_prompt_edge_alignment;
1486 --
1487 -- ----------------------------------------------------------------------------
1488 -- |-----------------------< chk_prompt_edge_offset >-------------------------|
1489 -- ----------------------------------------------------------------------------
1490 Procedure chk_prompt_edge_offset
1491 (p_effective_date in date
1492 ,p_item_property_id in number
1493 ,p_prompt_edge_offset in number
1494 ) is
1495 --
1496 l_proc varchar2(72) := g_package || 'chk_prompt_edge_offset';
1497 l_api_updating boolean;
1498 --
1499 Begin
1500 hr_utility.set_location('Entering:'||l_proc, 10);
1501 --
1502 hr_utility.set_location('Leaving:'||l_proc, 100);
1503 End chk_prompt_edge_offset;
1504 --
1505 -- ----------------------------------------------------------------------------
1506 -- |-----------------------< chk_prompt_text_alignment >----------------------|
1507 -- ----------------------------------------------------------------------------
1508 Procedure chk_prompt_text_alignment
1509 (p_effective_date in date
1510 ,p_object_version_number in number
1511 ,p_item_property_id in number
1512 ,p_prompt_text_alignment in number
1513 ) is
1514 --
1515 l_proc varchar2(72) := g_package || 'chk_prompt_text_alignment';
1516 l_api_updating boolean;
1517 --
1518 Begin
1519 hr_utility.set_location('Entering:'||l_proc, 10);
1520 --
1521 -- Check mandatory arguments have been set
1522 --
1523 hr_api.mandatory_arg_error
1524 (p_api_name => l_proc
1525 ,p_argument => 'effective_date'
1526 ,p_argument_value => p_effective_date
1527 );
1528 --
1529 l_api_updating := hr_itp_shd.api_updating
1530 (p_item_property_id => p_item_property_id
1531 ,p_object_version_number => p_object_version_number
1532 );
1533 hr_utility.set_location(l_proc,20);
1534 --
1535 -- Only proceed with SQL validation if absolutely necessary
1536 --
1537 if ( ( l_api_updating
1538 and nvl(hr_itp_shd.g_old_rec.prompt_text_alignment,hr_api.g_number) <>
1539 nvl(p_prompt_text_alignment,hr_api.g_number))
1540 or (NOT l_api_updating)) then
1541 --
1542 hr_utility.set_location(l_proc,30);
1543 --
1544 if (p_prompt_text_alignment is not null) then
1545 --
1546 hr_utility.set_location(l_proc,40);
1547 --
1548 -- Must exist in hr_standard_lookups where lookup_type is
1549 -- PROMPT_TEXT_ALIGNMENTS
1550 --
1551 if hr_api.not_exists_in_hrstanlookups
1552 (p_effective_date => p_effective_date
1553 ,p_lookup_type => 'PROMPT_TEXT_ALIGNMENTS'
1554 ,p_lookup_code => p_prompt_text_alignment
1555 ) then
1556 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1557 fnd_message.set_token('PROCEDURE', l_proc);
1558 fnd_message.set_token('STEP','10');
1559 fnd_message.raise_error;
1560 end if;
1561 --
1562 end if;
1563 --
1564 end if;
1565 --
1566 hr_utility.set_location('Leaving:'||l_proc, 100);
1567 End chk_prompt_text_alignment;
1568 --
1569 -- ----------------------------------------------------------------------------
1570 -- |--------------------------< chk_query_allowed >---------------------------|
1571 -- ----------------------------------------------------------------------------
1572 Procedure chk_query_allowed
1573 (p_effective_date in date
1574 ,p_object_version_number in number
1575 ,p_item_property_id in number
1576 ,p_query_allowed in number
1577 ) is
1578 --
1579 l_proc varchar2(72) := g_package || 'chk_query_allowed';
1580 l_api_updating boolean;
1581 --
1582 Begin
1583 hr_utility.set_location('Entering:'||l_proc, 10);
1584 --
1585 -- Check mandatory arguments have been set
1586 --
1587 hr_api.mandatory_arg_error
1588 (p_api_name => l_proc
1589 ,p_argument => 'effective_date'
1590 ,p_argument_value => p_effective_date
1591 );
1592 --
1593 l_api_updating := hr_itp_shd.api_updating
1594 (p_item_property_id => p_item_property_id
1595 ,p_object_version_number => p_object_version_number
1596 );
1597 hr_utility.set_location(l_proc,20);
1598 --
1599 -- Only proceed with SQL validation if absolutely necessary
1600 --
1601 if ( ( l_api_updating
1602 and nvl(hr_itp_shd.g_old_rec.query_allowed,hr_api.g_number) <>
1603 nvl(p_query_allowed,hr_api.g_number))
1604 or (NOT l_api_updating)) then
1605 --
1606 hr_utility.set_location(l_proc,30);
1607 --
1608 if (p_query_allowed is not null) then
1609 --
1610 hr_utility.set_location(l_proc,40);
1611 --
1612 -- Must exist in hr_standard_lookups where lookup_type is
1613 -- PROPERTY_TRUE_OR_FALSE
1614 --
1615 if hr_api.not_exists_in_hrstanlookups
1616 (p_effective_date => p_effective_date
1617 ,p_lookup_type => 'PROPERTY_TRUE_OR_FALSE'
1618 ,p_lookup_code => p_query_allowed
1619 ) then
1620 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1621 fnd_message.set_token('PROCEDURE', l_proc);
1622 fnd_message.set_token('STEP','10');
1623 fnd_message.raise_error;
1624 end if;
1625 --
1626 end if;
1627 --
1628 end if;
1629 --
1630 hr_utility.set_location('Leaving:'||l_proc, 100);
1631 End chk_query_allowed;
1632 --
1633 -- ----------------------------------------------------------------------------
1634 -- |-----------------------------< chk_required >-----------------------------|
1635 -- ----------------------------------------------------------------------------
1636 Procedure chk_required
1637 (p_effective_date in date
1638 ,p_object_version_number in number
1639 ,p_item_property_id in number
1640 ,p_required in number
1641 ) is
1642 --
1643 l_proc varchar2(72) := g_package || 'chk_required';
1644 l_api_updating boolean;
1645 --
1646 Begin
1647 hr_utility.set_location('Entering:'||l_proc, 10);
1648 --
1649 -- Check mandatory arguments have been set
1650 --
1651 hr_api.mandatory_arg_error
1652 (p_api_name => l_proc
1653 ,p_argument => 'effective_date'
1654 ,p_argument_value => p_effective_date
1655 );
1656 --
1657 l_api_updating := hr_itp_shd.api_updating
1658 (p_item_property_id => p_item_property_id
1659 ,p_object_version_number => p_object_version_number
1660 );
1661 hr_utility.set_location(l_proc,20);
1662 --
1663 -- Only proceed with SQL validation if absolutely necessary
1664 --
1665 if ( ( l_api_updating
1666 and nvl(hr_itp_shd.g_old_rec.required,hr_api.g_number) <>
1667 nvl(p_required,hr_api.g_number))
1668 or (NOT l_api_updating)) then
1669 --
1670 hr_utility.set_location(l_proc,30);
1671 --
1672 if (p_required is not null) then
1673 --
1674 hr_utility.set_location(l_proc,40);
1675 --
1676 -- Must exist in hr_standard_lookups where lookup_type is
1677 -- PROPERTY_TRUE_OR_FALSE
1678 --
1679 if hr_api.not_exists_in_hrstanlookups
1680 (p_effective_date => p_effective_date
1681 ,p_lookup_type => 'PROPERTY_TRUE_OR_FALSE'
1682 ,p_lookup_code => p_required
1683 ) then
1684 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1685 fnd_message.set_token('PROCEDURE', l_proc);
1686 fnd_message.set_token('STEP','10');
1687 fnd_message.raise_error;
1688 end if;
1689 --
1690 end if;
1691 --
1692 end if;
1693 --
1694 hr_utility.set_location('Leaving:'||l_proc, 100);
1695 End chk_required;
1696 --
1697 -- ----------------------------------------------------------------------------
1698 -- |--------------------------< chk_update_allowed >--------------------------|
1699 -- ----------------------------------------------------------------------------
1700 Procedure chk_update_allowed
1701 (p_effective_date in date
1702 ,p_object_version_number in number
1703 ,p_item_property_id in number
1704 ,p_update_allowed in number
1705 ) is
1706 --
1707 l_proc varchar2(72) := g_package || 'chk_update_allowed';
1708 l_api_updating boolean;
1709 --
1710 Begin
1711 hr_utility.set_location('Entering:'||l_proc, 10);
1712 --
1713 -- Check mandatory arguments have been set
1714 --
1715 hr_api.mandatory_arg_error
1716 (p_api_name => l_proc
1717 ,p_argument => 'effective_date'
1718 ,p_argument_value => p_effective_date
1719 );
1720 --
1721 l_api_updating := hr_itp_shd.api_updating
1722 (p_item_property_id => p_item_property_id
1723 ,p_object_version_number => p_object_version_number
1724 );
1725 hr_utility.set_location(l_proc,20);
1726 --
1727 -- Only proceed with SQL validation if absolutely necessary
1728 --
1729 if ( ( l_api_updating
1730 and nvl(hr_itp_shd.g_old_rec.update_allowed,hr_api.g_number) <>
1731 nvl(p_update_allowed,hr_api.g_number))
1732 or (NOT l_api_updating)) then
1733 --
1734 hr_utility.set_location(l_proc,30);
1735 --
1736 if (p_update_allowed is not null) then
1737 --
1738 hr_utility.set_location(l_proc,40);
1739 --
1740 -- Must exist in hr_standard_lookups where lookup_type is
1741 -- PROPERTY_TRUE_OR_FALSE
1742 --
1743 if hr_api.not_exists_in_hrstanlookups
1744 (p_effective_date => p_effective_date
1745 ,p_lookup_type => 'PROPERTY_TRUE_OR_FALSE'
1746 ,p_lookup_code => p_update_allowed
1747 ) then
1748 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1749 fnd_message.set_token('PROCEDURE', l_proc);
1750 fnd_message.set_token('STEP','10');
1751 fnd_message.raise_error;
1752 end if;
1753 --
1754 end if;
1755 --
1756 end if;
1757 --
1758 hr_utility.set_location('Leaving:'||l_proc, 100);
1759 End chk_update_allowed;
1760 --
1761 -- ----------------------------------------------------------------------------
1762 -- |----------------------< chk_validation_formula_id >-----------------------|
1763 -- ----------------------------------------------------------------------------
1764 Procedure chk_validation_formula_id
1765 (p_effective_date in date
1766 ,p_object_version_number in number
1767 ,p_item_property_id in number
1768 ,p_validation_formula_id in number
1769 ) is
1770 --
1771 cursor csr_formula is
1772 select fft.formula_type_name
1773 from ff_formula_types fft
1774 ,ff_formulas fml
1775 where fft.formula_type_id = fml.formula_type_id
1776 and fml.formula_id = p_validation_formula_id;
1777 --
1778 l_proc varchar2(72) := g_package || 'chk_validation_formula_id';
1779 l_api_updating boolean;
1780 l_formula_type_name varchar2(80);
1781 --
1782 Begin
1783 hr_utility.set_location('Entering:'||l_proc, 10);
1784 --
1785 l_api_updating := hr_itp_shd.api_updating
1786 (p_item_property_id => p_item_property_id
1787 ,p_object_version_number => p_object_version_number
1788 );
1789 hr_utility.set_location(l_proc,20);
1790 --
1791 -- Only proceed with SQL validation if absolutely necessary
1792 --
1793 if ( ( l_api_updating
1794 and nvl(hr_itp_shd.g_old_rec.validation_formula_id,hr_api.g_number) <>
1795 nvl(p_validation_formula_id,hr_api.g_number))
1796 or (NOT l_api_updating)) then
1797 --
1798 if p_validation_formula_id is not null then
1799 --
1800 -- Check formula exists
1801 --
1802 open csr_formula;
1803 fetch csr_formula into l_formula_type_name;
1804 if csr_formula%notfound then
1805 close csr_formula;
1806 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1807 fnd_message.set_token('PROCEDURE', l_proc);
1808 fnd_message.set_token('STEP','10');
1809 fnd_message.raise_error;
1810 end if;
1811 close csr_formula;
1812 --
1813 -- Check formula is of type 'Template Validation' if specified
1814 --
1815 if nvl(l_formula_type_name,hr_api.g_varchar2) <> 'Template Validation' then
1816 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1817 fnd_message.set_token('PROCEDURE', l_proc);
1818 fnd_message.set_token('STEP','20');
1819 fnd_message.raise_error;
1820 end if;
1821 --
1822 end if;
1823 --
1824 end if;
1825 --
1826 hr_utility.set_location('Leaving:'||l_proc, 100);
1827 End chk_validation_formula_id;
1828 --
1829 -- ----------------------------------------------------------------------------
1830 -- |--------------------< chk_validation_param_item_ids >---------------------|
1831 -- ----------------------------------------------------------------------------
1832 Procedure chk_validation_param_item_ids
1833 (p_effective_date in date
1834 ,p_item_property_id in number
1835 ,p_validation_formula_id in number
1836 ,p_validation_param_item_id1 in number
1837 ,p_validation_param_item_id2 in number
1838 ,p_validation_param_item_id3 in number
1839 ,p_validation_param_item_id4 in number
1840 ,p_validation_param_item_id5 in number
1841 ) is
1842 --
1843 l_proc varchar2(72) := g_package || 'chk_validation_param_item_ids';
1844 l_api_updating boolean;
1845 --
1846 Begin
1847 hr_utility.set_location('Entering:'||l_proc, 10);
1848 --
1849 -- Check item ids have only been specified if the formula has
1850 --
1851 if p_validation_formula_id is null then
1852 if ( p_validation_param_item_id1 is not null
1853 or p_validation_param_item_id2 is not null
1854 or p_validation_param_item_id3 is not null
1855 or p_validation_param_item_id4 is not null
1856 or p_validation_param_item_id5 is not null) then
1857 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1858 fnd_message.set_token('PROCEDURE', l_proc);
1859 fnd_message.set_token('STEP','10');
1860 fnd_message.raise_error;
1861 end if;
1862 end if;
1863 --
1864 hr_utility.set_location('Leaving:'||l_proc, 100);
1865 End chk_validation_param_item_ids;
1866 --
1867 -- ----------------------------------------------------------------------------
1868 -- |-----------------------------< chk_visible >------------------------------|
1869 -- ----------------------------------------------------------------------------
1870 Procedure chk_visible
1871 (p_effective_date in date
1872 ,p_object_version_number in number
1873 ,p_item_property_id in number
1874 ,p_visible in number
1875 ) is
1876 --
1877 l_proc varchar2(72) := g_package || 'chk_visible';
1878 l_api_updating boolean;
1879 --
1880 Begin
1881 hr_utility.set_location('Entering:'||l_proc, 10);
1882 --
1883 -- Check mandatory arguments have been set
1884 --
1885 hr_api.mandatory_arg_error
1886 (p_api_name => l_proc
1887 ,p_argument => 'effective_date'
1888 ,p_argument_value => p_effective_date
1889 );
1890 --
1891 l_api_updating := hr_itp_shd.api_updating
1892 (p_item_property_id => p_item_property_id
1893 ,p_object_version_number => p_object_version_number
1894 );
1895 hr_utility.set_location(l_proc,20);
1896 --
1897 -- Only proceed with SQL validation if absolutely necessary
1898 --
1899 if ( ( l_api_updating
1900 and nvl(hr_itp_shd.g_old_rec.visible,hr_api.g_number) <>
1901 nvl(p_visible,hr_api.g_number))
1902 or (NOT l_api_updating)) then
1903 --
1904 hr_utility.set_location(l_proc,30);
1905 --
1906 if (p_visible is not null) then
1907 --
1908 hr_utility.set_location(l_proc,40);
1909 --
1910 -- Must exist in hr_standard_lookups where lookup_type is
1911 -- PROPERTY_TRUE_OR_FALSE
1912 --
1913 if hr_api.not_exists_in_hrstanlookups
1914 (p_effective_date => p_effective_date
1915 ,p_lookup_type => 'PROPERTY_TRUE_OR_FALSE'
1916 ,p_lookup_code => p_visible
1917 ) then
1918 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1919 fnd_message.set_token('PROCEDURE', l_proc);
1920 fnd_message.set_token('STEP','10');
1921 fnd_message.raise_error;
1922 end if;
1923 --
1924 end if;
1925 --
1926 end if;
1927 --
1928 hr_utility.set_location('Leaving:'||l_proc, 100);
1929 End chk_visible;
1930 --
1931 -- ----------------------------------------------------------------------------
1932 -- |------------------------------< chk_width >-------------------------------|
1933 -- ----------------------------------------------------------------------------
1934 Procedure chk_width
1935 (p_effective_date in date
1936 ,p_item_property_id in number
1937 ,p_width in number
1938 ) is
1939 --
1940 l_proc varchar2(72) := g_package || 'chk_width';
1941 l_api_updating boolean;
1942 --
1943 Begin
1944 hr_utility.set_location('Entering:'||l_proc, 10);
1945 --
1946 -- Width must be greater than or equal to zero, if given
1947 --
1948 if (p_width is not null) then
1949 --
1950 hr_utility.set_location(l_proc,30);
1951 --
1952 if (p_width < 0) then
1953 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1954 fnd_message.set_token('PROCEDURE', l_proc);
1955 fnd_message.set_token('STEP','10');
1956 fnd_message.raise_error;
1957 end if;
1958 --
1959 end if;
1960 --
1961 hr_utility.set_location('Leaving:'||l_proc, 100);
1962 End chk_width;
1963 --
1964 -- ----------------------------------------------------------------------------
1965 -- |-----------------------------< chk_x_position >---------------------------|
1966 -- ----------------------------------------------------------------------------
1967 Procedure chk_x_position
1968 (p_effective_date in date
1969 ,p_item_property_id in number
1970 ,p_x_position in number
1971 ) is
1972 --
1973 l_proc varchar2(72) := g_package || 'chk_x_position';
1974 l_api_updating boolean;
1975 --
1976 Begin
1977 hr_utility.set_location('Entering:'||l_proc, 10);
1978 --
1979 -- X position must be greater than or equal to zero,if given
1980 --
1981 if (p_x_position is not null) then
1982 --
1983 hr_utility.set_location(l_proc,30);
1984 --
1985 if (p_x_position < 0) then
1986 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
1987 fnd_message.set_token('PROCEDURE', l_proc);
1988 fnd_message.set_token('STEP','10');
1989 fnd_message.raise_error;
1990 end if;
1991 --
1992 end if;
1993 --
1994 hr_utility.set_location('Leaving:'||l_proc, 100);
1995 End chk_x_position;
1996 --
1997 -- ----------------------------------------------------------------------------
1998 -- |-----------------------------< chk_y_position >---------------------------|
1999 -- ----------------------------------------------------------------------------
2000 Procedure chk_y_position
2001 (p_effective_date in date
2002 ,p_item_property_id in number
2003 ,p_y_position in number
2004 ) is
2005 --
2006 l_proc varchar2(72) := g_package || 'chk_y_position';
2007 l_api_updating boolean;
2008 --
2009 Begin
2010 hr_utility.set_location('Entering:'||l_proc, 10);
2011 --
2012 -- Y position must be greater than or equal to zero, if given
2013 --
2014 if (p_y_position is not null) then
2015 --
2016 hr_utility.set_location(l_proc,30);
2017 --
2018 if (p_y_position < 0) then
2019 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2020 fnd_message.set_token('PROCEDURE', l_proc);
2021 fnd_message.set_token('STEP','10');
2022 fnd_message.raise_error;
2023 end if;
2024 --
2025 end if;
2026 --
2027 hr_utility.set_location('Leaving:'||l_proc, 100);
2028 End chk_y_position;
2029 --
2030 -- ----------------------------------------------------------------------------
2031 -- |----------------------< chk_item_type_dependencies >----------------------|
2032 -- ----------------------------------------------------------------------------
2033 Procedure chk_item_type_dependencies
2034 (p_effective_date in date
2035 ,p_rec in hr_itp_shd.g_rec_type
2036 ) is
2037 --
2038 l_proc varchar2(72) := g_package||'chk_item_type_dependencies';
2039 l_api_updating boolean;
2040 l_item_type varchar2(30);
2041 --
2042 Begin
2043 hr_utility.set_location('Entering:'||l_proc, 10);
2044 --
2045 l_item_type := return_item_type
2046 (p_form_item_id => p_rec.form_item_id
2047 ,p_template_item_id => p_rec.template_item_id
2048 ,p_template_item_context_id => p_rec.template_item_context_id
2049 );
2050 hr_utility.set_location(l_proc,20);
2051 --
2052 if p_rec.alignment is not null then
2053 if l_item_type not in ('DISPLAY_ITEM','TEXT_ITEM') then
2054 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2055 fnd_message.set_token('PROCEDURE', l_proc);
2056 fnd_message.set_token('STEP','10');
2057 fnd_message.raise_error;
2058 end if;
2059 end if;
2060 hr_utility.set_location(l_proc,30);
2061 --
2062 if p_rec.bevel is not null then
2063 if l_item_type not in ('CHART_ITEM','USER_AREA','IMAGE','TEXT_ITEM') then
2064 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2065 fnd_message.set_token('PROCEDURE', l_proc);
2066 fnd_message.set_token('STEP','20');
2067 fnd_message.raise_error;
2068 end if;
2069 end if;
2070 hr_utility.set_location(l_proc,40);
2071 --
2072 if p_rec.case_restriction is not null then
2073 if l_item_type not in ('TEXT_ITEM') then
2074 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2075 fnd_message.set_token('PROCEDURE', l_proc);
2076 fnd_message.set_token('STEP','30');
2077 fnd_message.raise_error;
2078 end if;
2079 end if;
2080 hr_utility.set_location(l_proc,50);
2081 --
2082 if p_rec.enabled is not null then
2083 if l_item_type not in ('BUTTON','CHECKBOX','IMAGE','LIST','OLE_OBJECT','RADIO_BUTTON','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2084 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2085 fnd_message.set_token('PROCEDURE', l_proc);
2086 fnd_message.set_token('STEP','40');
2087 fnd_message.raise_error;
2088 end if;
2089 end if;
2090 hr_utility.set_location(l_proc,60);
2091 --
2092 if p_rec.format_mask is not null then
2093 if l_item_type not in ('TEXT_ITEM') then
2094 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2095 fnd_message.set_token('PROCEDURE', l_proc);
2096 fnd_message.set_token('STEP','50');
2097 fnd_message.raise_error;
2098 end if;
2099 end if;
2100 hr_utility.set_location(l_proc,70);
2101 --
2102 if p_rec.height is not null then
2103 if l_item_type not in ('BUTTON','CHART_ITEM','CHECKBOX','DISPLAY_ITEM','IMAGE','LIST','OLE_OBJECT','RADIO_BUTTON','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2104 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2105 fnd_message.set_token('PROCEDURE', l_proc);
2106 fnd_message.set_token('STEP','53');
2107 fnd_message.raise_error;
2108 end if;
2109 end if;
2110 hr_utility.set_location(l_proc,73);
2111 --
2112 if p_rec.information_formula_id is not null then
2113 if l_item_type not in ('BUTTON','CHART_ITEM','CHECKBOX','DISPLAY_ITEM','IMAGE','LIST','OLE_OBJECT','RADIO_BUTTON','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2114 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2115 fnd_message.set_token('PROCEDURE', l_proc);
2116 fnd_message.set_token('STEP','56');
2117 fnd_message.raise_error;
2118 end if;
2119 end if;
2120 hr_utility.set_location(l_proc,76);
2121 --
2122 if p_rec.insert_allowed is not null then
2123 if l_item_type not in ('CHECKBOX','IMAGE','LIST','RADIO_BUTTON','TEXT_ITEM') then
2124 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2125 fnd_message.set_token('PROCEDURE', l_proc);
2126 fnd_message.set_token('STEP','60');
2127 fnd_message.raise_error;
2128 end if;
2129 end if;
2130 hr_utility.set_location(l_proc,80);
2131 --
2132 if p_rec.next_navigation_item_id is not null then
2133 if l_item_type not in ('BUTTON','CHECKBOX','IMAGE','LIST','OLE_OBJECT','RADIO_BUTTON','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2134 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2135 fnd_message.set_token('PROCEDURE', l_proc);
2136 fnd_message.set_token('STEP','61');
2137 fnd_message.raise_error;
2138 end if;
2139 end if;
2140 hr_utility.set_location(l_proc,81);
2141 --
2142 if p_rec.previous_navigation_item_id is not null then
2143 if l_item_type not in ('BUTTON','CHECKBOX','IMAGE','LIST','OLE_OBJECT','RADIO_BUTTON','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2144 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2145 fnd_message.set_token('PROCEDURE', l_proc);
2146 fnd_message.set_token('STEP','62');
2147 fnd_message.raise_error;
2148 end if;
2149 end if;
2150 hr_utility.set_location(l_proc,82);
2151 --
2152 if p_rec.prompt_alignment_offset is not null then
2153 if l_item_type not in ('BUTTON','CHART_ITEM','CHECKBOX','DISPLAY_ITEM','IMAGE','LIST','OLE_OBJECT','RADIO_BUTTON','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2154 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2155 fnd_message.set_token('PROCEDURE', l_proc);
2156 fnd_message.set_token('STEP','63');
2157 fnd_message.raise_error;
2158 end if;
2159 end if;
2160 hr_utility.set_location(l_proc,83);
2161 --
2162 if p_rec.prompt_display_style is not null then
2163 if l_item_type not in ('BUTTON','CHART_ITEM','CHECKBOX','DISPLAY_ITEM','IMAGE','LIST','OLE_OBJECT','RADIO_BUTTON','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2164 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2165 fnd_message.set_token('PROCEDURE', l_proc);
2166 fnd_message.set_token('STEP','64');
2167 fnd_message.raise_error;
2168 end if;
2169 end if;
2170 hr_utility.set_location(l_proc,84);
2171 --
2172 if p_rec.prompt_edge is not null then
2173 if l_item_type not in ('BUTTON','CHART_ITEM','CHECKBOX','DISPLAY_ITEM','IMAGE','LIST','OLE_OBJECT','RADIO_BUTTON','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2174 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2175 fnd_message.set_token('PROCEDURE', l_proc);
2176 fnd_message.set_token('STEP','65');
2177 fnd_message.raise_error;
2178 end if;
2179 end if;
2180 hr_utility.set_location(l_proc,85);
2181 --
2182 if p_rec.prompt_edge_alignment is not null then
2183 if l_item_type not in ('BUTTON','CHART_ITEM','CHECKBOX','DISPLAY_ITEM','IMAGE','LIST','OLE_OBJECT','RADIO_BUTTON','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2184 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2185 fnd_message.set_token('PROCEDURE', l_proc);
2186 fnd_message.set_token('STEP','66');
2187 fnd_message.raise_error;
2188 end if;
2189 end if;
2190 hr_utility.set_location(l_proc,86);
2191 --
2192 if p_rec.prompt_edge_offset is not null then
2193 if l_item_type not in ('BUTTON','CHART_ITEM','CHECKBOX','DISPLAY_ITEM','IMAGE','LIST','OLE_OBJECT','RADIO_BUTTON','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2194 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2195 fnd_message.set_token('PROCEDURE', l_proc);
2196 fnd_message.set_token('STEP','67');
2197 fnd_message.raise_error;
2198 end if;
2199 end if;
2200 hr_utility.set_location(l_proc,87);
2201 --
2202 if p_rec.prompt_text_alignment is not null then
2203 if l_item_type not in ('BUTTON','CHART_ITEM','CHECKBOX','DISPLAY_ITEM','IMAGE','LIST','OLE_OBJECT','RADIO_BUTTON','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2204 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2205 fnd_message.set_token('PROCEDURE', l_proc);
2206 fnd_message.set_token('STEP','68');
2207 fnd_message.raise_error;
2208 end if;
2209 end if;
2210 hr_utility.set_location(l_proc,88);
2211 --
2212 if p_rec.query_allowed is not null then
2213 if l_item_type not in ('CHECKBOX','DISPLAY_ITEM','LIST','OLE_OBJECT','RADIO_BUTTON','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2214 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2215 fnd_message.set_token('PROCEDURE', l_proc);
2216 fnd_message.set_token('STEP','70');
2217 fnd_message.raise_error;
2218 end if;
2219 end if;
2220 hr_utility.set_location(l_proc,90);
2221 --
2222 if p_rec.required is not null then
2223 if l_item_type not in ('CHECKBOX','LIST','TEXT_ITEM') then
2224 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2225 fnd_message.set_token('PROCEDURE', l_proc);
2226 fnd_message.set_token('STEP','80');
2227 fnd_message.raise_error;
2228 end if;
2229 end if;
2230 hr_utility.set_location(l_proc,100);
2231 --
2232 if p_rec.update_allowed is not null then
2233 if l_item_type not in ('CHECKBOX','DISPLAY_ITEM','LIST','OLE_OBJECT','RADIO_BUTTON','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2234 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2235 fnd_message.set_token('PROCEDURE', l_proc);
2236 fnd_message.set_token('STEP','90');
2237 fnd_message.raise_error;
2238 end if;
2239 end if;
2240 hr_utility.set_location(l_proc,110);
2241 --
2242 if p_rec.validation_formula_id is not null then
2243 if l_item_type not in ('CHECKBOX','DISPLAY_ITEM','LIST','OLE_OBJECT','RADIO_BUTTON','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2244 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2245 fnd_message.set_token('PROCEDURE', l_proc);
2246 fnd_message.set_token('STEP','100');
2247 fnd_message.raise_error;
2248 end if;
2249 end if;
2250 hr_utility.set_location(l_proc,120);
2251 --
2252 if p_rec.visible is not null then
2253 if l_item_type not in ('BUTTON','CHART_ITEM','CHECKBOX','DISPLAY_ITEM','IMAGE','LIST','OLE_OBJECT','RADIO_BUTTON','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2254 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2255 fnd_message.set_token('PROCEDURE', l_proc);
2256 fnd_message.set_token('STEP','110');
2257 fnd_message.raise_error;
2258 end if;
2259 end if;
2260 hr_utility.set_location(l_proc,130);
2261 --
2262 if p_rec.width is not null then
2263 if l_item_type not in ('BUTTON','CHART_ITEM','CHECKBOX','DISPLAY_ITEM','IMAGE','LIST','OLE_OBJECT','RADIO_BUTTON','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2264 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2265 fnd_message.set_token('PROCEDURE', l_proc);
2266 fnd_message.set_token('STEP','120');
2267 fnd_message.raise_error;
2268 end if;
2269 end if;
2270 hr_utility.set_location(l_proc,140);
2271 --
2272 if p_rec.x_position is not null then
2273 if l_item_type not in ('BUTTON','CHART_ITEM','CHECKBOX','DISPLAY_ITEM','IMAGE','LIST','OLE_OBJECT','RADIO_BUTTON','SCROLLBAR','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2274 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2275 fnd_message.set_token('PROCEDURE', l_proc);
2276 fnd_message.set_token('STEP','130');
2277 fnd_message.raise_error;
2278 end if;
2279 end if;
2280 hr_utility.set_location(l_proc,150);
2281 --
2282 if p_rec.y_position is not null then
2283 if l_item_type not in ('BUTTON','CHART_ITEM','CHECKBOX','DISPLAY_ITEM','IMAGE','LIST','OLE_OBJECT','RADIO_BUTTON','SCROLLBAR','TEXT_ITEM','USER_AREA','VBX_CONTROL') then
2284 fnd_message.set_name('PAY', 'HR_6153_ALL_PROCEDURE_FAIL');
2285 fnd_message.set_token('PROCEDURE', l_proc);
2286 fnd_message.set_token('STEP','140');
2287 fnd_message.raise_error;
2288 end if;
2289 end if;
2290 hr_utility.set_location(l_proc,160);
2291 --
2292 hr_utility.set_location('Leaving:'||l_proc, 1000);
2293 End chk_item_type_dependencies;
2294 --
2295 -- ----------------------------------------------------------------------------
2296 -- |------------------------------< chk_delete >------------------------------|
2297 -- ----------------------------------------------------------------------------
2298 Procedure chk_delete
2299 (p_rec in hr_itp_shd.g_rec_type
2300 ) is
2301 --
2302 l_proc varchar2(72) := g_package||'chk_delete';
2303 --
2304 Begin
2305 hr_utility.set_location('Entering:'||l_proc, 5);
2306 --
2307 -- No additional validation required
2308 --
2309 null;
2310 --
2311 hr_utility.set_location(' Leaving:'||l_proc, 10);
2312 End chk_delete;
2313 --
2314 -- ----------------------------------------------------------------------------
2315 -- |---------------------------< insert_validate >----------------------------|
2316 -- ----------------------------------------------------------------------------
2317 Procedure insert_validate
2318 (p_effective_date in date
2319 ,p_rec in hr_itp_shd.g_rec_type
2320 ) is
2321 --
2322 l_proc varchar2(72) := g_package||'insert_validate';
2323 --
2324 Begin
2325 hr_utility.set_location('Entering:'||l_proc, 5);
2326 --
2327 -- Call all supporting business operations
2328 -- No business group context. HR_STANDARD_LOOKUPS used for validation.
2329 --
2330 chk_form_template_and_context
2331 (p_effective_date => p_effective_date
2332 ,p_item_property_id => p_rec.item_property_id
2333 ,p_form_item_id => p_rec.form_item_id
2334 ,p_template_item_id => p_rec.template_item_id
2335 ,p_template_item_context_id => p_rec.template_item_context_id
2336 );
2337 --
2338 chk_form_item_id
2339 (p_effective_date => p_effective_date
2340 ,p_item_property_id => p_rec.item_property_id
2341 ,p_form_item_id => p_rec.form_item_id
2342 );
2343 --
2344 chk_template_item_id
2345 (p_effective_date => p_effective_date
2346 ,p_item_property_id => p_rec.item_property_id
2347 ,p_template_item_id => p_rec.template_item_id
2348 );
2349 --
2350 chk_template_item_context_id
2351 (p_effective_date => p_effective_date
2352 ,p_item_property_id => p_rec.item_property_id
2353 ,p_template_item_context_id => p_rec.template_item_context_id
2354 );
2355 --
2356 chk_alignment
2357 (p_effective_date => p_effective_date
2358 ,p_object_version_number => p_rec.object_version_number
2359 ,p_item_property_id => p_rec.item_property_id
2360 ,p_alignment => p_rec.alignment
2361 );
2362 --
2363 chk_bevel
2364 (p_effective_date => p_effective_date
2365 ,p_object_version_number => p_rec.object_version_number
2366 ,p_item_property_id => p_rec.item_property_id
2367 ,p_bevel => p_rec.bevel
2368 );
2369 --
2370 chk_case_restriction
2371 (p_effective_date => p_effective_date
2372 ,p_object_version_number => p_rec.object_version_number
2373 ,p_item_property_id => p_rec.item_property_id
2374 ,p_case_restriction => p_rec.case_restriction
2375 );
2376 --
2377 chk_enabled
2378 (p_effective_date => p_effective_date
2379 ,p_object_version_number => p_rec.object_version_number
2380 ,p_item_property_id => p_rec.item_property_id
2381 ,p_enabled => p_rec.enabled
2382 );
2383 --
2384 chk_format_mask
2385 (p_effective_date => p_effective_date
2386 ,p_item_property_id => p_rec.item_property_id
2387 ,p_format_mask => p_rec.format_mask
2388 );
2389 --
2390 chk_height
2391 (p_effective_date => p_effective_date
2392 ,p_item_property_id => p_rec.item_property_id
2393 ,p_height => p_rec.height
2394 );
2395 --
2396 chk_information_formula_id
2397 (p_effective_date => p_effective_date
2398 ,p_object_version_number => p_rec.object_version_number
2399 ,p_item_property_id => p_rec.item_property_id
2400 ,p_information_formula_id => p_rec.information_formula_id
2401 );
2402 --
2403 chk_information_param_item_ids
2404 (p_effective_date => p_effective_date
2405 ,p_item_property_id => p_rec.item_property_id
2406 ,p_information_formula_id => p_rec.information_formula_id
2407 ,p_information_param_item_id1 => p_rec.information_parameter_item_id1
2408 ,p_information_param_item_id2 => p_rec.information_parameter_item_id2
2409 ,p_information_param_item_id3 => p_rec.information_parameter_item_id3
2410 ,p_information_param_item_id4 => p_rec.information_parameter_item_id4
2411 ,p_information_param_item_id5 => p_rec.information_parameter_item_id5
2412 );
2413 --
2414 chk_insert_allowed
2415 (p_effective_date => p_effective_date
2416 ,p_object_version_number => p_rec.object_version_number
2417 ,p_item_property_id => p_rec.item_property_id
2418 ,p_insert_allowed => p_rec.insert_allowed
2419 );
2420 --
2421 chk_prompt_alignment_offset
2422 (p_effective_date => p_effective_date
2423 ,p_item_property_id => p_rec.item_property_id
2424 ,p_prompt_alignment_offset => p_rec.prompt_alignment_offset
2425 );
2426 --
2427 chk_prompt_display_style
2428 (p_effective_date => p_effective_date
2429 ,p_object_version_number => p_rec.object_version_number
2430 ,p_item_property_id => p_rec.item_property_id
2431 ,p_prompt_display_style => p_rec.prompt_display_style
2432 );
2433 --
2434 chk_prompt_edge
2435 (p_effective_date => p_effective_date
2436 ,p_object_version_number => p_rec.object_version_number
2437 ,p_item_property_id => p_rec.item_property_id
2438 ,p_prompt_edge => p_rec.prompt_edge
2439 );
2440 --
2441 chk_prompt_edge_alignment
2442 (p_effective_date => p_effective_date
2443 ,p_object_version_number => p_rec.object_version_number
2444 ,p_item_property_id => p_rec.item_property_id
2445 ,p_prompt_edge_alignment => p_rec.prompt_edge_alignment
2446 );
2447 --
2448 chk_prompt_edge_offset
2449 (p_effective_date => p_effective_date
2450 ,p_item_property_id => p_rec.item_property_id
2451 ,p_prompt_edge_offset => p_rec.prompt_edge_offset
2452 );
2453 --
2454 chk_prompt_text_alignment
2455 (p_effective_date => p_effective_date
2456 ,p_object_version_number => p_rec.object_version_number
2457 ,p_item_property_id => p_rec.item_property_id
2458 ,p_prompt_text_alignment => p_rec.prompt_text_alignment
2459 );
2460 --
2461 chk_query_allowed
2462 (p_effective_date => p_effective_date
2463 ,p_object_version_number => p_rec.object_version_number
2464 ,p_item_property_id => p_rec.item_property_id
2465 ,p_query_allowed => p_rec.query_allowed
2466 );
2467 --
2468 chk_required
2469 (p_effective_date => p_effective_date
2470 ,p_object_version_number => p_rec.object_version_number
2471 ,p_item_property_id => p_rec.item_property_id
2472 ,p_required => p_rec.required
2473 );
2474 --
2475 chk_update_allowed
2476 (p_effective_date => p_effective_date
2477 ,p_object_version_number => p_rec.object_version_number
2478 ,p_item_property_id => p_rec.item_property_id
2479 ,p_update_allowed => p_rec.update_allowed
2480 );
2481 --
2482 chk_validation_formula_id
2483 (p_effective_date => p_effective_date
2484 ,p_object_version_number => p_rec.object_version_number
2485 ,p_item_property_id => p_rec.item_property_id
2486 ,p_validation_formula_id => p_rec.validation_formula_id
2487 );
2488 --
2489 chk_validation_param_item_ids
2490 (p_effective_date => p_effective_date
2491 ,p_item_property_id => p_rec.item_property_id
2492 ,p_validation_formula_id => p_rec.validation_formula_id
2493 ,p_validation_param_item_id1 => p_rec.validation_parameter_item_id1
2494 ,p_validation_param_item_id2 => p_rec.validation_parameter_item_id2
2495 ,p_validation_param_item_id3 => p_rec.validation_parameter_item_id3
2496 ,p_validation_param_item_id4 => p_rec.validation_parameter_item_id4
2497 ,p_validation_param_item_id5 => p_rec.validation_parameter_item_id5
2498 );
2499 --
2500 chk_visible
2501 (p_effective_date => p_effective_date
2502 ,p_object_version_number => p_rec.object_version_number
2503 ,p_item_property_id => p_rec.item_property_id
2504 ,p_visible => p_rec.visible
2505 );
2506 --
2507 chk_width
2508 (p_effective_date => p_effective_date
2509 ,p_item_property_id => p_rec.item_property_id
2510 ,p_width => p_rec.width
2511 );
2512 --
2513 chk_x_position
2514 (p_effective_date => p_effective_date
2515 ,p_item_property_id => p_rec.item_property_id
2516 ,p_x_position => p_rec.x_position
2517 );
2518 --
2519 chk_y_position
2520 (p_effective_date => p_effective_date
2521 ,p_item_property_id => p_rec.item_property_id
2522 ,p_y_position => p_rec.y_position
2523 );
2524 --
2525 chk_item_type_dependencies
2526 (p_effective_date => p_effective_date
2527 ,p_rec => p_rec
2528 );
2529 --
2530 chk_prev_and_next_nav_item
2531 (p_effective_date => p_effective_date
2532 ,p_item_property_id => p_rec.item_property_id
2533 ,p_form_item_id => p_rec.form_item_id
2534 ,p_template_item_id => p_rec.template_item_id
2535 ,p_template_item_context_id => p_rec.template_item_context_id
2536 ,p_previous_navigation_item_id => p_rec.previous_navigation_item_id
2537 ,p_next_navigation_item_id => p_rec.next_navigation_item_id
2538 );
2539 --
2540 chk_ddf
2541 (p_rec => p_rec
2542 );
2543 --
2544 hr_utility.set_location(' Leaving:'||l_proc, 10);
2545 End insert_validate;
2546 --
2547 -- ----------------------------------------------------------------------------
2548 -- |---------------------------< update_validate >----------------------------|
2549 -- ----------------------------------------------------------------------------
2550 Procedure update_validate
2551 (p_effective_date in date
2552 ,p_rec in hr_itp_shd.g_rec_type
2553 ) is
2554 --
2555 l_proc varchar2(72) := g_package||'update_validate';
2556 --
2557 Begin
2558 hr_utility.set_location('Entering:'||l_proc, 5);
2559 --
2560 -- Call all supporting business operations
2561 -- No business group context. HR_STANDARD_LOOKUPS used for validation.
2562 --
2563 chk_non_updateable_args
2564 (p_effective_date => p_effective_date
2565 ,p_rec => p_rec
2566 );
2567 --
2568 chk_form_template_and_context
2569 (p_effective_date => p_effective_date
2570 ,p_item_property_id => p_rec.item_property_id
2571 ,p_form_item_id => p_rec.form_item_id
2572 ,p_template_item_id => p_rec.template_item_id
2573 ,p_template_item_context_id => p_rec.template_item_context_id
2574 );
2575 --
2576 chk_form_item_id
2577 (p_effective_date => p_effective_date
2578 ,p_item_property_id => p_rec.item_property_id
2579 ,p_form_item_id => p_rec.form_item_id
2580 );
2581 --
2582 chk_template_item_id
2583 (p_effective_date => p_effective_date
2584 ,p_item_property_id => p_rec.item_property_id
2585 ,p_template_item_id => p_rec.template_item_id
2586 );
2587 --
2588 chk_template_item_context_id
2589 (p_effective_date => p_effective_date
2590 ,p_item_property_id => p_rec.item_property_id
2591 ,p_template_item_context_id => p_rec.template_item_context_id
2592 );
2593 --
2594 chk_alignment
2595 (p_effective_date => p_effective_date
2596 ,p_object_version_number => p_rec.object_version_number
2597 ,p_item_property_id => p_rec.item_property_id
2598 ,p_alignment => p_rec.alignment
2599 );
2600 --
2601 chk_bevel
2602 (p_effective_date => p_effective_date
2603 ,p_object_version_number => p_rec.object_version_number
2604 ,p_item_property_id => p_rec.item_property_id
2605 ,p_bevel => p_rec.bevel
2606 );
2607 --
2608 chk_case_restriction
2609 (p_effective_date => p_effective_date
2610 ,p_object_version_number => p_rec.object_version_number
2611 ,p_item_property_id => p_rec.item_property_id
2612 ,p_case_restriction => p_rec.case_restriction
2613 );
2614 --
2615 chk_enabled
2616 (p_effective_date => p_effective_date
2617 ,p_object_version_number => p_rec.object_version_number
2618 ,p_item_property_id => p_rec.item_property_id
2619 ,p_enabled => p_rec.enabled
2620 );
2621 --
2622 chk_format_mask
2623 (p_effective_date => p_effective_date
2624 ,p_item_property_id => p_rec.item_property_id
2625 ,p_format_mask => p_rec.format_mask
2626 );
2627 --
2628 chk_height
2629 (p_effective_date => p_effective_date
2630 ,p_item_property_id => p_rec.item_property_id
2631 ,p_height => p_rec.height
2632 );
2633 --
2634 chk_information_formula_id
2635 (p_effective_date => p_effective_date
2636 ,p_object_version_number => p_rec.object_version_number
2637 ,p_item_property_id => p_rec.item_property_id
2638 ,p_information_formula_id => p_rec.information_formula_id
2639 );
2640 --
2641 chk_information_param_item_ids
2642 (p_effective_date => p_effective_date
2643 ,p_item_property_id => p_rec.item_property_id
2644 ,p_information_formula_id => p_rec.information_formula_id
2645 ,p_information_param_item_id1 => p_rec.information_parameter_item_id1
2646 ,p_information_param_item_id2 => p_rec.information_parameter_item_id2
2647 ,p_information_param_item_id3 => p_rec.information_parameter_item_id3
2648 ,p_information_param_item_id4 => p_rec.information_parameter_item_id4
2649 ,p_information_param_item_id5 => p_rec.information_parameter_item_id5
2650 );
2651 --
2652 chk_insert_allowed
2653 (p_effective_date => p_effective_date
2654 ,p_object_version_number => p_rec.object_version_number
2655 ,p_item_property_id => p_rec.item_property_id
2656 ,p_insert_allowed => p_rec.insert_allowed
2657 );
2658 --
2659 chk_prompt_alignment_offset
2660 (p_effective_date => p_effective_date
2661 ,p_item_property_id => p_rec.item_property_id
2662 ,p_prompt_alignment_offset => p_rec.prompt_alignment_offset
2663 );
2664 --
2665 chk_prompt_display_style
2666 (p_effective_date => p_effective_date
2667 ,p_object_version_number => p_rec.object_version_number
2668 ,p_item_property_id => p_rec.item_property_id
2669 ,p_prompt_display_style => p_rec.prompt_display_style
2670 );
2671 --
2672 chk_prompt_edge
2673 (p_effective_date => p_effective_date
2674 ,p_object_version_number => p_rec.object_version_number
2675 ,p_item_property_id => p_rec.item_property_id
2676 ,p_prompt_edge => p_rec.prompt_edge
2677 );
2678 --
2679 chk_prompt_edge_alignment
2680 (p_effective_date => p_effective_date
2681 ,p_object_version_number => p_rec.object_version_number
2682 ,p_item_property_id => p_rec.item_property_id
2683 ,p_prompt_edge_alignment => p_rec.prompt_edge_alignment
2684 );
2685 --
2686 chk_prompt_edge_offset
2687 (p_effective_date => p_effective_date
2688 ,p_item_property_id => p_rec.item_property_id
2689 ,p_prompt_edge_offset => p_rec.prompt_edge_offset
2690 );
2691 --
2692 chk_prompt_text_alignment
2693 (p_effective_date => p_effective_date
2694 ,p_object_version_number => p_rec.object_version_number
2695 ,p_item_property_id => p_rec.item_property_id
2696 ,p_prompt_text_alignment => p_rec.prompt_text_alignment
2697 );
2698 --
2699 chk_query_allowed
2700 (p_effective_date => p_effective_date
2701 ,p_object_version_number => p_rec.object_version_number
2702 ,p_item_property_id => p_rec.item_property_id
2703 ,p_query_allowed => p_rec.query_allowed
2704 );
2705 --
2706 chk_required
2707 (p_effective_date => p_effective_date
2708 ,p_object_version_number => p_rec.object_version_number
2709 ,p_item_property_id => p_rec.item_property_id
2710 ,p_required => p_rec.required
2711 );
2712 --
2713 chk_update_allowed
2714 (p_effective_date => p_effective_date
2715 ,p_object_version_number => p_rec.object_version_number
2716 ,p_item_property_id => p_rec.item_property_id
2717 ,p_update_allowed => p_rec.update_allowed
2718 );
2719 --
2720 chk_validation_formula_id
2721 (p_effective_date => p_effective_date
2722 ,p_object_version_number => p_rec.object_version_number
2723 ,p_item_property_id => p_rec.item_property_id
2724 ,p_validation_formula_id => p_rec.validation_formula_id
2725 );
2726 --
2727 chk_validation_param_item_ids
2728 (p_effective_date => p_effective_date
2729 ,p_item_property_id => p_rec.item_property_id
2730 ,p_validation_formula_id => p_rec.validation_formula_id
2731 ,p_validation_param_item_id1 => p_rec.validation_parameter_item_id1
2732 ,p_validation_param_item_id2 => p_rec.validation_parameter_item_id2
2733 ,p_validation_param_item_id3 => p_rec.validation_parameter_item_id3
2734 ,p_validation_param_item_id4 => p_rec.validation_parameter_item_id4
2735 ,p_validation_param_item_id5 => p_rec.validation_parameter_item_id5
2736 );
2737 --
2738 chk_visible
2739 (p_effective_date => p_effective_date
2740 ,p_object_version_number => p_rec.object_version_number
2741 ,p_item_property_id => p_rec.item_property_id
2742 ,p_visible => p_rec.visible
2743 );
2744 --
2745 chk_width
2746 (p_effective_date => p_effective_date
2747 ,p_item_property_id => p_rec.item_property_id
2748 ,p_width => p_rec.width
2749 );
2750 --
2751 chk_x_position
2752 (p_effective_date => p_effective_date
2753 ,p_item_property_id => p_rec.item_property_id
2754 ,p_x_position => p_rec.x_position
2755 );
2756 --
2757 chk_y_position
2758 (p_effective_date => p_effective_date
2759 ,p_item_property_id => p_rec.item_property_id
2760 ,p_y_position => p_rec.y_position
2761 );
2762 --
2763 chk_item_type_dependencies
2764 (p_effective_date => p_effective_date
2765 ,p_rec => p_rec
2766 );
2767 --
2768 chk_prev_and_next_nav_item
2769 (p_effective_date => p_effective_date
2770 ,p_item_property_id => p_rec.item_property_id
2771 ,p_form_item_id => p_rec.form_item_id
2772 ,p_template_item_id => p_rec.template_item_id
2773 ,p_template_item_context_id => p_rec.template_item_context_id
2774 ,p_previous_navigation_item_id => p_rec.previous_navigation_item_id
2775 ,p_next_navigation_item_id => p_rec.next_navigation_item_id
2776 );
2777 --
2778 chk_ddf
2779 (p_rec => p_rec
2780 );
2781 --
2782 hr_utility.set_location(' Leaving:'||l_proc, 10);
2783 End update_validate;
2784 --
2785 -- ----------------------------------------------------------------------------
2786 -- |---------------------------< delete_validate >----------------------------|
2787 -- ----------------------------------------------------------------------------
2788 Procedure delete_validate
2789 (p_rec in hr_itp_shd.g_rec_type
2790 ) is
2791 --
2792 l_proc varchar2(72) := g_package||'delete_validate';
2793 --
2794 Begin
2795 hr_utility.set_location('Entering:'||l_proc, 5);
2796 --
2797 -- Call all supporting business operations
2798 --
2799 chk_delete
2800 (p_rec => p_rec
2801 );
2802 --
2803 hr_utility.set_location(' Leaving:'||l_proc, 10);
2804 End delete_validate;
2805 --
2806 end hr_itp_bus;