[Home] [Help]
PACKAGE BODY: APPS.BEN_ELIG_ANTHR_PL_PRTE_API
Source
1 Package Body ben_ELIG_ANTHR_PL_PRTE_api as
2 /* $Header: beeopapi.pkb 115.1 2002/12/16 17:36:54 glingapp noship $ */
3 --
4 -- Package Variables
5 --
6 g_package varchar2(33) := ' ben_ELIG_ANTHR_PL_PRTE_api.';
7 --
8 -- ----------------------------------------------------------------------------
9 -- |------------------------< create_ELIG_ANTHR_PL_PRTE >----------------------|
10 -- ----------------------------------------------------------------------------
11 --
12 procedure create_ELIG_ANTHR_PL_PRTE
13 (p_validate in boolean default false
14 ,p_ELIG_ANTHR_PL_PRTE_id out nocopy number
15 ,p_effective_start_date out nocopy date
16 ,p_effective_end_date out nocopy date
17 ,p_excld_flag in varchar2 default null
18 ,p_ordr_num in number default null
19 ,p_pl_id in number default null
20 ,p_eligy_prfl_id in number default null
21 ,p_business_group_id in number default null
22 ,p_eop_attribute_category in varchar2 default null
23 ,p_eop_attribute1 in varchar2 default null
24 ,p_eop_attribute2 in varchar2 default null
25 ,p_eop_attribute3 in varchar2 default null
26 ,p_eop_attribute4 in varchar2 default null
27 ,p_eop_attribute5 in varchar2 default null
28 ,p_eop_attribute6 in varchar2 default null
29 ,p_eop_attribute7 in varchar2 default null
30 ,p_eop_attribute8 in varchar2 default null
31 ,p_eop_attribute9 in varchar2 default null
32 ,p_eop_attribute10 in varchar2 default null
33 ,p_eop_attribute11 in varchar2 default null
34 ,p_eop_attribute12 in varchar2 default null
35 ,p_eop_attribute13 in varchar2 default null
36 ,p_eop_attribute14 in varchar2 default null
37 ,p_eop_attribute15 in varchar2 default null
38 ,p_eop_attribute16 in varchar2 default null
39 ,p_eop_attribute17 in varchar2 default null
40 ,p_eop_attribute18 in varchar2 default null
41 ,p_eop_attribute19 in varchar2 default null
42 ,p_eop_attribute20 in varchar2 default null
43 ,p_eop_attribute21 in varchar2 default null
44 ,p_eop_attribute22 in varchar2 default null
45 ,p_eop_attribute23 in varchar2 default null
46 ,p_eop_attribute24 in varchar2 default null
47 ,p_eop_attribute25 in varchar2 default null
48 ,p_eop_attribute26 in varchar2 default null
49 ,p_eop_attribute27 in varchar2 default null
50 ,p_eop_attribute28 in varchar2 default null
51 ,p_eop_attribute29 in varchar2 default null
52 ,p_eop_attribute30 in varchar2 default null
53 ,p_object_version_number out nocopy number
54 ,p_effective_date in date
55 ) is
56 --
57 -- Declare cursors and local variables
58 --
59 l_ELIG_ANTHR_PL_PRTE_id ben_ELIG_ANTHR_PL_PRTE_f.ELIG_ANTHR_PL_PRTE_id%TYPE;
60 l_effective_start_date ben_ELIG_ANTHR_PL_PRTE_f.effective_start_date%TYPE;
61 l_effective_end_date ben_ELIG_ANTHR_PL_PRTE_f.effective_end_date%TYPE;
62 l_proc varchar2(72) := g_package||'create_ELIG_ANTHR_PL_PRTE';
63 l_object_version_number ben_ELIG_ANTHR_PL_PRTE_f.object_version_number%TYPE;
64 --
65 begin
66 --
67 hr_utility.set_location('Entering:'|| l_proc, 10);
68 --
69 -- Issue a savepoint if operating in validation only mode
70 --
71 savepoint create_ELIG_ANTHR_PL_PRTE;
72 --
73 hr_utility.set_location(l_proc, 20);
74 --
75 -- Process Logic
76 --
77 begin
78 --
79 -- Start of API User Hook for the before hook of create_ELIG_ANTHR_PL_PRTE
80 --
81 ben_ELIG_ANTHR_PL_PRTE_bk1.create_ELIG_ANTHR_PL_PRTE_b
82 (
83 p_excld_flag => p_excld_flag
84 ,p_ordr_num => p_ordr_num
85 ,p_pl_id => p_pl_id
86 ,p_eligy_prfl_id => p_eligy_prfl_id
87 ,p_business_group_id => p_business_group_id
88 ,p_eop_attribute_category => p_eop_attribute_category
89 ,p_eop_attribute1 => p_eop_attribute1
90 ,p_eop_attribute2 => p_eop_attribute2
91 ,p_eop_attribute3 => p_eop_attribute3
92 ,p_eop_attribute4 => p_eop_attribute4
93 ,p_eop_attribute5 => p_eop_attribute5
94 ,p_eop_attribute6 => p_eop_attribute6
95 ,p_eop_attribute7 => p_eop_attribute7
96 ,p_eop_attribute8 => p_eop_attribute8
97 ,p_eop_attribute9 => p_eop_attribute9
98 ,p_eop_attribute10 => p_eop_attribute10
99 ,p_eop_attribute11 => p_eop_attribute11
100 ,p_eop_attribute12 => p_eop_attribute12
101 ,p_eop_attribute13 => p_eop_attribute13
102 ,p_eop_attribute14 => p_eop_attribute14
103 ,p_eop_attribute15 => p_eop_attribute15
104 ,p_eop_attribute16 => p_eop_attribute16
105 ,p_eop_attribute17 => p_eop_attribute17
106 ,p_eop_attribute18 => p_eop_attribute18
107 ,p_eop_attribute19 => p_eop_attribute19
108 ,p_eop_attribute20 => p_eop_attribute20
109 ,p_eop_attribute21 => p_eop_attribute21
110 ,p_eop_attribute22 => p_eop_attribute22
111 ,p_eop_attribute23 => p_eop_attribute23
112 ,p_eop_attribute24 => p_eop_attribute24
113 ,p_eop_attribute25 => p_eop_attribute25
114 ,p_eop_attribute26 => p_eop_attribute26
115 ,p_eop_attribute27 => p_eop_attribute27
116 ,p_eop_attribute28 => p_eop_attribute28
117 ,p_eop_attribute29 => p_eop_attribute29
118 ,p_eop_attribute30 => p_eop_attribute30
119 ,p_effective_date => trunc(p_effective_date)
120 );
121 exception
122 when hr_api.cannot_find_prog_unit then
123 hr_api.cannot_find_prog_unit_error
124 (
125 p_module_name => 'CREATE_ELIG_ANTHR_PL_PRTE'
126 ,p_hook_type => 'BP'
127 );
128 --
129 -- End of API User Hook for the before hook of create_ELIG_ANTHR_PL_PRTE
130 --
131 end;
132 --
133 hr_utility.set_location(l_proc, 30);
134 ben_eop_ins.ins
135 (
136 p_ELIG_ANTHR_PL_PRTE_id => l_ELIG_ANTHR_PL_PRTE_id
137 ,p_effective_start_date => l_effective_start_date
138 ,p_effective_end_date => l_effective_end_date
139 ,p_excld_flag => p_excld_flag
140 ,p_ordr_num => p_ordr_num
141 ,p_pl_id => p_pl_id
142 ,p_eligy_prfl_id => p_eligy_prfl_id
143 ,p_business_group_id => p_business_group_id
144 ,p_eop_attribute_category => p_eop_attribute_category
145 ,p_eop_attribute1 => p_eop_attribute1
146 ,p_eop_attribute2 => p_eop_attribute2
147 ,p_eop_attribute3 => p_eop_attribute3
148 ,p_eop_attribute4 => p_eop_attribute4
149 ,p_eop_attribute5 => p_eop_attribute5
150 ,p_eop_attribute6 => p_eop_attribute6
151 ,p_eop_attribute7 => p_eop_attribute7
152 ,p_eop_attribute8 => p_eop_attribute8
153 ,p_eop_attribute9 => p_eop_attribute9
154 ,p_eop_attribute10 => p_eop_attribute10
155 ,p_eop_attribute11 => p_eop_attribute11
156 ,p_eop_attribute12 => p_eop_attribute12
157 ,p_eop_attribute13 => p_eop_attribute13
158 ,p_eop_attribute14 => p_eop_attribute14
159 ,p_eop_attribute15 => p_eop_attribute15
160 ,p_eop_attribute16 => p_eop_attribute16
161 ,p_eop_attribute17 => p_eop_attribute17
162 ,p_eop_attribute18 => p_eop_attribute18
163 ,p_eop_attribute19 => p_eop_attribute19
164 ,p_eop_attribute20 => p_eop_attribute20
165 ,p_eop_attribute21 => p_eop_attribute21
166 ,p_eop_attribute22 => p_eop_attribute22
167 ,p_eop_attribute23 => p_eop_attribute23
168 ,p_eop_attribute24 => p_eop_attribute24
169 ,p_eop_attribute25 => p_eop_attribute25
170 ,p_eop_attribute26 => p_eop_attribute26
171 ,p_eop_attribute27 => p_eop_attribute27
172 ,p_eop_attribute28 => p_eop_attribute28
173 ,p_eop_attribute29 => p_eop_attribute29
174 ,p_eop_attribute30 => p_eop_attribute30
175 ,p_object_version_number => l_object_version_number
176 ,p_effective_date => trunc(p_effective_date)
177 );
178 --
179 hr_utility.set_location(l_proc, 40);
180 begin
181 --
182 -- Start of API User Hook for the after hook of create_ELIG_ANTHR_PL_PRTE
183 --
184 ben_ELIG_ANTHR_PL_PRTE_bk1.create_ELIG_ANTHR_PL_PRTE_a
185 (
186 p_ELIG_ANTHR_PL_PRTE_id => l_ELIG_ANTHR_PL_PRTE_id
187 ,p_effective_start_date => l_effective_start_date
188 ,p_effective_end_date => l_effective_end_date
189 ,p_excld_flag => p_excld_flag
190 ,p_ordr_num => p_ordr_num
191 ,p_pl_id => p_pl_id
192 ,p_eligy_prfl_id => p_eligy_prfl_id
193 ,p_business_group_id => p_business_group_id
194 ,p_eop_attribute_category => p_eop_attribute_category
195 ,p_eop_attribute1 => p_eop_attribute1
196 ,p_eop_attribute2 => p_eop_attribute2
197 ,p_eop_attribute3 => p_eop_attribute3
198 ,p_eop_attribute4 => p_eop_attribute4
199 ,p_eop_attribute5 => p_eop_attribute5
200 ,p_eop_attribute6 => p_eop_attribute6
201 ,p_eop_attribute7 => p_eop_attribute7
202 ,p_eop_attribute8 => p_eop_attribute8
203 ,p_eop_attribute9 => p_eop_attribute9
204 ,p_eop_attribute10 => p_eop_attribute10
205 ,p_eop_attribute11 => p_eop_attribute11
206 ,p_eop_attribute12 => p_eop_attribute12
207 ,p_eop_attribute13 => p_eop_attribute13
208 ,p_eop_attribute14 => p_eop_attribute14
209 ,p_eop_attribute15 => p_eop_attribute15
210 ,p_eop_attribute16 => p_eop_attribute16
211 ,p_eop_attribute17 => p_eop_attribute17
212 ,p_eop_attribute18 => p_eop_attribute18
213 ,p_eop_attribute19 => p_eop_attribute19
214 ,p_eop_attribute20 => p_eop_attribute20
215 ,p_eop_attribute21 => p_eop_attribute21
216 ,p_eop_attribute22 => p_eop_attribute22
217 ,p_eop_attribute23 => p_eop_attribute23
218 ,p_eop_attribute24 => p_eop_attribute24
219 ,p_eop_attribute25 => p_eop_attribute25
220 ,p_eop_attribute26 => p_eop_attribute26
221 ,p_eop_attribute27 => p_eop_attribute27
222 ,p_eop_attribute28 => p_eop_attribute28
223 ,p_eop_attribute29 => p_eop_attribute29
224 ,p_eop_attribute30 => p_eop_attribute30
225 ,p_object_version_number => l_object_version_number
226 ,p_effective_date => trunc(p_effective_date)
227 );
228 exception
229 when hr_api.cannot_find_prog_unit then
230 hr_api.cannot_find_prog_unit_error
231 (p_module_name => 'CREATE_ELIG_ANTHR_PL_PRTE'
232 ,p_hook_type => 'AP'
233 );
234 --
235 -- End of API User Hook for the after hook of create_ELIG_ANTHR_PL_PRTE
236 --
237 end;
238 hr_utility.set_location(l_proc, 50);
239 --
240 ben_profile_handler.event_handler
241 (p_event => 'CREATE',
242 p_base_table => 'BEN_ELIGY_PRFL_F',
243 p_base_table_column => 'ELIGY_PRFL_ID',
244 p_base_table_column_value => p_eligy_prfl_id,
245 p_base_table_reference_column => 'ELIG_ANTHR_PL_FLAG',
246 p_reference_table => 'BEN_ELIG_ANTHR_PL_PRTE_F',
247 p_reference_table_column => 'ELIGY_PRFL_ID');
248 --
249 hr_utility.set_location(l_proc, 60);
250 --
251 -- When in validation only mode raise the Validate_Enabled exception
252 --
253 if p_validate then
254 raise hr_api.validate_enabled;
255 end if;
256 --
257 -- Set all output arguments
258 --
259 p_ELIG_ANTHR_PL_PRTE_id := l_ELIG_ANTHR_PL_PRTE_id;
260 p_effective_start_date := l_effective_start_date;
261 p_effective_end_date := l_effective_end_date;
262 p_object_version_number := l_object_version_number;
263 --
264 hr_utility.set_location(' Leaving:'||l_proc, 70);
265 --
266 exception
267 --
268 when hr_api.validate_enabled then
269 --
270 -- As the Validate_Enabled exception has been raised
271 -- we must rollback to the savepoint
272 --
273 ROLLBACK TO create_ELIG_ANTHR_PL_PRTE;
274 --
275 -- Only set output warning arguments
276 -- (Any key or derived arguments must be set to null
277 -- when validation only mode is being used.)
278 --
279 p_ELIG_ANTHR_PL_PRTE_id := null;
280 p_effective_start_date := null;
281 p_effective_end_date := null;
282 p_object_version_number := null;
283 hr_utility.set_location(' Leaving:'||l_proc, 80);
284 --
285 when others then
286 --
287 -- A validation or unexpected error has occured
288 --
289 ROLLBACK TO create_ELIG_ANTHR_PL_PRTE;
290 p_ELIG_ANTHR_PL_PRTE_id := null;
291 p_effective_start_date := null;
292 p_effective_end_date := null;
293 p_object_version_number := null;
294 raise;
295 --
296 end create_ELIG_ANTHR_PL_PRTE;
297 -- ----------------------------------------------------------------------------
298 -- |------------------------< update_ELIG_ANTHR_PL_PRTE >--- ------------------|
299 -- ----------------------------------------------------------------------------
300 --
301 procedure update_ELIG_ANTHR_PL_PRTE
302 (p_validate in boolean default false
303 ,p_ELIG_ANTHR_PL_PRTE_id in number
304 ,p_effective_start_date out nocopy date
305 ,p_effective_end_date out nocopy date
306 ,p_excld_flag in varchar2 default hr_api.g_varchar2
307 ,p_ordr_num in number default hr_api.g_number
308 ,p_pl_id in number default hr_api.g_number
309 ,p_eligy_prfl_id in number default hr_api.g_number
310 ,p_business_group_id in number default hr_api.g_number
311 ,p_eop_attribute_category in varchar2 default hr_api.g_varchar2
312 ,p_eop_attribute1 in varchar2 default hr_api.g_varchar2
313 ,p_eop_attribute2 in varchar2 default hr_api.g_varchar2
314 ,p_eop_attribute3 in varchar2 default hr_api.g_varchar2
315 ,p_eop_attribute4 in varchar2 default hr_api.g_varchar2
316 ,p_eop_attribute5 in varchar2 default hr_api.g_varchar2
317 ,p_eop_attribute6 in varchar2 default hr_api.g_varchar2
318 ,p_eop_attribute7 in varchar2 default hr_api.g_varchar2
319 ,p_eop_attribute8 in varchar2 default hr_api.g_varchar2
323 ,p_eop_attribute12 in varchar2 default hr_api.g_varchar2
320 ,p_eop_attribute9 in varchar2 default hr_api.g_varchar2
321 ,p_eop_attribute10 in varchar2 default hr_api.g_varchar2
322 ,p_eop_attribute11 in varchar2 default hr_api.g_varchar2
324 ,p_eop_attribute13 in varchar2 default hr_api.g_varchar2
325 ,p_eop_attribute14 in varchar2 default hr_api.g_varchar2
326 ,p_eop_attribute15 in varchar2 default hr_api.g_varchar2
327 ,p_eop_attribute16 in varchar2 default hr_api.g_varchar2
328 ,p_eop_attribute17 in varchar2 default hr_api.g_varchar2
329 ,p_eop_attribute18 in varchar2 default hr_api.g_varchar2
330 ,p_eop_attribute19 in varchar2 default hr_api.g_varchar2
331 ,p_eop_attribute20 in varchar2 default hr_api.g_varchar2
332 ,p_eop_attribute21 in varchar2 default hr_api.g_varchar2
333 ,p_eop_attribute22 in varchar2 default hr_api.g_varchar2
334 ,p_eop_attribute23 in varchar2 default hr_api.g_varchar2
335 ,p_eop_attribute24 in varchar2 default hr_api.g_varchar2
336 ,p_eop_attribute25 in varchar2 default hr_api.g_varchar2
337 ,p_eop_attribute26 in varchar2 default hr_api.g_varchar2
338 ,p_eop_attribute27 in varchar2 default hr_api.g_varchar2
339 ,p_eop_attribute28 in varchar2 default hr_api.g_varchar2
340 ,p_eop_attribute29 in varchar2 default hr_api.g_varchar2
341 ,p_eop_attribute30 in varchar2 default hr_api.g_varchar2
342 ,p_object_version_number in out nocopy number
343 ,p_effective_date in date
344 ,p_datetrack_mode in varchar2
345 ) is
346 --
347 -- Declare cursors and local variables
348 --
349 l_proc varchar2(72) := g_package||'update_ELIG_ANTHR_PL_PRTE';
350 l_object_version_number ben_ELIG_ANTHR_PL_PRTE_f.object_version_number%TYPE;
351 l_effective_start_date ben_ELIG_ANTHR_PL_PRTE_f.effective_start_date%TYPE;
352 l_effective_end_date ben_ELIG_ANTHR_PL_PRTE_f.effective_end_date%TYPE;
353 --
354 begin
355 --
356 hr_utility.set_location('Entering:'|| l_proc, 10);
357 --
358 -- Issue a savepoint if operating in validation only mode
359 --
360 savepoint update_ELIG_ANTHR_PL_PRTE;
361 --
362 hr_utility.set_location(l_proc, 20);
363 --
364 -- Process Logic
365 --
366 l_object_version_number := p_object_version_number;
367 --
368 begin
369 --
370 -- Start of API User Hook for the before hook of update_ELIG_ANTHR_PL_PRTE
371 --
372 ben_ELIG_ANTHR_PL_PRTE_bk2.update_ELIG_ANTHR_PL_PRTE_b
373 (
374 p_ELIG_ANTHR_PL_PRTE_id => p_ELIG_ANTHR_PL_PRTE_id
375 ,p_excld_flag => p_excld_flag
376 ,p_ordr_num => p_ordr_num
377 ,p_pl_id => p_pl_id
378 ,p_eligy_prfl_id => p_eligy_prfl_id
379 ,p_business_group_id => p_business_group_id
380 ,p_eop_attribute_category => p_eop_attribute_category
381 ,p_eop_attribute1 => p_eop_attribute1
382 ,p_eop_attribute2 => p_eop_attribute2
383 ,p_eop_attribute3 => p_eop_attribute3
384 ,p_eop_attribute4 => p_eop_attribute4
385 ,p_eop_attribute5 => p_eop_attribute5
386 ,p_eop_attribute6 => p_eop_attribute6
387 ,p_eop_attribute7 => p_eop_attribute7
388 ,p_eop_attribute8 => p_eop_attribute8
389 ,p_eop_attribute9 => p_eop_attribute9
390 ,p_eop_attribute10 => p_eop_attribute10
391 ,p_eop_attribute11 => p_eop_attribute11
392 ,p_eop_attribute12 => p_eop_attribute12
393 ,p_eop_attribute13 => p_eop_attribute13
394 ,p_eop_attribute14 => p_eop_attribute14
395 ,p_eop_attribute15 => p_eop_attribute15
396 ,p_eop_attribute16 => p_eop_attribute16
397 ,p_eop_attribute17 => p_eop_attribute17
398 ,p_eop_attribute18 => p_eop_attribute18
399 ,p_eop_attribute19 => p_eop_attribute19
400 ,p_eop_attribute20 => p_eop_attribute20
401 ,p_eop_attribute21 => p_eop_attribute21
402 ,p_eop_attribute22 => p_eop_attribute22
403 ,p_eop_attribute23 => p_eop_attribute23
404 ,p_eop_attribute24 => p_eop_attribute24
405 ,p_eop_attribute25 => p_eop_attribute25
406 ,p_eop_attribute26 => p_eop_attribute26
407 ,p_eop_attribute27 => p_eop_attribute27
408 ,p_eop_attribute28 => p_eop_attribute28
409 ,p_eop_attribute29 => p_eop_attribute29
413 ,p_datetrack_mode => p_datetrack_mode
410 ,p_eop_attribute30 => p_eop_attribute30
411 ,p_object_version_number => p_object_version_number
412 ,p_effective_date => trunc(p_effective_date)
414 );
415 exception
416 when hr_api.cannot_find_prog_unit then
417 hr_api.cannot_find_prog_unit_error
418 (p_module_name => 'UPDATE_ELIG_ANTHR_PL_PRTE'
419 ,p_hook_type => 'BP'
420 );
421 --
422 -- End of API User Hook for the before hook of update_ELIG_ANTHR_PL_PRTE
423 --
424 end;
425 --
426 ben_eop_upd.upd
427 (
428 p_ELIG_ANTHR_PL_PRTE_id => p_ELIG_ANTHR_PL_PRTE_id
429 ,p_effective_start_date => l_effective_start_date
430 ,p_effective_end_date => l_effective_end_date
431 ,p_excld_flag => p_excld_flag
432 ,p_ordr_num => p_ordr_num
433 ,p_pl_id => p_pl_id
434 ,p_eligy_prfl_id => p_eligy_prfl_id
435 ,p_business_group_id => p_business_group_id
436 ,p_eop_attribute_category => p_eop_attribute_category
437 ,p_eop_attribute1 => p_eop_attribute1
438 ,p_eop_attribute2 => p_eop_attribute2
439 ,p_eop_attribute3 => p_eop_attribute3
440 ,p_eop_attribute4 => p_eop_attribute4
441 ,p_eop_attribute5 => p_eop_attribute5
442 ,p_eop_attribute6 => p_eop_attribute6
443 ,p_eop_attribute7 => p_eop_attribute7
444 ,p_eop_attribute8 => p_eop_attribute8
445 ,p_eop_attribute9 => p_eop_attribute9
446 ,p_eop_attribute10 => p_eop_attribute10
447 ,p_eop_attribute11 => p_eop_attribute11
448 ,p_eop_attribute12 => p_eop_attribute12
449 ,p_eop_attribute13 => p_eop_attribute13
450 ,p_eop_attribute14 => p_eop_attribute14
451 ,p_eop_attribute15 => p_eop_attribute15
452 ,p_eop_attribute16 => p_eop_attribute16
453 ,p_eop_attribute17 => p_eop_attribute17
454 ,p_eop_attribute18 => p_eop_attribute18
455 ,p_eop_attribute19 => p_eop_attribute19
456 ,p_eop_attribute20 => p_eop_attribute20
457 ,p_eop_attribute21 => p_eop_attribute21
458 ,p_eop_attribute22 => p_eop_attribute22
459 ,p_eop_attribute23 => p_eop_attribute23
460 ,p_eop_attribute24 => p_eop_attribute24
461 ,p_eop_attribute25 => p_eop_attribute25
462 ,p_eop_attribute26 => p_eop_attribute26
463 ,p_eop_attribute27 => p_eop_attribute27
464 ,p_eop_attribute28 => p_eop_attribute28
465 ,p_eop_attribute29 => p_eop_attribute29
466 ,p_eop_attribute30 => p_eop_attribute30
467 ,p_object_version_number => l_object_version_number
468 ,p_effective_date => trunc(p_effective_date)
469 ,p_datetrack_mode => p_datetrack_mode
470 );
471 --
472 begin
473 --
474 -- Start of API User Hook for the after hook of update_ELIG_ANTHR_PL_PRTE
475 --
476 ben_ELIG_ANTHR_PL_PRTE_bk2.update_ELIG_ANTHR_PL_PRTE_a
477 (
478 p_ELIG_ANTHR_PL_PRTE_id => p_ELIG_ANTHR_PL_PRTE_id
479 ,p_effective_start_date => l_effective_start_date
480 ,p_effective_end_date => l_effective_end_date
481 ,p_excld_flag => p_excld_flag
482 ,p_ordr_num => p_ordr_num
483 ,p_pl_id => p_pl_id
484 ,p_eligy_prfl_id => p_eligy_prfl_id
485 ,p_business_group_id => p_business_group_id
486 ,p_eop_attribute_category => p_eop_attribute_category
487 ,p_eop_attribute1 => p_eop_attribute1
488 ,p_eop_attribute2 => p_eop_attribute2
489 ,p_eop_attribute3 => p_eop_attribute3
490 ,p_eop_attribute4 => p_eop_attribute4
491 ,p_eop_attribute5 => p_eop_attribute5
492 ,p_eop_attribute6 => p_eop_attribute6
493 ,p_eop_attribute7 => p_eop_attribute7
494 ,p_eop_attribute8 => p_eop_attribute8
495 ,p_eop_attribute9 => p_eop_attribute9
496 ,p_eop_attribute10 => p_eop_attribute10
497 ,p_eop_attribute11 => p_eop_attribute11
498 ,p_eop_attribute12 => p_eop_attribute12
499 ,p_eop_attribute13 => p_eop_attribute13
500 ,p_eop_attribute14 => p_eop_attribute14
501 ,p_eop_attribute15 => p_eop_attribute15
502 ,p_eop_attribute16 => p_eop_attribute16
503 ,p_eop_attribute17 => p_eop_attribute17
504 ,p_eop_attribute18 => p_eop_attribute18
505 ,p_eop_attribute19 => p_eop_attribute19
506 ,p_eop_attribute20 => p_eop_attribute20
507 ,p_eop_attribute21 => p_eop_attribute21
508 ,p_eop_attribute22 => p_eop_attribute22
509 ,p_eop_attribute23 => p_eop_attribute23
510 ,p_eop_attribute24 => p_eop_attribute24
514 ,p_eop_attribute28 => p_eop_attribute28
511 ,p_eop_attribute25 => p_eop_attribute25
512 ,p_eop_attribute26 => p_eop_attribute26
513 ,p_eop_attribute27 => p_eop_attribute27
515 ,p_eop_attribute29 => p_eop_attribute29
516 ,p_eop_attribute30 => p_eop_attribute30
517 ,p_object_version_number => l_object_version_number
518 ,p_effective_date => trunc(p_effective_date)
519 ,p_datetrack_mode => p_datetrack_mode
520 );
521 exception
522 when hr_api.cannot_find_prog_unit then
523 hr_api.cannot_find_prog_unit_error
524 (p_module_name => 'UPDATE_ELIG_ANTHR_PL_PRTE'
525 ,p_hook_type => 'AP'
526 );
527 --
528 -- End of API User Hook for the after hook of update_ELIG_ANTHR_PL_PRTE
529 --
530 end;
531 --
532 hr_utility.set_location(l_proc, 60);
533 --
534 -- When in validation only mode raise the Validate_Enabled exception
535 --
536 if p_validate then
537 raise hr_api.validate_enabled;
538 end if;
539 --
540 -- Set all output arguments
541 --
542 p_object_version_number := l_object_version_number;
543 p_effective_start_date := l_effective_start_date;
544 p_effective_end_date := l_effective_end_date;
545 --
546 hr_utility.set_location(' Leaving:'||l_proc, 70);
547 --
548 exception
549 --
550 when hr_api.validate_enabled then
551 --
552 -- As the Validate_Enabled exception has been raised
553 -- we must rollback to the savepoint
554 --
555 ROLLBACK TO update_ELIG_ANTHR_PL_PRTE;
556 --
557 -- Only set output warning arguments
558 -- (Any key or derived arguments must be set to null
559 -- when validation only mode is being used.)
560 --
561 p_effective_start_date := null;
562 p_effective_end_date := null;
563 hr_utility.set_location(' Leaving:'||l_proc, 80);
564 --
565 when others then
566 --
567 -- A validation or unexpected error has occured
568 --
569 ROLLBACK TO update_ELIG_ANTHR_PL_PRTE;
570 p_effective_start_date := null;
571 p_effective_end_date := null;
572 raise;
573 --
574 end update_ELIG_ANTHR_PL_PRTE;
575 -- ----------------------------------------------------------------------------
576 -- |------------------------< delete_ELIG_ANTHR_PL_PRTE >----------------------|
577 -- ----------------------------------------------------------------------------
578 --
579 procedure delete_ELIG_ANTHR_PL_PRTE
580 (p_validate in boolean default false
581 ,p_ELIG_ANTHR_PL_PRTE_id in number
582 ,p_effective_start_date out nocopy date
583 ,p_effective_end_date out nocopy date
584 ,p_object_version_number in out nocopy number
585 ,p_effective_date in date
586 ,p_datetrack_mode in varchar2
587 ) is
588 --
589 -- Declare cursors and local variables
590 --
591 l_proc varchar2(72) := g_package||'update_ELIG_ANTHR_PL_PRTE';
592 l_object_version_number ben_ELIG_ANTHR_PL_PRTE_f.object_version_number%TYPE;
593 l_effective_start_date ben_ELIG_ANTHR_PL_PRTE_f.effective_start_date%TYPE;
594 l_effective_end_date ben_ELIG_ANTHR_PL_PRTE_f.effective_end_date%TYPE;
595 --
596 begin
597 --
598 hr_utility.set_location('Entering:'|| l_proc, 10);
599 --
600 -- Issue a savepoint if operating in validation only mode
601 --
602 savepoint delete_ELIG_ANTHR_PL_PRTE;
603 --
604 hr_utility.set_location(l_proc, 20);
605 --
606 -- Process Logic
607 --
608 l_object_version_number := p_object_version_number;
609 --
610 --
611 begin
612 --
613 -- Start of API User Hook for the before hook of delete_ELIG_ANTHR_PL_PRTE
614 --
615 ben_ELIG_ANTHR_PL_PRTE_bk3.delete_ELIG_ANTHR_PL_PRTE_b
616 (
617 p_ELIG_ANTHR_PL_PRTE_id => p_ELIG_ANTHR_PL_PRTE_id
618 ,p_object_version_number => p_object_version_number
619 ,p_effective_date => trunc(p_effective_date)
620 ,p_datetrack_mode => p_datetrack_mode
621 );
622 exception
623 when hr_api.cannot_find_prog_unit then
624 hr_api.cannot_find_prog_unit_error
625 (p_module_name => 'DELETE_ELIG_ANTHR_PL_PRTE'
626 ,p_hook_type => 'BP'
627 );
628 --
629 -- End of API User Hook for the before hook of delete_ELIG_ANTHR_PL_PRTE
630 --
631 end;
632 --
633 ben_eop_del.del
634 (
635 p_ELIG_ANTHR_PL_PRTE_id => p_ELIG_ANTHR_PL_PRTE_id
636 ,p_effective_start_date => l_effective_start_date
637 ,p_effective_end_date => l_effective_end_date
638 ,p_object_version_number => l_object_version_number
639 ,p_effective_date => p_effective_date
640 ,p_datetrack_mode => p_datetrack_mode
641 );
642 --
643 begin
647 ben_ELIG_ANTHR_PL_PRTE_bk3.delete_ELIG_ANTHR_PL_PRTE_a
644 --
645 -- Start of API User Hook for the after hook of delete_ELIG_ANTHR_PL_PRTE
646 --
648 (
649 p_ELIG_ANTHR_PL_PRTE_id => p_ELIG_ANTHR_PL_PRTE_id
650 ,p_effective_start_date => l_effective_start_date
651 ,p_effective_end_date => l_effective_end_date
652 ,p_object_version_number => l_object_version_number
653 ,p_effective_date => trunc(p_effective_date)
654 ,p_datetrack_mode => p_datetrack_mode
655 );
656 exception
657 when hr_api.cannot_find_prog_unit then
658 hr_api.cannot_find_prog_unit_error
659 (p_module_name => 'DELETE_ELIG_ANTHR_PL_PRTE'
660 ,p_hook_type => 'AP'
661 );
662 --
663 -- End of API User Hook for the after hook of delete_ELIG_ANTHR_PL_PRTE
664 --
665 end;
666 --
667 ben_profile_handler.event_handler
668 (p_event => 'DELETE',
669 p_base_table => 'BEN_ELIGY_PRFL_F',
670 p_base_table_column => 'ELIGY_PRFL_ID',
671 p_base_table_column_value => ben_eop_shd.g_old_rec.eligy_prfl_id,
672 p_base_table_reference_column => 'ELIG_ANTHR_PL_FLAG',
673 p_reference_table => 'BEN_ELIG_ANTHR_PL_PRTE_F',
674 p_reference_table_column => 'ELIGY_PRFL_ID');
675 --
676 hr_utility.set_location(l_proc, 60);
677 --
678 -- When in validation only mode raise the Validate_Enabled exception
679 --
680 if p_validate then
681 raise hr_api.validate_enabled;
682 end if;
683 --
684 hr_utility.set_location(' Leaving:'||l_proc, 70);
685 --
686 exception
687 --
688 when hr_api.validate_enabled then
689 --
690 -- As the Validate_Enabled exception has been raised
691 -- we must rollback to the savepoint
692 --
693 ROLLBACK TO delete_ELIG_ANTHR_PL_PRTE;
694 --
695 -- Only set output warning arguments
696 -- (Any key or derived arguments must be set to null
697 -- when validation only mode is being used.)
698 --
699 p_effective_start_date := null;
700 p_effective_end_date := null;
701 --
702 when others then
703 --
704 -- A validation or unexpected error has occured
705 --
706 ROLLBACK TO delete_ELIG_ANTHR_PL_PRTE;
707 p_effective_start_date := null;
708 p_effective_end_date := null;
709 raise;
710 --
711 end delete_ELIG_ANTHR_PL_PRTE;
712 --
713 -- ----------------------------------------------------------------------------
714 -- |-------------------------------< lck >------------------------------------|
715 -- ----------------------------------------------------------------------------
716 --
717 procedure lck
718 (
722 ,p_datetrack_mode in varchar2
719 p_ELIG_ANTHR_PL_PRTE_id in number
720 ,p_object_version_number in number
721 ,p_effective_date in date
723 ,p_validation_start_date out nocopy date
724 ,p_validation_end_date out nocopy date
725 ) is
726 --
727 --
728 -- Declare cursors and local variables
729 --
730 l_proc varchar2(72) := g_package||'lck';
731 l_validation_start_date date;
732 l_validation_end_date date;
733 --
734 begin
735 --
736 hr_utility.set_location('Entering:'|| l_proc, 10);
737 --
738 ben_eop_shd.lck
739 (
740 p_ELIG_ANTHR_PL_PRTE_id => p_ELIG_ANTHR_PL_PRTE_id
741 ,p_validation_start_date => l_validation_start_date
742 ,p_validation_end_date => l_validation_end_date
743 ,p_object_version_number => p_object_version_number
744 ,p_effective_date => p_effective_date
745 ,p_datetrack_mode => p_datetrack_mode
746 );
747 --
748 hr_utility.set_location(' Leaving:'||l_proc, 70);
749 --
750 end lck;
751 --
752 end ben_ELIG_ANTHR_PL_PRTE_api;