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